Use tree_vector_builder::new_binary_operation for folding
[official-gcc.git] / gcc / ChangeLog
blob6fb516053546482cd109b7808a26d1ccecc2f4e3
1 2017-12-07  Richard Sandiford  <richard.sandiford@linaro.org>
3         * tree-vector-builder.h
4         (tree_vector_builder::new_binary_operation): Declare.
5         * tree-vector-builder.c
6         (tree_vector_builder::new_binary_operation): New function.
7         * fold-const.c (fold_relational_const): Use it.
8         (const_binop): Likewise.  Check that both input vectors have
9         the same number of elements, thus excluding things like WIDEN_SUM.
10         Check whether it is possible to operate directly on the encodings
11         of stepped inputs.
13 2017-12-07  Richard Sandiford  <richard.sandiford@linaro.org>
15         * fold-const.c (fold_negate_expr_1): Use tree_vector_builder and
16         new_unary_operation, operating only on the encoded elements.
17         (const_unop): Likewise.
18         (exact_inverse): Likewise.
19         (distributes_over_addition_p): New function.
20         (const_binop): Use tree_vector_builder and new_unary_operation
21         for combinations of VECTOR_CST and INTEGER_CST.  Operate only
22         on the encoded elements unless the encoding is strided and the
23         operation does not distribute over addition.
24         (fold_convert_const):  Use tree_vector_builder and
25         new_unary_operation.  Operate only on the encoded elements
26         for truncating integer conversions, or for non-stepped encodings.
28 2017-12-07  Richard Sandiford  <richard.sandiford@linaro.org>
30         * config/sparc/sparc.c: Include tree-vector-builder.h.
31         (sparc_fold_builtin): Use tree_vector_builder instead of build_vector.
32         * expmed.c: Include tree-vector-builder.h.
33         (make_tree): Use tree_vector_builder instead of build_vector.
34         * fold-const.c: Include tree-vector-builder.h.
35         (const_binop): Use tree_vector_builder instead of build_vector.
36         (const_unop): Likewise.
37         (native_interpret_vector): Likewise.
38         (fold_vec_perm): Likewise.
39         (fold_ternary_loc): Likewise.
40         * gimple-fold.c: Include tree-vector-builder.h.
41         (gimple_fold_stmt_to_constant_1): Use tree_vector_builder instead
42         of build_vector.
43         * tree-ssa-forwprop.c: Include tree-vector-builder.h.
44         (simplify_vector_constructor): Use tree_vector_builder instead
45         of build_vector.
46         * tree-vect-generic.c: Include tree-vector-builder.h.
47         (add_rshift): Use tree_vector_builder instead of build_vector.
48         (expand_vector_divmod): Likewise.
49         (optimize_vector_constructor): Likewise.
50         * tree-vect-loop.c: Include tree-vector-builder.h.
51         (vect_create_epilog_for_reduction): Use tree_vector_builder instead
52         of build_vector.  Explicitly use a stepped encoding for
53         { 1, 2, 3, ... }.
54         * tree-vect-slp.c: Include tree-vector-builder.h.
55         (vect_get_constant_vectors): Use tree_vector_builder instead
56         of build_vector.
57         (vect_transform_slp_perm_load): Likewise.
58         (vect_schedule_slp_instance): Likewise.
59         * tree-vect-stmts.c: Include tree-vector-builder.h.
60         (vectorizable_bswap): Use tree_vector_builder instead of build_vector.
61         (vect_gen_perm_mask_any): Likewise.
62         (vectorizable_call): Likewise.  Explicitly use a stepped encoding.
63         * tree.c: (build_vector_from_ctor): Use tree_vector_builder instead
64         of build_vector.
65         (build_vector_from_val): Likewise.  Explicitly use a duplicate
66         encoding.
68 2017-12-07  Richard Sandiford  <richard.sandiford@arm.com>
70         * doc/generic.texi (VECTOR_CST): Describe new representation of
71         vector constants.
72         * vector-builder.h: New file.
73         * tree-vector-builder.h: Likewise.
74         * tree-vector-builder.c: Likewise.
75         * Makefile.in (OBJS): Add tree-vector-builder.o.
76         * tree.def (VECTOR_CST): Update comment to refer to generic.texi.
77         * tree-core.h (tree_base): Add a vector_cst field to the u union.
78         (tree_vector): Change the number of elements to
79         vector_cst_encoded_nelts.
80         * tree.h (VECTOR_CST_NELTS): Redefine using TYPE_VECTOR_SUBPARTS.
81         (VECTOR_CST_ELTS): Delete.
82         (VECTOR_CST_ELT): Redefine using vector_cst_elt.
83         (VECTOR_CST_LOG2_NPATTERNS, VECTOR_CST_NPATTERNS): New macros.
84         (VECTOR_CST_NELTS_PER_PATTERN, VECTOR_CST_DUPLICATE_P): Likewise.
85         (VECTOR_CST_STEPPED_P, VECTOR_CST_ENCODED_ELTS): Likewise.
86         (VECTOR_CST_ENCODED_ELT): Likewise.
87         (vector_cst_encoded_nelts): New function.
88         (make_vector): Take the values of VECTOR_CST_LOG2_NPATTERNS and
89         VECTOR_CST_NELTS_PER_PATTERN as arguments.
90         (vector_cst_int_elt, vector_cst_elt): Declare.
91         * tree.c: Include tree-vector-builder.h.
92         (tree_code_size): Abort if passed VECTOR_CST.
93         (tree_size): Update for new VECTOR_CST layout.
94         (make_vector): Take the values of VECTOR_CST_LOG2_NPATTERNS and
95         VECTOR_CST_NELTS_PER_PATTERN as arguments.
96         (build_vector): Use tree_vector_builder.
97         (vector_cst_int_elt, vector_cst_elt): New functions.
98         (drop_tree_overflow): For VECTOR_CST, drop the TREE_OVERFLOW from the
99         encoded elements and then create the vector in the canonical form.
100         (check_vector_cst, check_vector_cst_duplicate, check_vector_cst_fill)
101         (check_vector_cst_stepped, test_vector_cst_patterns): New functions.
102         (tree_c_tests): Call test_vector_cst_patterns.
103         * lto-streamer-out.c (DFS::DFS_write_tree_body): Handle the new
104         VECTOR_CST fields.
105         (hash_tree): Likewise.
106         * tree-streamer-out.c (write_ts_vector_tree_pointers): Likewise.
107         (streamer_write_tree_header): Likewise.
108         * tree-streamer-in.c (lto_input_ts_vector_tree_pointers): Likewise.
109         (streamer_alloc_tree): Likewise.  Update call to make_vector.
110         * fold-const.c (fold_ternary_loc): Avoid using VECTOR_CST_ELTS.
112 2017-12-07  Richard Sandiford  <richard.sandiford@linaro.org>
114         * selftest.h (ASSERT_TRUE_AT, ASSERT_FALSE_AT, ASSERT_EQ_AT)
115         (ASSERT_NE, ASSERT_PRED1): Add underscores to local variable names
116         * selftest-rtl.h (ASSERT_RTX_EQ, ASSERT_RTX_PTR_EQ): Likewise.
118 2017-12-07  Bin Cheng  <bin.cheng@arm.com>
119             Richard Biener  <rguenther@suse.de>
121         PR tree-optimization/81303
122         * Makefile.in (gimple-loop-interchange.o): New object file.
123         * common.opt (floop-interchange): Reuse the option from graphite.
124         * doc/invoke.texi (-floop-interchange): Ditto.  New document for
125         -floop-interchange and mention it for -O3.
126         * opts.c (default_options_table): Enable -floop-interchange at -O3.
127         * gimple-loop-interchange.cc: New file.
128         * params.def (PARAM_LOOP_INTERCHANGE_MAX_NUM_STMTS): New parameter.
129         (PARAM_LOOP_INTERCHANGE_STRIDE_RATIO): New parameter.
130         * passes.def (pass_linterchange): New pass.
131         * timevar.def (TV_LINTERCHANGE): New time var.
132         * tree-pass.h (make_pass_linterchange): New declaration.
133         * tree-ssa-loop-ivcanon.c (create_canonical_iv): Change to external
134         interchange.  Record IV before/after increment in new parameters.
135         * tree-ssa-loop-ivopts.h (create_canonical_iv): New declaration.
136         * tree-vect-loop.c (vect_is_simple_reduction): Factor out reduction
137         path check into...
138         (check_reduction_path): ...New function here.
139         * tree-vectorizer.h (check_reduction_path): New declaration.
141 2017-12-07  Vladimir Makarov  <vmakarov@redhat.com>
143         PR target/83252
144         PR rtl-optimization/80818
145         * lra.c (add_regs_to_insn_regno_info): Make a hard reg in CLOBBER
146         always early clobbered.
147         * lra-lives.c (process_bb_lives): Check input hard regs for early
148         clobbered non-operand hard reg.
150 2017-12-07  Jakub Jelinek  <jakub@redhat.com>
152         PR middle-end/83164
153         * tree-cfg.c (verify_gimple_assign_binary): Don't require
154         types_compatible_p, just that TYPE_MODE is the same.
156 2017-12-07  Martin Sebor  <msebor@redhat.com>
158         PR c/81544
159         * attribs.c (empty_attribute_table): Initialize new member of
160         struct attribute_spec.
161         (decl_attributes): Add argument.  Handle mutually exclusive
162         combinations of attributes.
163         (selftests::test_attribute_exclusions): New function.
164         (selftests::attribute_c_tests): Ditto.
165         * attribs.h (decl_attributes): Add default argument.
166         * selftest.h (attribute_c_tests): Declare.
167         * selftest-run-tests.c (selftest::run_tests): Call attribute_c_tests.
168         * tree-core.h (attribute_spec::exclusions, exclude): New type and
169         member.
170         * doc/extend.texi (Common Function Attributes): Update const and pure.
171         * config/alpha/alpha.c (vms_attribute_table): Initialize new member
172         of struct attribute_spec.
173         * config/arc/arc.c (arc_attribute_table): Same.
174         * config/arm/arm.c (arm_attribute_table): Same.
175         * config/avr/avr.c ( avr_attribute_table): Same.
176         * config/bfin/bfin.c (bfin_attribute_table): Same.
177         * config/cr16/cr16.c (cr16_attribute_table): Same.
178         * config/epiphany/epiphany.c (epiphany_attribute_table): Same.
179         * config/h8300/h8300.c (h8300_attribute_table): Same.
180         * config/i386/i386.c (ix86_attribute_table): Same.
181         * config/ia64/ia64.c (ia64_attribute_table): Same.
182         * config/m32c/m32c.c (m32c_attribute_table): Same.
183         * config/m32r/m32r.c (m32r_attribute_table): Same.
184         * config/m68k/m68k.c (m68k_attribute_table): Same.
185         * config/mcore/mcore.c (mcore_attribute_table): Same.
186         * config/microblaze/microblaze.c (microblaze_attribute_table): Same.
187         * config/mips/mips.c (mips_attribute_table): Same.
188         * config/msp430/msp430.c (msp430_attribute_table): Same.
189         * config/nds32/nds32.c (nds32_attribute_table): Same.
190         * config/nvptx/nvptx.c (nvptx_attribute_table): Same.
191         * config/powerpcspe/powerpcspe.c (rs6000_attribute_table): Same.
192         * config/rl78/rl78.c (rl78__attribute_table): Same.
193         * config/rs6000/rs6000.c (rs6000_attribute_table): Same.
194         * onfig/rx/rx.c (rx_attribute_table): Same.
195         * config/s390/s390.c (s390_handle_vectorbool_attribute): Same.
196         * config/sh/sh.c (sh_attribute_table): Same.
197         * config/sparc/sparc.c (sparc_attribute_table): Same.
198         * config/spu/spu.c (spu_attribute_table): Same.
199         * config/stormy16/stormy16.c (xstormy16_attribute_table): Same.
200         * config/v850/v850.c (v850_attribute_table): Same.
201         * config/visium/visium.c (visium_attribute_table): Same.
203 2017-12-07  Tamar Christina  <tamar.christina@arm.com>
205         PR target/82641
206         * config/arm/arm.c (INCLUDE_STRING): Define.
207         (arm_last_printed_arch_string, arm_last_printed_fpu_string): New.
208         (arm_declare_function_name): Conservatively emit .arch, .arch_extensions
209         and .fpu.
211 2017-12-07  Michael Matz  <matz@suse.de>
213         Add unroll and jam pass
215         * gimple-loop-jam.c: New file.
216         * Makefile.in (OBJS): Add gimple-loop-jam.o.
217         * common.opt (funroll-and-jam): New option.
218         * opts.c (default_options_table): Add unroll-and-jam at -O3.
219         * params.def (PARAM_UNROLL_JAM_MIN_PERCENT): New param.
220         (PARAM_UNROLL_JAM_MAX_UNROLL): Ditto.
221         * passes.def: Add pass_loop_jam.
222         * timevar.def (TV_LOOP_JAM): Add.
223         * tree-pass.h (make_pass_loop_jam): Declare.
224         * cfgloop.c (flow_loop_tree_node_add): Add AT argument.
225         * cfgloop.h (flow_loop_tree_node_add): Adjust declaration.
226         * cfgloopmanip.c (duplicate_loop): Add AT argument, adjust call
227         to flow_loop_tree_node_add.
228         (duplicate_subloops, copy_loops_to): Append to sibling list.
229         * cfgloopmanip.h: (duplicate_loop): Adjust declaration.
230         * doc/invoke.texi (-funroll-and-jam): Document new option.
231         (unroll-jam-min-percent, unroll-jam-max-unroll): Document new params.
233 2017-12-07  Richard Biener  <rguenther@suse.de>
235         PR tree-optimization/83296
236         PR tree-optimization/67769
237         * tree-ssa-phiopt.c (conditional_replacement): Do not reset
238         flow sensitive info in an unrelated BB.
239         (value_replacement): Use reset_flow_sensitive_info.
240         (minmax_replacement): Reset flow sensitive info on the def
241         we move.  Do not reset flow sensitive info in the whole BB
242         we move the stmt to.
243         (abs_replacement): Likewise.
245 2017-12-07  Segher Boessenkool  <segher@kernel.crashing.org>
247         PR target/43871
248         * config/rs6000/rs6000.c (rs6000_option_override_internal): Set
249         rs6000_cpu to the given -mcpu=, or to the default processor.
251 2017-12-07  Segher Boessenkool  <segher@kernel.crashing.org>
253         * config/rs6000/rs6000.h (rs6000_cpu_attr): Delete.
254         * config/rs6000/rs6000.c (rs6000_variable_issue_1): Use rs6000_tune
255         instead of rs6000_cpu_attr.
256         (rs6000_adjust_cost): Ditto.
257         (is_microcoded_insn): Ditto.
258         (rs6000_adjust_priority): Ditto.
259         (rs6000_issue_rate): Ditto.
260         (rs6000_use_sched_lookahead): Ditto.
261         (rs6000_use_sched_lookahead_guard): Ditto.
262         (rs6000_sched_reorder): Ditto.
263         (force_new_group): Ditto.
264         * config/rs6000/rs6000.md (cpu attribute): Ditto.
265         (group_ending_nop): Ditto.
267 2017-12-07  Segher Boessenkool  <segher@kernel.crashing.org>
269         * config/rs6000/rs6000.opt (rs6000_tune): New variable.
270         * config/rs6000/rs6000.c (rs6000_option_override_internal): Also set
271         rs6000_tune.  Use rs6000_tune instead of rs6000_cpu where appropriate.
272         (rs6000_loop_align): Use rs6000_tune instead of rs6000_cpu where
273         appropriate.
274         (rs6000_reassociation_width): Ditto.
275         (rs6000_emit_epilogue): Ditto.
276         (rs6000_adjust_cost): Ditto.
277         (is_microcoded_insn): Ditto.
278         (is_cracked_insn): Ditto.
279         (rs6000_adjust_priority): Ditto.
280         (rs6000_sched_reorder): Ditto.
281         (rs6000_sched_reorder2): Ditto.
282         (insn_must_be_first_in_group): Ditto.
283         (insn_must_be_last_in_group): Ditto.
284         (rs6000_register_move_cost): Ditto.
285         * config/rs6000/rs6000.h (rs6000_cpu_attr): Use rs6000_tune instead of
286         rs6000_cpu.
288 2017-12-07  Julia Koval  <julia.koval@intel.com>
290         * config.gcc: Add vaesintrin.h.
291         * config/i386/i386-builtin-types.def (V64QI_FTYPE_V64QI_V64QI): New type.
292         * config/i386/i386-builtin.def (__builtin_ia32_vaesdec_v16qi,
293         __builtin_ia32_vaesdec_v32qi, __builtin_ia32_vaesdec_v64qi): New builtins.
294         * config/i386/i386.c (ix86_expand_args_builtin): Handle new type.
295         * config/i386/immintrin.h: Include vaesintrin.h.
296         * config/i386/sse.md (vaesdec_<mode>): New pattern.
297         * config/i386/vaesintrin.h (_mm256_aesdec_epi128, _mm512_aesdec_epi128,
298         _mm_aesdec_epi128): New intrinsics.
300 2017-12-06  David Malcolm  <dmalcolm@redhat.com>
302         * Makefile.in (C_COMMON_OBJS): Add c-family/c-spellcheck.o.
303         * spellcheck-tree.c (find_closest_macro_cpp_cb): Move to
304         c-family/c-spellcheck.cc.
305         (best_macro_match::best_macro_match): Likewise.
306         * spellcheck-tree.h
307         (struct edit_distance_traits<cpp_hashnode *>): Move to
308         c-family/c-spellcheck.h.
309         (class best_macro_match): Likewise.
311 2017-12-06  Jakub Jelinek  <jakub@redhat.com>
313         PR tree-optimization/83293
314         * gimple-ssa-strength-reduction.c (insert_initializers): Use
315         GSI_NEW_STMT instead of GSI_SAME_STMT in gsi_insert_after that
316         might insert into empty bb.
318         PR sanitizer/81281
319         * match.pd ((T)(P + A) - (T)P -> (T) A): Split into separate
320         simplify for plus with :c added, and pointer_plus without that.
321         ((T)P - (T)(P + A) -> -(T) A): Likewise.  If type is integral
322         with undefined overflow and the conversion is not widening,
323         perform negation in utype and only convert to type afterwards.
324         ((T)(P + A) - (T)(P + B) -> (T)A - (T)B): Split into separate
325         simplify for plus with :c added, and pointer_plus without that.
326         If type is integral with undefined overflow and the conversion is
327         not widening, perform minus in utype and only convert to type
328         afterwards.  Move the last pointer_diff_expr simplify into the
329         two outermost ifs.
331 2017-12-06  Martin Sebor  <msebor@redhat.com>
333         PR tree-optimization/82646
334         * builtins.c (maybe_emit_chk_warning): Use size as the bound for
335         strncpy, not maxlen.
337 2017-12-06  Martin Sebor  <msebor@redhat.com>
339         * doc/invoke.texi (-Wstringop-truncation): Mention attribute
340         nonstring.
342         PR tree-optimization/83075
343         * tree-ssa-strlen.c (handle_builtin_stxncpy): Avoid assuming
344         strncat/strncpy don't change length of source string.
346 2017-12-06  Eric Botcazou  <ebotcazou@adacore.com>
348         Revert
349         2017-11-29  Martin Aberg  <maberg@gaisler.com>
351         * config/sparc/sparc.md (divdf3_fix): Add NOP and adjust length
352         to prevent b2bst errata sequence.
353         (sqrtdf2_fix): Likewise.
355 2017-12-06  Jakub Jelinek  <jakub@redhat.com>
357         PR tree-optimization/81945
358         * cfgloop.h (FOR_EACH_LOOP_FN): Use FN instead of hardcoding fn.
359         * tree-cfg.c (move_sese_region_to_fn): If any of the loops moved
360         to dest_cfun has orig_loop_num set, either remap it to the new
361         loop number if the loop got moved too, or clear it.
363 2017-12-05  Steve Ellcey  <sellcey@cavium.com>
365         * config/aarch64/thunderx2-t99.md (thunderx2t99_branch): Add trap
366         to reservation.
367         (thunderx2t99_nothing): New insn reservation.
368         (thunderx2t99_mrs): New insn reservation.
369         (thunderx2t99_multiple): New insn reservation.
370         (thunderx2t99_alu_basi): Add bfx to reservation.
371         (thunderx2t99_fp_cmp): Add fccmps and fccmpd to reservation.
373 2017-12-05  Ramana Radhakrishnan  <ramana.radhakrishnan@arm.com>
375         PR target/82248
376         * config/arm/arm.md (probe_stack) : Use the 'o' constraint.
378 2017-12-05  Bin Cheng  <bin.cheng@arm.com>
380         * tree-ssa-dce.c (simple_dce_from_worklist): Move and rename from
381         tree-ssa-pre.c::remove_dead_inserted_code.
382         * tree-ssa-dce.h: New file.
383         * tree-ssa-pre.c (tree-ssa-dce.h): Include new header file.
384         (remove_dead_inserted_code): Move and rename to function
385         tree-ssa-dce.c::simple_dce_from_worklist.
386         (pass_pre::execute): Update use.
388 2017-12-05  Richard Biener  <rguenther@suse.de>
390         PR tree-optimization/83277
391         * graphite-isl-ast-to-gimple.c (should_copy_to_new_region): Make sure
392         to code-gen liveout vars.
394 2017-12-05  Richard Sandiford  <richard.sandiford@linaro.org>
396         * config/aarch64/aarch64-simd.md (aarch64_simd_bsldi_internal)
397         (aarch64_simd_bsldi_alt): Check REG_P before GP_REGNUM_P.
398         (aarch64_cm<optab>di, aarch64_cmtstdi): Add leading "&&" to
399         split condition.
401 2017-12-05  Max Filippov  <jcmvbkbc@gmail.com>
403         * config/xtensa/xtensa.c (xtensa_asan_shadow_offset): New
404         function.
405         (TARGET_ASAN_SHADOW_OFFSET): New macro definition.
406         * config/xtensa/xtensa.h (FRAME_GROWS_DOWNWARD): Set to 1 if
407         ASAN is enabled.
409 2017-12-05  Richard Biener   <rguenther@suse.de>
411         * timevar.def (TV_TREE_RECIP, TV_TREE_SINCOS, TV_TREE_WIDEN_MUL):
412         Add.
413         * tree-ssa-math-opts.c (pass_data_cse_reciprocal): Use TV_TREE_RECIP.
414         (pass_data_cse_sincos): Use TV_TREE_SINCOS.
415         (pass_data_optimize_widening_mul): Use TV_TREE_WIDEN_MUL.
417 2017-12-05  Rainer Orth  <ro@CeBiTec.Uni-Bielefeld.DE>
419         * dbxout.c (dbxout_block): Grow buf to 30 bytes.
421 2017-12-05  Martin Liska  <mliska@suse.cz>
422             Jakub Jelinek  <jakub@redhat.com>
424         * doc/invoke.texi: Document the options.
425         * flag-types.h (enum sanitize_code): Add
426         SANITIZE_POINTER_COMPARE and SANITIZE_POINTER_SUBTRACT.
427         * ipa-inline.c (sanitize_attrs_match_for_inline_p): Add handling
428         of SANITIZE_POINTER_COMPARE and SANITIZE_POINTER_SUBTRACT.
429         * opts.c: Define new sanitizer options.
430         * sanitizer.def (BUILT_IN_ASAN_POINTER_COMPARE): Likewise.
431         (BUILT_IN_ASAN_POINTER_SUBTRACT): Likewise.
433 2017-12-05  Julia Koval  <julia.koval@intel.com>
435         * common/config/i386/i386-common.c (OPTION_MASK_ISA_AVX512VNNI_SET,
436         OPTION_MASK_ISA_AVX512VNNI_UNSET): New.
437         (ix86_handle_option): Handle -mavx512vnni.
438         * config/i386/cpuid.h (bit_AVX512VNNI): New bit.
439         * config/i386/driver-i386.c (host_detect_local_cpu): Handle new bit.
440         * config/i386/i386-c (__AVX512VNNI__): New.
441         * config/i386/i386.c (ix86_target_string): Handle new option.
442         (ix86_valid_target_attribute_inner_p): Handle new option.
443         * config/i386/i386.h (TARGET_AVX512VNNI, TARGET_AVX512VNNI_P): New.
444         * config/i386/i386.opt (mavx512vnni): New option.
446 2017-12-01  Jan Hubicka  <hubicka@ucw.cz>
448         PR target/81616
449         * athlon.md: Disable for generic.
450         * haswell.md: Enable for generic.
451         * i386.c (ix86_sched_init_global): Add core hooks for generic.
452         * x86-tune-sched.c (ix86_issue_rate): Increase issue rate for generic
453         to 4.
454         (ix86_adjust_cost): Move generic to haswell path.
456 2017-12-04  Eric Botcazou  <ebotcazou@adacore.com>
458         * config/sparc/sparc.c (sparc_do_work_around_errata): Use mem_ref
459         instead of MEM_P in a couple more places.  Fix formatting issues.
461 2017-12-04  Jim Wilson  <jimw@sifive.com>
463         * config/riscv/riscv.c (riscv_for_each_saved_reg): Use GP_REG_LAST
464         instead of GP_REG_LAST-1.
465         (riscv_adjust_libcall_cfi_prologue): Likewise.
466         (riscv_adjust_libcall_cri_epilogue): Likewise.
467         * config/riscv/riscv.h (CALL_USED_REGISTERS): Change a6 to t6 in
468         comment.
470 2017-12-04  Luis Machado  <luis.machado@linaro.org>
472         * ipa-pure-const.c (check_decl): Add missing newline.
473         (state_from_flags): Likewise.
475 2017-12-04  Jeff Law  <law@redhat.com>
477         PR tree-optimizatin/78496
478         * gimple-ssa-evrp-analyze.h
479         (evrp_range_analyzer::get_vr_values): Simplify.
480         * gimple-ssa-evrp-analyze.c: Corresponding changes.
481         * tree-ssa-dom.c: Include alloc-pool.h, tree-vrp.h, vr-values.h
482         and gimple-ssa-evrp-analyze.h.
483         (dom_opt_dom_walker class): Add evrp_range_analyzer member.
484         (simplify_stmt_for_jump_threading): Copy a blob of code from
485         tree-vrp.c to use ranges to simplify statements.
486         (dom_opt_dom_walker::before_dom_children): Call
487         evrp_range_analyzer::{enter,record_ranges_from_stmt} methods.
488         (dom_opt_dom_walker::after_dom_children): Similarly for
489         evrp_range_analyzer::leave.
490         (dom_opt_dom_walker::optimize_stmt): Use EVRP ranges to optimize
491         conditionals.
493         * gimple-ssa-evrp-analyze.c
494         (evrp_range_analyzer::extract_range_from_stmt):  Always use
495         vr_values::update_value_range so preexisting range info is
496         medged with new range info, even if the new range is VR_VARYING.
498 2017-12-04  Segher Boessenkool  <segher@kernel.crashing.org>
500         * combine.c: Adjust comment.
501         (use_crosses_set_p): Delete.
502         (can_combine_p): Use modified_between_p instead of use_crosses_set_p.
503         (try_combine): Ditto.
505 2017-12-04  Richard Biener  <rguenther@suse.de>
507         PR tree-optimization/83255
508         * graphite-isl-ast-to-gimple.c (translate_isl_ast_node_for):
509         Re-add zero-iteration check.
511 2017-12-04  Segher Boessenkool  <segher@kernel.crashing.org>
513         PR rtl-optimization/83245
514         * lra.c (collect_non_operand_hard_regs): Treat clobbers of non-operand
515         hard registers as earlyclobber, also if not in an asm.
517 2017-12-04  Segher Boessenkool  <segher@kernel.crashing.org>
519         PR bootstrap/83265
520         Revert
521         2017-12-01  Segher Boessenkool  <segher@kernel.crashing.org>
523         PR target/43871
524         * config/rs6000/rs6000.c (rs6000_option_override_internal): Set
525         rs6000_cpu based on cpu_index, not tune_index.
527 2017-12-04  Richard Biener  <rguenther@suse.de>
529         PR tree-optimization/83238
530         * graphite-scop-detection.c (scop_detection::merge_sese): Make
531         code match comment, rejecting invalid SESE regions.
533 2017-12-03  John David Anglin  <danglin@gcc.gnu.org>
535         * config/pa/pa.c (pa_legitimate_address_p): For scaled indexing,
536         require base operand is a REG_POINTER prior to reload on targets
537         with non-equivalent space registers.
539 2017-12-01  Jan Hubicka  <hubicka@ucw.cz>
541         * ipa-cp.c (ipcp_lattice<valtype>::print): Update dumping.
542         (update_specialized_profile): Fix updating of counts.
543         (perhaps_add_new_callers): Likewise.
545 2017-12-01  Jan Hubicka  <hubicka@ucw.cz>
547         PR target/81616
548         * x86-tune.def: Remove obsolette FIXMEs.
549         (X86_TUNE_PARTIAL_FLAG_REG_STALL): Disable for generic
550         (X86_TUNE_FUSE_CMP_AND_BRANCH_32, X86_TUNE_FUSE_CMP_AND_BRANCH_64,
551         X86_TUNE_FUSE_CMP_AND_BRANCH_SOFLAGS, X86_TUNE_FUSE_ALU_AND_BRANCH):
552         Enable for generic.
553         (X86_TUNE_PAD_RETURNS): Disable for generic.
555 2017-12-02  Jakub Jelinek  <jakub@redhat.com>
557         PR tree-optimization/83170
558         PR tree-optimization/83241
559         * gimple-ssa-store-merging.c
560         (imm_store_chain_info::try_coalesce_bswap): Update vuse field from
561         gimple_vuse (ins_stmt) in case it has changed.
562         (imm_store_chain_info::output_merged_store): Likewise.
564         * tree-chkp.c (chkp_compute_bounds_for_assignment): Handle
565         POINTER_DIFF_EXPR.
567         PR c++/81212
568         * tree-cfg.c (pass_warn_function_return::execute): Handle
569         __builtin_ubsan_handle_missing_return like __builtin_unreachable
570         with BUILTINS_LOCATION.
572         PR target/78643
573         PR target/80583
574         * expr.c (get_inner_reference): If DECL_MODE of a non-bitfield
575         is BLKmode for vector field with vector raw mode, use TYPE_MODE
576         instead of DECL_MODE.
578         * config/i386/i386-protos.h (standard_sse_constant_opcode): Change
579         last argument to rtx pointer.
580         * config/i386/i386.c (standard_sse_constant_opcode): Replace X argument
581         with OPERANDS.  For AVX+ 128-bit VEX encoded instructions over 256-bit
582         or 512-bit.  If setting EXT_REX_SSE_REG_P, use EVEX encoded insn
583         depending on the chosen ISAs.
584         * config/i386/i386.md (*movxi_internal_avx512f, *movoi_internal_avx,
585         *movti_internal, *movdi_internal, *movsi_internal, *movtf_internal,
586         *movdf_internal, *movsf_internal): Adjust standard_sse_constant_opcode
587         callers.
588         * config/i386/sse.md (mov<mode>_internal): Likewise.
589         * config/i386/mmx.md (*mov<mode>_internal): Likewise.
591 2017-12-01  Segher Boessenkool  <segher@kernel.crashing.org>
593         * doc/invoke.texi (-dp): Say that instruction cost is printed as well.
595 2017-12-01  Segher Boessenkool  <segher@kernel.crashing.org>
597         * config/rs6000/rs6000-protos.h (emit_fusion_addis): Remove last two
598         parameters from prototype.
599         * config/rs6000/rs6000.c (emit_fusion_addis): Remove last two
600         parameters.  Don't print a comment.
601         (emit_fusion_gpr_load): Adjust.
602         (emit_fusion_load_store): Adjust.
603         * config/rs6000/rs6000.md (*fusion_p9_<mode>_constant): Adjust.
604         * config/rs6000/vsx.md (two peepholes): Print the "vector load fusion"
605         comment on the second line.
607 2017-12-01  Segher Boessenkool  <segher@kernel.crashing.org>
609         PR target/43871
610         * config/rs6000/rs6000.c (rs6000_option_override_internal): Set
611         rs6000_cpu based on cpu_index, not tune_index.
613 2017-12-01  Segher Boessenkool  <segher@kernel.crashing.org>
615         * final.c (output_asm_name): Print insn_cost.  Shorten output.  Print
616         which_alternative instead of which_alternative + 1.
617         (output_asm_insn): Print an extra tab if the template is short.
619 2017-12-01  Jim Wilson  <jimw@sifive.com>
621         * common.opt (use_gnu_debug_info_extensions): Delete DWARF_DEBUG from
622         comment.
623         * config/vx-common.h (DWARF_DEBUGGING_INFO): Delete undef.
624         * doc/tm.texi.in (PREFERRED_DEBUGGING_TYPE): Delete DWARF_DEBUG
625         reference.
626         * doc/tm.texi: Regenerate.
628 2017-12-01  Michael Meissner  <meissner@linux.vnet.ibm.com>
630         PR target/81959
631         * config/rs6000/rs6000.c (rs6000_address_for_fpconvert): Check for
632         whether we can allocate pseudos before trying to fix an address.
633         * config/rs6000/rs6000.md (float_<mode>si2_hw): Make sure the
634         memory address is indexed or indirect.
635         (floatuns_<mode>si2_hw2): Likewise.
637 2017-12-01  Jason Merrill  <jason@redhat.com>
639         * Makefile.in (TAGS): Add c-family/*.cc.
641 2017-12-01  Wilco Dijkstra  <wdijkstr@arm.com>
643         * config/aarch64/aarch64.md (call_insn): Use %c rather than %a.
644         (call_value_insn): Likewise.
645         (sibcall_insn): Likewise.
646         (sibcall_value_insn): Likewise.
647         (movsi_aarch64): Likewise.
648         (movdi_aarch64): Likewise.
649         (add_losym_): Likewise.
650         (ldr_got_small_): Likewise.
651         (ldr_got_small_sidi): Likewise.
652         (ldr_got_small_28k_): Likewise.
653         (ldr_got_small_28k_sidi): Likewise.
654         * config/aarch64/aarch64.c (aarch64_print_address_internal):
655         Move output_addr_const to symbolic case. Add error check.
657 2017-12-01  Andreas Krebbel  <krebbel@linux.vnet.ibm.com>
659         * config/s390/predicates.md (plus16_Q_operand): New predicate.
660         * config/s390/s390.md: Disable MVC merging peephole if it would
661         disable operand forwarding.
662         (new peephole2): Split MVCs if it would turn them into up to 2
663         forwardable MVCs.
665 2017-12-01  Richard Biener  <rguenther@suse.de>
667         PR tree-optimization/83232
668         * tree-vect-data-refs.c (vect_analyze_data_ref_accesses): Fix
669         detection of same access. Instead of breaking the group here
670         do not consider the duplicate.  Add comment explaining real fix.
672 2017-12-01  Jonathan Wakely  <jwakely@redhat.com>
674         * doc/md.texi (Insn Splitting): Fix "central flowgraph" typo.
676 2017-12-01  Sudakshina Das  <sudi.das@arm.com>
678         * config/arm/vfp.md (*movhf_vfp_fp16): Add conds attribute.
680 2017-12-01  Jakub Jelinek  <jakub@redhat.com>
682         * function.h (struct function): Remove cilk_frame_decl,
683         is_cilk_function and calls_cilk_spawn fields.
684         * tree-inline.h (struct copy_body_data): Remove remap_var_for_cilk
685         field.
686         * omp-simd-clone.c (simd_clone_clauses_extract): Don't clear
687         cilk_elemental field.
688         * cgraph.h (struct cgraph_simd_clone): Remove cilk_elemental field.
689         * target.def: Adjust comment.
690         * config/i386/i386.c (ix86_simd_clone_compute_vecsize_and_simdlen):
691         Don't test cilk_elemental.
693         PR tree-optimization/83233
694         * gimple-ssa-store-merging.c (nop_stats, bswap_stats): Use
695         bswap_stat name for the struct.
697         PR c/79153
698         * tree.h (SWITCH_BREAK_LABEL_P): Define.
699         * gimplify.c (collect_fallthrough_labels): Handle GIMPLE_BIND
700         starting with a GIMPLE_SWITCH and ending with GIMPLE_LABEL with
701         SWITCH_BREAK_LABEL_P set on the label.
702         (gimplify_switch_expr): Set SWITCH_BREAK_LABEL_P on the label
703         added for default case if it was missing and not all cases covered.
704         Wrap GIMPLE_SWITCH and the switch_body_seq into a GIMPLE_BIND if
705         switch_body_seq ends with a GIMPLE_LABEL with SWITCH_BREAK_LABEL_P
706         set on the label.
707         * tree-chrec.c (evolution_function_is_univariate_p): Add return true;
708         to avoid -Wimplicit-fallthrough warning.
709         * config/i386/i386.c (ix86_expand_special_args_builtin): Add
710         FALLTHRU comment to avoid -Wimplicit-fallthrough warning.
712         PR tree-optimization/83221
713         * tree-ssa-reassoc.c (sort_by_operand_rank): Shift bb_rank
714         down by 16.
715         (init_reassoc): Formatting fix.
717         PR sanitizer/81275
718         * tree-cfg.c (group_case_labels_stmt): Don't optimize away
719         C++ FE implicitly added __builtin_unreachable () until -Wreturn-type
720         is diagnosed.
722         PR sanitizer/83219
723         * tree-cfg.c: Include asan.h.
724         (gimple_seq_unreachable_p): Return false for -fsanitize=unreachable.
726 2017-12-01  Sergey Shalnov  <Sergey.Shalnov@intel.com>
728         * config/i386/i386.md: Fix AVX512 register width in AVX512 instruction.
730 2017-12-01  Sergey Shalnov  <Sergey.Shalnov@intel.com>
732         * config/i386/i386.c (standard_sse_constant_opcode): Fix wrong form for
733         vpcmpeqd instruction.
735 2017-12-01  Sergey Shalnov  <Sergey.Shalnov@intel.com>
737         * config/i386/i386.c (standard_sse_constant_opcode): Fix
738         registers type for 128bit mode.
740 2017-11-30  Jakub Jelinek  <jakub@redhat.com>
742         * spellcheck-tree.c (test_find_closest_identifier): Use ; instead
743         of ;;.
744         * gengtype-state.c (read_state_pair): Likewise.
745         * gimple-fold.c (gimple_fold_builtin_string_compare): Likewise.
746         * sel-sched-dump.c (dump_insn_rtx_1): Likewise.
747         * ipa-cp.c (intersect_aggregates_with_edge): Likewise.
748         * ifcvt.c (noce_try_store_flag_constants): Likewise.
749         * tree-ssa-ccp.c (ccp_finalize): Likewise.
750         * omp-grid.c (grid_process_kernel_body_copy): Likewise.
751         * builtins.c (fold_builtin_3): Likewise.
752         * graphite-scop-detection.c
753         (scop_detection::stmt_has_simple_data_refs_p): Likewise.
754         * hsa-gen.c (hsa_function_representation::hsa_function_representation):
755         Likewise.
757 2017-12-01  Maxim Ostapenko  <m.ostapenko@samsung.com>
759         PR sanitizer/81697
760         * asan.c (asan_protect_global): Add new ignore_decl_rtl_set_p
761         parameter. Return true if ignore_decl_rtl_set_p is true and other
762         conditions are satisfied.
763         * asan.h (asan_protect_global): Add new parameter.
764         * varasm.c (categorize_decl_for_section): Pass true as second parameter
765         to asan_protect_global calls.
767 2017-11-30  Jim Wilson  <jimw@sifive.com>
769         * doc/invoke.texi (RISC-V Options): Delete nonexistent -mmemcpy and
770         -mno-memcpy options.  For -mplt, -mfdiv, -mdiv, -msave-restore, and
771         -mstrict-align, add info on default value.  Delete redundant lines for
772         -mabi.  Add missing -mexplicit-relocs docs.
774 2017-11-30  Claudiu Zissulescu  <claziss@synopsys.com>
776         * config/arc/arc.md (trap): New pattern.
778 2017-11-30  Claudiu Zissulescu  <claziss@synopsys.com>
780         * config/arc/arc.c (hwloop_optimize): Prevent the last ZOL
781         instruction to end into a delay slot.
782         * config/arc/arc.md (cond_delay_insn): Check if the instruction
783         can be placed into a delay slot against reg_note.
785 2017-11-30  Claudiu Zissulescu  <claziss@synopsys.com>
787         * config/arc/arc.c (hwloop_optimize): Update hw-loop's end/start
788         labels number of usages.
790 2017-11-30  Claudiu Zissulescu  <claziss@synopsys.com>
792         * config/arc/arc.c (arc_cannot_substitue_mem_equiv_p): New
793         function.
794         (TARGET_CANNOT_SUBSTITUTE_MEM_EQUIV_P): Define.
796 2017-11-30  Jakub Jelinek  <jakub@redhat.com>
798         PR target/83210
799         * internal-fn.c (expand_mul_overflow): Optimize unsigned
800         multiplication by power of 2 constant into two shifts + comparison.
802 2017-11-30  Jan Hubicka  <hubicka@ucw.cz>
804         PR target/81616
805         * config/i386/x86-tune-costs.h (generic_cost): Revise for modern CPUs.
807 2017-11-30  Richard Biener  <rguenther@suse.de>
809         PR tree-optimization/83202
810         * tree-ssa-loop-ivcanon.c (try_unroll_loop_completely): Add
811         allow_peel argument and guard peeling.
812         (canonicalize_loop_induction_variables): Likewise.
813         (canonicalize_induction_variables): Pass false.
814         (tree_unroll_loops_completely_1): Pass unroll_outer to disallow
815         peeling from cunrolli.
817 2017-11-29  Segher Boessenkool  <segher@kernel.crashing.org>
819         * combine.c (try_combine): Print a message to dump file whenever
820         I0, I1, or I2 cannot be combined into I3.
822 2017-11-29  Segher Boessenkool  <segher@kernel.crashing.org>
824         PR rtl-optimization/83156
825         PR rtl-optimization/82621
826         * combine.c (try_combine): Don't split an I2 if one of the dests is
827         set again before I3.  Allow unused dests.
829 2017-11-29  Segher Boessenkool  <segher@kernel.crashing.org>
831         * config/rs6000/rs6000.md (*add<mode>3_carry_in_internal2): New.
833 2017-11-29  Vladimir Makarov  <vmakarov@redhat.com>
835         PR rtl-optimization/80818
836         * lra.c (collect_non_operand_hard_regs): New arg insn.  Pass it
837         recursively.  Use insn code for clobber.
838         (lra_set_insn_recog_data): Pass the new arg to
839         collect_non_operand_hard_regs.
840         (add_regs_to_insn_regno_info): Pass insn instead of uid.  Use insn
841         code for clobber.
842         (lra_update_insn_regno_info): Pass insn to
843         add_regs_to_insn_regno_info.
845 2017-11-29  Jim Wilson  <jimw@sifive.com>
846             Andrew Waterman  <andrew@sifive.com>
848         * config/riscv/riscv.c (SINGLE_SHIFT_COST): New.
849         (riscv_rtx_costs): Case ZERO_EXTRACT, match new pattern, and return
850         SINGLE_SHIFT_COST.  Case LT and ZERO_EXTEND, likewise.  Case ASHIFT,
851         use SINGLE_SHIFT_COST.
852         * config/riscv/riscv.md (lshrsi3_zero_extend_1): New.
853         (lshrsi3_zero_extend_2, lshrsi3_zero_extend_3): New.
855 2017-11-29  Julia Koval  <julia.koval@intel.com>
857         * config/i386/avx512vbmi2intrin.h (_mm512_shldv_epi16,
858         _mm512_mask_shldv_epi16, _mm512_maskz_shldv_epi16, _mm512_shldv_epi32,
859         _mm512_mask_shldv_epi32, _mm512_maskz_shldv_epi32, _mm512_shldv_epi64,
860         _mm512_mask_shldv_epi64, _mm512_maskz_shldv_epi64): New intrinsics.
861         * config/i386/avx512vbmi2vlintrin.h (_mm256_shldv_epi16,
862         _mm256_mask_shldv_epi16, _mm256_maskz_shldv_epi16, _mm256_shldv_epi32,
863         _mm256_mask_shldv_epi32, _mm256_maskz_shldv_epi32, _mm256_shldv_epi64,
864         _mm256_mask_shldv_epi64, _mm256_maskz_shldv_epi64, _mm_shldv_epi16,
865         _mm_mask_shldv_epi16, _mm_maskz_shldv_epi16, _mm_shldv_epi32,
866         _mm_mask_shldv_epi32, _mm_maskz_shldv_epi32, _mm_shldv_epi64,
867         _mm_mask_shldv_epi64, _mm_maskz_shldv_epi64): Ditto.
868         * config/i386/i386-builtin.def (__builtin_ia32_vpshldv_v32hi,
869         __builtin_ia32_vpshldv_v32hi_mask, __builtin_ia32_vpshldv_v32hi_maskz,
870         __builtin_ia32_vpshldv_v16hi, __builtin_ia32_vpshldv_v16hi_mask,
871         __builtin_ia32_vpshldv_v16hi_maskz, __builtin_ia32_vpshldv_v8hi,
872         __builtin_ia32_vpshldv_v8hi_mask, __builtin_ia32_vpshldv_v8hi_maskz,
873         __builtin_ia32_vpshldv_v16si, __builtin_ia32_vpshldv_v16si_mask,
874         __builtin_ia32_vpshldv_v16si_maskz, __builtin_ia32_vpshldv_v8si,
875         __builtin_ia32_vpshldv_v8si_mask, __builtin_ia32_vpshldv_v8si_maskz,
876         __builtin_ia32_vpshldv_v4si, __builtin_ia32_vpshldv_v4si_mask,
877         __builtin_ia32_vpshldv_v4si_maskz, __builtin_ia32_vpshldv_v8di,
878         __builtin_ia32_vpshldv_v8di_mask, __builtin_ia32_vpshldv_v8di_maskz,
879         __builtin_ia32_vpshldv_v4di, __builtin_ia32_vpshldv_v4di_mask,
880         __builtin_ia32_vpshldv_v4di_maskz, __builtin_ia32_vpshldv_v2di,
881         __builtin_ia32_vpshldv_v2di_mask,
882         __builtin_ia32_vpshldv_v2di_maskz): New builtins.
883         * config/i386/sse.md (vpshldv_<mode>, vpshldv_<mode>_mask,
884         vpshldv_<mode>_maskz, vpshldv_<mode>_maskz_1): New patterns.
886 2017-11-29  Julia Koval  <julia.koval@intel.com>
888         * config/i386/avx512vbmi2intrin.h (_mm512_shrdv_epi16,
889         _mm512_mask_shrdv_epi16, _mm512_maskz_shrdv_epi16, _mm512_shrdv_epi32,
890         _mm512_mask_shrdv_epi32, _mm512_maskz_shrdv_epi32, _mm512_shrdv_epi64,
891         _mm512_mask_shrdv_epi64, _mm512_maskz_shrdv_epi64): New intrinsics.
892         * config/i386/avx512vbmi2vlintrin.h (_mm256_shrdv_epi16,
893         _mm256_mask_shrdv_epi16, _mm256_maskz_shrdv_epi16, _mm256_shrdv_epi32,
894         _mm256_mask_shrdv_epi32, _mm256_maskz_shrdv_epi32, _mm256_shrdv_epi64,
895         _mm256_mask_shrdv_epi64, _mm256_maskz_shrdv_epi64, _mm_shrdv_epi16,
896         _mm_mask_shrdv_epi16, _mm_maskz_shrdv_epi16, _mm_shrdv_epi32,
897         _mm_mask_shrdv_epi32, _mm_maskz_shrdv_epi32, _mm_shrdv_epi64,
898         _mm_mask_shrdv_epi64, _mm_maskz_shrdv_epi64): Ditto.
899         * config/i386/i386-builtin-types.def (V32HI_FTYPE_V32HI_V32HI_V32HI,
900         V32HI_FTYPE_V32HI_V32HI_V32HI_INT, V16HI_FTYPE_V16HI_V16HI_V16HI_INT,
901         V8HI_FTYPE_V8HI_V8HI_V8HI_INT, V8SI_FTYPE_V8SI_V8SI_V8SI_INT,
902         V4SI_FTYPE_V4SI_V4SI_V4SI_INT, V8DI_FTYPE_V8DI_V8DI_V8DI,
903         V8DI_FTYPE_V8DI_V8DI_V8DI_INT, V4DI_FTYPE_V4DI_V4DI_V4DI_INT,
904         V16SI_FTYPE_V16SI_V16SI_V16SI, V16SI_FTYPE_V16SI_V16SI_V16SI_INT,
905         V2DI_FTYPE_V2DI_V2DI_V2DI_INT): New types.
906         * config/i386/i386.c (ix86_expand_args_builtin): Handle new types.
907         * config/i386/sse.md (vpshrdv_<mode>, vpshrdv_<mode>_mask,
908         vpshrdv_<mode>_maskz, vpshrdv_<mode>_maskz_1): New pattern.
910 2017-11-29  Daniel Cederman  <cederman@gaisler.com>
912         * config/sparc/sparc.c (sparc_do_work_around_errata): Treat the
913         movsi_pic_gotdata_op instruction as a load for the UT699 errata
914         workaround.
916 2017-11-29  Martin Aberg  <maberg@gaisler.com>
918         * config/sparc/sparc.md (divdf3_fix): Add NOP and adjust length
919         to prevent b2bst errata sequence.
920         (sqrtdf2_fix): Likewise.
922 2017-11-29  Daniel Cederman  <cederman@gaisler.com>
924         * config/sparc/sparc.c (fpop_reg_depend_p): New function.
925         (div_sqrt_insn_p): New function.
926         (sparc_do_work_around_errata): Insert NOP instructions to
927         prevent sequences that could trigger the TN-0013 errata for
928         certain LEON3 processors.
929         (pass_work_around_errata::gate): Also test sparc_fix_lost_divsqrt.
930         (sparc_option_override): Set sparc_fix_lost_divsqrt appropriately.
931         * config/sparc/sparc.md (fix_lost_divsqrt): New attribute.
932         (in_branch_delay): Prevent div and sqrt in delay slot if
933         fix_lost_divsqrt.
934         * config/sparc/sparc.opt (sparc_fix_lost_divsqrt): New variable.
936 2017-11-29  Daniel Cederman  <cederman@gaisler.com>
938         * config/sparc/sparc.c (atomic_insn_p): New function.
939         (sparc_do_work_around_errata): Insert NOP instructions to
940         prevent sequences that could trigger the TN-0010 errata for
941         UT700.
942         * config/sparc/sync.md (atomic_compare_and_swap_leon3_1): Make
943         instruction referable in atomic_insns_p.
945 2017-11-29  Daniel Cederman  <cederman@gaisler.com>
947         * config/sparc/sync.md (swapsi): 16-byte align if sparc_fix_gr712rc.
948         (atomic_compare_and_swap_leon3_1): Likewise.
949         (ldstub): Likewise.
951 2017-11-29  Daniel Cederman  <cederman@gaisler.com>
953         * config/sparc/sparc.c (fpop_insn_p): New function.
954         (sparc_do_work_around_errata): Insert NOP instructions to
955         prevent sequences that could trigger the TN-0012 errata for
956         GR712RC.
957         (pass_work_around_errata::gate): Also test sparc_fix_gr712rc.
958         * config/sparc/sparc.md (fix_gr712rc): New attribute.
959         (in_branch_annul_delay): Prevent floating-point instructions
960         in delay slot of annulled integer branch.
962 2017-11-29  Richard Biener  <rguenther@suse.de>
964         PR tree-optimization/83202
965         * tree-vect-slp.c (scalar_stmts_set_t): New typedef.
966         (bst_fail): Use it.
967         (vect_analyze_slp_cost_1): Add visited set, do not account SLP
968         nodes vectorized to the same stmts multiple times.
969         (vect_analyze_slp_cost): Allocate a visited set and pass it down.
970         (vect_analyze_slp_instance): Adjust.
971         (scalar_stmts_to_slp_tree_map_t): New typedef.
972         (vect_schedule_slp_instance): Add a map recording the SLP node
973         representing the vectorized stmts for a set of scalar stmts.
974         Avoid code-generating redundancies.
975         (vect_schedule_slp): Allocate map and pass it down.
977 2017-11-29  Nathan Sidwell  <nathan@acm.org>
979         PR c++/83187
980         * tree.c (build_complex_type): Fix canonicalization.  Only fill in
981         type if it is new.
983 2017-11-29  Wilco Dijkstra  <wdijkstr@arm.com>
985         * config/aarch64/aarch64.c (aarch64_print_operand): Add new
986         cases for printing LDP/STP memory addresses.
987         (aarch64_print_address_internal): Renamed from
988         aarch64_print_operand_address, added parameter, add Pmode check.
989         (aarch64_print_ldpstp_address): New function for LDP/STP addresses.
990         (aarch64_print_operand_address): Indirect to
991         aarch64_print_address_internal.
992         * config/aarch64/aarch64-simd.md (store_pair_lanes): Use new
993         'y' operand output specifier.
995 2017-11-29  Jakub Jelinek  <jakub@redhat.com>
997         PR middle-end/83185
998         * tree.c (build_simple_mem_ref_loc): Handle
999         get_addr_base_and_unit_offset returning a MEM_REF.
1001         PR middle-end/80929
1002         * rtlanal.c (seq_cost): For non-single_set insns try to use insn_cost.
1004         PR target/80819
1005         * config/i386/sse.md (vec_concatv2di): Remove * from (=Yr,0,*rm)
1006         alternative.
1008 2017-11-28  David Malcolm  <dmalcolm@redhat.com>
1010         * diagnostic-show-locus.c (layout::print_trailing_fixits): Handle
1011         m_x_offset.
1012         (layout::move_to_column): Likewise.
1014 2017-11-28  Jakub Jelinek  <jakub@redhat.com>
1016         PR sanitizer/81275
1017         * tree.c (block_may_fallthru): Return false if SWITCH_ALL_CASES_P
1018         is set on SWITCH_EXPR and !block_may_fallthru (SWITCH_BODY ()).
1020 2017-11-28  Prathamesh Kulkarni  <prathamesh.kulkarni@linaro.org>
1021             Martin Jambor  <mjambor@suse.cz>
1023         PR ipa/82808
1024         * tree.h (expr_type_first_operand_type_p): Declare
1025         * tree.c (expr_type_first_operand_type_p): New function.
1026         * ipa-prop.h (ipa_get_type): Allow i to be out of bounds.
1027         (ipa_value_from_jfunc): Adjust declaration.
1028         * ipa-cp.c (ipa_get_jf_pass_through_result): New parameter RES_TYPE.
1029         Use it as result type for arithmetics, unless it is NULL in which case
1030         be more conservative.
1031         (ipa_value_from_jfunc): New parameter PARM_TYPE, pass it to
1032         ipa_get_jf_pass_through_result.
1033         (propagate_vals_across_pass_through): Likewise.
1034         (propagate_scalar_across_jump_function): New parameter PARM_TYPE, pass
1035         is to propagate_vals_across_pass_through.
1036         (propagate_constants_across_call): Pass PARM_TYPE to
1037         propagate_scalar_across_jump_function.
1038         (find_more_scalar_values_for_callers_subset): Pass parameter type to
1039         ipa_value_from_jfunc.
1040         (cgraph_edge_brings_all_scalars_for_node): Likewise.
1041         * ipa-fnsummary.c (evaluate_properties_for_edge): Renamed parms_info
1042         to caller_parms_info, pass parameter type to ipa_value_from_jfunc.
1043         * ipa-prop.c (try_make_edge_direct_simple_call): New parameter
1044         target_type, pass it to ipa_value_from_jfunc.
1045         (update_indirect_edges_after_inlining): Pass parameter type to
1046         try_make_edge_direct_simple_call.
1048 2017-11-28  Jeff Law  <law@redhat.com>
1050         * gimple-ssa-evrp-analyze.c
1051         (evrp_range_analyzer::record_ranges_from_phis): Only use SCEV to
1052         refine ranges if scev_initialized_p returns true.
1053         * vr-values.c (vr_values::extract_range_from_phi_node): Likewise.
1055 2017-11-28  Julia Koval  <julia.koval@intel.com>
1057         * config/i386/avx512vbmi2intrin.h (_mm512_shrdi_epi16,
1058         _mm512_mask_shrdi_epi16, _mm512_maskz_shrdi_epi16, _mm512_shrdi_epi32,
1059         _mm512_mask_shrdi_epi32, _mm512_maskz_shrdi_epi32, _mm512_shrdi_epi64,
1060         _mm512_mask_shrdi_epi64, _mm512_maskz_shrdi_epi64): New intrinsics.
1061         * config/i386/avx512vbmi2vlintrin.h (_mm256_shrdi_epi16,
1062         _mm256_mask_shrdi_epi16, _mm256_maskz_shrdi_epi16,
1063         _mm256_mask_shrdi_epi32, _mm256_maskz_shrdi_epi32, _mm256_shrdi_epi32,
1064         _mm256_mask_shrdi_epi64, _mm256_maskz_shrdi_epi64, _mm256_shrdi_epi64,
1065         _mm_mask_shrdi_epi16, _mm_maskz_shrdi_epi16, _mm_shrdi_epi16,
1066         _mm_mask_shrdi_epi32, _mm_maskz_shrdi_epi32, _mm_shrdi_epi32,
1067         _mm_mask_shrdi_epi64, _mm_maskz_shrdi_epi64, _mm_shrdi_epi64): Ditto.
1068         * config/i386/i386-builtin.def (__builtin_ia32_vpshrd_v32hi,
1069         __builtin_ia32_vpshrd_v32hi_mask, __builtin_ia32_vpshrd_v16hi,
1070         __builtin_ia32_vpshrd_v16hi_mask, __builtin_ia32_vpshrd_v8hi,
1071         __builtin_ia32_vpshrd_v8hi_mask, __builtin_ia32_vpshrd_v16si,
1072         __builtin_ia32_vpshrd_v16si_mask, __builtin_ia32_vpshrd_v8si,
1073         __builtin_ia32_vpshrd_v8si_mask, __builtin_ia32_vpshrd_v4si,
1074         __builtin_ia32_vpshrd_v4si_mask, __builtin_ia32_vpshrd_v8di,
1075         __builtin_ia32_vpshrd_v8di_mask, __builtin_ia32_vpshrd_v4di,
1076         __builtin_ia32_vpshrd_v4di_mask, __builtin_ia32_vpshrd_v2di,
1077         __builtin_ia32_vpshrd_v2di_mask): New builtins.
1078         * config/i386/sse.md (vpshrd_<mode><mask_name>): New pattern.
1080 2017-11-28  Julia Koval  <julia.koval@intel.com>
1082         * config/i386/avx512vbmi2intrin.h (_mm512_shldi_epi16,
1083         _mm512_mask_shldi_epi16, _mm512_maskz_shldi_epi16, _mm512_shldi_epi32,
1084         _mm512_mask_shldi_epi32, _mm512_maskz_shldi_epi32, _mm512_shldi_epi64,
1085         _mm512_mask_shldi_epi64, _mm512_maskz_shldi_epi64): New intrinsics.
1086         * config/i386/avx512vbmi2vlintrin.h (_mm256_shldi_epi16,
1087         _mm256_mask_shldi_epi16, _mm256_maskz_shldi_epi16,
1088         _mm256_mask_shldi_epi32, _mm256_maskz_shldi_epi32, _mm256_shldi_epi32,
1089         _mm256_mask_shldi_epi64, _mm256_maskz_shldi_epi64, _mm256_shldi_epi64,
1090         _mm_mask_shldi_epi16, _mm_maskz_shldi_epi16, _mm_shldi_epi16,
1091         _mm_mask_shldi_epi32, _mm_maskz_shldi_epi32, _mm_shldi_epi32,
1092         _mm_mask_shldi_epi64, _mm_maskz_shldi_epi64, _mm_shldi_epi64): Ditto.
1093         * config/i386/i386-builtin-types.def (V32HI_FTYPE_V32HI_V32HI_INT,
1094         V32HI_FTYPE_V32HI_V32HI_INT_V32HI_INT, V16SI_FTYPE_V16SI_V16SI_INT,
1095         V16SI_FTYPE_V16SI_V16SI_INT_V16SI_INT,
1096         V8DI_FTYPE_V8DI_V8DI_INT_V8DI_INT, V8SI_FTYPE_V8SI_V8SI_INT_V8SI_INT,
1097         V16HI_FTYPE_V16HI_V16HI_INT_V16HI_INT,
1098         V4DI_FTYPE_V4DI_V4DI_INT_V4DI_INT,
1099         V8HI_FTYPE_V8HI_V8HI_INT_V8HI_INT,
1100         V4SI_FTYPE_V4SI_V4SI_INT_V4SI_INT,
1101         V2DI_FTYPE_V2DI_V2DI_INT_V2DI_INT): New types.
1102         * config/i386/i386-builtin.def (__builtin_ia32_vpshld_v32hi,
1103         __builtin_ia32_vpshld_v32hi_mask, __builtin_ia32_vpshld_v16hi,
1104         __builtin_ia32_vpshld_v16hi_mask, __builtin_ia32_vpshld_v8hi,
1105         __builtin_ia32_vpshld_v8hi_mask, __builtin_ia32_vpshld_v16si,
1106         __builtin_ia32_vpshld_v16si_mask, __builtin_ia32_vpshld_v8si,
1107         __builtin_ia32_vpshld_v8si_mask, __builtin_ia32_vpshld_v4si,
1108         __builtin_ia32_vpshld_v4si_mask, __builtin_ia32_vpshld_v8di,
1109         __builtin_ia32_vpshld_v8di_mask, __builtin_ia32_vpshld_v4di,
1110         __builtin_ia32_vpshld_v4di_mask, __builtin_ia32_vpshld_v2di,
1111         __builtin_ia32_vpshld_v2di_mask): New builtins.
1112         * config/i386/i386.c (ix86_expand_args_builtin): Handle new types.
1113         * config/i386/sse.md (vpshld_<mode><mask_name>): New pattern.
1115 2017-11-28  Richard Biener  <rguenther@suse.de>
1117         PR tree-optimization/80776
1118         * gimple-ssa-evrp-analyze.h (evrp_range_analyzer::set_ssa_range_info):
1119         Declare.
1120         * gimple-ssa-evrp-analyze.c (evrp_range_analyzer::set_ssa_range_info):
1121         New function.
1122         (evrp_range_analyzer::record_ranges_from_incoming_edges):
1123         If the incoming edge is an effective fallthru because the other
1124         edge only reaches a __builtin_unreachable () then record ranges
1125         derived from the controlling condition in SSA info.
1126         (evrp_range_analyzer::record_ranges_from_phis): Use set_ssa_range_info.
1127         (evrp_range_analyzer::record_ranges_from_stmt): Likewise.
1129 2017-11-28  Olivier Hainque  <hainque@adacore.com>
1131         * Makefile.in (SELFTEST_FLAGS): Use nul instead of /dev/null
1132         on mingw build hosts.
1134 2017-11-28  Jakub Jelinek  <jakub@redhat.com>
1136         PR debug/81307
1137         * dbxout.c (dbx_block_with_cold_children): Fix function comment.
1139 2017-11-28  Richard Biener  <rguenther@suse.de>
1141         PR middle-end/83141
1142         * gimple-fold.c (gimple_fold_builtin_memory_op): For aggregate
1143         copies generated from memcpy use a character array as reference
1144         type.
1146 2017-11-28  Julia Koval  <julia.koval@intel.com>
1147             Sebastian Peryt  <sebastian.peryt@intel.com>
1149         * Makefile.in (cilkplus.def, cilk-builtins.def, c-family/cilk.o, 
1150         c-family/c-cilkplus.o, c-family/array-notation-common.o,
1151         cilk-common.o, cilk.h, cilk-common.c): Remove.
1152         * builtin-types.def
1153         (BT_FN_INT_PTR_PTR_PTR_FTYPE_BT_INT_BT_PTR_BT_PTR_BT_PTR): Remove.
1154         * builtins.c (is_builtin_name): Remove cilkplus condition.
1155         (BUILT_IN_CILK_DETACH, BUILT_IN_CILK_POP_FRAME): Remove.
1156         * builtins.def (DEF_CILK_BUILTIN_STUB, DEF_CILKPLUS_BUILTIN,
1157         cilk-builtins.def, cilkplus.def): Remove.
1158         * cif-code.def (CILK_SPAWN): Remove.
1159         * cilk-builtins.def: Delete.
1160         * cilk-common.c: Ditto.
1161         * cilk.h: Ditto.
1162         * cilkplus.def: Ditto.
1163         * config/darwin.h (fcilkplus): Delete.
1164         * cppbuiltin.c: Ditto.
1165         * doc/extend.texi: Remove cilkplus doc.
1166         * doc/generic.texi: Ditto.
1167         * doc/invoke.texi: Ditto.
1168         * doc/passes.texi: Ditto.
1169         * gcc.c (fcilkplus): Remove.
1170         * gengtype.c (cilk.h): Remove.
1171         * gimple-pretty-print.c (dump_gimple_omp_for): Remove cilkplus
1172         support.
1173         * gimple.h (GF_OMP_FOR_KIND_CILKFOR, GF_OMP_FOR_KIND_CILKSIMD):
1174         Remove.
1175         * gimplify.c (gimplify_return_expr, maybe_fold_stmt,
1176         gimplify_call_expr,
1177         is_gimple_stmt, gimplify_modify_expr, gimplify_scan_omp_clauses,
1178         gimplify_adjust_omp_clauses, gimplify_omp_for, gimplify_expr): Remove
1179         cilkplus conditions.
1180         * ipa-fnsummary.c (ipa_dump_fn_summary, compute_fn_summary,
1181         inline_read_section): Ditto.
1182         * ipa-inline-analysis.c (cilk.h): Remove.
1183         * ira.c (ira_setup_eliminable_regset): Remove cilkplus support.
1184         * lto-wrapper.c (merge_and_complain, append_compiler_options,
1185         append_linker_options): Remove condition for fcilkplus.
1186         * lto/lto-lang.c (cilk.h): Remove.
1187         (lto_init): Remove condition for fcilkplus.
1188         * omp-expand.c (expand_cilk_for_call): Delete.
1189         (expand_omp_taskreg, expand_omp_for_static_chunk,
1190         expand_omp_for): Remove cilkplus
1191         conditions.
1192         (expand_cilk_for): Delete.
1193         * omp-general.c (omp_extract_for_data): Remove cilkplus support.
1194         * omp-low.c (scan_sharing_clauses, create_omp_child_function,
1195         execute_lower_omp, diagnose_sb_0): Ditto.
1196         * omp-simd-clone.c (simd_clone_clauses_extract): Ditto.
1197         * tree-core.h (OMP_CLAUSE__CILK_FOR_COUNT_): Delete.
1198         * tree-nested.c: Ditto.
1199         * tree-pretty-print.c (dump_omp_clause): Remove cilkplus support.
1200         (dump_generic_node): Ditto.
1201         * tree.c (OMP_CLAUSE__CILK_FOR_COUNT_): Delete.
1202         * tree.def (cilk_simd, cilk_for, cilk_spawn_stmt, cilk_sync_stmt):
1203         Delete.
1204         * tree.h (CILK_SPAWN_FN, EXPR_CILK_SPAWN): Delete.
1206 2017-11-28  Ramana Radhakrishnan  <ramana.radhakrishnan@arm.com>
1208         * config/aarch64/aarch64.md (div<mode>3): Change check to TARGET_FLOAT.
1209         * config/aarch64/aarch64.c (aarch64_emit_approx_div): Add early exit
1210         for vector mode and !TARGET_SIMD.
1212 2017-11-28  Jakub Jelinek  <jakub@redhat.com>
1214         * tree.def (SWITCH_EXPR): Change from 3 operand to 2 operand tree.
1215         Adjust comment.
1216         * tree.h (SWITCH_LABELS): Remove.
1217         * gimplify.c (gimplify_switch_expr): Don't test SWITCH_LABELS,
1218         assert SWITCH_BODY is non-NULL.
1219         * tree-pretty-print.c (dump_generic_node): Remove SWITCH_LABELS
1220         handling.
1221         * tree.c (block_may_fallthru): Always return true; for SWITCH_EXPR.
1223         PR tree-optimization/80788
1224         * match.pd (X +- C1 CMP C2 -> X CMP C2 -+ C1): If res
1225         has TREE_OVERFLOW set, call drop_tree_overflow.
1227 2017-11-28  Richard Biener  <rguenther@suse.de>
1229         PR tree-optimization/83158
1230         * tree-vrp.c (intersect_ranges): Prefer ~[0, 0] in a few more
1231         cases.
1233 2017-11-28  Segher Boessenkool  <segher@kernel.crashing.org>
1235         PR 81288/target
1236         * config/rs6000/rs6000.c (rs6000_rtx_costs): Do not handle
1237         TARGET_ISEL && !TARGET_MFCRF differently.  Simplify code.
1239 2017-11-27  Segher Boessenkool  <segher@kernel.crashing.org>
1241         * config/rs6000/rs6000.md (<code><GPR:mode><GPR2:mode>2_isel): Change
1242         LT/GT/LTU/GTU to LE/GE/LEU/GEU where possible.
1244 2017-11-27  Michael Meissner  <meissner@linux.vnet.ibm.com>
1246         PR middle_end/82333
1247         * varasm.c (compare_constant): Take the mode of the constants into
1248         account when comparing floating point constants.
1250 2017-11-27  Gerald Pfeifer  <gerald@pfeifer.com>
1252         * hash-set.h (DEFINE_DEBUG_HASH_SET): Remove static qualifier
1253         from explicit instantiation of debug_helper.
1254         * vec.h (DEFINE_DEBUG_VEC): Ditto.
1256 2017-11-27  Richard Biener  <rguenther@suse.de>
1258         * gimple-fold.c (gimple_fold_builtin_memory_op): Remove dead code,
1259         refactor a bit.
1261 2017-11-27  Richard Biener  <rguenther@suse.de>
1263         * tree.c (wide_int_to_tree): Free discarded INTEGER_CST.
1264         (type_hash_canon): Also clear int_cst_hash_table entry for
1265         TYPE_MIN/MAX_VALUE.
1266         (build_nonstandard_integer_type): Hash all TYPE_MAX_VALUEs.
1268 2017-11-27  Tamar Christina  <tamar.christina@arm.com>
1270         * doc/extend.texi: Add -A suffix (ARMv8*-A, ARMv7-A).
1271         * doc/invoke.texi: Add -A suffix (ARMv8*-A, ARMv7-A).
1272         * doc/sourcebuild.texi: Add -A suffix (ARMv8*-A, ARMv7-A).
1274 2017-11-27  Markus Trippelsdorf  <markus@trippelsdorf.de>
1276         * hash-map.h (gt_cleare_cache): Avoid UB.
1278 2017-11-27  Eric Botcazou  <ebotcazou@adacore.com>
1280         * cfgloop.h (struct loop): Document usage of USHRT_MAX for unroll.
1281         * loop-unroll.c (decide_unroll_constant_iterations): Implement it.
1282         (decide_unroll_runtime_iterations): Likewise.
1283         (decide_unroll_stupid): Likewise.
1285 2017-11-27  Igor Tsimbalist  <igor.v.tsimbalist@intel.com>
1287         PR target/83109
1288         * config/i386/i386.md: Add a loop with incssp.
1290 2017-11-27  Martin Jambor  <mjambor@suse.cz>
1292         PR tree-optimization/81248
1293         * tree-sra.c (splice_param_accesses): Remove size check.
1294         (decide_one_param_reduction): Fix size check.
1295         * gimple-pretty-print.c (dump_profile): Silence warning.
1296         * params.def (PARAM_IPA_SRA_PTR_GROWTH_FACTOR): Adjust description.
1298 2017-11-27  Jakub Jelinek  <jakub@redhat.com>
1300         PR debug/81307
1301         * dbxout.c (lastlineno): New variable.
1302         (dbx_debug_hooks): Use dbxout_switch_text_section as
1303         switch_text_section debug hook.
1304         (dbxout_function_end): Switch to current_function_section
1305         rather than function_section.  If crtl->has_bb_partition,
1306         output just one N_FUN, depending on in_cold_section_p.
1307         (dbxout_source_line): Remember last lineno in lastlineno.
1308         (dbxout_switch_text_section): New function.
1309         (dbxout_function_decl): Adjust dbxout_block caller.
1310         (dbx_block_with_cold_children): New function.
1311         (dbxout_block): Return true if any LBRAC/RBRAC have been
1312         emitted.  Use dbx_block_with_cold_children at depth == 0
1313         in second partition.  Add PARENT_BLOCKNUM argument, pass
1314         it optionally adjusted to children.  Output LBRAC/RBRAC
1315         around recursive call only if the block is in the current
1316         partition, if not and anything was output, emit empty
1317         range LBRAC/RBRAC.
1318         * final.c (final_scan_insn): Compute cold_function_name
1319         before calling switch_text_section debug hook.  Call
1320         that hook even if dwarf2out_do_frame if not emitting
1321         dwarf debug info.
1323         PR target/83100
1324         * varasm.c (bss_initializer_p): Return true for DECL_COMMON
1325         TREE_READONLY decls.
1327 2017-11-27  Markus Trippelsdorf  <markus@trippelsdorf.de>
1329         PR rtl-optimization/82488
1330         * expr.c (fixup_args_size_notes): Avoid signed integer overflow.
1332 2017-11-26  Julia Koval  <julia.koval@intel.com>
1334         * config/i386/i386.c (processor_target_table): Add skylake_cost for
1335         skylake-avx512.
1336         * config/i386/x86-tune-costs.h (skylake_memcpy, skylake_memset,
1337         skylake_cost): New.
1339 2017-11-26  Julia Koval  <julia.koval@intel.com>
1341         * config/i386/driver-i386.c (host_detect_local_cpu):
1342         Detect skylake-avx512.
1344 2017-11-26  Julia Koval  <julia.koval@intel.com>
1346         * config.gcc: Add -march=cannonlake.
1347         * config/i386/driver-i386.c (host_detect_local_cpu): Detect cannonlake.
1348         * config/i386/i386-c.c (ix86_target_macros_internal): Handle cannonlake.
1349         * config/i386/i386.c (processor_costs): Add m_CANNONLAKE.
1350         (PTA_CANNONLAKE): New.
1351         (processor_target_table): Add cannonlake.
1352         (ix86_option_override_internal): Ditto.
1353         (fold_builtin_cpu): Ditto.
1354         (get_builtin_code_for_version): Handle cannonlake.
1355         (M_INTEL_COREI7_CANNONLAKE): New.
1356         * config/i386/i386.h (TARGET_CANNONLAKE, PROCESSOR_CANNONLAKE): New.
1357         * doc/invoke.texi: Add -march=cannonlake.
1359 2017-11-14  Boris Kolpackov  <boris@codesynthesis.com>
1361         * plugin.c (add_new_plugin): Use platform-specific library extensions.
1362         (try_init_one_plugin): Alternative implementation for MinGW.
1363         * Makefile.in (plugin_implib): New.
1364         (gengtype-lex.c): Fix broken AIX workaround.
1365         * configure: Regenerate.
1366         * doc/plugins.texi: Document support for MinGW.
1368 2017-11-25  Jakub Jelinek  <jakub@redhat.com>
1370         PR rtl-optimization/81553
1371         * combine.c (simplify_if_then_else): In (if_then_else COND (OP Z C1) Z)
1372         to (OP Z (mult COND (C1 * STORE_FLAG_VALUE))) optimization, if OP
1373         is a shift where C1 has different mode than the whole shift, use C1's
1374         mode for MULT rather than the shift's mode.
1376         PR target/82848
1377         * config/rs6000/rs6000.c (rs6000_gimple_fold_builtin): Don't fold
1378         builtins not enabled in the currently selected ISA.
1380 2017-11-24  Jackson Woodruff  <jackson.woodruff@arm.com>
1382         PR tree-optimization/71026
1383         * tree-ssa-math-opts (is_division_by_square, is_square_of): New.
1384         (insert_reciprocals): Change to insert reciprocals before a division
1385         by a square and to insert the square of a reciprocal.
1386         (execute_cse_reciprocals_1): Change to consider division by a square.
1387         (register_division_in): Add importance parameter.
1389 2017-11-24  Richard Biener  <rguenther@suse.de>
1391         PR tree-optimization/82402
1392         * tree-vect-loop-manip.c (create_lcssa_for_virtual_phi): Properly
1393         set SSA_NAME_OCCURS_IN_ABNORMAL_PHI.
1395 2017-11-24  Marc Glisse  <marc.glisse@inria.fr>
1397         * match.pd (0-ptr): New transformation.
1399 2017-11-24  Jan Hubicka  <hubicka@ucw.cz>
1401         PR bootstrap/83015
1402         * ipa-inline.c (inline_small_functions): Set current badnes correctly
1403         when skipping checking.
1405 2017-11-24  Richard Biener  <rguenther@suse.de>
1407         PR tree-optimization/83128
1408         * tree-ssa-sccvn.c (fully_constant_vn_reference_p): Handle STRING_CSTs.
1409         (vn_reference_lookup_3): Likewise.
1411 2017-11-24  Jakub Jelinek  <jakub@redhat.com>
1413         PR sanitizer/83014
1414         * ubsan.c (ubsan_type_descriptor): Use pp_unsigned_wide_integer
1415         instead of pp_printf with HOST_WIDE_INT_PRINT_DEC.  Avoid calling
1416         tree_to_uhwi twice.
1418         * tree-object-size.c (pass_through_call): Use gimple_call_return_flags
1419         ERF_RETURN*ARG* for builtins other than BUILT_IN_ASSUME_ALIGNED,
1420         check for the latter with gimple_call_builtin_p.  Do not handle
1421         BUILT_IN_STPNCPY_CHK which is not a pass through call.
1423 2017-11-24  Christophe Lyon  <christophe.lyon@linaro.org>
1425         * config/arm/arm_neon.h: Fix pragma GCC push_options before
1426         vdot_u32.
1428 2017-11-23  Julia Koval  <julia.koval@intel.com>
1430         * config/i386/avx512vbmi2intrin.h (_mm512_mask_expand_epi8,
1431         _mm512_maskz_expand_epi8, _mm512_mask_expandloadu_epi8,
1432         _mm512_maskz_expandloadu_epi8, _mm512_mask_expand_epi16,
1433         _mm512_maskz_expand_epi16, _mm512_mask_expandloadu_epi16,
1434         _mm512_maskz_expandloadu_epi16): New intrinsics.
1435         * config/i386/avx512vbmi2vlintrin.h (_mm_mask_expand_epi8,
1436         _mm_maskz_expand_epi8, _mm_mask_expandloadu_epi8,
1437         _mm_maskz_expandloadu_epi8, _mm_mask_expand_epi16,
1438         _mm_maskz_expand_epi16, _mm_mask_expandloadu_epi16,
1439         _mm_maskz_expandloadu_epi16, _mm256_mask_expand_epi16,
1440         _mm256_maskz_expand_epi16, _mm256_mask_expandloadu_epi16,
1441         _mm256_maskz_expandloadu_epi16, _mm256_mask_expand_epi8,
1442         _mm256_maskz_expand_epi8, _mm256_mask_expandloadu_epi8,
1443         _mm256_maskz_expandloadu_epi8): New intrinsics.
1444         * config/i386/i386-builtin-types.def (V64QI_FTYPE_PCV64QI_V64QI_UDI,
1445         V32HI_FTYPE_PCV32HI_V32HI_USI, V32QI_FTYPE_PCV32QI_V32QI_USI,
1446         V16HI_FTYPE_PCV16HI_V16HI_UHI, V16QI_FTYPE_PCV16QI_V16QI_UHI,
1447         V8HI_FTYPE_PCV8HI_V8HI_UQI): New types.
1448         * config/i386/i386.c (ix86_expand_special_args_builtin): Use new types.
1449         * config/i386/sse.md (VI248_VLBW): New iterator.
1450         (expand<mode>_mask, expand<mode>_maskz): New patterns.
1452 2017-11-23  Julia Koval  <julia.koval@intel.com>
1454         * config.gcc (avx512vbmi2intrin.h, avx512vbmi2vlintrin): New headers.
1455         * config/i386/avx512vbmi2intrin.h (_mm512_mask_compress_epi8,
1456         _mm512_maskz_compress_epi8, _mm512_mask_compressstoreu_epi8,
1457         _mm512_mask_compress_epi16, _mm512_maskz_compress_epi16,
1458         _mm512_mask_compressstoreu_epi16): New.
1459         * config/i386/avx512vbmi2vlintrin.h (_mm_mask_compress_epi8,
1460         _mm_maskz_compress_epi8, _mm256_mask_compressstoreu_epi16,
1461         _mm_mask_compress_epi16, _mm_maskz_compress_epi16,
1462         _mm256_mask_compress_epi16, _mm256_maskz_compress_epi16,
1463         _mm_mask_compressstoreu_epi8, _mm_mask_compressstoreu_epi16,
1464         _mm256_mask_compress_epi8, _mm256_maskz_compress_epi8,
1465         _mm256_mask_compressstoreu_epi8): New.
1466         * config/i386/i386-builtin-types.def (VOID_FTYPE_PV64QI_V64QI_UDI,
1467         VOID_FTYPE_PV32HI_V32HI_USI, VOID_FTYPE_PV32QI_V32QI_USI,
1468         VOID_FTYPE_PV16QI_V16QI_UHI, VOID_FTYPE_PV16HI_V16HI_UHI,
1469         VOID_FTYPE_PV8HI_V8HI_UQI): New types.
1470         * config/i386/i386-builtin.def (__builtin_ia32_compressqi512_mask,
1471         __builtin_ia32_compresshi512_mask, __builtin_ia32_compressqi256_mask,
1472         __builtin_ia32_compressqi128_mask, __builtin_ia32_compresshi256_mask,
1473         __builtin_ia32_compresshi128_mask,
1474         __builtin_ia32_compressstoreuqi512_mask,
1475         __builtin_ia32_compressstoreuhi512_mask,
1476         __builtin_ia32_compressstoreuqi256_mask,
1477         __builtin_ia32_compressstoreuqi128_mask,
1478         __builtin_ia32_compressstoreuhi256_mask,
1479         __builtin_ia32_compressstoreuhi128_mask): New builtins.
1480         * config/i386/i386.c (ix86_init_mmx_sse_builtins): Create special args
1481         array for flags2.
1482         (ix86_expand_special_args_builtin): Handle new types.
1483         (s4fma_expand): Handle new builtin array.
1484         * config/i386/immintrin.h: Include new headers.
1485         * config/i386/sse.md (VI12_AVX512VLBW): New iterator.
1486         (compress<mode>_mask, compressstore<mode>_mask): New patterns.
1488 2017-11-23  Jakub Jelinek  <jakub@redhat.com>
1490         * config/rs6000/rs6000.c (rs6000_gimple_fold_builtin): Formatting
1491         fixes.  Declare temp and g variables at the top in order to avoid
1492         {} in most of the cases.
1494 2017-11-23  Marc Glisse  <marc.glisse@inria.fr>
1496         * match.pd (ptr-0): New transformation.
1498 2017-11-23  Charles Baylis  <charles.baylis@linaro.org>
1500         * config/arm/arm-protos.h (enum arm_addr_mode_op): New.
1501         (struct addr_mode_cost_table): New.
1502         (struct tune_params): Add field addr_mode_costs.
1503         * config/arm/arm.c (generic_addr_mode_costs): New.
1504         (arm_slowmul_tune): Initialise addr_mode_costs field.
1505         (arm_fastmul_tune): Likewise.
1506         (arm_strongarm_tune): Likewise.
1507         (arm_xscale_tune): Likewise.
1508         (arm_9e_tune): Likewise.
1509         (arm_marvell_pj4_tune): Likewise.
1510         (arm_v6t2_tune): Likewise.
1511         (arm_cortex_tune): Likewise.
1512         (arm_cortex_a8_tune): Likewise.
1513         (arm_cortex_a7_tune): Likewise.
1514         (arm_cortex_a15_tune): Likewise.
1515         (arm_cortex_a35_tune): Likewise.
1516         (arm_cortex_a53_tune): Likewise.
1517         (arm_cortex_a57_tune): Likewise.
1518         (arm_exynosm1_tune): Likewise.
1519         (arm_xgene1_tune): Likewise.
1520         (arm_cortex_a5_tune): Likewise.
1521         (arm_cortex_a9_tune): Likewise.
1522         (arm_cortex_a12_tune): Likewise.
1523         (arm_cortex_a73_tune): Likewise.
1524         (arm_v7m_tune): Likewise.
1525         (arm_cortex_m7_tune): Likewise.
1526         (arm_v6m_tune): Likewise.
1527         (arm_fa726te_tune): Likewise.
1528         (arm_mem_costs): Use table lookup to calculate cost of addressing
1529         mode.
1531 2017-11-23  Charles Baylis  <charles.baylis@linaro.org>
1533         * config/arm/arm.c (arm_mem_costs): New function.
1534         (arm_rtx_costs_internal): Use arm_mem_costs.
1536 2017-11-23  Mark Wielaard  <mark@klomp.org>
1538         * dwarf2out.c (init_sections_and_labels): Use generation to create
1539         unique ranges_section_label and ranges_base_label. Return generation.
1540         (output_rnglists): Add generation argument. Use generation to create
1541         unique ranges labels.
1542         (dwarf2out_finish): Get generation from init_sections_and_labels
1543         and pass generation to output_rnglists.
1545 2017-11-23  Mike Stump  <mikestump@comcast.net>
1546             Eric Botcazou  <ebotcazou@adacore.com>
1548         * doc/generic.texi (ANNOTATE_EXPR): Document 3rd operand.
1549         * cfgloop.h (struct loop): Add unroll field.
1550         * function.h (struct function): Add has_unroll bitfield.
1551         * gimplify.c (gimple_boolify) <ANNOTATE_EXPR>: Deal with unroll kind.
1552         (gimplify_expr) <ANNOTATE_EXPR>: Propagate 3rd operand.
1553         * loop-init.c (pass_loop2::gate): Return true if cfun->has_unroll.
1554         (pass_rtl_unroll_loops::gate): Likewise.
1555         * loop-unroll.c (decide_unrolling): Tweak note message.  Skip loops
1556         for which loop->unroll==1.
1557         (decide_unroll_constant_iterations): Use note for consistency and
1558         take loop->unroll into account.  Return early if loop->unroll is set.
1559         Fix thinko in existing test.
1560         (decide_unroll_runtime_iterations): Use note for consistency and
1561         take loop->unroll into account.
1562         (decide_unroll_stupid): Likewise.
1563         * lto-streamer-in.c (input_cfg): Read loop->unroll.
1564         * lto-streamer-out.c (output_cfg): Write loop->unroll.
1565         * tree-cfg.c (replace_loop_annotate_in_block) <annot_expr_unroll_kind>:
1566         New case.
1567         (replace_loop_annotate) <annot_expr_unroll_kind>: Likewise.
1568         (print_loop): Print loop->unroll if set.
1569         * tree-core.h (enum annot_expr_kind): Add annot_expr_unroll_kind.
1570         * tree-inline.c (copy_loops): Copy unroll and set cfun->has_unroll.
1571         * tree-pretty-print.c (dump_generic_node) <annot_expr_unroll_kind>:
1572         New case.
1573         * tree-ssa-loop-ivcanon.c (try_unroll_loop_completely): Bail out if
1574         loop->unroll is set and smaller than the trip count.  Otherwise bypass
1575         entirely the heuristics if loop->unroll is set.  Remove dead note.
1576         Fix off-by-one bug in other note.
1577         (try_peel_loop): Bail out if loop->unroll is set.  Fix formatting.
1578         (tree_unroll_loops_completely_1): Force unrolling if loop->unroll
1579         is greater than 1.
1580         (tree_unroll_loops_completely): Make static.
1581         (pass_complete_unroll::execute): Use correct type for variable.
1582         (pass_complete_unrolli::execute): Fix formatting.
1583         * tree.def (ANNOTATE_EXPR): Add 3rd operand.
1585 2017-11-23  Sergey Shalnov  <Sergey.Shalnov@intel.com>
1587         * config/i386/i386.h (TARGET_PREFER_AVX256): Also
1588         enable when TARGET_PREFER_AVX128 is set.
1590 2017-11-23  Jan Hubicka  <hubicka@ucw.cz>
1592         * ipa-profile.c (ipa_propagate_frequency_1): Use count instead of
1593         frequency.
1594         * cgraph.c (cgraph_edge::dump_edge_flags): Dump sreal frequencies.
1595         (cgraph_edge::maybe_hot_p): Use sreal frequencies.
1597 2017-11-23  Jan Hubicka  <hubicka@ucw.cz>
1599         * ipa-fnsummary.c (record_modified_bb_info): Use sreal
1600         frequencies. Fix estimation of aggregate parameters.
1602 2017-11-23  Jan Hubicka  <hubicka@ucw.cz>
1604         * cgraphclones.c (cgraph_node::create_clone): Fix updating of profile
1605         when inlining.
1607 2017-11-23  Tom de Vries  <tom@codesourcery.com>
1609         * config/sh/sh.h (ASM_OUTPUT_ADDR_VEC_ELT): Wrap in "do {} while (0)".
1611 2017-11-23  Tom de Vries  <tom@codesourcery.com>
1613         * config/ft32/ft32.h (ASM_OUTPUT_ADDR_VEC_ELT): Remove semicolon after
1614         macro.
1616 2017-11-23  Oleg Endo  <olegendo@gcc.gnu.org>
1618         PR target/83111
1619         * config/sh/sh.md (udivsi3, divsi3, sibcall_value_pcrel,
1620         sibcall_value_pcrel_fdpic): Use local variable instead of
1621         operands[3].
1622         (calli_tbr_rel): Add missing operand 2.
1623         (call_valuei_tbr_rel): Add missing operand 3.
1625 2017-11-23  Jakub Jelinek  <jakub@redhat.com>
1627         PR middle-end/82253
1628         * expr.c (expand_assignment): For CONCAT to_rtx, complex type from and
1629         bitpos/bitsize covering the whole destination, use store_expr only if
1630         the complex mode is the same.  Otherwise, use expand_normal and if
1631         it returns CONCAT, subreg each part separately instead of trying to
1632         subreg the whole result.
1634 2017-11-23  Richard Biener  <rguenther@suse.de>
1636         PR tree-optimization/23094
1637         * tree-ssa-sccvn.c (vuse_ssa_val): Handle VN_TOP when we
1638         come here from walking over backedges in the first iteration.
1639         (vn_reference_lookup_3): Skip clobbers that store the same value.
1641 2017-11-23  Richard Biener  <rguenther@suse.de>
1643         PR tree-optimization/81403
1644         * tree-ssa-pre.c (get_representative_for): Add parameter specifying
1645         a block we need a leader relative to.
1646         (phi_translate_1): For nary processing require a leader from
1647         get_representative_for given we run expression simplification
1648         using match-and-simplify.  Remove previous fix.
1650 2017-11-22  Jeff Law  <law@redhat.com>
1652         * gimple-ssa-evrp-analyze.c (evrp_range_analyzer::try_find_new_range):
1653         Use new method allocate_value_range rather than accessing the
1654         vrp_value_range_pool data member directly.
1655         * tree-vrp.c (simplify_stmt_for_jump_threading): Tweak slightly
1656         to use extract_range_from_stmt method to avoid need for
1657         extract_range_from_assignment method.
1658         (vrp_prop::vrp_finalize): Use set_lattice_propagation_complete
1659         method rather than setting values_propgated data member directly.
1660         * vr-values.h (class vr_values): Privatize vrp_value_range_pool,
1661         and values propagated data members and extract_range_from_assignment
1662         method.  Reorder private data members to conform to standards.
1663         Add new methods set_lattice_propagation_complete and
1664         allocate_value_range.
1666 2017-11-22  Eric Botcazou  <ebotcazou@adacore.com>
1668         PR rtl-optimization/83030
1669         * doc/rtl.texi (Flags in an RTL Expression): Alphabetize, add entry
1670         for CROSSING_JUMP_P and mention usage of 'jump' for JUMP_INSNs.
1671         (Insns): Delete entry for REG_CROSSING_JUMP in register notes.
1672         * bb-reorder.c (update_crossing_jump_flags): Do not test whether the
1673         CROSSING_JUMP_P flag is already set before setting it.
1674         * cfgrtl.c (fixup_partition_crossing): Likewise.
1675         * reorg.c (relax_delay_slots): Do not consider a CROSSING_JUMP_P
1676         insn as useless.
1678 2017-11-22  Jakub Jelinek  <jakub@redhat.com>
1680         * simplify-rtx.c (simplify_binary_operation_1) <case VEC_SERIES>:
1681         Handle the case where both arguments are using gen_const_vec_series.
1683 2017-11-22  David Malcolm  <dmalcolm@redhat.com>
1685         PR c++/62170
1686         * pretty-print.c (pp_format): Move quoting implementation to
1687         pp_begin_quote and pp_end_quote.  Update pp_format_decoder call
1688         to pass address of "quote" local.
1689         (pp_begin_quote): New function.
1690         (pp_end_quote): New function.
1691         * pretty-print.h (printer_fn): Convert penultimate param from bool
1692         to bool *.
1693         (pp_begin_quote): New decl.
1694         (pp_end_quote): New decl.
1695         * tree-diagnostic.c (default_tree_printer): Convert penultimate
1696         param from bool to bool *.
1697         * tree-diagnostic.h (default_tree_printer): Likewise.
1699 2017-11-22  Jeff Law  <law@redhat.com>
1701         * gimple-ssa-evrp-analyze.c (evrp_range_analyzer::evrp_range_analyzer)
1702         Initialize vr_values.
1703         (evrp_range_analyzer::try_find_new_range): Call methods attached to
1704         vr_values via vr_values class instance rather than delegators.
1705         (evrp_range_analyzer::record_ranges_from_phis): Likewise.
1706         (evrp_range_analyzer::record_ranges_from_stmt): Likewise.
1707         (evrp_range_analyzer::push_value_range): Likewise.
1708         (evrp_range_analyzer::pop_value_range): Likewise.
1709         * gimple-ssa-evrp-analyze.h (class evrp_range_analyzer): Remove
1710         most delegators.  Those remaining are exposed as public interfaces.
1711         Make vr_values a pointer and private.
1712         (evrp_range_analyzer::~evrp_range_analyzer): Delete the attached
1713         vr_values.
1714         (evrp_range_analyzer::get_vr_value): New method.
1715         * gimple-ssa-evrp.c (class evrp_folder): Use DISABLE_COPY_AND_ASSIGN.
1716         (evrp_folder::evrp_folder): New ctor to initialize vr_values.
1717         (class evrp_dom_walker): Attach evrp_folder class, initialize
1718         it in the ctor.  Remove temporary delegators.
1719         (evrp_dom_walker::before_dom_children): Call methods in attached
1720         evrp_range_analyzer class via class instance pointer.  Use
1721         free value_range_constant_singleton to remove need for
1722         op_with_constant_singleton_value delegator method.  Do not
1723         create a vrp_prop class instance for every call!  Narrow
1724         scope of a couple variables.
1725         (evrp_dom_walker::cleanup): Call methods in attached
1726         evrp_range_analyzer class via class instance pointer.
1727         * vr-values.h (class vr_values): Privatize many methods and
1728         data members.
1730 2017-11-22  Richard Sandiford  <richard.sandiford@linaro.org>
1732         * tree.def (REDUC_MAX_EXPR, REDUC_MIN_EXPR, REDUC_PLUS_EXPR): Delete.
1733         * cfgexpand.c (expand_debug_expr): Remove handling for them.
1734         * expr.c (expand_expr_real_2): Likewise.
1735         * fold-const.c (const_unop): Likewise.
1736         * optabs-tree.c (optab_for_tree_code): Likewise.
1737         * tree-cfg.c (verify_gimple_assign_unary): Likewise.
1738         * tree-inline.c (estimate_operator_cost): Likewise.
1739         * tree-pretty-print.c (dump_generic_node): Likewise.
1740         (op_code_prio): Likewise.
1741         (op_symbol_code): Likewise.
1742         * internal-fn.def (DEF_INTERNAL_SIGNED_OPTAB_FN): Define.
1743         (IFN_REDUC_PLUS, IFN_REDUC_MAX, IFN_REDUC_MIN): New internal functions.
1744         * internal-fn.c (direct_internal_fn_optab): New function.
1745         (direct_internal_fn_array, direct_internal_fn_supported_p
1746         (internal_fn_expanders): Handle DEF_INTERNAL_SIGNED_OPTAB_FN.
1747         * fold-const-call.c (fold_const_reduction): New function.
1748         (fold_const_call): Handle CFN_REDUC_PLUS, CFN_REDUC_MAX and
1749         CFN_REDUC_MIN.
1750         * tree-vect-loop.c: Include internal-fn.h.
1751         (reduction_code_for_scalar_code): Rename to...
1752         (reduction_fn_for_scalar_code): ...this and return an internal
1753         function.
1754         (vect_model_reduction_cost): Take an internal_fn rather than
1755         a tree_code.
1756         (vect_create_epilog_for_reduction): Likewise.  Build calls rather
1757         than assignments.
1758         (vectorizable_reduction): Use internal functions rather than tree
1759         codes for the reduction operation.  Update calls to the functions
1760         above.
1761         * config/aarch64/aarch64-builtins.c (aarch64_gimple_fold_builtin):
1762         Use calls to internal functions rather than REDUC tree codes.
1763         * config/aarch64/aarch64-simd.md: Update comment accordingly.
1765 2017-11-22  Olivier Hainque  <hainque@adacore.com>
1767        * config/vxworks.c (vxworks_override_options): Pick default
1768         dwarf version from macro value, VXWORKS_DWARF_VERSION_DEFAULT.
1769        * config/vxworks.h: Define VXWORKS_DWARF_VERSION_DEFAULT and
1770        DWARF_GNAT_ENCODINGS_DEFAULT.
1771        * config/vxworksae.h: Likewise.
1773 2017-11-22  Marc Glisse  <marc.glisse@inria.fr>
1775         PR tree-optimization/83104
1776         * vr-values.c (simplify_stmt_using_ranges): Check integral argument,
1777         not result.
1779 2017-11-22  Marek Polacek  <polacek@redhat.com>
1780             H.J. Lu  <hongjiu.lu@intel.com>
1781             Jason Merrill  <jason@redhat.com>
1783         PR c++/60336
1784         PR middle-end/67239
1785         PR target/68355
1786         * calls.c (initialize_argument_information): Call
1787         warn_parameter_passing_abi target hook.
1788         (store_one_arg): Use 0 for empty record size.  Don't push 0 size
1789         argument onto stack.
1790         (must_pass_in_stack_var_size_or_pad): Return false for empty types.
1791         * common.opt: Update -fabi-version description.
1792         * config/i386/i386.c (init_cumulative_args): Set cum->warn_empty.
1793         (ix86_gimplify_va_arg): Call arg_int_size_in_bytes instead of
1794         int_size_in_bytes.
1795         (ix86_is_empty_record): New function.
1796         (ix86_warn_parameter_passing_abi): New function.
1797         (TARGET_EMPTY_RECORD_P): Redefine.
1798         (TARGET_WARN_PARAMETER_PASSING_ABI): Redefine.
1799         * config/i386/i386.h (CUMULATIVE_ARGS): Add warn_empty.
1800         * doc/tm.texi: Regenerated.
1801         * doc/tm.texi.in (TARGET_EMPTY_RECORD_P,
1802         TARGET_WARN_PARAMETER_PASSING_ABI): Add.
1803         * dwarf2out.c (get_ultimate_context): Move to tree.c.
1804         * explow.c (hard_function_value): Call arg_int_size_in_bytes
1805         instead of int_size_in_bytes.
1806         * expr.c (copy_blkmode_to_reg): Likewise.
1807         * function.c (aggregate_value_p): Return 0 for empty types.
1808         (assign_parm_find_entry_rtl): Call warn_parameter_passing_abi target hook.
1809         (locate_and_pad_parm): Call arg size_in_bytes instead
1810         size_in_bytes.
1811         * lto-streamer-out.c (hash_tree): Hash TYPE_EMPTY_P and DECL_PADDING_P.
1812         * stor-layout.c (finalize_type_size): Set TYPE_EMPTY_P.
1813         * target.def (empty_record_p, warn_parameter_passing_abi): New target
1814         hooks.
1815         * targhooks.c (hook_void_CUMULATIVE_ARGS_tree): New hook.
1816         (std_gimplify_va_arg_expr): Skip empty records.  Call
1817         arg_size_in_bytes instead size_in_bytes.
1818         * targhooks.h (hook_void_CUMULATIVE_ARGS_tree): Declare.
1819         * tree-core.h (tree_type_common): Add empty_flag.
1820         (tree_decl_common): Update comments.
1821         * tree-streamer-in.c (unpack_ts_decl_common_value_fields): Stream
1822         DECL_PADDING_P.
1823         (unpack_ts_type_common_value_fields): Stream TYPE_EMPTY_P.
1824         * tree-streamer-out.c (pack_ts_decl_common_value_fields): Stream
1825         DECL_PADDING_P.
1826         (pack_ts_type_common_value_fields): Stream TYPE_EMPTY_P.
1827         * tree.c (default_is_empty_type): New function.
1828         (default_is_empty_record): New function.
1829         (arg_int_size_in_bytes): New function.
1830         (arg_size_in_bytes): New function.
1831         (get_ultimate_context): New function.
1832         * tree.h: Define TYPE_EMPTY_P, DECL_PADDING_P and
1833         TRANSLATION_UNIT_WARN_EMPTY_P.
1834         (default_is_empty_record, arg_int_size_in_bytes,
1835         arg_size_in_bytes, get_ultimate_context): Declare.
1837 2017-11-22  Thomas Preud'homme  <thomas.preudhomme@arm.com>
1839         * config/arm/arm.c (cmse_clear_registers): New function.
1840         (cmse_nonsecure_call_clear_caller_saved): Replace register clearing
1841         code by call to cmse_clear_registers.
1842         (cmse_nonsecure_entry_clear_before_return): Likewise.
1844 2017-11-22  Tamar Christina  <tamar.christina@arm.com>
1846         * config/arm/arm_neon.h (vdot_u32, vdotq_u32)
1847         (vdot_s32, vdotq_s32): New.
1848         (vdot_lane_u32, vdotq_lane_u32): New.
1849         (vdot_lane_s32, vdotq_lane_s32): New.
1852 2017-11-22  Richard Sandiford  <richard.sandiford@linaro.org>
1854         PR middle-end/82547
1855         * wide-int.cc (wi::add_large, wi::sub_large): Fix overflow detection
1856         for unsigned values with fewer HWIs than the precision.
1857         (test_overflow): New function.
1858         (wide_int_cc_tests): Call it.
1860 2017-11-22  Richard Sandiford  <richard.sandiford@linaro.org>
1862         * emit-rtl.c (init_derived_machine_modes): Make sure ptr_mode
1863         has the same mode class as Pmode.
1865 2017-11-22  Thomas Preud'homme  <thomas.preudhomme@arm.com>
1867         * config/arm/arm.c (cmse_nonsecure_call_clear_caller_saved): Get rid of
1868         padding_bits_to_clear_ptr.
1869         (cmse_nonsecure_entry_clear_before_return): Likewise.
1871 2017-11-22  Thomas Preud'homme  <thomas.preudhomme@arm.com>
1873         * config/arm/arm.c (cmse_nonsecure_call_clear_caller_saved): Use
1874         auto_sbitap instead of integer bitfield to control register needing
1875         clearing.
1877 2017-11-22  Jakub Jelinek  <jakub@redhat.com>
1879         PR tree-optimization/83044
1880         * tree-vrp.c (vrp_prop::check_array_ref): If eltsize is not
1881         INTEGER_CST or is 0, clear up_bound{,_p1} and later ignore tests
1882         that need the upper bound.  Subtract offset from
1883         get_addr_base_and_unit_offset only if positive and subtract it
1884         before division by eltsize rather than after it.
1886         PR debug/83084
1887         * valtrack.c (propagate_for_debug_subst, propagate_for_debug): Reset
1888         debug insns if they would contain UNSPEC_VOLATILE or volatile asm.
1889         (dead_debug_insert_temp): Likewise, but also ignore even non-volatile
1890         asm.
1892         PR middle-end/82875
1893         * optabs.c (expand_doubleword_mult, expand_binop): Before calling
1894         expand_binop with *mul_widen_optab, make sure at least one of the
1895         operands doesn't have VOIDmode.
1897         PR debug/83034
1898         * dwarf2out.c (mem_loc_descriptor): Handle VEC_SERIES.
1900         PR rtl-optimization/82044
1901         PR tree-optimization/82042
1902         * dse.c (record_store): Check for overflow.
1903         (check_mem_read_rtx): Properly check for overflow if width == -1, call
1904         add_wild_read instead of clear_rhs_from_active_local_stores on
1905         overflow and log it into dump_file.
1907 2017-11-22  Richard Biener  <rguenther@suse.de>
1909         * gimple-iterator.c (gimple_find_edge_insert_loc): Ignore
1910         fake edges to exit when looking for a place to insert.
1911         * tree-ssa-pre.c (clear_expression_ids): Inline into callers
1912         and remove.
1913         (insert_into_preds_of_block): Commit edge insertion immediately,
1914         assert that doesn't require new BBs.
1915         (fini_pre): Release expressions.
1916         (pass_pre::execute): Shuffle things around a bit, if the fn
1917         is too large do not compute AVAIL either as this is really the
1918         quadratic bit.
1920 2017-11-22  Richard Biener  <rguenther@suse.de>
1922         PR tree-optimization/83089
1923         * tree-if-conv.c (pass_if_conversion::execute): If anything
1924         changed reset SCEV and free the number of iteration estimates.
1926 2017-11-21  Martin Sebor  <msebor@redhat.com>
1928         PR tree-optimization/82945
1929         * calls.h (warn_nonstring_bound): Remove unused function.
1931 2017-11-21  Martin Sebor  <msebor@redhat.com>
1933         PR tree-optimization/82945
1934         * builtins.c (expand_builtin_strlen): Call maybe_warn_nonstring_arg.
1935         * calls.h (maybe_warn_nonstring_arg): Declare new function.
1936         * calls.c (get_attr_nonstring_decl, maybe_warn_nonstring_arg): New
1937         functions.
1938         (initialize_argument_information): Call maybe_warn_nonstring_arg.
1939         * calls.h (get_attr_nonstring_decl): Declare new function.
1940         * doc/extend.texi (attribute nonstring): Update.
1941         * gimple-fold.c (gimple_fold_builtin_strncpy): Call
1942         get_attr_nonstring_decl and handle it.
1943         * tree-ssa-strlen.c (maybe_diag_stxncpy_trunc): Same.  Improve
1944         detection of nul-termination.
1945         (strlen_to_stridx): Change to a pointer.
1946         (handle_builtin_strlen, handle_builtin_stxncpy): Adjust.
1947         (pass_strlen::execute): Same.
1949 2017-11-21  Sergey Shalnov  <Sergey.Shalnov@intel.com>
1951         * config/i386/i386-opts.h (enum prefer_vector_width): Added new enum
1952         for the new option -mprefer-vector-width=[none|128|256|512].
1953         * config/i386/i386.c (ix86_target_string): remove old style options
1954         -mprefer-avx256 and make -mprefer-avx128 as alias.
1955         (ix86_option_override_internal):  Apply defaults for the
1956         -mprefer-vector-width=[128|256] option.
1957         * config/i386/i386.h (TARGET_PREFER_AVX128, TARGET_PREFER_AVX256):
1958         Implement macros to work with -mprefer-vector-width=.
1959         * config/i386/i386.opt: Implemented option
1960         -mprefer-vector-width=[none|128|256|512].
1961         * doc/invoke.texi: Documentation for
1962         -mprefer-vector-width=[none|128|256|512].
1964 2017-11-21  Pat Haugen  <pthaugen@us.ibm.com>
1966         * config/rs6000/ppc-asm.h (f50, vs50): Fix values.
1968 2017-11-21  Jonathan Wakely  <jwakely@redhat.com>
1970         * doc/invoke.texi (-Wmaybe-uninitialized): Rephrase for clarity.
1972 2017-11-21  Marc Glisse  <marc.glisse@inria.fr>
1974         * doc/generic.texi: Document POINTER_DIFF_EXPR, update
1975         POINTER_PLUS_EXPR.
1976         * cfgexpand.c (expand_debug_expr): Handle POINTER_DIFF_EXPR.
1977         * expr.c (expand_expr_real_2): Likewise.
1978         * fold-const.c (const_binop, fold_addr_of_array_ref_difference,
1979         fold_binary_loc): Likewise.
1980         * match.pd (X-X, P+(Q-P), &D-P, (P+N)-P, P-(P+N), (P+M)-(P+N),
1981         P-Q==0, -(A-B), X-Z<Y-Z, (X-Z)-(Y-Z), Z-X<Z-Y, (Z-X)-(Z-Y),
1982         (A-B)+(C-A)): New transformations for POINTER_DIFF_EXPR, based on
1983         MINUS_EXPR transformations.
1984         * optabs-tree.c (optab_for_tree_code): Handle POINTER_DIFF_EXPR.
1985         * tree-cfg.c (verify_expr, verify_gimple_assign_binary): Likewise.
1986         * tree-inline.c (estimate_operator_cost): Likewise.
1987         * tree-pretty-print.c (dump_generic_node, op_code_prio,
1988         op_symbol_code): Likewise.
1989         * tree-vect-stmts.c (vectorizable_operation): Likewise.
1990         * vr-values.c (extract_range_from_binary_expr): Likewise.
1991         * varasm.c (initializer_constant_valid_p_1): Likewise.
1992         * tree.def: New tree code POINTER_DIFF_EXPR.
1994 2017-11-21  Uros Bizjak  <ubizjak@gmail.com>
1996         * config/i386/i386.md (*bswap<mode>2_movbe): Add
1997         integer suffix to movbe mnemonic.
1998         (*bswaphi2_movbe): Ditto.
1999         (bswaphi_lowpart): Merge with *bswaphi_lowpart_1.
2001 2017-11-21  Jakub Jelinek  <jakub@redhat.com>
2003         PR c++/83045
2004         * tree-cfg.c (pass_warn_function_return::execute): Formatting fix.
2005         Also warn if seen __builtin_unreachable () call with BUILTINS_LOCATION.
2006         Use LOCATION_LOCUS when comparing against UNKNOWN_LOCATION.
2008 2017-11-21  Martin Liska  <mliska@suse.cz>
2010         * tree-inline.c (expand_call_inline): Remove not needed
2011         xstrdup_for_dump.
2013 2017-11-21  James Cowgill  <James.Cowgill@imgtec.com>
2014             Jakub Jelinek  <jakub@redhat.com>
2016         PR target/82880
2017         * config/mips/frame-header-opt.c (mips_register_frame_header_opt):
2018         Remove static keyword from f variable.
2020 2017-11-21  Jakub Jelinek  <jakub@redhat.com>
2022         PR tree-optimization/83086
2023         * gimple-ssa-store-merging.c
2024         (imm_store_chain_info::try_coalesce_bswap): Test this_n.base_addr
2025         rather than n.base_addr.
2027 2017-11-21  Martin Liska  <mliska@suse.cz>
2029         PR rtl-optimization/82044
2030         PR tree-optimization/82042
2031         * dse.c (check_mem_read_rtx): Check for overflow.
2033 2017-11-21  Aldy Hernandez  <aldyh@redhat.com>
2035         * tree-ssa-threadbackward.c (find_jump_threads_backwards): Fix
2036         typo in comment.
2038 2017-11-21  Claudiu Zissulescu  <claziss@synopsys.com>
2040         * cfgrtl.c (force_nonfallthru_and_redirect): Don't split a call
2041         and its corresponding call arg location note.
2043 2017-11-21  Claudiu Zissulescu  <claziss@synopsys.com>
2044             Andrew Burgess  <andrew.burgess@embecosm.com>
2046         * config/arc/arc-protos.h (arc_compute_frame_size): Delete
2047         declaration.
2048         (arc_return_slot_offset): Likewise.
2049         (arc_eh_return_address_location): New declaration.
2050         * config/arc/arc.c (TARGET_BUILTIN_SETJMP_FRAME_VALUE): Define.
2051         (MUST_SAVE_REGISTER): Add exception handler case.
2052         (MUST_SAVE_RETURN_ADDR): Likewise.
2053         (arc_frame_pointer_required): Likewise.
2054         (arc_frame_pointer_needed): New function.
2055         (arc_compute_frame_size): Changed.
2056         (arc_expand_prologue): Likewise.
2057         (arc_expand_epilogue): Likewise.
2058         (arc_initial_elimination_offset): Likewise.
2059         (arc_return_slot_offset): Delete.
2060         (arc_eh_return_address_location): New function.
2061         (arc_builtin_setjmp_frame_value): Likewise.
2062         * config/arc/arc.h (EH_RETURN_DATA_REGNO): Use 2 registers.
2063         (EH_RETURN_STACKADJ_RTX): Define.
2064         (EH_RETURN_HANDLER_RTX): Likewise.
2065         * config/arc/arc.md (eh_return): Delete.
2067 2017-11-21  Aldy Hernandez  <aldyh@redhat.com>
2069         * print-tree.h (debug_vec_tree): Remove prototype.
2070         * gdbinit.in (pvt): Remove macro.
2072 2017-11-21  Jakub Jelinek  <jakub@redhat.com>
2074         PR tree-optimization/83047
2075         * gimple-ssa-store-merging.c
2076         (imm_store_chain_info::output_merged_store): If the loads with the
2077         same vuse are in different basic blocks, for load_gsi pick a load
2078         location that is dominated by the other loads.
2080         PR c++/83059
2081         * config/i386/i386.c (ix86_memmodel_check): Start
2082         -Winvalid-memory-model diagnostics with lowercase letter.
2084         PR debug/82718
2085         * dwarf2out.c (dw_loc_list): If crtl->has_bb_partition, temporarily
2086         set in_cold_section_p to the partition containing loc_list->first.
2087         When seeing loc_list->last_before_switch node, update secname and
2088         perform range_across_switch second partition handling only after that.
2090         PR debug/82933
2091         * run-rtl-passes.c: Include debug.h.
2092         (run_rtl_passes): Call debug_hooks->assembly_start.
2093         * dwarf2out.c (dwarf2out_assembly_start): Return early if invoked
2094         multiple times.
2096         PR target/82981
2097         * internal-fn.c (expand_mul_overflow): Use OPTAB_WIDEN instead of
2098         OPTAB_DIRECT in calls to expand_simple_binop.
2100 2017-11-20  David Malcolm  <dmalcolm@redhat.com>
2102         PR c/81404
2103         * Makefile.in (C_COMMON_OBJS): Add c-family/known-headers.o.
2105 2017-11-20  David Malcolm  <dmalcolm@redhat.com>
2107         PR c++/72786
2108         * spellcheck.h (best_match::blithely_get_best_candidate): New
2109         accessor.
2111 2017-11-20  Jakub Jelinek  <jakub@redhat.com>
2113         * config/i386/i386.c (parse_mtune_ctrl_str): Start diagnostics
2114         with lower case letter.
2116 2017-11-20  Uros Bizjak  <ubizjak@gmail.com>
2118         * config/i386/i386.md (bswaphi2): New expander.
2119         (*bswaphi2_movbe): New insn pattern.
2120         (bswaphi -> rorhi pepehole2): New peephole pattern.
2122 2017-11-20  Jeff Law  <law@redhat.com>
2124         * Makefile.in (OBJS): Add gimple-ssa-evrp-analyze.o.
2125         * gimple-ssa-evrp-analyze.c: New file pulled from gimple-ssa-evrp.c.
2126         * gimple-ssa-evrp-analyze.h: New file pulled from gimple-ssa-evrp.c.
2127         * gimple-ssa-evrp.c: Remove bits moved into new files.  Include
2128         gimple-ssa-evrp-analyze.h.
2130         * gimple-ssa-evrp.c (evrp_dom_walker::before_dom_children): Do not
2131         set BB_VISITED here.
2132         (evrp_range_analyzer::enter): Set BB_VISITED here instead.
2134 2017-11-20  Bin Cheng  <bin.cheng@arm.com>
2136         * tree-predcom.c: Add general comment on Store-Store chains.
2137         (split_data_refs_to_components): Postpone clearing eliminate_store_p
2138         flag in component.
2139         (get_chain_last_ref_at): Rename into...
2140         (get_chain_last_write_at): ...this.
2141         (get_chain_last_write_before_load): New function.
2142         (add_ref_to_chain): Promote type of chain from CT_STORE_LOAD to
2143         CT_STORE_STORE when write reference is added.
2144         (determine_roots_comp): Support load ref in CT_STORE_STORE chains.
2145         (is_inv_store_elimination_chain): Update get_chain_last_write_at call.
2146         (initialize_root_vars_store_elim_1): Ditto.
2147         (initialize_root_vars_store_elim_2): Ditto.  Replace rhs once default
2148         definition is created.
2149         (execute_pred_commoning_chain): Support load ref in CT_STORE_STORE
2150         chain by replacing it with dominant stored value.
2152 2017-11-20  Bin Cheng  <bin.cheng@arm.com>
2154         * tree-predcom.c (add_ref_to_chain): Remove check on distance.
2156 2017-11-20  Marc Glisse  <marc.glisse@inria.fr>
2158         * vr-values.c (extract_range_from_binary_expr): Use a full range
2159         for VR_VARYING.
2161 2017-11-20  Thomas Preud'homme  <thomas.preudhomme@arm.com>
2163         * config/arm/arm.md (R4_REGNUM): Define constant.
2164         (nonsecure_call_internal): Remove r4 clobber.
2165         (nonsecure_call_value_internal): Likewise.
2166         * config/arm/thumb1.md (nonsecure_call_reg_thumb1_v5): Remove second
2167         clobber and resequence match_operands.
2168         (nonsecure_call_value_reg_thumb1_v5): Likewise.
2169         * config/arm/thumb2.md (nonsecure_call_reg_thumb2): Likewise.
2170         (nonsecure_call_value_reg_thumb2): Likewise.
2172 2017-11-20  Jakub Jelinek  <jakub@redhat.com>
2174         PR tree-optimization/78821
2175         * gimple-ssa-store-merging.c (find_bswap_or_nop_load): Give up
2176         if base is TARGET_MEM_REF.  If base is not MEM_REF, set base_addr
2177         to the address of the base rather than the base itself.
2178         (find_bswap_or_nop_1): Just use pointer comparison for vuse check.
2179         (find_bswap_or_nop_finalize): New function.
2180         (find_bswap_or_nop): Use it.
2181         (bswap_replace): Return a tree rather than bool, change first
2182         argument from gimple * to gimple_stmt_iterator, allow inserting
2183         into an empty sequence, allow ins_stmt to be NULL - then emit
2184         all stmts into gsi.  Fix up MEM_REF address gimplification.
2185         (pass_optimize_bswap::execute): Adjust bswap_replace caller.
2186         (struct store_immediate_info): Add N and INS_STMT non-static
2187         data members.
2188         (store_immediate_info::store_immediate_info): Initialize them
2189         from newly added ctor args.
2190         (merged_store_group::apply_stores): Formatting fixes.  Sort by
2191         bitpos at the end.
2192         (stmts_may_clobber_ref_p): For stores call also
2193         refs_anti_dependent_p.
2194         (gather_bswap_load_refs): New function.
2195         (imm_store_chain_info::try_coalesce_bswap): New method.
2196         (imm_store_chain_info::coalesce_immediate_stores): Use it.
2197         (split_group): Handle LROTATE_EXPR and NOP_EXPR rhs_code specially.
2198         (imm_store_chain_info::output_merged_store): Fail if number of
2199         new estimated stmts is bigger or equal than old.  Handle LROTATE_EXPR
2200         and NOP_EXPR rhs_code.
2201         (pass_store_merging::process_store): Compute n and ins_stmt, if
2202         ins_stmt is non-NULL and the store rhs is otherwise invalid, use
2203         LROTATE_EXPR rhs_code.  Pass n and ins_stmt to store_immediate_info
2204         ctor.
2205         (pass_store_merging::execute): Calculate dominators.
2207         * tree-ssa-math-opts.c (nop_stats, bswap_stats, struct symbolic_number,
2208         BITS_PER_MARKER, MARKER_MASK, MARKER_BYTE_UNKNOWN, HEAD_MARKER, CMPNOP,
2209         CMPXCHG, do_shift_rotate, verify_symbolic_number_p,
2210         init_symbolic_number, find_bswap_or_nop_load, perform_symbolic_merge,
2211         find_bswap_or_nop_1, find_bswap_or_nop, pass_data_optimize_bswap,
2212         class pass_optimize_bswap, bswap_replace,
2213         pass_optimize_bswap::execute): Moved to ...
2214         * gimple-ssa-store-merging.c: ... this file.
2215         Include optabs-tree.h.
2216         (nop_stats, bswap_stats, do_shift_rotate, verify_symbolic_number_p,
2217         init_symbolic_number, find_bswap_or_nop_load, perform_symbolic_merge,
2218         find_bswap_or_nop_1, find_bswap_or_nop, bswap_replace): Put into
2219         anonymous namespace, remove static keywords.
2220         (pass_optimize_bswap::gate): Test BITS_PER_UNIT == 8 here...
2221         (pass_optimize_bswap::execute): ... rather than here.  Formatting fix.
2223 2017-11-20  Jan Hubicka  <hubicka@ucw.cz>
2225         PR bootstrap/83062
2226         * ipa-inline.c (can_inline_edge_p): Fix typo in previous patch.
2228 2017-11-20  Aldy Hernandez  <aldyh@redhat.com>
2230         * vec.h (debug_helper): New function.
2231         (DEFINE_DEBUG_VEC): New macro.
2232         * hash-set.h (debug_helper): New function.
2233         (DEFINE_DEBUG_HASH_SET): New macro.
2234         * cfg.c (debug_slim (edge)): New function.
2235         Call DEFINE_DEBUG_VEC for edges.
2236         Call DEFINE_DEBUG_HASH_SET for edges.
2237         * cfghooks.c (debug_slim (basic_block)): New function.
2238         Call DEFINE_DEBUG_VEC for basic blocks.
2239         Call DEFINE_DEBUG_HASH_SET for basic blocks.
2240         * print-tree.c (debug_slim): New function to handle trees.
2241         Call DEFINE_DEBUG_VEC for trees.
2242         Call DEFINE_DEBUG_HASH_SET for trees.
2243         (debug (vec<tree, va_gc>) &): Remove.
2244         (debug (<vec<tree, va_gc>) *): Remove.
2245         * print-rtl.c (debug_slim): New function to handle const_rtx.
2246         Call DEFINE_DEBUG_VEC for rtx_def.
2247         Call DEFINE_DEBUG_VEC for rtx_insn.
2248         Call DEFINE_DEBUG_HASH_SET for rtx_def.
2249         Call DEFINE_DEBUG_HASH_SET for rtx_insn.
2250         * sel-sched-dump.c (debug (vec<rtx_insn *> &): Remove.
2251         (debug (vec<rtx_insn *> *ptr): Remove.
2252         (debug_insn_vector): Remove.
2253         * stor-layout.c (debug_rli): Call debug() instead of debug_vec_tree.
2255 2017-11-20  Tom de Vries  <tom@codesourcery.com>
2257         PR rtl-optimization/82020
2258         * simplify-rtx.c (simplify_ternary_operation): Fix comparison mode of
2259         IF_THEN_ELSE condition.
2261 2017-11-19  Jeff Law  <law@redhat.com>
2263         * tree-ssa-dom.c (record_equivalences_from_phis): Fix handling
2264         of degenerates resulting from ignoring an edge.
2266 2017-11-19  Jan Hubicka  <hubicka@ucw.cz>
2268         PR ipa/81360
2269         * ipa-inline.c (can_inline_edge_p): Also check that caller is optimized
2271 2017-11-19  Jan Hubicka  <hubicka@ucw.cz>
2273         PR ipa/83001
2274         * profile-count.c (profile_count::to_sreal_scale): Fix return value
2275         for uninitialied counts.
2277 2017-11-19  Jan Hubicka  <hubicka@ucw.cz>
2279         PR ipa/60243
2280         * tree-inline.c (estimate_num_insns): Set to 1 at least.
2282 2017-11-19  Jan Hubicka  <hubicka@ucw.cz>
2284         PR target/82713
2285         * i386.c (ix86_builtin_vectorization_cost): Be ready for insane types.
2287 2017-11-19  Tom de Vries  <tom@codesourcery.com>
2289         * config/arc/arc.h (FUNCTION_PROFILER): Remove semicolon after
2290         "do while (0)".
2292 2017-11-19  Tom de Vries  <tom@codesourcery.com>
2294         * config/phoenix.h (TARGET_OS_CPP_BUILTINS): Remove semicolon after
2295         "do {} while (0)".
2297 2017-11-19  Tom de Vries  <tom@codesourcery.com>
2299         * config/visium/visium.h (ASM_OUTPUT_CASE_END): Remove semicolon after
2300         macro body.
2302 2017-11-19  Tom de Vries  <tom@codesourcery.com>
2304         * config/ft32/ft32.h (REGISTER_TARGET_PRAGMAS): Remove semicolon after
2305         "do {} while (0)".
2306         * config/spu/spu.h (REGISTER_TARGET_PRAGMAS): Same.
2308 2017-11-19  Tom de Vries  <tom@codesourcery.com>
2310         * config/mcore/mcore-elf.h (MCORE_EXPORT_NAME): Remove semicolon after
2311         "do {} while (0)".
2312         * config/mcore/mcore.h (ASM_OUTPUT_ALIGNED_COMMON): After missing
2313         semicolon after MCORE_EXPORT_NAME call.
2315 2017-11-19  Tom de Vries  <tom@codesourcery.com>
2317         PR target/82961
2318         * vmsdbgout.c (vmsdbgout_early_finish): New function.
2319         (vmsdbg_debug_hooks): Set early_finish field to vmsdbgout_early_finish.
2321 2017-11-18  Jan Hubicka  <hubicka@ucw.cz>
2323         * cgraphclones.c (cgraph_edge::clone): Rename gcov_count to prof_count.
2324         (cgraph_edge::clone): Cleanup updating of profile.
2325         * ipa-cp.c (update_profiling_info): Likewise.
2326         * ipa-inline-transform.c (inline_transform): Likewise.
2327         * ipa-inline.c (inline_small_functions): Add missing space to dump.
2328         * ipa-split.c (execute_split_functions): Do not split when function
2329         is cold.
2330         * predict.c (estimate_bb_frequencies): Cleanup updating of profile.
2331         * profile-count.c (profile_count::dump): Add global0.
2332         (profile_count::to_cgraph_frequency): Do not ICE when entry is
2333         undefined.
2334         (profile_count::to_sreal_scale): Likewise.
2335         (profile_count::adjust_for_ipa_scaling): Fix typo in comment.
2336         (profile_count::combine_with_ipa_count): New function.
2337         * profile-count.h (profile_guessed_global0adjusted): New.
2338         (profile_count::adjusted_zero): New.
2339         (profile_count::global0adjusted): New.
2340         (profile_count::combine_with_ipa_count): New.
2341         * tree-inline.c (copy_edges_for_bb): Add NUM/DEN arugment;
2342         correct profile of return block of split functions.
2343         (copy_cfg_body): Remove unused profile_count.
2344         (copy_body): Likewise.
2345         (expand_call_inline): Update.
2346         (tree_function_versioning): Update.
2348 2017-11-18  Aldy Hernandez  <aldyh@redhat.com>
2350         * hash-set.h (hash_set::empty): New.
2351         * tree-ssa-threadbackward.h: Delete.
2352         * tree-ssa-threadbackward.c (class thread_jumps): New.
2353         Move max_threaded_paths into class.
2354         (fsm_find_thread_path): Remove arguments that are now in class.
2355         (profitable_jump_thread_path): Rename to...
2356         (thread_jumps::profitable_jump_thread_path): ...this.
2357         (convert_and_register_jump_thread_path): Rename to...
2358         (thread_jumps::convert_and_register_current_path): ...this.
2359         (check_subpath_and_update_thread_path): Rename to...
2360         (thread_jumps::check_subpath_and_update_thread_path): ...this.
2361         (register_jump_thread_path_if_profitable): Rename to...
2362         (thread_jumps::register_jump_thread_path_if_profitable): ...this.
2363         (handle_phi): Rename to...
2364         (thread_jumps::handle_phi): ...this.
2365         (handle_assignment): Rename to...
2366         (thread_jumps::handle_assignment): ...this.
2367         (fsm_find_control_statement_thread_paths): Rename to...
2368         (thread_jumps::fsm_find_control_statement_thread_paths): ...this.
2369         (find_jump_threads_backwards): Rename to...
2370         (thread_jumps::find_jump_threads_backwards): ...this.
2371         Initialize path local data.
2372         (pass_thread_jumps::execute): Call find_jump_threads_backwards
2373         from within thread_jumps class.
2374         (pass_early_thread_jumps::execute): Same.
2376 2017-11-17  Jan Hubicka  <hubicka@ucw.cz>
2378         * cgraph.c (cgraph_node::dump): Do IPA sanity checking on IPA counts.
2380 2017-11-17  Steve Ellcey  <sellcey@cavium.com>
2382         * config/aarch64/aarch64-simd.md (fnma<mode>4): Move neg operator
2383         to canonical location.
2385 2017-11-17  Steve Ellcey  <sellcey@cavium.com>
2387         PR target/81356
2388         * config/aarch64/aarch64.c (aarch64_use_by_pieces_infrastructure_p):
2389         Remove.
2390         (TARGET_USE_BY_PIECES_INFRASTRUCTURE_P): Remove define.
2392 2017-11-17  H.J. Lu  <hongjiu.lu@intel.com>
2394         * config/gnu-user.h (GNU_USER_TARGET_STARTFILE_SPEC): Use
2395         rcrt1.o%s/grcrt1.o%s for -static-pie.
2397 2017-11-17  Jan Hubicka  <hubicka@ucw.cz>
2399         * i386.c (ix86_multiplication_cost, ix86_division_cost,
2400         ix86_shift_rotate_cost): Break out from ...
2401         (ix86_rtx_costs): ... here.
2402         (ix86_add_stmt_cost): Use rtx cost machinery to compute cost of
2403         vector operations.
2405 2017-11-17  Jan Hubicka  <hubicka@ucw.cz>
2407         * predict.c (determine_unlikely_bbs): Set cgraph node count to 0
2408         when entry block was promoted unlikely.
2409         (estimate_bb_frequencies): Increase frequency scale.
2410         * profile-count.h (profile_count): Export precision info.
2412 2017-11-17  Jan Hubicka  <hubicka@ucw.cz>
2414         * tree-tailcall.c (eliminate_tail_call): Be more careful about not
2415         disturbin profile of entry block.
2417 2017-11-17  Jan Hubicka  <hubicka@ucw.cz>
2419         * ipa-fnsummary.c (estimate_node_size_and_time): Be more tolerant for
2420         roundoff errors.
2422 2017-11-17  Jan Hubicka  <hubicka@ucw.cz>
2424         * ipa-cp.c (update_profiling_info): Handle conversion to local profile.
2425         * tree-cfg.c (execute_fixup_cfg): Do fixup same way as inliner does.
2427 2017-11-17  Jeff Law  <law@redhat.com>
2429         * gimple-ssa-evrp.c (class evrp_range_analyzer): New class extracted
2430         from evrp_dom_walker class.  Various methods moved into new class.
2431         (evrp_range_analyzer::evrp_range_analyzer): Constructor for new class.
2432         (evrp_range_analyzer::enter): New method.
2433         (evrp_range_analyzer::leave): New method.
2434         (evrp_dom_walker): Remove delegators no longer needed by this class.
2435         Replace vr_values data member with evrp_range_analyzer
2437         * gimple-ssa-evrp.c (evrp_dom_walker::record_ranges_from_phis): New
2438         method extracted from evrp_dom_walker::before_dom_children.
2439         (evrp_dom_walker::record_ranges_from_stmt): Likewise.
2440         (evrp_dom_walker::record_ranges_from_incoming_edge): Likewise.
2442         * gimple-ssa-evrp.c (evrp_dom_walker): Add cleanup method.
2443         Add private copy constructor and move assignment operators.
2444         Privatize methods and class data where trivially possible.
2445         (evrp_dom_walker::cleanup): New function, extracted from
2446         execute_early_vrp.  Simplify access to class data.
2448         * vr-values.h (get_output_for_vrp): Prototype.
2449         * vr-values.c (get_output_for_vrp): New function extracted from
2450         vrp_visit_assignment_or_call and extract_range_from_stmt.
2451         (vrp_visit_assignment_or_call): Use get_output_for_vrp.  Simplify.
2453 2017-11-17  Luis Machado  <luis.machado@linaro.org>
2455         * config/aarch64/aarch64.c
2456         (qdf24xx_prefetch_tune) <default_opt_level>: Set to -1.
2457         (qdf24xx_tunings) <autoprefetcher_model>: Set to
2458         tune_params::AUTOPREFETCHER_WEAK.
2460 2017-11-17  Tamar Christina  <tamar.christina@arm.com>
2462         PR target/82641
2463         * config/arm/arm.c (arm_valid_target_attribute_rec):
2464         Parse "arch=" and "+<ext>".
2465         (arm_valid_target_attribute_tree): Re-init global options.
2466         (arm_option_override): Make non-static.
2467         (arm_options_perform_arch_sanity_checks): Make errors fatal.
2468         * gcc/config/arm/arm-c.c (__ARM_FEATURE_CMSE): Support undef.
2469         (__ARM_FEATURE_CRC32): Support undef.
2470         * config/arm/arm_acle.h (__ARM_FEATURE_CRC32): Replace with pragma.
2471         * doc/extend.texi (ARM Function Attributes): Add pragma and target.
2473 2017-11-17  David Malcolm  <dmalcolm@redhat.com>
2475         * gdbinit.in (break-on-diagnostic): New command.
2477 2017-11-17  Igor Tsimbalist  <igor.v.tsimbalist@intel.com>
2479         * config/i386/i386.c (ix86_expand_epilogue): Change simple
2480         return to indirect jump for EH return if control-flow
2481         protection is enabled. Change explicit 'false' argument in
2482         pro_epilogue_adjust_stack with a value of
2483         flag_cf_protection.
2484         * config/i386/i386.md (simple_return_indirect_internal):
2485         Remove SImode restriction to support 64-bit.
2487 2017-11-17  Segher Boessenkool  <segher@kernel.crashing.org>
2489         * combine.c (added_notes_insn): New.
2490         (try_combine): Handle added_notes_insn like added_links_insn.
2491         Rewrite return value code.
2492         (distribute_notes): Set added_notes_insn to the earliest insn we added
2493         a note to.
2495 2017-11-17  Segher Boessenkool  <segher@kernel.crashing.org>
2497         PR rtl-optimization/82621
2498         * combine.c (try_combine): Do not split PARALLELs of two SETs if the
2499         dest of one of those SETs is unused.
2501 2017-11-17  Richard Biener  <rguenther@suse.de>
2503         PR fortran/83017
2504         * tree-core.h (enum annot_expr_kind): Add annot_expr_parallel_kind.
2505         * tree-pretty-print.c (dump_generic_node): Handle
2506         annot_expr_parallel_kind.
2507         * tree-cfg.c (replace_loop_annotate_in_block): Likewise.
2508         * gimplify.c (gimple_boolify): Likewise.
2510 2017-11-17  Igor Tsimbalist  <igor.v.tsimbalist@intel.com>
2512         * config.gcc (extra_headers): Add cet.h for x86 targets.
2513         * config/i386/cet.h: New file.
2514         * doc/install.texi: Add --enable-cet/--disable-cet.
2516 2017-11-17  Richard Biener  <rguenther@suse.de>
2518         PR tree-optimization/83017
2519         * tree-parloops.c (MIN_PER_THREAD): Use --param parloops-min-per-thread.
2520         (gen_parallel_loop): Properly count iterations.
2521         (parallelize_loops): Handle loop->can_be_parallel independent
2522         of flag_loop_parallelize_all.  Make static profitability test match
2523         the runtime one.
2524         * params.def (PARAM_PARLOOPS_MIN_PER_THREAD): New.
2525         * invoke.texi (parloops-min-per-thread): Document.
2527 2017-11-17  Vineet Gupta  <vgupta@synopsys.com>
2529         * config/arc/linux.h: GLIBC_DYNAMIC_LINKER update per glibc
2530         upstreaming review comments.
2532 2017-11-17  Tamar Christina  <tamar.christina@arm.com>
2534         * expr.c (copy_blkmode_to_reg): Fix bitsize for targets
2535         with fast unaligned access.
2536         * doc/sourcebuild.texi (word_mode_no_slow_unalign): New.
2538 2017-11-17  Thomas Preud'homme  <thomas.preudhomme@arm.com>
2540         * config/arm/arm.c (cmse_nonsecure_entry_clear_before_return): Allocate
2541         to_clear_arg_regs_bitmap to the same size as to_clear_bitmap.
2543 2017-11-17  Richard Biener  <rguenther@suse.de>
2545         * tree-ssa-pre.c (phi_translate_1): Remove redundant constant
2546         folding of references.
2548 2017-11-17  Qing Zhao  <qing.zhao@oracle.com>
2550         PR middle-end/78809
2551         * gimple-fold.c (gimple_fold_builtin_string_compare): Add handling
2552         of replacing call to strncmp with corresponding call to strcmp when
2553         meeting conditions.
2555 2017-11-17  Sergey Shalnov  <Sergey.Shalnov@intel.com>
2557         * config/i386/x86-tune.def (X86_TUNE_AVX256_OPTIMAL): Add tuning
2558         option prefer-avx256 for skylake-avx512 configuration.
2559         * config/i386/i386.c (ix86_option_override_internal): Ditto.
2560         (get_builtin_code_for_version): Ditto.
2562 2017-11-17  Chung-Ju Wu  <jasonwucj@gmail.com>
2563             Monk Chiang  <sh.chiang04@gmail.com>
2565         * config/nds32/nds32.h (FIRST_PSEUDO_REGISTER): Modify.
2566         (FIXED_REGISTERS): Reserve more register numbers.
2567         (CALL_USED_REGISTERS): Likewise.
2568         (REG_ALLOC_ORDER): Likewise.
2569         (REG_CLASS_CONTENTS): Likewise.
2570         (REGISTER_NAMES): Likewise.
2572 2017-11-17  Chung-Ju Wu  <jasonwucj@gmail.com>
2573             Kito Cheng  <kito.cheng@gmail.com>
2575         * config/nds32/nds32-modes.def: Add vector mode V4QI V2HI V8QI V4HI
2576         V2SI.
2577         * config/nds32/iterators.md: Add vector mode iterators and attributes.
2579 2017-11-16  Steven Munroe  <munroesj@gcc.gnu.org>
2581         * config/rs6000/mmintrin.h (_mm_add_pi32[_ARCH_PWR]): Correct
2582         parameter list for vec_splats.
2584 2017-11-16  Joseph Myers  <joseph@codesourcery.com>
2586         * doc/invoke.texi (-std=c17): Refer to 2018 expected publication
2587         date of C17.
2588         (-std=c18, -std=iso9899:2018, -std=gnu18): Document option aliases.
2590 2017-11-16  Thomas Koenig  <tkoenig@gcc.gnu.org>
2592         PR bootstrap/82856
2593         * doc/install.texi: Document incompatibility of Perl >=5.6.26
2594         with the required version of automake 1.11.6.
2596 2017-11-16  Pat Haugen  <pthaugen@us.ibm.com>
2598         * rs6000/power9.md (power9fpdiv): New automaton and cpu_unit defined
2599         for it.
2600         (DU_C2_3_power9): Correct reservation combinations.
2601         (FP_DIV_power9, VEC_DIV_power9): New.
2602         (power9-alu): Split out rotate/shift...
2603         (power9-rot): ...to here, correct dispatch resource.
2604         (power9-cracked-alu, power9-mul, power9-mul-compare): Correct dispatch
2605         resource.
2606         (power9-fp): Correct latency.
2607         (power9-sdiv): Add div/sqrt resource.
2608         (power9-ddiv): Correct latency, add div/sqrt resource.
2609         (power9-sqrt, power9-dsqrt): Add div/sqrt resource.
2610         (power9-vecfdiv, power9-vecdiv): Correct latency, add div/sqrt
2611         resource.
2612         (power9-qpdiv, power9-qpmul): Adjust resource usage.
2614 2017-11-15  Michael Meissner  <meissner@linux.vnet.ibm.com>
2616         * config/rs6000/rs6000.c (rs6000_expand_builtin): Do not do the
2617         switch statement mapping KF built-ins to TF built-ins if we don't
2618         have the proper ISA 3.0 assembler support.
2620 2017-11-16  Jan Hubicka  <hubicka@ucw.cz>
2622         * tree-emutls.c (lower_emutls_data): Remove unused bb_freq.
2623         (lower_emutls_function_body): Do not compute it.
2625 2017-11-16  Jan Hubicka  <hubicka@ucw.cz>
2627         * ipa-split.c (split_bb_info): Turn time to sreal.
2628         (split_point): Likewise.
2629         (dump_split_point): Likewise.
2630         (fine_split_points): Likewise.
2631         (execute_split_functions): Only zero split_bbs; turn time to sreals.
2633 2017-11-16  Jan Hubicka  <hubicka@ucw.cz>
2635         * ipa-fnsummary.c (analyze_function_body): Accumulate time consistently
2636         in sreal.
2638 2017-11-16  Jan Hubicka  <hubicka@ucw.cz>
2640         * predict.c (combine_predictions_for_bb): Preserve zero predicted
2641         edges.
2642         (expensive_function_p): Remove useless assert.
2643         (determine_unlikely_bbs): Propagate also forward; determine cold blocks
2645 2017-11-16  Martin Sebor  <msebor@redhat.com>
2647         PR tree-optimization/82588
2648         PR tree-optimization/82583
2649         * tree-vrp.c (check_array_ref): Handle flexible array members,
2650         string literals, and inner indices.
2651         (search_for_addr_array): Add detail to diagnostics.
2653 2017-11-16  Nathan Sidwell  <nathan@acm.org>
2655         PR c++/82836
2656         PR c++/82737
2657         * tree.h (COPY_DECL_RTL): Rename parms for clarity.
2658         (SET_DECL_ASSEMBLER_NAME): Forward to
2659         overwrite_decl_assembler_name.
2660         (COPY_DECL_ASSEMBLER_NAME): Rename parms for clarity.
2661         (overwrite_decl_assembler_name): Declare.
2662         * tree.c (overwrite_decl_assembler_name): New.
2663         * langhooks-def.h (lhd_overwrite_decl_assembler_name): Declare.
2664         (LANG_HOOKS_OVERWRITE_DECL_ASSEMBLER_NAME): Provide default.
2665         (LANG_HOOKS_INITIALIZER): Add it.
2666         * langhooks.h (struct lang_hooks): Add overwrite_decl_assembler_name.
2667         * langhooks.c (lhd_set_decl_assembler_name): Use
2668         SET_DECL_ASSEMBLER_NAME.
2669         (lhd_overwrite_decl_assembler_name): Default implementation.
2671 2017-11-16  Wilco Dijkstra  <wdijkstr@arm.com>
2672             Jackson Woodruff  <jackson.woodruff@arm.com>
2674         PR tree-optimization/71026
2675         * match.pd: Canonicalize constant multiplies in division.
2677 2017-11-16  Wilco Dijkstra  <wdijkstr@arm.com>
2679         * opts.c (default_options_table): Add OPT_fomit_frame_pointer entry.
2680         * common/config/alpha/alpha-common.c (TARGET_OPTION_OPTIMIZATION_TABLE):
2681         Remove OPT_fomit_frame_pointer entry.
2682         * common/config/arc/arc-common.c: Likewise.
2683         * common/config/arm/arm-common.c: Likewise.
2684         * common/config/avr/avr-common.c: Likewise.
2685         * common/config/c6x/c6x-common.c: Likewise.
2686         * common/config/cr16/cr16-common.c: Likewise.
2687         * common/config/cris/cris-common.c: Likewise.
2688         * common/config/epiphany/epiphany-common.c: Likewise.
2689         * common/config/fr30/fr30-common.c: Likewise.
2690         * common/config/frv/frv-common.c: Likewise.
2691         * common/config/ia64/ia64-common.c: Likewise.
2692         * common/config/iq2000/iq2000-common.c: Likewise.
2693         * common/config/lm32/lm32-common.c: Likewise.
2694         * common/config/m32r/m32r-common.c: Likewise.
2695         * common/config/mcore/mcore-common.c: Likewise.
2696         * common/config/microblaze/microblaze-common.c: Likewise.
2697         * common/config/mips/mips-common.c: Likewise.
2698         * common/config/mmix/mmix-common.c: Likewise.
2699         * common/config/mn10300/mn10300-common.c: Likewise.
2700         * common/config/nios2/nios2-common.c: Likewise.
2701         * common/config/pa/pa-common.c: Likewise.
2702         * common/config/pdp11/pdp11-common.c: Likewise.
2703         * common/config/powerpcspe/powerpcspe-common.c: Likewise.
2704         * common/config/riscv/riscv-common.c: Likewise.
2705         * common/config/rs6000/rs6000-common.c: Likewise.
2706         * common/config/rx/rx-common.c: Likewise.
2707         * common/config/s390/s390-common.c: Likewise.
2708         * common/config/sh/sh-common.c: Likewise.
2709         * common/config/sparc/sparc-common.c: Likewise.
2710         * common/config/tilegx/tilegx-common.c: Likewise.
2711         * common/config/tilepro/tilepro-common.c: Likewise.
2712         * common/config/v850/v850-common.c: Likewise.
2713         * common/config/visium/visium-common.c: Likewise.
2714         * common/config/xstormy16/xstormy16-common.c: Likewise.
2715         * common/config/xtensa/xtensa-common.c: Likewise.
2716         * invoke.texi (-fomit-frame-pointer): Update documentation.
2718 2017-11-16  Jan Hubicka  <hubicka@ucw.cz>
2720         * tree-cfg.c (gimple_find_sub_bbs): Do not compute freq.
2722 2017-11-14  Jan Hubicka  <hubicka@ucw.cz>
2724         * cfg.c (scale_bbs_frequencies_int,
2725         cale_bbs_frequencies_gcov_type): Remove.
2726         * cfg.h (scale_bbs_frequencies_int,
2727         cale_bbs_frequencies_gcov_type): Remove.
2729 2017-11-14  Jan Hubicka  <hubicka@ucw.cz>
2731         * tree-ssa-loop-manip.c
2732         (scale_dominated_blocks_in_loop): Update to profile counts.
2733         (tree_transform_and_unroll_loop): Likewise.
2735 2017-11-14  Jan Hubicka  <hubicka@ucw.cz>
2737         * tree-vect-loop-manip.c (vect_do_peeling): Do not use
2738         scale_bbs_frequencies_int.
2740 2017-11-14  Jan Hubicka  <hubicka@ucw.cz>
2742         * final.c (compute_alignments): Use counts rather than frequencies.
2744 2017-11-14  Jan Hubicka  <hubicka@ucw.cz>
2746         * cfgloopanal.c: Include sreal.h
2747         (average_num_loop_insns): Use counts and sreal for accounting.
2749 2017-11-14  Jan Hubicka  <hubicka@ucw.cz>
2751         * cfgloopmanip.c (duplicate_loop_to_header_edge): Cleanup profile
2752         manipulation.
2754 2017-11-16  Chung-Ju Wu  <jasonwucj@gmail.com>
2755             Kito Cheng  <kito.cheng@gmail.com>
2757         * config/nds32/constraints.md: Provide more constraints.
2758         * config/nds32/nds32.h (enum reg_class, REG_CLASS_NAMES,
2759         REG_CLASS_CONTENTS): Define R5_REG, R8_REG, and FRAME_POINTER_REG to
2760         support constraints usage.
2762 2017-11-16  Chung-Ju Wu  <jasonwucj@gmail.com>
2764         * config/nds32/constants.md (UNSPEC_VOLATILE_FUNC_RETURN): Remove.
2766 2017-11-16  Chung-Ju Wu  <jasonwucj@gmail.com>
2767             Kito Cheng  <kito.cheng@gmail.com>
2769         * config/nds32/nds32.opt: Add mext-perf, mext-perf2, mext-string.
2770         * config/nds32/nds32.opt: Refine the layout.
2771         * config/nds32/nds32.c (TARGET_EXT_PERF, TARGET_EXT_PERF2,
2772         TARGET_EXT_STRING): Support new options.
2773         * config/nds32/nds32.h: Likewise.
2774         * config/nds32/nds32.md: Likewise.
2775         * config/nds32/nds32-predicates.c: Likewise.
2776         * config/nds32/constraints.md: Likewise.
2777         * common/config/nds32/nds32-common.c: Likewise.
2779 2017-11-16  Julia Koval  <julia.koval@intel.com>
2781         PR target/82983
2782         * config/i386/gfniintrin.h: Add sse check.
2783         * config/i386/i386.c (ix86_expand_builtin): Fix gfni check.
2785 2017-11-16  Julia Koval  <julia.koval@intel.com>
2787         * common/config/i386/i386-common.c (OPTION_MASK_ISA_AVX512VBMI2_SET,
2788         OPTION_MASK_ISA_AVX512VBMI2_UNSET): New.
2789         (ix86_handle_option): Handle -mavx512vbmi2.
2790         * config/i386/cpuid.h: Add bit_AVX512VBMI2.
2791         * config/i386/driver-i386.c (host_detect_local_cpu): Handle new bit.
2792         * config/i386/i386-c.c (__AVX512VBMI2__): New.
2793         * config/i386/i386.c (ix86_target_string): Handle -mavx512vbmi2.
2794         (ix86_valid_target_attribute_inner_p): Ditto.
2795         * config/i386/i386.h (TARGET_AVX512VBMI2, TARGET_AVX512VBMI2_P): New.
2796         * config/i386/i386.opt (mavx512vbmi2): New option.
2797         * doc/invoke.texi: Add new option.
2799 2017-11-16  Julia Koval  <julia.koval@intel.com>
2801         * config/i386/gfniintrin.h (_mm_gf2p8mul_epi8, _mm256_gf2p8mul_epi8,
2802         _mm_mask_gf2p8mul_epi8, _mm_maskz_gf2p8mul_epi8,
2803         _mm256_mask_gf2p8mul_epi8, _mm256_maskz_gf2p8mul_epi8,
2804         _mm512_mask_gf2p8mul_epi8, _mm512_maskz_gf2p8mul_epi8,
2805         _mm512_gf2p8mul_epi8): New intrinsics.
2806         * config/i386/i386-builtin-types.def
2807         (V64QI_FTYPE_V64QI_V64QI): New type.
2808         * config/i386/i386-builtin.def (__builtin_ia32_vgf2p8mulb_v64qi,
2809         __builtin_ia32_vgf2p8mulb_v64qi_mask, __builtin_ia32_vgf2p8mulb_v32qi,
2810         __builtin_ia32_vgf2p8mulb_v32qi_mask, __builtin_ia32_vgf2p8mulb_v16qi,
2811         __builtin_ia32_vgf2p8mulb_v16qi_mask): New builtins.
2812         * config/i386/sse.md (vgf2p8mulb_*): New pattern.
2813         * config/i386/i386.c (ix86_expand_args_builtin): Handle new type.
2815 2017-11-15  Uros Bizjak  <ubizjak@gmail.com>
2817         * config/i386/i386.c (x86_print_call_or_nop): Emit 5 byte nop
2818         explicitly as a stream of bytes.
2820 2017-11-15  Bill Schmidt  <wschmidt@linux.vnet.ibm.com>
2822         * config/rs6000/altivec.h (vec_xst_be): New #define.
2823         * config/rs6000/altivec.md (altivec_vperm_<mode>_direct): Rename
2824         and externalize from *altivec_vperm_<mode>_internal.
2825         * config/rs6000/rs6000-builtin.def (XL_BE_V16QI): Remove macro
2826         instantiation.
2827         (XL_BE_V8HI): Likewise.
2828         (XL_BE_V4SI): Likewise.
2829         (XL_BE_V4SI): Likewise.
2830         (XL_BE_V2DI): Likewise.
2831         (XL_BE_V4SF): Likewise.
2832         (XL_BE_V2DF): Likewise.
2833         (XST_BE): Add BU_VSX_OVERLOAD_X macro instantiation.
2834         * config/rs6000/rs6000-c.c (altivec_overloaded_builtins): Correct
2835         all array entries with these keys: VSX_BUILTIN_VEC_XL,
2836         VSX_BUILTIN_VEC_XL_BE, VSX_BUILTIN_VEC_XST.  Add entries for key
2837         VSX_BUILTIN_VEC_XST_BE.
2838         * config/rs6000/rs6000.c (altivec_expand_xl_be_builtin): Remove.
2839         (altivec_expand_builtin): Remove handling for VSX_BUILTIN_XL_BE_*
2840         built-ins.
2841         (altivec_init_builtins): Replace conditional calls to def_builtin
2842         for __builtin_vsx_ld_elemrev_{v8hi,v16qi} and
2843         __builtin_vsx_st_elemrev_{v8hi,v16qi} based on TARGET_P9_VECTOR
2844         with unconditional calls.  Remove calls to def_builtin for
2845         __builtin_vsx_le_be_<mode>.  Add a call to def_builtin for
2846         __builtin_vec_xst_be.
2847         * config/rs6000/vsx.md (vsx_ld_elemrev_v8hi): Convert define_insn
2848         to define_expand, and add alternate RTL generation for P8.
2849         (*vsx_ld_elemrev_v8hi_internal): New define_insn based on
2850         vsx_ld_elemrev_v8hi.
2851         (vsx_ld_elemrev_v16qi): Convert define_insn to define_expand, and
2852         add alternate RTL generation for P8.
2853         (*vsx_ld_elemrev_v16qi_internal): New define_insn based on
2854         vsx_ld_elemrev_v16qi.
2855         (vsx_st_elemrev_v8hi): Convert define_insn
2856         to define_expand, and add alternate RTL generation for P8.
2857         (*vsx_st_elemrev_v8hi_internal): New define_insn based on
2858         vsx_st_elemrev_v8hi.
2859         (vsx_st_elemrev_v16qi): Convert define_insn to define_expand, and
2860         add alternate RTL generation for P8.
2861         (*vsx_st_elemrev_v16qi_internal): New define_insn based on
2862         vsx_st_elemrev_v16qi.
2864 2017-11-15  H.J. Lu  <hongjiu.lu@intel.com>
2866         PR target/82990
2867         * config/i386/i386.c (pass_insert_vzeroupper::gate): Remove
2868         TARGET_AVX512ER check.
2869         (ix86_option_override_internal): Set MASK_VZEROUPPER if
2870         neither -mzeroupper nor -mno-zeroupper is used and
2871         TARGET_EMIT_VZEROUPPER is set.
2872         * config/i386/i386.h (TARGET_EMIT_VZEROUPPER): New.
2873         * config/i386/x86-tune.def: Add X86_TUNE_EMIT_VZEROUPPER.
2875 2017-11-15  Will Schmidt  <will_schmidt@vnet.ibm.com>
2877         * config/rs6000/rs6000.c (rs6000_gimple_fold_builtin): Add support for
2878         folding of vector compares.
2879         (fold_build_vec_cmp): New helper function.
2880         (fold_compare_helper): New helper function.
2881         (builtin_function_type): Add compare builtins to the list of functions
2882         having unsigned arguments.  Cosmetic updates to comment indentation.
2883         * config/rs6000/vsx.md (vcmpneb, vcmpneh, vcmpnew): Update to specify
2884         the not+eq combination.
2886 2017-11-15  Bin Cheng  <bin.cheng@arm.com>
2888         PR tree-optimization/82726
2889         PR tree-optimization/70754
2890         * tree-predcom.c (order_drefs_by_pos): New function.
2891         (combine_chains): Move code setting has_max_use_after to...
2892         (try_combine_chains): ...here.  New parameter.  Sort combined chains
2893         according to position information.
2894         (tree_predictive_commoning_loop): Update call to above function.
2895         (update_pos_for_combined_chains, pcom_stmt_dominates_stmt_p): New.
2897 2017-11-15  Bin Cheng  <bin.cheng@arm.com>
2899         PR tree-optimization/82726
2900         Revert
2901         2017-01-23  Bin Cheng  <bin.cheng@arm.com>
2903         PR tree-optimization/70754
2904         * tree-predcom.c (stmt_combining_refs): New parameter INSERT_BEFORE.
2905         (reassociate_to_the_same_stmt): New parameter INSERT_BEFORE.  Insert
2906         combined stmt before it if not NULL.
2907         (combine_chains): Process refs reversely and compute dominance point
2908         for root ref.
2910         Revert
2911         2017-02-23  Bin Cheng  <bin.cheng@arm.com>
2913         PR tree-optimization/79663
2914         * tree-predcom.c (combine_chains): Process refs in reverse order
2915         only for ZERO length chains, and add explaining comment.
2917 2017-11-15  Tamar Christina  <tamar.christina@arm.com>
2919         * config/arm/arm-cpus.in (armv8_3, ARMv8_3a, armv8.3-a): New
2920         * config/arm/arm-tables.opt (armv8.3-a): Regenerated.
2921         * doc/invoke.texi (ARM Options): Add armv8.3-a.
2923 2017-11-15  Tamar Christina  <tamar.christina@arm.com>
2925         * config/arm/arm.h (TARGET_DOTPROD): Add arm_arch8_2.
2927 2017-11-15  Martin Liska  <mliska@suse.cz>
2929         * tree-cfg.c (pass_warn_function_return::execute):
2930         Compare warn_return_type for greater than zero.
2932 2017-11-15  Sebastian Peryt  <sebastian.peryt@intel.com>
2934         PR target/82941
2935         PR target/82942
2936         * config/i386/i386.c (pass_insert_vzeroupper): Modify gate condition
2937         to return true on Xeon and not on Xeon Phi.
2938         (ix86_check_avx256_register): Changed to ...
2939         (ix86_check_avx_upper_register): ... this. Add extra check for
2940         VALID_AVX512F_REG_OR_XI_MODE.
2941         (ix86_avx_u128_mode_needed): Changed
2942         ix86_check_avx256_register to ix86_check_avx_upper_register.
2943         (ix86_check_avx256_stores): Changed to ...
2944         (ix86_check_avx_upper_stores): ... this. Changed
2945         ix86_check_avx256_register to ix86_check_avx_upper_register.
2946         (ix86_avx_u128_mode_after): Changed
2947         avx_reg256_found to avx_upper_reg_found. Changed
2948         ix86_check_avx256_stores to ix86_check_avx_upper_stores.
2949         (ix86_avx_u128_mode_entry): Changed
2950         ix86_check_avx256_register to ix86_check_avx_upper_register.
2951         (ix86_avx_u128_mode_exit): Ditto.
2952         * config/i386/i386.h: (host_detect_local_cpu): New define.
2954 2017-11-15  Dominik Infuehr  <dominik.infuehr@theobroma-systems.com>
2956         * config/arm/xgene1.md (xgene1): Split into automatons
2957         xgene1_main, xgene1_decoder, xgene1_div, xgene1_simd.
2958         (xgene1_f_load): Adjust reservations and/or types.
2959         (xgene1_f_store): Likewise.
2960         (xgene1_load_pair): Likewise.
2961         (xgene1_store_pair): Likewise.
2962         (xgene1_fp_load1): Likewise.
2963         (xgene1_load1): Likewise.
2964         (xgene1_store1): Likewise.
2965         (xgene1_move): Likewise.
2966         (xgene1_alu): Likewise.
2967         (xgene1_simd): Likewise.
2968         (xgene1_bfm): Likewise.
2969         (xgene1_neon_load1): Likewise.
2970         (xgene1_neon_store1): Likewise.
2971         (xgene1_neon_logic): Likewise.
2972         (xgene1_neon_st1): Likewise.
2973         (xgene1_neon_ld1r): Likewise.
2974         (xgene1_alu_cond): Added.
2975         (xgene1_shift_reg): Likwise.
2976         (xgene1_bfx): Likewise.
2977         (xgene1_mul): Split into xgene1_mul32, xgene1_mul64.
2979 2017-11-15  Jakub Jelinek  <jakub@redhat.com>
2981         PR target/82981
2982         * internal-fn.c: Include gimple-ssa.h, tree-phinodes.h and
2983         ssa-iterators.h.
2984         (can_widen_mult_without_libcall): New function.
2985         (expand_mul_overflow): If only checking unsigned mul overflow,
2986         not result, and can do efficiently MULT_HIGHPART_EXPR, emit that.
2987         Don't use WIDEN_MULT_EXPR if it would involve a libcall, unless
2988         no other way works.  Add MULT_HIGHPART_EXPR + MULT_EXPR support.
2989         (expand_DIVMOD): Formatting fix.
2990         * expmed.h (expand_mult): Add NO_LIBCALL argument.
2991         * expmed.c (expand_mult): Likewise.  Use OPTAB_WIDEN rather
2992         than OPTAB_LIB_WIDEN if NO_LIBCALL is true, and allow it to fail.
2994         PR tree-optimization/82977
2995         * tree-ssa-strlen.c (strlen_optimize_stmt): Pass a reference to a copy
2996         constructed temporary to strlen_to_stridx.put.
2998 2017-11-15  Martin Liska  <mliska@suse.cz>
3000         * configure.ac: Remove -fkeep-inline-functions from coverage_flags.
3001         * configure: Regenerate.
3003 2017-11-15  Martin Liska  <mliska@suse.cz>
3005         PR target/82927
3006         * config/sh/sh-mem.cc: Use proper probability for
3007         REG_BR_PROB_NOTE.
3009 2017-11-14  Jeff Law  <law@redhat.com>
3011         * explow.c (anti_adjust_stack_and_probe_stack_clash): Avoid probing
3012         the red zone for stack_clash_protection_final_dynamic_probe targets
3013         when the total dynamic stack size is zero bytes.
3015         * tree-ssa-threadupdate.c (thread_through_all_blocks): Thread
3016         blocks is post order.
3018 2017-11-15  Alexandre Oliva <aoliva@redhat.com>
3020         * dumpfile.h (TDF_COMPARE_DEBUG): New.
3021         * final.c (rest_of_clean_state): Set it for the
3022         -fcompare-debug dump.
3023         * tree-pretty-print.c (dump_generic_node): Omit OBJ_TYPE_REF
3024         class when TDF_COMPARE_DEBUG is set.
3026         * dwarf2out.c (gen_producer_string): Discard
3027         OPT_fcompare_debug.
3029 2017-11-15  Joseph Myers  <joseph@codesourcery.com>
3031         PR c/81156
3032         * doc/extend.texi (Other Builtins): Document __builtin_tgmath.
3033         * ginclude/tgmath.h (__tg_cplx, __tg_ldbl, __tg_dbl, __tg_choose)
3034         (__tg_choose_2, __tg_choose_3, __TGMATH_REAL_1_2)
3035         (__TGMATH_REAL_2_3): Remove macros.
3036         (__TGMATH_CPLX, __TGMATH_CPLX_2, __TGMATH_REAL, __TGMATH_REAL_2)
3037         (__TGMATH_REAL_3, __TGMATH_CPLX_ONLY): Define using
3038         __builtin_tgmath.
3039         (frexp, ldexp, nexttoward, scalbn, scalbln): Define using
3040         __TGMATH_REAL_2.
3041         (remquo): Define using __TGMATH_REAL_3.
3043 2017-11-14  Jeff Law  <law@redhat.com>
3045         * vr-values.c: New file with contents extracted from tree-vrp.c.
3046         * Makefile.in (OBJS): Add vr-values.o
3047         * tree-vrp.h (set_value_range_to_nonnull): Prototype.
3048         (set_value_range, set_and_canonicalize_value_range): Likewise.
3049         (vrp_bitmap_equal_p, range_is_nonnull): Likewise.
3050         (value_range_constant_singleton, symbolic_range_p): Likewise.
3051         (compare_values, compare_values_warnv, vrp_val_is_min): Likewise.
3052         (vrp_val_is_max, copy_value_range, set_value_range_to_value): Likewise.
3053         (extract_range_from_binary_expr_1, vrp_val_min, vrp_val_max): Likewise.
3054         (set_value_range_to_null, range_int_cst_p, opreand_less_p): Likewise.
3055         (find_case_label_range, find_case_label_index): Likewise.
3056         (zero_nonzero_bits_from_vr, overflow_comparison_p): Likewise.
3057         (range_int_cst_singleton_p, value_inside_range): Likewise.
3058         (get_single_symbol): Likewise.
3059         (switch_update): Move structure definition here.
3060         (to_remove_edges, to_update_switch_stmts): Provide externs.
3061         * tree-vrp.c: Move all methods for vr-values class to vr-values.c
3062         (vrp_val_max, vrp_val_min, vrp_val_is_max): Make externally visible.
3063         (vrp_val_is_min, set_value_range): Likewise.
3064         (set_and_canonicalize_value_range, copy_value_range): Likewise.
3065         (set_value_range_to_value, set_value_range_to_nonnull): Likewise.
3066         (set_value_range_to_null, vrp_bitmap_equal_p): Likewise.
3067         (range_is_nonnull, range_int_cst_p): Likewwise.
3068         (range_int_cst_singleton_p, symbolic_range_p): Likewise.
3069         (get_single_symbol, operand_less_p): Likewise
3070         (compare_values_warnv, compare_values): Likewise.
3071         (value_inside_range, value_range_constant_singleton): Likewise.
3072         (zero_nonzero_bitgs_from_vr): Likewise.
3073         (extract_range_from_binary_expr_1): Likewise.
3074         (overflow_comparison_p): Likewise.
3075         (to_remove_edges, to_update_switch_stmts): Likewise.
3076         (find_case_label-index, find_case_label_range): Likewise.
3077         (switch_update, set_value_range_to_nonnegative): Remove.
3078         (set_value_range_to_truthvalue): Likewise.
3079         (symbolic_range_based_on_p, gimple_assign_nonzero_p): Likewise.
3080         (gimple_stmt_nonzero_p, compare_ranges): Likewise.
3081         (compare_range_with_value, vrp_valueize, vrp_valueize_1): Likewise.
3082         (find_case_label_ranges, test_for_singularity): Likewise.
3083         (range_fits_type_p, simplify_conversion_using_ranges): LIkewise.
3084         (x_vr_values): Move to its remaining use site.
3086 2017-11-10  Jeff Law  <law@redhat.com>
3088         * vr-values.h (VR_INITIALIZER): Move #define here.
3089         * gimple-ssa-evrp.c: New file with contents extracted from tree-vrp.c
3090         * Makefile.in (OBJS): Add tree-evrp.o
3091         * tree-vrp.h (assert_info): Move structure definition here.
3092         (set_value_range_to_varying): Prototype.
3093         (vrp_operand_equal_p, range_includes_zero_p): Likewise.
3094         (infer_value_range, register_edge_assert_for): Likewise.
3095         (stmt_interesting_for_vrp): Likewise.
3096         * tree-vrp.c: Move all methods for evrp class into gimple-ssa-evrp.c.
3097         (set_value_range_to_varying): No longer static.
3098         (vrp_operand_equal_p, range_includes_zero_p): Likewise.
3099         (infer_value_range, register_edge_assert_for): Likewise.
3101 2017-11-14  Michael Meissner  <meissner@linux.vnet.ibm.com>
3103         * config/rs6000/rs6000.md (bswapdi2): On 32-bit ISA 3.0, don't
3104         generate the XXBRD instruction.
3106         * config/rs6000/rs6000-c.c (is_float128_p): New helper function.
3107         (rs6000_builtin_type_compatible): Treat _Float128 and long double
3108         as being compatible if -mabi=ieeelongdouble.
3109         * config/rs6000/rs6000-builtin.def (BU_FLOAT128_HW_1): New macros
3110         to setup float128 built-ins with hardware support.
3111         (BU_FLOAT128_HW_2): Likewise.
3112         (BU_FLOAT128_HW_3): Likewise.
3113         (BU_FLOAT128_HW_VSX_1): Likewise.
3114         (BU_FLOAT128_HW_VSX_2): Likewise.
3115         (scalar_extract_expq): Change float128 built-in functions to
3116         accommodate having both KFmode and TFmode functions.  Use the
3117         KFmode variant as the default.
3118         (scalar_extract_sigq): Likewise.
3119         (scalar_test_neg_qp): Likewise.
3120         (scalar_insert_exp_q): Likewise.
3121         (scalar_insert_exp_qp): Likewise.
3122         (scalar_test_data_class_qp): Likewise.
3123         (sqrtf128_round_to_odd): Delete processing the round to odd
3124         built-in functions as special built-in functions, and define them
3125         as float128 built-ins.  Use the KFmode variant as the default.
3126         (truncf128_round_to_odd): Likewise.
3127         (addf128_round_to_odd): Likewise.
3128         (subf128_round_to_odd): Likewise.
3129         (mulf128_round_to_odd): Likewise.
3130         (divf128_round_to_odd): Likewise.
3131         (fmaf128_round_to_odd): Likewise.
3132         * config/rs6000/rs6000.c (rs6000_expand_binop_builtin): Add
3133         support for KFmode and TFmode xststdcqp calls.
3134         (rs6000_expand_builtin): If long double is IEEE 128-bit floating
3135         point, switch the built-in handlers for the get/set float128
3136         exponent, get float128 mantissa, float128 test built-ins, and the
3137         float128 round to odd built-in functions.  Eliminate creating the
3138         float128 round to odd built-in functions as special built-ins.
3139         (rs6000_init_builtins): Eliminate special creation of the float128
3140         round to odd built-in functions.
3141         * config/rs6000/vsx.md (xsxexpqp_<mode>): Change float128 built-in
3142         function insns to support both TFmode and KFmode variants.
3143         (xsxsigqp_<mode>): Likewise.
3144         (xsiexpqpf_<mode>): Likewise.
3145         (xsiexpqp_<mode>): Likewise.
3146         (xststdcqp_<mode>): Likewise.
3147         (xststdcnegqp_<mode>): Likewise.
3148         (xststdcqp_<mode>): Likewise.
3150 2017-11-14  Jan Hubicka  <hubicka@ucw.cz>
3152         * tree-ssa-threadupdate.c (compute_path_counts): Remove
3153         unused path_in_freq_ptr parameter.
3154         (ssa_fix_duplicate_block_edges): Do not pass around path_in_freq
3156 2017-11-14  Jan Hubicka  <hubicka@ucw.cz>
3158         * ipa-inline.c (edge_badness): Dump sreal frequency.
3159         (compute_inlined_call_time): Match natural implementaiton ...
3160         * ipa-fnsummary.c (estimate_edge_size_and_time): ... here; remove
3161         forgotten division by CGRAPH_FREQ_BASE.
3163 2017-11-14  Rainer Orth  <ro@CeBiTec.Uni-Bielefeld.DE>
3165         * config.gcc (*-*-solaris2*): Enable default_use_cxa_atexit since
3166         Solaris 11.  Update comment.
3167         * configure.ac (gcc_cv_ld_pid): Adapt comment for Solaris 12
3168         renaming.
3169         * config/sol2.h (STARTFILE_SPEC): Likewise.
3170         * configure: Regenerate.
3172 2017-11-14  Carl Love  <cel@us.ibm.com>
3174         * config/rs6000/rs6000.c (swap_endian_selector_for_mode): Remove
3175         le_ and be_ prefixes to swap* variables.  Remove
3176         if (VECTOR_ELT_ORDER_BIG) statement. Remove E_V16QImode case
3177         statements.
3179 2017-11-14  Jason Merrill  <jason@redhat.com>
3181         Support GTY((cache)) on hash_map.
3182         * hash-traits.h (ggc_remove): Add ggc_maybe_mx member function.
3183         (ggc_cache_remove): Override it instead of ggc_mx.
3184         * hash-table.h (gt_ggc_mx): Call it instead of ggc_mx.
3185         (gt_cleare_cache): Call ggc_mx instead of gt_ggc_mx.
3186         * hash-map-traits.h (simple_hashmap_traits): Add maybe_mx member.
3187         (simple_cache_map_traits): Override maybe_mx.
3188         * hash-map.h (hash_entry): Add ggc_maybe_mx and keep_cache_entry.
3189         (hash_map): Friend gt_cleare_cache.
3190         (gt_cleare_cache): New.
3191         * tree.h (tree_cache_traits): New hash_map traits class.
3192         (tree_cache_map): New typedef.
3194 2017-11-14  Richard Biener  <rguenther@suse.de>
3196         * tree-cfgcleanup.c (cleanup_control_expr_graph): Remove first_p
3197         paramter and handling.
3198         (cleanup_control_flow_bb): Likewise.
3199         (cleanup_control_flow_pre): New helper performing a DFS walk
3200         to call cleanup_control_flow_bb in PRE order.
3201         (cleanup_tree_cfg_1): Do the first phase of cleanup_control_flow_bb
3202         via cleanup_control_flow_pre.
3204 2017-11-14  James Greenhalgh  <james.greenhalgh@arm.com>
3206         * config/aarch64/aarch64-simd.md
3207         (aarch64_simd_bsl<mode>_internal): Remove DImode.
3208         (*aarch64_simd_bsl<mode>_alt): Likewise.
3209         (aarch64_simd_bsldi_internal): New.
3210         (aarch64_simd_bsldi_alt): Likewise.
3212 2017-11-13  Jan Hubicka  <hubicka@ucw.cz>
3214         * tracer.c (better_p): Do not compare frequencies.
3215         * reg-stack.c (better_edge): Likewise.
3216         * shrink-wrap.c (try_shrink_wrapping): Do not convert to gcov counts
3217         and back.
3219 2017-11-13  Jan Hubicka  <hubicka@ucw.cz>
3221         * auto-profile.c (afdo_annotate_cfg): Use update_max_bb_count.
3222         * cgraphunit.c (cgraph_node::expand_thunk): Use update_max_bb_count.
3223         * ipa-utils.c (ipa_merge_profiles): Use update_max_bb_count.
3224         * lto-streamer-in.c (input_function): Use update_max_bb_count.
3225         * omp-expand.c (expand_omp_taskreg): Use update_max_bb_count.
3226         * predict.c (maybe_hot_frequency_p): Inline to ...
3227         (maybe_hot_count_p): ... here; rewrite to counts.
3228         (counts_to_freqs): Rename to ...
3229         (update_max_bb_count): ... this one.
3230         (expensive_function_p): Use counts.
3231         (estimate_bb_frequencies): Update.
3232         (rebuild_frequencies): Update.
3233         * predict.h (counts_to_freqs): Rename to ...
3234         (update_max_bb_count): ... this one.
3235         * profile.c (compute_branch_probabilities): Add debug info
3236         * tree-inline.c (expand_call_inline): Update debug info.
3237         (optimize_inline_calls): Use update_max_bb_count..
3238         (tree_function_versioning): Use update_max_bb_count..
3239         * value-prof.c (gimple_value_profile_transformations):
3240         Do not use update_max_bb_count.
3242 2017-11-13  Jan Hubicka  <hubicka@ucw.cz>
3244         * ipa-inline.c (compute_uninlined_call_time, compute_inlined_call_time):
3245         always use frequencies.
3247 2017-11-13  Jan Hubicka  <hubicka@ucw.cz>
3249         * bb-reorder.c: Remove frequencies from comments.
3250         (better_edge_p): Use profile counts.
3251         (find_traces): Dump profile counts.
3252         (rotate_loop): Use profile counts.
3253         (find_traces_1_round): Likewise.
3254         (connect_better_edge_p): Use counts instead of probabilities for
3255         reverse walk.
3256         (copy_bb_p): Drop early check for non-0 frequency.
3257         (sanitize_hot_paths): Update comments.
3259 2017-11-13  Jan Hubicka  <hubicka@ucw.cz>
3261         * ipa-split.c (struct split_point): Add count.
3262         (consider_split): Do not compute incoming frequency; compute incoming
3263         count and store it to split_point.
3264         (split_function): Set count of the call to split part correctly.
3266 2017-11-13  Carl Love  <cel@us.ibm.com>
3268         * config/rs6000/altivec.md (altivec_vsumsws_be): Add define_expand.
3270 2017-11-13  Tom Tromey  <tom@tromey.com>
3272         * doc/cpp.texi (Variadic Macros): Document __VA_OPT__.
3274 2017-11-13  Carl Love  <cel@us.ibm.com>
3276         * config/rs6000/rs6000-c.c (altivec_overloaded_builtins):
3277         Add support for builtins:
3278         unsigned int vec_first_{,miss}_match_{,or_eos}index,
3279         vector {un,}signed {char,int,short},
3280         vector {un,}signed {char,int,short}) arguments.
3281         * config/rs6000/rs6000-builtin.def (VFIRSTMATCHINDEX,
3282         VFIRSTMATCHOREOSINDEX, VFIRSTMISMATCHINDEX, VFIRSTMISMATCHOREOSINDEX):
3283         Add BU_P9V_AV_2 expansions for the builtins.
3284         * config/rs6000/altivec.h (vec_first_match_index,
3285         vec_first_mismatch_index, vec_first_match_or_eos_index,
3286         vec_first_mismatch_or_eos_index): Add #defines for the builtins.
3287         * config/rs6000/rs6000-protos.h (bytes_in_mode): Add
3288         new extern declaration.
3289         * config/rs6000/rs6000.c (bytes_in_mode): Add new function.
3290         * config/rs6000/vsx.md (first_match_index_<mode>,
3291         first_match_or_eos_index_<mode>, first_mismatch_index_<mode>,
3292         first_mismatch_or_eos_index_<mode>): Add define expand.
3293         (vctzlsbb_<mode>): Add mode field to define_insn for vctzlsbb.
3294         * doc/extend.texi: Update the built-in documenation file for the new
3295         built-in functions.
3297 2017-11-13  Michael Meissner  <meissner@linux.vnet.ibm.com>
3299         * match.pd: Convert fminf<N>, fminf<N>x, fmax<N>, and fmax<N>x
3300         into the min/max operations for _Float<N> and _Float<N>X types.
3302 2017-11-13  Eric Botcazou  <ebotcazou@adacore.com>
3304         PR lto/81351
3305         * dwarf2out.c (do_eh_frame): New static variable.
3306         (dwarf2out_begin_prologue): Set it.
3307         (dwarf2out_frame_finish): Test it instead of dwarf2out_do_eh_frame.
3309 2017-11-13  Jan Hubicka  <hubicka@ucw.cz>
3311         * tree-ssa-coalesce.c (coalesce_cost): Fix formating.
3313         * tree-ssa-sink.c (select_best_block): Do not use frequencies.
3315 2017-11-13  Eric Botcazou  <ebotcazou@adacore.com>
3317         PR lto/81351
3318         * debug.h (dwarf2out_do_eh_frame): Declare.
3319         * dwarf2cfi.c (dwarf2out_do_eh_frame): New predicate.
3320         (dwarf2out_do_frame): Use it.
3321         (dwarf2out_do_cfi_asm): Likewise.
3322         * dwarf2out.c (dwarf2out_frame_finish): Likewise.
3323         (dwarf2out_assembly_start): Likewise.
3324         (dwarf2out_begin_prologue): Fix comment.
3325         * toplev.c (compile_file): Always call dwarf2out_frame_finish
3326         if the target needs either debug or unwind DWARF2 info.
3327         * lto-opts.c (lto_write_options): Do not save -fexceptions,
3328         -fnon-call-exceptions, -ffp-contract, -fmath-errno, -fsigned-zeros,
3329         -ftrapping-math, -ftrapv and -fwrapv.
3331 2017-11-13  Jan Hubicka  <hubicka@ucw.cz>
3333         * cgraph.c (cgraph_edge::sreal_frequency): New function.
3334         * cgraph.h (cgraph_edge::sreal_frequency): Declare.
3335         * ipa-fnsummary.c (dump_ipa_call_summary): Use sreal_frequency.
3336         (estimate_edge_size_and_time): Likewise.
3337         (ipa_merge_fn_summary_after_inlining): Likewise.
3338         * ipa-inline.c (cgraph_freq_base_rec): Remove.
3339         (compute_uninlined_call_time): Use sreal_frequency.
3340         (compute_inlined_call_time): Likewise.
3341         (ipa_inline): Do not initialize cgraph_freq_base_rec.
3342         * profile-count.c: Include sreal.h.
3343         (profile_count::to_sreal_scale): New.
3344         * profile-count.h: Forward declare sreal.
3345         (profile_count::to_sreal_scale): Declare.
3347 2017-11-13  Nathan Sidwell  <nathan@acm.org>
3349         * diagnostic.c (maybe_line_and_column): New.
3350         (diagnostic_get_location_text): Use it.
3351         (diagnostic_report_current_module): Likewise.
3352         (test_diagnostic_get_location_text): Add tests.
3354 2017-11-13  Luis Machado  <luis.machado@linaro.org>
3356         * doc/md.texi (Specifying processor pipeline description): Fix
3357         incorrect latency for the div instruction example.
3359 2017-11-13  Jakub Jelinek  <jakub@redhat.com>
3361         PR tree-optimization/78821
3362         * gimple-ssa-store-merging.c (compatible_load_p): Don't require
3363         that bit_not_p is the same.
3364         (imm_store_chain_info::coalesce_immediate_stores): Likewise.
3365         (split_group): Count precisely bit_not_p bits in each statement.
3366         (invert_op): New function.
3367         (imm_store_chain_info::output_merged_store): Use invert_op to
3368         emit BIT_XOR_EXPR with a xor_mask instead of BIT_NOT_EXPR if some
3369         but not all orig_stores have BIT_NOT_EXPR in the corresponding spots.
3371 2017-11-13  Martin Liska  <mliska@suse.cz>
3373         * gcov.c (struct coverage_info): Remove typedef of coverage_t.
3374         (struct source_info): Likewise.
3375         (add_branch_counts): Likewise.
3376         (add_line_counts): Likewise.
3377         (function_summary): Likewise.
3378         (output_intermediate_line): Likewise.
3379         (generate_results): Likewise.
3381 2017-11-13  Martin Liska  <mliska@suse.cz>
3383         * gcov.c (struct block_info): Remove typedef for block_t.
3384         (struct line_info): Likewise.
3385         (line_info::has_block): Likewise.
3386         (EXIT_BLOCK): Likewise.
3387         (unblock): Likewise.
3388         (circuit): Likewise.
3389         (get_cycles_count): Likewise.
3390         (process_file): Likewise.
3391         (read_graph_file): Likewise.
3392         (solve_flow_graph): Likewise.
3393         (find_exception_blocks): Likewise.
3394         (add_line_counts): Likewise.
3395         (accumulate_line_info): Likewise.
3396         (output_line_details): Likewise.
3398 2017-11-13  Martin Liska  <mliska@suse.cz>
3400         * gcov.c (struct arc_info): Remove typedef for arc_t.
3401         (struct line_info): Likewise.
3402         (add_branch_counts): Likewise.
3403         (output_branch_count): Likewise.
3404         (function_info::~function_info): Likewise.
3405         (circuit): Likewise.
3406         (output_intermediate_line): Likewise.
3407         (read_graph_file): Likewise.
3408         (solve_flow_graph): Likewise.
3409         (find_exception_blocks): Likewise.
3410         (add_line_counts): Likewise.
3411         (accumulate_line_info): Likewise.
3412         (output_line_details): Likewise.
3413         (output_function_details): Likewise.
3415 2017-11-13  Martin Liska  <mliska@suse.cz>
3417         * gcov.c (struct function_info): Remove typedef for function_t.
3418         (struct source_info): Likewise.
3419         (source_info::get_functions_at_location): Likewise.
3420         (solve_flow_graph): Likewise.
3421         (find_exception_blocks): Likewise.
3422         (add_line_counts): Likewise.
3423         (output_intermediate_file): Likewise.
3424         (process_file): Likewise.
3425         (generate_results): Likewise.
3426         (release_structures): Likewise.
3427         (read_graph_file): Likewise.
3428         (read_count_file): Likewise.
3429         (accumulate_line_counts): Likewise.
3430         (output_lines): Likewise.
3432 2017-11-13  Martin Liska  <mliska@suse.cz>
3434         * gcov.c (function_info::function_info): Remove num_counts
3435         and add vector<gcov_type>.
3436         (function_info::~function_info): Use the vector.
3437         (process_file): Likewise.
3438         (read_graph_file): Likewise.
3439         (read_count_file): Likewise.
3440         (solve_flow_graph): Likewise.
3442 2017-11-13  Martin Liska  <mliska@suse.cz>
3444         * gcov.c (function_info::is_artificial): New function.
3445         (process_file): Erase all artificial early.
3446         (generate_results): Skip as all artificial are already
3447         removed.
3449 2017-11-13  Martin Liska  <mliska@suse.cz>
3451         * gcov.c (read_graph_file): Store to global vector of functions.
3452         (read_count_file): Iterate the vector.
3453         (process_file): Likewise.
3454         (generate_results): Likewise.
3455         (release_structures): Likewise.
3457 2017-11-13  Jakub Jelinek  <jakub@redhat.com>
3459         PR tree-optimization/82954
3460         * gimple-ssa-store-merging.c
3461         (imm_store_chain_info::coalesce_immediate_stores): If
3462         !infof->ops[N].base_addr, split group if info->ops[N].base_addr.
3464 2017-11-13  Richard Sandiford  <richard.sandiford@linaro.org>
3466         * config/aarch64/aarch64-simd.md (aarch64_store_lane0<mode>):
3467         Upddate call to ENDIAN_LANE_N.
3468         (aarch64_<sur>dot_lane<vsi2qi>): Use aarch64_endian_lane_rtx.
3469         (aarch64_<sur>dot_laneq<vsi2qi>): Likewise.
3470         (*aarch64_simd_vec_copy_lane<mode>): Update calls to ENDIAN_LANE_N
3471         and use aarch64_endian_lane_rtx.
3472         (*aarch64_simd_vec_copy_lane_<vswap_width_name><mode>): Likewise.
3474 2017-11-12  Tom de Vries  <tom@codesourcery.com>
3476         * config/riscv/riscv.h (ASM_OUTPUT_LABELREF): Wrap in do {} while (0).
3478 2017-11-12  Tom de Vries  <tom@codesourcery.com>
3480         * config/elfos.h (ASM_OUTPUT_ASCII): Remove semicolon after macro body.
3482 2017-11-12  Tom de Vries  <tom@codesourcery.com>
3484         * config/cr16/cr16.h (ASM_OUTPUT_LABELREF): Remove semicolon after macro
3485         body.
3486         * config/powerpcspe/xcoff.h (ASM_OUTPUT_LABELREF): Same.
3487         * config/rs6000/xcoff.h (ASM_OUTPUT_LABELREF): Same.
3488         * defaults.h (ASM_OUTPUT_LABELREF): Same.
3490 2017-11-11  Martin Sebor  <msebor@redhat.com>
3492         PR c/81117
3493         * doc/extend.texi (attribute nonstring): Remove spurious argument.
3495         PR bootstrap/82948
3496         * prefic.c (translate_name): Replace strncpy with memcpy to
3497         avoid -Wstringop-truncation.
3499 2017-11-10  Jan Hubicka  <hubicka@ucw.cz>
3501         * tree-ssa-loop-im.c (execute_sm_if_changed): Do not compute freq_sum.
3503 2017-11-10  Jan Hubicka  <hubicka@ucw.cz>
3505         * predict.c (maybe_hot_frequency_p): Do not use cfun.
3507 2017-11-10  Jan Hubicka  <hubicka@ucw.cz>
3509         * tree-ssa-tail-merge.c (replace_block_by): Fix and re-enable profile
3510         merging.
3512 2017-11-10  Michael Meissner  <meissner@linux.vnet.ibm.com>
3514         * config/rs6000/rs6000.md (bswaphi2_reg): On ISA 3.0 systems,
3515         enable generating XXBRH if the value is in a vector register.
3516         (bswapsi2_reg): On ISA 3.0 systems, enable generating XXBRW if the
3517         value is in a vector register.
3518         (bswapdi2_reg): On ISA 3.0 systems, always use XXBRD to do
3519         register to register bswap64's instead of doing the GPR sequence
3520         used on previous machines.
3521         (bswapdi2_xxbrd): New insn.
3522         (bswapdi2_reg): Disallow on ISA 3.0.
3523         (register to register bswap64 splitter): Do not split the insn on
3524         ISA 3.0 systems that use XXBRD.
3526 2017-11-10  Martin Sebor  <msebor@redhat.com>
3528         PR c/81117
3529         * config/darwin-c.c (framework_construct_pathname): Replace strncpy
3530         with memcpy.
3531         (find_subframework_file): Same.
3533 2017-11-10  Jan Hubicka  <hubicka@ucw.cz>
3535         * auto-profile.c (afdo_indirect_call): Drop frequency.
3536         * cgraph.c (symbol_table::create_edge): Drop frequency argument.
3537         (cgraph_node::create_edge): Drop frequency argument.
3538         (cgraph_node::create_indirect_edge): Drop frequency argument.
3539         (cgraph_edge::make_speculative): Drop frequency arguments.
3540         (cgraph_edge::resolve_speculation): Do not update frequencies
3541         (cgraph_edge::dump_edge_flags): Do not dump frequency.
3542         (cgraph_node::dump): Check consistency in IPA mode.
3543         (cgraph_edge::maybe_hot_p): Use IPA counter.
3544         (cgraph_edge::verify_count_and_frequency): Rename to ...
3545         (cgraph_edge::verify_count): ... this one; drop frequency checking.
3546         (cgraph_node::verify_node): Update.
3547         * cgraph.h (struct cgraph_edge): Drop frequency.
3548         (cgraph_edge::frequency): New function.
3549         * cgraphbuild.c (pass_build_cgraph_edges::execute): Donot pass
3550         frequencies.
3551         (cgraph_edge::rebuild_edges): Likewise.
3552         * cgraphclones.c (cgraph_edge::clone): Scale only counts.
3553         (duplicate_thunk_for_node): Do not pass frequency.
3554         (cgraph_node::create_clone): Scale only counts.
3555         (cgraph_node::create_virtual_clone): Do not pass frequency.
3556         (cgraph_node::create_edge_including_clones): Do not pass frequency.
3557         (cgraph_node::create_version_clone): Do not pass frequency.
3558         * cgraphunit.c (cgraph_node::analyze): Do not pass frequency.
3559         (cgraph_node::expand_thunk): Do not pass frequency.
3560         (cgraph_node::create_wrapper): Do not pass frequency.
3561         * gimple-iterator.c (update_call_edge_frequencies): Do not pass
3562         frequency.
3563         * gimple-streamer-in.c (input_bb): Scale only IPA counts.
3564         * ipa-chkp.c (chkp_produce_thunks): Do not pass frequency.
3565         * ipa-cp.c (ipcp_lattice::print): Use frequency function.
3566         (gather_caller_stats): Use frequency function.
3567         (ipcp_cloning_candidate_p): Use frequency function.
3568         (ipcp_propagate_stage): Use frequency function.
3569         (get_info_about_necessary_edges): Use frequency function.
3570         (update_profiling_info): Update only IPA profile.
3571         (update_specialized_profile): Use frequency functoin.
3572         (perhaps_add_new_callers): Update only IPA profile.
3573         * ipa-devirt.c (ipa_devirt): Use IPA profile.
3574         * ipa-fnsummary.c (redirect_to_unreachable): Do not set frequrency.
3575         (dump_ipa_call_summary): Use frequency function.
3576         (estimate_edge_size_and_time): Use frequency function.
3577         (ipa_merge_fn_summary_after_inlining): Use frequency function.
3578         * ipa-inline-analysis.c (do_estimate_edge_time): Use IPA profile.
3579         * ipa-inline-transform.c (update_noncloned_frequencies): Rename to ..
3580         (update_noncloned_counts): ... ths one; scale counts only.
3581         (clone_inlined_nodes): Do not scale frequency.
3582         (inline_call): Do not pass frequency.
3583         * ipa-inline.c (compute_uninlined_call_time): Use IPA profile.
3584         (compute_inlined_call_time): Use IPA profile.
3585         (want_inline_small_function_p): Use IPA profile.
3586         (want_inline_self_recursive_call_p): Use IPA profile.
3587         (edge_badness): Use IPA profile.
3588         (lookup_recursive_calls): Use IPA profile.
3589         (recursive_inlining): Do not pass frequency.
3590         (resolve_noninline_speculation): Do not update frequency.
3591         (inline_small_functions): Collect max of IPA profile.
3592         (dump_overall_stats): Dump IPA porfile.
3593         (dump_inline_stats): Dump IPA porfile.
3594         (ipa_inline): Collect IPA stats.
3595         * ipa-inline.h (clone_inlined_nodes): Update prototype.
3596         * ipa-profile.c (ipa_propagate_frequency_1): Use frequency function.
3597         (ipa_propagate_frequency): Use frequency function.
3598         (ipa_profile): Cleanup.
3599         * ipa-prop.c (ipa_make_edge_direct_to_target): Do not pass frequency
3600         * ipa-utils.c (ipa_merge_profiles): Merge all profiles.
3601         * lto-cgraph.c (lto_output_edge): Do not stream frequency.
3602         (input_node): Do not stream frequency.
3603         (input_edge): Do not stream frequency.
3604         (merge_profile_summaries): Scale only IPA profiles.
3605         * omp-simd-clone.c (simd_clone_adjust): Do not pass frequency.
3606         * predict.c (drop_profile): Do not recompute frequency.
3607         * trans-mem.c (ipa_tm_insert_irr_call): Do not pass frequency.
3608         (ipa_tm_insert_gettmclone_call): Do not pass frequency.
3609         * tree-cfg.c (execute_fixup_cfg): Drop profile to global0 if needed.
3610         * tree-chkp.c (chkp_copy_bounds_for_assign): Do not pass frequency.
3611         * tree-emutls.c (gen_emutls_addr): Do not pass frequency.
3612         * tree-inline.c (copy_bb): Do not scale frequency.
3613         (expand_call_inline): Do not scale frequency.
3614         (tree_function_versioning): Do not scale frequency.
3615         * ubsan.c (ubsan_create_edge): Do not pass frequency.
3617 2017-11-10  Julia Koval  <julia.koval@intel.com>
3619         * config/i386/gfniintrin.h (_mm_gf2p8affine_epi64_epi8)
3620         (_mm256_gf2p8affine_epi64_epi8, _mm_mask_gf2p8affine_epi64_epi8)
3621         (_mm_maskz_gf2p8affine_epi64_epi8, _mm256_mask_gf2p8affine_epi64_epi8)
3622         (_mm256_maskz_gf2p8affine_epi64_epi8)
3623         (_mm512_mask_gf2p8affine_epi64_epi8, _mm512_gf2p8affine_epi64_epi8)
3624         (_mm512_maskz_gf2p8affine_epi64_epi8): New intrinsics.
3625         * config/i386/i386-builtin.def (__builtin_ia32_vgf2p8affineqb_v64qi)
3626         (__builtin_ia32_vgf2p8affineqb_v32qi)
3627         (__builtin_ia32_vgf2p8affineqb_v16qi): New builtins.
3628         * config/i386/sse.md (vgf2p8affineqb_<mode><mask_name>): New pattern.
3630 2017-11-10  Tamar Christina  <tamar.christina@arm.com>
3632         PR target/82641
3633         * config/arm/arm.c
3634         (arm_option_override): Refactor.
3635         (arm_option_reconfigure_globals): New.
3636         (arm_options_perform_arch_sanity_checks): New.
3637         * config/arm/arm-protos.h (arm_option_reconfigure_globals):
3638         New prototype.
3639         (arm_options_perform_arch_sanity_checks): Likewise
3641 2017-11-10  Pat Haugen  <pthaugen@us.ibm.com>
3643         * rs6000/power9.md (power9-qpdiv): Correct DFU pipe usage.
3644         (power9-qpmul): New.
3645         * rs6000/rs6000.md ("type" attr): Add qmul.
3646         (mul<mode>3, fma<mode>4_hw, *fms<mode>4_hw, *nfma<mode>4_hw,
3647         *nfms<mode>4_hw, mul<mode>3_odd, fma<mode>4_odd, *fms<mode>4_odd,
3648         *nfma<mode>4_odd, *nfms<mode>4_odd): Change type to qmul.
3650 2017-11-10  Martin Sebor  <msebor@redhat.com>
3652         PR c/81117
3653         * builtins.c (compute_objsize): Handle arrays that
3654         compute_builtin_object_size likes to fail for.  Make extern.
3655         * builtins.h (compute_objsize): Declare.
3656         (check_strncpy_sizes): New function.
3657         (expand_builtin_strncpy): Call check_strncpy_sizes.
3658         * gimple-fold.c (gimple_fold_builtin_strncpy): Implement
3659         -Wstringop-truncation.
3660         (gimple_fold_builtin_strncat): Same.
3661         * gimple.c (gimple_build_call_from_tree): Set call location.
3662         * tree-ssa-strlen.c (strlen_to_stridx): New global variable.
3663         (maybe_diag_bound_equal_length, is_strlen_related_p): New functions.
3664         (handle_builtin_stxncpy, handle_builtin_strncat): Same.
3665         (handle_builtin_strlen): Use strlen_to_stridx.
3666         (strlen_optimize_stmt): Handle flavors of strncat, strncpy, and
3667         stpncpy.
3668         Use strlen_to_stridx.
3669         (pass_strlen::execute): Release strlen_to_stridx.
3670         * doc/invoke.texi (-Wsizeof-pointer-memaccess): Document enhancement.
3671         (-Wstringop-truncation): Document new option.
3673 2017-11-10  Martin Liska  <mliska@suse.cz>
3675         PR gcov-profile/82702
3676         * gcov.c (main): Handle intermediate files in a different
3677         way.
3678         (get_gcov_intermediate_filename): New function.
3679         (output_gcov_file): Remove support of intermediate files.
3680         (generate_results): Allocate intermediate file.
3681         (release_structures): Clean-up properly fn_end.
3682         (output_intermediate_file): Start iterating with line 1.
3684 2017-11-10  Jakub Jelinek  <jakub@redhat.com>
3686         PR tree-optimization/82929
3687         * gimple-ssa-store-merging.c (struct store_immediate_info): Add
3688         ops_swapped_p non-static data member.
3689         (store_immediate_info::store_immediate_info): Clear it.
3690         (imm_store_chain_info::coalesce_immediate_stores): If swapping
3691         ops set ops_swapped_p.
3692         (count_multiple_uses): Handle ops_swapped_p.
3694 2017-11-10  Martin Liska  <mliska@suse.cz>
3696         * coverage.c (coverage_init): Stream information about
3697         support of has_unexecuted_blocks.
3698         * doc/gcov.texi: Document that.
3699         * gcov-dump.c (dump_gcov_file): Support it in gcov_dump tool.
3700         * gcov.c (read_graph_file): Likewise.
3701         (output_line_beginning): Fix a small issue with
3702         color output.
3704 2017-11-10  Bin Cheng  <bin.cheng@arm.com>
3706         * tree-predcom.c (determine_roots_comp): Avoid memory leak by freeing
3707         reference of trivial component.
3709 2017-11-10  Jakub Jelinek  <jakub@redhat.com>
3711         PR bootstrap/82916
3712         * gimple-ssa-store-merging.c
3713         (pass_store_merging::terminate_all_aliasing_chains): For
3714         gimple_store_p stmts also call refs_output_dependent_p.
3716         PR rtl-optimization/82913
3717         * compare-elim.c (try_merge_compare): Punt if def_insn is not
3718         single set.
3720 2017-11-09  Jeff Law  <law@redhat.com>
3722         * vr-values.h: New file with vr_values class.
3723         * tree-vrp.c: Include vr-values.h
3724         (vrp_value_range_pool, vrp_equiv_obstack, num_vr_values): Move static
3725         data objects into the vr_values class.
3726         (vr_value, values_propagated, vr_phi_edge_counts): Likewise.
3727         (get_value_range): Make it a member function within vr_values class.
3728         (set_defs_to_varying, update_value_range, add_equivalence): Likewise.
3729         (vrp_stmt_computes_nonzero_p, op_with_boolean_value_range_p): Likewise.
3730         (op_with_constant_singleton_value_range): Likewise.
3731         (extract_range_for_var_from_comparison_expr): Likewise.
3732         (extract_range_from_assert, extract_range_from_ssa_name): Likewise.
3733         (extract_range_from_binary_expr): Likewise.
3734         (extract_range_from_unary_expr): Likewise.
3735         (extract_range_from_cond_expr, extrat_range_from_comparison): Likewise.
3736         (check_for_binary_op_overflow, extract_range_basic): Likewise.
3737         (extract_range_from_assignment, adjust_range_with_scev): Likewise.
3738         (dump_all_value_ranges, get_vr_for_comparison): Likewise.
3739         (compare_name_with_value, compare_names): Likewise.
3740         (vrp_evaluate_conditional_warnv_with_ops_using_ranges): Likewise.
3741         (vrp_evaluate_conditional_warnv_with_ops): Likewise.  Remove prototype.
3742         (vrp_evaluate_conditional, vrp_visit_cond_stmt): Likewise.
3743         (vrp_visit_switch_stmt, extract_range_from_stmt): Likewise.
3744         (extract_range_from_phi_node): Likewise.
3745         (simplify_truth_ops_using_ranges): Likewise.
3746         (simplify_div_or_mod_using_ranges): Likewise.
3747         (simplify_min_or_max_using_ranges, simplify_abs_using_ranges): Likewise.
3748         (simplify_bit_ops_using_ranges, simplify_cond_using_ranges_1): Likewise.
3749         (simplify_cond_using_ranges_2, simplify_switch_using_ranges): Likewise.
3750         (simplify_float_conversion_using_ranges): Likewise.
3751         (simplify_internal_call_using_ranges): Likewise.
3752         (two_valued_val_range_p, simplify_stmt_using_ranges): Likewise.
3753         (vrp_visit_assignment_or_call): Likewise.  Smuggle class instance
3754         poitner via x_vr_values for calls into gimple folder.
3755         (vrp_initialize_lattice): Make this the vr_values ctor.
3756         (vrp_free_lattice): Make this the vr_values dtor.
3757         (set_vr_value): New function.
3758         (class vrp_prop): Add vr_values data member.  Add various member
3759         functions as well as member functions that delegate to vr_values.
3760         (check_array_ref): Make a member function within vrp_prop class.
3761         (search_for_addr_array, vrp_initialize): Likewise.
3762         (vrp_finalize): Likewise.  Revamp to avoid direct access to
3763         vr_value, values_propagated, etc.
3764         (check_array_bounds): Extract vrp_prop class instance pointer from
3765         walk info structure.  Use it to call member functions.
3766         (check_all_array_refs): Make a member function within vrp_prop class.
3767         Smuggle class instance pointer via walk info structure.
3768         (x_vr_values): New local static.
3769         (vrp_valueize): Use x_vr_values to get class instance.
3770         (vr_valueize_1): Likewise.
3771         (class vrp_folder): Add vr_values data member.  Add various member
3772         functions as well as member functions that delegate to vr_values.
3773         (fold_predicate_in): Make a mber fucntion within vrp_folder class.
3774         (simplify_stmt_for_jump_threading): Extract smuggled vr_values
3775         class instance from vr_values.  Use it to call member functions.
3776         (vrp_dom_walker): Add vr_values data member.
3777         (vrp_dom_walker::after_dom_children): Smuggle vr_values class
3778         instance via x_vr_values.
3779         (identify_jump_threads): Accept vr_values as argument.  Store
3780         it into the walker structure.
3781         (evrp_dom_walker): Add vr_values class data member.  Add various
3782         delegators.
3783         (evrp_dom_walker::try_find_new_range): Use vr_values data
3784         member to access the memory allocator.
3785         (evrp_dom_walker::before_dom_children): Store vr_values class
3786         instance into the vrp_folder class.
3787         (evrp_dom_walker::push_value_range): Rework to avoid direct
3788         access to num_vr_values and vr_value.
3789         (evrp_dom_walker::pop_value_range): Likewise.
3790         (execute_early_vrp): Remove call to vrp_initialize_lattice.
3791         Use vr_values to get to dump_all_value_ranges member function.
3792         Remove call to vrp_free_lattice.  Call vrp_initialize, vrp_finalize,
3793         and simplify_cond_using_ranges_2 via vrp_prop class instance.
3794         Pass vr_values class instance down to identify_jump_threads.
3795         Remove call to vrp_free_lattice.
3796         (debug_all_value_ranges): Remove.
3798         * tree-vrp.c (vrp_prop): Move class to earlier point in the file.
3799         (vrp_folder): Likewise.
3801         * tree-vrp.c (set_value_range): Do not reference vrp_equiv_obstack.
3802         Get it from the existing bitmap instead.
3803         (vrp_intersect_ranges_1): Likewise.
3805 2017-11-09  Jakub Jelinek  <jakub@redhat.com>
3807         * gimple-ssa-store-merging.c (struct store_immediate_info): Add
3808         bit_not_p field.
3809         (store_immediate_info::store_immediate_info): Add bitnotp argument,
3810         set bit_not_p to it.
3811         (imm_store_chain_info::coalesce_immediate_stores): Break group
3812         if bit_not_p is different.
3813         (count_multiple_uses, split_group,
3814         imm_store_chain_info::output_merged_store): Handle info->bit_not_p.
3815         (handled_load): Avoid multiple chained BIT_NOT_EXPRs.
3816         (pass_store_merging::process_store): Handle BIT_{AND,IOR,XOR}_EXPR
3817         result inverted using BIT_NOT_EXPR, compute bit_not_p, pass it
3818         to store_immediate_info ctor.
3820 2017-11-09  Jim Wilson  <jimw@sifive.com>
3822         * collect2.c (OBJECT_FORMAT_COFF): Remove EXTENDED_COFF support.
3823         (scan_prog_file): Likewise.
3825 2017-11-09  Jan Hubicka  <hubicka@ucw.cz>
3827         * bb-reorder.c (max_entry_frequency): Remove.
3828         (find_traces, rotate_loop, mark_bb_visited, connect_better_edge_p,
3829         connect_traces, push_to_next_round_p): Remove prototypes.
3830         (find_traces_1_round): Use counts only.
3831         (push_to_next_round_p): Likewise.
3832         (find_traces): Likewise.
3833         (rotate_loop): Likewise.
3834         (find_traces_1_round): Likewise.
3835         (connect_traces): Likewise.
3836         (edge_order): Likewise.
3838 2017-11-09  Thomas Preud'homme  <thomas.preudhomme@arm.com>
3840         * config/arm/arm.c (output_return_instruction): Add comments to
3841         indicate requirement for cmse_nonsecure_entry return to account
3842         for the size of clearing instruction output here.
3843         (thumb_exit): Likewise.
3844         * config/arm/thumb2.md (thumb2_cmse_entry_return): Fix length for
3845         return in hardfloat mode.
3847 2017-11-09  Segher Boessenkool  <segher@kernel.crashing.org>
3849         * config/rs6000/rs6000.c (machine_function): Add a bool,
3850         "toc_is_wrapped_separately".
3851         (rs6000_option_override_internal): Enable OPTION_MASK_SAVE_TOC_INDIRECT
3852         if it wasn't explicitly set or unset, we are optimizing for speed, and
3853         doing separate shrink-wrapping.
3854         (rs6000_get_separate_components): Enable the TOC component if
3855         saving the TOC register in the prologue.
3856         (rs6000_components_for_bb): Handle the TOC component.
3857         (rs6000_emit_prologue_components): Store the TOC register where needed.
3858         (rs6000_set_handled_components): Mark TOC as handled, if handled.
3859         (rs6000_emit_prologue): Don't save the TOC if that is already done.
3861 2017-11-09  Martin Jambor  <mjambor@suse.cz>
3863         * ipa-param-manipulation.c: New file.
3864         * ipa-param-manipulation.h: Likewise.
3865         * Makefile.in (OBJS): Add ipa-param-manipulation.o.
3866         (PLUGIN_HEADERS): Addded ipa-param-manipulation.h
3867         * ipa-param.h (ipa_parm_op): Moved to ipa-param-manipulation.h.
3868         (ipa_parm_adjustment): Likewise.
3869         (ipa_parm_adjustment_vec): Likewise.
3870         (ipa_get_vector_of_formal_parms): Moved declaration to
3871         ipa-param-manipulation.h.
3872         (ipa_get_vector_of_formal_parm_types): Likewise.
3873         (ipa_modify_formal_parameters): Likewise.
3874         (ipa_modify_call_arguments): Likewise.
3875         (ipa_combine_adjustments): Likewise.
3876         (ipa_dump_param_adjustments): Likewise.
3877         (ipa_modify_expr): Likewise.
3878         (ipa_get_adjustment_candidate): Likewise.
3879         * ipa-prop.c (ipa_get_vector_of_formal_parms): Moved to
3880         ipa-param-manipulation.c.
3881         (ipa_get_vector_of_formal_parm_types): Likewise.
3882         (ipa_modify_formal_parameters): Likewise.
3883         (ipa_modify_call_arguments): Likewise.
3884         (ipa_modify_expr): Likewise.
3885         (get_ssa_base_param): Likewise.
3886         (ipa_get_adjustment_candidate): Likewise.
3887         (index_in_adjustments_multiple_times_p): Likewise.
3888         (ipa_combine_adjustments): Likewise.
3889         (ipa_dump_param_adjustments): Likewise.
3890         * tree-sra.c: Also include ipa-param-manipulation.h
3891         * omp-simd-clone.c: Include ipa-param-manipulation.h instead of
3892         ipa-param.h.
3894 2017-11-09  Richard Sandiford  <richard.sandiford@linaro.org>
3895             Alan Hayward  <alan.hayward@arm.com>
3896             David Sherwood  <david.sherwood@arm.com>
3898         * doc/sourcebuild.texi (vect_masked_store): Document.
3900 2017-11-09  Richard Sandiford  <richard.sandiford@linaro.org>
3901             Alan Hayward  <alan.hayward@arm.com>
3902             David Sherwood  <david.sherwood@arm.com>
3904         * doc/sourcebuild.texi (vect_align_stack_vars): Document.
3906 2017-11-09  Richard Sandiford  <richard.sandiford@linaro.org>
3907             Alan Hayward  <alan.hayward@arm.com>
3908             David Sherwood  <david.sherwood@arm.com>
3910         * doc/sourcebuild.texi (vect_variable_length): Document.
3912 2017-11-09  Richard Sandiford  <richard.sandiford@linaro.org>
3913             Alan Hayward  <alan.hayward@arm.com>
3914             David Sherwood  <david.sherwood@arm.com>
3916         * doc/sourcebuild.texi (vect_unaligned_possible): Document.
3918 2017-11-09  Richard Sandiford  <richard.sandiford@linaro.org>
3919             Alan Hayward  <alan.hayward@arm.com>
3920             David Sherwood  <david.sherwood@arm.com>
3922         * doc/sourcebuild.texi (vect_element_align_preferred): Document.
3924 2017-11-09  Richard Sandiford  <richard.sandiford@linaro.org>
3925             Alan Hayward  <alan.hayward@arm.com>
3926             David Sherwood  <david.sherwood@arm.com>
3928         * doc/sourcebuild.texi (vect_perm_short, vect_perm_byte): Document
3929         previously undocumented selectors.
3930         (vect_perm3_byte, vect_perm3_short, vect_perm3_int): Document.
3932 2017-11-09  Richard Sandiford  <richard.sandiford@linaro.org>
3934         * doc/rtl.texi (const_vector): Say that elements can be
3935         const_wide_ints too.
3936         * emit-rtl.h (valid_for_const_vec_duplicate_p): Declare.
3937         * emit-rtl.c (valid_for_const_vec_duplicate_p): New function.
3938         (gen_vec_duplicate): Use it instead of CONSTANT_P.
3939         * optabs.c (expand_vector_broadcast): Likewise.
3941 2017-11-09  Richard Sandiford  <richard.sandiford@linaro.org>
3942             Alan Hayward  <alan.hayward@arm.com>
3943             David Sherwood  <david.sherwood@arm.com>
3945         * tree-ssa-loop-ivopts.c (get_address_cost): Try using a
3946         scaled index even if the unscaled address was invalid.
3947         Don't increase the complexity of using a scale in that case.
3949 2017-11-09  Richard Sandiford  <richard.sandiford@linaro.org>
3950             Alan Hayward  <alan.hayward@arm.com>
3951             David Sherwood  <david.sherwood@arm.com>
3953         * doc/rtl.texi: Rewrite the subreg rules so that they partition
3954         the inner register into REGMODE_NATURAL_SIZE bytes rather than
3955         UNITS_PER_WORD bytes.
3956         * emit-rtl.c (validate_subreg): Divide subregs into blocks
3957         based on REGMODE_NATURAL_SIZE of the inner mode.
3958         (gen_lowpart_common): Split the SCALAR_FLOAT_MODE_P and
3959         !SCALAR_FLOAT_MODE_P cases.  Use REGMODE_NATURAL_SIZE for the latter.
3960         * expmed.c (lowpart_bit_field_p): Divide the value up into
3961         chunks of REGMODE_NATURAL_SIZE rather than UNITS_PER_WORD.
3962         * expr.c (store_constructor): Use REGMODE_NATURAL_SIZE to test
3963         whether something is likely to occupy more than one register.
3965 2017-11-09  Jan Hubicka  <hubicka@ucw.cz>
3967         PR ipa/82879
3968         * ipa-inline-transform.c (update_noncloned_frequencies): Use
3969         profile_count::adjust_for_ipa_scaling.
3970         * tree-inline.c (copy_bb, copy_cfg_body): Likewise.
3971         * profile-count.c (profile_count::adjust_for_ipa_scaling): New member
3972         function.
3973         * profile-count.h (profile_count::adjust_for_ipa_scaling): Declare.
3975 2017-11-09  Jakub Jelinek  <jakub@redhat.com>
3977         * gimple-ssa-store-merging.c (count_multiple_uses): New function.
3978         (split_group): Add total_orig and total_new arguments, estimate the
3979         number of statements related to the store group without store merging
3980         and with store merging.
3981         (imm_store_chain_info::output_merged_store): Adjust split_group
3982         callers, punt if estimated number of statements with store merging
3983         is not smaller than estimated number of statements without it.
3984         Formatting fix.
3985         (handled_load): Remove has_single_use checks.
3986         (pass_store_merging::process_store): Likewise.
3988 2017-11-09  Richard Biener  <rguenther@suse.de>
3990         PR tree-optimization/82902
3991         * tree-ssa-phiprop.c (propagate_with_phi): Test proper type.
3993 2017-11-09  Martin Liska  <mliska@suse.cz>
3995         PR target/82863
3996         * emit-rtl.c (init_emit_regs): Initialize split_branch_probability to
3997         uninitialized.
3999 2017-11-09  Martin Liska  <mliska@suse.cz>
4001         PR tree-optimization/82669
4002         * sbitmap.h (bmp_iter_set_init): Remove non needed check.
4004 2017-11-09  Martin Liska  <mliska@suse.cz>
4006         PR gcov-profile/48463
4007         * coverage.c (coverage_begin_function): Output also end locus
4008         of a function and information whether the function is
4009         artificial.
4010         * gcov-dump.c (tag_function): Parse and print the information.
4011         * gcov.c (INCLUDE_MAP): Add include.
4012         (INCLUDE_SET): Likewise.
4013         (struct line_info): Move earlier in the source file because
4014         of vector<line_info> in function_info structure.
4015         (line_info::line_info): Likewise.
4016         (line_info::has_block): Likewise.
4017         (struct source_info): Add new member index.
4018         (source_info::get_functions_at_location): New function.
4019         (function_info::group_line_p): New function.
4020         (output_intermediate_line): New function.
4021         (output_intermediate_file): Use the mentioned function.
4022         (struct function_start): New.
4023         (struct function_start_pair_hash): Likewise.
4024         (process_file): Add code that identifies group functions.
4025         Assign lines either to global or function scope.
4026         (generate_results): Skip artificial functions.
4027         (find_source): Assign index for each source file.
4028         (read_graph_file): Read new flag artificial and end_line.
4029         (add_line_counts): Assign it either to global of function scope.
4030         (accumulate_line_counts): Isolate core of the function to
4031         accumulate_line_info and call it for both function and global
4032         scope lines.
4033         (accumulate_line_info): New function.
4034         (output_line_beginning): Fix GNU coding style.
4035         (print_source_line): New function.
4036         (output_line_details): Likewise.
4037         (output_function_details): Likewise.
4038         (output_lines): Iterate both source (global) scope and function
4039         scope.
4040         (struct function_line_start_cmp): New class.
4041         * doc/gcov.texi: Reflect changes in documentation.
4043 2017-11-09  Jakub Jelinek  <jakub@redhat.com>
4045         PR debug/82837
4046         * dwarf2out.c (const_ok_for_output_1): Reject NEG in addition to NOT.
4047         (mem_loc_descriptor): Handle (const (neg (...))) as (neg (const (...)))
4048         and similarly for not instead of neg.
4050 2017-11-08  Andi Kleen  <ak@linux.intel.com>
4052         * config/i386/i386.opt: Add -mforce-indirect-call.
4053         * config/i386/predicates.md: Check for flag_force_indirect_call.
4054         * doc/invoke.texi: Document -mforce-indirect-call
4056 2017-11-08  Kito Cheng  <kito.cheng@gmail.com>
4058         * config/riscv/riscv-protos.h (riscv_slow_unaligned_access_p):
4059         New extern.
4060         (MOVE_RATIO): Use riscv_slow_unaligned_access_p.
4061         config/riscv/riscv.c (predict.h): New include.
4062         (riscv_slow_unaligned_access_p): No longer static.
4063         (riscv_block_move_straight): Add require.
4064         * config/riscv/riscv-protos.h (riscv_hard_regno_nregs): Delete.
4066 2017-11-08  Jakub Jelinek  <jakub@redhat.com>
4068         PR target/82855
4069         * config/i386/sse.md (<avx512>_eq<mode>3<mask_scalar_merge_name>,
4070         <avx512>_eq<mode>3<mask_scalar_merge_name>_1): Use
4071         nonimmediate_operand predicate for operand 1 instead of
4072         register_operand.
4074 2017-11-08  Kyrylo Tkachov  <kyrylo.tkachov@arm.com>
4076         * config/aarch64/aarch64-simd.md (store_pair_lanes<mode>):
4077         New pattern.
4078         * config/aarch64/constraints.md (Uml): New constraint.
4079         * config/aarch64/predicates.md (aarch64_mem_pair_lanes_operand): New
4080         predicate.
4082 2017-11-08  Kyrylo Tkachov  <kyrylo.tkachov@arm.com>
4084         * simplify-rtx.c (simplify_ternary_operation): Simplify vec_merge
4085         of two vec_duplicates into a vec_concat.
4087 2017-11-08  Kyrylo Tkachov  <kyrylo.tkachov@arm.com>
4089         * simplify-rtx.c (simplify_ternary_operation, VEC_MERGE):
4090         Simplify vec_merge of vec_duplicate and vec_concat.
4091         * config/aarch64/constraints.md (Utq): New constraint.
4092         * config/aarch64/aarch64-simd.md (load_pair_lanes<mode>): New
4093         define_insn.
4095 2017-11-08  Kyrylo Tkachov  <kyrylo.tkachov@arm.com>
4097         * simplify-rtx.c (simplify_ternary_operation, VEC_MERGE):
4098         Simplify vec_merge of vec_duplicate and const_vector.
4099         * config/aarch64/predicates.md (aarch64_simd_or_scalar_imm_zero):
4100         New predicate.
4101         * config/aarch64/aarch64-simd.md (*aarch64_combinez<mode>): Use VDC
4102         mode iterator.  Update predicate on operand 1 to
4103         handle non-const_vec constants.  Delete constraints.
4104         (*aarch64_combinez_be<mode>): Likewise for operand 2.
4106 2017-11-08  Jakub Jelinek  <jakub@redhat.com>
4108         PR tree-optimization/78821
4109         * gimple-ssa-store-merging.c (struct store_operand_info): Add bit_not_p
4110         data member.
4111         (store_operand_info::store_operand_info): Initialize it to false.
4112         (pass_store_merging::terminate_all_aliasing_chains): Rewritten to use
4113         ref_maybe_used_by_stmt_p and stmt_may_clobber_ref_p on lhs of each
4114         store in the group, and if chain_info is non-NULL, to ignore altogether
4115         that chain.
4116         (compatible_load_p): Fail if bit_not_p does not match.
4117         (imm_store_chain_info::output_merged_store): Handle bit_not_p loads.
4118         (handled_load): Fill in bit_not_p.  Handle BIT_NOT_EXPR.
4119         (pass_store_merging::process_store): Adjust
4120         terminate_all_aliasing_chains calls to pass NULL in all current spots,
4121         call terminate_all_aliasing_chains newly when adding a store into
4122         a chain with non-NULL chain_info.
4124 2017-11-08  Wilco Dijkstra  <wdijkstr@arm.com>
4126         * config/aarch64/aarch64.c (aarch64_can_eliminate): Simplify logic.
4128 2017-11-08  Wilco Dijkstra  <wdijkstr@arm.com>
4130         * config/aarch64/aarch64.c (aarch64_frame_pointer_required)
4131         Remove.
4132         (aarch64_layout_frame): Initialise emit_frame_chain.
4133         (aarch64_can_eliminate): Remove omit leaf frame pointer code.
4134         (TARGET_FRAME_POINTER_REQUIRED): Remove define.
4136 2017-11-08  Martin Liska  <mliska@suse.cz>
4138         * gimplify.c (expand_FALLTHROUGH_r): Simplify usage
4139         of gimple_call_internal_p.
4141 2017-11-07  Tom de Vries  <tom@codesourcery.com>
4143         * config/mips/mips.h (ASM_OUTPUT_LABELREF): Wrap in "do {} while (0)".
4145 2017-11-07  Tom de Vries  <tom@codesourcery.com>
4147         * config/mips/mips.h (ASM_OUTPUT_CASE_END): Remove semicolon after
4148         "do {} while (0)".
4150 2017-11-08  Martin Liska  <mliska@suse.cz>
4152         PR sanitizer/82792
4153         * gimplify.c (expand_FALLTHROUGH_r): Skip IFN_ASAN_MARK.
4155 2017-11-07  Eric Botcazou  <ebotcazou@adacore.com>
4157         * gimple-pretty-print.c (dump_profile): Return "" instead of NULL.
4159 2017-11-07  Jakub Jelinek  <jakub@redhat.com>
4161         PR target/82855
4162         * config/i386/i386.md (SWI1248_AVX512BWDQ2_64): New mode iterator.
4163         (*cmp<mode>_ccz_1): New insn with $k alternative.
4165         PR target/82855
4166         * config/i386/i386.c (ix86_swap_binary_operands_p): Treat
4167         RTX_COMM_COMPARE as commutative as well.
4168         (ix86_binary_operator_ok): Formatting fix.
4169         * config/i386/sse.md (*mul<mode>3<mask_name><round_name>,
4170         *<code><mode>3<mask_name><round_saeonly_name>,
4171         *<code><mode>3<mask_name>, *<code>tf3, *mul<mode>3<mask_name>,
4172         *<s>mul<mode>3_highpart<mask_name>,
4173         *vec_widen_umult_even_v16si<mask_name>,
4174         *vec_widen_umult_even_v8si<mask_name>,
4175         *vec_widen_umult_even_v4si<mask_name>,
4176         *vec_widen_smult_even_v16si<mask_name>,
4177         *vec_widen_smult_even_v8si<mask_name>, *sse4_1_mulv2siv2di3<mask_name>,
4178         *avx2_pmaddwd, *sse2_pmaddwd, *<sse4_1_avx2>_mul<mode>3<mask_name>,
4179         *avx2_<code><mode>3, *avx512f_<code><mode>3<mask_name>,
4180         *sse4_1_<code><mode>3<mask_name>, *<code>v8hi3,
4181         *sse4_1_<code><mode>3<mask_name>, *<code>v16qi3, *avx2_eq<mode>3,
4182         <avx512>_eq<mode>3<mask_scalar_merge_name>_1, *sse4_1_eqv2di3,
4183         *sse2_eq<mode>3, <mask_codefor><code><mode>3<mask_name>,
4184         *<code><mode>3, *<sse2_avx2>_uavg<mode>3<mask_name>,
4185         *<ssse3_avx2>_pmulhrsw<mode>3<mask_name>, *ssse3_pmulhrswv4hi3): Use
4186         !(MEM_P (operands[1]) && MEM_P (operands[2])) condition instead of
4187         ix86_binary_operator_ok.  Formatting fixes.
4188         (*<plusminus_insn><mode>3<mask_name><round_name>,
4189         *<plusminus_insn><mode>3, *<plusminus_insn><mode>3_m): Formatting
4190         fixes.
4192 2017-11-07  Segher Boessenkool  <segher@kernel.crashing.org>
4194         * config/rs6000/rs6000.md (GPR2): New mode_iterator.
4195         ("cstore<mode>4"): Don't always expand with rs6000_emit_int_cmove for
4196         eq and ne if TARGET_ISEL.
4197         (cmp): New code_iterator.
4198         (UNS, UNSU_, UNSIK): New code_attrs.
4199         (<code><GPR:mode><GPR2:mode>2_isel): New define_insn_and_split.
4200         ("eq<mode>3"): New define_expand, rename the define_insn_and_split
4201         to...
4202         ("eq<mode>3"): ... this.
4203         ("ne<mode>3"): New define_expand, rename the define_insn_and_split
4204         to...
4205         ("ne<mode>3"): ... this.
4207 2017-11-07  Julia Koval  <julia.koval@intel.com>
4209         PR target/82812
4210         * common/config/i386/i386-common.c
4211         (OPTION_MASK_ISA_GENERAL_REGS_ONLY_UNSET): Remove MPX from flag.
4212         (ix86_handle_option): Move MPX to isa_flags2 and GFNI to isa_flags.
4213         * config/i386/i386-c.c (ix86_target_macros_internal): Ditto.
4214         * config/i386/i386.opt: Ditto.
4215         * config/i386/i386.c (ix86_target_string): Ditto.
4216         (ix86_option_override_internal): Ditto.
4217         (ix86_init_mpx_builtins): Move MPX to args2.
4218         (ix86_expand_builtin): Special handling for OPTION_MASK_ISA_GFNI.
4219         * config/i386/i386-builtin.def (__builtin_ia32_vgf2p8affineinvqb_v64qi,
4220         __builtin_ia32_vgf2p8affineinvqb_v64qi_mask,
4221         __builtin_ia32_vgf2p8affineinvqb_v32qi,
4222         __builtin_ia32_vgf2p8affineinvqb_v32qi_mask,
4223         __builtin_ia32_vgf2p8affineinvqb_v16qi,
4224         __builtin_ia32_vgf2p8affineinvqb_v16qi_mask): Move to ARGS array.
4226 2017-11-07  Uros Bizjak  <ubizjak@gmail.com>
4228         PR target/80425
4229         * config/i386.i386.md (*zero_extendsidi2): Change (?r,*Yj), (?*Yi,r)
4230         and (*x,m) to ($r,Yj), ($Yi,r) and ($x,m).
4231         (zero-extendsidi peephole2): Remove peephole.
4233 2017-11-07  Eric Botcazou  <ebotcazou@adacore.com>
4235         PR c/53037
4236         * stor-layout.c: Include attribs.h.
4237         (handle_warn_if_not_align): Replace test on TYPE_USER_ALIGN with
4238         explicit lookup of "aligned" attribute.
4240 2017-11-07  Andrew Waterman  <andrew@sifive.com>
4242         * config/riscv/riscv-protos.h (riscv_hard_regno_nregs): New prototype.
4243         (riscv_expand_block_move): Likewise.
4244         * config/riscv/riscv.h (MOVE_RATIO): Tune cost to movmemsi
4245         implementation.
4246         (RISCV_MAX_MOVE_BYTES_PER_LOOP_ITER): New define.
4247         (RISCV_MAX_MOVE_BYTES_STRAIGHT): New define.
4248         * config/riscv/riscv.c (riscv_block_move_straight): New function.
4249         (riscv_adjust_block_mem): Likewise.
4250         (riscv_block_move_loop): Likewise.
4251         (riscv_expand_block_move): Likewise.
4252         * config/riscv/riscv.md (movmemsi): New pattern.
4254 2017-11-07  Michael Clark  <michaeljclark@mac.com>
4256         * config/riscv/linux.h (MUSL_ABI_SUFFIX): New define.
4257         (MUSL_DYNAMIC_LINKER): Likewise.
4259 2017-11-07  Richard Sandiford  <richard.sandiford@linaro.org>
4261         * config/aarch64/aarch64.md (ashl<mode>3, ashr<mode>3, lshr<mode>3)
4262         (rotr<mode>3, rotl<mode>3): Use aarch64_reg_or_imm instead of
4263         nonmmory_operand.
4265 2017-11-07  Richard Biener  <rguenther@suse.de>
4267         * match.pd: Fix build.
4269 2017-11-07  Wilco Dijkstra  <wdijkstr@arm.com>
4270             Jackson Woodruff  <jackson.woodruff@arm.com>
4272         PR tree-optimization/71026
4273         * match.pd: Canonicalize negate in division.
4275 2017-11-07  Sudakshina Das  <sudi.das@arm.com>
4277         PR middle-end/80131
4278         * match.pd: Simplify 1 << (C - x) where C = precision (x) - 1.
4280 2017-11-07  Marc Glisse  <marc.glisse@inria.fr>
4282         * match.pd ((a&~b)|(a^b),(a&~b)^~a,(a|b)&~(a^b),a|~(a^b),
4283         (a|b)|(a&^b),(a&b)|~(a^b),~(~a&b),~X^Y): New transformations.
4285 2017-11-07  Marc Glisse  <marc.glisse@inria.fr>
4287         * fold-const.c (negate_expr_p) [PLUS_EXPR, MINUS_EXPR]: Handle
4288         non-scalar integral types.
4289         * match.pd (negate_expr_p): Handle MINUS_EXPR.
4290         (-(A-B), -(~A)): New transformations.
4292 2017-11-07  Tom de Vries  <tom@codesourcery.com>
4294         * config/powerpcspe/aix43.h (SUBTARGET_OVERRIDE_OPTIONS): Remove
4295         semicolon after "do {} while (0)".
4296         * config/powerpcspe/aix51.h (SUBTARGET_OVERRIDE_OPTIONS): Same.
4297         * config/powerpcspe/aix52.h (SUBTARGET_OVERRIDE_OPTIONS): Same.
4298         * config/powerpcspe/aix53.h (SUBTARGET_OVERRIDE_OPTIONS): Same.
4299         * config/powerpcspe/aix61.h (SUBTARGET_OVERRIDE_OPTIONS): Same.
4300         * config/powerpcspe/aix71.h (SUBTARGET_OVERRIDE_OPTIONS): Same.
4302 2017-11-07  Tom de Vries  <tom@codesourcery.com>
4304         * config/rs6000/aix43.h (SUBTARGET_OVERRIDE_OPTIONS): Remove semicolon
4305         after "do {} while (0)".
4306         * config/rs6000/aix51.h (SUBTARGET_OVERRIDE_OPTIONS): Same.
4307         * config/rs6000/aix52.h (SUBTARGET_OVERRIDE_OPTIONS): Same.
4308         * config/rs6000/aix53.h (SUBTARGET_OVERRIDE_OPTIONS): Same.
4309         * config/rs6000/aix61.h (SUBTARGET_OVERRIDE_OPTIONS): Same.
4310         * config/rs6000/aix71.h (SUBTARGET_OVERRIDE_OPTIONS): Same.
4312 2017-11-07  Tom de Vries  <tom@codesourcery.com>
4314         PR other/82784
4315         * config/arm/arm.c (HANDLE_NARROW_SHIFT_ARITH): Remove semicolon after
4316         "while {} do (0)".
4317         (arm_rtx_costs_internal): Add missing semicolon after
4318         HANDLE_NARROW_SHIFT_ARITH call.
4320 2017-11-06  Segher Boessenkool  <segher@kernel.crashing.org>
4322         * config/rs6000/rs6000.c (rs6000_option_override_internal): Don't
4323         disable isel if it was not set explicitly.
4325 2017-11-06  James Bowman  <james.bowman@ftdichip.com>
4327         * gcc/dwarf2out.c (modified_type_die): Retain ADDR_SPACE qualifiers.
4328         (add_type_attribute) likewise.
4330 2017-11-06  H.J. Lu  <hongjiu.lu@intel.com>
4332         * config/i386/i386.c (ix86_can_use_return_insn_p): Use reference
4333         of struct ix86_frame.
4334         (ix86_initial_elimination_offset): Likewise.
4335         (ix86_expand_split_stack_prologue): Likewise.
4337 2017-11-06  Marc Glisse  <marc.glisse@inria.fr>
4339         * tree-vrp.h (enum value_range_type): Update stale comment.
4341 2017-11-06  Richard Sandiford  <richard.sandiford@linaro.org>
4342             Alan Hayward  <alan.hayward@arm.com>
4343             David Sherwood  <david.sherwood@arm.com>
4345         * config/aarch64/aarch64-protos.h (aarch64_expand_vec_perm)
4346         (aarch64_expand_vec_perm_const): Take the number of units too.
4347         * config/aarch64/aarch64.c (aarch64_expand_vec_perm)
4348         (aarch64_expand_vec_perm_const): Likewise.
4349         * config/aarch64/aarch64-simd.md (vec_perm_const<mode>)
4350         (vec_perm<mode>): Update accordingly.
4352 2017-11-06  Richard Sandiford  <richard.sandiford@linaro.org>
4353             Alan Hayward  <alan.hayward@arm.com>
4354             David Sherwood  <david.sherwood@arm.com>
4356         * config/aarch64/aarch64-protos.h (aarch64_simd_vect_par_cnst_half):
4357         Take the number of units too.
4358         * config/aarch64/aarch64.c (aarch64_simd_vect_par_cnst_half): Likewise.
4359         (aarch64_simd_check_vect_par_cnst_half): Update call accordingly,
4360         but check for a vector mode before rather than after the call.
4361         * config/aarch64/aarch64-simd.md (aarch64_split_simd_mov<mode>)
4362         (move_hi_quad_<mode>, vec_unpack<su>_hi_<mode>)
4363         (vec_unpack<su>_lo_<mode, vec_widen_<su>mult_lo_<mode>)
4364         (vec_widen_<su>mult_hi_<mode>, vec_unpacks_lo_<mode>)
4365         (vec_unpacks_hi_<mode>, aarch64_saddl2<mode>, aarch64_uaddl2<mode>)
4366         (aarch64_ssubl2<mode>, aarch64_usubl2<mode>, widen_ssum<mode>3)
4367         (widen_usum<mode>3, aarch64_saddw2<mode>, aarch64_uaddw2<mode>)
4368         (aarch64_ssubw2<mode>, aarch64_usubw2<mode>, aarch64_sqdmlal2<mode>)
4369         (aarch64_sqdmlsl2<mode>, aarch64_sqdmlal2_lane<mode>)
4370         (aarch64_sqdmlal2_laneq<mode>, aarch64_sqdmlsl2_lane<mode>)
4371         (aarch64_sqdmlsl2_laneq<mode>, aarch64_sqdmlal2_n<mode>)
4372         (aarch64_sqdmlsl2_n<mode>, aarch64_sqdmull2<mode>)
4373         (aarch64_sqdmull2_lane<mode>, aarch64_sqdmull2_laneq<mode>)
4374         (aarch64_sqdmull2_n<mode>): Update accordingly.
4376 2017-11-06  Richard Sandiford  <richard.sandiford@linaro.org>
4377             Alan Hayward  <alan.hayward@arm.com>
4378             David Sherwood  <david.sherwood@arm.com>
4380         * config/aarch64/aarch64-protos.h (aarch64_reverse_mask): Take
4381         the number of units too.
4382         * config/aarch64/aarch64.c (aarch64_reverse_mask): Likewise.
4383         * config/aarch64/aarch64-simd.md (vec_load_lanesoi<mode>)
4384         (vec_store_lanesoi<mode>, vec_load_lanesci<mode>)
4385         (vec_store_lanesci<mode>, vec_load_lanesxi<mode>)
4386         (vec_store_lanesxi<mode>): Update accordingly.
4388 2017-11-06  Richard Sandiford  <richard.sandiford@linaro.org>
4389             Alan Hayward  <alan.hayward@arm.com>
4390             David Sherwood  <david.sherwood@arm.com>
4392         * config/aarch64/aarch64-protos.h (aarch64_endian_lane_rtx): Declare.
4393         * config/aarch64/aarch64.c (aarch64_endian_lane_rtx): New function.
4394         * config/aarch64/aarch64.h (ENDIAN_LANE_N): Take the number
4395         of units rather than the mode.
4396         * config/aarch64/iterators.md (nunits): New mode attribute.
4397         * config/aarch64/aarch64-builtins.c (aarch64_simd_expand_args):
4398         Use aarch64_endian_lane_rtx instead of GEN_INT (ENDIAN_LANE_N ...).
4399         * config/aarch64/aarch64-simd.md (aarch64_dup_lane<mode>)
4400         (aarch64_dup_lane_<vswap_width_name><mode>, *aarch64_mul3_elt<mode>)
4401         (*aarch64_mul3_elt_<vswap_width_name><mode>): Likewise.
4402         (*aarch64_mul3_elt_to_64v2df, *aarch64_mla_elt<mode>): Likewise.
4403         (*aarch64_mla_elt_<vswap_width_name><mode>, *aarch64_mls_elt<mode>)
4404         (*aarch64_mls_elt_<vswap_width_name><mode>, *aarch64_fma4_elt<mode>)
4405         (*aarch64_fma4_elt_<vswap_width_name><mode>):: Likewise.
4406         (*aarch64_fma4_elt_to_64v2df, *aarch64_fnma4_elt<mode>): Likewise.
4407         (*aarch64_fnma4_elt_<vswap_width_name><mode>): Likewise.
4408         (*aarch64_fnma4_elt_to_64v2df, reduc_plus_scal_<mode>): Likewise.
4409         (reduc_plus_scal_v4sf, reduc_<maxmin_uns>_scal_<mode>): Likewise.
4410         (reduc_<maxmin_uns>_scal_<mode>): Likewise.
4411         (*aarch64_get_lane_extend<GPI:mode><VDQQH:mode>): Likewise.
4412         (*aarch64_get_lane_zero_extendsi<mode>): Likewise.
4413         (aarch64_get_lane<mode>, *aarch64_mulx_elt_<vswap_width_name><mode>)
4414         (*aarch64_mulx_elt<mode>, *aarch64_vgetfmulx<mode>): Likewise.
4415         (aarch64_sq<r>dmulh_lane<mode>, aarch64_sq<r>dmulh_laneq<mode>)
4416         (aarch64_sqrdml<SQRDMLH_AS:rdma_as>h_lane<mode>): Likewise.
4417         (aarch64_sqrdml<SQRDMLH_AS:rdma_as>h_laneq<mode>): Likewise.
4418         (aarch64_sqdml<SBINQOPS:as>l_lane<mode>): Likewise.
4419         (aarch64_sqdml<SBINQOPS:as>l_laneq<mode>): Likewise.
4420         (aarch64_sqdml<SBINQOPS:as>l2_lane<mode>_internal): Likewise.
4421         (aarch64_sqdml<SBINQOPS:as>l2_laneq<mode>_internal): Likewise.
4422         (aarch64_sqdmull_lane<mode>, aarch64_sqdmull_laneq<mode>): Likewise.
4423         (aarch64_sqdmull2_lane<mode>_internal): Likewise.
4424         (aarch64_sqdmull2_laneq<mode>_internal): Likewise.
4425         (aarch64_vec_load_lanesoi_lane<mode>): Likewise.
4426         (aarch64_vec_store_lanesoi_lane<mode>): Likewise.
4427         (aarch64_vec_load_lanesci_lane<mode>): Likewise.
4428         (aarch64_vec_store_lanesci_lane<mode>): Likewise.
4429         (aarch64_vec_load_lanesxi_lane<mode>): Likewise.
4430         (aarch64_vec_store_lanesxi_lane<mode>): Likewise.
4431         (aarch64_simd_vec_set<mode>): Update use of ENDIAN_LANE_N.
4432         (aarch64_simd_vec_setv2di): Likewise.
4434 2017-11-06  Carl Love  <cel@us.ibm.com>
4436         * config/rs6000/rs6000-c.c (P8V_BUILTIN_VEC_REVB): Add power 8
4437         definitions.
4438         (P9V_BUILTIN_VEC_REVB): Remove the power 9 instance definitions.
4439         * config/rs6000/altivec.h (vec_revb): Change the #define from power 9
4440         to power 8.
4441         * config/rs6000/r6000-protos.h (swap_endian_selector_for_mode): Add new
4442         extern declaration.
4443         * config/rs6000/rs6000.c (swap_endian_selector_for_mode): Add function.
4444         * config/rs6000/rs6000-builtin.def (BU_P8V_VSX_1, BU_P8V_OVERLOAD_1):
4445         Add power 8 macro expansions.
4446         (BU_P9V_OVERLOAD_1): Remove power 9 overload expansion.
4447         * config/rs6000/vsx.md (revb_<mode>): Add define_expand to generate
4448         power 8 instructions.  (VSX_XXBR): Add iterator.
4450 2017-11-06  Wilco Dijkstra  <wdijkstr@arm.com>
4452         * config/arm/arm.md (predicable_short_it): Change default to "no",
4453         improve documentation, remove uses that are identical to the default.
4454         (enabled_for_depr_it): Rename to enabled_for_short_it.
4455         * gcc/config/arm/arm-fixed.md (predicable_short_it):
4456         Remove default uses.
4457         * gcc/config/arm/ldmstm.md (predicable_short_it): Likewise.
4458         * gcc/config/arm/sync.md (predicable_short_it): Likewise.
4459         * gcc/config/arm/thumb2.md (predicable_short_it): Likewise.
4460         * gcc/config/arm/vfp.md (predicable_short_it): Likewise.
4462 2017-11-06  Michael Meissner  <meissner@linux.vnet.ibm.com>
4464         PR target/82748
4465         * config/rs6000/rs6000-builtin.def (BU_FLOAT128_1): Delete
4466         float128 helper macros, which are no longer used after deleting
4467         the old 'q' built-in functions, and moving the round to odd
4468         built-in functions to being special built-in functions.
4469         (BU_FLOAT128_2): Likewise.
4470         (BU_FLOAT128_1_HW): Likewise.
4471         (BU_FLOAT128_2_HW): Likewise.
4472         (BU_FLOAT128_3_HW): Likewise.
4473         (FABSQ): Delete old 'q' built-in functions.
4474         (COPYSIGNQ): Likewise.
4475         (SQRTF128_ODD): Move round to odd built-in functions to be
4476         special built-in functions, so that we can handle
4477         -mabi=ieeelongdouble.
4478         (TRUNCF128_ODD): Likewise.
4479         (ADDF128_ODD): Likewise.
4480         (SUBF128_ODD): Likewise.
4481         (MULF128_ODD): Likewise.
4482         (DIVF128_ODD): Likewise.
4483         (FMAF128_ODD): Likewise.
4484         * config/rs6000/rs6000-c.c (rs6000_cpu_cpp_builtins): Map old 'q'
4485         built-in names to 'f128'.
4486         * config/rs6000/rs6000.c (rs6000_fold_builtin): Remove folding the
4487         old 'q' built-in functions, as the machine independent code for
4488         'f128' built-in functions handles this.
4489         (rs6000_expand_builtin): Add expansion for float128 round to odd
4490         functions, keying off on -mabi=ieeelongdouble of whether to use
4491         the KFmode or TFmode variant.
4492         (rs6000_init_builtins): Initialize the _Float128 round to odd
4493         built-in functions.
4494         * doc/extend.texi (PowerPC Built-in Functions): Document the old
4495         _Float128 'q' built-in functions are now mapped into the new
4496         'f128' built-in functions.
4498 2017-11-06  David Edelsohn  <dje.gcc@gmail.com>
4500         * collect2.c (add_lto_object): Compile for OBJECT_COFF.
4501         (scan_prog_file): Don't skip PASS_LTOINFO. Scan for LTO objects.
4503 2017-11-06  David Malcolm  <dmalcolm@redhat.com>
4505         PR jit/82826
4506         * ipa-fnsummary.c (ipa_fnsummary_c_finalize): New function.
4507         * ipa-fnsummary.h (ipa_fnsummary_c_finalize): New decl.
4508         * toplev.c: Include "ipa-fnsummary.h".
4509         (toplev::finalize): Call ipa_fnsummary_c_finalize.
4511 2017-11-06  Jakub Jelinek  <jakub@redhat.com>
4513         PR tree-optimization/82838
4514         * gimple-ssa-store-merging.c
4515         (imm_store_chain_info::output_merged_store): Call force_gimple_operand_1
4516         on a separate gimple_seq which is then appended to seq.
4518 2017-11-06  Jeff Law  <law@redhat.com>
4520         PR target/82788
4521         * config/i386/i386.c (PROBE_INTERVAL): Remove.
4522         (get_probe_interval): New functions.
4523         (ix86_adjust_stack_and_probe_stack_clash): Use get_probe_interval.
4524         (ix86_adjust_stack_and_probe): Likewise.
4525         (output_adjust_stack_and_probe): Likewise.
4526         (ix86_emit_probe_stack_range): Likewise.
4527         (ix86_expand_prologue): Likewise.
4529 2017-11-06  Richard Sandiford  <richard.sandiford@linaro.org>
4531         PR tree-optimization/82816
4532         * tree-ssa-math-opts.c (convert_mult_to_widen): Return false
4533         if the modes of the two types are the same.
4534         (convert_plusminus_to_widen): Likewise.
4536 2017-11-06  Bill Schmidt  <wschmidt@linux.vnet.ibm.com>
4538         * config/rs6000/altivec.md (*p9_vadu<mode>3) Rename to
4539         p9_vadu<mode>3.
4540         (usadv16qi): New define_expand.
4541         (usadv8hi): New define_expand.
4543 2017-11-06  Jan Hubicka  <hubicka@ucw.cz>
4545         PR bootstrap/82832
4546         * ipa-inline-transform.c (update_noncloned_frequencies): Always
4547         scale.
4548         (inline_transform): Likewise.
4549         * predict.c (counts_to_freqs): Remove useless conditional.
4550         * profile-count.h (profile_count::apply_scale): Move sanity check.
4551         * tree-inline.c (copy_bb): Always scale.
4552         (copy_cfg_body): Likewise.
4554 2017-11-06  Christophe Lyon  <christophe.lyon@linaro.org>
4556         PR target/67591
4557         * config/arm/arm.md (*sub_shiftsi): Add predicable_short_it
4558         attribute.
4559         (*cmp_ite0): Add enabled_for_depr_it attribute.
4560         (*cmp_ite1): Likewise.
4562 2017-11-06  Segher Boessenkool  <segher@kernel.crashing.org>
4564         * config/rs6000/rs6000.c (rs6000_insn_cost): Handle TYPE_MFCR and
4565         TYPE_MFCRF.
4567 2017-11-06  Richard Sandiford  <richard.sandiford@linaro.org>
4569         * tree-vrp.c (vrp_int_const_binop): Return true on success and
4570         return the value by pointer.
4571         (extract_range_from_multiplicative_op_1): Update accordingly.
4572         Return as soon as an operation fails.
4574 2017-11-05  Tom de Vries  <tom@codesourcery.com>
4576         PR other/82784
4577         * asan.c (DEF_SANITIZER_BUILTIN_1): Factor out of ...
4578         (DEF_SANITIZER_BUILTIN): ... here.
4579         (initialize_sanitizer_builtins): Use DEF_SANITIZER_BUILTIN_1 instead of
4580         DEF_SANITIZER_BUILTIN in if stmt.  Add missing semicolon.
4582 2017-11-05  Tom de Vries  <tom@codesourcery.com>
4584         PR other/82784
4585         * config/elfos.h (ASM_OUTPUT_BEFORE_CASE_LABEL): Remove semicolon after
4586         macro body.
4587         (ASM_OUTPUT_CASE_LABEL): Add semicolon after
4588         ASM_OUTPUT_BEFORE_CASE_LABEL call.
4589         * config/arc/arc.h (ASM_OUTPUT_BEFORE_CASE_LABEL): Remove semicolon
4590         after macro body.
4591         * config/m68k/m68kelf.h (ASM_OUTPUT_BEFORE_CASE_LABEL): Same.
4592         * config/mips/mips.h (ASM_OUTPUT_BEFORE_CASE_LABEL): Same.
4593         * config/v850/v850.h (ASM_OUTPUT_BEFORE_CASE_LABEL): Same.
4595 2017-11-05  Tom de Vries  <tom@codesourcery.com>
4597         PR other/82784
4598         * graphite-scop-detection.c (DEBUG_PRINT): Remove semicolon after
4599         "do {} while (0)".
4601 2017-11-04  Michael Clark  <michaeljclark@mac.com>
4603         * config/riscv/riscv.c (riscv_print_operand): Add a 'i' format.
4604         config/riscv/riscv.md (addsi3): Use 'i' for immediates.
4605         (adddi3): Likewise.
4606         (*addsi3_extended): Likewise.
4607         (*addsi3_extended2): Likewise.
4608         (<optab>si3): Likewise.
4609         (<optab>di3): Likewise.
4610         (<optab><mode>3): Likewise.
4611         (<*optabe>si3_internal): Likewise.
4612         (zero_extendqi<SUPERQI:mode>2): Likewise.
4613         (*add<mode>hi3): Likewise.
4614         (*xor<mode>hi3): Likewise.
4615         (<optab>di3): Likewise.
4616         (*<optab>si3_extend): Likewise.
4617         (*sge<u>_<X:mode><GPR:mode>): Likewise.
4618         (*slt<u>_<X:mode><GPR:mode>): Likewise.
4619         (*sle<u>_<X:mode><GPR:mode>): Likewise.
4621 2017-11-04  Andrew Waterman  <andrew@sifive.com>
4623         * config/riscv/riscv.c (riscv_option_override): Conditionally set
4624         TARGET_STRICT_ALIGN based upon -mtune argument.
4626 2017-11-04  Andrew Waterman  <andrew@sifive.com>
4628         * config/riscv/riscv.h (SLOW_BYTE_ACCESS): Change to 1.
4630 2017-11-04  Daniel Santos  <daniel.santos@pobox.com>
4632         * config/i386/i386.c (choose_basereg): Use optional scratch
4633         register and add assertion.
4634         (x86_emit_outlined_ms2sysv_save): Use scratch register when
4635         needed, and don't allocate stack.
4636         (ix86_expand_prologue): Rearrange where SSE saves/stub call is
4637         emitted, correct wrong allocation with -mcall-ms2sysv-xlogues.
4638         (ix86_emit_outlined_ms2sysv_restore): Fix non-immediate offsets.
4640 2017-11-03  Jeff Law  <law@redhat.com>
4642         * config/i386/i386.c (ix86_emit_restore_reg_using_pop): Prototype.
4643         (ix86_adjust_stack_and_probe_stack_clash): Use a push/pop sequence
4644         to probe at the start of a noreturn function.
4646 2017-11-03  Jakub Jelinek  <jakub@redhat.com>
4648         PR tree-optimization/78821
4649         * gimple-ssa-store-merging.c: Update the file comment.
4650         (MAX_STORE_ALIAS_CHECKS): Define.
4651         (struct store_operand_info): New type.
4652         (store_operand_info::store_operand_info): New constructor.
4653         (struct store_immediate_info): Add rhs_code and ops data members.
4654         (store_immediate_info::store_immediate_info): Add rhscode, op0r
4655         and op1r arguments to the ctor, initialize corresponding data members.
4656         (struct merged_store_group): Add load_align_base and load_align
4657         data members.
4658         (merged_store_group::merged_store_group): Initialize them.
4659         (merged_store_group::do_merge): Update them.
4660         (merged_store_group::apply_stores): Pick the constant for
4661         encode_tree_to_bitpos from one of the two operands, or skip
4662         encode_tree_to_bitpos if neither operand is a constant.
4663         (class pass_store_merging): Add process_store method decl.  Remove
4664         bool argument from terminate_all_aliasing_chains method decl.
4665         (pass_store_merging::terminate_all_aliasing_chains): Remove
4666         var_offset_p argument and corresponding handling.
4667         (stmts_may_clobber_ref_p): New function.
4668         (compatible_load_p): New function.
4669         (imm_store_chain_info::coalesce_immediate_stores): Terminate group
4670         if there is overlap and rhs_code is not INTEGER_CST.  For
4671         non-overlapping stores terminate group if rhs is not mergeable.
4672         (get_alias_type_for_stmts): Change first argument from
4673         auto_vec<gimple *> & to vec<gimple *> &.  Add IS_LOAD, CLIQUEP and
4674         BASEP arguments.  If IS_LOAD is true, look at rhs1 of the stmts
4675         instead of lhs.  Compute *CLIQUEP and *BASEP in addition to the
4676         alias type.
4677         (get_location_for_stmts): Change first argument from
4678         auto_vec<gimple *> & to vec<gimple *> &.
4679         (struct split_store): Remove orig_stmts data member, add orig_stores.
4680         (split_store::split_store): Create orig_stores rather than orig_stmts.
4681         (find_constituent_stmts): Renamed to ...
4682         (find_constituent_stores): ... this.  Change second argument from
4683         vec<gimple *> * to vec<store_immediate_info *> *, push pointers
4684         to info structures rather than the statements.
4685         (split_group): Rename ALLOW_UNALIGNED argument to
4686         ALLOW_UNALIGNED_STORE, add ALLOW_UNALIGNED_LOAD argument and handle
4687         it.  Adjust find_constituent_stores caller.
4688         (imm_store_chain_info::output_merged_store): Handle rhs_code other
4689         than INTEGER_CST, adjust split_group, get_alias_type_for_stmts and
4690         get_location_for_stmts callers.  Set MR_DEPENDENCE_CLIQUE and
4691         MR_DEPENDENCE_BASE on the MEM_REFs if they are the same in all stores.
4692         (mem_valid_for_store_merging): New function.
4693         (handled_load): New function.
4694         (pass_store_merging::process_store): New method.
4695         (pass_store_merging::execute): Use process_store method.  Adjust
4696         terminate_all_aliasing_chains caller.
4698 2017-11-03  Wilco Dijkstra  <wdijkstr@arm.com>
4700         * config/aarch64/aarch64.c (aarch64_legitimate_constant_p):
4701         Return true for more constants, symbols and label references.
4702         (aarch64_valid_floating_const): Remove unused function.
4704 2017-11-03  Wilco Dijkstra  <wdijkstr@arm.com>
4706         PR target/82786
4707         * config/aarch64/aarch64.c (aarch64_layout_frame):
4708         Undo forcing of LR at bottom of frame.
4710 2017-11-03  Jeff Law  <law@redhat.com>
4712         PR target/82823
4713         * config/i386/i386.c (ix86_expand_prologue): Tighten assert
4714         for int_registers_saved.
4716         * cfganal.c (single_pred_edge_ignoring_loop_edges): New function
4717         extracted from tree-ssa-dom.c.
4718         * cfganal.h (single_pred_edge_ignoring_loop_edges): Prototype.
4719         * tree-ssa-dom.c (single_incoming_edge_ignoring_loop_edges): Remove.
4720         (record_equivalences_from_incoming_edge): Add additional argument
4721         to single_pred_edge_ignoring_loop_edges call.
4722         * tree-ssa-uncprop.c (single_incoming_edge_ignoring_loop_edges): Remove.
4723         (uncprop_dom_walker::before_dom_children): Add additional argument
4724         to single_pred_edge_ignoring_loop_edges call.
4725         * tree-ssa-sccvn.c (sccvn_dom_walker::before_dom_children): Use
4726         single_pred_edge_ignoring_loop_edges rather than open coding.
4727         * tree-vrp.c (evrp_dom_walker::before_dom_children): Similarly.
4729 2017-11-03  Marc Glisse  <marc.glisse@inria.fr>
4731         * match.pd (-(-A)): Rewrite.
4733 2017-11-03  Segher Boessenkool  <segher@kernel.crashing.org>
4735         * config/rs6000/rs60000-protos.h (rs6000_emit_sISEL): Delete.
4736         (rs6000_emit_int_cmove): New declaration.
4737         * config/rs6000/rs6000.c (rs6000_emit_int_cmove): Delete declaration.
4738         (rs6000_emit_sISEL): Delete.
4739         (rs6000_emit_int_cmove): Make non-static.
4740         * config/rs6000/rs6000.md (cstore<mode>4): Use rs6000_emit_int_cmove
4741         instead of rs6000_emit_sISEL.
4743 2017-11-03  Jan Hubicka  <hubicka@ucw.cz>
4745         * asan.c (create_cond_insert_point): Maintain profile.
4746         * ipa-utils.c (ipa_merge_profiles): Be sure only IPA profiles are
4747         merged.
4748         * basic-block.h (struct basic_block_def): Remove frequency.
4749         (EDGE_FREQUENCY): Use to_frequency
4750         * bb-reorder.c (push_to_next_round_p): Use only IPA counts for global
4751         heuristics.
4752         (find_traces): Update to use to_frequency.
4753         (find_traces_1_round): Likewise; use only IPA counts.
4754         (bb_to_key): Likewise.
4755         (connect_traces): Use IPA counts only.
4756         (copy_bb_p): Update to use to_frequency.
4757         (fix_up_crossing_landing_pad): Likewise.
4758         (sanitize_hot_paths): Likewise.
4759         * bt-load.c (basic_block_freq): Likewise.
4760         * cfg.c (init_flow): Set count_max to uninitialized.
4761         (check_bb_profile): Remove frequencies; check counts.
4762         (dump_bb_info): Do not dump frequencies.
4763         (update_bb_profile_for_threading): Update counts only.
4764         (scale_bbs_frequencies_int): Likewise.
4765         (MAX_SAFE_MULTIPLIER): Remove.
4766         (scale_bbs_frequencies_gcov_type): Update counts only.
4767         (scale_bbs_frequencies_profile_count): Update counts only.
4768         (scale_bbs_frequencies): Update counts only.
4769         * cfg.h (struct control_flow_graph): Add count-max.
4770         (update_bb_profile_for_threading): Update prototype.
4771         * cfgbuild.c (find_bb_boundaries): Do not update frequencies.
4772         (find_many_sub_basic_blocks): Likewise.
4773         * cfgcleanup.c (try_forward_edges): Likewise.
4774         (try_crossjump_to_edge): Likewise.
4775         * cfgexpand.c (expand_gimple_cond): Likewise.
4776         (expand_gimple_tailcall): Likewise.
4777         (construct_init_block): Likewise.
4778         (construct_exit_block): Likewise.
4779         * cfghooks.c (verify_flow_info): Check consistency of counts.
4780         (dump_bb_for_graph): Do not dump frequencies.
4781         (split_block_1): Do not update frequencies.
4782         (split_edge): Do not update frequencies.
4783         (make_forwarder_block): Do not update frequencies.
4784         (duplicate_block): Do not update frequencies.
4785         (account_profile_record): Do not update frequencies.
4786         * cfgloop.c (find_subloop_latch_edge_by_profile): Use IPA counts
4787         for global heuristics.
4788         * cfgloopanal.c (average_num_loop_insns): Update to use to_frequency.
4789         (expected_loop_iterations_unbounded): Use counts only.
4790         * cfgloopmanip.c (scale_loop_profile): Simplify.
4791         (create_empty_loop_on_edge): Simplify
4792         (loopify): Simplify
4793         (duplicate_loop_to_header_edge): Simplify
4794         * cfgrtl.c (force_nonfallthru_and_redirect): Update profile.
4795         (update_br_prob_note): Take care of removing note when profile
4796         becomes undefined.
4797         (relink_block_chain): Do not dump frequency.
4798         (rtl_account_profile_record): Use to_frequency.
4799         * cgraph.c (symbol_table::create_edge): Convert count to ipa count.
4800         (cgraph_edge::redirect_call_stmt_to_calle): Conver tcount to ipa count.
4801         (cgraph_update_edges_for_call_stmt_node): Likewise.
4802         (cgraph_edge::verify_count_and_frequency): Update.
4803         (cgraph_node::verify_node): Temporarily disable frequency verification.
4804         * cgraphbuild.c (compute_call_stmt_bb_frequency): Use
4805         to_cgraph_frequency.
4806         (cgraph_edge::rebuild_edges): Convert to ipa counts.
4807         * cgraphunit.c (init_lowered_empty_function): Do not initialize
4808         frequencies.
4809         (cgraph_node::expand_thunk): Update profile.
4810         * except.c (dw2_build_landing_pads): Do not update frequency.
4811         * final.c (compute_alignments): Use to_frequency.
4812         (dump_basic_block_info): Do not dump frequency.
4813         * gimple-pretty-print.c (dump_profile): Do not dump frequency.
4814         (dump_gimple_bb_header): Do not dump frequency.
4815         * gimple-ssa-isolate-paths.c (isolate_path): Do not update frequency;
4816         do update count.
4817         * gimple-streamer-in.c (input_bb): Do not stream frequency.
4818         * gimple-streamer-out.c (output_bb): Do not stream frequency.
4819         * haifa-sched.c (sched_pressure_start_bb): Use to_freuqency.
4820         (init_before_recovery): Do not update frequency.
4821         (sched_create_recovery_edges): Do not update frequency.
4822         * hsa-gen.c (convert_switch_statements): Do not update frequency.
4823         * ipa-cp.c (ipcp_propagate_stage): Update search for max_count.
4824         (ipa_cp_c_finalize): Set max_count to uninitialized.
4825         * ipa-fnsummary.c (get_minimal_bb): Use counts.
4826         (param_change_prob): Use counts.
4827         * ipa-profile.c (ipa_profile_generate_summary): Do not summarize
4828         local profiles.
4829         * ipa-split.c (consider_split): Use to_frequency.
4830         (split_function): Use to_frequency.
4831         * ira-build.c (loop_compare_func): Likewise.
4832         (mark_loops_for_removal): Likewise.
4833         (mark_all_loops_for_removal): Likewise.
4834         * loop-doloop.c (doloop_modify): Do not update frequency.
4835         * loop-unroll.c (unroll_loop_runtime_iterations): Do not update
4836         frequency.
4837         * lto-streamer-in.c (input_function): Update count_max.
4838         * omp-expand.c (expand_omp_taskreg): Update count_max.
4839         * omp-simd-clone.c (simd_clone_adjust): Update profile.
4840         * predict.c (maybe_hot_frequency_p): Use to_frequency.
4841         (maybe_hot_count_p): Use ipa counts only.
4842         (maybe_hot_bb_p): Simplify.
4843         (maybe_hot_edge_p): Simplify.
4844         (probably_never_executed): Do not take frequency argument.
4845         (probably_never_executed_bb_p): Do not pass frequency.
4846         (probably_never_executed_edge_p): Likewise.
4847         (combine_predictions_for_bb): Check that profile is nonzero.
4848         (propagate_freq): Do not set frequency.
4849         (drop_profile): Simplify.
4850         (counts_to_freqs): Simplify.
4851         (expensive_function_p): Use to_frequency.
4852         (propagate_unlikely_bbs_forward): Simplify.
4853         (determine_unlikely_bbs): Simplify.
4854         (estimate_bb_frequencies): Add hack to silence graphite issues.
4855         (compute_function_frequency): Use ipa counts.
4856         (pass_profile::execute): Update.
4857         (rebuild_frequencies): Use counts only.
4858         (force_edge_cold): Use counts only.
4859         * profile-count.c (profile_count::dump): Dump new count types.
4860         (profile_count::differs_from_p): Check compatiblity.
4861         (profile_count::to_frequency): New function.
4862         (profile_count::to_cgraph_frequency): New function.
4863         * profile-count.h (struct function): Declare.
4864         (enum profile_quality): Add profile_guessed_local and
4865         profile_guessed_global0.
4866         (class profile_proability): Decrease number of bits to 29;
4867         update from_reg_br_prob_note and to_reg_br_prob_note.
4868         (class profile_count: Update comment; decrease number of bits
4869         to 61. Check compatibility.
4870         (profile_count::compatible_p): New private member function.
4871         (profile_count::ipa_p): New member function.
4872         (profile_count::operator<): Handle global zero correctly.
4873         (profile_count::operator>): Handle global zero correctly.
4874         (profile_count::operator<=): Handle global zero correctly.
4875         (profile_count::operator>=): Handle global zero correctly.
4876         (profile_count::nonzero_p): New member function.
4877         (profile_count::force_nonzero): New member function.
4878         (profile_count::max): New member function.
4879         (profile_count::apply_scale): Handle IPA scalling.
4880         (profile_count::guessed_local): New member function.
4881         (profile_count::global0): New member function.
4882         (profile_count::ipa): New member function.
4883         (profile_count::to_frequency): Declare.
4884         (profile_count::to_cgraph_frequency): Declare.
4885         * profile.c (OVERLAP_BASE): Delete.
4886         (compute_frequency_overlap): Delete.
4887         (compute_branch_probabilities): Do not use compute_frequency_overlap.
4888         * regs.h (REG_FREQ_FROM_BB): Use to_frequency.
4889         * sched-ebb.c (rank): Use counts only.
4890         * shrink-wrap.c (handle_simple_exit): Use counts only.
4891         (try_shrink_wrapping): Use counts only.
4892         (place_prologue_for_one_component): Use counts only.
4893         * tracer.c (find_best_predecessor): Use to_frequency.
4894         (find_trace): Use to_frequency.
4895         (tail_duplicate): Use to_frequency.
4896         * trans-mem.c (expand_transaction): Do not update frequency.
4897         * tree-call-cdce.c: Do not update frequency.
4898         * tree-cfg.c (gimple_find_sub_bbs): Likewise.
4899         (gimple_merge_blocks): Likewise.
4900         (gimple_split_edge): Likewise.
4901         (gimple_duplicate_sese_region): Likewise.
4902         (gimple_duplicate_sese_tail): Likewise.
4903         (move_sese_region_to_fn): Likewise.
4904         (gimple_account_profile_record): Likewise.
4905         (insert_cond_bb): Likewise.
4906         * tree-complex.c (expand_complex_div_wide): Likewise.
4907         * tree-eh.c (lower_resx): Update profile.
4908         * tree-inline.c (copy_bb): Simplify count scaling; do not scale
4909         frequencies.
4910         (initialize_cfun): Do not initialize frequencies
4911         (freqs_to_counts): Delete.
4912         (copy_cfg_body): Ignore count parameter.
4913         (copy_body): Update.
4914         (expand_call_inline): Update count_max.
4915         (optimize_inline_calls): Update count_max.
4916         (tree_function_versioning): Update count_max.
4917         * tree-ssa-coalesce.c (coalesce_cost_bb): Use to_frequency.
4918         * tree-ssa-ifcombine.c (update_profile_after_ifcombine): Do not update
4919         frequency.
4920         * tree-ssa-loop-im.c (execute_sm_if_changed): Use counts only.
4921         * tree-ssa-loop-ivcanon.c (unloop_loops): Do not update freuqency.
4922         (try_peel_loop): Likewise.
4923         * tree-ssa-loop-ivopts.c (get_scaled_computation_cost_at): Use
4924         to_frequency.
4925         * tree-ssa-loop-manip.c (niter_for_unrolled_loop): Pass -1.
4926         (tree_transform_and_unroll_loop): Do not use frequencies
4927         * tree-ssa-loop-niter.c (estimate_numbers_of_iterations):
4928         Use reliable prediction only.
4929         * tree-ssa-loop-unswitch.c (hoist_guard): Do not use frequencies.
4930         * tree-ssa-sink.c (select_best_block): Use to_frequency.
4931         * tree-ssa-tail-merge.c (replace_block_by): Temporarily disable
4932         probability scaling.
4933         * tree-ssa-threadupdate.c (create_block_for_threading): Do
4934         not update frequency
4935         (any_remaining_duplicated_blocks): Likewise.
4936         (update_profile): Likewise.
4937         (estimated_freqs_path): Delete.
4938         (freqs_to_counts_path): Delete.
4939         (clear_counts_path): Delete.
4940         (ssa_fix_duplicate_block_edges): Likewise.
4941         (duplicate_thread_path): Likewise.
4942         * tree-switch-conversion.c (gen_inbound_check): Use counts.
4943         * tree-tailcall.c (decrease_profile): Do not update frequency.
4944         (eliminate_tail_call): Likewise.
4945         * tree-vect-loop-manip.c (vect_do_peeling): Likewise.
4946         * tree-vect-loop.c (scale_profile_for_vect_loop): Likewise.
4947         (optimize_mask_stores): Likewise.
4948         * tree-vect-stmts.c (vectorizable_simd_clone_call): Likewise.
4949         * ubsan.c (ubsan_expand_null_ifn): Update profile.
4950         (ubsan_expand_ptr_ifn): Update profile.
4951         * value-prof.c (gimple_ic): Simplify.
4952         * value-prof.h (gimple_ic): Update prototype.
4953         * ipa-inline-transform.c (inline_transform): Fix scaling conditoins.
4954         * ipa-inline.c (compute_uninlined_call_time): Be sure that
4955         counts are nonzero.
4956         (want_inline_self_recursive_call_p): Likewise.
4957         (resolve_noninline_speculation): Only cummulate defined counts.
4958         (inline_small_functions): Use nonzero_p.
4959         (ipa_inline): Do not access freed node.
4961 2017-11-03  Wilco Dijkstra  <wdijkstr@arm.com>
4963         * config/aarch64/aarch64.c (aarch64_override_options_internal):
4964         Set PARAM_SCHED_PRESSURE_ALGORITHM to SCHED_PRESSURE_MODEL.
4966 2017-11-03  Kito Cheng  <kito.cheng@gmail.com>
4968         * config/riscv/riscv.c (riscv_legitimize_move): Handle
4969         non-legitimate address.
4971 2017-11-03  Segher Boessenkool  <segher@kernel.crashing.org>
4973         * config/rs6000/rs6000.md (*lt0_disi): Delete.
4974         (*lt0_<mode>di, *lt0_<mode>si): New.
4976 2017-11-03  Segher Boessenkool  <segher@kernel.crashing.org>
4978         * config/rs6000/rs6000.md (move_from_CR_ov_bit): Change condition to
4979         TARGET_PAIRED_FLOAT.
4981 2017-11-03  Siddhesh Poyarekar  <siddhesh.poyarekar@linaro.org>
4982             Jim Wilson  <jim.wilson@linaro.org>
4984         * config/aarch64/aarch64-cores.def (saphira): New CPU.
4985         * config/aarch64/aarch64-tune.md: Regenerated.
4986         * doc/invoke.texi (AArch64 Options/-mtune): Add "saphira".
4987         * gcc/config/aarch64/aarch64.c (saphira_tunings): New tuning table.
4989 2017-11-03  Cupertino Miranda  <cmiranda@synopsys.com>
4991         * config/arc/arc.c (arc_save_restore): Corrected CFA note.
4992         (arc_expand_prologue): Restore blink for millicode.
4993         * config/arc/linux.h (LINK_EH_SPEC): Defined.
4995 2017-11-03  Richard Sandiford  <richard.sandiford@linaro.org>
4997         PR target/82809
4998         * config/i386/i386.c (ix86_vector_duplicate_value): Use
4999         gen_vec_duplicate after forcing the scalar into a register.
5001 2017-11-02  Segher Boessenkool  <segher@kernel.crashing.org>
5003         * combine (try_combine): Print the insns input to try_combine to the
5004         dump file.
5006 2017-11-02  Steve Ellcey  <sellcey@cavium.com>
5008         PR target/79868
5009         * config/aarch64/aarch64-c.c (aarch64_pragma_target_parse):
5010         Remove second argument from aarch64_process_target_attr call.
5011         * config/aarch64/aarch64-protos.h (aarch64_process_target_attr):
5012         Ditto.
5013         * config/aarch64/aarch64.c (aarch64_attribute_info): Change
5014         field type.
5015         (aarch64_handle_attr_arch): Remove second argument.
5016         (aarch64_handle_attr_cpu): Ditto.
5017         (aarch64_handle_attr_tune): Ditto.
5018         (aarch64_handle_attr_isa_flags): Ditto.
5019         (aarch64_process_one_target_attr): Ditto.
5020         (aarch64_process_target_attr): Ditto.
5021         (aarch64_option_valid_attribute_p): Remove second argument.
5022         on aarch64_process_target_attr call.
5024 2017-11-02  David Malcolm  <dmalcolm@redhat.com>
5026         * diagnostic.c: Include "selftest-diagnostic.h".
5027         (selftest::assert_location_text): New function.
5028         (selftest::test_diagnostic_get_location_text): New function.
5029         (selftest::diagnostic_c_tests): Call it.
5031 2017-11-02  David Malcolm  <dmalcolm@redhat.com>
5033         * Makefile.in (OBJS-libcommon): Add selftest-diagnostic.o.
5034         * diagnostic-show-locus.c: Include "selftest-diagnostic.h".
5035         (class selftest::test_diagnostic_context): Move to...
5036         * selftest-diagnostic.c: New file.
5037         * selftest-diagnostic.h: New file.
5039 2017-11-02  James Bowman  <james.bowman@ftdichip.com>
5041         * config/ft32/ft32.c (ft32_addr_space_legitimate_address_p): increase
5042         offset range for FT32B.
5043         * config/ft32/ft32.h: option "mcompress" enables relaxation.
5044         * config/ft32/ft32.md: Add TARGET_NOPM.
5045         * config/ft32/ft32.opt: Add mft32b, mcompress, mnopm.
5046         * gcc/doc/invoke.texi: Add mft32b, mcompress, mnopm.
5048 2017-11-02  Wilco Dijkstra  <wdijkstr@arm.com>
5050         * config/aarch64/aarch64.h (MALLOC_ABI_ALIGNMENT): New define.
5052 2017-11-02  Jeff Law  <law@redhat.com>
5054         * gimple-ssa-sprintf.c (sprintf_dom_walker): Remove
5055         virtual keyword on FINAL OVERRIDE members.
5057         * tree-ssa-propagate.h (ssa_propagation_engine): Group
5058         virtuals together.  Add virtual destructor.
5059         (substitute_and_fold_engine): Similarly.
5061 2017-11-02  Jan Hubicka  <hubicka@ucw.cz>
5063         * x86-tune.def (X86_TUNE_USE_INCDEC): Enable for Haswell+.
5065 2017-11-02  Richard Biener  <rguenther@suse.de>
5067         PR tree-optimization/82795
5068         * tree-if-conv.c (predicate_mem_writes): Remove bogus assert.
5070 2017-11-02  Rainer Orth  <ro@CeBiTec.Uni-Bielefeld.DE>
5072         * acinclude.m4 (gcc_AC_INITFINI_ARRAY): Don't require
5073         gcc_SUN_LD_VERSION.
5074         (gcc_GAS_CHECK_FEATURE): Remove.
5075         * configure.ac (ld_vers) <*-*-solaris2*>: Move comments from
5076         gcc_AC_INITFINI_ARRAY here.  Update for Solaris 11.4 changes.
5077         * configure: Regenerate.
5079 2017-11-02  Claudiu Zissulescu <claziss@synopsys.com>
5081         * config/arc/arc.c (hwloop_optimize): Account for empty
5082         body loops.
5084 2017-11-02  Richard Biener  <rguenther@suse.de>
5086         PR middle-end/82765
5087         * varasm.c (decode_addr_const): Make offset HOST_WIDE_INT.
5088         Truncate ARRAY_REF index and element size.
5090 2017-11-01  Palmer Dabbelt  <palmer@dabbelt.com>
5092         * doc/invoke.texi (RISC-V Options): Use "@minus{}2 GB", not "-2 GB".
5094 2017-11-01  Jeff Law  <law@redhat.com>
5096         * tree-ssa-ccp.c (ccp_folder): New class derived from
5097         substitute_and_fold_engine.
5098         (ccp_folder::get_value): New member function.
5099         (ccp_folder::fold_stmt): Renamed from ccp_fold_stmt.
5100         (ccp_fold_stmt): Remove prototype.
5101         (ccp_finalize): Call substitute_and_fold from the ccp_class.
5102         * tree-ssa-copy.c (copy_folder): New class derived from
5103         substitute_and_fold_engine.
5104         (copy_folder::get_value): Renamed from get_value.
5105         (fini_copy_prop): Call substitute_and_fold from copy_folder class.
5106         * tree-vrp.c (vrp_folder): New class derived from
5107         substitute_and_fold_engine.
5108         (vrp_folder::fold_stmt): Renamed from vrp_fold_stmt.
5109         (vrp_folder::get_value): New member function.
5110         (vrp_finalize): Call substitute_and_fold from vrp_folder class.
5111         (evrp_dom_walker::before_dom_children): Similarly for replace_uses_in.
5112         * tree-ssa-propagate.h (substitute_and_fold_engine): New class to
5113         provide a class interface to folder/substitute routines.
5114         (ssa_prop_fold_stmt_fn): Remove typedef.
5115         (ssa_prop_get_value_fn): Likewise.
5116         (subsitute_and_fold): Remove prototype.
5117         (replace_uses_in): Likewise.
5118         * tree-ssa-propagate.c (substitute_and_fold_engine::replace_uses_in):
5119         Renamed from replace_uses_in.  Call the virtual member function
5120         (substitute_and_fold_engine::replace_phi_args_in): Similarly.
5121         (substitute_and_fold_dom_walker): Remove initialization of
5122         data member entries for calbacks.  Add substitute_and_fold_engine
5123         member and initialize it.
5124         (substitute_and_fold_dom_walker::before_dom_children0: Use the
5125         member functions for get_value, replace_phi_args_in c
5126         replace_uses_in, and fold_stmt calls.
5127         (substitute_and_fold_engine::substitute_and_fold): Renamed from
5128         substitute_and_fold.  Remove assert.   Update ctor call.
5130         * tree-ssa-propagate.h (ssa_prop_visit_stmt_fn): Remove typedef.
5131         (ssa_prop_visit_phi_fn): Likewise.
5132         (class ssa_propagation_engine): New class to provide an interface
5133         into ssa_propagate.
5134         * tree-ssa-propagate.c (ssa_prop_visit_stmt): Remove file scoped
5135         variable.
5136         (ssa_prop_visit_phi): Likewise.
5137         (ssa_propagation_engine::simulate_stmt): Moved into class.
5138         Call visit_phi/visit_stmt from the class rather than via
5139         file scoped static variables.
5140         (ssa_propagation_engine::simulate_block): Moved into class.
5141         (ssa_propagation_engine::process_ssa_edge_worklist): Similarly.
5142         (ssa_propagation_engine::ssa_propagate): Similarly.  No longer
5143         set file scoped statics for the visit_stmt/visit_phi callbacks.
5144         * tree-complex.c (complex_propagate): New class derived from
5145         ssa_propagation_engine.
5146         (complex_propagate::visit_stmt): Renamed from complex_visit_stmt.
5147         (complex_propagate::visit_phi): Renamed from complex_visit_phi.
5148         (tree_lower_complex): Call ssa_propagate via the complex_propagate
5149         class.
5150         * tree-ssa-ccp.c: (ccp_propagate): New class derived from
5151         ssa_propagation_engine.
5152         (ccp_propagate::visit_phi): Renamed from ccp_visit_phi_node.
5153         (ccp_propagate::visit_stmt): Renamed from ccp_visit_stmt.
5154         (do_ssa_ccp): Call ssa_propagate from the ccp_propagate class.
5155         * tree-ssa-copy.c (copy_prop): New class derived from
5156         ssa_propagation_engine.
5157         (copy_prop::visit_stmt): Renamed from copy_prop_visit_stmt.
5158         (copy_prop::visit_phi): Renamed from copy_prop_visit_phi_node.
5159         (execute_copy_prop): Call ssa_propagate from the copy_prop class.
5160         * tree-vrp.c (vrp_prop): New class derived from ssa_propagation_engine.
5161         (vrp_prop::visit_stmt): Renamed from vrp_visit_stmt.
5162         (vrp_prop::visit_phi): Renamed from vrp_visit_phi_node.
5163         (execute_vrp): Call ssa_propagate from the vrp_prop class.
5165 2017-11-01  Jakub Jelinek  <jakub@redhat.com>
5167         PR rtl-optimization/82778
5168         PR rtl-optimization/82597
5169         * compare-elim.c (struct comparison): Add in_a_setter field.
5170         (find_comparison_dom_walker::before_dom_children): Remove killed
5171         bitmap and df_simulate_find_defs call, instead walk the defs.
5172         Compute last_setter and initialize in_a_setter.  Merge definitions
5173         with first initialization for a few variables.
5174         (try_validate_parallel): Use insn_invalid_p instead of
5175         recog_memoized.  Return insn rather than just the pattern.
5176         (try_merge_compare): Fix up comment.  Don't uselessly test if
5177         in_a is a REG_P.  Use cmp->in_a_setter instead of walking UD
5178         chains.
5179         (execute_compare_elim_after_reload): Remove df_chain_add_problem
5180         call.
5182 2017-11-01  Richard Sandiford  <richard.sandiford@linaro.org>
5183             Alan Hayward  <alan.hayward@arm.com>
5184             David Sherwood  <david.sherwood@arm.com>
5186         * config/aarch64/aarch64.c (aarch64_rtx_costs): Use
5187         aarch64_hard_regno_nregs to get the number of registers
5188         in a mode.
5190 2017-11-01  Richard Sandiford  <richard.sandiford@linaro.org>
5191             Alan Hayward  <alan.hayward@arm.com>
5192             David Sherwood  <david.sherwood@arm.com>
5194         * config/aarch64/constraints.md (Upl): Rename to...
5195         (Uaa): ...this.
5196         * config/aarch64/aarch64.md
5197         (*zero_extend<SHORT:mode><GPI:mode>2_aarch64, *addsi3_aarch64_uxtw):
5198         Update accordingly.
5200 2017-11-01  Richard Sandiford  <richard.sandiford@linaro.org>
5201             Alan Hayward  <alan.hayward@arm.com>
5202             David Sherwood  <david.sherwood@arm.com>
5204         * config/aarch64/aarch64.c (aarch64_add_constant_internal)
5205         (aarch64_add_constant, aarch64_add_sp, aarch64_sub_sp): Move
5206         earlier in file.
5208 2017-11-01  Richard Sandiford  <richard.sandiford@linaro.org>
5209             Alan Hayward  <alan.hayward@arm.com>
5210             David Sherwood  <david.sherwood@arm.com>
5212         * config/aarch64/aarch64.c (aarch64_evpc_trn, aarch64_evpc_uzp)
5213         (aarch64_evpc_zip, aarch64_evpc_ext, aarch64_evpc_rev)
5214         (aarch64_evpc_dup): Generate rtl direcly, rather than using
5215         named expanders.
5216         (aarch64_expand_vec_perm_const_1): Explicitly check for permutes
5217         of a single element.
5218         * config/aarch64/iterators.md: Add a comment above the permute
5219         unspecs to say that they are generated directly by
5220         aarch64_expand_vec_perm_const.
5221         * config/aarch64/aarch64-simd.md: Likewise the permute instructions.
5223 2017-11-01  Nathan Sidwell  <nathan@acm.org>
5225         * tree-dump.c (dequeue_and_dump): Use HAS_DECL_ASSEMBLER_NAME_P.
5227 2017-11-01  Palmer Dabbelt  <palmer@dabbelt.com>
5229         * doc/invoke.texi (RISC-V Options): Explicitly name the medlow
5230         and medany code models, and describe what they do.
5232 2017-11-01  Richard Sandiford  <richard.sandiford@linaro.org>
5234         Revert accidental duplicate:
5236         * combine.c (can_change_dest_mode): Reject changes in
5237         REGMODE_NATURAL_SIZE.
5239 2017-11-01  Segher Boessenkool  <segher@kernel.crashing.org>
5241         PR rtl-optimization/64682
5242         PR rtl-optimization/69567
5243         PR rtl-optimization/69737
5244         PR rtl-optimization/82683
5245         * combine.c (distribute_notes) <REG_DEAD>: If the new I2 sets the same
5246         register mentioned in the note, drop the note, unless it came from I3,
5247         in which case it should go to I3 again.
5249 2017-11-01  Richard Sandiford  <richard.sandiford@linaro.org>
5251         * tree-ssa-dse.c (normalize_ref): Check whether the ranges overlap
5252         and return false if not.
5253         (clear_bytes_written_by, live_bytes_read): Update accordingly.
5255 2017-11-01  Richard Sandiford  <richard.sandiford@linaro.org>
5257         * tree-ssa-alias.h (ranges_overlap_p): Return false if either
5258         range is known to be empty.
5260 2017-11-01  Richard Sandiford  <richard.sandiford@linaro.org>
5261             Alan Hayward  <alan.hayward@arm.com>
5262             David Sherwood  <david.sherwood@arm.com>
5264         * simplify-rtx.c (simplify_const_unary_operation): Use GET_MODE_NUNITS
5265         and CONST_VECTOR_NUNITS instead of computing the number of units from
5266         the byte sizes of the vector and element.
5267         (simplify_binary_operation_1): Likewise.
5268         (simplify_const_binary_operation): Likewise.
5269         (simplify_ternary_operation): Likewise.
5271 2017-11-01  Richard Sandiford  <richard.sandiford@linaro.org>
5272             Alan Hayward  <alan.hayward@arm.com>
5273             David Sherwood  <david.sherwood@arm.com>
5275         * var-tracking.c (INT_MEM_OFFSET): Replace with...
5276         (int_mem_offset): ...this new function.
5277         (var_mem_set, var_mem_delete_and_set, var_mem_delete)
5278         (find_mem_expr_in_1pdv, dataflow_set_preserve_mem_locs)
5279         (same_variable_part_p, use_type, add_stores, vt_get_decl_and_offset):
5280         Update accordingly.
5282 2017-11-01  Richard Sandiford  <richard.sandiford@linaro.org>
5283             Alan Hayward  <alan.hayward@arm.com>
5284             David Sherwood  <david.sherwood@arm.com>
5286         * lower-subreg.c (interesting_mode_p): New function.
5287         (compute_costs, find_decomposable_subregs, decompose_register)
5288         (simplify_subreg_concatn, can_decompose_p, resolve_simple_move)
5289         (resolve_clobber, dump_choices): Use it.
5291 2017-11-01  Richard Sandiford  <richard.sandiford@linaro.org>
5292             Alan Hayward  <alan.hayward@arm.com>
5293             David Sherwood  <david.sherwood@arm.com>
5295         * rtlhash.c (add_rtx): Use add_hwi for 'w' and add_int for 'i'.
5297 2017-11-01  Richard Sandiford  <richard.sandiford@linaro.org>
5298             Alan Hayward  <alan.hayward@arm.com>
5299             David Sherwood  <david.sherwood@arm.com>
5301         * alias.c (find_base_value, find_base_term): Only process integer
5302         truncations.  Check the precision rather than the size.
5304 2017-11-01  Richard Sandiford  <richard.sandiford@linaro.org>
5305             Alan Hayward  <alan.hayward@arm.com>
5306             David Sherwood  <david.sherwood@arm.com>
5308         * machmode.h (is_narrower_int_mode): New function
5309         * optabs.c (expand_float, expand_fix): Use it.
5310         * dwarf2out.c (rotate_loc_descriptor): Likewise.
5312 2017-11-01  Richard Sandiford  <richard.sandiford@linaro.org>
5313             Alan Hayward  <alan.hayward@arm.com>
5314             David Sherwood  <david.sherwood@arm.com>
5316         * rtl.h (narrower_subreg_mode): New function.
5317         * ira-color.c (update_costs_from_allocno): Use it.
5319 2017-11-01  Richard Sandiford  <richard.sandiford@linaro.org>
5320             Alan Hayward  <alan.hayward@arm.com>
5321             David Sherwood  <david.sherwood@arm.com>
5323         * optabs-query.h (convert_optab_p): New function, split out from...
5324         (convert_optab_handler): ...here.
5325         (widening_optab_handler): Delete.
5326         (find_widening_optab_handler): Remove permit_non_widening parameter.
5327         (find_widening_optab_handler_and_mode): Likewise.  Provide an
5328         override that operates on mode class wrappers.
5329         * optabs-query.c (widening_optab_handler): Delete.
5330         (find_widening_optab_handler_and_mode): Remove permit_non_widening
5331         parameter.  Assert that the two modes are the same class and that
5332         the "from" mode is narrower than the "to" mode.  Use
5333         convert_optab_handler instead of widening_optab_handler.
5334         * expmed.c (expmed_mult_highpart_optab): Use convert_optab_handler
5335         instead of widening_optab_handler.
5336         * expr.c (expand_expr_real_2): Update calls to
5337         find_widening_optab_handler.
5338         * optabs.c (expand_widen_pattern_expr): Likewise.
5339         (expand_binop_directly): Take the insn_code as a parameter.
5340         (expand_binop): Only call find_widening_optab_handler for
5341         conversion optabs; use optab_handler otherwise.  Update calls
5342         to find_widening_optab_handler and expand_binop_directly.
5343         Use convert_optab_handler instead of widening_optab_handler.
5344         * tree-ssa-math-opts.c (convert_mult_to_widen): Update calls to
5345         find_widening_optab_handler and use scalar_mode rather than
5346         machine_mode.
5347         (convert_plusminus_to_widen): Likewise.
5349 2017-11-01  Richard Sandiford  <richard.sandiford@linaro.org>
5350             Alan Hayward  <alan.hayward@arm.com>
5351             David Sherwood  <david.sherwood@arm.com>
5353         * machmode.h (fixed_size_mode): New class.
5354         * rtl.h (get_pool_mode): Return fixed_size_mode.
5355         * gengtype.c (main): Add fixed_size_mode.
5356         * target.def (get_raw_result_mode): Return a fixed_size_mode.
5357         (get_raw_arg_mode): Likewise.
5358         * doc/tm.texi: Regenerate.
5359         * targhooks.h (default_get_reg_raw_mode): Return a fixed_size_mode.
5360         * targhooks.c (default_get_reg_raw_mode): Likewise.
5361         * config/ia64/ia64.c (ia64_get_reg_raw_mode): Likewise.
5362         * config/mips/mips.c (mips_get_reg_raw_mode): Likewise.
5363         * config/msp430/msp430.c (msp430_get_raw_arg_mode): Likewise.
5364         (msp430_get_raw_result_mode): Likewise.
5365         * config/avr/avr-protos.h (regmask): Use as_a <fixed_side_mode>
5366         * dbxout.c (dbxout_parms): Require fixed-size modes.
5367         * expr.c (copy_blkmode_from_reg, copy_blkmode_to_reg): Likewise.
5368         * gimple-ssa-store-merging.c (encode_tree_to_bitpos): Likewise.
5369         * omp-low.c (lower_oacc_reductions): Likewise.
5370         * simplify-rtx.c (simplify_immed_subreg): Take fixed_size_modes.
5371         (simplify_subreg): Update accordingly.
5372         * varasm.c (constant_descriptor_rtx::mode): Change to fixed_size_mode.
5373         (force_const_mem): Update accordingly.  Return NULL_RTX for modes
5374         that aren't fixed-size.
5375         (get_pool_mode): Return a fixed_size_mode.
5376         (output_constant_pool_2): Take a fixed_size_mode.
5378 2017-11-01  Richard Sandiford  <richard.sandiford@linaro.org>
5379             Alan Hayward  <alan.hayward@arm.com>
5380             David Sherwood  <david.sherwood@arm.com>
5382         * doc/rtl.texi (vec_series): Document.
5383         (const): Say that the operand can be a vec_series.
5384         * rtl.def (VEC_SERIES): New rtx code.
5385         * rtl.h (const_vec_series_p_1): Declare.
5386         (const_vec_series_p): New function.
5387         * emit-rtl.h (gen_const_vec_series): Declare.
5388         (gen_vec_series): Likewise.
5389         * emit-rtl.c (const_vec_series_p_1, gen_const_vec_series)
5390         (gen_vec_series): Likewise.
5391         * optabs.c (expand_mult_highpart): Use gen_const_vec_series.
5392         * simplify-rtx.c (simplify_unary_operation): Handle negations
5393         of vector series.
5394         (simplify_binary_operation_series): New function.
5395         (simplify_binary_operation_1): Use it.  Handle VEC_SERIES.
5396         (test_vector_ops_series): New function.
5397         (test_vector_ops): Call it.
5398         * config/powerpcspe/altivec.md (altivec_lvsl): Use
5399         gen_const_vec_series.
5400         (altivec_lvsr): Likewise.
5401         * config/rs6000/altivec.md (altivec_lvsl, altivec_lvsr): Likewise.
5403 2017-11-01  Richard Sandiford  <richard.sandiford@linaro.org>
5404             Alan Hayward  <alan.hayward@arm.com>
5405             David Sherwood  <david.sherwood@arm.com>
5407         * doc/rtl.texi (const): Update description of address constants.
5408         Say that vector constants are allowed too.
5409         * common.md (E, F): Use CONSTANT_P instead of checking for
5410         CONST_VECTOR.
5411         * emit-rtl.c (gen_lowpart_common): Use const_vec_p instead of
5412         checking for CONST_VECTOR.
5413         * expmed.c (make_tree): Use build_vector_from_val for a CONST
5414         VEC_DUPLICATE.
5415         * expr.c (expand_expr_real_2): Check for vector modes instead
5416         of checking for CONST_VECTOR.
5417         * rtl.h (const_vec_p): New function.
5418         (const_vec_duplicate_p): Check for a CONST VEC_DUPLICATE.
5419         (unwrap_const_vec_duplicate): Handle them here too.
5421 2017-11-01  Richard Sandiford  <richard.sandiford@linaro.org>
5422             David Malcolm  <dmalcolm@redhat.com>
5423             Alan Hayward  <alan.hayward@arm.com>
5424             David Sherwood  <david.sherwood@arm.com>
5426         * rtl.h (vec_duplicate_p): New function.
5427         * selftest-rtl.c (assert_rtx_eq_at): New function.
5428         * selftest-rtl.h (ASSERT_RTX_EQ): New macro.
5429         (assert_rtx_eq_at): Declare.
5430         * selftest.h (selftest::simplify_rtx_c_tests): Declare.
5431         * selftest-run-tests.c (selftest::run_tests): Call it.
5432         * simplify-rtx.c: Include selftest.h and selftest-rtl.h.
5433         (simplify_unary_operation_1): Recursively handle vector duplicates.
5434         (simplify_binary_operation_1): Likewise.  Handle VEC_SELECTs of
5435         vector duplicates.
5436         (simplify_subreg): Handle subregs of vector duplicates.
5437         (make_test_reg, test_vector_ops_duplicate, test_vector_ops)
5438         (selftest::simplify_rtx_c_tests): New functions.
5440 2017-11-01  Richard Sandiford  <richard.sandiford@linaro.org>
5441             Alan Hayward  <alan.hayward@arm.com>
5442             David Sherwood  <david.sherwood@arm.com>
5444         * emit-rtl.h (gen_const_vec_duplicate): Declare.
5445         (gen_vec_duplicate): Likewise.
5446         * emit-rtl.c (gen_const_vec_duplicate_1): New function, split
5447         out from...
5448         (gen_const_vector): ...here.
5449         (gen_const_vec_duplicate, gen_vec_duplicate): New functions.
5450         (gen_rtx_CONST_VECTOR): Use gen_const_vec_duplicate for constants
5451         whose elements are all equal.
5452         * optabs.c (expand_vector_broadcast): Use gen_const_vec_duplicate.
5453         * simplify-rtx.c (simplify_const_unary_operation): Likewise.
5454         (simplify_relational_operation): Likewise.
5455         * config/aarch64/aarch64.c (aarch64_simd_gen_const_vector_dup):
5456         Likewise.
5457         (aarch64_simd_dup_constant): Use gen_vec_duplicate.
5458         (aarch64_expand_vector_init): Likewise.
5459         * config/arm/arm.c (neon_vdup_constant): Likewise.
5460         (neon_expand_vector_init): Likewise.
5461         (arm_expand_vec_perm): Use gen_const_vec_duplicate.
5462         (arm_block_set_unaligned_vect): Likewise.
5463         (arm_block_set_aligned_vect): Likewise.
5464         * config/arm/neon.md (neon_copysignf<mode>): Likewise.
5465         * config/i386/i386.c (ix86_expand_vec_perm): Likewise.
5466         (expand_vec_perm_even_odd_pack): Likewise.
5467         (ix86_vector_duplicate_value): Use gen_vec_duplicate.
5468         * config/i386/sse.md (one_cmpl<mode>2): Use CONSTM1_RTX.
5469         * config/ia64/ia64.c (ia64_expand_vecint_compare): Use
5470         gen_const_vec_duplicate.
5471         * config/ia64/vect.md (addv2sf3, subv2sf3): Use CONST1_RTX.
5472         * config/mips/mips.c (mips_gen_const_int_vector): Use
5473         gen_const_vec_duplicate.
5474         (mips_expand_vector_init): Use CONST0_RTX.
5475         * config/powerpcspe/altivec.md (abs<mode>2, nabs<mode>2): Likewise.
5476         (define_split): Use gen_const_vec_duplicate.
5477         * config/rs6000/altivec.md (abs<mode>2, nabs<mode>2): Use CONST0_RTX.
5478         (define_split): Use gen_const_vec_duplicate.
5479         * config/s390/vx-builtins.md (vec_genmask<mode>): Likewise.
5480         (vec_ctd_s64, vec_ctd_u64, vec_ctsl, vec_ctul): Likewise.
5481         * config/spu/spu.c (spu_const): Likewise.
5483 2017-11-01  Richard Sandiford  <richard.sandiford@linaro.org>
5484             Alan Hayward  <alan.hayward@arm.com>
5485             David Sherwood  <david.sherwood@arm.com>
5487         * combine.c (can_change_dest_mode): Reject changes in
5488         REGMODE_NATURAL_SIZE.
5490 2017-10-31  Sandra Loosemore  <sandra@codesourcery.com>
5492         * configure.ac (--enable-libssp): New.
5493         (gcc_cv_libc_provides_ssp): Check for explicit setting before
5494         trying to determine target-specific default.  Adjust indentation.
5495         * configure: Regenerated.
5496         * doc/install.texi (Configuration): Expand --disable-libssp
5497         documentation.
5499 2017-10-31  Daniel Santos  <daniel.santos@pobox.com>
5501         config/i386/i386.c (ix86_expand_epilogue): Correct stack
5502         calculation.
5504 2017-10-31  Martin Jambor  <mjambor@suse.cz>
5506         PR c++/81702
5507         * gimple-fold.c (gimple_get_virt_method_for_vtable): Remove assert.
5509 2017-10-31  David Malcolm  <dmalcolm@redhat.com>
5511         * auto-profile.c (autofdo_source_profile::read): Use
5512         UNKNOWN_LOCATION rather than 0.
5513         * diagnostic-core.h (warning_at_rich_loc): Rename to...
5514         (warning_at): ...this overload.
5515         (warning_at_rich_loc_n): Rename to...
5516         (warning_n): ...this overload.
5517         (error_at_rich_loc): Rename to...
5518         (error_at): ...this overload.
5519         (pedwarn_at_rich_loc): Rename to...
5520         (pedwarn): ...this overload.
5521         (permerror_at_rich_loc): Rename to...
5522         (permerror): ...this overload.
5523         (inform_at_rich_loc): Rename to...
5524         (inform): ...this overload.
5525         * diagnostic.c: (diagnostic_n_impl): Delete location_t-based decl.
5526         (diagnostic_n_impl_richloc): Rename to...
5527         (diagnostic_n_impl): ...this rich_location *-based decl.
5528         (inform_at_rich_loc): Rename to...
5529         (inform): ...this, and add an assertion.
5530         (inform_n): Update for removal of location_t-based diagnostic_n_impl.
5531         (warning_at_rich_loc): Rename to...
5532         (warning_at): ...this, and add an assertion.
5533         (warning_at_rich_loc_n): Rename to...
5534         (warning_n): ...this, and add an assertion.
5535         (warning_n): Update location_t-based implementation for removal of
5536         location_t-based diagnostic_n_impl.
5537         (pedwarn_at_rich_loc): Rename to...
5538         (pedwarn): ...this, and add an assertion.
5539         (permerror_at_rich_loc): Rename to...
5540         (permerror): ...this, and add an assertion.
5541         (error_n): Update for removal of location_t-based diagnostic_n_impl.
5542         (error_at_rich_loc): Rename to...
5543         (error_at): ...this, and add an assertion.
5544         * gcc.c (do_spec_1): Use UNKNOWN_LOCATION rather than 0.
5545         (driver::do_spec_on_infiles): Likewise.
5546         * substring-locations.c (format_warning_va): Update for renaming
5547         of inform_at_rich_loc.
5549 2017-10-31  Michael Meissner  <meissner@linux.vnet.ibm.com>
5551         * builtins.def (DEF_FLOATN_BUILTIN): Change most _Float<N> and
5552         _Float<N>X built-in functions so that the variant without the
5553         "__builtin_" prefix is only enabled for the GNU C and Objective C
5554         languages when they are in non-strict ANSI/ISO mode.
5555         (DEF_EXT_LIB_FLOATN_NX_BUILTINS): Likewise.
5556         * target.def (floatn_builtin_p): Add a target hook to control
5557         whether _Float<N> and _Float<N>X built-in functions without the
5558         "__builtin_" prefix are enabled, and return true for C and
5559         Objective C in the default hook.  Include langhooks.h in
5560         targhooks.c.
5561         * targhooks.h (default_floatn_builtin_p): Likewise.
5562         * targhooks.c (default_floatn_builtin_p): Likewise.
5563         * doc/tm.texi.in (TARGET_FLOATN_BUILTIN_P): Document the
5564         floatn_builtin_p target hook.
5565         * doc/tm.texi (TARGET_FLOATN_BUILTIN_P): Likewise.
5567 2017-10-31  Matthew Fortune  <matthew.fortune@imgtec.com>
5568             Eric Botcazou  <ebotcazou@adacore.com>
5570         PR rtl-optimization/81803
5571         * lra-constraints.c (curr_insn_transform): Also reload the whole
5572         register for a strict subreg no wider than a word if this is for
5573         a WORD_REGISTER_OPERATIONS target.
5575 2017-10-31  Jason Merrill  <jason@redhat.com>
5577         * gdbinit.in: Skip over inlines from timevar.h.
5579 2017-10-31  Martin Liska  <mliska@suse.cz>
5581         * doc/gcov.texi: Document new option.
5582         * gcov.c (print_usage): Likewise print it.
5583         (process_args): Support the argument.
5584         (format_count): New function.
5585         (format_gcov): Use the function.
5587 2017-10-31  Martin Liska  <mliska@suse.cz>
5589         * gcov.c (struct name_map): do not use typedef.
5590         Define operator== and operator<.
5591         (name_search): Remove.
5592         (name_sort): Remove.
5593         (main): Do not allocate names.
5594         (process_file): Add vertical space.
5595         (generate_results): Use std::find.
5596         (release_structures): Do not release memory.
5597         (find_source): Use std::find.
5599 2017-10-31  Martin Liska  <mliska@suse.cz>
5601         * gcov.c (struct line_info): Remove it's typedef.
5602         (line_info::line_info): Add proper ctor.
5603         (line_info::has_block): Do not use a typedef.
5604         (struct source_info): Do not use typedef.
5605         (circuit): Likewise.
5606         (get_cycles_count): Likewise.
5607         (output_intermediate_file): Iterate via vector iterator.
5608         (add_line_counts): Use std::vector methods.
5609         (accumulate_line_counts): Likewise.
5610         (output_lines): Likewise.
5612 2017-10-31  Martin Liska  <mliska@suse.cz>
5614         * gcov.c (struct source_info): Remove typedef.
5615         (source_info::source_info): Add proper ctor.
5616         (accumulate_line_counts): Use struct, not it's typedef.
5617         (output_gcov_file): Likewise.
5618         (output_lines): Likewise.
5619         (main): Do not allocate an array.
5620         (output_intermediate_file): Use size of vector container.
5621         (process_file): Resize the vector.
5622         (generate_results): Do not preallocate, use newly added vector
5623         lines.
5624         (release_structures): Do not release sources.
5625         (find_source): Use vector methods.
5626         (add_line_counts): Do not use typedef.
5628 2017-10-31  Martin Liska  <mliska@suse.cz>
5630         * doc/gcov.texi: Document that.
5631         * gcov.c (add_line_counts): Mark lines with a non-executed
5632         statement.
5633         (output_line_beginning): Handle such lines.
5634         (output_lines): Pass new argument.
5635         (output_intermediate_file): Print it in intermediate format.
5637 2017-10-31  Martin Liska  <mliska@suse.cz>
5639         * color-macros.h: New file.
5640         * diagnostic-color.c: Factor out color related to macros to
5641         color-macros.h.
5642         * doc/gcov.texi: Document -k option.
5643         * gcov.c (INCLUDE_STRING): Include string.h.
5644         (print_usage): Add -k option.
5645         (process_args): Parse it.
5646         (pad_count_string): New function.
5647         (output_line_beginning): Likewise.
5648         (DEFAULT_LINE_START): New macro.
5649         (output_lines): Support color output.
5651 2017-10-31  Martin Liska  <mliska@suse.cz>
5653         PR gcov-profile/82633
5654         * doc/gcov.texi: Document -fkeep-{static,inline}-functions and
5655         their interaction with GCOV infrastructure.
5656         * configure.ac: Add -fkeep-{inline,static}-functions to
5657         coverage_flags.
5658         * configure: Regenerate.
5660 2017-10-31  Uros Bizjak  <ubizjak@gmail.com>
5662         PR target/82772
5663         * config/alpha/sync.md (fetchop_constr) <and>: Change to "rINM".
5665 2017-10-31  Segher Boessenkool  <segher@kernel.crashing.org>
5667         PR target/82674
5668         * config/rs6000/rs6000.md (allocate_stack): Force update interval
5669         into a register if it does not fit into an immediate offset field.
5671 2017-10-31  Olivier Hainque  <hainque@adacore.com>
5673         * gcc/Makefile.in (FLAGS_TO_PASS): Pass libsubdir as well.
5675 2017-10-31  Julia Koval  <julia.koval@intel.com>
5677         * config.gcc: Add gfniintrin.h.
5678         * config/i386/gfniintrin.h: New.
5679         * config/i386/i386-builtin-types.def
5680         (__builtin_ia32_vgf2p8affineinvqb_v64qi,
5681         __builtin_ia32_vgf2p8affineinvqb_v64qi_mask,
5682         __builtin_ia32_vgf2p8affineinvqb_v32qi,
5683         __builtin_ia32_vgf2p8affineinvqb_v32qi_mask,
5684         __builtin_ia32_vgf2p8affineinvqb_v16qi,
5685         __builtin_ia32_vgf2p8affineinvqb_v16qi_mask): New builtins.
5686         * config/i386/i386-builtin.def (V64QI_FTYPE_V64QI_V64QI_INT_V64QI_UDI,
5687         V32QI_FTYPE_V32QI_V32QI_INT_V32QI_USI,
5688         V16QI_FTYPE_V16QI_V16QI_INT_V16QI_UHI,
5689         V64QI_FTYPE_V64QI_V64QI_INT): New types.
5690         * config/i386/i386.c (ix86_expand_args_builtin): Handle new types.
5691         * config/i386/immintrin.h: Include gfniintrin.h.
5692         * config/i386/sse.md (vgf2p8affineinvqb_*) New pattern.
5694 2017-10-30  Eric Botcazou  <ebotcazou@adacore.com>
5696         * gcc.c (HAVE_TARGET_EXECUTABLE_SUFFIX): Remove old kludge.
5698 2017-10-30  Wilco Dijkstra  <wdijkstr@arm.com>
5700         * config/arm/arm.md (ashldi3): Remove shift by 1 expansion.
5701         (arm_ashldi3_1bit): Remove pattern.
5702         (ashrdi3): Remove shift by 1 expansion.
5703         (arm_ashrdi3_1bit): Remove pattern.
5704         (lshrdi3): Remove shift by 1 expansion.
5705         (arm_lshrdi3_1bit): Remove pattern.
5706         * config/arm/arm.c (arm_rtx_costs_internal): Slightly increase
5707         cost of ashldi3 by 1.
5708         * config/arm/neon.md (ashldi3_neon): Remove shift by 1 expansion.
5709         (<shift>di3_neon): Likewise.
5711 2017-10-30  Dominik Infuehr  <dominik.infuehr@theobroma-systems.com>
5713         * config/aarch64/aarch64-simd.md (*aarch64_simd_mov): Rename
5714         both identically named patterns to (*aarch64_simd_mov<VD:mode>)
5715         and (*aarch64_simd_mov<VQ:mode>).
5716         (*aarch64_simd_mov<VD:mode>): Change type attribute to match
5717         pattern alternative.
5718         (*aarch64_simd_mov<VQ:mode>): Re-order and change type
5719         attributes to match pattern alternative.
5721 2017-10-30  Steven Munroe  <munroesj@gcc.gnu.org>
5723         * config.gcc (powerpc*-*-*): Add emmintrin.h.
5724         * config/rs6000/emmintrin.h: New file.
5725         * config/rs6000/x86intrin.h [__ALTIVEC__]: Include emmintrin.h.
5727 2017-10-30  Wilco Dijkstra  <wdijkstr@arm.com>
5729         * config/arm/vfp.md (movdi_vfp): Merge changes from movdi_vfp_cortexa8.
5730         * (movdi_vfp_cortexa8): Remove pattern.
5732 2017-10-30  Rainer Orth  <ro@CeBiTec.Uni-Bielefeld.DE>
5734         * doc/install.texi (Specific, alpha*-*-*): Remove DEC OSF/1
5735         etc. reference.
5736         (Specific, alpha*-dec-osf5.1): Remove.
5737         (Specific, mips-sgi-irix5): Remove.
5738         (Specific, mips-sgi-irix6): Remove.
5740 2017-10-30  Jakub Jelinek  <jakub@redhat.com>
5742         PR middle-end/22141
5743         * gimple-ssa-store-merging.c (merged_store_group::apply_stores): Fix
5744         arguments to clear_bit_region_be.
5746 2017-10-30  Jim Wilson  <wilson@tuliptree.org>
5748         * gimplify.c: Include memmodel.h.
5750 2017-10-30  Martin Jambor  <mjambor@suse.cz>
5752         * omp-grid.c (grid_attempt_target_gridification): Also insert a
5753         condition whether loop should be executed at all.
5755 2017-10-30  Will Schmidt  <will_schmidt@vnet.ibm.com>
5757         * config/rs6000/rs6000.c (rs6000_gimple_fold_builtin): Add support for
5758         gimple folding of vec_madd() intrinsics.
5759         * config/rs6000/altivec.md (mulv8hi3): Rename altivec_vmladduhm to
5760         fmav8hi4.  (altivec_vmladduhm): Rename to fmav8hi4.
5761         * config/rs6000/rs6000-builtin.def: Rename vmladduhm to fmav8hi4
5763 2017-10-30  Richard Biener  <rguenther@suse.de>
5765         PR tree-optimization/82762
5766         Revert
5767         2017-10-23  Richard Biener  <rguenther@suse.de>
5769         PR tree-optimization/82129
5770         Revert
5771         2017-08-01  Richard Biener  <rguenther@suse.de>
5773         PR tree-optimization/81181
5774         * tree-ssa-pre.c (compute_antic_aux): Defer clean() to ...
5775         (compute_antic): ... end of iteration here.
5777 2017-10-30  Joseph Myers  <joseph@codesourcery.com>
5779         * doc/invoke.texi (C Dialect Options): Document -std=c17,
5780         -std=iso9899:2017 and -std=gnu17.
5781         * doc/standards.texi (C Language): Document C17 support.
5782         * doc/cpp.texi (Overview): Mention -std=c17.
5783         (Standard Predefined Macros): Document C11 and C17 values of
5784         __STDC_VERSION__.  Do not refer to C99 support as incomplete.
5785         * doc/extend.texi (Inline): Do not list individual options for
5786         standards newer than C99.
5787         * dwarf2out.c (highest_c_language, gen_compile_unit_die): Handle
5788         "GNU C17".
5789         * config/rl78/rl78.c (rl78_option_override): Handle "GNU C17"
5790         language name.
5792 2017-10-30  Maxim Ostapenko  <m.ostapenko@samsung.com>
5794         * asan.c (asan_finish_file): Align asan globals array by shadow
5795         granularity.
5797 2017-10-30  Jakub Jelinek  <jakub@redhat.com>
5799         PR middle-end/22141
5800         * gimple-ssa-store-merging.c: Include rtl.h and expr.h.
5801         (struct store_immediate_info): Add bitregion_start and bitregion_end
5802         fields.
5803         (store_immediate_info::store_immediate_info): Add brs and bre
5804         arguments and initialize bitregion_{start,end} from those.
5805         (struct merged_store_group): Add bitregion_start, bitregion_end,
5806         align_base and mask fields.  Drop unnecessary struct keyword from
5807         struct store_immediate_info.  Add do_merge method.
5808         (clear_bit_region_be): Use memset instead of loop storing zeros.
5809         (merged_store_group::do_merge): New method.
5810         (merged_store_group::merge_into): Use do_merge.  Allow gaps in between
5811         stores as long as the surrounding bitregions have no gaps.
5812         (merged_store_group::merge_overlapping): Use do_merge.
5813         (merged_store_group::apply_stores): Test that bitregion_{start,end}
5814         is byte aligned, rather than requiring that start and width are
5815         byte aligned.  Drop unnecessary struct keyword from
5816         struct store_immediate_info.  Allocate and populate also mask array.
5817         Make start of the arrays relative to bitregion_start rather than
5818         start and size them according to bitregion_{end,start} difference.
5819         (struct imm_store_chain_info): Drop unnecessary struct keyword from
5820         struct store_immediate_info.
5821         (pass_store_merging::gate): Punt if BITS_PER_UNIT or CHAR_BIT is not 8.
5822         (pass_store_merging::terminate_all_aliasing_chains): Drop unnecessary
5823         struct keyword from struct store_immediate_info.
5824         (imm_store_chain_info::coalesce_immediate_stores): Allow gaps in
5825         between stores as long as the surrounding bitregions have no gaps.
5826         Formatting fixes.
5827         (struct split_store): Add orig non-static data member.
5828         (split_store::split_store): Initialize orig to false.
5829         (find_constituent_stmts): Return store_immediate_info *, non-NULL
5830         if there is exactly a single original stmt.  Change stmts argument
5831         to pointer from reference, if NULL, don't push anything to it.  Add
5832         first argument, use it to optimize skipping over orig stmts that
5833         are known to be before bitpos already.  Simplify.
5834         (split_group): Return unsigned int count how many stores are or
5835         would be needed rather than a bool.  Add allow_unaligned argument.
5836         Change split_stores argument from reference to pointer, if NULL,
5837         only do a dry run computing how many stores would be produced.
5838         Rewritten algorithm to use both alignment and misalign if
5839         !allow_unaligned and handle bitfield stores with gaps.
5840         (imm_store_chain_info::output_merged_store): Set start_byte_pos
5841         from bitregion_start instead of start.  Compute allow_unaligned
5842         here, if true, do 2 split_group dry runs to compute which one
5843         produces fewer stores and prefer aligned if equal.  Punt if
5844         new count is bigger or equal than original before emitting any
5845         statements, rather than during that.  Remove no longer needed
5846         new_ssa_names tracking.  Replace num_stmts with
5847         split_stores.length ().  Use 32-bit stack allocated entries
5848         in split_stores auto_vec.  Try to reuse original store lhs/rhs1
5849         if possible.  Handle bitfields with gaps.
5850         (pass_store_merging::execute): Ignore bitsize == 0 stores.
5851         Compute bitregion_{start,end} for the stores and construct
5852         store_immediate_info with that.  Formatting fixes.
5854 2017-10-30  Uros Bizjak  <ubizjak@gmail.com>
5856         PR target/82725
5857         * config/i386/i386.c (legitimate_pic_address_disp_p): Allow
5858         UNSPEC_DTPOFF and UNSPEC_NTPOFF with SImode immediate offset.
5860 2017-10-29  Jim Wilson  <wilson@tuliptree.org>
5862         * gimplify.c: Include tm_p.h.
5864         * common.opt (gcoff): Re-add as ignored option.
5865         (gcoff1, gcoff2, gcoff3): Likewise.
5867         * Makefile.in (OBJS): Delete sdbout.o.
5868         (GTFILES): Delete $(srcdir)/sdbout.c.
5869         * debug.h: Delete sdb_debug_hooks.
5870         * final.c: Delete sdbout.h include.
5871         (final_scan_insn): Delete SDB_DEBUG check.
5872         (rest_of_clean_state): Likewise.
5873         * output.h: Delete sdb_begin_function_line.
5874         * sdbout.c: Delete.
5875         * sdbout.h: Delete.
5876         * toplev.c: Delete sdbout.h include.
5877         (process_options): Delete SDB_DEBUG check.
5878         * tree-core.h (tree_type_common): Delete pointer field of
5879         tree_type_symtab.
5880         * tree.c (copy_node): Clear TYPE_SYMTAB_DIE instead of
5881         TYPE_SYMTAB_POINTER.
5882         * tree.h (TYPE_SYMTAB_POINTER): Delete.
5883         (TYPE_SYMTAB_IS_POINTER): Delete.
5884         (TYPE_SYMTAB_IS_DIE): Renumber.
5885         * xcoffout.c: Refer to former sdbout.c file.
5886         (xcoffout_begin_prologue): Use past tense for sdbout.c reference.
5888         * doc/install.texi (--with-stabs): Delete COFF and ECOFF info.
5889         * doc/invoke.texi (SEEALSO): Delete adb and sdb references.
5890         (Debugging Options): Delete -gcoff.
5891         (-gstabs): Delete SDB reference.
5892         (-gcoff): Delete.
5893         (-gcoff@var{level}): Delete.
5894         * doc/passes.texi (Debugging information output): Delete SDB and
5895         sdbout.c references.
5896         * doc/tm.texi: Regenerate.
5897         * doc/tm.texi.in (DWARF_CIE_DATA_ALIGNMENT): Delete SDB from xref.
5898         (SDB and DWARF): Change node name to DWARF and delete SDB and COFF
5899         references.
5900         (DEBUGGER_AUTO_OFFSET): Delete COFF and SDB references.
5901         (PREFERRED_DEBUGGING_TYPE): Delete SDB_DEBUG and -gcoff references.
5902         (SDB_DEBUGGING_INFO): Delete.
5903         (PUT_SDB_@dots{}, SDB_DELIM, SDB_ALLOW_UNKNOWN_REFERENCES)
5904         SDB_ALLOW_FORWARD_REFERENCES, SDB_OUTPUT_SOURCE_LINE): Delete.
5905         * target.def (output_source_filename): Delete COFF reference.
5907         * common.opt (gcoff): Delete.
5908         (gxcoff+): Update Negative chain.
5909         * defaults.h: Delete all references to SDB_DEBUGGING_INFO and
5910         SDB_DEBUG.
5911         * dwarf2out.c (gen_array_type_die): Change SDB to debuggers.
5912         * flag-types.h (enum debug_info_type): Delete SDB_DEBUG.
5913         * function.c (number_blocks): Delete SDB_DEBUGGING_INFO, SDB_DEBUG,
5914         and SDB references.
5915         (expand_function_start): Change sdb reference to past tense.
5916         (expand_function_end): Change sdb reference to past tense.
5917         * gcc.c (cpp_unique_options): Delete gcoff3 reference.
5918         * opts.c (debug_type_names): Delete coff entry.
5919         (common_handle_option): Delete OPT_gcoff case.
5920         * system.h (SDB_DEBUG, SDB_DEBUGGING_INFO): Poison.
5922         * config/dbxcoff.h (PREFERRED_DEBUGGING_TYPE): Set to DBX_DEBUG.
5923         * config/cris/cris.h: Delete SDB reference in comment.
5924         * config/i386/cygming.h: Don't define SDB_DEBUGGING_INFO.
5925         (ASM_DECLARE_FUNCTION_NAME): Delete SDB reference from comment.
5926         * config/i386/gas.h: Don't define SDB_DEBUGGING_INFO.
5927         * config/i386/i386.c (svr4_dbx_register_map): Change SDB references
5928         to past tense.
5929         (ix86_expand_prologue): Likewise.
5930         * config/i386/winnt.c (i386_pe_start_function): Don't check SDB_DEBUG.
5931         * config/ia64/ia64.h: Likewise.
5932         * config/m68k/m68kelf.h (DBX_REGISTER_NUMBER): Delete SDB reference.
5933         * config/mips/mips.h (SUBTARGET_ASM_DEBUGGING_SPEC): Delete gcoff*
5934         support.
5935         * config/mmix/mmix.h: Likewise.
5936         * config/nds32/nds32.c: Likewise.
5937         * config/stormy/storym16.h: Likewise.
5938         * config/visium/visium.h: Likewise.
5939         * config/vx-common.h (SDB_DEBUGGING_INFO): Delete undef.
5941 2017-10-28  Sandra Loosemore  <sandra@codesourcery.com>
5943         * config/nios2/nios2.h (FRAME_GROWS_DOWNWARD): Define to 1.
5944         * config/nios2/nios2.c (nios2_initial_elimination_offset):  Make
5945         FRAME_POINTER_REGNUM point at high end of local var area.
5947 2017-10-27  Eric Botcazou  <ebotcazou@adacore.com>
5949         * bb-reorder.c (find_traces_1_round): Fix off-by-one index.
5950         Move comment around.  Do not reset best_edge for a copiable
5951         destination if the copy would cause a partition change.
5952         (better_edge_p): Remove redundant check.
5954 2017-10-27  Uros Bizjak  <ubizjak@gmail.com>
5956         * config/i386/i386-protos.h (ix86_fp_compare_mode): Remove prototype.
5958 2017-10-27  Michael Meissner  <meissner@linux.vnet.ibm.com>
5960         * builtins.c (CASE_MATHFN_FLOATN): New helper macro to add cases
5961         for math functions that have _Float<N> and _Float<N>X variants.
5962         (mathfn_built_in_2): Add support for math functions that have
5963         _Float<N> and _Float<N>X variants.
5964         (DEF_INTERNAL_FLT_FLOATN_FN): New helper macro.
5965         (expand_builtin_mathfn_ternary): Add support for fma with
5966         _Float<N> and _Float<N>X variants.
5967         (expand_builtin): Likewise.
5968         (fold_builtin_3): Likewise.
5969         * builtins.def (DEF_EXT_LIB_FLOATN_NX_BUILTINS): New macro to
5970         create math function _Float<N> and _Float<N>X variants as external
5971         library builtins.
5972         (BUILT_IN_COPYSIGN _Float<N> and _Float<N>X variants) Use
5973         DEF_EXT_LIB_FLOATN_NX_BUILTINS to make built-in functions using
5974         the __builtin_ prefix and if not strict ansi, without the prefix.
5975         (BUILT_IN_FABS _Float<N> and _Float<N>X variants): Likewise.
5976         (BUILT_IN_FMA _Float<N> and _Float<N>X variants): Likewise.
5977         (BUILT_IN_FMAX _Float<N> and _Float<N>X variants): Likewise.
5978         (BUILT_IN_FMIN _Float<N> and _Float<N>X variants): Likewise.
5979         (BUILT_IN_NAN _Float<N> and _Float<N>X variants): Likewise.
5980         (BUILT_IN_SQRT _Float<N> and _Float<N>X variants): Likewise.
5981         * builtin-types.def (BT_FN_FLOAT16_FLOAT16_FLOAT16_FLOAT16): New
5982         function signatures for fma _Float<N> and _Float<N>X variants.
5983         (BT_FN_FLOAT32_FLOAT32_FLOAT32_FLOAT32): Likewise.
5984         (BT_FN_FLOAT64_FLOAT64_FLOAT64_FLOAT64): Likewise.
5985         (BT_FN_FLOAT128_FLOAT128_FLOAT128_FLOAT128): Likewise.
5986         (BT_FN_FLOAT32X_FLOAT32X_FLOAT32X_FLOAT32X): Likewise.
5987         (BT_FN_FLOAT64X_FLOAT64X_FLOAT64X_FLOAT64X): Likewise.
5988         (BT_FN_FLOAT128X_FLOAT128X_FLOAT128X_FLOAT128X): Likewise.
5989         * gencfn-macros.c (print_case_cfn): Add support for math functions
5990         that have _Float<N> and _Float<N>X variants.
5991         (print_define_operator_list): Likewise.
5992         (fltfn_suffixes): Likewise.
5993         (main): Likewise.
5994         * internal-fn.def (DEF_INTERNAL_FLT_FLOATN_FN): New helper macro
5995         for math functions that have _Float<N> and _Float<N>X variants.
5996         (SQRT): Add support for sqrt, copysign, fmin and fmax _Float<N>
5997         and _Float<N>X variants.
5998         (COPYSIGN): Likewise.
5999         (FMIN): Likewise.
6000         (FMAX): Likewise.
6001         * fold-const.c (tree_call_nonnegative_warnv_p): Add support for
6002         copysign, fma, fmax, fmin, and sqrt _Float<N> and _Float<N>X
6003         variants.
6004         (integer_valued_read_call_p): Likewise.
6005         * fold-const-call.c (fold_const_call_ss): Likewise.
6006         (fold_const_call_sss): Add support for copysign, fmin, and fmax
6007         _Float<N> and _Float<N>X variants.
6008         (fold_const_call_ssss): Add support for fma _Float<N> and
6009         _Float<N>X variants.
6010         * gimple-ssa-backprop.c (backprop::process_builtin_call_use): Add
6011         support for copysign and fma _Float<N> and _Float<N>X variants.
6012         (backprop::process_builtin_call_use): Likewise.
6013         * tree-call-cdce.c (can_test_argument_range); Add support for
6014         sqrt _Float<N> and _Float<N>X variants.
6015         (edom_only_function): Likewise.
6016         (get_no_error_domain): Likewise.
6017         * tree-ssa-math-opts.c (internal_fn_reciprocal): Likewise.
6018         * tree-ssa-reassoc.c (attempt_builtin_copysign): Add support for
6019         copysign _Float<N> and _Float<N>X variants.
6020         * config/rs6000/rs6000-builtin.def (SQRTF128): Delete, this is now
6021         handled by machine independent code.
6022         (FMAF128): Likewise.
6023         * doc/cpp.texi (Common Predefined Macros): Document defining
6024         __FP_FAST_FMAF<N> and __FP_FAST_FMAF<N>X if the backend supports
6025         fma _Float<N> and _Float<N>X variants.
6027 2017-10-27  Uros Bizjak  <ubizjak@gmail.com>
6029         PR target/82692
6030         * config/i386/i386-modes.def (CCFPU): Remove definition.
6031         * config/i386/i386.c (put_condition_mode): Remove CCFPU mode handling.
6032         (ix86_cc_modes_compatible): Ditto.
6033         (ix86_expand_carry_flag_compare): Ditto.
6034         (ix86_expand_int_movcc): Ditto.
6035         (ix86_expand_int_addcc): Ditto.
6036         (ix86_reverse_condition): Ditto.
6037         (ix86_unordered_fp_compare): Rename from ix86_fp_compare_mode.
6038         Return true/false for unordered/ordered fp comparisons.
6039         (ix86_cc_mode): Always return CCFPmode for float mode comparisons.
6040         (ix86_prepare_fp_compare_args): Update for rename.
6041         (ix86_expand_fp_compare): Update for rename.  Generate unordered
6042         compare RTXes wrapped with UNSPEC_NOTRAP unspec.
6043         (ix86_expand_sse_compare_and_jump): Ditto.
6044         * config/i386/predicates.md (fcmov_comparison_operator):
6045         Remove CCFPU mode handling.
6046         (ix86_comparison_operator): Ditto.
6047         (ix86_carry_flag_operator): Ditto.
6048         * config/i386/i386.md (UNSPEC_NOTRAP): New unspec.
6049         (*cmpu<mode>_i387): Wrap compare RTX with UNSPEC_NOTRAP unspec.
6050         (*cmpu<mode>_cc_i387): Ditto.
6051         (FPCMP): Remove mode iterator.
6052         (unord): Remove mode attribute.
6053         (unord_subst): New define_subst transformation
6054         (unord): New define_subst attribute.
6055         (unordered): Ditto.
6056         (*cmpi<unord><MODEF:mode>): Rewrite using unord_subst transformation.
6057         (*cmpi<unord>xf_i387): Ditto.
6058         * config/i386/sse.md (<sse>_<unord>comi<round_saeonly_name>): Merge
6059         from <sse>_comi<round_saeonly_name> and <sse>_ucomi<round_saeonly_name>
6060         using unord_subst transformation.
6061         * config/i386/subst.md (SUBST_A): Remove CCFP and CCFPU modes.
6062         (round_saeonly): Also handle CCFP mode.
6063         * reg-stack.c (subst_stack_regs_pat): Handle UNSPEC_NOTRAP unspec.
6064         Remove UNSPEC_SAHF unspec handling.
6066 2017-10-27  Jan Hubicka  <hubicka@ucw.cz>
6068         * x86-tune.def (X86_TUNE_INTER_UNIT_MOVES_TO_VEC): Disable for Zen.
6070 2017-10-27  Jeff Law  <law@redhat.com>
6072         * gimple-ssa-sprintf.c: Include domwalk.h.
6073         (class sprintf_dom_walker): New class, derived from dom_walker.
6074         (sprintf_dom_walker::before_dom_children): New function.
6075         (struct call_info): Moved into sprintf_dom_walker class
6076         (compute_formath_length, handle_gimple_call): Likewise.
6077         (sprintf_length::execute): Call the dominator walker rather
6078         than walking the statements.
6080         * tree-vrp.c (check_all_array_refs): Do not use wi->info to smuggle
6081         gimple statement locations.
6082         (check_array_bounds): Corresponding changes.  Get the statement's
6083         location directly from wi->stmt.
6085 2017-10-27  Palmer Dabbelt  <palmer@dabbelt.com>
6087         PR target/82717
6088         * doc/invoke.texi (RISC-V) <-mabi>: Correct and improve.
6090 2017-10-27  Jan Hubicka  <hubicka@ucw.cz>
6092         * config/i386/x86-tune.def (X86_TUNE_PARTIAL_REG_DEPENDENCY,
6093         X86_TUNE_MOVX): Disable for Haswell and newer CPUs.
6095 2017-10-27  Jakub Jelinek  <jakub@redhat.com>
6097         PR target/82703
6098         * config/i386/i386-protos.h (maybe_get_pool_constant): Removed.
6099         * config/i386/i386.c (maybe_get_pool_constant): Removed.
6100         (ix86_split_to_parts): Use avoid_constant_pool_reference instead of
6101         maybe_get_pool_constant.
6102         * config/i386/predicates.md (zero_extended_scalar_load_operand):
6103         Likewise.
6105 2017-10-27  Rainer Orth  <ro@CeBiTec.Uni-Bielefeld.DE>
6107         * doc/install.texi (Specific, i?86-*-solaris2.10): Simplify gas
6108         2.26 caveat.  Update gas and gld versions.
6109         (Specific, *-*-solaris2*): Update binutils version.  Remove caveat
6110         reference.
6112 2017-10-27  Prathamesh Kulkarni  <prathamesh.kulkarni@linaro.org>
6114         * cgraph.h (set_malloc_flag): Declare.
6115         * cgraph.c (set_malloc_flag_1): New function.
6116         (set_malloc_flag): Likewise.
6117         * ipa-fnsummary.h (ipa_call_summary): Add new field is_return_callee.
6118         * ipa-fnsummary.c (ipa_call_summary::reset): Set is_return_callee to
6119         false.
6120         (read_ipa_call_summary): Add support for reading is_return_callee.
6121         (write_ipa_call_summary): Stream is_return_callee.
6122         * ipa-inline.c (ipa_inline): Remove call to ipa_free_fn_summary.
6123         * ipa-pure-const.c: Add headers ssa.h, alloc-pool.h, symbol-summary.h,
6124         ipa-prop.h, ipa-fnsummary.h.
6125         (pure_const_names): Change to static.
6126         (malloc_state_e): Define.
6127         (malloc_state_names): Define.
6128         (funct_state_d): Add field malloc_state.
6129         (varying_state): Set malloc_state to STATE_MALLOC_BOTTOM.
6130         (check_retval_uses): New function.
6131         (malloc_candidate_p): Likewise.
6132         (analyze_function): Add support for malloc attribute.
6133         (pure_const_write_summary): Stream malloc_state.
6134         (pure_const_read_summary): Add support for reading malloc_state.
6135         (dump_malloc_lattice): New function.
6136         (propagate_malloc): New function.
6137         (warn_function_malloc): New function.
6138         (ipa_pure_const::execute): Call propagate_malloc and
6139         ipa_free_fn_summary.
6140         (pass_local_pure_const::execute): Add support for malloc attribute.
6141         * ssa-iterators.h (RETURN_FROM_IMM_USE_STMT): New macro.
6142         * doc/invoke.texi: Document Wsuggest-attribute=malloc.
6144 2017-10-27  Martin Liska  <mliska@suse.cz>
6146         PR gcov-profile/82457
6147         * doc/invoke.texi: Document that one needs a non-strict ISO mode
6148         for fork-like functions to be properly instrumented.
6150 2017-10-27  Richard Biener  <rguenther@suse.de>
6152         PR middle-end/81659
6153         * tree-eh.c (pass_lower_eh_dispatch::execute): Free dominator
6154         info when we redirected EH.
6156 2017-10-26  Michael Collison  <michael.collison@arm.com>
6158         * config/aarch64/aarch64.md(<optab>_trunc><vf><GPI:mode>2):
6159         New pattern.
6160         (<optab>_trunchf<GPI:mode>2: New pattern.
6161         (<optab>_trunc<vgp><GPI:mode>2: New pattern.
6162         * config/aarch64/iterators.md (wv): New mode attribute.
6163         (vf, VF): New mode attributes.
6164         (vgp, VGP): New mode attributes.
6165         (s): Update attribute with SImode and DImode prefixes.
6167 2017-10-26  Sandra Loosemore  <sandra@codesourcery.com>
6169         * config/nios2/constraints.md ("S"): Match r0rel_constant_p too.
6170         * config/nios2/nios2-protos.h (r0rel_constant_p): Declare.
6171         * config/nios2/nios2.c: (nios2_r0rel_sec_regex): New.
6172         (nios2_option_overide): Initialize it.  Don't allow R0-relative
6173         addressing with PIC.
6174         (nios2_rtx_costs): Handle r0rel_constant_p like gprel_constant_p.
6175         (nios2_symbolic_constant_p): Likewise.
6176         (nios2_legitimate_address_p): Likewise.
6177         (nios2_r0rel_section_name_p): New.
6178         (nios2_symbol_ref_in_r0rel_data_p): New.
6179         (nios2_emit_move_sequence): Handle r0rel_constant_p.
6180         (r0rel_constant_p): New.
6181         (nios2_print_operand_address): Handle r0rel_constant_p.
6182         (nios2_cdx_narrow_form_p): Likewise.
6183         * config/nios2/nios2.opt (mr0rel-sec=): New option.
6184         * doc/invoke.texi (Option Summary): Add -mr0rel-sec.
6185         (Nios II Options): Document -mr0rel-sec.
6187 2017-10-26  Sandra Loosemore  <sandra@codesourcery.com>
6189         * config/nios2/nios2.c: Include xregex.h.
6190         (nios2_gprel_sec_regex): New.
6191         (nios2_option_overide): Initialize it.  Don't allow GP-relative
6192         addressing with PIC.
6193         (nios2_small_section_name_p): Check for regex match.
6194         * config/nios2/nios2.opt (mgprel-sec=): New option.
6195         * doc/invoke.texi (Option Summary): Add -mgprel-sec.
6196         (Nios II Options): Document -mgprel-sec.
6198 2017-10-26  Jim Wilson  <wilson@tuliptree.org>
6200         * doc/invoke.texi (-fdebug-prefix-map): Expand documentation.
6202 2017-10-26  Tom de Vries  <tom@codesourcery.com>
6204         PR tree-optimization/82707
6205         * gimple.c (gimple_copy): Fix unsharing of
6206         GIMPLE_OMP_{SINGLE,TARGET,TEAMS}.
6208 2017-10-26  Olga Makhotina  <olga.makhotina@intel.com>
6210         * config/i386/avx512fintrin.h (_mm512_cmpeq_pd_mask,
6211         _mm512_cmple_pd_mask, _mm512_cmplt_pd_mask,
6212         _mm512_cmpneq_pd_mask, _mm512_cmpnle_pd_mask,
6213         _mm512_cmpnlt_pd_mask, _mm512_cmpord_pd_mask,
6214         _mm512_cmpunord_pd_mask, _mm512_mask_cmpeq_pd_mask,
6215         _mm512_mask_cmple_pd_mask, _mm512_mask_cmplt_pd_mask,
6216         _mm512_mask_cmpneq_pd_mask, _mm512_mask_cmpnle_pd_mask,
6217         _mm512_mask_cmpnlt_pd_mask, _mm512_mask_cmpord_pd_mask,
6218         _mm512_mask_cmpunord_pd_mask, _mm512_cmpeq_ps_mask,
6219         _mm512_cmple_ps_mask, _mm512_cmplt_ps_mask,
6220         _mm512_cmpneq_ps_mask, _mm512_cmpnle_ps_mask,
6221         _mm512_cmpnlt_ps_mask, _mm512_cmpord_ps_mask,
6222         _mm512_cmpunord_ps_mask, _mm512_mask_cmpeq_ps_mask,
6223         _mm512_mask_cmple_ps_mask, _mm512_mask_cmplt_ps_mask,
6224         _mm512_mask_cmpneq_ps_mask, _mm512_mask_cmpnle_ps_mask,
6225         _mm512_mask_cmpnlt_ps_mask, _mm512_mask_cmpord_ps_mask,
6226         _mm512_mask_cmpunord_ps_mask): New intrinsics.
6228 2017-10-26  Michael Meissner  <meissner@linux.vnet.ibm.com>
6230         * config/rs6000/aix.h (TARGET_IEEEQUAD_DEFAULT): Set long double
6231         default to IBM.
6232         * config/rs6000/darwin.h (TARGET_IEEEQUAD_DEFAULT): Likewise.
6233         * config/rs6000/rs6000.opt (-mabi=ieeelongdouble): Move the
6234         warning to rs6000.c.  Remove the Undocumented flag, since it has
6235         been documented.
6236         (-mabi=ibmlongdouble): Likewise.
6237         * config/rs6000/rs6000.c (TARGET_IEEEQUAD_DEFAULT): If it is not
6238         already set, set the default format for long double.
6239         (rs6000_debug_reg_global): Print whether long double is IBM or
6240         IEEE.
6241         (rs6000_option_override_internal): Rework setting long double
6242         format.  Only warn if the user is changing the long double default
6243         and they did not use -Wno-psabi.
6244         * doc/invoke.texi (PowerPC options): Update the documentation for
6245         -mabi=ieeelongdouble and -mabi=ibmlongdouble.
6247 2017-10-26  Richard Sandiford  <richard.sandiford@linaro.org>
6248             Alan Hayward  <alan.hayward@arm.com>
6249             David Sherwood  <david.sherwood@arm.com>
6251         * rtl.h (wider_subreg_mode): New function.
6252         * ira.h (ira_sort_regnos_for_alter_reg): Take a machine_mode *
6253         rather than an unsigned int *.
6254         * ira-color.c (regno_max_ref_width): Replace with...
6255         (regno_max_ref_mode): ...this new variable.
6256         (coalesced_pseudo_reg_slot_compare): Update accordingly.
6257         Use wider_subreg_mode.
6258         (ira_sort_regnos_for_alter_reg): Likewise.  Take a machine_mode *
6259         rather than an unsigned int *.
6260         * lra-constraints.c (uses_hard_regs_p): Use wider_subreg_mode.
6261         (process_alt_operands): Likewise.
6262         (invariant_p): Likewise.
6263         * lra-spills.c (assign_mem_slot): Likewise.
6264         (add_pseudo_to_slot): Likewise.
6265         * lra.c (collect_non_operand_hard_regs): Likewise.
6266         (add_regs_to_insn_regno_info): Likewise.
6267         * reload1.c (regno_max_ref_width): Replace with...
6268         (regno_max_ref_mode): ...this new variable.
6269         (reload): Update accordingly.  Update call to
6270         ira_sort_regnos_for_alter_reg.
6271         (alter_reg): Update to use regno_max_ref_mode.  Call wider_subreg_mode.
6272         (init_eliminable_invariants): Update to use regno_max_ref_mode.
6273         (scan_paradoxical_subregs): Likewise.
6275 2017-10-26  Wilco Dijkstra  <wdijkstr@arm.com>
6277         * config/aarch64/aarch64.h (EXIT_IGNORE_STACK): Set if alloca is used.
6278         (aarch64_frame): Add emit_frame_chain boolean.
6279         * config/aarch64/aarch64.c (aarch64_frame_pointer_required)
6280         Move eh_return case to aarch64_layout_frame.
6281         (aarch64_layout_frame): Initialize emit_frame_chain.
6282         (aarch64_expand_prologue): Use emit_frame_chain.
6284 2017-10-26  Wilco Dijkstra  <wdijkstr@arm.com>
6286         * config/aarch64/aarch64.c (aarch64_layout_frame):
6287         Ensure LR is always stored at the bottom of the callee-saves.
6288         Remove rarely used frame layout which saves callee-saves at top of
6289         frame, so the store of LR can be used as a valid probe in all cases.
6291 2017-10-26  Wilco Dijkstra  <wdijkstr@arm.com>
6293         * config/aarch64/aarch64.c (aarch64_legitimize_address_displacement):
6294         Improve unaligned TImode/TFmode base/offset split.
6296 2017-10-26  Richard Sandiford  <richard.sandiford@linaro.org>
6297             Alan Hayward  <alan.hayward@arm.com>
6298             David Sherwood  <david.sherwood@arm.com>
6300         * caller-save.c (mark_referenced_regs):  Use read_modify_subreg_p.
6301         * combine.c (find_single_use_1): Likewise.
6302         (expand_field_assignment): Likewise.
6303         (move_deaths): Likewise.
6304         * lra-constraints.c (simplify_operand_subreg): Likewise.
6305         (curr_insn_transform): Likewise.
6306         * lra.c (collect_non_operand_hard_regs): Likewise.
6307         (add_regs_to_insn_regno_info): Likewise.
6308         * rtlanal.c (reg_referenced_p): Likewise.
6309         (covers_regno_no_parallel_p): Likewise.
6311 2017-10-26  Richard Sandiford  <richard.sandiford@linaro.org>
6313         * wide-int-print.cc (print_hex): Loop based on extract_uhwi.
6314         Don't print any bits outside the precision of the value.
6315         * wide-int.cc (test_printing): Add some new tests.
6317 2017-10-26  Rainer Orth  <ro@CeBiTec.Uni-Bielefeld.DE>
6319         * configure.ac (gcc_cv_as_ix86_xbrace_comment): Check if assembler
6320         supports -xbrace_comment option.
6321         * configure: Regenerate.
6322         * config.in: Regenerate.
6323         * config/i386/sol2.h (ASM_XBRACE_COMMENT_SPEC): Define.
6324         (ASM_CPU_SPEC): Use it.
6326 2017-10-26  Richard Sandiford  <richard.sandiford@linaro.org>
6328         * target.def (static_rtx_alignment): New hook.
6329         * targhooks.h (default_static_rtx_alignment): Declare.
6330         * targhooks.c (default_static_rtx_alignment): New function.
6331         * doc/tm.texi.in (TARGET_STATIC_RTX_ALIGNMENT): New hook.
6332         * doc/tm.texi: Regenerate.
6333         * varasm.c (force_const_mem): Use targetm.static_rtx_alignment
6334         instead of targetm.constant_alignment.  Remove call to
6335         set_mem_attributes.
6336         * config/cris/cris.c (TARGET_STATIC_RTX_ALIGNMENT): Redefine.
6337         (cris_preferred_mininum_alignment): New function, split out from...
6338         (cris_constant_alignment): ...here.
6339         (cris_static_rtx_alignment): New function.
6340         * config/i386/i386.c (ix86_static_rtx_alignment): New function,
6341         split out from...
6342         (ix86_constant_alignment): ...here.
6343         (TARGET_STATIC_RTX_ALIGNMENT): Redefine.
6344         * config/mmix/mmix.c (TARGET_STATIC_RTX_ALIGNMENT): Redefine.
6345         (mmix_static_rtx_alignment): New function.
6346         * config/spu/spu.c (spu_static_rtx_alignment): New function.
6347         (TARGET_STATIC_RTX_ALIGNMENT): Redefine.
6349 2017-10-26  Tamar Christina  <tamar.christina@arm.com>
6351         PR target/81800
6352         * config/aarch64/aarch64.md (lrint<GPF:mode><GPI:mode>2):
6353         Add flag_trapping_math and flag_fp_int_builtin_inexact.
6355 2017-10-25  Palmer Dabbelt  <palmer@dabbelt.com>
6357         * config/riscv/riscv.md (ZERO_EXTEND_LOAD): Define.
6358         * config/riscv/pic.md (local_pic_load): Rename to local_pic_load_s,
6359         mark as a sign-extending load.
6360         (local_pic_load_u): Define.
6362 2017-10-25  Eric Botcazou  <ebotcazou@adacore.com>
6364         PR middle-end/82062
6365         * fold-const.c (operand_equal_for_comparison_p): Also return true
6366         if ARG0 is a simple variant of ARG1 with narrower precision.
6367         (fold_ternary_loc): Always pass unstripped operands to the predicate.
6369 2017-10-25  Jan Hubicka  <hubicka@ucw.cz>
6371         * i386.c (ix86_builtin_vectorization_cost): Compute scatter/gather
6372         cost correctly.
6373         * i386.h (processor_costs): Add gather_static, gather_per_elt,
6374         scatter_static, scatter_per_elt.
6375         * x86-tune-costs.h: Add new cost entries.
6377 2017-10-25  Richard Biener  <rguenther@suse.de>
6379         * tree-ssa-sccvn.h (vn_eliminate): Declare.
6380         * tree-ssa-pre.c (class eliminate_dom_walker, eliminate,
6381         class pass_fre): Move to ...
6382         * tree-ssa-sccvn.c (class eliminate_dom_walker, vn_eliminate,
6383         class pass_fre): ... here and adjust for statistics.
6385 2017-10-25  Jakub Jelinek  <jakub@redhat.com>
6387         PR libstdc++/81706
6388         * attribs.c (attribute_value_equal): Use omp_declare_simd_clauses_equal
6389         for comparison of OMP_CLAUSEs regardless of flag_openmp{,_simd}.
6390         (duplicate_one_attribute, copy_attributes_to_builtin): New functions.
6391         * attribs.h (duplicate_one_attribute, copy_attributes_to_builtin): New
6392         declarations.
6394 2017-10-25  Richard Biener  <rguenther@suse.de>
6396         * tree-ssa-pre.c (need_eh_cleanup, need_ab_cleanup, el_to_remove,
6397         el_to_fixup, el_todo, el_avail, el_avail_stack, eliminate_avail,
6398         eliminate_push_avail, eliminate_insert): Move inside...
6399         (class eliminate_dom_walker): ... this class in preparation
6400         of move.
6401         (fini_eliminate): Remove by merging with ...
6402         (eliminate): ... this function.  Adjust for class changes.
6403         (pass_pre::execute): Remove fini_eliminate call.
6404         (pass_fre::execute): Likewise.
6406 2017-10-24  Jakub Jelinek  <jakub@redhat.com>
6408         PR target/82460
6409         * config/i386/sse.md (UNSPEC_VPERMI2, UNSPEC_VPERMI2_MASK): Remove.
6410         (VPERMI2, VPERMI2I): New mode iterators.
6411         (<avx512>_vpermi2var<mode>3_maskz): Remove 3 define_expand patterns.
6412         (<avx512>_vpermi2var<mode>3<sd_maskz_name>): Remove 3 define_insn
6413         patterns.
6414         (<avx512>_vpermi2var<mode>3_mask): New define_expand using VPERMI2
6415         mode iterator.  Remove 3 old define_insn patterns.
6416         (*<avx512>_vpermi2var<mode>3_mask): 2 new define_insn patterns.
6417         (<avx512>_vpermt2var<mode>3_maskz): Adjust 1 define_expand to use
6418         VPERMI2 mode iterator, remove the other two expanders.
6419         (<avx512>_vpermt2var<mode>3<sd_maskz_name>): Adjust 1 define_insn
6420         to use VPERMI2 mode iterator, add another alternative for vpermi2*
6421         instructions, remove the other two patterns.
6422         (<avx512>_vpermt2var<mode>3_mask): Adjust 1 define_insn to use VPERMI2
6423         mode iterator, remove the other two patterns.
6424         * config/i386/i386.c (ix86_expand_vec_perm_vpermi2): Renamed to ...
6425         (ix86_expand_vec_perm_vpermt2): ... this.  Swap mask and op0
6426         arguments, use gen_*vpermt2* expanders instead of gen_*vpermi2*
6427         and adjust argument order accordingly.
6428         (ix86_expand_vec_perm): Adjust caller.
6429         (expand_vec_perm_1): Likewise.
6430         (expand_vec_perm_vpermi2_vpshub2): Rename to ...
6431         (expand_vec_perm_vpermt2_vpshub2): ... this.
6432         (ix86_expand_vec_perm_const_1): Adjust caller.
6433         (ix86_vectorize_vec_perm_const_ok): Adjust comments.
6435         PR target/82370
6436         * config/i386/sse.md (VIMAX_AVX2): Remove V4TImode.
6437         (VIMAX_AVX2_AVX512BW, VIMAX_AVX512VL): New mode iterators.
6438         (vec_shl_<mode>): Remove unused expander.
6439         (avx512bw_<shift_insn><mode>3): New define_insn.
6440         (<sse2_avx2>_ashl<mode>3, <sse2_avx2>_lshr<mode>3): Replaced by ...
6441         (<sse2_avx2>_<shift_insn><mode>3): ... this.  New define_insn.
6443 2017-10-24  Paolo Carlini  <paolo.carlini@oracle.com>
6445         PR c++/82466
6446         * doc/invoke.texi ([Wbuiltin-declaration-mismatch]): Extend
6447         description.
6449 2017-10-24  Wilco Dijkstra  <wdijkstr@arm.com>
6451         PR rtl-optimization/82396
6452         * gcc/haifa-sched.c (ready_sort_real): Remove qsort workaround.
6453         (autopref_multipass_init): Simplify initialization.
6454         (autopref_rank_data): Simplify sort order.
6455         * gcc/sched-int.h (autopref_multipass_data_): Remove
6456         multi_mem_insn_p, min_offset and max_offset.
6458 2017-10-24  Wilco Dijkstra  <wdijkstr@arm.com>
6460         PR middle-end/60580
6461         * config/aarch64/aarch64.c (aarch64_frame_pointer_required)
6462         Check special value of flag_omit_frame_pointer.
6463         (aarch64_can_eliminate): Likewise.
6464         (aarch64_override_options_after_change_1): Simplify handling of
6465         -fomit-frame-pointer and -fomit-leaf-frame-pointer.
6467 2017-10-24  Richard Biener  <rguenther@suse.de>
6469         PR tree-optimization/82697
6470         * tree-ssa-phiopt.c (cond_store_replacement): Use alias-set
6471         zero for conditional load and unconditional store.
6473 2017-10-24  H.J. Lu  <hongjiu.lu@intel.com>
6475         * doc/install.texi: Document bootstrap-cet.
6477 2017-10-24  H.J. Lu  <hongjiu.lu@intel.com>
6479         PR target/82659
6480         * config/i386/i386.c (rest_of_insert_endbranch): Don't insert
6481         ENDBR instruction at function entrance if function is only
6482         called directly.
6484 2017-10-24  Jakub Jelinek  <jakub@redhat.com>
6486         PR target/82628
6487         * config/i386/i386.md (addcarry<mode>, subborrow<mode>): Change
6488         patterns to better describe from which operation the CF is computed.
6489         (addcarry<mode>_0, subborrow<mode>_0): New patterns.
6490         * config/i386/i386.c (ix86_expand_builtin) <case handlecarry>: Pass
6491         one LTU with [DT]Imode and another one with [SD]Imode.  If arg0
6492         is 0, use _0 suffixed expanders instead of emitting a comparison
6493         before it.
6495 2017-10-06  Sergey Shalnov  <Sergey.Shalnov@intel.com>
6497         * config/i386/i386.md(*movsf_internal, *movdf_internal):
6498         Avoid 512-bit AVX modes for TARGET_PREFER_AVX256.
6500 2017-10-24  Eric Botcazou  <ebotcazou@adacore.com>
6502         PR middle-end/82569
6503         * tree-outof-ssa.h (always_initialized_rtx_for_ssa_name_p): Delete.
6504         * expr.c (expand_expr_real_1) <expand_decl_rtl>: Revert latest change.
6505         * loop-iv.c (iv_get_reaching_def): Likewise.
6506         * cfgexpand.c (expand_one_ssa_partition): Initialize the RTX if the
6507         variable is promoted and the partition contains undefined values.
6509 2017-10-23  Sandra Loosemore  <sandra@codesourcery.com>
6511         * config/nios2/nios2.c (nios2_rtx_costs): Make costs better
6512         reflect reality.
6513         (nios2_address_cost): Define.
6514         (nios2_legitimize_address): Recognize (exp + constant) directly.
6515         (TARGET_ADDRESS_COST): Define.
6517 2017-10-23  Sandra Loosemore  <sandra@codesourcery.com>
6519         * config/nios2/nios2-protos.h (nios2_large_constant_p): Declare.
6520         (nios2_symbolic_memory_operand_p): Declare.
6521         (nios2_split_large_constant): Declare.
6522         (nios2_split_symbolic_memory_operand): Declare.
6523         * config/nios2/nios2.c: Adjust includes.
6524         (nios2_symbolic_constant_allowed): New.
6525         (nios2_symbolic_constant_p): New.
6526         (nios2_plus_symbolic_constant_p): New.
6527         (nios2_valid_addr_expr_p): Recognize addresses involving
6528         symbolic constants.
6529         (nios2_legitimate_address_p): Likewise, also LO_SUM.
6530         (nios2_symbolic_memory_operand_p): New.
6531         (nios2_large_constant_p): New.
6532         (nios2_split_large_constant): New.
6533         (nios2_split_plus_large_constant): New.
6534         (nios2_split_symbolic_memory_operand): New.
6535         (nios2_legitimize_address): Code refactoring.  Handle addresses
6536         involving symbolic constants.
6537         (nios2_emit_move_sequence): Likewise.
6538         (nios2_print_operand): Improve error output.
6539         (nios2_print_operand_address): Handle LO_SUM.
6540         (nios2_cdx_narrow_form_p): Likewise.
6541         * config/nios2/nios2.md (movqi_internal): Add splitter for memory
6542         operands involving symbolic constants.
6543         (movhi_internal, movsi_internal): Likewise.
6544         (zero_extendhisi2, zero_extendqi<mode>2): Likewise.
6545         (extendhisi2, extendqi<mode>2): Likewise.
6547 2017-10-23  Sandra Loosemore  <sandra@codesourcery.com>
6549         * tree-pass.h (PROP_rtl_split_insns): Define.
6550         * recog.c (pass_data_split_all_insns): Provide PROP_rtl_split_insns.
6552 2017-10-23  Sandra Loosemore  <sandra@codesourcery.com>
6554         * config/nios2/nios2.c (TARGET_LRA_P): Don't override.
6556 2017-10-23  Jakub Jelinek  <jakub@redhat.com>
6558         PR debug/82630
6559         * target.def (const_not_ok_for_debug_p): Default to
6560         default_const_not_ok_for_debug_p instead of hook_bool_rtx_false.
6561         * targhooks.h (default_const_not_ok_for_debug_p): New declaration.
6562         * targhooks.c (default_const_not_ok_for_debug_p): New function.
6563         * dwarf2out.c (const_ok_for_output_1): Only reject UNSPECs for
6564         which targetm.const_not_ok_for_debug_p returned true.
6565         * config/arm/arm.c (arm_const_not_ok_for_debug_p): Return true
6566         for UNSPECs.
6567         * config/powerpcspe/powerpcspe.c (rs6000_const_not_ok_for_debug_p):
6568         Likewise.
6569         * config/rs6000/rs6000.c (rs6000_const_not_ok_for_debug_p): Likewise.
6570         * config/i386/i386.c (ix86_delegitimize_address_1): Don't delegitimize
6571         UNSPEC_GOTOFF with addend into addend - _GLOBAL_OFFSET_TABLE_ + symbol
6572         if !base_term_p.
6573         (ix86_const_not_ok_for_debug_p): New function.
6574         (i386_asm_output_addr_const_extra): Handle UNSPEC_GOTOFF.
6575         (TARGET_CONST_NOT_OK_FOR_DEBUG_P): Redefine.
6577 2017-10-23  David Malcolm  <dmalcolm@redhat.com>
6579         PR bootstrap/82610
6580         * system.h: Conditionally include "unique-ptr.h" if
6581         INCLUDE_UNIQUE_PTR is defined.
6582         * unique-ptr-tests.cc: Remove include of "unique-ptr.h" in favor
6583         of defining INCLUDE_UNIQUE_PTR before including "system.h".
6585 2017-10-23  Sebastian Perta  <sebastian.perta@renesas.com>
6587         * config/rl78/rl78.md: New define_expand "subdi3".
6589 2017-10-23  H.J. Lu  <hongjiu.lu@intel.com>
6591         PR target/82673
6592         * config/i386/i386.c (ix86_finalize_stack_frame_flags): Skip
6593         DF_REF_INSN if DF_REF_INSN_INFO is false.
6595 2017-10-23  Jan Hubicka  <hubicka@ucw.cz>
6597         * i386.c (dimode_scalar_chain::compute_convert_gain): Use
6598         xmm_move instead of sse_move.
6599         (sse_store_index): New function.
6600         (ix86_register_move_cost): Be more sensible about mismatch stall;
6601         model AVX moves correctly; make difference between sse->integer and
6602         integer->sse.
6603         (ix86_builtin_vectorization_cost): Model correctly aligned and unaligned
6604         moves; make difference between SSE and AVX.
6605         * i386.h (processor_costs): Remove sse_move; add xmm_move, ymm_move
6606         and zmm_move. Increase size of sse load and store tables;
6607         add unaligned load and store tables; add ssemmx_to_integer.
6608         * x86-tune-costs.h: Update all entries according to real
6609         move latencies from Agner Fog's manual and chip documentation.
6611 2017-10-23  Jakub Jelinek  <jakub@redhat.com>
6613         PR target/82628
6614         * config/i386/predicates.md (x86_64_dwzext_immediate_operand): New.
6615         * config/i386/constraints.md (Wf): New constraint.
6616         * config/i386/i386.md (UNSPEC_SBB): New unspec.
6617         (cmp<dwi>_doubleword): Removed.
6618         (sub<mode>3_carry_ccc, *sub<mode>3_carry_ccc_1): New patterns.
6619         (sub<mode>3_carry_ccgz): Use unspec instead of compare.
6620         * config/i386/i386.c (ix86_expand_branch) <case E_TImode>: Don't
6621         expand with cmp<dwi>_doubleword.  For LTU and GEU use
6622         sub<mode>3_carry_ccc instead of sub<mode>3_carry_ccgz and use CCCmode.
6624         * common.opt (gcolumn-info): Enable by default.
6625         * doc/invoke.texi (gcolumn-info): Document new default.
6627 2017-10-23  Richard Biener  <rguenther@suse.de>
6629         PR tree-optimization/82672
6630         * graphite-isl-ast-to-gimple.c (graphite_copy_stmts_from_block):
6631         Fold the stmt if we propagated into it.
6633 2017-10-23  Richard Biener  <rguenther@suse.de>
6635         * tree-ssa-pre.c (bitmap_remove_from_set): Rename to...
6636         (bitmap_remove_expr_from_set): ... this.  All callers call this
6637         for non-constant values.
6638         (bitmap_set_subtract): Rename to...
6639         (bitmap_set_subtract_expressions): ... this.  Adjust and
6640         optimize.
6641         (bitmap_set_contains_value): Remove superfluous check.
6642         (bitmap_set_replace_value): Inline into single caller ...
6643         (bitmap_value_replace_in_set): ... here and simplify.
6644         (dependent_clean): Merge into ...
6645         (clean): ... this using an overload.  Adjust.
6646         (prune_clobbered_mems): Adjust.
6647         (compute_antic_aux): Likewise.
6648         (compute_partial_antic_aux): Likewise.
6650 2017-10-23  Richard Biener  <rguenther@suse.de>
6652         PR tree-optimization/82129
6653         Revert
6654         2017-08-01  Richard Biener  <rguenther@suse.de>
6656         PR tree-optimization/81181
6657         * tree-ssa-pre.c (compute_antic_aux): Defer clean() to ...
6658         (compute_antic): ... end of iteration here.
6660 2017-10-23  Richard Sandiford  <richard.sandiford@linaro.org>
6662         * target.def (starting_frame_offset): New hook.
6663         * doc/tm.texi (STARTING_FRAME_OFFSET): Remove in favor of...
6664         (TARGET_STARTING_FRAME_OFFSET): ...this new hook.
6665         * doc/tm.texi.in: Regenerate.
6666         * hooks.h (hook_hwi_void_0): Declare.
6667         * hooks.c (hook_hwi_void_0): New function.
6668         * doc/rtl.texi: Refer to TARGET_STARTING_FRAME_OFFSET instead of
6669         STARTING_FRAME_OFFSET.
6670         * builtins.c (expand_builtin_setjmp_receiver): Likewise.
6671         * reload1.c (reload): Likewise.
6672         * cfgexpand.c (expand_used_vars): Use targetm.starting_frame_offset
6673         instead of STARTING_FRAME_OFFSET.
6674         * function.c (try_fit_stack_local): Likewise.
6675         (assign_stack_local_1): Likewise
6676         (instantiate_virtual_regs): Likewise.
6677         * rtlanal.c (rtx_addr_can_trap_p_1): Likewise.
6678         * config/avr/avr.md (nonlocal_goto_receiver): Likewise.
6679         * config/aarch64/aarch64.h (STARTING_FRAME_OFFSET): Delete.
6680         * config/alpha/alpha.h (STARTING_FRAME_OFFSET): Likewise.
6681         * config/arc/arc.h (STARTING_FRAME_OFFSET): Likewise.
6682         * config/arm/arm.h (STARTING_FRAME_OFFSET): Likewise.
6683         * config/bfin/bfin.h (STARTING_FRAME_OFFSET): Likewise.
6684         * config/c6x/c6x.h (STARTING_FRAME_OFFSET): Likewise.
6685         * config/cr16/cr16.h (STARTING_FRAME_OFFSET): Likewise.
6686         * config/cris/cris.h (STARTING_FRAME_OFFSET): Likewise.
6687         * config/fr30/fr30.h (STARTING_FRAME_OFFSET): Likewise.
6688         * config/frv/frv.h (STARTING_FRAME_OFFSET): Likewise.
6689         * config/ft32/ft32.h (STARTING_FRAME_OFFSET): Likewise.
6690         * config/h8300/h8300.h (STARTING_FRAME_OFFSET): Likewise.
6691         * config/i386/i386.h (STARTING_FRAME_OFFSET): Likewise.
6692         * config/ia64/ia64.h (STARTING_FRAME_OFFSET): Likewise.
6693         * config/m32c/m32c.h (STARTING_FRAME_OFFSET): Likewise.
6694         * config/m68k/m68k.h (STARTING_FRAME_OFFSET): Likewise.
6695         * config/mcore/mcore.h (STARTING_FRAME_OFFSET): Likewise.
6696         * config/mn10300/mn10300.h (STARTING_FRAME_OFFSET): Likewise.
6697         * config/moxie/moxie.h (STARTING_FRAME_OFFSET): Likewise.
6698         * config/msp430/msp430.h (STARTING_FRAME_OFFSET): Likewise.
6699         * config/nds32/nds32.h (STARTING_FRAME_OFFSET): Likewise.
6700         * config/nios2/nios2.h (STARTING_FRAME_OFFSET): Likewise.
6701         * config/nvptx/nvptx.h (STARTING_FRAME_OFFSET): Likewise.
6702         * config/pdp11/pdp11.h (STARTING_FRAME_OFFSET): Likewise.
6703         * config/riscv/riscv.h (STARTING_FRAME_OFFSET): Likewise.
6704         * config/rl78/rl78.h (STARTING_FRAME_OFFSET): Likewise.
6705         * config/rx/rx.h (STARTING_FRAME_OFFSET): Likewise.
6706         * config/s390/s390.h (STARTING_FRAME_OFFSET): Likewise.
6707         * config/sh/sh.h (STARTING_FRAME_OFFSET): Likewise.
6708         * config/sparc/sparc.c (sparc_compute_frame_size): Likewise.
6709         * config/sparc/sparc.h (STARTING_FRAME_OFFSET): Likewise.
6710         * config/spu/spu.h (STARTING_FRAME_OFFSET): Likewise.
6711         * config/stormy16/stormy16.h (STARTING_FRAME_OFFSET): Likewise.
6712         * config/tilegx/tilegx.h (STARTING_FRAME_OFFSET): Likewise.
6713         * config/tilepro/tilepro.h (STARTING_FRAME_OFFSET): Likewise.
6714         * config/v850/v850.h (STARTING_FRAME_OFFSET): Likewise.
6715         * config/visium/visium.h (STARTING_FRAME_OFFSET): Likewise.
6716         * config/avr/avr.h (STARTING_FRAME_OFFSET): Likewise.
6717         * config/avr/avr-protos.h (avr_starting_frame_offset): Likewise.
6718         * config/avr/avr.c (avr_starting_frame_offset): Make static and
6719         return a HOST_WIDE_INT.
6720         (avr_builtin_setjmp_frame_value): Use it instead of
6721         STARTING_FRAME_OFFSET.
6722         (TARGET_STARTING_FRAME_OFFSET): Redefine.
6723         * config/epiphany/epiphany.h (STARTING_FRAME_OFFSET): Delete.
6724         * config/epiphany/epiphany.c (epiphany_starting_frame_offset):
6725         New function.
6726         (TARGET_STARTING_FRAME_OFFSET): Redefine.
6727         * config/iq2000/iq2000.h (STARTING_FRAME_OFFSET): Delete.
6728         * config/iq2000/iq2000.c (iq2000_starting_frame_offset): New function.
6729         (TARGET_CONSTANT_ALIGNMENT): Redefine.
6730         * config/lm32/lm32.h (STARTING_FRAME_OFFSET): Delete.
6731         * config/lm32/lm32.c (lm32_starting_frame_offset): New function.
6732         (TARGET_STARTING_FRAME_OFFSET): Redefine.
6733         * config/m32r/m32r.h (STARTING_FRAME_OFFSET): Delete.
6734         * config/m32r/m32r.c (m32r_starting_frame_offset): New function.
6735         (TARGET_STARTING_FRAME_OFFSET): Redefine.
6736         * config/microblaze/microblaze.h (STARTING_FRAME_OFFSET): Delete.
6737         * config/microblaze/microblaze.c (microblaze_starting_frame_offset):
6738         New function.
6739         (TARGET_STARTING_FRAME_OFFSET): Redefine.
6740         * config/mips/mips.h (STARTING_FRAME_OFFSET): Delete.
6741         * config/mips/mips.c (mips_compute_frame_info): Refer to
6742         TARGET_STARTING_FRAME_OFFSET instead of STARTING_FRAME_OFFSET.
6743         (mips_starting_frame_offset): New function.
6744         (TARGET_STARTING_FRAME_OFFSET): Redefine.
6745         * config/mmix/mmix.h (STARTING_FRAME_OFFSET): Delete.
6746         * config/mmix/mmix-protos.h (mmix_starting_frame_offset): Delete.
6747         * config/mmix/mmix.c (mmix_starting_frame_offset): Make static
6748         and return a HOST_WIDE_INT.
6749         (TARGET_STARTING_FRAME_OFFSET): Redefine.
6750         (mmix_initial_elimination_offset): Refer to
6751         TARGET_STARTING_FRAME_OFFSET instead of STARTING_FRAME_OFFSET.
6752         * config/pa/pa.h (STARTING_FRAME_OFFSET): Delete.
6753         * config/pa/pa.c (pa_starting_frame_offset): New function.
6754         (pa_compute_frame_size): Use it instead of STARTING_FRAME_OFFSET.
6755         (pa_expand_prologue): Likewise.
6756         (TARGET_STARTING_FRAME_OFFSET): Redefine.
6757         * config/powerpcspe/aix.h (STARTING_FRAME_OFFSET): Split out
6758         !FRAME_GROWS_DOWNWARD handling to...
6759         (RS6000_STARTING_FRAME_OFFSET): ...this new macro.
6760         * config/powerpcspe/darwin.h (STARTING_FRAME_OFFSET): Split out
6761         !FRAME_GROWS_DOWNWARD handling to...
6762         (RS6000_STARTING_FRAME_OFFSET): ...this new macro.
6763         * config/powerpcspe/powerpcspe.h (STARTING_FRAME_OFFSET): Split out
6764         !FRAME_GROWS_DOWNWARD handling to...
6765         (RS6000_STARTING_FRAME_OFFSET): ...this new macro.
6766         * config/powerpcspe/powerpcspe.c (TARGET_STARTING_FRAME_OFFSET):
6767         Redefine.
6768         (rs6000_starting_frame_offset): New function.
6769         * config/rs6000/aix.h (STARTING_FRAME_OFFSET): Split out
6770         !FRAME_GROWS_DOWNWARD handling to...
6771         (RS6000_STARTING_FRAME_OFFSET): ...this new macro.
6772         * config/rs6000/darwin.h (STARTING_FRAME_OFFSET): Split out
6773         !FRAME_GROWS_DOWNWARD handling to...
6774         (RS6000_STARTING_FRAME_OFFSET): ...this new macro.
6775         * config/rs6000/rs6000.h (STARTING_FRAME_OFFSET): Split out
6776         !FRAME_GROWS_DOWNWARD handling to...
6777         (RS6000_STARTING_FRAME_OFFSET): ...this new macro.
6778         * config/rs6000/rs6000.c (TARGET_STARTING_FRAME_OFFSET): Refine.
6779         (rs6000_starting_frame_offset): New function.
6780         * config/vax/elf.h (STARTING_FRAME_OFFSET): Delete.
6781         * config/vax/vax.h (STARTING_FRAME_OFFSET): Delete.
6782         * config/vax/vax.c (vax_starting_frame_offset): New function.
6783         (vax_expand_prologue): Use it instead of STARTING_FRAME_OFFSET.
6784         (TARGET_STARTING_FRAME_OFFSET): Redefine.
6785         * config/xtensa/xtensa.h (STARTING_FRAME_OFFSET): Delete.
6786         * config/xtensa/xtensa.c (xtensa_starting_frame_offset): New function.
6787         (TARGET_STARTING_FRAME_OFFSET): Redefine.
6788         * system.h (STARTING_FRAME_OFFSET): Poison.
6790 2017-10-23  Richard Sandiford  <richard.sandiford@linaro.org>
6792         * tree-vect-loop.c (vect_create_epilog_for_reduction): Use
6793         SCALAR_TYPE_MODE instead of TYPE_MODE.
6795 2017-10-23  Richard Sandiford  <richard.sandiford@linaro.org>
6796             Alan Hayward  <alan.hayward@arm.com>
6797             David Sherwood  <david.sherwood@arm.com>
6799         * dwarf2out.c (loc_list_from_tree_1): Use SCALAR_INT_TYPE_MODE
6801 2017-10-23  Richard Sandiford  <richard.sandiford@linaro.org>
6802             Alan Hayward  <alan.hayward@arm.com>
6803             David Sherwood  <david.sherwood@arm.com>
6805         * expmed.c (expand_shift_1): Use scalar_mode for scalar_mode.
6807 2017-10-23  Richard Biener  <rguenther@suse.de>
6809         PR tree-optimization/82129
6810         * tree-ssa-pre.c (bitmap_set_and): Remove.
6811         (compute_antic_aux): Compute ANTIC_OUT intersection in a way
6812         canonicalizing expressions in the set to those with lowest
6813         ID rather than taking that from the first edge.
6815 2017-10-23  Richard Sandiford  <richard.sandiford@linaro.org>
6817         * combine.c (rtx_equal_for_field_assignment_p): Use
6818         byte_lowpart_offset.
6820 2017-10-22  Richard Sandiford  <richard.sandiford@linaro.org>
6821             Alan Hayward  <alan.hayward@arm.com>
6822             David Sherwood  <david.sherwood@arm.com>
6824         * internal-fn.c (expand_direct_optab_fn): Don't assign directly
6825         to a SUBREG_PROMOTED_VAR.
6827 2017-10-22  Richard Sandiford  <richard.sandiford@linaro.org>
6828             Alan Hayward  <alan.hayward@arm.com>
6829             David Sherwood  <david.sherwood@arm.com>
6831         * cfgexpand.c (expand_debug_expr): Use GET_MODE_UNIT_PRECISION.
6832         (expand_debug_source_expr): Likewise.
6833         * combine.c (combine_simplify_rtx): Likewise.
6834         * cse.c (fold_rtx): Likewise.
6835         * optabs.c (expand_float): Likewise.
6836         * simplify-rtx.c (simplify_unary_operation_1): Likewise.
6837         (simplify_binary_operation_1): Likewise.
6839 2017-10-22  Richard Sandiford  <richard.sandiford@linaro.org>
6840             Alan Hayward  <alan.hayward@arm.com>
6841             David Sherwood  <david.sherwood@arm.com>
6843         * combine.c (simplify_comparison): Use HWI_COMPUTABLE_MODE_P.
6844         (record_promoted_value): Likewise.
6845         * expr.c (expand_expr_real_2): Likewise.
6846         * ree.c (update_reg_equal_equiv_notes): Likewise.
6847         (combine_set_extension): Likewise.
6848         * rtlanal.c (low_bitmask_len): Likewise.
6849         * simplify-rtx.c (neg_const_int): Likewise.
6850         (simplify_binary_operation_1): Likewise.
6852 2017-10-22  Richard Sandiford  <richard.sandiford@linaro.org>
6853             Alan Hayward  <alan.hayward@arm.com>
6854             David Sherwood  <david.sherwood@arm.com>
6856         * lra-spills.c (assign_mem_slot): Use subreg_size_lowpart_offset.
6857         * regcprop.c (maybe_mode_change): Likewise.
6858         * reload1.c (alter_reg): Likewise.
6860 2017-10-22  Richard Sandiford  <richard.sandiford@linaro.org>
6862         * inchash.h (inchash::hash::add_wide_int): New function.
6863         * lto-streamer-out.c (hash_tree): Use it.
6865 2017-10-22  Richard Sandiford  <richard.sandiford@linaro.org>
6867         * inchash.h (inchash::hash::add_wide_int): Rename to...
6868         (inchash::hash::add_hwi): ...this.
6869         * ipa-devirt.c (hash_odr_vtable): Update accordingly.
6870         (polymorphic_call_target_hasher::hash): Likewise.
6871         * ipa-icf.c (sem_function::get_hash, sem_function::init): Likewise.
6872         (sem_item::add_expr, sem_item::add_type, sem_variable::get_hash)
6873         (sem_item_optimizer::update_hash_by_addr_refs): Likewise.
6874         * lto-streamer-out.c (hash_tree): Likewise.
6875         * optc-save-gen.awk: Likewise.
6876         * tree.c (add_expr): Likewise.
6878 2017-10-22  Uros Bizjak  <ubizjak@gmail.com>
6880         PR target/52451
6881         * config/i386/i386.c (ix86_fp_compare_mode): Return CCFPmode
6882         for ordered inequality comparisons even with TARGET_IEEE_FP.
6884 2017-10-22  Uros Bizjak  <ubizjak@gmail.com>
6886         PR target/82628
6887         * config/i386/i386.md (cmp<dwi>_doubleword): New pattern.
6888         * config/i386/i386.c (ix86_expand_branch) <case E_TImode>:
6889         Expand with cmp<dwi>_doubleword.
6891 2017-10-21  Igor Tsimbalist  <igor.v.tsimbalist@intel.com>
6893         * extend.texi: Add x86 specific to 'nocf_check' attribute.
6894         List CET intrinsics.
6895         * invoke.texi: Add -mcet, -mibt, -mshstk options.  Add x86
6896         specific to -fcf-protection option.
6898 2017-10-21  Igor Tsimbalist  <igor.v.tsimbalist@intel.com>
6900         * common/config/i386/i386-common.c (OPTION_MASK_ISA_IBT_SET): New.
6901         (OPTION_MASK_ISA_SHSTK_SET): Likewise.
6902         (OPTION_MASK_ISA_IBT_UNSET): Likewise.
6903         (OPTION_MASK_ISA_SHSTK_UNSET): Likewise.
6904         (ix86_handle_option): Add -mibt, -mshstk, -mcet handling.
6905         * config.gcc (extra_headers): Add cetintrin.h for x86 targets.
6906         (extra_objs): Add cet.o for Linux/x86 targets.
6907         (tmake_file): Add i386/t-cet for Linux/x86 targets.
6908         * config/i386/cet.c: New file.
6909         * config/i386/cetintrin.h: Likewise.
6910         * config/i386/t-cet: Likewise.
6911         * config/i386/cpuid.h (bit_SHSTK): New.
6912         (bit_IBT): Likewise.
6913         * config/i386/driver-i386.c (host_detect_local_cpu): Detect and
6914         pass IBT and SHSTK bits.
6915         * config/i386/i386-builtin-types.def
6916         (VOID_FTYPE_UNSIGNED_PVOID): New.
6917         (VOID_FTYPE_UINT64_PVOID): Likewise.
6918         * config/i386/i386-builtin.def: Add CET intrinsics.
6919         * config/i386/i386-c.c (ix86_target_macros_internal): Add
6920         OPTION_MASK_ISA_IBT, OPTION_MASK_ISA_SHSTK handling.
6921         * config/i386/i386-passes.def: Add pass_insert_endbranch pass.
6922         * config/i386/i386-protos.h (make_pass_insert_endbranch): New
6923         prototype.
6924         * config/i386/i386.c (rest_of_insert_endbranch): New.
6925         (pass_data_insert_endbranch): Likewise.
6926         (pass_insert_endbranch): Likewise.
6927         (make_pass_insert_endbranch): Likewise.
6928         (ix86_notrack_prefixed_insn_p): Likewise.
6929         (ix86_target_string): Add -mibt, -mshstk flags.
6930         (ix86_option_override_internal): Add flag_cf_protection
6931         processing.
6932         (ix86_valid_target_attribute_inner_p): Set OPT_mibt, OPT_mshstk.
6933         (ix86_print_operand): Add 'notrack' prefix output.
6934         (ix86_init_mmx_sse_builtins): Add CET intrinsics.
6935         (ix86_expand_builtin): Expand CET intrinsics.
6936         (x86_output_mi_thunk): Add 'endbranch' instruction.
6937         * config/i386/i386.h (TARGET_IBT): New.
6938         (TARGET_IBT_P): Likewise.
6939         (TARGET_SHSTK): Likewise.
6940         (TARGET_SHSTK_P): Likewise.
6941         * config/i386/i386.md (unspecv): Add UNSPECV_NOP_RDSSP,
6942         UNSPECV_INCSSP, UNSPECV_SAVEPREVSSP, UNSPECV_RSTORSSP,
6943         UNSPECV_WRSS, UNSPECV_WRUSS, UNSPECV_SETSSBSY, UNSPECV_CLRSSBSY.
6944         (builtin_setjmp_setup): New pattern.
6945         (builtin_longjmp): Likewise.
6946         (rdssp<mode>): Likewise.
6947         (incssp<mode>): Likewise.
6948         (saveprevssp): Likewise.
6949         (rstorssp): Likewise.
6950         (wrss<mode>): Likewise.
6951         (wruss<mode>): Likewise.
6952         (setssbsy): Likewise.
6953         (clrssbsy): Likewise.
6954         (nop_endbr): Likewise.
6955         * config/i386/i386.opt: Add -mcet, -mibt, -mshstk and -mcet-switch
6956         options.
6957         * config/i386/immintrin.h: Include <cetintrin.h>.
6958         * config/i386/linux-common.h
6959         (file_end_indicate_exec_stack_and_cet): New prototype.
6960         (TARGET_ASM_FILE_END): New.
6962 2017-10-20  Jan Hubicka  <hubicka@ucw.cz>
6964         * i386.c (ix86_builtin_vectorization_cost): Use existing rtx_cost
6965         latencies instead of having separate table; make difference between
6966         integer and float costs.
6967         * i386.h (processor_costs): Remove scalar_stmt_cost,
6968         scalar_load_cost, scalar_store_cost, vec_stmt_cost, vec_to_scalar_cost,
6969         scalar_to_vec_cost, vec_align_load_cost, vec_unalign_load_cost,
6970         vec_store_cost.
6971         * x86-tune-costs.h: Remove entries which has been removed in
6972         procesor_costs from all tables; make cond_taken_branch_cost
6973         and cond_not_taken_branch_cost COST_N_INSNS based.
6975 2017-10-20  Jan Hubicka  <hubicka@ucw.cz>
6977         * x86-tune-costs.h (intel_cost, generic_cost): Fix move costs.
6979 2017-10-20  Jakub Jelinek  <jakub@redhat.com>
6981         * config/i386/i386.md (isa): Remove fma_avx512f.
6982         * config/i386/sse.md (<avx512>_fmadd_<mode>_mask<round_name>,
6983         <avx512>_fmadd_<mode>_mask3<round_name>,
6984         <avx512>_fmsub_<mode>_mask<round_name>,
6985         <avx512>_fmsub_<mode>_mask3<round_name>,
6986         <avx512>_fnmadd_<mode>_mask<round_name>,
6987         <avx512>_fnmadd_<mode>_mask3<round_name>,
6988         <avx512>_fnmsub_<mode>_mask<round_name>,
6989         <avx512>_fnmsub_<mode>_mask3<round_name>,
6990         <avx512>_fmaddsub_<mode>_mask<round_name>,
6991         <avx512>_fmaddsub_<mode>_mask3<round_name>,
6992         <avx512>_fmsubadd_<mode>_mask<round_name>,
6993         <avx512>_fmsubadd_<mode>_mask3<round_name>): Remove isa attribute.
6994         (*vec_widen_umult_even_v16si<mask_name>,
6995         *vec_widen_smult_even_v16si<mask_name>): Likewise.
6996         (<mask_codefor>avx512bw_dbpsadbw<mode><mask_name>): Likewise.
6998 2017-10-20  Igor Tsimbalist  <igor.v.tsimbalist@intel.com>
7000         * extend.texi: Add 'nocf_check' documentation.
7001         * gimple.texi: Add second parameter to
7002         gimple_build_call_from_tree.
7003         * invoke.texi: Add -fcf-protection documentation.
7004         * rtl.texi: Add REG_CALL_NOTRACK documenation.
7006 2017-10-20  Richard Biener  <rguenther@suse.de>
7008         PR tree-optimization/82473
7009         * tree-vect-loop.c (vectorizable_reduction): Properly get at
7010         the largest input type.
7012 2017-10-20  Igor Tsimbalist  <igor.v.tsimbalist@intel.com>
7014         * c-attribs.c (handle_nocf_check_attribute): New function.
7015         (c_common_attribute_table): Add 'nocf_check' handling.
7016         * gimple-parser.c: Add second argument NULL to
7017         gimple_build_call_from_tree.
7018         * attrib.c (comp_type_attributes): Check nocf_check attribute.
7019         * cfgexpand.c (expand_call_stmt): Set REG_CALL_NOCF_CHECK for
7020         call insn.
7021         * combine.c (distribute_notes): Add REG_CALL_NOCF_CHECK handling.
7022         * common.opt: Add fcf-protection flag.
7023         * emit-rtl.c (try_split): Add REG_CALL_NOCF_CHECK handling.
7024         * flag-types.h: Add enum cf_protection_level.
7025         * gimple.c (gimple_build_call_from_tree): Add second parameter.
7026         Add 'nocf_check' attribute propagation to gimple call.
7027         * gimple.h (gf_mask): Add GF_CALL_NOCF_CHECK.
7028         (gimple_build_call_from_tree): Update prototype.
7029         (gimple_call_nocf_check_p): New function.
7030         (gimple_call_set_nocf_check): Likewise.
7031         * gimplify.c: Add second argument to gimple_build_call_from_tree.
7032         * ipa-icf.c: Add nocf_check attribute in statement hash.
7033         * recog.c (peep2_attempt): Add REG_CALL_NOCF_CHECK handling.
7034         * reg-notes.def: Add REG_NOTE (CALL_NOCF_CHECK).
7035         * toplev.c (process_options): Add flag_cf_protection handling.
7037 2017-10-19  Jan Hubicka  <hubicka@ucw.cz>
7039         * x86-tune-costs.h (core_cost): Fix div, move and sqrt latencies.
7041 2017-10-20  Richard Biener  <rguenther@suse.de>
7043         PR tree-optimization/82603
7044         * tree-if-conv.c (predicate_mem_writes): Make sure to only
7045         remove false predicated stores.
7047 2017-10-20  Richard Biener  <rguenther@suse.de>
7049         * graphite-isl-ast-to-gimple.c
7050         (translate_isl_ast_to_gimple::graphite_copy_stmts_from_block):
7051         Remove return value and simplify, dump copied stmt after lhs
7052         adjustment.
7053         (translate_isl_ast_to_gimple::translate_isl_ast_node_user):
7054         Reduce dump verbosity.
7055         (gsi_insert_earliest): Likewise.
7056         (translate_isl_ast_to_gimple::copy_bb_and_scalar_dependences): Adjust.
7057         * graphite.c (print_global_statistics): Adjust dumping.
7058         (print_graphite_scop_statistics): Likewise.
7059         (print_graphite_statistics): Do not dump loops here.
7060         (graphite_transform_loops): But here.
7062 2017-10-20  Nicolas Roche  <roche@adacore.com>
7064         * configure.ac (ACX_PROG_GNAT): Append "libgnat" to include search dir.
7065         * configure: Regenerate.
7067 2017-10-20  Jakub Jelinek  <jakub@redhat.com>
7069         PR target/82158
7070         * tree-cfg.c (pass_warn_function_return::execute): In noreturn
7071         functions when optimizing replace GIMPLE_RETURN stmts with
7072         calls to __builtin_unreachable ().
7074         PR sanitizer/82595
7075         * config/gnu-user.h (LIBTSAN_EARLY_SPEC): Add libtsan_preinit.o
7076         for -fsanitize=thread link of executables.
7077         (LIBLSAN_EARLY_SPEC): Add liblsan_preinit.o for -fsanitize=leak
7078         link of executables.
7080         PR target/82370
7081         * config/i386/sse.md (VI248_AVX2, VI248_AVX512BW, VI248_AVX512BW_2):
7082         New mode iterators.
7083         (<shift_insn><mode>3<mask_name>): Change the last of the 3
7084         define_insns for logical vector shifts to use VI248_AVX512BW
7085         iterator instead of VI48_AVX512, remove <mask_mode512bit_condition>
7086         condition, useless isa and prefix attributes.  Change the first
7087         2 of these define_insns to ...
7088         (<mask_codefor><shift_insn><mode>3<mask_name>): ... this, new
7089         define_insn for avx512vl.
7090         (<shift_insn><mode>3): ... and this, new define_insn without
7091         masking for non-avx512vl.
7093         PR target/82370
7094         * config/i386/sse.md (*andnot<mode>3,
7095         <mask_codefor><code><mode>3<mask_name>, *<code><mode>3): Split
7096         (=v,v,vm) alternative into (=x,x,xm) and (=v,v,vm), for 128-bit
7097         and 256-bit vectors, the (=x,x,xm) alternative and when mask is
7098         not applied use empty suffix even for TARGET_AVX512VL.
7099         * config/i386/subst.md (mask_prefix3, mask_prefix4): When mask
7100         is applied, supply evex,evex or evex,evex,evex instead of just
7101         evex.
7103 2017-10-20  Julia Koval  <julia.koval@intel.com>
7105         * common/config/i386/i386-common.c (OPTION_MASK_ISA_GFNI_SET,
7106         (OPTION_MASK_ISA_GFNI_UNSET): New.
7107         (ix86_handle_option): Handle OPT_mgfni.
7108         * config/i386/cpuid.h (bit_GFNI): New.
7109         * config/i386/driver-i386.c (host_detect_local_cpu): Detect gfni.
7110         * config/i386/i386-c.c (ix86_target_macros_internal): Define __GFNI__.
7111         * config/i386/i386.c (ix86_target_string): Add -mgfni.
7112         (ix86_valid_target_attribute_inner_p): Add OPT_mgfni.
7113         * config/i386/i386.h (TARGET_GFNI, TARGET_GFNI_P): New.
7114         * config/i386/i386.opt: Add mgfni.
7116 2017-10-20  Orlando Arias  <oarias@knights.ucf.edu>
7118         * config/msp430/msp430.c (msp430_option_override): Disable
7119         -fdelete-null-pointer-checks.
7120         * doc/invoke.text (-fdelete-null-pointer-checks): Document that.
7122 2017-10-19  Jan Hubicka  <hubicka@ucw.cz>
7124         * x86-tune-costs.h (generic_cost, core_cost): Correct costs
7125         of x87 and SSE instructions.
7127 2017-10-19  Jan Hubicka  <hubicka@ucw.cz>
7129         * asan.c (create_cond_insert_point): Do not update edge count.
7130         * auto-profile.c (afdo_propagate_edge): Update for edge count removal.
7131         (afdo_propagate_circuit): Likewise.
7132         (afdo_calculate_branch_prob): Likewise.
7133         (afdo_annotate_cfg): Likewise.
7134         * basic-block.h (struct edge_def): Remove count.
7135         (edge_def::count): New accessor.
7136         * bb-reorder.c (rotate_loop): Update.
7137         (find_traces_1_round): Update.
7138         (connect_traces): Update.
7139         (sanitize_hot_paths): Update.
7140         * cfg.c (unchecked_make_edge): Update.
7141         (make_single_succ_edge): Update.
7142         (check_bb_profile): Update.
7143         (dump_edge_info): Update.
7144         (update_bb_profile_for_threading): Update.
7145         (scale_bbs_frequencies_int): Update.
7146         (scale_bbs_frequencies_gcov_type): Update.
7147         (scale_bbs_frequencies_profile_count): Update.
7148         (scale_bbs_frequencies): Update.
7149         * cfganal.c (connect_infinite_loops_to_exit): Update.
7150         * cfgbuild.c (compute_outgoing_frequencies): Update.
7151         (find_many_sub_basic_blocks): Update.
7152         * cfgcleanup.c (try_forward_edges): Update.
7153         (try_crossjump_to_edge): Update
7154         * cfgexpand.c (expand_gimple_cond): Update
7155         (expand_gimple_tailcall): Update
7156         (construct_exit_block): Update
7157         * cfghooks.c (verify_flow_info): Update
7158         (redirect_edge_succ_nodup): Update
7159         (split_edge): Update
7160         (make_forwarder_block): Update
7161         (duplicate_block): Update
7162         (account_profile_record): Update
7163         * cfgloop.c (find_subloop_latch_edge_by_profile): Update.
7164         * cfgloopanal.c (expected_loop_iterations_unbounded): Update.
7165         * cfgloopmanip.c (scale_loop_profile): Update.
7166         (loopify): Update.
7167         (lv_adjust_loop_entry_edge): Update.
7168         * cfgrtl.c (try_redirect_by_replacing_jump): Update.
7169         (force_nonfallthru_and_redirect): Update.
7170         (purge_dead_edges): Update.
7171         (rtl_flow_call_edges_add): Update.
7172         * cgraphunit.c (init_lowered_empty_function): Update.
7173         (cgraph_node::expand_thunk): Update.
7174         * gimple-pretty-print.c (dump_probability): Update.
7175         (dump_edge_probability): Update.
7176         * gimple-ssa-isolate-paths.c (isolate_path): Update.
7177         * haifa-sched.c (sched_create_recovery_edges): Update.
7178         * hsa-gen.c (convert_switch_statements): Update.
7179         * ifcvt.c (dead_or_predicable): Update.
7180         * ipa-inline-transform.c (inline_transform): Update.
7181         * ipa-split.c (split_function): Update.
7182         * ipa-utils.c (ipa_merge_profiles): Update.
7183         * loop-doloop.c (add_test): Update.
7184         * loop-unroll.c (unroll_loop_runtime_iterations): Update.
7185         * lto-streamer-in.c (input_cfg): Update.
7186         (input_function): Update.
7187         * lto-streamer-out.c (output_cfg): Update.
7188         * modulo-sched.c (sms_schedule): Update.
7189         * postreload-gcse.c (eliminate_partially_redundant_load): Update.
7190         * predict.c (maybe_hot_edge_p): Update.
7191         (unlikely_executed_edge_p): Update.
7192         (probably_never_executed_edge_p): Update.
7193         (dump_prediction): Update.
7194         (drop_profile): Update.
7195         (propagate_unlikely_bbs_forward): Update.
7196         (determine_unlikely_bbs): Update.
7197         (force_edge_cold): Update.
7198         * profile.c (compute_branch_probabilities): Update.
7199         * reg-stack.c (better_edge): Update.
7200         * shrink-wrap.c (handle_simple_exit): Update.
7201         * tracer.c (better_p): Update.
7202         * trans-mem.c (expand_transaction): Update.
7203         (split_bb_make_tm_edge): Update.
7204         * tree-call-cdce.c: Update.
7205         * tree-cfg.c (gimple_find_sub_bbs): Update.
7206         (gimple_split_edge): Update.
7207         (gimple_duplicate_sese_region): Update.
7208         (gimple_duplicate_sese_tail): Update.
7209         (gimple_flow_call_edges_add): Update.
7210         (insert_cond_bb): Update.
7211         (execute_fixup_cfg): Update.
7212         * tree-cfgcleanup.c (cleanup_control_expr_graph): Update.
7213         * tree-complex.c (expand_complex_div_wide): Update.
7214         * tree-eh.c (lower_resx): Update.
7215         (unsplit_eh): Update.
7216         (cleanup_empty_eh_move_lp): Update.
7217         * tree-inline.c (copy_edges_for_bb): Update.
7218         (freqs_to_counts): Update.
7219         (copy_cfg_body): Update.
7220         * tree-ssa-dce.c (remove_dead_stmt): Update.
7221         * tree-ssa-ifcombine.c (update_profile_after_ifcombine): Update.
7222         * tree-ssa-loop-im.c (execute_sm_if_changed): Update.
7223         * tree-ssa-loop-ivcanon.c (remove_exits_and_undefined_stmts): Update.
7224         (unloop_loops): Update.
7225         * tree-ssa-loop-manip.c (tree_transform_and_unroll_loop): Update.
7226         * tree-ssa-loop-split.c (connect_loops): Update.
7227         (split_loop): Update.
7228         * tree-ssa-loop-unswitch.c (hoist_guard): Update.
7229         * tree-ssa-phionlycprop.c (propagate_rhs_into_lhs): Update.
7230         * tree-ssa-phiopt.c (replace_phi_edge_with_variable): Update.
7231         * tree-ssa-reassoc.c (branch_fixup): Update.
7232         * tree-ssa-tail-merge.c (replace_block_by): Update.
7233         * tree-ssa-threadupdate.c (remove_ctrl_stmt_and_useless_edges): Update.
7234         (compute_path_counts): Update.
7235         (update_profile): Update.
7236         (recompute_probabilities): Update.
7237         (update_joiner_offpath_counts): Update.
7238         (estimated_freqs_path): Update.
7239         (freqs_to_counts_path): Update.
7240         (clear_counts_path): Update.
7241         (ssa_fix_duplicate_block_edges): Update.
7242         (duplicate_thread_path): Update.
7243         * tree-switch-conversion.c (hoist_edge_and_branch_if_true): Update.
7244         (case_bit_test_cmp): Update.
7245         (collect_switch_conv_info): Update.
7246         (gen_inbound_check): Update.
7247         (do_jump_if_equal): Update.
7248         (emit_cmp_and_jump_insns): Update.
7249         * tree-tailcall.c (decrease_profile): Update.
7250         (eliminate_tail_call): Update.
7251         * tree-vect-loop-manip.c (slpeel_add_loop_guard): Update.
7252         (vect_do_peeling): Update.
7253         * tree-vect-loop.c (scale_profile_for_vect_loop): Update.
7254         * ubsan.c (ubsan_expand_null_ifn): Update.
7255         (ubsan_expand_ptr_ifn): Update.
7256         * value-prof.c (gimple_divmod_fixed_value): Update.
7257         (gimple_mod_pow2): Update.
7258         (gimple_mod_subtract): Update.
7259         (gimple_ic): Update.
7260         (gimple_stringop_fixed_value): Update.
7262 2017-10-19  Uros Bizjak  <ubizjak@gmail.com>
7264         PR target/82618
7265         * config/i386/i386.md (sub to cmp): New peephole2 pattern.
7267 2017-10-19  Alexander Monakov  <amonakov@ispras.ru>
7269         PR rtl-optimization/82395
7270         * ira-color.c (allocno_priority_compare_func): Fix comparison step
7271         based on non_spilled_static_chain_regno_p.
7273 2017-10-19  Uros Bizjak  <ubizjak@gmail.com>
7275         * config/i386/i386.c (output_387_binary_op): Rewrite SSE part.
7276         (ix86_emit_mode_set): Rewrite insn mnemonic construction.
7277         (ix86_prepare_fp_compare_args): Redefine is_sse as bool.
7279 2017-10-19  Martin Sebor  <msebor@redhat.com>
7281         PR tree-optimization/82596
7282         * tree.c (array_at_struct_end_p): Handle STRING_CST.
7284 2017-10-19  Eric Botcazou  <ebotcazou@adacore.com>
7286         * asan.c (handle_builtin_alloca): Deal with all alloca variants.
7287         (get_mem_refs_of_builtin_call): Likewise.
7288         * builtins.c (expand_builtin_apply): Adjust call to
7289         allocate_dynamic_stack_space.
7290         (expand_builtin_alloca): For __builtin_alloca_with_align_and_max, pass
7291         the third argument to allocate_dynamic_stack_space, otherwise -1.
7292         (expand_builtin): Deal with all alloca variants.
7293         (is_inexpensive_builtin): Likewise.
7294         * builtins.def (BUILT_IN_ALLOCA_WITH_ALIGN_AND_MAX): New.
7295         * calls.c (special_function_p): Deal with all alloca variants.
7296         (initialize_argument_information): Adjust call to
7297         allocate_dynamic_stack_space.
7298         (expand_call): Likewise.
7299         * cfgexpand.c (expand_call_stmt): Deal with all alloca variants.
7300         * doc/extend.texi (Built-ins): Add __builtin_alloca_with_align_and_max
7301         * explow.c (allocate_dynamic_stack_space): Add MAX_SIZE parameter and
7302         use it for the stack usage computation.
7303         * explow.h (allocate_dynamic_stack_space): Adjust prototype.
7304         * function.c (gimplify_parameters): Call build_alloca_call_expr.
7305         * gimple-ssa-warn-alloca.c (alloca_call_type): Simplify control flow.
7306         Take into account 3rd argument of __builtin_alloca_with_align_and_max.
7307         (in_loop_p): Remove first argument and useless check.
7308         (pass_walloca::execute): Remove useless test and adjust call to above.
7309         * gimple.c (gimple_build_call_from_tree): Deal with all alloc variants
7310         * gimplify.c (gimplify_vla_decl): Call build_alloca_call_expr.
7311         (gimplify_call_expr): Deal with all alloca variants.
7312         * hsa-gen.c (gen_hsa_alloca): Likewise.
7313         (gen_hsa_insns_for_call): Likewise.
7314         * ipa-pure-const.c (special_builtin_state): Likewise.
7315         * tree-chkp.c (chkp_build_returned_bound): Likewise.
7316         * tree-object-size.c (alloc_object_size): Likewise.
7317         * tree-ssa-alias.c (ref_maybe_used_by_call_p_1): Likewise.
7318         (call_may_clobber_ref_p_1): Likewise.
7319         * tree-ssa-ccp.c (evaluate_stmt): Likewise.
7320         (ccp_fold_stmt): Likewise.
7321         (optimize_stack_restore): Likewise.
7322         * tree-ssa-dce.c (mark_stmt_if_obviously_necessary): Likewise.
7323         (mark_all_reaching_defs_necessary_1): Likewise.
7324         (propagate_necessity): Likewise.
7325         (eliminate_unnecessary_stmts): Likewise.
7326         * tree.c (build_common_builtin_nodes): Build
7327         BUILT_IN_ALLOCA_WITH_ALIGN_AND_MAX.
7328         (build_alloca_call_expr): New function.
7329         * tree.h (ALLOCA_FUNCTION_CODE_P): New macro.
7330         (CASE_BUILT_IN_ALLOCA): Likewise.
7331         (build_alloca_call_expr): Declare.
7332         * varasm.c (incorporeal_function_p): Deal with all alloca variants.
7334 2017-10-19  Eric Botcazou  <ebotcazou@adacore.com>
7336         PR debug/82509
7337         * dwarf2out.c (new_die_raw): New static inline function.
7338         (new_die): Use it to create the DIE.
7339         (add_AT_external_die_ref): Likewise.
7340         (clone_die): Likewise.
7341         (clone_as_declaration): Likewise.
7342         (dwarf2out_vms_debug_main_pointer): Likewise.
7343         (base_type_die): Likewise.  Remove early return for corner cases.
7344         Do not call add_pubtype on the DIE here.
7345         (is_base_type): Remove ERROR_MARK and return 0 for VOID_TYPE.
7346         (modified_type_die): Adjust the lookup for reverse order DIEs.  Skip
7347         typedefs for base types with DW_AT_endianity.  Make sure a DIE with
7348         native order exists for base types, attach the DIE manually and call
7349         add_pubtype on it.  Do not equate a reverse order DIE to the type.
7351 2017-10-19  Richard Earnshaw  <rearnsha@arm.com>
7353         * config/arm/arm.c (align_ok_ldrd_strd): New function.
7354         (mem_ok_for_ldrd_strd): New parameter align.  Extract the alignment of
7355         the mem into it.
7356         (gen_operands_ldrd_strd): Validate the alignment of the accesses.
7358 2017-10-19  Jakub Jelinek  <jakub@redhat.com>
7360         * flag-types.h (enum sanitize_code): Add SANITIZE_BUILTIN.  Or
7361         SANITIZE_BUILTIN into SANITIZE_UNDEFINED.
7362         * sanitizer.def (BUILT_IN_UBSAN_HANDLE_INVALID_BUILTIN,
7363         BUILT_IN_UBSAN_HANDLE_INVALID_BUILTIN_ABORT): New builtins.
7364         * opts.c (sanitizer_opts): Add builtin.
7365         * ubsan.c (instrument_builtin): New function.
7366         (pass_ubsan::execute): Call it.
7367         (pass_ubsan::gate): Enable even for SANITIZE_BUILTIN.
7368         * doc/invoke.texi: Document -fsanitize=builtin.
7370         * ubsan.c (ubsan_expand_null_ifn): Use _v1 suffixed type mismatch
7371         builtins, store max (log2 (align), 0) into uchar field instead of
7372         align into uptr field.
7373         (ubsan_expand_objsize_ifn): Use _v1 suffixed type mismatch builtins,
7374         store uchar 0 field instead of uptr 0 field.
7375         (instrument_nonnull_return): Use _v1 suffixed nonnull return builtin,
7376         instead of passing one address of struct with 2 locations pass
7377         two addresses of structs with 1 location each.
7378         * sanitizer.def (BUILT_IN_UBSAN_HANDLE_TYPE_MISMATCH,
7379         BUILT_IN_UBSAN_HANDLE_TYPE_MISMATCH_ABORT,
7380         BUILT_IN_UBSAN_HANDLE_NONNULL_RETURN,
7381         BUILT_IN_UBSAN_HANDLE_NONNULL_RETURN_ABORT): Removed.
7382         (BUILT_IN_UBSAN_HANDLE_TYPE_MISMATCH_V1,
7383         BUILT_IN_UBSAN_HANDLE_TYPE_MISMATCH_V1_ABORT,
7384         BUILT_IN_UBSAN_HANDLE_NONNULL_RETURN_V1,
7385         BUILT_IN_UBSAN_HANDLE_NONNULL_RETURN_V1_ABORT): New builtins.
7387 2017-10-19  Martin Liska  <mliska@suse.cz>
7389         PR driver/81829
7390         * file-find.c (remove_prefix): Remove.
7391         * file-find.h (remove_prefix): Likewise.
7392         * gcc-ar.c: Remove smartness of lookup.
7394 2017-10-19  Segher Boessenkool  <segher@kernel.crashing.org>
7396         * config/rs6000/rs6000.md (*call_indirect_aix<mode>,
7397         *call_value_indirect_aix<mode>, *call_indirect_elfv2<mode>,
7398         *call_value_indirect_elfv2<mode>): Add correct mode to the unspec.
7400 2017-10-19  Jakub Jelinek  <jakub@redhat.com>
7402         PR target/82580
7403         * config/i386/i386.md (setcc + movzbl to xor + setcc): New peephole2.
7404         (setcc + and to xor + setcc): New peephole2.
7406 2017-10-19  Tom de Vries  <tom@codesourcery.com>
7408         * doc/sourcebuild.texi (Test Directives, Variants of
7409         dg-require-support): Add dg-require-stack-size.
7411 2017-10-19  Martin Liska  <mliska@suse.cz>
7413         PR sanitizer/82517
7414         * gimplify.c (gimplify_decl_expr): Do not instrument variables
7415         that have a large alignment.
7416         (gimplify_target_expr): Likewise.
7418 2017-10-18  Segher Boessenkool  <segher@kernel.crashing.org>
7420         PR rtl-optimization/82602
7421         * ira.c (rtx_moveable_p): Return false for volatile asm.
7423 2017-10-18  Uros Bizjak  <ubizjak@gmail.com>
7425         PR target/82580
7426         * config/i386/i386-modes.def (CCGZ): New CC mode.
7427         * config/i386/i386.md (sub<mode>3_carry_ccgz): New insn pattern.
7428         * config/i386/predicates.md (ix86_comparison_operator):
7429         Handle CCGZmode.
7430         * config/i386/i386.c (ix86_expand_branch) <case E_TImode>:
7431         Emulate LE, LEU, GT, GTU, LT, LTU, GE and GEU double-word comparisons
7432         with double-word subtraction.
7433         (put_condition_code): Handle CCGZmode.
7435 2017-10-18  Aldy Hernandez  <aldyh@redhat.com>
7437         * wide-int.cc (debug (const wide_int &)): New.
7438         (debug (const wide_int *)): New.
7439         (debug (const widest_int &)): New.
7440         (debug (const widest_int *)): New.
7442 2017-10-18  Vladimir Makarov  <vmakarov@redhat.com>
7444         PR middle-end/82556
7445         * lra-constraints.c (curr_insn_transform): Use non-input operand
7446         instead of output one for matched reload.
7448 2017-10-18  Bin Cheng  <bin.cheng@arm.com>
7450         * tree-loop-distribution.c (INCLUDE_ALGORITHM): New header file.
7451         (tree-ssa-loop-ivopts.h): New header file.
7452         (struct builtin_info): New fields.
7453         (classify_builtin_1): Compute and record base and offset parts for
7454         memset builtin partition by calling strip_offset.
7455         (offset_cmp, fuse_memset_builtins): New functions.
7456         (finalize_partitions): Fuse adjacent memset partitions by calling
7457         above function.
7458         * tree-ssa-loop-ivopts.c (strip_offset): Delete static declaration.
7459         Expose the interface.
7460         * tree-ssa-loop-ivopts.h (strip_offset): New declaration.
7462 2017-10-18  Bin Cheng  <bin.cheng@arm.com>
7464         PR tree-optimization/82574
7465         * tree-loop-distribution.c (find_single_drs): New parameter.  Check
7466         that data reference must be executed exactly once per iteration
7467         against the outermost loop in nest.
7468         (classify_partition): Update call to above function.
7470 2017-10-18  Richard Biener  <rguenther@suse.de>
7472         PR tree-optimization/82591
7473         * graphite.c (graphite_transform_loops): Move code gen message
7474         printing ...
7475         * graphite-isl-ast-to-gimple.c (graphite_regenerate_ast_isl):
7476         Here.  Handle scop_to_isl_ast failing.
7477         (scop_to_isl_ast): Limit the number of ISL operations.
7479 2017-10-18  Richard Biener  <rguenther@suse.de>
7481         * graphite-isl-ast-to-gimple.c
7482         (translate_isl_ast_to_gimple::set_rename): Simplify.
7483         (translate_isl_ast_to_gimple::set_rename_for_each_def): Inline...
7484         (graphite_copy_stmts_from_block): ... here.
7485         (copy_bb_and_scalar_dependences): Simplify.
7486         (add_parameters_to_ivs_params): Canonicalize.
7487         (generate_entry_out_of_ssa_copies): Simplify.
7488         * graphite-sese-to-poly.c (extract_affine_name): Simplify
7489         by passing in ISL dimension.
7490         (parameter_index_in_region_1): Rename to ...
7491         (parameter_index_in_region): ... this.
7492         (extract_affine): Adjust assert, pass down parameter index.
7493         (add_param_constraints): Use range-info when available.
7494         (build_scop_context): Adjust.
7495         * sese.c (new_sese_info): Adjust.
7496         (free_sese_info): Likewise.
7497         * sese.h (bb_map_t, rename_map_t, phi_rename, init_back_edge_pair_t):
7498         Remove unused typedefs.
7499         (struct sese_info_t): Simplify rename_map, remove incomplete_phis.
7501 2017-10-18  Martin Liska  <mliska@suse.cz>
7503         * combine.c (simplify_compare_const): Add gcc_fallthrough.
7505 2017-10-18  Robin Dapp  <rdapp@linux.vnet.ibm.com>
7507         * config/s390/s390.c (s390_bb_fallthru_entry_likely): New function.
7508         (s390_sched_init): Do not reset s390_sched_state if we entered the
7509         current basic block via a fallthru edge and all others are unlikely.
7511 2017-10-18  Robin Dapp  <rdapp@linux.vnet.ibm.com>
7513         * config/s390/s390.c (NUM_SIDES): New variable.
7514         (LONGRUNNING_THRESHOLD): New variable.
7515         (LATENCY_FACTOR): New variable.
7516         (s390_sched_score): Decrease score for long-running instructions on
7517         wrong side.
7518         (s390_sched_variable_issue): Perform bookkeeping for long-running
7519         instructions.
7521 2017-10-18  Richard Biener  <rguenther@suse.de>
7523         * graphite-isl-ast-to-gimple.c (gcc_expression_from_isl_ast_expr_id):
7524         Simplify with removal of the parameter rename map.
7525         (set_rename): Likewise.
7526         (should_copy_to_new_region): Likewise.
7527         (graphite_copy_stmts_from_block): Likewise.
7528         (copy_bb_and_scalar_dependences): Remove initialization of
7529         unused copied_bb_map.
7530         (copy_def): Remove.
7531         (copy_internal_parameters): Likewise.
7532         (graphite_regenerate_ast_isl): Do not call copy_internal_parameters.
7533         * graphite-scop-detection.c (scop_detection::stmt_simple_for_scop_p):
7534         Use INTEGRAL_TYPE_P.
7535         (parameter_index_in_region_1): Rename to ...
7536         (assign_parameter_index_in_region): ... this.  Assert we have
7537         a parameter we handle.
7538         (scan_tree_for_params): Adjust.
7539         * sese.h (parameter_rename_map_t): Remove.
7540         (struct sese_info_t): Remove unused parameter_rename_map and
7541         copied_bb_map members.
7542         * sese.c (new_sese_info): Adjust.
7543         (free_sese_info): Likewise.
7545 2017-10-18  Martin Liska  <mliska@suse.cz>
7547         PR sanitizer/82545
7548         * asan.c (asan_expand_poison_ifn): Do not put gimple stmt
7549         on an abnormal edge.
7551 2017-10-18  Sebastian Huber  <sebastian.huber@embedded-brains.de>
7553         * doc/invoke.texi (ffunction-sections and fdata-sections):
7554         Update.
7556 2017-10-17  Eric Botcazou  <ebotcazou@adacore.com>
7558         * tree-ssa-loop-ivopts.c (add_autoinc_candidates): Bail out only if
7559         the use statement can throw internally.
7561 2017-10-17  Eric Botcazou  <ebotcazou@adacore.com>
7563         * config/visium/visium.c (visium_select_cc_mode): Return CCmode for
7564         any RTX present on the RHS of a SET.
7565         * compare-elim.c (try_eliminate_compare): Restore comment.
7567 2017-10-17  Jakub Jelinek  <jakub@redhat.com>
7569         * langhooks.h (struct lang_hooks): Document that tree_size langhook
7570         may be also called on tcc_type nodes.
7571         * langhooks.c (lhd_tree_size): Likewise.
7573 2017-10-17  David Malcolm  <dmalcolm@redhat.com>
7575         * gimple-ssa-sprintf.c (fmtwarn): Update for changed signature of
7576         format_warning_at_substring.
7577         (maybe_warn): Convert source_range * param to a location_t.  Pass
7578         UNKNOWN_LOCATION rather than NULL to fmtwarn.
7579         (format_directive): Remove code to extract source_ranges and
7580         source_range * in favor of just a location_t.
7581         (parse_directive): Pass UNKNOWN_LOCATION rather than NULL to
7582         fmtwarn.
7583         * substring-locations.c (format_warning_va): Convert
7584         source_range * param to a location_t.
7585         (format_warning_at_substring): Likewise.
7586         * substring-locations.h (format_warning_va): Likewise.
7587         (format_warning_at_substring): Likewise.
7589 2017-10-17  Jan Hubicka  <hubicka@ucw.cz>
7591         * target.h (enum vect_cost_for_stmt): Add vec_gather_load and
7592         vec_scatter_store
7593         * tree-vect-stmts.c (record_stmt_cost): Make difference between normal
7594         and scatter/gather ops.
7596         * aarch64/aarch64.c (aarch64_builtin_vectorization_cost): Add
7597         vec_gather_load and vec_scatter_store.
7598         * arm/arm.c (arm_builtin_vectorization_cost): Likewise.
7599         * powerpcspe/powerpcspe.c (rs6000_builtin_vectorization_cost): Likewise.
7600         * rs6000/rs6000.c (rs6000_builtin_vectorization_cost): Likewise.
7601         * s390/s390.c (s390_builtin_vectorization_cost): Likewise.
7602         * spu/spu.c (spu_builtin_vectorization_cost): Likewise.
7603         * i386/i386.c (x86_builtin_vectorization_cost): Likewise.
7605 2017-10-17  Uros Bizjak  <ubizjak@gmail.com>
7607         * reg-stack.c (compare_for_stack_reg): Add bool argument.
7608         Detect FTST instruction and handle its register pops.  Only pop
7609         second operand if can_pop_second_op is true.
7610         (subst_stack_regs_pat) <case COMPARE>: Detect FCOMI instruction to
7611         set can_pop_second_op to false in the compare_for_stack_reg call.
7613         * config/i386/i386.md (*cmpi<FPCMP:unord><MODEF:mode>): Only call
7614         output_fp_compare for stack register operands.
7615         * config/i386/i386.c (output_fp_compare): Do not output SSE compare
7616         instructions here.  Do not emit stack register pops here.  Assert
7617         that FCOMPP pops next to top stack register.  Rewrite function.
7619 2017-10-17  Nathan Sidwell  <nathan@acm.org>
7621         PR middle-end/82577
7622         * alias.c (compare_base_decls): Check HAS_DECL_ASSEMBLER_NAME_P,
7623         use DECL_ASSEMBLER_NAME_RAW.
7625         PR middle-end/82546
7626         * tree.c (tree_code_size): Reformat.  Punt to lang hook for unknown
7627         TYPE nodes.
7629 2017-10-17  Qing Zhao <qing.zhao@oracle.com>
7630             Wilco Dijkstra <wilco.dijkstra@arm.com>
7632         * builtins.c (expand_builtin_update_setjmp_buf): Add a
7633         converstion to Pmode from the buf_addr.
7635 2017-10-17  Richard Biener  <rguenther@suse.de>
7637         * graphite-dependences.c (scop_get_reads_and_writes): Change
7638         output parameters to references.
7640 2017-10-17  Jackson Woodruff  <jackson.woodruff@arm.com>
7642         PR 71026/tree-optimization
7643         * fold-const.c (distribute_real_division): Removed.
7644         (fold_binary_loc): Remove calls to distribute_real_divison.
7646 2017-10-17  Richard Biener  <rguenther@suse.de>
7648         * graphite-scop-detection.c
7649         (scop_detection::stmt_has_simple_data_refs_p): Always use
7650         the full nest as region.
7651         (try_generate_gimple_bb): Likewise.
7652         * sese.c (scalar_evolution_in_region): Simplify now that
7653         SCEV can handle instantiation in regions.
7654         * tree-scalar-evolution.c (instantiate_scev_name): Also instantiate
7655         in the non-loop part of a function if requested.
7657 2017-10-17  Richard Biener  <rguenther@suse.de>
7659         PR tree-optimization/82563
7660         * graphite-isl-ast-to-gimple.c (generate_entry_out_of_ssa_copies):
7661         New function.
7662         (graphite_regenerate_ast_isl): Call it.
7663         * graphite-scop-detection.c (build_scops): Remove entry edge split.
7665 2017-10-17  Jakub Jelinek  <jakub@redhat.com>
7667         PR tree-optimization/82549
7668         * fold-const.c (optimize_bit_field_compare, fold_truth_andor_1):
7669         Formatting fixes.  Instead of calling make_bit_field_ref with negative
7670         bitpos return 0.
7672 2017-10-17  Olga Makhotina  <olga.makhotina@intel.com>
7674         * config/i386/avx512dqintrin.h (_mm_mask_reduce_sd,
7675         _mm_maskz_reduce_sd, _mm_mask_reduce_ss,=20
7676         _mm_maskz_reduce_ss): New.
7677         * config/i386/i386-builtin.def (__builtin_ia32_reducesd_mask,
7678         __builtin_ia32_reducess_mask): Ditto..
7679         (__builtin_ia32_reducesd, __builtin_ia32_reducess): Remove.
7680         * config/i386/sse.md (reduces<mode>): Renamed to ...
7681         (reduces<mode><mask_scalar_name>): ... this.
7682         (vreduce<ssescalarmodesuffix>\t{%3, %2, %1, %0|%0, %1, %2, %3}):
7683         Changed to ...
7684         (vreduce<ssescalarmodesuffix>\t{%3, %2, %1, %0<mask_scalar_operand4>|
7685         %0<mask_scalar_operand4>, %1, %2, %3}): ... this.
7687 2017-10-16  David Malcolm  <dmalcolm@redhat.com>
7689         * Makefile.in (OBJS): Add unique-ptr-tests.o.
7690         * selftest-run-tests.c (selftest::run_tests): Call
7691         selftest::unique_ptr_tests_cc_tests.
7692         * selftest.h (selftest::unique_ptr_tests_cc_tests): New decl.
7693         * unique-ptr-tests.cc: New file.
7695 2017-10-16  Vladimir Makarov  <vmakarov@redhat.com>
7697         PR sanitizer/82353
7698         * lra.c (collect_non_operand_hard_regs): Don't ignore operator
7699         locations.
7700         * lra-lives.c (bb_killed_pseudos, bb_gen_pseudos): Move up.
7701         (make_hard_regno_born, make_hard_regno_dead): Update
7702         bb_killed_pseudos and bb_gen_pseudos for fixed regs.
7704 2017-10-16  Jeff Law  <law@redhat.com>
7706         * tree-ssa-dse.c (live_bytes_read): Fix thinko.
7708 2017-10-16  Jan Hubicka  <hubicka@ucw.cz>
7710         * x86-tune-costs.h (znver1_cost): Fix move cost tables.
7712 2017-10-16  Olivier Hainque  <hainque@adacore.com>
7714         * gcc/config.gcc (powerpc*-*-*spe*): Pick 8548 as the default
7715         with_cpu if we were configured for an e500v2 target cpu name.
7717 2017-10-16  Thomas Preud'homme  <thomas.preudhomme@arm.com>
7719         * config/arm/arm-cpus.in (cortex-m33): Add nodsp option.
7720         * doc/invoke.texi: Document +nodsp as a valid extension for
7721         -mcpu=cortex-m33.
7723 2017-10-16  Martin Liska  <mliska@suse.cz>
7725         * sbitmap.c (bitmap_bit_in_range_p_checking): New function.
7726         (test_set_range): Likewise.
7727         (test_range_functions): Rename to ...
7728         (test_bit_in_range): ... this.
7729         (sbitmap_c_tests): Add new test.
7731 2017-10-16  Tamar Christina  <tamar.christina@arm.com>
7733         * config/aarch64/arm_neon.h (vdot_u32, vdotq_u32, vdot_s32, vdotq_s32):
7734         New.
7735         (vdot_lane_u32, vdot_laneq_u32, vdotq_lane_u32, vdotq_laneq_u32): New.
7736         (vdot_lane_s32, vdot_laneq_s32, vdotq_lane_s32, vdotq_laneq_s32): New.
7738 2017-10-16  Tamar Christina  <tamar.christina@arm.com>
7740         * config/aarch64/aarch64-builtins.c
7741         (aarch64_types_quadopu_lane_qualifiers): New.
7742         (TYPES_QUADOPU_LANE): New.
7743         * config/aarch64/aarch64-simd.md (aarch64_<sur>dot<vsi2qi>): New.
7744         (<sur>dot_prod<vsi2qi>, aarch64_<sur>dot_lane<vsi2qi>): New.
7745         (aarch64_<sur>dot_laneq<vsi2qi>): New.
7746         * config/aarch64/aarch64-simd-builtins.def (sdot, udot): New.
7747         (sdot_lane, udot_lane, sdot_laneq, udot_laneq): New.
7748         * config/aarch64/iterators.md (sur): Add UNSPEC_SDOT, UNSPEC_UDOT.
7749         (Vdottype, DOTPROD): New.
7750         (sur): Add SDOT and UDOT.
7752 2017-10-16  Tamar Christina  <tamar.christina@arm.com>
7754         * config/aarch64/aarch64.h (AARCH64_FL_DOTPROD): New.
7755         (AARCH64_ISA_DOTPROD, TARGET_DOTPROD): New.
7756         * config/aarch64/aarch64-c.c (aarch64_update_cpp_builtins):
7757         Add TARGET_DOTPROD.
7758         * config/aarch64/aarch64-option-extensions.def (dotprod): New.
7759         * config/aarch64/aarch64-cores.def (cortex-a55, cortex-a75):
7760         Enable TARGET_DOTPROD.
7761         (cortex-a75.cortex-a55): Likewise.
7762         * doc/invoke.texi (aarch64-feature-modifiers): Document dotprod.
7764 2017-10-16  Tamar Christina  <tamar.christina@arm.com>
7766         * config/arm/arm-builtins.c (arm_unsigned_uternop_qualifiers): New.
7767         (UTERNOP_QUALIFIERS, arm_umac_lane_qualifiers, UMAC_LANE_QUALIFIERS):
7768         New.
7769         * config/arm/arm_neon_builtins.def (sdot, udot, sdot_lane, udot_lane):
7770         New.
7771         * config/arm/iterators.md (DOTPROD, VSI2QI, vsi2qi): New.
7772         (UNSPEC_DOT_S, UNSPEC_DOT_U, opsuffix): New.
7773         * config/arm/neon.md (neon_<sup>dot<vsi2qi>): New.
7774         (neon_<sup>dot_lane<vsi2qi>, <sup>dot_prod<vsi2qi>): New.
7775         * config/arm/types.md (neon_dot, neon_dot_q): New.
7776         * config/arm/unspecs.md (sup): Add UNSPEC_DOT_S, UNSPEC_DOT_U.
7778 2017-10-16  Tamar Christina  <tamar.christina@arm.com>
7780         * config/arm/arm.h (TARGET_DOTPROD): New.
7781         * config/arm/arm.c (arm_arch_dotprod): New.
7782         (arm_option_reconfigure_globals): Add arm_arch_dotprod.
7783         * config/arm/arm-c.c (__ARM_FEATURE_DOTPROD): New.
7784         * config/arm/arm-cpus.in (armv8.2-a): Enabled +dotprod.
7785         (feature dotprod, group dotprod, ALL_SIMD_INTERNAL): New.
7786         (ALL_FPU_INTERNAL): Use ALL_SIMD_INTERNAL.
7787         * config/arm/t-multilib (v8_2_a_simd_variants): Add dotprod.
7788         * doc/invoke.texi (armv8.2-a): Document dotprod
7790 2017-10-14  Jan Hubicka  <hubicka@ucw.cz>
7792         * i386.c (ix86_vec_cost): New function.
7793         (ix86_rtx_costs): Handle vector operations better.
7794         * i386.h (struct processor_costs): Add sse_op, fmasd, fmass.
7795         * x86-tune-costs.h: Add new costs to all tables.
7797 2017-10-14  Jan Hubicka  <hubicka@ucw.cz>
7799         * i386.c (ix86_rtx_costs): Make difference between x87 and SSE
7800         operations.
7801         * i386.h (struct processor_costs): Add addss, mulss, mulsd, divss,
7802         divsd, sqrtss and sqrtsd
7803         * x86-tune-costs.h: Add new entries to all costs.
7804         (znver1_cost): Fix to match real instruction latencies.
7806 2017-10-14  Kyrylo Tkachov  <kyrylo.tkachov@arm.com>
7807             Michael Collison <michael.collison@arm.com>
7809         * compare-elim.c: Include emit-rtl.h.
7810         (can_merge_compare_into_arith): New function.
7811         (try_validate_parallel): Likewise.
7812         (try_merge_compare): Likewise.
7813         (try_eliminate_compare): Call the above when no previous clobber
7814         is available.
7815         (execute_compare_elim_after_reload): Add DF_UD_CHAIN and DF_DU_CHAIN
7816         dataflow problems.
7818 2017-10-14  Jakub Jelinek  <jakub@redhat.com>
7820         PR middle-end/62263
7821         PR middle-end/82498
7822         * tree-ssa-phiopt.c (value_replacement): Comment fix.  Handle
7823         up to 2 preparation statements for ASSIGN in MIDDLE_BB.
7825         PR middle-end/62263
7826         PR middle-end/82498
7827         * tree-ssa-forwprop.c (simplify_rotate): Allow def_arg1[N]
7828         to be any operand_equal_p operands.  For & (B - 1) require
7829         B to be power of 2.  Recognize
7830         (X << (Y & (B - 1))) | (X >> ((-Y) & (B - 1))) and similar patterns.
7832 2017-10-14  Uros Bizjak  <ubizjak@gmail.com>
7834         PR bootstrap/82553
7835         * optabs.c (expand_memory_blockage): Fix call of
7836         targetm.have_memory_blockage.
7838 2017-10-14  Jakub Jelinek  <jakub@redhat.com>
7840         PR bootstrap/82548
7841         * config.gcc (*-*-solaris2*, i[34567]86-*-cygwin*,
7842         x86_64-*-cygwin*, i[34567]86-*-mingw* | x86_64-*-mingw*): Append
7843         objects to extra_objs instead of overwriting it.
7845 2017-10-14  Uros Bizjak  <ubizjak@gmail.com>
7847         * config/i386/sync.md (FILD_ATOMIC/FIST_ATOMIC FP load peephole2):
7848         Use any_fp_register_operand as operand[3] predicate.  Simplify
7849         equality test for operands[2] and operands[4] memory location.
7850         (LDX_ATOMIC/STX_ATOMIC FP load peephole2): Ditto.
7851         (FILD_ATOMIC/FIST_ATOMIC FP load peephole2 with mem blockage): New.
7852         (LDX_ATOMIC/LDX_ATOMIC FP load peephole2 with mem blockage): Ditto.
7853         (FILD_ATOMIC/FIST_ATOMIC FP store peephole2): Use
7854         any_fp_register_operand as operand[1] predicate.  Simplify
7855         equality test for operands[0] and operands[3] memory location.
7856         (LDX_ATOMIC/STX_ATOMIC FP store peephole2): Ditto.
7857         (FILD_ATOMIC/FIST_ATOMIC FP store peephole2 with mem blockage): New.
7858         (LDX_ATOMIC/LDX_ATOMIC FP storepeephole2 with mem blockage): Ditto.
7860 2017-10-14  Uros Bizjak  <ubizjak@gmail.com>
7862         * target-insns.def: Add memory_blockage.
7863         * optabs.c (expand_memory_blockage): New function.
7864         (expand_asm_memory_barrier): Rename ...
7865         (expand_asm_memory_blockage): ... to this.
7866         (expand_mem_thread_fence): Call expand_memory_blockage
7867         instead of expand_asm_memory_barrier.
7868         (expand_mem_singnal_fence): Ditto.
7869         (expand_atomic_load): Ditto.
7870         (expand_atomic_store): Ditto.
7871         * doc/md.texi (Standard Pattern Names For Generation):
7872         Document memory_blockage instruction pattern.
7874 2017-10-13  Sebastian Perta  <sebastian.perta@renesas.com>
7876         * config/rl78/rl78.c (rl78_emit_libcall): New function.
7877         * config/rl78/rl78-protos.h (rl78_emit_libcall): New function.
7878         * config/rl78/rl78.md: New define_expand "adddi3".
7880 2017-10-13  Jan Hubicka  <hubicka@ucw.cz>
7882         * cfghooks.c (verify_flow_info): Disable check that all probabilities
7883         are set correctly.
7885 2017-10-13  Jeff Law  <law@redhat.com>
7887         * tree-ssa-reassoc.c (reassociate_bb): Clarify code slighly.
7889 2017-10-13  Jakub Jelinek  <jakub@redhat.com>
7891         PR target/82274
7892         * internal-fn.c (expand_mul_overflow): If both operands have
7893         the same highpart of -1 or 0 and the topmost bit of lowpart
7894         is different, overflow is if res <= 0 rather than res < 0.
7896 2017-10-13  Pat Haugen  <pthaugen@us.ibm.com>
7898         * config/rs6000/rs6000.c (rs6000_builtin_vectorization_cost): Remove
7899         TARGET_P9_VECTOR code for unaligned_load case.
7901 2017-10-13  Jan Hubicka  <hubicka@ucw.cz>
7903         * cfghooks.c (verify_flow_info): Check that edge probabilities are set.
7905 2017-10-13  Nathan Sidwell  <nathan@acm.org>
7907         * tree-core.h (tree_contains_struct): Make bool.
7908         * tree.c (tree_contains_struct): Likewise.
7909         * tree.h (MARK_TS_BASE): Remove do ... while (0) idiom.
7910         (MARK_TS_TYPED, MARK_TS_COMMON, MARK_TS_TYPE_COMMON,
7911         MARK_TS_TYPE_WITH_LANG_SPECIFIC, MARK_TS_DECL_MINIMAL,
7912         MARK_TS_DECL_COMMON, MARK_TS_DECL_WRTL, MARK_TS_DECL_WITH_VIS,
7913         MARK_TS_DECL_NON_COMMON): Likewise, use comma operator.
7915 2017-10-13  Richard Biener  <rguenther@suse.de>
7917         * graphite-isl-ast-to-gimple.c
7918         (translate_isl_ast_to_gimple::get_rename_from_scev): Remove unused
7919         parameters and dominance check.
7920         (translate_isl_ast_to_gimple::graphite_copy_stmts_from_block): Adjust.
7921         (translate_isl_ast_to_gimple::copy_bb_and_scalar_dependences): Likewise.
7922         (translate_isl_ast_to_gimple::graphite_regenerate_ast_isl):
7923         Do not update SSA form here or do intermediate IL verification.
7924         * graphite.c: Include tree-ssa.h and tree-into-ssa.h.
7925         (graphite_initialize): Remove check on the number of loops in
7926         the function and inline into graphite_transform_loops.
7927         (graphite_finalize): Inline into graphite_transform_loops.
7928         (graphite_transform_loops): Perform SSA update and IL verification
7929         here.
7930         * params.def (PARAM_GRAPHITE_MIN_LOOPS_PER_FUNCTION): Remove.
7932 2017-10-13  Richard Biener  <rguenther@suse.de>
7934         * graphite-isl-ast-to-gimple.c (max_mode_int_precision,
7935         graphite_expression_type_precision): Avoid global constructor
7936         by moving ...
7937         (translate_isl_ast_to_gimple::translate_isl_ast_to_gimple): Here.
7938         (translate_isl_ast_to_gimple::graphite_expr_type): Add type member.
7939         (translate_isl_ast_to_gimple::translate_isl_ast_node_for): Use it.
7940         (translate_isl_ast_to_gimple::build_iv_mapping): Likewise.
7941         (translate_isl_ast_to_gimple::graphite_create_new_guard): Likewise.
7942         * graphite-sese-to-poly.c (build_original_schedule): Return nothing.
7944 2017-10-13  H.J. Lu  <hongjiu.lu@intel.com>
7946         PR target/82499
7947         * config/i386/i386.h (ix86_red_zone_size): New.
7948         * config/i386/i386.md (push peephole2s): Replace
7949         "!ix86_using_red_zone ()" with "ix86_red_zone_size == 0".
7951 2017-10-13  Richard Sandiford  <richard.sandiford@linaro.org>
7952             Alan Hayward  <alan.hayward@arm.com>
7953             David Sherwood  <david.sherwood@arm.com>
7955         * combine.c (can_change_dest_mode): Reject changes in
7956         REGMODE_NATURAL_SIZE.
7958 2017-10-13  Richard Sandiford  <richard.sandiford@linaro.org>
7959             Alan Hayward  <alan.hayward@arm.com>
7960             David Sherwood  <david.sherwood@arm.com>
7962         * cfgexpand.c (expand_debug_expr): Use GET_MODE_UNIT_BITSIZE.
7963         (expand_debug_source_expr): Likewise.
7964         * combine.c (combine_simplify_rtx): Likewise.
7965         * cse.c (fold_rtx): Likewise.
7966         * fwprop.c (canonicalize_address): Likewise.
7967         * targhooks.c (default_shift_truncation_mask): Likewise.
7969 2017-10-13  Richard Sandiford  <richard.sandiford@linaro.org>
7970             Alan Hayward  <alan.hayward@arm.com>
7971             David Sherwood  <david.sherwood@arm.com>
7973         * optabs.c (add_equal_note): Use GET_MODE_UNIT_SIZE.
7974         (widened_mode): Likewise.
7975         (expand_unop): Likewise.
7976         * ree.c (transform_ifelse): Likewise.
7977         (merge_def_and_ext): Likewise.
7978         (combine_reaching_defs): Likewise.
7979         * simplify-rtx.c (simplify_unary_operation_1): Likewise.
7981 2017-10-13  Richard Sandiford  <richard.sandiford@linaro.org>
7982             Alan Hayward  <alan.hayward@arm.com>
7983             David Sherwood  <david.sherwood@arm.com>
7985         * caller-save.c (replace_reg_with_saved_mem): Use byte_lowpart_offset.
7986         * combine.c (gen_lowpart_for_combine): Likewise.
7987         * dwarf2out.c (rtl_for_decl_location): Likewise.
7988         * final.c (alter_subreg): Likewise.
7989         * rtlhooks.c (gen_lowpart_general): Likewise.
7990         (gen_lowpart_if_possible): Likewise.
7992 2017-10-13  Richard Sandiford  <richard.sandiford@linaro.org>
7993             Alan Hayward  <alan.hayward@arm.com>
7994             David Sherwood  <david.sherwood@arm.com>
7996         * calls.c (expand_call): Use subreg_lowpart_offset.
7997         * cse.c (cse_insn): Likewise.
7998         * regcprop.c (copy_value): Likewise.
7999         (copyprop_hardreg_forward_1): Likewise.
8001 2017-10-13  Jakub Jelinek  <jakub@redhat.com>
8003         PR target/82524
8004         * config/i386/i386.md (addqi_ext_1, andqi_ext_1,
8005         *andqi_ext_1_cc, *<code>qi_ext_1, *xorqi_ext_1_cc): Change
8006         =Q constraints to +Q and into insn condition add check
8007         that operands[0] and operands[1] are equal.
8008         (*addqi_ext_2, *andqi_ext_2, *<code>qi_ext_2): Change
8009         =Q constraints to +Q and into insn condition add check
8010         that operands[0] is equal to either operands[1] or operands[2].
8012         PR target/82498
8013         * fold-const.c (fold_binary_loc) <bit_rotate>: Code cleanups,
8014         instead of handling MINUS_EXPR twice (once for each argument),
8015         canonicalize operand order and handle just once, use rtype where
8016         possible.  Handle (A << B) | (A >> (-B & (Z - 1))).
8018         PR target/82498
8019         * config/i386/ia32intrin.h (__rold, __rord, __rolq, __rorq): Allow
8020         any values of __C while still being pattern recognizable as a simple
8021         rotate instruction.
8023 2017-10-13  Richard Biener  <rguenther@suse.de>
8025         PR tree-optimization/82451
8026         Revert
8027         2017-10-02  Richard Biener  <rguenther@suse.de>
8029         PR tree-optimization/82355
8030         * graphite-isl-ast-to-gimple.c (build_iv_mapping): Also build
8031         a mapping for the enclosing loop but avoid generating one for
8032         the loop tree root.
8033         (copy_bb_and_scalar_dependences): Remove premature codegen
8034         error on PHIs in blocks duplicated into multiple places.
8035         * graphite-scop-detection.c
8036         (scop_detection::stmt_has_simple_data_refs_p): For a loop not
8037         in the region use it as loop and nest to analyze the DR in.
8038         (try_generate_gimple_bb): Likewise.
8039         * graphite-sese-to-poly.c (extract_affine_chrec): Adjust.
8040         (add_loop_constraints): For blocks in a loop not in the region
8041         create a dimension with a single iteration.
8042         * sese.h (gbb_loop_at_index): Remove assert.
8044         * cfgloop.c (loop_preheader_edge): For the loop tree root
8045         return the single successor of the entry block.
8046         * graphite-isl-ast-to-gimple.c (graphite_regenerate_ast_isl):
8047         Reset the SCEV hashtable and niters.
8048         * graphite-scop-detection.c
8049         (scop_detection::graphite_can_represent_scev): Add SCOP parameter,
8050         assert that we only have POLYNOMIAL_CHREC that vary in loops
8051         contained in the region.
8052         (scop_detection::graphite_can_represent_expr): Adjust.
8053         (scop_detection::stmt_has_simple_data_refs_p): For loops
8054         not in the region set loop to NULL.  The nest is now the
8055         entry edge to the region.
8056         (try_generate_gimple_bb): Likewise.
8057         * sese.c (scalar_evolution_in_region): Adjust for
8058         instantiate_scev change.
8059         * tree-data-ref.h (graphite_find_data_references_in_stmt):
8060         Make nest parameter the edge into the region.
8061         (create_data_ref): Likewise.
8062         * tree-data-ref.c (dr_analyze_indices): Make nest parameter an
8063         entry edge into a region and adjust instantiate_scev calls.
8064         (create_data_ref): Likewise.
8065         (graphite_find_data_references_in_stmt): Likewise.
8066         (find_data_references_in_stmt): Pass the loop preheader edge
8067         from the nest argument.
8068         * tree-scalar-evolution.h (instantiate_scev): Make instantiate_below
8069         parameter the edge into the region.
8070         (instantiate_parameters): Use the loop preheader edge as entry.
8071         * tree-scalar-evolution.c (analyze_scalar_evolution): Handle
8072         NULL loop.
8073         (get_instantiated_value_entry): Make instantiate_below parameter
8074         the edge into the region.
8075         (instantiate_scev_name): Likewise.  Adjust dominance checks,
8076         when we cannot use loop-based instantiation instantiate by
8077         walking use-def chains.
8078         (instantiate_scev_poly): Adjust.
8079         (instantiate_scev_binary): Likewise.
8080         (instantiate_scev_convert): Likewise.
8081         (instantiate_scev_not): Likewise.
8082         (instantiate_array_ref): Remove.
8083         (instantiate_scev_3): Likewise.
8084         (instantiate_scev_2): Likewise.
8085         (instantiate_scev_1): Likewise.
8086         (instantiate_scev_r): Do not blindly handle N-operand trees.
8087         Do not instantiate array-refs.  Handle all constants and invariants.
8088         (instantiate_scev): Make instantiate_below parameter
8089         the edge into the region.
8090         (resolve_mixers): Use the loop preheader edge for the region
8091         parameter to instantiate_scev_r.
8092         * tree-ssa-loop-prefetch.c (determine_loop_nest_reuse): Adjust.
8094 2017-10-13  Richard Biener  <rguenther@suse.de>
8096         PR tree-optimization/82525
8097         * graphite-isl-ast-to-gimple.c
8098         (translate_isl_ast_to_gimple::widest_int_from_isl_expr_int): Split
8099         out from ...
8100         (translate_isl_ast_to_gimple::gcc_expression_from_isl_expr_int): Here.
8101         Fail code generation when we cannot represent the isl integer.
8102         (binary_op_to_tree): Elide modulo operations that are no-ops
8103         in the type we code generate.  Remove now superfluous code
8104         generation errors.
8106 2017-10-13  Richard Biener  <rguenther@suse.de>
8108         * graphite-scop-detection.c (loop_ivs_can_be_represented): Remove.
8109         (scop_detection::harmful_loop_in_region): Remove premature
8110         IV type restriction.
8111         (scop_detection::graphite_can_represent_scev): We can handle
8112         pointer IVs just fine.
8114 2017-10-13  Alan Modra  <amodra@gmail.com>
8116         * doc/extend.texi (Extended Asm <Clobbers>): Rename to
8117         "Clobbers and Scratch Registers".  Add paragraph on
8118         alternative to clobbers for scratch registers and OpenBLAS
8119         example.
8121 2017-10-13  Alan Modra  <amodra@gmail.com>
8123         * doc/extend.texi (Clobbers): Correct vax example.  Delete old
8124         example of a memory input for a string of known length.  Move
8125         commentary out of table.  Add a number of new examples
8126         covering array memory inputs.
8128 2017-10-12  Martin Liska  <mliska@suse.cz>
8130         PR tree-optimization/82493
8131         * sbitmap.c (bitmap_bit_in_range_p): Fix the implementation.
8132         (test_range_functions): New function.
8133         (sbitmap_c_tests): Likewise.
8134         * selftest-run-tests.c (selftest::run_tests): Run new tests.
8135         * selftest.h (sbitmap_c_tests): New function.
8137         * tree-ssa-dse.c (live_bytes_read): Fix thinko.
8139 2017-10-12  Michael Meissner  <meissner@linux.vnet.ibm.com>
8141         * config/rs6000/amo.h: Fix spacing issue.
8143 2017-10-12  Jakub Jelinek  <jakub@redhat.com>
8145         PR target/82498
8146         * config/i386/i386.md (*ashl<mode>3_mask_1,
8147         *<shift_insn><mode>3_mask_1, *<rotate_insn><mode>3_mask_1,
8148         *<btsc><mode>_mask_1, *btr<mode>_mask_1): New define_insn_and_split
8149         patterns.
8151 2017-10-12  Jan Hubicka  <hubicka@ucw.cz>
8153         * profile-count.h (safe_scale_64bit): Fix GCC4.x path.
8154         (profile_probability): Set max_probability
8155         to (uint32_t) 1 << (n_bits - 2) and update accessors to avoid overlfows
8156         in temporaries.
8157         * profile-count.c (profile_probability::differs_from_p): Do not
8158         rely on max_probaiblity == 10000
8160 2017-10-12  Jeff Law  <law@redhat.com>
8162         * tree-ssa-dse.c (valid_ao_ref_for_dse): Reject ao_refs with
8163         negative offsets.
8165 2017-10-12  Martin Sebor  <msebor@redhat.com>
8167         PR other/82301
8168         PR c/82435
8169         * cgraphunit.c (maybe_diag_incompatible_alias): New function.
8170         (handle_alias_pairs): Call it.
8171         * common.opt (-Wattribute-alias): New option.
8172         * doc/extend.texi (ifunc attribute): Discuss C++ specifics.
8173         * doc/invoke.texi (-Wattribute-alias): Document.
8175 2017-10-12  Vladimir Makarov  <vmakarov@redhat.com>
8177         Revert
8178         2017-10-11  Vladimir Makarov  <vmakarov@redhat.com>
8179         PR sanitizer/82353
8180         * lra.c (collect_non_operand_hard_regs): Don't ignore operator
8181         locations.
8182         * lra-lives.c (bb_killed_pseudos, bb_gen_pseudos): Move up.
8183         (make_hard_regno_born, make_hard_regno_dead): Update
8184         bb_killed_pseudos and bb_gen_pseudos.
8186 2017-10-12  Jan Hubicka  <hubicka@ucw.cz>
8188         * config/i386/x86-tune-sched.c (ix86_adjust_cost): Fix Zen support.
8190 2017-10-12  Uros Bizjak  <ubizjak@gmail.com>
8192         * config/alpha/alpha.c (alpha_split_conditional_move):
8193         Use std::swap instead of manually swapping.
8194         (alpha_stdarg_optimize_hook): Ditto.
8195         (alpha_canonicalize_comparison): Ditto.
8197 2017-10-12  Bin Cheng  <bin.cheng@arm.com>
8199         * tree-loop-distribution.c (struct builtin_info): New struct.
8200         (struct partition): Refactor fields into struct builtin_info.
8201         (partition_free): Free struct builtin_info.
8202         (build_size_arg_loc, build_addr_arg_loc): Delete.
8203         (generate_memset_builtin, generate_memcpy_builtin): Get memory range
8204         information from struct builtin_info.
8205         (find_single_drs): New function refactored from classify_partition.
8206         Also moved builtin validity checks to this function.
8207         (compute_access_range, alloc_builtin): New functions.
8208         (classify_builtin_st, classify_builtin_ldst): New functions.
8209         (classify_partition): Refactor code into functions find_single_drs,
8210         classify_builtin_st and classify_builtin_ldst.
8211         (distribute_loop): Don't do runtime alias check when distributing
8212         loop nest.
8213         (find_seed_stmts_for_distribution): New function.
8214         (pass_loop_distribution::execute): Refactor code finding seed
8215         stmts into above function.  Support distribution for the innermost
8216         two-level loop nest.  Adjust dump information.
8218 2017-10-12  Bin Cheng  <bin.cheng@arm.com>
8220         * tree-loop-distribution.c: Adjust the general comment.
8221         (NUM_PARTITION_THRESHOLD): New macro.
8222         (ssa_name_has_uses_outside_loop_p): Support loop nest distribution.
8223         (classify_partition): Skip builtin pattern of loop nest's inner loop.
8224         (merge_dep_scc_partitions): New parameter ignore_alias_p and use it
8225         in call to build_partition_graph.
8226         (finalize_partitions): New parameter.  Make loop distribution more
8227         conservative by fusing more partitions.
8228         (distribute_loop): Don't do runtime alias check in case of loop nest
8229         distribution.
8230         (find_seed_stmts_for_distribution): New function.
8231         (prepare_perfect_loop_nest): New function.
8232         (pass_loop_distribution::execute): Refactor code finding seed stmts
8233         and loop nest into above functions.  Support loop nest distribution.
8234         Adjust dump information accordingly.
8236 2017-10-12  Bin Cheng  <bin.cheng@arm.com>
8238         * tree-loop-distribution.c (break_alias_scc_partitions): Add comment
8239         and set PTYPE_SEQUENTIAL for merged partition.
8241 2017-10-12  Richard Biener  <rguenther@suse.de>
8243         PR tree-optimization/69728
8244         Revert
8245         2017-09-19  Richard Biener  <rguenther@suse.de>
8247         PR tree-optimization/69728
8248         * graphite-sese-to-poly.c (schedule_error): New global.
8249         (add_loop_schedule): Handle empty domain by failing the
8250         schedule.
8251         (build_original_schedule): Handle schedule_error.
8253         * graphite-sese-to-poly.c (add_loop_schedule): Handle empty
8254         domain by returning an unchanged schedule.
8256 2017-10-12  Jakub Jelinek  <jakub@redhat.com>
8258         * genrecog.c (validate_pattern): For VEC_SELECT verify that
8259         CONST_INT selectors are 0 to GET_MODE_NUNITS (imode) - 1.
8261 2017-10-12  Aldy Hernandez  <aldyh@redhat.com>
8263         * Makefile.in (TAGS): Merge all the *.def files into one pattern.
8264         Handle params.def.
8266 2017-10-12  Jakub Jelinek  <jakub@redhat.com>
8268         PR c++/82159
8269         * expr.c (store_field): Don't optimize away bitsize == 0 store
8270         from CALL_EXPR with addressable return type.
8272 2017-10-11  Segher Boessenkool  <segher@kernel.crashing.org>
8274         * config/rs6000/rs6000.h (TARGET_ISEL64): Delete.
8275         * config/rs6000/rs6000.md (sel): Delete mode attribute.
8276         (mov<mode>cc, isel_signed_<mode>, isel_unsigned_<mode>,
8277         *isel_reversed_signed_<mode>, *isel_reversed_unsigned_<mode>): Use
8278         TARGET_ISEL instead of TARGET_ISEL<sel>.
8280 2017-10-11  David Edelsohn  <dje.gcc@gmail.com>
8282         * config/rs6000/rs6000.c
8283         (rs6000_xcoff_asm_output_aligned_decl_common): Test for NULL decl.
8285 2017-10-11  Segher Boessenkool  <segher@kernel.crashing.org>
8287         * config/rs6000/predicates.md (zero_constant, all_ones_constant):
8288         Move up in file.
8289         (reg_or_cint_operand): Fix comment.
8290         (reg_or_zero_operand): New predicate.
8291         * config/rs6000/rs6000-protos.h (output_isel): Delete.
8292         * config/rs6000/rs6000.c (output_isel): Delete.
8293         * config/rs6000/rs6000.md (isel_signed_<mode>): Use reg_or_zero_operand
8294         instead of reg_or_cint_operand.  Output instruction directly (not via
8295         output_isel).
8296         (isel_unsigned_<mode>): Ditto.
8297         (*isel_reversed_signed_<mode>): Use reg_or_zero_operand instead of
8298         gpc_reg_operand.  Add an instruction alternative for this.  Output
8299         instruction directly.
8300         (*isel_reversed_unsigned_<mode>): Ditto.
8302 2017-10-11  Uros Bizjak  <ubizjak@gmail.com>
8304         * config/i386/i386.c (ix86_canonicalize_comparison): New function.
8305         (TARGET_CANONICALIZE_COMPARISON): Define.
8307 2017-10-11  Qing Zhao  <qing.zhao@oracle.com>
8309         PR target/81422
8310         * config/aarch64/aarch64.c (aarch64_load_symref_appropriately):
8311         Check whether the dest is REG before adding REG_EQUIV note.
8313 2017-10-11  Vladimir Makarov  <vmakarov@redhat.com>
8315         PR sanitizer/82353
8316         * lra.c (collect_non_operand_hard_regs): Don't ignore operator
8317         locations.
8318         * lra-lives.c (bb_killed_pseudos, bb_gen_pseudos): Move up.
8319         (make_hard_regno_born, make_hard_regno_dead): Update
8320         bb_killed_pseudos and bb_gen_pseudos.
8322 2017-10-11  Nathan Sidwell  <nathan@acm.org>
8324         * incpath.h (enum incpath_kind): Name enum, prefix values.
8325         (add_path, add_cpp_dir_path, get_added_cpp_dirs): Use incpath_kind.
8326         * incpath.c (heads, tails): Use INC_MAX.
8327         (add_env_var_paths, add_standard_paths): Use incpath_kind.
8328         (merge_include_chains, split_quote_chain,
8329         register_include_chains): Update incpath_kind names.
8330         (add_cpp_dir_path, add_path, get_added_cpp_dirs): Use incpath_kind.
8331         * config/darwin-c.c (add_system_framework_path): Update incpath_kind
8332         names.
8333         (add_framework_path, darwin_register_objc_includes): Likewise.
8334         * config/vms/vms-c.c (vms_c_register_includes): Likewise.
8336 2017-10-11  Uros Bizjak  <ubizjak@gmail.com>
8338         * config/i386/i386.md (*cmp<X87MODEF:mode>_<SWI24:mode>_i387):
8339         Do not use float_operator operator predicate.
8340         (*cmp<X87MODEF:mode>_<SWI24:mode>_cc_i387): Ditto.
8341         * config/i386/predicates.md (float_operator): Remove predicate.
8343 2017-10-11  Uros Bizjak  <ubizjak@gmail.com>
8345         * config/i386/i386.md (*jcc<mode>_0_i387): Remove insn pattern.
8346         (*jccxf_i387): Ditto.
8347         (*jcc<mode>_i387): Ditto.
8348         (*jccu<mode>_i387): Ditto.
8349         (*jcc<X87MODEF:mode>_<SWI24:mode>_i387): Ditto.
8350         (*jcc_*_i387 splitters): Remove.
8351         * config/i386/i386-protos.h (ix86_split_fp_branch): Remove prototype.
8352         * config/i386/i386.c (ix86_split_fp_branch): Remove.
8353         * config/i386/predicates.md (ix86_swapped_fp_comparison_operator):
8354         Remove predicate.
8356 2017-10-11  Jan Hubicka  <hubicka@ucw.cz>
8358         * profile-count.h (slow_safe_scale_64bit): New function.
8359         (safe_scale_64bit): New inline.
8360         (profile_count::max_safe_multiplier): Remove; use safe_scale_64bit.
8361         * profile-count.c: Include wide-int.h
8362         (slow_safe_scale_64bit): New.
8364 2017-10-11  Nathan Sidwell  <nathan@acm.org>
8366         * tree.h (DECL_ASSEMBLER_NAME_SET_P): Don't check
8367         HAS_DECL_ASSEMBLER_NAME_P.
8368         * gimple-expr.c (gimple_decl_printable_name: Check
8369         HAS_DECL_ASSEMBLER_NAME_P too.
8370         * ipa-utils.h (type_in_anonymous_namespace_p): Check
8371         DECL_ASSEMBLER_NAME_SET_P of TYPE_NAME.
8372         (odr_type_p): No need to assert TYPE_NAME is a TYPE_DECL.
8373         * passes.c (rest_of_decl_compilation): Check
8374         HAS_DECL_ASSEMBLER_NAME_P too.
8375         * recog.c (verify_changes): Likewise.
8376         * tree-pretty-print.c (dump_decl_name): Likewise.
8377         * tree-ssa-structalias.c (alias_get_name): Likewise.  Reimplement.
8379         * tree.h (DECL_ASSEMBLER_NAME_RAW): New.
8380         (SET_DECL_ASSEMBLER_NAME): Use it.
8381         (DECL_ASSEMBLER_NAME_SET_P): Likewise.
8382         (COPY_DECL_ASSEMBLER_NAME): Likewise.
8383         * tree.c (decl_assembler_name): Use DECL_ASSEMBLER_NAME_RAW.
8385 2017-10-11  Jan Hubicka  <hubicka@ucw.cz>
8387         * config.gcc (i386, x86_64): Add extra objects.
8388         * config/i386/i386-protos.h (ix86_rip_relative_addr_p): Declare.
8389         (ix86_min_insn_size): Declare.
8390         (ix86_issue_rate): Declare.
8391         (ix86_adjust_cost): Declare.
8392         (ia32_multipass_dfa_lookahead): Declare.
8393         (ix86_macro_fusion_p): Declare.
8394         (ix86_macro_fusion_pair_p): Declare.
8395         (ix86_bd_has_dispatch): Declare.
8396         (ix86_bd_do_dispatch): Declare.
8397         (ix86_core2i7_init_hooks): Declare.
8398         (ix86_atom_sched_reorder): Declare.
8399         * config/i386/i386.c Move all CPU cost tables to x86-tune-costs.h.
8400         (COSTS_N_BYTES): Move to x86-tune-costs.h.
8401         (DUMMY_STRINGOP_ALGS):Move to x86-tune-costs.h.
8402         (rip_relative_addr_p): Rename to ...
8403         (ix86_rip_relative_addr_p): ... this one; export.
8404         (memory_address_length): Update.
8405         (ix86_issue_rate): Move to x86-tune-sched.c.
8406         (ix86_flags_dependent): Move to x86-tune-sched.c.
8407         (ix86_agi_dependent): Move to x86-tune-sched.c.
8408         (exact_dependency_1): Move to x86-tune-sched.c.
8409         (exact_store_load_dependency): Move to x86-tune-sched.c.
8410         (ix86_adjust_cost): Move to x86-tune-sched.c.
8411         (ia32_multipass_dfa_lookahead): Move to x86-tune-sched.c.
8412         (ix86_macro_fusion_p): Move to x86-tune-sched.c.
8413         (ix86_macro_fusion_pair_p): Move to x86-tune-sched.c.
8414         (do_reorder_for_imul): Move to x86-tune-sched-atom.c.
8415         (swap_top_of_ready_list): Move to x86-tune-sched-atom.c.
8416         (ix86_sched_reorder): Move to x86-tune-sched-atom.c.
8417         (core2i7_first_cycle_multipass_init): Move to x86-tune-sched-core.c.
8418         (core2i7_dfa_post_advance_cycle): Move to x86-tune-sched-core.c.
8419         (min_insn_size): Rename to ...
8420         (ix86_min_insn_size): ... this one; export.
8421         (core2i7_first_cycle_multipass_begin): Move to x86-tune-sched-core.c.
8422         (core2i7_first_cycle_multipass_issue): Move to x86-tune-sched-core.c.
8423         (core2i7_first_cycle_multipass_backtrack): Move to
8424         x86-tune-sched-core.c.
8425         (core2i7_first_cycle_multipass_end): Move to x86-tune-sched-core.c.
8426         (core2i7_first_cycle_multipass_fini): Move to x86-tune-sched-core.c.
8427         (ix86_sched_init_global): Break up logic to ix86_core2i7_init_hooks.
8428         (ix86_avoid_jump_mispredicts): Update.
8429         (TARGET_SCHED_DISPATCH): Move to ix86-tune-sched-bd.c.
8430         (TARGET_SCHED_DISPATCH_DO): Move to ix86-tune-sched-bd.c.
8431         (TARGET_SCHED_REORDER): Move to ix86-tune-sched-bd.c.
8432         (DISPATCH_WINDOW_SIZE): Move to ix86-tune-sched-bd.c.
8433         (MAX_DISPATCH_WINDOWS): Move to ix86-tune-sched-bd.c.
8434         (MAX_INSN): Move to ix86-tune-sched-bd.c.
8435         (MAX_IMM): Move to ix86-tune-sched-bd.c.
8436         (MAX_IMM_SIZE): Move to ix86-tune-sched-bd.c.
8437         (MAX_IMM_32): Move to ix86-tune-sched-bd.c.
8438         (MAX_IMM_64): Move to ix86-tune-sched-bd.c.
8439         (MAX_LOAD): Move to ix86-tune-sched-bd.c.
8440         (MAX_STORE): Move to ix86-tune-sched-bd.c.
8441         (BIG): Move to ix86-tune-sched-bd.c.
8442         (enum dispatch_group): Move to ix86-tune-sched-bd.c.
8443         (enum insn_path): Move to ix86-tune-sched-bd.c.
8444         (get_mem_group): Move to ix86-tune-sched-bd.c.
8445         (is_cmp): Move to ix86-tune-sched-bd.c.
8446         (dispatch_violation): Move to ix86-tune-sched-bd.c.
8447         (is_branch): Move to ix86-tune-sched-bd.c.
8448         (is_prefetch): Move to ix86-tune-sched-bd.c.
8449         (init_window): Move to ix86-tune-sched-bd.c.
8450         (allocate_window): Move to ix86-tune-sched-bd.c.
8451         (init_dispatch_sched): Move to ix86-tune-sched-bd.c.
8452         (is_end_basic_block): Move to ix86-tune-sched-bd.c.
8453         (process_end_window): Move to ix86-tune-sched-bd.c.
8454         (allocate_next_window): Move to ix86-tune-sched-bd.c.
8455         (find_constant): Move to ix86-tune-sched-bd.c.
8456         (get_num_immediates): Move to ix86-tune-sched-bd.c.
8457         (has_immediate): Move to ix86-tune-sched-bd.c.
8458         (get_insn_path): Move to ix86-tune-sched-bd.c.
8459         (get_insn_group): Move to ix86-tune-sched-bd.c.
8460         (count_num_restricted): Move to ix86-tune-sched-bd.c.
8461         (fits_dispatch_window): Move to ix86-tune-sched-bd.c.
8462         (add_insn_window): Move to ix86-tune-sched-bd.c.
8463         (add_to_dispatch_window): Move to ix86-tune-sched-bd.c.
8464         (debug_dispatch_window_file): Move to ix86-tune-sched-bd.c.
8465         (debug_dispatch_window): Move to ix86-tune-sched-bd.c.
8466         (debug_insn_dispatch_info_file): Move to ix86-tune-sched-bd.c.
8467         (debug_ready_dispatch): Move to ix86-tune-sched-bd.c.
8468         (do_dispatch): Move to ix86-tune-sched-bd.c.
8469         (has_dispatch): Move to ix86-tune-sched-bd.c.
8470         * config/i386/t-i386: Add new object files.
8471         * config/i386/x86-tune-costs.h: New file.
8472         * config/i386/x86-tune-sched-atom.c: New file.
8473         * config/i386/x86-tune-sched-bd.c: New file.
8474         * config/i386/x86-tune-sched-core.c: New file.
8475         * config/i386/x86-tune-sched.c: New file.
8477 2017-10-11  Liu Hao  <lh_mouse@126.com>
8479         * pretty-print.c [_WIN32] (colorize_init): Remove.  Use
8480         the generic version below instead.
8481         (should_colorize): Recognize Windows consoles as terminals
8482         for MinGW targets.
8483         * pretty-print.c [__MINGW32__] (write_all): New function.
8484         [__MINGW32__] (find_esc_head): Likewise.
8485         [__MINGW32__] (find_esc_terminator): Likewise.
8486         [__MINGW32__] (eat_esc_sequence): Likewise.
8487         [__MINGW32__] (mingw_ansi_fputs): New function that handles
8488         ANSI escape codes.
8489         (pp_write_text_to_stream): Use mingw_ansi_fputs instead of fputs
8490         for MinGW targets.
8492 2017-10-11  Richard Biener  <rguenther@suse.de>
8494         * tree-ssa-loop-niter.c (infer_loop_bounds_from_pointer_arith):
8495         Properly call analyze_scalar_evolution with the loop of the stmt.
8497 2017-10-11  Richard Biener  <rguenther@suse.de>
8499         * tree.def (POLYNOMIAL_CHREC): Remove CHREC_VARIABLE tree operand.
8500         * tree-core.h (tree_base): Add chrec_var union member.
8501         * tree.h (CHREC_VAR): Remove.
8502         (CHREC_LEFT, CHREC_RIGHT, CHREC_VARIABLE): Adjust.
8503         * tree-chrec.h (build_polynomial_chrec): Adjust.
8504         * tree-chrec.c (reset_evolution_in_loop): Use build_polynomial_chrec.
8505         * tree-pretty-print.c (dump_generic_node): Use CHREC_VARIABLE.
8507 2017-10-11  Marc Glisse  <marc.glisse@inria.fr>
8509         * fold-const.c (fold_binary_loc) [X +- Y CMP X]: Move ...
8510         * match.pd: ... here.
8511         ((T) X == (T) Y): Relax condition.
8513 2017-10-11  Bin Cheng  <bin.cheng@arm.com>
8515         PR tree-optimization/82472
8516         * tree-loop-distribution.c (sort_partitions_by_post_order): Refine
8517         comment.
8518         (break_alias_scc_partitions): Update postorder number.
8520 2017-10-11  Martin Liska  <mliska@suse.cz>
8522         PR sanitizer/82490
8523         * opts.c (parse_no_sanitize_attribute): Do not use error_value
8524         variable.
8525         * opts.h (parse_no_sanitize_attribute): Remove last argument.
8527 2017-10-11  Martin Liska  <mliska@suse.cz>
8529         * print-rtl.c (print_insn): Move declaration of idbuf
8530         to same scope as name.
8532 2017-10-11  Martin Liska  <mliska@suse.cz>
8534         Revert r253637:
8536         PR sanitizer/82484
8537         * sanopt.c (sanitize_rewrite_addressable_params): Do not handle
8538         volatile arguments.
8540 2017-10-11  Martin Liska  <mliska@suse.cz>
8542         PR sanitizer/82484
8543         * sanopt.c (sanitize_rewrite_addressable_params): Do not handle
8544         volatile arguments.
8546 2017-10-11  Adhemerval Zanella  <adhemerval.zanella@linaro.org>
8548         * config.gcc (default_gnu_indirect_function): Default to yes for
8549         arm*-*-linux* with glibc.
8551 2017-10-11  Richard Biener  <rguenther@suse.de>
8553         * tree-scalar-evolution.c (get_scalar_evolution): Handle
8554         default-defs and types we do not want to analyze.
8555         (interpret_loop_phi): Replace unreachable code with an assert.
8556         (compute_scalar_evolution_in_loop): Remove and inline ...
8557         (analyze_scalar_evolution_1): ... here, replacing condition with
8558         what makes the intent clearer.  Remove handling of cases
8559         get_scalar_evolution now handles.
8561 2017-10-10  Jim Wilson  <wilson@tuliptree.org>
8563         PR rtl-optimization/81434
8564         * haifa-sched.c (prune_ready_list): Init min_cost_group to 0.  Update
8565         comment for main loop.  In sched_group_found if, also add checks for
8566         pass and min_cost_group.
8568 2017-10-10  Segher Boessenkool  <segher@kernel.crashing.org>
8570         * config/rs6000/rs6000.c (TARGET_INSN_COST): New.
8571         (rs6000_insn_cost): New function.
8572         * config/rs6000/rs6000.md (cost): New attribute.
8574 2017-10-10  Jakub Jelinek  <jakub@redhat.com>
8575             H.J. Lu  <hongjiu.lu@intel.com>
8577         PR target/79565
8578         PR target/82483
8579         * config/i386/i386.c (ix86_init_mmx_sse_builtins): Add
8580         OPTION_MASK_ISA_MMX for __builtin_ia32_maskmovq,
8581         __builtin_ia32_vec_ext_v4hi and __builtin_ia32_vec_set_v4hi.
8582         (ix86_expand_builtin): Treat OPTION_MASK_ISA_MMX similarly
8583         to OPTION_MASK_ISA_AVX512VL - builtins that have both
8584         OPTION_MASK_ISA_MMX and some other bit set require both
8585         mmx and the ISAs without the mmx bit.
8586         * config/i386/i386-builtin.def (__builtin_ia32_cvtps2pi,
8587         __builtin_ia32_cvttps2pi, __builtin_ia32_cvtpi2ps,
8588         __builtin_ia32_pavgb, __builtin_ia32_pavgw, __builtin_ia32_pmulhuw,
8589         __builtin_ia32_pmaxub, __builtin_ia32_pmaxsw, __builtin_ia32_pminub,
8590         __builtin_ia32_pminsw, __builtin_ia32_psadbw, __builtin_ia32_pmovmskb,
8591         __builtin_ia32_pshufw, __builtin_ia32_cvtpd2pi,
8592         __builtin_ia32_cvttpd2pi, __builtin_ia32_cvtpi2pd,
8593         __builtin_ia32_pmuludq, __builtin_ia32_pabsb, __builtin_ia32_pabsw,
8594         __builtin_ia32_pabsd, __builtin_ia32_phaddw, __builtin_ia32_phaddd,
8595         __builtin_ia32_phaddsw, __builtin_ia32_phsubw, __builtin_ia32_phsubd,
8596         __builtin_ia32_phsubsw, __builtin_ia32_pmaddubsw,
8597         __builtin_ia32_pmulhrsw, __builtin_ia32_pshufb, __builtin_ia32_psignb,
8598         __builtin_ia32_psignw, __builtin_ia32_psignd, __builtin_ia32_movntq,
8599         __builtin_ia32_paddq, __builtin_ia32_psubq, __builtin_ia32_palignr):
8600         Add OPTION_MASK_ISA_MMX.
8602 2017-10-10  Andreas Tobler  <andreast@gcc.gnu.org>
8604         * config.gcc (armv7*-*-freebsd*): New target.
8605         (armv6*-*-freebsd*): Remove obsolete TARGET_FREEBSD_ARMv6 define.
8607 2017-10-10  Jan Hubicka  <hubicka@ucw.cz>
8609         * x86-tune.def (X86_TUNE_AVOID_FALSE_DEP_FOR_BMI,
8610         X86_TUNE_ADJUST_UNROLL, X86_TUNE_ONE_IF_CONV_INSN): Move to right
8611         spot in the file.
8613 2017-10-10  Richard Sandiford  <richard.sandiford@linaro.org>
8615         * wide-int.h (wide_int_ref_storage): Make host_dependent_precision
8616         a template parameter.
8617         (WIDE_INT_REF_FOR): Update accordingly.
8618         * tree.h (wi::int_traits <const_tree>): Delete.
8619         (wi::tree_to_widest_ref, wi::tree_to_offset_ref): New typedefs.
8620         (wi::to_widest, wi::to_offset): Use them.  Expand commentary.
8621         (wi::tree_to_wide_ref): New typedef.
8622         (wi::to_wide): New function.
8623         * calls.c (get_size_range): Use wi::to_wide when operating on
8624         trees as wide_ints.
8625         * cgraph.c (cgraph_node::create_thunk): Likewise.
8626         * config/i386/i386.c (ix86_data_alignment): Likewise.
8627         (ix86_local_alignment): Likewise.
8628         * dbxout.c (stabstr_O): Likewise.
8629         * dwarf2out.c (add_scalar_info, gen_enumeration_type_die): Likewise.
8630         * expr.c (const_vector_from_tree): Likewise.
8631         * fold-const-call.c (host_size_t_cst_p, fold_const_call_1): Likewise.
8632         * fold-const.c (may_negate_without_overflow_p, negate_expr_p)
8633         (fold_negate_expr_1, int_const_binop_1, const_binop)
8634         (fold_convert_const_int_from_real, optimize_bit_field_compare)
8635         (all_ones_mask_p, sign_bit_p, unextend, extract_muldiv_1)
8636         (fold_div_compare, fold_single_bit_test, fold_plusminus_mult_expr)
8637         (pointer_may_wrap_p, expr_not_equal_to, fold_binary_loc)
8638         (fold_ternary_loc, multiple_of_p, fold_negate_const, fold_abs_const)
8639         (fold_not_const, round_up_loc): Likewise.
8640         * gimple-fold.c (gimple_fold_indirect_ref): Likewise.
8641         * gimple-ssa-warn-alloca.c (alloca_call_type_by_arg): Likewise.
8642         (alloca_call_type): Likewise.
8643         * gimple.c (preprocess_case_label_vec_for_gimple): Likewise.
8644         * godump.c (go_output_typedef): Likewise.
8645         * graphite-sese-to-poly.c (tree_int_to_gmp): Likewise.
8646         * internal-fn.c (get_min_precision): Likewise.
8647         * ipa-cp.c (ipcp_store_vr_results): Likewise.
8648         * ipa-polymorphic-call.c
8649         (ipa_polymorphic_call_context::ipa_polymorphic_call_context): Likewise.
8650         * ipa-prop.c (ipa_print_node_jump_functions_for_edge): Likewise.
8651         (ipa_modify_call_arguments): Likewise.
8652         * match.pd: Likewise.
8653         * omp-low.c (scan_omp_1_op, lower_omp_ordered_clauses): Likewise.
8654         * print-tree.c (print_node_brief, print_node): Likewise.
8655         * stmt.c (expand_case): Likewise.
8656         * stor-layout.c (layout_type): Likewise.
8657         * tree-affine.c (tree_to_aff_combination): Likewise.
8658         * tree-cfg.c (group_case_labels_stmt): Likewise.
8659         * tree-data-ref.c (dr_analyze_indices): Likewise.
8660         (prune_runtime_alias_test_list): Likewise.
8661         * tree-dump.c (dequeue_and_dump): Likewise.
8662         * tree-inline.c (remap_gimple_op_r, copy_tree_body_r): Likewise.
8663         * tree-predcom.c (is_inv_store_elimination_chain): Likewise.
8664         * tree-pretty-print.c (dump_generic_node): Likewise.
8665         * tree-scalar-evolution.c (iv_can_overflow_p): Likewise.
8666         (simple_iv_with_niters): Likewise.
8667         * tree-ssa-address.c (addr_for_mem_ref): Likewise.
8668         * tree-ssa-ccp.c (ccp_finalize, evaluate_stmt): Likewise.
8669         * tree-ssa-loop-ivopts.c (constant_multiple_of): Likewise.
8670         * tree-ssa-loop-niter.c (split_to_var_and_offset)
8671         (refine_value_range_using_guard, number_of_iterations_ne_max)
8672         (number_of_iterations_lt_to_ne, number_of_iterations_lt)
8673         (get_cst_init_from_scev, record_nonwrapping_iv)
8674         (scev_var_range_cant_overflow): Likewise.
8675         * tree-ssa-phiopt.c (minmax_replacement): Likewise.
8676         * tree-ssa-pre.c (compute_avail): Likewise.
8677         * tree-ssa-sccvn.c (vn_reference_fold_indirect): Likewise.
8678         (vn_reference_maybe_forwprop_address, valueized_wider_op): Likewise.
8679         * tree-ssa-structalias.c (get_constraint_for_ptr_offset): Likewise.
8680         * tree-ssa-uninit.c (is_pred_expr_subset_of): Likewise.
8681         * tree-ssanames.c (set_nonzero_bits, get_nonzero_bits): Likewise.
8682         * tree-switch-conversion.c (collect_switch_conv_info, array_value_type)
8683         (dump_case_nodes, try_switch_expansion): Likewise.
8684         * tree-vect-loop-manip.c (vect_gen_vector_loop_niters): Likewise.
8685         (vect_do_peeling): Likewise.
8686         * tree-vect-patterns.c (vect_recog_bool_pattern): Likewise.
8687         * tree-vect-stmts.c (vectorizable_load): Likewise.
8688         * tree-vrp.c (compare_values_warnv, vrp_int_const_binop): Likewise.
8689         (zero_nonzero_bits_from_vr, ranges_from_anti_range): Likewise.
8690         (extract_range_from_binary_expr_1, adjust_range_with_scev): Likewise.
8691         (overflow_comparison_p_1, register_edge_assert_for_2): Likewise.
8692         (is_masked_range_test, find_switch_asserts, maybe_set_nonzero_bits)
8693         (vrp_evaluate_conditional_warnv_with_ops, intersect_ranges): Likewise.
8694         (range_fits_type_p, two_valued_val_range_p, vrp_finalize): Likewise.
8695         (evrp_dom_walker::before_dom_children): Likewise.
8696         * tree.c (cache_integer_cst, real_value_from_int_cst, integer_zerop)
8697         (integer_all_onesp, integer_pow2p, integer_nonzerop, tree_log2)
8698         (tree_floor_log2, tree_ctz, mem_ref_offset, tree_int_cst_sign_bit)
8699         (tree_int_cst_sgn, get_unwidened, int_fits_type_p): Likewise.
8700         (get_type_static_bounds, num_ending_zeros, drop_tree_overflow)
8701         (get_range_pos_neg): Likewise.
8702         * ubsan.c (ubsan_expand_ptr_ifn): Likewise.
8703         * config/darwin.c (darwin_mergeable_constant_section): Likewise.
8704         * config/aarch64/aarch64.c (aapcs_vfp_sub_candidate): Likewise.
8705         * config/arm/arm.c (aapcs_vfp_sub_candidate): Likewise.
8706         * config/avr/avr.c (avr_fold_builtin): Likewise.
8707         * config/bfin/bfin.c (bfin_local_alignment): Likewise.
8708         * config/msp430/msp430.c (msp430_attr): Likewise.
8709         * config/nds32/nds32.c (nds32_insert_attributes): Likewise.
8710         * config/powerpcspe/powerpcspe-c.c
8711         (altivec_resolve_overloaded_builtin): Likewise.
8712         * config/powerpcspe/powerpcspe.c (rs6000_aggregate_candidate)
8713         (rs6000_expand_ternop_builtin): Likewise.
8714         * config/rs6000/rs6000-c.c
8715         (altivec_resolve_overloaded_builtin): Likewise.
8716         * config/rs6000/rs6000.c (rs6000_aggregate_candidate): Likewise.
8717         (rs6000_expand_ternop_builtin): Likewise.
8718         * config/s390/s390.c (s390_handle_hotpatch_attribute): Likewise.
8720 2017-10-10  Bin Cheng  <bin.cheng@arm.com>
8722         * tree-vect-loop-manip.c (rename_variables_in_bb): Rename PHI nodes
8723         when copying loop nest with only one inner loop.
8725 2017-10-10  Richard Biener  <rguenther@suse.de>
8727         * tree-cfgcleanup.c (cleanup_tree_cfg_noloop): Avoid compacting
8728         blocks if SCEV is active.
8729         * tree-scalar-evolution.c (analyze_scalar_evolution_1): Remove
8730         dead code.
8731         (analyze_scalar_evolution): Handle cached evolutions the obvious way.
8732         (scev_initialize): Assert we are not yet initialized.
8734 2017-10-10  Bin Cheng  <bin.cheng@arm.com>
8736         * tree-loop-distribution.c (generate_loops_for_partition): Remove
8737         inner loop's exit stmt by making it always exit the loop, otherwise
8738         we would generate an infinite empty loop.
8740 2017-10-10  Bin Cheng  <bin.cheng@arm.com>
8742         * tree-vect-loop-manip.c (slpeel_tree_duplicate_loop_to_edge_cfg): Skip
8743         renaming variables in new preheader if it's deleted.
8745 2017-10-10  Bin Cheng  <bin.cheng@arm.com>
8747         * tree-loop-distribution.c (struct partition): Remove unused field
8748         loops of the structure.
8749         (partition_alloc, partition_free): Ditto.
8750         (build_rdg_partition_for_vertex): Ditto.
8752 2017-10-09  Jeff Law  <law@redhat.com>
8754         * targhooks.c (default_stack_clash_protection_final_dynamic_probe): Fix
8755         return type to match prototype and documentation.
8757 2010-10-09  Segher Boessenkool  <segher@kernel.crashing.org>
8759         * config/rs6000/rs6000.c (processor_costs): Move to ...
8760         * config/rs6000/rs6000.h: ... here.
8761         (rs6000_cost): Declare.
8763 2017-10-09  Eric Botcazou  <ebotcazou@adacore.com>
8765         * except.c (setjmp_fn): New global variable.
8766         (init_eh): Initialize it if DONT_USE_BUILTIN_SETJMP is defined.
8767         (sjlj_emit_function_enter): Call it instead of BUILTIN_SETJMP
8768         if DONT_USE_BUILTIN_SETJMP is defined.
8770 2017-10-09  Segher Boessenkool  <segher@kernel.crashing.org>
8772         * target.def (insn_cost): New hook.
8773         * doc/tm.texi.in (TARGET_INSN_COST): New hook.
8774         * doc/tm.texi: Regenerate.
8775         * rtlanal.c (insn_cost): Use the new hook.
8777 2017-10-09  Segher Boessenkool  <segher@kernel.crashing.org>
8779         * combine.c (combine_validate_cost): Compute the new insn_cost,
8780         not just pattern_cost.
8781         (try_combine): Adjust comment.
8783 2017-10-09  Segher Boessenkool  <segher@kernel.crashing.org>
8785         * cfgrtl.c (rtl_account_profile_record): Replace insn_rtx_cost with
8786         insn_cost.
8787         * combine.c (uid_insn_cost): Adjust comment.
8788         (combine_validate_cost): Adjust comment.  Use pattern_cost instead
8789         of insn_rtx_cost
8790         (combine_instructions): Use insn_cost instead of insn_rtx_cost.
8791         * dse.c (find_shift_sequence): Ditto.
8792         * ifcvt.c (cheap_bb_rtx_cost_p): Ditto.
8793         (bb_valid_for_noce_process_p): Use pattern_cost.
8794         * rtl.h (insn_rtx_cost): Delete.
8795         (pattern_cost): New prototype.
8796         (insn_cost): New prototype.
8797         * rtlanal.c (insn_rtx_cost): Rename to...
8798         (pattern_cost): ... this.
8799         (insn_cost): New.
8801 2017-10-09  Uros Bizjak  <ubizjak@gmail.com>
8803         * config/i386/i386.md (*jcc_2): Remove insn pattern.
8804         (*jcc<mode>_0_r_i387): Ditto.
8805         (*jccxf_r_i387): Ditto.
8806         (*jcc<mode>_r_i387): Ditto.
8807         (*jccu<mode>_r_i387): Ditto.
8808         (*jcc<X87MODEF:mode>_<SWI24:mode>_r_i387): Ditto.
8809         (*jcc): Rename from *jcc_1.
8811 2017-10-09  Bill Schmidt  <wschmidt@linux.vnet.ibm.com>
8813         * config/rs6000/rs6000-p8swap.c (rs6000_analyze_swaps): Process
8814         deferred rescans after the lvx/stvx recombination pre-pass.
8816 2017-10-09  Michael Meissner  <meissner@linux.vnet.ibm.com>
8818         * config/rs6000/amo.h: New include file to provide ISA 3.0 atomic
8819         memory operation instruction support.
8820         * config.gcc (powerpc*-*-*): Include amo.h as an extra header.
8821         (rs6000-ibm-aix[789]*): Likewise.
8822         * doc/extend.texi (PowerPC Atomic Memory Operation Functions):
8823         Document new functions.
8825 2017-10-09  Richard Biener  <rguenther@suse.de>
8827         PR tree-optimization/82397
8828         * tree-data-ref.c (data_ref_compare_tree): Make sure to return
8829         equality only for semantically equal trees.
8831 2017-10-09  Richard Biener  <rguenther@suse.de>
8833         PR tree-optimization/82449
8834         * sese.c (scev_analyzable_p): Check whether the SCEV is linear.
8835         * tree-chrec.h (evolution_function_is_constant_p): Adjust to
8836         allow constant addresses.
8837         * tree-chrec.c (scev_is_linear_expression): Constant evolutions
8838         are linear.
8840 2017-10-09  Andreas Krebbel  <krebbel@linux.vnet.ibm.com>
8842         * config/s390/s390-builtins.def (vec_nabs, vec_vfi): Fix builtin
8843         flags.
8845 2017-10-09  Andreas Krebbel  <krebbel@linux.vnet.ibm.com>
8847         PR target/82463
8848         * config/s390/vecintrin.h (vec_madd, vec_msub): Fix macro
8849         definitions.
8851 2017-10-09  Andreas Krebbel  <krebbel@linux.vnet.ibm.com>
8853         PR target/82465
8854         * config/s390/s390-builtins.def (vec_sqrt): Fix builtin flags.
8856 2017-10-09  Jakub Jelinek  <jakub@redhat.com>
8858         PR target/82464
8859         * config/s390/s390-builtins.def (s390_vec_xor_flt_a,
8860         s390_vec_xor_flt_b, s390_vec_xor_flt_c): New.
8862 2017-10-09  Richard Sandiford  <richard.sandiford@linaro.org>
8864         * wide-int.h (WI_BINARY_OPERATOR_RESULT): New macro.
8865         (WI_BINARY_PREDICATE_RESULT): Likewise.
8866         (wi::binary_traits::operator_result): New type.
8867         (wi::binary_traits::predicate_result): Likewise.
8868         (generic_wide_int::operator~, unary generic_wide_int::operator-)
8869         (generic_wide_int::operator==, generic_wide_int::operator!=)
8870         (generic_wide_int::operator&, generic_wide_int::and_not)
8871         (generic_wide_int::operator|, generic_wide_int::or_not)
8872         (generic_wide_int::operator^, generic_wide_int::operator+
8873         (binary generic_wide_int::operator-, generic_wide_int::operator*):
8874         Delete.
8875         (operator~, unary operator-, operator==, operator!=, operator&)
8876         (operator|, operator^, operator+, binary operator-, operator*): New
8877         functions.
8878         * expr.c (get_inner_reference): Use wi::bit_and_not.
8879         * fold-const.c (fold_binary_loc): Likewise.
8880         * ipa-prop.c (ipa_compute_jump_functions_for_edge): Likewise.
8881         * tree-ssa-ccp.c (get_value_from_alignment): Likewise.
8882         (bit_value_binop): Likewise.
8883         * tree-ssa-math-opts.c (find_bswap_or_nop_load): Likewise.
8884         * tree-vrp.c (zero_nonzero_bits_from_vr): Likewise.
8885         (extract_range_from_binary_expr_1): Likewise.
8886         (masked_increment): Likewise.
8887         (simplify_bit_ops_using_ranges): Likewise.
8889 2017-10-09  Martin Jambor  <mjambor@suse.cz>
8891         PR hsa/82416
8892         * hsa-common.h (hsa_op_with_type): New method extend_int_to_32bit.
8893         * hsa-gen.c (hsa_extend_inttype_to_32bit): New function.
8894         (hsa_type_for_scalar_tree_type): Use it.  Always force min32int for
8895         COMPLEX types.
8896         (hsa_fixup_mov_insn_type): New function.
8897         (hsa_op_with_type::get_in_type): Use it.
8898         (hsa_build_append_simple_mov): Likewise.  Allow sub-32bit
8899         immediates in an assert.
8900         (hsa_op_with_type::extend_int_to_32bit): New method.
8901         (gen_hsa_insns_for_bitfield): Fixup instruction and intermediary
8902         types.  Convert to dest type if necessary.
8903         (gen_hsa_insns_for_bitfield_load): Fixup load type if necessary.
8904         (reg_for_gimple_ssa): Pass false as min32int to
8905         hsa_type_for_scalar_tree_type.
8906         (gen_hsa_addr): Fixup type when creating addresable temporary.
8907         (gen_hsa_cmp_insn_from_gimple): Extend operands if necessary.
8908         (gen_hsa_unary_operation): Extend operands and convert to dest type if
8909         necessary.  Call hsa_fixup_mov_insn_type.
8910         (gen_hsa_binary_operation): Changed operand types to hsa_op_with_type,
8911         extend operands and convert to dest type if necessary.
8912         (gen_hsa_insns_for_operation_assignment): Extend operands and convert
8913         to dest type if necessary.
8914         (set_output_in_type): Call hsa_fixup_mov_insn_type.  Just ude dest
8915         if conversion nt necessary and size matches.
8916         (gen_hsa_insns_for_load): Call hsa_fixup_mov_insn_type, convert
8917         to dest type if necessary.
8918         (gen_hsa_insns_for_store): Call hsa_fixup_mov_insn_type.
8919         (gen_hsa_insns_for_switch_stmt): Likewise. Also extend operands if
8920         necessary.
8921         (gen_hsa_clrsb): Likewise.
8922         (gen_hsa_ffs): Likewise.
8923         (gen_hsa_divmod): Extend operands and convert to dest type if
8924         necessary.
8925         (gen_hsa_atomic_for_builtin): Change type of op to hsa_op_with_type.
8927 2017-10-08  Segher Boessenkool  <segher@kernel.crashing.org>
8929         * config/rs6000/rs6000.md (conditional branch): Clean up formatting.
8930         Remove empty default arguments.  Use a brace block as output
8931         statement.
8932         (conditional return): Ditto.
8933         (jump): Ditto.
8934         (indirect_jump): Ditto.  Use b%T0 instead of bctr/blr.
8935         (tablejump, tablejumpsi, tablejumpdi, *tablejump<mode>_internal1):
8936         Ditto.
8937         (group_ending_nop): Ditto.
8938         (doloop_end): Ditto.
8939         (ctr<mode>, ctr<mode>_internal1, ctr<mode>_internal2): Ditto.
8940         (splitters for those): Ditto.
8942 2017-10-08  Segher Boessenkool  <segher@kernel.crashing.org>
8944         * config/rs6000/rs6000-string.c (expand_strncmp_align_check): Invert
8945         a conditional jump (and the compare for it) so that pc_rtx is the
8946         last operand.
8947         * config/rs6000/rs6000.c (rs6000_legitimate_combined_insn): Adjust
8948         for the deleted and renamed ctr<mode>_internal[234] patterns.
8949         * config/rs6000/rs6000.md: Delete second conditional branch pattern.
8950         Delete second conditional return pattern.
8951         (ctr<mode>_internal2): Delete this second bdnz pattern.
8952         (ctr<mode>_internal3): Rename to ctr<mode>_internal2.
8953         (ctr<mode>_internal4): Delete this second bdz pattern.
8955 2017-10-08  Eric Botcazou  <ebotcazou@adacore.com>
8957         * tree-outof-ssa.h (ssaexpand): Add partitions_for_undefined_values.
8958         (always_initialized_rtx_for_ssa_name_p): New predicate.
8959         * tree-outof-ssa.c (remove_ssa_form): Initialize new field of SA.
8960         (finish_out_of_ssa): Free new field of SA.
8961         * tree-ssa-coalesce.h (get_undefined_value_partitions): Declare.
8962         * tree-ssa-coalesce.c: Include tree-ssa.h.
8963         (get_parm_default_def_partitions): Remove extern keyword.
8964         (get_undefined_value_partitions): New function.
8965         * expr.c (expand_expr_real_1) <expand_decl_rtl>: For a SSA_NAME, do
8966         not set SUBREG_PROMOTED_VAR_P on the sub-register if it may contain
8967         uninitialized bits.
8968         * loop-iv.c (iv_get_reaching_def): Disqualify all subregs.
8970 2017-10-08  Eric Botcazou  <ebotcazou@adacore.com>
8972         * builtins.def (BUILT_IN_SETJMP): Revert latest change.
8974 2017-10-08  Jan Hubicka  <hubicka@ucw.cz>
8976         * config/i386/i386.c (ix86_expand_set_or_movmem): Disable 512bit loops
8977         for targets that preffer 128bit.
8979 2017-10-08  Jan Hubicka  <hubicka@ucw.cz>
8981         * config/i386/i386.c (has_dispatch): Disable for Ryzen.
8983 2017-10-08  Olivier Hainque  <hainque@adacore.com>
8985         * config/arm/arm.c (arm_set_return_address): Use MEM_VOLATILE_P
8986         on the target mem instead of RTX_FRAME_RELATED_P on the insn to
8987         prevent DSE.
8988         (thumb_set_return_address): Likewise.
8990 2017-10-08  Olivier Hainque  <hainque@adacore.com>
8992         * common/config/arm/arm-common.c (arm_except_unwind_info):
8993         Handle DWARF2_UNWIND_INFO.
8995 2017-10-07  Michael Collison <michael.collison@arm.com>
8997         * config/aarch64/aarch64.md (*aarch64_reg_<optab>_minus<mode>3):
8998         New pattern.
9000 2017-10-07  Eric Botcazou  <ebotcazou@adacore.com>
9002         * builtins.def (BUILT_IN_SETJMP): Declare as library builtin instead
9003         of GCC builtin if DONT_USE_BUILTIN_SETJMP is defined.
9004         * except.c (sjlj_emit_function_enter): If DONT_USE_BUILTIN_SETJMP is
9005         defined, force the creation of a new block for a dispatch label.
9007 2017-10-07  Jan Hubicka  <hubicka@ucw.cz>
9009         * invoke.texi (Wsuggest-attribute=cold): Document.
9010         * common.opt (Wsuggest-attribute=cold): New
9011         * ipa-pure-const.c (warn_function_cold): New function.
9012         * predict.c (compute_function_frequency): Use it.
9013         * predict.h (warn_function_cold): Declare.
9015 2017-10-06  Jan Hubicka  <hubicka@ucw.cz>
9017         * tree-switch-conversion.c (do_jump_if_equal, emit_cmp_and_jump_insns):
9018         Update profile.
9020 2017-10-06  Martin Liska  <mliska@suse.cz>
9022         * sanopt.c (struct sanopt_tree_triplet_hash): Remove inline
9023         keyword for member functions.
9024         (struct sanopt_tree_couple): New struct.
9025         (struct sanopt_tree_couple_hash): New function.
9026         (struct sanopt_ctx): Add new hash_map.
9027         (has_dominating_ubsan_ptr_check): New function.
9028         (record_ubsan_ptr_check_stmt): Likewise.
9029         (maybe_optimize_ubsan_ptr_ifn): Likewise.
9030         (sanopt_optimize_walker): Handle IFN_UBSAN_PTR.
9031         (pass_sanopt::execute): Handle also SANITIZE_POINTER_OVERFLOW.
9033 2017-10-06  Sudakshina Das  <sudi.das@arm.com>
9035         PR target/82440
9036         * config/aarch64/predicates.md (aarch64_reg_or_orr_imm): Only call
9037         aarch64_simd_valid_immediate on CONST_VECTORs.
9038         (aarch64_reg_or_bic_imm): Likewise.
9040 2017-10-06  Wilco Dijkstra  <wdijkstr@arm.com>
9042         PR rtl-optimization/82396
9043         * haifa-sched.c (ready_sort_real): Disable qsort checking.
9045 2017-10-06  Sebastian Pop  <sebpop@gmail.com>
9047         * graphite-dependences.c (scop_get_reads): Move code to...
9048         (scop_get_must_writes): Move code to...
9049         (scop_get_may_writes): Move code to...
9050         (scop_get_reads_and_writes): ... here.
9051         (scop_get_dependences): Call scop_get_reads_and_writes.
9053 2017-10-06  Jakub Jelinek  <jakub@redhat.com>
9055         PR tree-optimization/82434
9056         * fold-const.h (can_native_encode_type_p,
9057         can_native_encode_string_p): Remove.
9058         * fold-const.c (native_encode_int): Formatting fixes.  If ptr is NULL,
9059         don't encode anything, just return what would be otherwise returned.
9060         (native_encode_fixed, native_encode_complex, native_encode_vector):
9061         Likewise.
9062         (native_encode_string): Likewise.  Inline by hand
9063         can_native_encode_string_p.
9064         (can_native_encode_type_p): Remove.
9065         (can_native_encode_string_p): Remove.
9066         * tree-vect-stmts.c (vectorizable_store): Instead of testing just
9067         STRING_CSTs using can_native_encode_string_p, test all
9068         CONSTANT_CLASS_P values using native_encode_expr with NULL ptr.
9069         * gimple-ssa-store-merging.c (encode_tree_to_bitpos): Remove last
9070         argument from native_encode_expr.
9071         (rhs_valid_for_store_merging_p): Use native_encode_expr with NULL ptr.
9072         (pass_store_merging::execute): Don't unnecessarily look for 3 stmts,
9073         but just 2.
9075 2017-10-06  Richard Biener  <rguenther@suse.de>
9077         PR tree-optimization/82397
9078         * tree-vect-data-refs.c (dr_group_sort_cmp): Do not use
9079         operand_equal_p but rely on data_ref_compare_tree for detecting
9080         equalities.
9081         (vect_analyze_data_ref_accesses): Use data_ref_compare_tree
9082         to match up with dr_group_sort_cmp.
9084 2017-10-06  Andreas Krebbel  <krebbel@linux.vnet.ibm.com>
9086         PR target/82322
9087         * config/s390/s390-builtins.def (s390_vfi): Define new overloaded
9088         builtin.
9089         * config/s390/s390-builtin-types.def: Regenerate.
9091 2017-10-06  Andreas Krebbel  <krebbel@linux.vnet.ibm.com>
9093         PR target/82317
9094         * config/s390/s390-builtin-types.def: Regenerate.
9095         * config/s390/s390-builtins.def (s390_vfmaxdb_4, s390_vfmindb_4):
9096         Change flag from B_VXE to B_VX.
9097         (s390_vec_min_dbl): Remove B_VXE flag.
9099 2017-10-06  Richard Biener  <rguenther@suse.de>
9101         * graphite-isl-ast-to-gimple.c: Include ssa.h and tree-ssa.h.
9102         (translate_isl_ast_to_gimple::translate_pending_phi_nodes,
9103         translate_isl_ast_to_gimple::is_valid_rename,
9104         translate_isl_ast_to_gimple::get_rename,
9105         translate_isl_ast_to_gimple::get_def_bb_for_const,
9106         translate_isl_ast_to_gimple::get_new_name,
9107         translate_isl_ast_to_gimple::collect_all_ssa_names,
9108         translate_isl_ast_to_gimple::copy_loop_phi_args,
9109         translate_isl_ast_to_gimple::collect_all_ssa_names,
9110         translate_isl_ast_to_gimple::copy_loop_phi_args,
9111         translate_isl_ast_to_gimple::copy_loop_phi_nodes,
9112         translate_isl_ast_to_gimple::add_close_phis_to_merge_points,
9113         translate_isl_ast_to_gimple::add_close_phis_to_outer_loops,
9114         translate_isl_ast_to_gimple::copy_loop_close_phi_args,
9115         translate_isl_ast_to_gimple::copy_loop_close_phi_nodes,
9116         translate_isl_ast_to_gimple::copy_cond_phi_args,
9117         translate_isl_ast_to_gimple::copy_cond_phi_nodes,
9118         translate_isl_ast_to_gimple::edge_for_new_close_phis,
9119         translate_isl_ast_to_gimple::add_phi_arg_for_new_expr,
9120         translate_isl_ast_to_gimple::rename_uses,
9121         translate_isl_ast_to_gimple::rename_all_uses): Remove.
9122         (translate_isl_ast_to_gimple::get_rename_from_scev): Simplify.
9123         (set_rename_for_each_def): Likewise.
9124         (graphite_copy_stmts_from_block): Handle debug stmt resetting
9125         here.  Handle rewriting SCEV analyzable uses here.
9126         (copy_bb_and_scalar_dependences): Generate code for PHI
9127         copy-in/outs.
9128         (graphite_regenerate_ast_isl): Adjust.
9129         * graphite-scop-detection.c (trivially_empty_bb_p): Move to sese.[ch].
9130         (add_write, add_read): New functions.
9131         (build_cross_bb_scalars_def): Use it and simplify.
9132         (build_cross_bb_scalars_use): Likewise.
9133         (graphite_find_cross_bb_scalar_vars): Inline into...
9134         (try_generate_gimple_bb): ...here.  Add dependences for PHIs,
9135         simulating out-of-SSA.  Compute liveout and add dependencies.
9136         (build_scops): Force an empty entry block.
9137         * sese.h (sese_info_t::liveout, sese_info_t::debug_liveout): New
9138         members.
9139         (sese_build_liveouts): Declare.
9140         (sese_trivially_empty_bb_p): Likewise.
9141         * sese.c (sese_build_liveouts_bb): Properly handle PHIs,
9142         compute liveout and debug_liveout.
9143         (sese_bad_liveouts_use): Remove.
9144         (sese_reset_debug_liveouts_bb): Likewise.
9145         (sese_reset_debug_liveouts): Rewrite in terms of debug_liveout.
9146         (sese_build_liveouts): Build liveout and debug_liveout and store
9147         it in region.
9148         (new_sese_info): Adjust.
9149         (free_sese_info): Likewise.
9150         (sese_insert_phis_for_liveouts): Reset debug stmts from here,
9151         do not build liveout here.
9152         (move_sese_in_condition): Adjust region entry.
9153         (scev_analyzable_p): Match up with chrec_apply requirements.
9154         (sese_trivially_empty_bb_p): New.
9155         * tree-into-ssa.c (get_reaching_def): Properly support generating
9156         default-defs for incremental rewrite of anonymous names.
9158 2017-10-06  Richard Biener  <rguenther@suse.de>
9160         * graphite-sese-to-poly.c (extract_affine): For casts increasing
9161         precision do not perform modulo reduction.
9163 2017-10-06  Richard Biener  <rguenther@suse.de>
9165         PR tree-optimization/82436
9166         * tree-vect-slp.c (vect_supported_load_permutation_p): More
9167         conservatively choose the vectorization factor when checking
9168         whether we can perform the required load permutation.
9169         (vect_transform_slp_perm_load): Assert when we may not fail.
9171 2017-10-05  Segher Boessenkool  <segher@kernel.crashing.org>
9173         * config/rs6000/sysv4.h (SUBTARGET_OVERRIDE_OPTIONS): Correct error
9174         message for incompatible -msdata=* and -mcall-* options.
9176 2017-10-05  Jan Hubicka <hubicka@ucw.cz>
9178         * config/i386/i386.c (ia32_multipass_dfa_lookahead): Default to issue
9179         rate for post-reload scheduling.
9181 2017-10-05  Tamar Christina  <tamar.christina@arm.com>
9183         * doc/sourcebuild.texi (vect_sizes_16B_8B, vect_sizes_32B_16B): New.
9185 2017-10-05  Jan Hubicka <hubicka@ucw.cz>
9187         * config/i386/i386.c (znver1_cost): Set branch_cost to 3 (instead of 2)
9188         to improve monte carlo in scimark.
9190 2017-10-05  Jan Hubicka <hubicka@ucw.cz>
9192         * config/i386/i386.c (ix86_size_cost, i386_cost, i486_cost,
9193         pentium_cost, lakemont_cost, pentiumpro_cost, geode_cost, k6_cost,
9194         athlon_cost, k8_cost, amdfam10_cost, btver1_cost, btver2_cost,
9195         pentium4_cost, nocona_cost): Set reassociation width to 1.
9196         (bdver1_cost, bdver2_cost, bdver3_cost, bdver4_cost): Set reassociation
9197         width to 2 for fp operations and 1 otherwise.
9198         (znver1_cost): Set scalar reassoc width to 4 and vector to 3 and 6
9199         for int and fp.
9200         (atom_cost): Set reassociation width to 2.
9201         (slm_cost, generic_cost): Set fp reassociation width
9202         to 2 and 1 otherwise.
9203         (intel_cost): Set fp reassociation width to 4 and 1 otherwise.
9204         (core_cost): Set fp reassociation width to 4 and vector to 2.
9205         (ix86_reassociation_width): Rewrite using cost table; special case
9206         plus/minus on Zen; honor X86_TUNE_SSE_SPLIT_REGS
9207         and TARGET_AVX128_OPTIMAL.
9208         * config/i386/i386.h (processor_costs): Add
9209         reassoc_int, reassoc_fp, reassoc_vec_int, reassoc_vec_fp.
9210         (TARGET_VECTOR_PARALLEL_EXECUTION, TARGET_REASSOC_INT_TO_PARALLEL,
9211         TARGET_REASSOC_FP_TO_PARALLEL): Remove.
9212         * x86-tune.def (X86_TUNE_REASSOC_INT_TO_PARALLEL): Remove.
9213         (X86_TUNE_REASSOC_FP_TO_PARALLEL): Remove.
9214         (X86_TUNE_VECTOR_PARALLEL_EXECUTION):  Remove.
9216 2017-10-05  Nathan Sidwell  <nathan@acm.org>
9218         * doc/invoke.texi (Wparentheses): Document C++ MVP behaviour.
9220 2017-10-05  Tamar Christina  <tamar.christina@arm.com>
9222         * config/arm/arm.c (arm_test_fpu_data): New.
9223         (arm_run_selftests): Call arm_test_fpu_data.
9225 2017-10-04  Nathan Sidwell  <nathan@acm.org>
9227         * toplev.c (toplev::main): Remove excess parens on pretty_printer
9228         decl.
9229         * caller-save.c (insert_save): Remove excess parens on TO_SAVE parm.
9231 2017-10-04  Sudakshina Das  <sudi.das@arm.com>
9233         * config/aarch64/aarch64-protos.h (enum simd_immediate_check): New
9234         check type for aarch64_simd_valid_immediate.
9235         (aarch64_output_simd_mov_immediate): Update prototype.
9236         (aarch64_simd_valid_immediate): Update prototype.
9237         * config/aarch64/aarch64-simd.md (orr<mode>3): modified pattern to add
9238         support for ORR-immediate.
9239         (and<mode>3): modified pattern to add support for BIC-immediate.
9240         * config/aarch64/aarch64.c (aarch64_simd_valid_immediate): Function
9241         now checks for valid immediate for BIC and ORR based on new enum
9242         argument.
9243         (aarch64_output_simd_mov_immediate): Function now used to output
9244         BIC/ORR imm as well based on new enum argument.
9245         * config/aarch64/constraints.md (Do): New vector immediate constraint.
9246         (Db) : Likewise.
9247         * config/aarch64/predicates.md (aarch64_reg_or_orr_imm): New predicate.
9248         (aarch64_reg_or_bic_imm): Likewise.
9250 2017-10-04  Andreas Krebbel  <krebbel@linux.vnet.ibm.com>
9252         * config/s390/vx-builtins.md ("vec_mergeh<mode>")
9253         ("vec_mergel<mode>"): Change mode iterator to V_128_NOSINGLE.
9255 2017-10-04  Wilco Dijkstra  <wdijkstr@arm.com>
9257         Revert r253399:
9259         PR rtl-optimization/82396
9260         * haifa-sched.c (autopref_multipass_init): Simplify
9261         initialization.
9262         (autopref_rank_data): Simplify sort order.
9263         * sched-int.h (autopref_multipass_data_): Remove
9264         multi_mem_insn_p, min_offset and max_offset.
9266 2017-10-04  Andreas Krebbel  <krebbel@linux.vnet.ibm.com>
9268         * doc/sourcebuild.texi: Document vect_peeling_profitable.
9270 2017-10-04  Andreas Krebbel  <krebbel@linux.vnet.ibm.com>
9272         * doc/sourcebuild.texi: Document vect_intdouble_cvt and
9273         vect_doubleint_cvt.
9275 2017-10-04  Andreas Krebbel  <krebbel@linux.vnet.ibm.com>
9277         * doc/sourcebuild.texi: Document vect_long_mult.
9279 2017-10-04  Richard Sandiford  <richard.sandiford@linaro.org>
9281         PR tree-optimization/82413
9282         * fold-const.c (build_range_check): Use widest_int when comparing
9283         the maximum ETYPE value with HIGH.
9285 2017-10-04  Wilco Dijkstra  <wdijkstr@arm.com>
9287         PR rtl-optimization/82396
9288         * haifa-sched.c (autopref_multipass_init): Simplify
9289         initialization.
9290         (autopref_rank_data): Simplify sort order.
9291         * sched-int.h (autopref_multipass_data_): Remove
9292         multi_mem_insn_p, min_offset and max_offset.
9294 2017-10-04  Jakub Jelinek  <jakub@redhat.com>
9296         PR tree-optimization/82381
9297         * tree-ssa-reassoc.c (sort_by_operand_rank): Check for different
9298         oeN->rank first.  Return 1 or -1 if one op is SSA_NAME and the other
9299         is not.
9301         PR tree-optimization/82374
9302         * omp-low.c (create_omp_child_function): Copy DECL_ATTRIBUTES,
9303         DECL_FUNCTION_SPECIFIC_OPTIMIZATION,
9304         DECL_FUNCTION_SPECIFIC_TARGET and DECL_FUNCTION_VERSIONED from
9305         current_function_decl to the new decl.
9307 2017-10-03  Michael Meissner  <meissner@linux.vnet.ibm.com>
9309         * config/rs6000/rs6000-builtin.def (BU_FLOAT128_2_HW): Define new
9310         helper macro for IEEE float128 hardware built-in functions.
9311         (SQRTF128_ODD): Add built-in functions with the round-to-odd
9312         semantics.
9313         (TRUNCF128_ODD): Likewise.
9314         (ADDF128_ODD): Likewise.
9315         (SUBF128_ODD): Likewise.
9316         (MULF128_ODD): Likewise.
9317         (DIVF128_ODD): Likewise.
9318         (FMAF128_ODD): Likewise.
9319         * config/rs6000/rs6000.md (UNSPEC_ROUND_TO_ODD): Rename to
9320         UNSPEC_TRUNC_ROUND_TO_ODD.
9321         (UNSPEC_TRUNC_ROUND_TO_ODD): Likewise.
9322         (UNSPEC_ADD_ROUND_TO_ODD): New unspec codes for the IEEE 128-bit
9323         floating point round to odd instructions.
9324         (UNSPEC_SUB_ROUND_TO_ODD): Likewise.
9325         (UNSPEC_MUL_ROUND_TO_ODD): Likewise.
9326         (UNSPEC_DIV_ROUND_TO_ODD): Likewise.
9327         (UNSPEC_FMA_ROUND_TO_ODD): Likewise.
9328         (UNSPEC_SQRT_ROUND_TO_ODD): Likewise.
9329         (trunc<mode>sf2_hw): Change the truncate with round to odd
9330         expansion to use UNSPEC_TRUNC_ROUND_TO_ODD.
9331         (add<mode>3_odd): Add insns for IEEE 128-bit floating point round
9332         to odd hardware instructions.
9333         (sub<mode>3_odd): Likewise.
9334         (mul<mode>3_odd): Likewise.
9335         (div<mode>3_odd): Likewise.
9336         (sqrt<mode>2_odd): Likewise.
9337         (fma<mode>4_odd): Likewise.
9338         (fms<mode>4_odd): Likewise.
9339         (nfma<mode>4_odd): Likewise.
9340         (nfms<mode>4_odd): Likewise.
9341         (trunc<mode>df2_odd): Change the truncate with round to odd
9342         expansion to use UNSPEC_TRUNC_ROUND_TO_ODD.  Add a generator
9343         function.
9344         * doc/extend.texi (PowerPC built-in functions): Update documentation
9345         for existing IEEE float128-bit built-in functions.  Add built-in
9346         functions that generate the IEEE 128-bit floating point round to
9347         odd instructions.
9349 2017-10-03  Segher Boessenkool  <segher@kernel.crashing.org>
9351         PR rtl-optimization/77729
9352         * simplify-rtx.c (simplify_binary_operation_1): Delete the (X&C1)|C2
9353         to (X&(C1&~C2))|C2 transformations.
9355 2017-10-03  Martin Jambor  <mjambor@suse.cz>
9357         PR tree-optimization/82363
9358         * tree-sra.c (propagate_subaccesses_across_link): In unrecoverable
9359         mismatch, mark lacc written regardless of racc.
9361 2017-10-03  Jakub Jelinek  <jakub@redhat.com>
9363         PR tree-optimization/82381
9364         * tree-ssa-reassoc.c (sort_by_operand_rank): Don't check
9365         stmt_to_insert nor wheather SSA_NAMEs are default defs.
9366         Return 1 or -1 if one of bba and bbb is NULL. If bb_rank is equal,
9367         fallthrough into reassoc_stmt_dominates_stmt_p.
9369         PR target/82386
9370         * combine.c (combine_instructions): Don't combine in unreachable
9371         basic blocks.
9373 2017-08-18  Peter Bergner  <bergner@vnet.ibm.com>
9375         PR target/80210
9376         * config/rs6000/rs6000.c (rs6000_option_override_internal): Rewrite
9377         function to not use the have_cpu variable.  Do not set cpu_index,
9378         rs6000_cpu_index or rs6000_tune_index if we end up using TARGET_DEFAULT
9379         or the default cpu.
9380         (rs6000_valid_attribute_p): Remove duplicate initializations of
9381         old_optimize and func_optimize.
9382         (rs6000_pragma_target_parse): Call rs6000_activate_target_options ().
9383         (rs6000_activate_target_options): Make global.
9384         * config/rs6000/rs6000-protos.h (rs6000_activate_target_options): Add
9385         prototype.
9387 2017-10-02  Jakub Jelinek  <jakub@redhat.com>
9389         * tree-dfa.c (get_ref_base_and_extent): Set *pmax_size to -1
9390         if *poffset + *pmax_size overflows in HOST_WIDE_INT.
9391         Set *poffset to 0 and *psize and *pmax_size to -1 if
9392         *poffset + *psize overflows in HOST_WIDE_INT.
9394         PR tree-optimization/82387
9395         PR tree-optimization/82388
9396         PR tree-optimization/82389
9397         * tree-ssa-dse.c (dse_classify_store): Test byte_tracking_enabled
9398         instead of live_bytes non-NULL.
9400 2017-10-02  Georg-Johann Lay  <avr@gjlay.de>
9402         PR target/41076
9403         * confg/avr/avr.md (*iorhi3.ashift8-ext.zerox): Add "r,r,0"
9404         alternative.
9406 2017-10-02  Richard Biener  <rguenther@suse.de>
9408         * graphite-isl-ast-to-gimple.c (set_codegen_error): With
9409         -fchecking and --param graphite-allow-codegen-errors=0 ICE.
9410         * params.def (PARAM_GRAPHITE_ALLOW_CODEGEN_ERRORS): New param.
9412 2017-10-02  Richard Sandiford  <richard.sandiford@linaro.org>
9414         * tree.h (wi::int_traits <const_tree>::decompose): Assert that the
9415         requested precision matches the type's.
9416         * calls.c (alloc_max_size): Calculate the new candidate size as
9417         a widest_int and use wi::to_widest when comparing it with the
9418         current candidate size.
9419         * gimple-ssa-warn-alloca.c (pass_walloca::execute): Compare with
9420         zero rather than integer_zero_node.
9421         * match.pd: Check for a no-op conversion before using wi::add
9422         rather than after.  Use tree_to_uhwi when summing small shift
9423         counts into an unsigned int.
9425 2017-10-02  Richard Sandiford  <richard.sandiford@linaro.org>
9426             Alan Hayward  <alan.hayward@arm.com>
9427             David Sherwood  <david.sherwood@arm.com>
9429         PR target/71307
9430         * config/aarch64/aarch64.h (POINTER_AND_FP_REGS): New reg class.
9431         (REG_CLASS_NAMES, REG_CLASS_CONTENTS): Update accordingly.
9432         * config/aarch64/aarch64.c (aarch64_class_max_nregs): Handle
9433         POINTER_AND_FP_REGS.
9435 2017-10-02  Richard Biener  <rguenther@suse.de>
9437         PR tree-optimization/82355
9438         * graphite-isl-ast-to-gimple.c (build_iv_mapping): Also build
9439         a mapping for the enclosing loop but avoid generating one for
9440         the loop tree root.
9441         (copy_bb_and_scalar_dependences): Remove premature codegen
9442         error on PHIs in blocks duplicated into multiple places.
9443         * graphite-scop-detection.c
9444         (scop_detection::stmt_has_simple_data_refs_p): For a loop not
9445         in the region use it as loop and nest to analyze the DR in.
9446         (try_generate_gimple_bb): Likewise.
9447         * graphite-sese-to-poly.c (extract_affine_chrec): Adjust.
9448         (add_loop_constraints): For blocks in a loop not in the region
9449         create a dimension with a single iteration.
9450         * sese.h (gbb_loop_at_index): Remove assert.
9452 2017-10-01  Kevin Buettner  <kevinb@redhat.com>
9454         * omp-expand.c (adjust_context_scope): New function.
9455         (expand_parallel_call): Call adjust_context_scope.
9457 2017-10-01  Jeff Law  <law@redhat.com>
9459         * tree-ssa-dom.c (optimize_stmt): Make this a method within the
9460         dom_opt_dom_walker class with direct access to private members.
9461         Add comments.  Call test_for_singularity.
9462         (dom_opt_dom_walker::before_dom_children): Corresponding changes.
9463         (dom_opt_dom_walker::after_dom_children): Do not lazily initialize
9464         m_dummy_cond anymore.
9465         (class dom_opt_dom_walker): Initialize m_dummy_cond member in the
9466         class ctor.
9467         (pass_dominator:execute): Build the dummy_cond here and pass it
9468         to the dom_opt_dom_walker ctor.
9469         (test_for_singularity): New function.
9471 2017-09-30  Krister Walfridsson  <krister.walfridsson@gmail.com>
9472             Maya Rashish  <coypu@sdf.org>
9474         * config.gcc (*-*-netbsd*): New variable nbsd_tm_file containing
9475         netbsd.h, netbsd-stdint.h, and netbsd-elf.h.
9476         (alpha*-*-netbsd*) Use nbsd_tm_file.
9477         (arm*-*-netbsdelf*) Likewise.
9478         (i[34567]86-*-netbsdelf*) Likewise.
9479         (x86_64-*-netbsd*) Likewise.
9480         (mips*-*-netbsd*) Likewise.
9481         (powerpc-*-netbsd*) Likewise.
9482         (sh*-*-netbsd*) Likewise.
9483         (sparc-*-netbsdelf*) Likewise.
9484         (sparc64-*-netbsd*) Likewise.
9485         (m68k*-*-netbsdelf*) Use nbsd_tm_file and add CHAR_FAST8/SHORT_FAST16
9486         to tm_defines.
9487         (vax-*-netbsdelf*) Likewise.
9488         * config/netbsd-stdint.h (INT_FAST8_TYPE): Check CHAR_FAST8.
9489         (UINT_FAST8_TYPE) Likewise.
9490         (INT_FAST16_TYPE) Check CHAR_FAST16.
9491         (UINT_FAST16_TYPE) Likewise.
9493 2017-09-30  Jakub Jelinek  <jakub@redhat.com>
9495         PR target/82361
9496         * config/i386/i386.md
9497         (TARGET_USE_8BIT_IDIV zext divmodsi4 splitter): New define_split.
9498         (divmodsi4_zext_1, divmodsi4_zext_2, *divmodsi4_zext_1,
9499         *divmodsi4_zext_2): New define_insn_and_split.
9500         (*divmodsi4_noext_zext_1, *divmodsi4_noext_zext_2): New define_insn.
9501         (TARGET_USE_8BIT_IDIV zext udivmodsi4 splitter): New define_split.
9502         (udivmodsi4_zext_1, udivmodsi4_zext_2, *udivmodsi4_zext_1,
9503         *udivmodsi4_zext_2, *udivmodsi4_pow2_zext_1, *udivmodsi4_pow2_zext_2):
9504         New define_insn_and_split.
9505         (*udivmodsi4_noext_zext_1, *udivmodsi4_noext_zext_2): New define_insn.
9506         * config/i386/i386.c (ix86_split_idivmod): Handle operands[0] or
9507         operands[1] having DImode when mode is SImode.
9509         * config/i386/i386.c (ix86_split_idivmod): Use mode instead of
9510         always SImode for DIV and MOD in REG_EQUAL notes.
9512 2017-09-29  Yury Gribov  <tetra2005@gmail.com>
9514         PR middle-end/82319
9515         * match.pd: Fix handling of NaNs in pattern.
9517 2017-09-29  Jeff Law  <law@redhat.com>
9519         * sbitmap.c (bitmap_bit_in_range_p): New function.
9520         * sbitmap.h (bitmap_bit_in_range_p): Prototype.
9521         * tree-ssa-dse.c (live_bytes_read): New function.
9522         (dse_classify_store): Ignore reads of dead bytes.
9524         * config/i386/i386.c (ix86_adjust_stack_and_probe_stack_clash): Fix
9525         typos and whitespace errors.
9526         * config/i386/predicates.md (address_no_seg_operand): Likewise.
9527         * config/s390/s390.c (s390_emit_prologue): Likewise.
9529 2017-09-29  Vladimir Makarov  <vmakarov@redhat.com>
9531         PR target/81481
9532         * ira-costs.c (scan_one_insn): Don't take into account PIC equiv
9533         with a symbol for LRA.
9535 2017-09-29  Vladimir Makarov  <vmakarov@redhat.com>
9537         PR rtl-optimization/82338
9538         * lra-constraints.c (inherit_in_ebb): Check usage_insns check.
9540 2017-09-29  Alexander Monakov  <amonakov@ispras.ru>
9542         * genmodes.c (calc_wider_mode): Suppress qsort macro.
9543         * system.h [CHECKING_P] (qsort): Redirect to qsort_chk.
9544         (qsort_chk): Declare.
9545         * vec.c [CHECKING_P] (qsort_chk_error): New static function.
9546         (qsort_chk): New function.
9548 2017-09-29  Bill Schmidt  <wschmidt@linux.vnet.ibm.com>
9550         PR tree-optimization/82337
9551         * gimple-ssa-strength-reduction.c (find_phi_def): Don't record a
9552         phi definition if the PHI result appears in an abnormal PHI.
9553         (find_basis_for_base_expr): Don't record a basis if the LHS of the
9554         basis appears in an abnormal PHI.
9556 2017-09-29  Richard Biener  <rguenther@suse.de>
9558         * graphite-isl-ast-to-gimple.c
9559         (translate_isl_ast_to_gimple::set_codegen_error): New function.
9560         (binary_op_to_tree): Use it.
9561         (get_rename_from_scev): Likewise.
9562         (copy_loop_phi_nodes): Likewise.
9563         (copy_bb_and_scalar_dependences): Likewise.
9564         (translate_pending_phi_nodes): Likewise.
9566 2017-09-29  Jakub Jelinek  <jakub@redhat.com>
9568         PR target/82339
9569         * config/i386/i386.md (*movdi_internal peephole2): New -Os peephole
9570         for movabsq $(i32 << shift), r64.
9572 2017-09-28  Uros Bizjak  <ubizjak@gmail.com>
9574         * config/i386/i386.c (ix86_print_operand_address_as): Do not check
9575         index when encoding %esp as %rsp to avoid 0x67 prefix.
9577 2017-09-28  Sergey Shalnov  <Sergey.Shalnov@intel.com>
9579         * config/i386/i386.md (*movsf_internal, *movdf_internal):
9580         Return 256-bit AVX modes for TARGET_PREFER_AVX256.
9582 2017-09-28  Thomas Preud'homme  <thomas.preudhomme@arm.com>
9584         * config/arm/arm.c (arm_option_override): Forbid ARMv8-M Security
9585         Extensions with more than 16 double VFP registers.
9586         (cmse_nonsecure_entry_clear_before_return): Remove second entry of
9587         to_clear_mask and all code related to it.  Replace the remaining
9588         entry by a sbitmap and adapt code accordingly.
9590 2017-09-28  Henry Linjamäki  <henry.linjamaki@parmance.com>
9592         * brig-builtins.def: Change pure attributes to const.
9594 2017-09-28  Joseph Myers  <joseph@codesourcery.com>
9596         * config.gcc (default_gnu_indirect_function): Default to yes for
9597         sparc*-*-linux* with glibc.
9599 2017-09-28  Joseph Myers  <joseph@codesourcery.com>
9601         * config/aarch64/aarch64.c (aarch64_elf_asm_constructor)
9602         (aarch64_elf_asm_destructor): Pass SECTION_NOTYPE to get_section
9603         when creating .init_array and .fini_array sections with priority
9604         specified.
9606 2017-09-27  Christophe Lyon  <christophe.lyon@linaro.org>
9608         PR target/71727
9609         * config/aarch64/aarch64.c
9610         (aarch64_builtin_support_vector_misalignment): Always return false
9611         when misalignment is unknown.
9613 2017-09-27  Kelvin Nilsen  <kelvin@gcc.gnu.org>
9615         * config/rs6000/rs6000-p8swap.c (const_load_sequence_p): Revise
9616         this function to return false if the definition used by the swap
9617         instruction is artificial, or if the memory address from which the
9618         constant value is loaded is not represented by a base address held
9619         in a register or if the base address register is a frame or stack
9620         pointer.  Additionally, return false if the base address of the
9621         loaded constant is a SYMBOL_REF but is not considered to be a
9622         constant.
9623         (replace_swapped_load_constant): New function.
9624         (rs6000_analyze_swaps): Add a new pass to replace a swap of a
9625         loaded constant vector with a load of a swapped constant vector.
9627 2017-09-27  Carl Love  <cel@us.ibm.com>
9629         * config/rs6000/rs6000-builtin.def (BU_FP_1MISC_1): Add define macro.
9630         (FCTID, FCTIW): Add BU_FP_MISC_1 macro expansion for builtins.
9631         * config/rs6000/rs6000.md (lrintsfsi2): Add define_insn for the
9632         fctiw instruction.
9634 2017-09-27  Alexander Monakov  <amonakov@ispras.ru>
9636         * haifa-sched.c (autopref_rank_for_schedule): Order 'irrelevant' insns
9637         first, always call autopref_rank_data otherwise.
9639 2017-09-27  Richard Biener  <rguenther@suse.de>
9641         * graphite-scop-detection.c (find_scop_parameters): Move
9642         loop bound handling ...
9643         (gather_bbs::before_dom_children): ... here, avoiding the need
9644         to build scop_info->loop_nest.
9645         (record_loop_in_sese): Remove.
9646         * sese.h (sese_info_t::loop_nest): Remove.
9647         * sese.c (new_sese_info): Do not allocate loop_nest.
9648         (free_sese_info): Do not free loop_nest.
9650 2017-09-27  Jakub Jelinek  <jakub@redhat.com>
9652         PR c++/82159
9653         * gimplify.c (gimplify_modify_expr): Don't optimize away zero sized
9654         lhs from calls if the lhs has addressable type.
9656 2017-09-27  Richard Biener  <rguenther@suse.de>
9658         * graphite.h (scop::max_alias_set): New member.
9659         * graphite-scop-detection.c: Remove references to non-existing
9660         --param in comments.
9661         (build_alias_sets): Record the maximum alias set used for drs.
9662         (build_scops): Support zero as unlimited for
9663         --param graphite-max-arrays-per-scop.
9664         * graphite-sese-to-poly.c (add_scalar_version_numbers): Remove
9665         and inline into ...
9666         (build_poly_sr_1): ... here.  Compute alias set based on the
9667         maximum alias set used for drs rather than
9668         PARAM_GRAPHITE_MAX_ARRAYS_PER_SCOP
9670 2017-09-27  Richard Biener  <rguenther@suse.de>
9672         * graphite-optimize-isl.c (get_schedule_for_node_st): Allow
9673         --param loop-block-tile-size=0 to disable tiling.
9675 2017-09-27  Richard Biener  <rguenther@suse.de>
9677         * doc/invoke.texi (graphite-max-bbs-per-function): Remove.
9678         (graphite-max-nb-scop-params): Document special value zero.
9679         * domwalk.h (dom_walker::STOP): New symbolical constant.
9680         (dom_walker::dom_walker): Add optional parameter for bb to
9681         RPO mapping.
9682         (dom_walker::~dom_walker): Declare.
9683         (dom_walker::before_dom_children): Document STOP return value.
9684         (dom_walker::m_user_bb_to_rpo): New member.
9685         (dom_walker::m_bb_to_rpo): Likewise.
9686         * domwalk.c (dom_walker::dom_walker): Compute bb to RPO
9687         mapping here if not provided by the user.
9688         (dom_walker::~dom_walker): Free bb to RPO mapping if not
9689         provided by the user.
9690         (dom_walker::STOP): Define.
9691         (dom_walker::walk): Do not compute bb to RPO mapping here.
9692         Support STOP return value from before_dom_children to stop
9693         walking.
9694         * graphite-optimize-isl.c (optimize_isl): If the schedule
9695         is the same still generate code if -fgraphite-identity
9696         or -floop-parallelize-all are given.
9697         * graphite-scop-detection.c: Include cfganal.h.
9698         (gather_bbs::gather_bbs): Get and pass through bb to RPO
9699         mapping.
9700         (gather_bbs::before_dom_children): Return STOP for BBs
9701         not in the region.
9702         (build_scops): Compute bb to RPO mapping and pass it to
9703         the domwalk.  Treat --param graphite-max-nb-scop-params=0
9704         as not limiting the number of params.
9705         * graphite.c (graphite_initialize): Remove limit on the
9706         number of basic-blocks in a function.
9707         * params.def (PARAM_GRAPHITE_MAX_BBS_PER_FUNCTION): Remove.
9708         (PARAM_GRAPHITE_MAX_NB_SCOP_PARAMS): Adjust to documented
9709         default value of 10.
9711 2017-09-26  Michael Meissner  <meissner@linux.vnet.ibm.com>
9713         * config/rs6000/vsx.md (peephole for optimizing move SF to GPR):
9714         Adjust code to eliminate needing to do the shift right 32-bits
9715         operation after XSCVDPSPN.
9717 2017-09-26  Prathamesh Kulkarni  <prathamesh.kulkarni@linaro.org>
9719         * match.pd ((X / Y) == 0 -> X < Y): New pattern.
9720         ((X / Y) != 0 -> X >= Y): Likewise.
9722 2017-09-26  Carl Love  <cel@us.ibm.com>
9724         * config/rs6000/rs6000-c.c (P9V_BUILTIN_VEC_XL_LEN_R,
9725         P9V_BUILTIN_VEC_XST_LEN_R): Add support for builtins
9726         vector unsigned char vec_xl_len_r (unsigned char *, size_t);
9727         void vec_xst_len_r (vector unsigned char, unsigned char *, size_t);
9728         * config/rs6000/altivec.h (vec_xl_len_r, vec_xst_len_r): Add defines.
9729         * config/rs6000/rs6000-builtin.def (XL_LEN_R, XST_LEN_R): Add
9730         definitions and overloading.
9731         * config/rs6000/rs6000.c (altivec_expand_builtin): Add case
9732         statement for P9V_BUILTIN_XST_LEN_R.
9733         (altivec_init_builtins): Add def_builtin for P9V_BUILTIN_STXVLL.
9734         * config/rs6000/vsx.md (lxvll, stxvll, xl_len_r, xst_len_r): Add
9735         define_expand and define_insn for the instructions and builtins.
9736         * doc/extend.texi: Update the built-in documentation file for the new
9737         built-in functions.
9738         * config/rs6000/altivec.md (altivec_lvsl_reg, altivec_lvsr_reg): Add
9739         define_insn for the instructions
9741 2017-09-26  Krister Walfridsson  <krister.walfridsson@gmail.com>
9743         PR target/39570
9744         * gcc/config/netbsd-protos.h: New file.
9745         * gcc/config/netbsd.c: New file.
9746         * gcc/config/netbsd.h (SUBTARGET_INIT_BUILTINS): Define.
9747         * gcc/config/t-netbsd: New file.
9748         * gcc/config.gcc (tm_p_file): Add netbsd-protos.h.
9749         (tmake_file) Add t-netbsd.
9750         (extra_objs) Add netbsd.o.
9752 2017-09-26  Janus Weil  <janus@gcc.gnu.org>
9754         PR fortran/82143
9755         PR fortran/82324
9756         * doc/sourcebuild.texi: Document fortran_real_10 and fortran_real_16.
9758 2017-09-26  Michael Meissner  <meissner@linux.vnet.ibm.com>
9760         * config/rs6000/rs6000.md (extendsi<mode>2): Add a splitter to do
9761         sign extension from a vector register to a GPR by doing a 32-bit
9762         direct move and then an EXTSW.
9763         (extendsi<mode>2 splitter): Likewise.
9764         (movsi_from_sf): Adjust code to eliminate doing a 32-bit shift
9765         right or vector extract after doing XSCVDPSPN.  Use
9766         zero_extendsidi2 instead of p8_mfvsrd_4_disf to move the value to
9767         the GPRs.
9768         (movdi_from_sf_zero_ext): Likewise.
9769         (reload_gpr_from_vsxsf): Likewise.
9770         (p8_mfvsrd_4_disf): Delete, no longer used.
9771         (movsi_from_df): Optimize converting a DFmode to a SFmode, and
9772         then needing to move the SFmode to a GPR to use the XSCVDPSP
9773         instruction instead of FRSP and XSCVDPSPN.
9774         * config/rs6000/vsx.md (vsx_xscvspdp_scalar2): Move insn so that
9775         it is adjacent to the other XSCVSPDP insns.
9776         (vsx_xscvdpsp_scalar): Use "ww" constraint instead of "f" to allow
9777         SFmode to be in traditional Altivec registers.
9778         (vsx_xscvdpspn): Eliminate useless alternative constraint.
9779         (vsx_xscvspdpn): Likewise.
9780         (vsx_xscvspdpn_scalar): Likewise.
9782 2017-09-26  Martin Jambor  <mjambor@suse.cz>
9784         * tree-sra.c (compare_access_positions): Put integral types first,
9785         stabilize sorting of integral types, remove conditions putting
9786         non-full-precision integers last.
9787         (sort_and_splice_var_accesses): Disable scalarization if a
9788         non-integert would be represented by a non-full-precision integer.
9790 2017-09-26  Joseph Myers  <joseph@codesourcery.com>
9792         * config/microblaze/linux.h (TARGET_ASM_FILE_END): Likewise.
9793         * config/pa/pa.h (NEED_INDICATE_EXEC_STACK): Likewise.
9794         * config/pa/pa-linux.h (NEED_INDICATE_EXEC_STACK): Likewise.
9795         * config/pa/pa.c (pa_hpux_file_end): Rename to pa_file_end.
9796         Define unconditionally, with [ASM_OUTPUT_EXTERNAL_REAL]
9797         conditionals inside the function instead of around it.  Call
9798         file_end_indicate_exec_stack if NEED_INDICATE_EXEC_STACK.
9799         (TARGET_ASM_FILE_END): Define unconditionally to pa_file_end.
9801 2017-09-26  Richard Biener  <rguenther@suse.de>
9803         * graphite-scop-detection.c (scop_detection::build_scop_depth): Rewrite,
9804         fold in ...
9805         (scop_detection::build_scop_breadth): ... this.  Removed.
9806         (scop_detection::loop_is_valid_in_scop): Fold into single caller.
9807         (scop_detection::harmful_stmt_in_bb): Likewise.
9808         (scop_detection::graphite_can_represent_stmt): Likewise.
9809         (scop_detection::loop_body_is_valid_scop): Likewise.  Remove recursion.
9810         (scop_detection::can_represent_loop): Remove recursion, fold in ...
9811         (scop_detection::can_represent_loop_1): ... this.  Removed.
9812         (scop_detection::harmful_loop_in_region): Simplify after inlining
9813         the above and remove more quadraticness.
9814         (build_scops): Adjust.
9815         * tree-data-ref.c (loop_nest_has_data_refs): Remove pointless
9816         quadraticness.
9818 2017-09-26  Jakub Jelinek  <jakub@redhat.com>
9820         PR target/82267
9821         * config/i386/i386.c (ix86_print_operand_address_as): Only test
9822         REGNO (base) == SP_REG if base is a REG.
9824         PR middle-end/35691
9825         * tree-ssa-reassoc.c (update_range_test): Dump r->exp each time
9826         if it is different SSA_NAME.
9827         (optimize_range_tests_cmp_bitwise): New function.
9828         (optimize_range_tests): Call it.
9830 2017-09-26  Richard Biener  <rguenther@suse.de>
9832         PR tree-optimization/82321
9833         * graphite.c (canonicalize_loop_closed_ssa): Properly check
9834         for the def being inside the loop.
9836 2017-09-26  Andreas Krebbel  <krebbel@linux.vnet.ibm.com>
9838         * config/s390/vx-builtins.md ("vmslg"): Add missing operand in
9839         assembler output.
9840         * config/s390/s390-builtins.def: Fix constraint on op4.
9842 2017-09-26  Andreas Krebbel  <krebbel@linux.vnet.ibm.com>
9844         * config/s390/s390.c (s390_expand_vec_compare): Use the new mode
9845         independent expanders.
9846         * config/s390/vector.md ("vec_cmpuneq", "vec_cmpltgt")
9847         ("vec_ordered", "vec_unordered"): New expanders.
9849 2017-09-26  Andreas Krebbel  <krebbel@linux.vnet.ibm.com>
9851         * config/s390/s390.c (s390_preferred_simd_mode): Return V4SFmode
9852         for SFmode.
9854 2017-09-26  Andreas Krebbel  <krebbel@linux.vnet.ibm.com>
9856         * config/s390/vector.md ("vec_unpacks_low_v16qi"): Rename to
9857         vec_unpacks_lo_v16qi.
9858         ("vec_unpacku_low_v16qi"): Rename to vec_unpacku_lo_v16qi.
9860 2017-09-26  Andreas Krebbel  <krebbel@linux.vnet.ibm.com>
9862         * config/s390/vector.md ("vec_unpacks_lo_v4sf")
9863         ("vec_unpacks_hi_v4sf", "vec_unpacks_lo_v2df")
9864         ("vec_unpacks_hi_v2df", "vec_pack_trunc_v2df"): New expanders.
9866 2017-09-26  Andreas Krebbel  <krebbel@linux.vnet.ibm.com>
9868         * config/s390/predicates.md ("const_shift_by_byte_operand"): New
9869         predicate.
9870         * config/s390/vector.md ("*vec_srb<mode>"): Change modes to V_128
9871         and V16QI.
9872         ("*vec_slb<mode>"): New insn pattern.
9873         ("vec_shr_<mode>"): New expander.
9874         * config/s390/vx-builtins.md ("vec_slb<mode>"): Turn into expander
9875         and force the shift count operand to V16QImode.
9876         ("vec_srb<mode>"): Set shift count mode to V16QI.
9878 2017-09-26  Andreas Krebbel  <krebbel@linux.vnet.ibm.com>
9880         * config/s390/vector.md ("vec_widen_umult_lo_<mode>")
9881         ("vec_widen_umult_hi_<mode>", "vec_widen_smult_lo_<mode>")
9882         ("vec_widen_smult_hi_<mode>"): New expander definitions.
9884 2017-09-26  Richard Earnshaw  <rearnsha@arm.com>
9886         PR target/82175
9887         * config/arm/arm.h (DRIVER_SELF_SPECS): Separate sub-rules with commas.
9889 2017-09-26  Richard Biener  <rguenther@suse.de>
9891         PR tree-optimization/82320
9892         * tree-ssa-sccvn.c (set_ssa_val_to): Changing undef to undef
9893         isn't a change.
9895 2017-09-25  Jeff Law  <law@redhat.com>
9897         * config/rs6000/rs6000-protos.h (output_probe_stack_range): Update
9898         prototype for new argument.
9899         * config/rs6000/rs6000.c (rs6000_emit_allocate_stack_1): New function,
9900         mostly extracted from rs6000_emit_allocate_stack.
9901         (rs6000_emit_probe_stack_range_stack_clash): New function.
9902         (rs6000_emit_allocate_stack): Call
9903         rs6000_emit_probe_stack_range_stack_clash as needed.
9904         (rs6000_emit_probe_stack_range): Add additional argument
9905         to call to gen_probe_stack_range{si,di}.
9906         (output_probe_stack_range): New.
9907         (output_probe_stack_range_1): Renamed from output_probe_stack_range.
9908         (output_probe_stack_range_stack_clash): New.
9909         (rs6000_emit_prologue): Emit notes into dump file as requested.
9910         * rs6000.md (allocate_stack): Handle -fstack-clash-protection.
9911         (probe_stack_range<P:mode>): Operand 0 is now early-clobbered.
9912         Add additional operand and pass it to output_probe_stack_range.
9914 2017-09-25  Bin Cheng  <bin.cheng@arm.com>
9916         PR tree-optimization/82163
9917         * tree-ssa-loop-manip.h (verify_loop_closed_ssa): New parameter.
9918         (checking_verify_loop_closed_ssa): New parameter.
9919         * tree-ssa-loop-manip.c (check_loop_closed_ssa_use): Delete.
9920         (check_loop_closed_ssa_stmt): Delete.
9921         (check_loop_closed_ssa_def, check_loop_closed_ssa_bb): New functions.
9922         (verify_loop_closed_ssa): Check loop closed ssa form for LOOP.
9923         (tree_transform_and_unroll_loop): Check loop closed ssa form only for
9924         changed loops.
9926 2017-09-25  Pekka Jaaskelainen <pekka@parmance.com>
9928         * brig-builtins.def: Treat HSAIL barrier builtins as
9929         setjmp/longjump style functions.
9931 2017-09-25  Richard Sandiford  <richard.sandiford@linaro.org>
9933         * target.def (constant_alignment): New hook.
9934         * defaults.h (CONSTANT_ALIGNMENT): Delete.
9935         * doc/tm.texi.in (CONSTANT_ALIGNMENT): Replace with...
9936         (TARGET_CONSTANT_ALIGNMENT): ...this new hook.
9937         * doc/tm.texi: Regenerate.
9938         * targhooks.h (default_constant_alignment): Declare.
9939         (constant_alignment_word_strings): Likewise.
9940         * targhooks.c (default_constant_alignment): New function.
9941         (constant_alignment_word_strings): Likewise.
9942         * builtins.c (get_object_alignment_2): Use targetm.constant_alignment
9943         instead of CONSTANT_ALIGNMENT.
9944         * varasm.c (align_variable, get_variable_align, build_constant_desc)
9945         (force_const_mem): Likewise.
9946         * config/aarch64/aarch64.h (CONSTANT_ALIGNMENT): Delete.
9947         * config/aarch64/aarch64.c (aarch64_constant_alignment): New function.
9948         (aarch64_classify_address): Call it instead of CONSTANT_ALIGNMENT.
9949         (TARGET_CONSTANT_ALIGNMENT): Redefine.
9950         * config/alpha/alpha.h (CONSTANT_ALIGNMENT): Delete commented-out
9951         definition.
9952         * config/arc/arc.h (CONSTANT_ALIGNMENT): Delete.
9953         * config/arc/arc.c (TARGET_CONSTANT_ALIGNMENT): Redefine to
9954         constant_alignment_word_strings.
9955         * config/arm/arm.h (CONSTANT_ALIGNMENT_FACTOR): Delete.
9956         (CONSTANT_ALIGNMENT): Likewise.
9957         * config/arm/arm.c (TARGET_CONSTANT_ALIGNMENT): Redefine.
9958         (arm_constant_alignment): New function.
9959         * config/bfin/bfin.h (CONSTANT_ALIGNMENT): Delete.
9960         * config/bfin/bfin.c (TARGET_CONSTANT_ALIGNMENT): Redefine to
9961         constant_alignment_word_strings.
9962         * config/cr16/cr16.h (CONSTANT_ALIGNMENT): Delete.
9963         * config/cr16/cr16.c (TARGET_CONSTANT_ALIGNMENT): Redefine to
9964         constant_alignment_word_strings.
9965         * config/cris/cris.h (CONSTANT_ALIGNMENT): Delete.
9966         * config/cris/cris.c (TARGET_CONSTANT_ALIGNMENT): Redefine.
9967         (cris_constant_alignment): New function.
9968         * config/epiphany/epiphany.h (CONSTANT_ALIGNMENT): Delete.
9969         * config/epiphany/epiphany.c (TARGET_CONSTANT_ALIGNMENT): Redefine.
9970         (epiphany_constant_alignment): New function.
9971         * config/fr30/fr30.h (CONSTANT_ALIGNMENT): Delete.
9972         * config/fr30/fr30.c (TARGET_CONSTANT_ALIGNMENT): Redefine to
9973         constant_alignment_word_strings.
9974         * config/frv/frv.h (CONSTANT_ALIGNMENT): Delete.
9975         * config/frv/frv.c (TARGET_CONSTANT_ALIGNMENT): Redefine to
9976         constant_alignment_word_strings.
9977         * config/ft32/ft32.h (CONSTANT_ALIGNMENT): Delete.
9978         * config/ft32/ft32.c (TARGET_CONSTANT_ALIGNMENT): Redefine to
9979         constant_alignment_word_strings.
9980         * config/i386/i386.h (CONSTANT_ALIGNMENT): Delete.
9981         * config/i386/i386-protos.h (ix86_constant_alignment): Delete.
9982         * config/i386/i386.c (ix86_constant_alignment): Make static.
9983         Use the same interface as the target hook.
9984         (TARGET_CONSTANT_ALIGNMENT): Redefine.
9985         * config/ia64/ia64.h (CONSTANT_ALIGNMENT): Delete.
9986         * config/ia64/ia64.c (TARGET_CONSTANT_ALIGNMENT): Redefine to
9987         constant_alignment_word_strings.
9988         * config/iq2000/iq2000.h (CONSTANT_ALIGNMENT): Delete.
9989         * config/iq2000/iq2000.c (iq2000_constant_alignment): New function.
9990         (TARGET_CONSTANT_ALIGNMENT): Redefine.
9991         * config/lm32/lm32.h (CONSTANT_ALIGNMENT): Delete.
9992         * config/lm32/lm32.c (TARGET_CONSTANT_ALIGNMENT): Redefine to
9993         constant_alignment_word_strings.
9994         * config/m32r/m32r.h (CONSTANT_ALIGNMENT): Delete.
9995         * config/m32r/m32r.c (TARGET_CONSTANT_ALIGNMENT): Redefine to
9996         constant_alignment_word_strings.
9997         * config/mcore/mcore.h (CONSTANT_ALIGNMENT): Delete.
9998         * config/mcore/mcore.c (TARGET_CONSTANT_ALIGNMENT): Redefine to
9999         constant_alignment_word_strings.
10000         * config/microblaze/microblaze.h (CONSTANT_ALIGNMENT): Delete.
10001         * config/microblaze/microblaze.c (microblaze_constant_alignment):
10002         New function.
10003         (TARGET_CONSTANT_ALIGNMENT): Redefine.
10004         * config/mips/mips.h (CONSTANT_ALIGNMENT): Delete.
10005         * config/mips/mips.c (mips_constant_alignment): New function.
10006         (TARGET_CONSTANT_ALIGNMENT): Redefine.
10007         * config/mmix/mmix.h (CONSTANT_ALIGNMENT): Delete.
10008         * config/mmix/mmix-protos.h (mmix_constant_alignment): Delete.
10009         * config/mmix/mmix.c (TARGET_CONSTANT_ALIGNMENT): Redefine.
10010         (mmix_constant_alignment): Make static.  Use the same interface
10011         as the target hook.
10012         * config/moxie/moxie.h (CONSTANT_ALIGNMENT): Delete.
10013         * config/moxie/moxie.c (TARGET_CONSTANT_ALIGNMENT): Redefine to
10014         constant_alignment_word_strings.
10015         * config/nios2/nios2.h (CONSTANT_ALIGNMENT): Delete.
10016         * config/nios2/nios2.c (TARGET_CONSTANT_ALIGNMENT): Redefine to
10017         constant_alignment_word_strings.
10018         * config/pa/pa.h (CONSTANT_ALIGNMENT): Delete.
10019         * config/pa/pa.c (TARGET_CONSTANT_ALIGNMENT): Redefine to
10020         constant_alignment_word_strings.
10021         * config/powerpcspe/powerpcspe.h (CONSTANT_ALIGNMENT): Delete.
10022         * config/powerpcspe/powerpcspe.c (TARGET_CONSTANT_ALIGNMENT): Redefine.
10023         (rs6000_constant_alignment): New function.
10024         * config/riscv/riscv.h (CONSTANT_ALIGNMENT): Delete.
10025         * config/riscv/riscv.c (riscv_constant_alignment): New function.
10026         (TARGET_CONSTANT_ALIGNMENT): Redefine.
10027         * config/rs6000/rs6000.h (CONSTANT_ALIGNMENT): Delete.
10028         * config/rs6000/rs6000.c (TARGET_CONSTANT_ALIGNMENT): Redefine.
10029         (rs6000_constant_alignment): New function.
10030         * config/s390/s390.h (CONSTANT_ALIGNMENT): Delete.
10031         * config/s390/s390.c (s390_constant_alignment): New function.
10032         (TARGET_CONSTANT_ALIGNMENT): Redefine.
10033         * config/sh/sh.h (CONSTANT_ALIGNMENT): Delete.
10034         * config/sh/sh.c (TARGET_CONSTANT_ALIGNMENT): Redefine to
10035         constant_alignment_word_strings.
10036         * config/sparc/sparc.h (CONSTANT_ALIGNMENT): Delete.
10037         * config/sparc/sparc.c (TARGET_CONSTANT_ALIGNMENT): Redefine.
10038         (sparc_constant_alignment): New function.
10039         * config/spu/spu.h (CONSTANT_ALIGNMENT): Delete.
10040         * config/spu/spu.c (spu_constant_alignment): New function.
10041         (TARGET_CONSTANT_ALIGNMENT): Redefine.
10042         * config/stormy16/stormy16.h (CONSTANT_ALIGNMENT): Delete.
10043         * config/stormy16/stormy16.c (TARGET_CONSTANT_ALIGNMENT): Redefine to
10044         constant_alignment_word_strings.
10045         * config/tilegx/tilegx.h (CONSTANT_ALIGNMENT): Delete.
10046         * config/tilegx/tilegx.c (TARGET_CONSTANT_ALIGNMENT): Redefine to
10047         constant_alignment_word_strings.
10048         * config/tilepro/tilepro.h (CONSTANT_ALIGNMENT): Delete.
10049         * config/tilepro/tilepro.c (TARGET_CONSTANT_ALIGNMENT): Redefine to
10050         constant_alignment_word_strings.
10051         * config/visium/visium.h (CONSTANT_ALIGNMENT): Delete.
10052         * config/visium/visium.c (TARGET_CONSTANT_ALIGNMENT): Redefine.
10053         (visium_constant_alignment): New function.
10054         * config/xtensa/xtensa.h (CONSTANT_ALIGNMENT): Delete.
10055         * config/xtensa/xtensa.c (TARGET_CONSTANT_ALIGNMENT): Redefine.
10056         (xtensa_constant_alignment): New function.
10057         * system.h (CONSTANT_ALIGNMENT): Poison.
10059 2017-09-25  Will Schmidt  <will_schmidt@vnet.ibm.com>
10061         * config/rs6000/rs6000.c (rs6000_gimple_fold_builtin): Add handling
10062         for early folding of vector stores (ALTIVEC_BUILTIN_ST_*).
10063         (rs6000_builtin_valid_without_lhs): New helper function.
10064         * config/rs6000/rs6000-c.c (altivec_resolve_overloaded_builtin):
10065         Remove obsoleted code for handling ALTIVEC_BUILTIN_VEC_ST.
10067 2017-09-25  Richard Sandiford  <richard.sandiford@linaro.org>
10069         * target.h (vec_perm_indices): Use unsigned short rather than
10070         unsigned char.
10071         (auto_vec_perm_indices): Likewise.
10072         * config/aarch64/aarch64.c (aarch64_vectorize_vec_perm_const_ok):
10073         Use unsigned int rather than unsigned char.
10074         * config/arm/arm.c (arm_vectorize_vec_perm_const_ok): Likewise.
10076 2017-09-25  Richard Biener  <rguenther@suse.de>
10078         * cfgloop.h (sort_sibling_loops): Declare.
10079         * cfgloop.c (sort_sibling_loops_cmp): New helper.
10080         (sort_sibling_loops): New function sorting the sibling loop list
10081         in RPO order.
10082         * graphite.c (graphite_transform_loops): Sort sibling loops.
10084 2017-09-25  Richard Sandiford  <richard.sandifird@linaro.org>
10086         * target.def (vec_perm_const_ok): Change sel parameter to
10087         vec_perm_indices.
10088         * optabs-query.c (can_vec_perm_p): Update accordingly.
10089         * doc/tm.texi: Regenerate.
10090         * config/aarch64/aarch64.c (expand_vec_perm_d): Change perm to
10091         auto_vec_perm_indices and remove separate nelt field.
10092         (aarch64_evpc_trn, aarch64_evpc_uzp, aarch64_evpc_zip)
10093         (aarch64_evpc_ext, aarch64_evpc_rev, aarch64_evpc_dup)
10094         (aarch64_evpc_tbl, aarch64_expand_vec_perm_const_1)
10095         (aarch64_expand_vec_perm_const): Update accordingly.
10096         (aarch64_vectorize_vec_perm_const_ok): Likewise.  Change sel
10097         to vec_perm_indices.
10098         * config/arm/arm.c (expand_vec_perm_d): Change perm to
10099         auto_vec_perm_indices and remove separate nelt field.
10100         (arm_evpc_neon_vuzp, arm_evpc_neon_vzip, arm_evpc_neon_vrev)
10101         (arm_evpc_neon_vtrn, arm_evpc_neon_vext, arm_evpc_neon_vtbl)
10102         (arm_expand_vec_perm_const_1, arm_expand_vec_perm_const): Update
10103         accordingly.
10104         (arm_vectorize_vec_perm_const_ok): Likewise.  Change sel
10105         to vec_perm_indices.
10106         * config/i386/i386.c (ix86_vectorize_vec_perm_const_ok): Change
10107         sel to vec_perm_indices.
10108         * config/ia64/ia64.c (ia64_vectorize_vec_perm_const_ok): Likewise.
10109         * config/mips/mips.c (mips_vectorize_vec_perm_const_ok): Likewise.
10110         * config/powerpcspe/powerpcspe.c (rs6000_vectorize_vec_perm_const_ok):
10111         Likewise.
10112         * config/rs6000/rs6000.c (rs6000_vectorize_vec_perm_const_ok):
10113         Likewise.
10115 2017-09-25  Pierre-Marie de Rodat  <derodat@adacore.com>
10117         PR debug/82155
10118         * dwarf2out.c (dwarf2out_early_global_decl): Call dwarf2out_decl
10119         on the FUNCTION_DECL function context if it has a DIE that is a
10120         declaration.
10122 2017-09-25  Richard Biener  <rguenther@suse.de>
10124         PR tree-optimization/82285
10125         * tree-vect-patterns.c (vect_recog_bool_pattern): Also handle
10126         enumeral types.
10128 2017-09-25  Tom de Vries  <tom@codesourcery.com>
10130         PR target/80035
10131         PR target/81069
10132         * config/nvptx/nvptx.c (nvptx_output_call_insn): Add exit after call to
10133         noreturn function.
10135 2017-09-25  Richard Biener  <rguenther@suse.de>
10137         * graphite-optimize-isl.c (optimize_isl): Fail and dump if
10138         ISL errors other than isl_error_quota happen.  Dump if the
10139         schedule is the same.
10140         * graphite-sese-to-poly.c (build_poly_scop): Fail on ISL
10141         errors instead of aborting inside ISL.
10143 2017-09-25  Iain Sandoe  <iain@codesourcery.com>
10145         PR target/80556
10146         * config/i386/darwin.h (REAL_LIB_SPEC): New; put libSystem ahead
10147         of libgcc_eh for m64.
10148         * config/i386/darwin64.h: Likewise.
10150 2017-09-25  Richard Biener  <rguenther@suse.de>
10152         PR middle-end/82144
10153         * dwarf2out.c (gen_enumeration_type_die): Do not add alignment
10154         attribute for incomplete types nor twice for complete ones.
10156 2017-09-24  Uros Bizjak  <ubizjak@gmail.com>
10158         PR target/82267
10159         * config/i386/i386.c (ix86_print_operand_address_as): Encode
10160         %esp as %rsp to avoid 0x67 prefix if there is no index or base
10161         register.
10163 2017-09-23  Uros Bizjak  <ubizjak@gmail.com>
10165         PR bootstrap/82306
10166         * config/i386/i386.opt (mprefer-avx256): Use
10167         ix86_target_flags variable.
10168         * config/i386/i386.c (ix86_target_string): Move
10169         -mprefer-avx256 to flag2_opts.
10171 2017-09-22  Jakub Jelinek  <jakub@redhat.com>
10173         PR middle-end/35691
10174         * match.pd: Simplify x == -1 & y == -1 into (x & y) == -1
10175         and x != -1 | y != -1 into (x & y) != -1.
10177 2017-09-22  Steve Ellcey  <sellcey@cavium.com>
10179         * config.gcc: Add new case statement to set
10180         default_gnu_indirect_function.  Remove it from x86_64-*-linux*,
10181         i[34567]86-*, powerpc*-*-linux*spe*, powerpc*-*-linux*, s390-*-linux*,
10182         s390x-*-linux* case statements.   Added aarch64 to the list of
10183         supported architectures.
10185 2017-09-22  Richard Sandiford  <richard.sandiford@linaro.org>
10187         PR tree-optimization/82289
10188         * tree-vect-data-refs.c (vect_get_peeling_costs_all_drs): Check
10189         STMT_VINFO_RELEVANT_P.
10191 2017-09-22  Richard Sandiford  <richard.sandiford@linaro.org>
10192             Alan Hayward  <alan.hayward@arm.com>
10193             David Sherwood  <david.sherwood@arm.com>
10195         * tree-vrp.c (extract_range_from_multiplicative_op_1): Assert
10196         for VR_RANGE only; don't allow VR_ANTI_RANGE.
10197         (extract_range_from_binary_expr_1): Don't call
10198         extract_range_from_multiplicative_op_1 if !range_int_cst_p.
10200 2017-09-22  Richard Sandiford  <richard.sandiford@linaro.org>
10201             Alan Hayward  <alan.hayward@arm.com>
10202             David Sherwood  <david.sherwood@arm.com>
10204         * target.def (preferred_vector_alignment): New hook.
10205         * doc/tm.texi.in (TARGET_VECTORIZE_PREFERRED_VECTOR_ALIGNMENT): New
10206         hook.
10207         * doc/tm.texi: Regenerate.
10208         * targhooks.h (default_preferred_vector_alignment): Declare.
10209         * targhooks.c (default_preferred_vector_alignment): New function.
10210         * tree-vectorizer.h (dataref_aux): Add a target_alignment field.
10211         Expand commentary.
10212         (DR_TARGET_ALIGNMENT): New macro.
10213         (aligned_access_p): Update commentary.
10214         (vect_known_alignment_in_bytes): New function.
10215         * tree-vect-data-refs.c (vect_calculate_required_alignment): New
10216         function.
10217         (vect_compute_data_ref_alignment): Set DR_TARGET_ALIGNMENT.
10218         Calculate the misalignment based on the target alignment rather than
10219         the vector size.
10220         (vect_update_misalignment_for_peel): Use DR_TARGET_ALIGMENT
10221         rather than TYPE_ALIGN / BITS_PER_UNIT to update the misalignment.
10222         (vect_enhance_data_refs_alignment): Mask the byte misalignment with
10223         the target alignment, rather than masking the element misalignment
10224         with the number of elements in a vector.  Also use the target
10225         alignment when calculating the maximum number of peels.
10226         (vect_find_same_alignment_drs): Use vect_calculate_required_alignment
10227         instead of TYPE_ALIGN_UNIT.
10228         (vect_duplicate_ssa_name_ptr_info): Remove stmt_info parameter.
10229         Measure DR_MISALIGNMENT relative to DR_TARGET_ALIGNMENT.
10230         (vect_create_addr_base_for_vector_ref): Update call accordingly.
10231         (vect_create_data_ref_ptr): Likewise.
10232         (vect_setup_realignment): Realign by ANDing with
10233         -DR_TARGET_MISALIGNMENT.
10234         * tree-vect-loop-manip.c (vect_gen_prolog_loop_niters): Calculate
10235         the number of peels based on DR_TARGET_ALIGNMENT.
10236         * tree-vect-stmts.c (get_group_load_store_type): Compare the gap
10237         with the guaranteed alignment boundary when deciding whether
10238         overrun is OK.
10239         (vectorizable_mask_load_store): Interpret DR_MISALIGNMENT
10240         relative to DR_TARGET_ALIGNMENT instead of TYPE_ALIGN_UNIT.
10241         (ensure_base_align): Remove stmt_info parameter.  Get the
10242         target base alignment from DR_TARGET_ALIGNMENT.
10243         (vectorizable_store): Update call accordingly.   Interpret
10244         DR_MISALIGNMENT relative to DR_TARGET_ALIGNMENT instead of
10245         TYPE_ALIGN_UNIT.
10246         (vectorizable_load): Likewise.
10248 2017-09-22  Richard Sandiford  <richard.sandiford@linaro.org>
10249             Alan Hayward  <alan.hayward@arm.com>
10250             David Sherwood  <david.sherwood@arm.com>
10252         * tree-vectorizer.h (vect_get_scalar_dr_size): New function.
10253         * tree-vect-data-refs.c (vect_update_misalignment_for_peel): Use it.
10254         (vect_enhance_data_refs_alignment): Likewise.
10256 2017-09-22  Richard Earnshaw  <richard.earnshaw@arm.com>
10258         * config/arm/parsecpu.awk (fatal): Note that we've encountered an
10259         error.  Only quit immediately if parsing is complete.
10260         (BEGIN): Initialize fatal_err and parse_done.
10261         (begin fpu, end fpu): Check number of arguments.
10262         (begin arch, end arch): Likewise.
10263         (begin cpu, end cpu): Likewise.
10264         (cname, tune for, tune flags, architecture, fpu, option): Likewise.
10265         (optalias): Likewise.
10267 2017-09-22  Richard Earnshaw  <richard.earnshaw@arm.com>
10269         * config.gcc (arm*-*-*): Don't add arm-isa.h to tm_p_file.
10270         * config/arm/arm-isa.h: Delete.  Move definitions to ...
10271         * arm-cpus.in: ... here.  Use new feature and fgroup values.
10272         * config/arm/arm.c (arm_option_override): Use lower case for feature
10273         bit names.
10274         * config/arm/arm.h (TARGET_HARD_FLOAT): Likewise.
10275         (TARGET_VFP3, TARGET_VFP5, TARGET_FMA): Likewise.
10276         * config/arm/parsecpu.awk (END): Add new command 'isa'.
10277         (isa_pfx): Delete.
10278         (print_isa_bits_for): New function.
10279         (gen_isa): New function.
10280         (gen_comm_data): Use print_isa_bits_for.
10281         (define feature): New keyword.
10282         (define fgroup): New keyword.
10283         * config/arm/t-arm (TM_H): Remove.
10284         (GTM_H): Add arm-isa.h.
10285         (arm-isa.h): Add rule to generate file.
10286         * common/config/arm/arm-common.c: (arm_canon_arch_option): Use lower
10287         case for feature bit names.
10289 2017-09-22  Richard Biener  <rguenther@suse.de>
10291         * graphite-isl-ast-to-gimple.c (graphite_verify): Inline into
10292         single caller.
10293         (graphite_regenerate_ast_isl): Do not reset SCEV.  Move debug
10294         print of no dependency loops ...
10295         * graphite.c (graphite_transform_loops): ... here.
10296         (canonicalize_loop_closed_ssa_form): Work from inner to outer
10297         loops.
10298         (same_close_phi_node, remove_duplicate_close_phi,
10299         make_close_phi_nodes_unique, defined_in_loop_p): Fold into ...
10300         (canonicalize_loop_closed_ssa): ... here and simplify.
10301         * graphite-optimize-isl.c: Include tree-vectorizer.h.
10302         (optimize_isl): Use dump_printf_loc to tell when we stopped
10303         optimizing because of an ISL timeout.
10305 2017-09-22  Richard Biener  <rguenther@suse.de>
10307         PR tree-optimization/82291
10308         * tree-if-conv.c (predicate_mem_writes): Make sure to
10309         remove writes in blocks predicated with false.
10311 2017-09-22  Richard Biener  <rguenther@suse.de>
10313         * sese.c: Include cfganal.h.
10314         (if_region_set_false_region): Remove.
10315         (create_if_region_on_edge): Likewise.
10316         (move_sese_in_condition): Re-implement without destroying
10317         dominators.
10319 2017-09-22  Richard Biener  <rguenther@suse.de>
10321         * graphite-isl-ast-to-gimple.c (translate_pending_phi_nodes):
10322         Verify both BBs contain loop PHI nodes before dispatching to
10323         copy_loop_phi_args.
10324         (graphite_regenerate_ast_isl): Do not recompute dominators,
10325         do not verify three times.  Restructure for clarity.
10326         * graphite-scop-detection.c (same_close_phi_node,
10327         remove_duplicate_close_phi, make_close_phi_nodes_unique,
10328         defined_in_loop_p, canonicalize_loop_closed_ssa,
10329         canonicalize_loop_closed_ssa_form): Simplify, remove excess
10330         checking and SSA rewrite, move to ...
10331         * graphite.c: ... here.  Include ssa.h and tree-ssa-loop-manip.h.
10332         (graphite_initialize): Do not pass in ctx, do not reset the
10333         SCEV cache, compute only dominators.
10334         (graphite_transform_loops): Allocate ISL ctx after
10335         graphite_initialize.  Call canonicalize_loop_closed_ssa_form.
10336         Maintain post-dominators only around build_scops.
10337         * sese.c (if_region_set_false_region): Make static.  Free
10338         and recompute dominators.
10339         (move_sese_in_condition): Assert we don't get called with
10340         post-dominators computed.
10341         * sese.h (if_region_set_false_region): Remove.
10343 2017-09-22  Sergey Shalnov  <sergey.shalnov@intel.com>
10345         * config/i386/sse.md ("mov<mode>_internal"): Use <sseinsnmode>
10346         mode attribute for TARGET_AVX512VL.
10348 2017-09-21  Sergey Shalnov  <sergey.shalnov@intel.com>
10350         * config/i386/i386.opt (mprefer-avx256): New option.
10351         * config/i386/i386.c (ix86_target_string): Add -mprefer-avx256
10352         to flag_opts.
10353         (ix86_preferred_simd_mode): Return 256-bit AVX modes
10354         for TARGET_PREFER_AVX256.
10355         * doc/invoke.texi (x86 Options): Document -mprefer-avx256.
10357 2017-09-21  Jeff Law  <law@redhat.com>
10359         * config/i386/i386.c (ix86_adjust_stack_and_probe_stack_clash):
10360         Fix dump output if the only stack space is for pushed registers.
10362 2017-09-21  Richard Sandiford  <richard.sandiford@linaro.org>
10364         * config/spu/spu.c (spu_sched_adjust_cost): Update after renaming
10365         of insn_cost.
10367 2017-09-21  Martin Sebor  <msebor@redhat.com>
10369         PR c/81882
10370         * doc/extend.texi (attribute ifunc): Avoid relying on ill-formed
10371         code (in C++) or code that triggers warnings.
10373 2017-09-21  Eric Botcazou  <ebotcazou@adacore.com>
10375         * stor-layout.c (bit_from_pos): Do not distribute the conversion.
10377 2017-09-21  Segher Boessenkool  <segher@kernel.crashing.org>
10379         * haifa-sched.c: Rename insn_cost to insn_sched_cost.
10380         * sched-rgn.c: Ditto.
10381         * sel-sched-ir.c: Ditto.
10383 2017-09-21  Alexander Monakov  <amonakov@ispras.ru>
10385         * toplev.h (set_random_seed): Adjust return type.
10386         * toplev.c (init_local_tick): Move eager initialization of random_seed
10387         to get_random_seed.  Adjust comment.
10388         (init_random_seed): Inline to get_random_seed, delete.
10389         (get_random_seed): Initialize random_seed lazily.
10390         (set_random_seed): Do not return previous value.
10391         (print_switch_value): Do not call get_random_seed.
10393 2017-09-21  Evgeny Kudryashov  <kudryashov@ispras.ru>
10395         * cgraph.c (delete_function_version): New, broken out from...
10396         (cgraph_node::delete_function_version): ...here.  Rename to
10397         cgraph_node::delete_function_version_by_decl.  Update all uses.
10398         (cgraph_node::remove): Call delete_function_version.
10400 2017-09-21  Jakub Jelinek  <jakub@redhat.com>
10402         PR sanitizer/81715
10403         * tree-inline.c (expand_call_inline): Emit clobber stmts for
10404         VAR_DECLs to which addressable non-volatile parameters are mapped
10405         and for id->retvar after the return value assignment.  Clear
10406         id->retval and id->retbnd after inlining.
10408 2017-09-21  Richard Biener  <rguenther@suse.de>
10410         PR tree-optimization/82276
10411         PR tree-optimization/82244
10412         * tree-vrp.c (build_assert_expr_for): Set
10413         SSA_NAME_OCCURS_IN_ABNORMAL_PHI if the variable we assert on
10414         has it set.
10415         (remove_range_assertions): Revert earlier change.
10417 2017-09-21  Wilco Dijkstra  <wdijkstr@arm.com>
10419         PR target/71951
10420         * config/aarch64/aarch64.h (LIBGCC2_UNWIND_ATTRIBUTE): Define.
10422 2017-09-21  Richard Biener  <rguenther@suse.de>
10424         * graphite-isl-ast-to-gimple.c (graphite_regenerate_ast_isl):
10425         Restore valid IL after code generation errors.
10426         * graphite.c (graphite_transform_loops): Diagnose code
10427         generation issues as MSG_MISSED_OPTIMIZATION and continue
10428         with processing SCOPs.
10430 2017-09-21  Richard Sandiford  <richard.sandiford@linaro.org>
10431             Alan Hayward  <alan.hayward@arm.com>
10432             David Sherwood  <david.sherwood@arm.com>
10434         * calls.c (compute_argument_addresses): Use simplify_gen_binary
10435         rather than choosing between plus_constant and gen_rtx_<CODE>.
10436         * expr.c (emit_push_insn): Likewise.
10437         (expand_expr_real_2): Likewise.
10439 2017-09-21  Richard Sandiford  <richard.sandiford@linaro.org>
10440             Alan Hayward  <alan.hayward@arm.com>
10441             David Sherwood  <david.sherwood@arm.com>
10443         * loop-unroll.c (split_iv): Call copy_rtx on the step.
10445 2017-09-21  Richard Sandiford  <richard.sandiford@linaro.org>
10446             Alan Hayward  <alan.hayward@arm.com>
10447             David Sherwood  <david.sherwood@arm.com>
10449         * tree.c (find_atomic_core_type): Check tree_fits_uhwi_p before
10450         calling tree_to_uhwi.
10452 2017-09-21  Richard Sandiford  <richard.sandiford@linaro.org>
10453             Alan Hayward  <alan.hayward@arm.com>
10454             David Sherwood  <david.sherwood@arm.com>
10456         * tree-ssa-ccp.c (get_value_for_expr): Use a positive test for
10457         INTEGER_CST rather than a negative test for ADDR_EXPR.
10459 2017-09-21  Richard Sandiford  <richard.sandiford@linaro.org>
10460             Alan Hayward  <alan.hayward@arm.com>
10461             David Sherwood  <david.sherwood@arm.com>
10463         * tree-vrp.c (extract_range_from_binary_expr_1): Check
10464         int_cst_rangeN before calling value_range_constant_singleton (&vrN).
10466 2017-09-21  Richard Biener  <rguenther@suse.de>
10468         PR tree-optimization/71351
10469         * graphite-isl-ast-to-gimple.c (translate_isl_ast_to_gimple::
10470         graphite_create_new_loop_guard): Remove, fold remaining parts
10471         into caller ...
10472         (translate_isl_ast_node_for): ... here and simplify.
10474 2017-09-21  Jakub Jelinek  <jakub@redhat.com>
10476         PR target/82260
10477         * config/i386/i386.md (*movqi_internal): Replace (=q,q) alternative
10478         with (=Q,Q), (=R,R) and (=r,r) alternatives, only enable the
10479         latter two for 64-bit, renumber alternatives, for -Os imov (=q,n)
10480         alternative always use QI mode, for -Os imov (=R,R) alternative
10481         always use SI mode, for imov (=Q,Q) or (=r,r) alternatives
10482         ignore -Os.
10484 2017-09-20  Andreas Krebbel  <krebbel@linux.vnet.ibm.com>
10485             Jeff Law  <law@redhat.com>
10487         * config/s390/s390.c (MIN_UNROLL_PROBES): Define.
10488         (allocate_stack_space): New function, partially extracted from
10489         s390_emit_prologue.
10490         (s390_emit_prologue): Track offset to most recent stack probe.
10491         Code to allocate space moved into allocate_stack_space.
10492         Dump actions when no stack is allocated.
10493         (s390_prologue_plus_offset): New function.
10494         (s390_emit_stack_probe): Likewise.
10496 2017-09-20  Alexandre Oliva <aoliva@redhat.com>
10498         * common.opt (Wa, Wl, Wp, g, gz=): Add
10499         RejectNegative.
10500         (gno-column-info): Remove.
10501         (gcolumn-info): Drop RejectNegative.
10502         (gno-): New prefix.
10503         (gno-record-gcc-switches): Remove.
10504         (grecord-gcc-switches): Drop RejectNegative.
10505         (gno-split-dwarf): Remove.
10506         (gsplit-dwarf): Drop RejectNegative.
10507         (gno-strict-dwarf): Remove.
10508         (gstrict-dwarf): Drop RejectNegative.
10509         * config/darwin.opt (gfull, gused): Add RejectNegative.
10510         * dwarf2out.c (gen_producer_string): Drop
10511         gno-record-gcc-switches handler.
10512         * optc-gen.awk: Add g to prefixes with negative forms.
10513         * opts-common.c (remapping_prefix_p): New.
10514         (find_opt): Check it.
10515         (generate_canonical_option): Test g prefix.
10516         (option_map): Add -gno- mapping.
10517         (add_misspelling_candidates): Check remapping_prefix_p.
10519 2017-09-20  Jeff Law  <law@redhat.com>
10521         * config/powerpcspe/powerpcspe.c (rs6000_expand_prologue): Fix
10522         thinko in stack clash protection support.
10524         * explow.c (compute_stack_clash_protection_loop_data): Use
10525         CONST_INT_P instead of explicit test.  Verify object is a
10526         CONST_INT_P before looking at INTVAL.
10527         (anti_adjust_stack_and_probe_stack_clash): Use CONST_INT_P
10528         instead of explicit test.
10530 2017-09-20  Segher Boessenkool  <segher@kernel.crashing.org>
10532         PR target/77687
10533         * config/rs6000/rs6000.md (stack_restore_tie): Store to a scratch
10534         address instead of to r1 and r11.
10536 2017-09-20  Sebastian Peryt  <sebastian.peryt@intel.com>
10538         * config.gcc: Support "knm".
10539         * config/i386/driver-i386.c (host_detect_local_cpu): Detect "knm".
10540         * config/i386/i386-c.c (ix86_target_macros_internal): Handle
10541         PROCESSOR_KNM.
10542         * config/i386/i386.c (m_KNM): Define.
10543         (processor_target_table): Add "knm".
10544         (PTA_KNM): Define.
10545         (ix86_option_override_internal): Add "knm".
10546         (ix86_issue_rate): Add PROCESSOR_KNM.
10547         (ix86_adjust_cost): Ditto.
10548         (ia32_multipass_dfa_lookahead): Ditto.
10549         (get_builtin_code_for_version): Handle PROCESSOR_KNM.
10550         (fold_builtin_cpu): Add M_INTEL_KNM.
10551         * config/i386/i386.h (processor_costs): Define TARGET_KNM.
10552         (processor_type): Add PROCESSOR_KNM.
10553         * config/i386/x86-tune.def: Add m_KNM.
10554         * doc/invoke.texi: Add knm as x86 -march=/-mtune= CPU type.
10556 2017-09-20  Richard Biener  <rguenther@suse.de>
10558         PR tree-optimization/80213
10559         * graphite-scop-detection.c (trivially_empty_bb_p): Labels
10560         are allowed in empty BBs as well.
10561         (canonicalize_loop_closed_ssa): Also look for other complex
10562         edges.
10563         (scop_detection::get_sese): Include the loop-closed PHI block
10564         in loop SESEs.
10565         (scop_detection::merge_sese): Remove code adding extra blocks.
10566         (scop_detection::region_has_one_loop): Adjust for get_sese changes.
10567         (build_scops): Assert the final returned scop is invalid.
10569 2017-09-20  Richard Biener  <rguenther@suse.de>
10571         PR tree-optimization/82264
10572         * tree-ssa-sccvn.c (vn_phi_eq): Use safe_dyn_cast to check
10573         for GIMPLE_CONDs.
10574         (vn_phi_lookup): Likewise.
10575         (vn_phi_insert): Likewise.
10577 2017-09-20  Jakub Jelinek  <jakub@redhat.com>
10579         * dwarf2out.c (tree_add_const_value_attribute): For INTEGER_CST
10580         that fits into uhwi or shwi, add DW_AT_const_value regardless
10581         of early_dwarf without going through RTL, using add_AT_unsigned
10582         or add_AT_int.
10584         * dwarf2out.c (DEBUG_LTO_DWO_INFO_SECTION): Reorder defines.
10585         (DEBUG_LTO_ABBREV_SECTION): Likewise.
10586         (DEBUG_LTO_MACINFO_SECTION): Likewise.
10587         (DEBUG_MACRO_SECTION): Likewise.
10588         (DEBUG_LTO_MACRO_SECTION): Likewise.
10589         (DEBUG_STR_DWO_SECTION): Likewise.
10590         (DEBUG_LTO_STR_DWO_SECTION): Likewise.
10591         (DEBUG_LTO_LINE_SECTION): Drop .dwo suffix from the name.
10592         (DEBUG_LTO_DWO_LINE_SECTION): Define.
10593         (DEBUG_LTO_LINE_STR_SECTION): Define.
10594         (init_sections_and_labels): Initialize debug_line_str_section
10595         variable.  Initialize debug_loc_section for -gdwarf-5 to
10596         DEBUG_LOCLISTS_SECTION.  Formatting fixes.
10598 2017-09-20  Richard Biener  <rguenther@suse.de>
10600         * graphite-sese-to-poly.c (extract_affine): Properly handle
10601         POINTER_PLUS_EXPR, BIT_NOT_EXPR and conversion to signed.
10603 2017-09-20  Richard Biener  <rguenther@suse.de>
10605         PR tree-optimization/81373
10606         * graphite-scop-detection.c (build_cross_bb_scalars_def):
10607         Force SESE live-out defs to be handled even if they are
10608         scev_analyzable_p.
10610 2017-09-19  Jeff Law  <law@redhat.com>
10612         * combine-stack-adj.c (combine_stack_adjustments_for_block): Do
10613         nothing for stack adjustments with REG_STACK_CHECK.
10614         * sched-deps.c (parse_add_or_inc): Reject insns with
10615         REG_STACK_CHECK from dependency breaking.
10616         * config/i386/i386.c (pro_epilogue_adjust_stack): Return insn.
10617         (ix86_adjust_satck_and_probe_stack_clash): Add REG_STACK_NOTEs.
10618         * reg-notes.def (STACK_CHECK): New note.
10620         * config/i386/i386.c (ix86_adjust_stack_and_probe_stack_clash): New.
10621         (ix86_expand_prologue): Dump stack clash info as needed.
10622         Call ix86_adjust_stack_and_probe_stack_clash as needed.
10624         * function.c (dump_stack_clash_frame_info): New function.
10625         * function.h (dump_stack_clash_frame_info): Prototype.
10626         (enum stack_clash_probes): New enum.
10628         * config/alpha/alpha.c (alpha_expand_prologue): Also check
10629         flag_stack_clash_protection.
10630         * config/arm/arm.c (arm_compute_static_chain_stack_bytes): Likewise.
10631         (arm_expand_prologue, thumb1_expand_prologue): Likewise.
10632         (arm_frame_pointer_required): Likewise.
10633         * config/ia64/ia64.c (ia64_compute_frame_size): Likewise.
10634         (ia64_expand_prologue): Likewise.
10635         * config/mips/mips.c (mips_expand_prologue): Likewise.
10636         * config/powerpcspe/powerpcspe.c (rs6000_expand_prologue): Likewise.
10637         * config/sparc/sparc.c (sparc_expand_prologue): Likewise.
10638         (sparc_flat_expand_prologue): Likewise.
10639         * config/spu/spu.c (spu_expand_prologue): Likewise.
10641         * explow.c: Include "params.h".
10642         (anti_adjust_stack_and_probe_stack_clash): New function.
10643         (get_stack_check_protect): Likewise.
10644         (compute_stack_clash_protection_loop_data): Likewise.
10645         (emit_stack_clash_protection_loop_start): Likewise.
10646         (emit_stack_clash_protection_loop_end): Likewise.
10647         (allocate_dynamic_stack_space): Use get_stack_check_protect.
10648         Use anti_adjust_stack_and_probe_stack_clash.
10649         * explow.h (compute_stack_clash_protection_loop_data): Prototype.
10650         (emit_stack_clash_protection_loop_start): Likewise.
10651         (emit_stack_clash_protection_loop_end): Likewise.
10652         * rtl.h (get_stack_check_protect): Prototype.
10653         * target.def (stack_clash_protection_final_dynamic_probe): New hook.
10654         * targhooks.c (default_stack_clash_protection_final_dynamic_probe): New.
10655         * targhooks.h (default_stack_clash_protection_final_dynamic_probe):
10656         Prototype.
10657         * doc/tm.texi.in (TARGET_STACK_CLASH_PROTECTION_FINAL_DYNAMIC_PROBE):
10658         Add @hook.
10659         * doc/tm.texi: Rebuilt.
10660         * config/aarch64/aarch64.c (aarch64_expand_prologue): Use
10661         get_stack_check_protect.
10662         * config/alpha/alpha.c (alpha_expand_prologue): Likewise.
10663         * config/arm/arm.c (arm_expand_prologue): Likewise.
10664         (arm_frame_pointer_required): Likewise.
10665         * config/i386/i386.c (ix86_expand_prologue): Likewise.
10666         * config/ia64/ia64.c (ia64_expand_prologue): Likewise.
10667         * config/mips/mips.c (mips_expand_prologue): Likewise.
10668         * config/powerpcspe/powerpcspe.c (rs6000_emit_prologue): Likewise.
10669         * config/rs6000/rs6000.c (rs6000_emit_prologue): Likewise.
10670         * config/sparc/sparc.c (sparc_expand_prologue): Likewise.
10671         (sparc_flat_expand_prologue): Likewise.
10673         * common.opt (-fstack-clash-protection): New option.
10674         * flag-types.h (enum stack_check_type): Note difference between
10675         -fstack-check= and -fstack-clash-protection.
10676         * params.def (PARAM_STACK_CLASH_PROTECTION_GUARD_SIZE): New PARAM.
10677         (PARAM_STACK_CLASH_PROTECTION_PROBE_INTERVAL): Likewise.
10678         * toplev.c (process_options): Issue warnings/errors for cases
10679         not handled with -fstack-clash-protection.
10680         * doc/invoke.texi (-fstack-clash-protection): Document new option.
10681         (-fstack-check): Note additional problem with -fstack-check=generic.
10682         Note that -fstack-check is primarily for Ada and refer users
10683         to -fstack-clash-protection for stack-clash-protection.
10684         Document new params for stack clash protection.
10686 2017-09-19  Uros Bizjak  <ubizjak@gmail.com>
10688         * config/i386/i386.c (ix86_split_long_move): Do not handle
10689         address used for LEA in a special way.
10691 2017-09-19  Segher Boessenkool  <segher@kernel.crashing.org>
10693         * simplify-rtx.c (simplify_binary_operation_1): Fix typo in comment.
10695 2017-09-19  Martin Sebor  <msebor@redhat.com>
10697         PR c/81854
10698         * cgraphunit.c (handle_alias_pairs): Reject aliases between functions
10699         of incompatible types.
10701 2017-09-19  Will Schmidt  <will_schmidt@vnet.ibm.com>
10703         * config/rs6000/rs6000.c (rs6000_gimple_fold_builtin): Add handling
10704         for early folding of vector loads (ALTIVEC_BUILTIN_LVX_*).
10705         * config/rs6000/rs6000-c.c (altivec_resolve_overloaded_builtin):
10706         Remove obsoleted code for handling ALTIVEC_BUILTIN_VEC_LD.
10708 2017-09-19  Richard Biener  <rguenther@suse.de>
10710         PR tree-optimization/82244
10711         * tree-vrp.c (remove_range_assertions): Do not propagate
10712         a constant to abnormals but replace the assert with a copy.
10714 2017-09-19  Alexander Monakov  <amonakov@ispras.ru>
10716         PR rtl-optimization/57878
10717         PR rtl-optimization/68988
10718         * lra-assigns.c (reload_pseudo_compare_func): Remove fragmentation
10719         avoidance test involving non_reload_pseudos.  Move frequency test
10720         below the general fragmentation avoidance test.
10722 2017-09-19  Richard Biener  <rguenther@suse.de>
10724         PR tree-optimization/69728
10725         * graphite-sese-to-poly.c (schedule_error): New global.
10726         (add_loop_schedule): Handle empty domain by failing the
10727         schedule.
10728         (build_original_schedule): Handle schedule_error.
10730 2017-09-19  Richard Biener  <rguenther@suse.de>
10732         * graphite-scop-detection.c (scop_detection::can_represent_loop):
10733         Do not iterate to sibling loops but only to siblings of inner
10734         loops.
10736 2017-09-18  Andreas Schwab  <schwab@linux-m68k.org>
10738         PR target/81613
10739         * config/m68k/m68k.md (moveq feeding equality comparison): Check
10740         that the registers are different.
10742 2017-09-18  Uros Bizjak  <ubizjak@gmail.com>
10744         * config/i386/i386.c (fold_builtin_cpu): Add M_AMDFAM17H
10745         to processor_model and "amdfam17h" to arch_names_table.
10746         * doc/extend.texi (__builtin_cpu_is): Document amdfam17h CPU name.
10748 2017-09-18  Jakub Jelinek  <jakub@redhat.com>
10750         PR c/82234
10751         * doc/extend.texi: Add @findex entry for __builtin_shuffle.
10753 2017-09-18  Richard Sandiford  <richard.sandiford@linaro.org>
10754             Alan Hayward  <alan.hayward@arm.com>
10755             David Sherwood  <david.sherwood@arm.com>
10757         * tree-vectorizer.h (vect_slp_analyze_operations): Replace parameters
10758         with a vec_info *.
10759         * tree-vect-loop.c (vect_analyze_loop_operations): Update call
10760         accordingly.
10761         * tree-vect-slp.c (vect_slp_analyze_node_operations): Add vec_info *
10762         parameter.  Set SLP_TREE_NUMBER_OF_VEC_STMTS here rather than in
10763         vect_schedule_slp_instance.
10764         (vect_slp_analyze_operations): Replace parameters with a vec_info *.
10765         Update call to vect_slp_analyze_node_operations.  Simplify return
10766         value.
10767         (vect_slp_analyze_bb_1): Update call accordingly.
10768         (vect_schedule_slp_instance): Remove vectorization_factor parameter.
10769         Don't calculate SLP_TREE_NUMBER_OF_VEC_STMTS here.
10770         (vect_schedule_slp): Update call accordingly.
10772 2017-09-18  Richard Sandiford  <richard.sandiford@linaro.org>
10773             Alan Hayward  <alan.hayward@arm.com>
10774             David Sherwood  <david.sherwood@arm.com>
10776         * tree-vect-data-refs.c (vect_get_smallest_scalar_type): Cope
10777         with types that aren't in fact scalar.
10779 2017-09-18  Richard Sandiford  <richard.sandiford@linaro.org>
10781         * tree-vect-slp.c (vect_record_max_nunits): New function,
10782         split out from...
10783         (vect_build_slp_tree_1): ...here.
10784         (vect_build_slp_tree_2): Call it for phis too.
10786 2017-09-18  Richard Sandiford  <richard.sandiford@linaro.org>
10788         * tree-vect-stmts.c (vectorizable_mask_load_store): Pass mask_vectype
10789         to vect_get_vec_def_for_operand when getting the mask operand.
10791 2017-09-18  Richard Sandiford  <richard.sandiford@linaro.org>
10792             Alan Hayward  <alan.hayward@arm.com>
10793             David Sherwood  <david.sherwood@arm.com>
10795         * tree-vect-loop.c (vectorizable_live_operation): Fix type of
10796         bitstart.
10798 2017-09-18  Richard Sandiford  <richard.sandiford@linaro.org>
10799             Alan Hayward  <alan.hayward@arm.com>
10800             David Sherwood  <david.sherwood@arm.com>
10802         * tree-vect-loop.c (vectorizable_live_operation): Fix element size
10803         calculation for vector booleans.
10805 2017-09-18  Richard Sandiford  <richard.sandiford@linaro.org>
10806             Alan Hayward  <alan.hayward@arm.com>
10807             David Sherwood  <david.sherwood@arm.com>
10809         * tree-vect-stmts.c (can_vectorize_live_stmts): New function,
10810         split out from...
10811         (vect_transform_stmt): ...here.
10812         (vect_analyze_stmt): Use it instead of calling
10813         vectorizable_live_operation directly.
10815 2017-09-18  Cesar Philippidis  <cesar@codesourcery.com>
10817         * omp-offload.c (oacc_xform_loop): Enable SIMD vectorization on
10818         non-SIMT targets in acc vector loops.
10820 2017-09-18  Claudiu Zissulescu  <claziss@synopsys.com>
10822         * configure.ac: Add arc and check if assembler supports gdwarf2.
10823         * configure: Regenerate.
10825 2017-09-18  Richard Biener  <rguenther@suse.de>
10827         PR tree-optimization/82220
10828         * tree-vect-loop.c (vect_estimate_min_profitable_iters): Exclude
10829         epilogue niters from the min_profitable_iters compute.
10831 2017-09-18  Jakub Jelinek  <jakub@redhat.com>
10833         PR target/82145
10834         * config/i386/i386.c (ix86_init_large_pic_reg): Revert 2017-09-01
10835         changes.  Turn CODE_LABEL into NOTE_INSN_DELETED_LABEL immediately.
10836         (ix86_init_pic_reg): Revert 2017-09-01 changes.
10838 2017-09-18  Eric Botcazou  <ebotcazou@adacore.com>
10840         PR target/81361
10841         * dwarf2cfi.c (add_cfis_to_fde): Do not generate DW_CFA_set_loc after
10842         switching to a new text section.
10844 2017-09-18  Richard Biener  <rguenther@suse.de>
10846         * graphite-scop-detection.c (scop_detection::stmt_has_simple_data_ref):
10847         Simplify.
10848         (build_alias_set): Reject aliases with no access function.
10850 2017-09-18  Richard Biener  <rguenther@suse.de>
10852         PR tree-optimization/79622
10853         * graphite-scop-detection.c (build_cross_bb_scalars_def): Properly
10854         handle PHIs.
10855         (build_cross_bb_scalars_use): Likewise.
10857 2017-09-18  Pierre-Marie de Rodat  <derodat@adacore.com>
10859         * cgraph.h (cgraph_thunk_info): Fix a typo in a comment.
10861 2017-09-18  Alan Modra  <amodra@gmail.com>
10863         PR target/81996
10864         * gcc/config/rs6000/rs6000.c (rs6000_return_addr): Use
10865         stack_pointer_rtx for count 0.  Update comments.  Break up
10866         large rtl expression.
10868 2017-09-17  Daniel Santos  <daniel.santos@pobox.com>
10870         * config/i386/i386.c (xlogue_layout::STUB_NAME_MAX_LEN):
10871         Increase to 20 bytes.
10872         (xlogue_layout::s_stub_names): Add an additional size-2 diminsion.
10873         (xlogue_layout::get_stub_name): Modify to select the appropairate sse
10874         or avx version of the stub.
10876 2017-09-17  H.J. Lu  <hongjiu.lu@intel.com>
10878         PR target/82166
10879         * config/i386/i386.c (ix86_finalize_stack_frame_flags): Properly
10880         compute the minimum stack alignment.  Also update preferred stack
10881         boundary for leaf functions.
10883 2017-09-16  Richard Sandiford  <richard.sandiford@linaro.org>
10885         PR tree-optimization/82228
10886         * tree-vect-loop.c (vectorizable_live_operation): Move initialization
10887         of ncopies.
10889 2017-09-16  Chung-Ju Wu  <jasonwucj@gmail.com>
10891         * common/config/nds32/nds32-common.c
10892         (nds32_option_optimization_table): Refine formatting.
10893         (nds32_option_optimization_table): Use -fsched-pressure and
10894         -fomit-frame-pointer for specific optimization level.
10896 2017-09-16  Chung-Ju Wu  <jasonwucj@gmail.com>
10898         * config/nds32/nds32.c: Refine formatting and comments.
10899         * config/nds32/nds32.h: Likewise.
10900         * config/nds32/nds32.md: Likewise.
10901         * config/nds32/nds32-cost.c: Likewise.
10902         * config/nds32/nds32-isr.c: Likewise.
10903         * config/nds32/nds32-md-auxiliary.c: Likewise.
10904         * config/nds32/nds32-multiple.md: Likewise.
10905         * config/nds32/nds32-predicates.c: Likewise.
10907 2017-09-15  Andrew Sutton  <andrew.n.sutton@gmail.com>
10908             Jakub Jelinek  <jakub@redhat.com>
10910         Add support for -std=c++2a.
10911         * doc/cpp.texi (__cplusplus): Document value for -std=c++2a
10912         or -std=gnu+2a.
10913         * doc/invoke.texi: Document -std=c++2a and -std=gnu++2a.
10915 2017-09-15  Steve Ellcey  <sellcey@cavium.com>
10917         PR target/82066
10918         * doc/extend.texi (Common Function Attributes): Add 
10919         references to ARM, AArch64, and S/390 specific attributes.
10920         (Function Specific Option Pragmas): Add AArch64 and S/390
10921         to list of back ends that support the target pragma.
10923 2017-09-15  Nathan Sidwell  <nathan@acm.org>
10925         * doc/standards.texi: Fix C++17 description.  Update URLs for
10926         C++11 & 14.
10928 2017-09-15  Bernd Edlinger  <bernd.edlinger@hotmail.de>
10930         * common.opt (Wcast-align=strict): New warning option.
10931         * doc/invoke.texi: Document -Wcast-align=strict. 
10933 2017-09-15  Pierre-Marie de Rodat  <derodat@adacore.com>
10935         * cgraph.h (cgraph_thunk_info): Add comments.
10936         * cgraph.c (cgraph_node::create_thunk): Adjust comment, make
10937         assert for VIRTUAL_* arguments stricter.
10939 2017-09-15  Jackson Woodruff  <jackson.woodruff@arm.com>
10941         PR tree-optimization/71026
10942         * match.pd: Move RDIV patterns from fold-const.c
10943         * fold-const.c (distribute_real_division): Removed.
10944         (fold_binary_loc): Remove calls to distribute_real_divison.
10946 2017-09-15  Jakub Jelinek  <jakub@redhat.com>
10948         * doc/invoke.texi: Document -std=c++17 and -std=gnu++17 and document
10949         c++1z and gnu++1z as deprecated.  Change other references to
10950         -std=c++1z to -std=c++17 and -std=gnu++1z to -std=gnu++17.
10951         Change -Wc++1z-compat to -Wc++17-compat.
10952         * doc/cpp.texi: Document -std=c++17 defines __cplusplus 201703L.
10953         * dwarf2out.c (highest_c_language): Handle C++17.
10954         (gen_compile_unit_die): Likewise.
10956 2017-09-15  Jakub Jelinek  <jakub@redhat.com>
10958         PR rtl-optimization/82192
10959         * combine.c (make_extraction): Don't look through non-paradoxical
10960         SUBREGs or TRUNCATE if pos + len is or might be bigger than
10961         inner's mode.
10963 2017-09-15  Richard Sandiford  <richard.sandiford@linaro.org>
10964             Alan Hayward  <alan.hayward@arm.com>
10965             David Sherwood  <david.sherwood@arm.com>
10967         * target.def (function_arg_offset): New hook.
10968         * targhooks.h (default_function_arg_offset): Declare.
10969         * targhooks.c (default_function_arg_offset): New function.
10970         * function.c (locate_and_pad_parm): Use
10971         targetm.calls.function_arg_offset instead of FUNCTION_ARG_OFFSET.
10972         * doc/tm.texi.in (FUNCTION_ARG_OFFSET): Replace with...
10973         (TARGET_FUNCTION_ARG_OFFSET): ...this.
10974         * doc/tm.texi: Regenerate.
10975         * config/spu/spu.h (FUNCTION_ARG_OFFSET): Delete.
10976         * config/spu/spu.c (spu_function_arg_offset): New function.
10977         (TARGET_FUNCTION_ARG_OFFSET): Redefine.
10978         * system.h (FUNCTION_ARG_OFFSET): Poison.
10980 2017-09-15  Richard Sandiford  <richard.sandiford@linaro.org>
10981             Alan Hayard  <alan.hayward@arm.com>
10982             David Sherwood  <david.sherwood@arm.com>
10984         * target.def (truly_noop_truncation): New hook.
10985         (mode_rep_extended): Refer to TARGET_TRULY_NOOP_TRUNCATION rather
10986         than TRULY_NOOP_TRUNCATION.
10987         * hooks.h (hook_bool_uint_uint_true): Declare.
10988         * hooks.c (hook_bool_uint_uint_true): New function.
10989         * doc/tm.texi.in (TRULY_NOOP_TRUNCATION): Replace with...
10990         (TARGET_TRULY_NOOP_TRUNCATION): ...this.
10991         * doc/tm.texi: Regenerate.
10992         * combine.c (make_extraction): Refer to TARGET_TRULY_NOOP_TRUNCATION
10993         rather than TRULY_NOOP_TRUNCATION in comments.
10994         (simplify_comparison): Likewise.
10995         (record_truncated_value): Likewise.
10996         * expmed.c (extract_bit_field_1): Likewise.
10997         (extract_split_bit_field): Likewise.
10998         * convert.c (convert_to_integer_1): Use targetm.truly_noop_truncation
10999         instead of TRULY_NOOP_TRUNCATION.
11000         * function.c (assign_parm_setup_block): Likewise.
11001         * machmode.h (TRULY_NOOP_TRUNCATION_MODES_P): Likewise.
11002         * rtlhooks.c: Include target.h.
11003         * config/aarch64/aarch64.h (TRULY_NOOP_TRUNCATION): Delete.
11004         * config/alpha/alpha.h (TRULY_NOOP_TRUNCATION): Delete.
11005         * config/arc/arc.h (TRULY_NOOP_TRUNCATION): Delete.
11006         * config/arm/arm.h (TRULY_NOOP_TRUNCATION): Delete.
11007         * config/avr/avr.h (TRULY_NOOP_TRUNCATION): Delete.
11008         * config/bfin/bfin.h (TRULY_NOOP_TRUNCATION): Delete.
11009         * config/c6x/c6x.h (TRULY_NOOP_TRUNCATION): Delete.
11010         * config/cr16/cr16.h (TRULY_NOOP_TRUNCATION): Delete.
11011         * config/cris/cris.h (TRULY_NOOP_TRUNCATION): Delete.
11012         * config/epiphany/epiphany.h (TRULY_NOOP_TRUNCATION): Delete.
11013         * config/fr30/fr30.h (TRULY_NOOP_TRUNCATION): Delete.
11014         * config/frv/frv.h (TRULY_NOOP_TRUNCATION): Delete.
11015         * config/ft32/ft32.h (TRULY_NOOP_TRUNCATION): Delete.
11016         * config/h8300/h8300.h (TRULY_NOOP_TRUNCATION): Delete.
11017         * config/i386/i386.h (TRULY_NOOP_TRUNCATION): Delete.
11018         * config/ia64/ia64.h (TRULY_NOOP_TRUNCATION): Delete.
11019         * config/iq2000/iq2000.h (TRULY_NOOP_TRUNCATION): Delete.
11020         * config/lm32/lm32.h (TRULY_NOOP_TRUNCATION): Delete.
11021         * config/m32c/m32c.h (TRULY_NOOP_TRUNCATION): Delete.
11022         * config/m32r/m32r.h (TRULY_NOOP_TRUNCATION): Delete.
11023         * config/m68k/m68k.h (TRULY_NOOP_TRUNCATION): Delete.
11024         * config/mcore/mcore.h (TRULY_NOOP_TRUNCATION): Delete.
11025         * config/microblaze/microblaze.h (TRULY_NOOP_TRUNCATION): Delete.
11026         * config/mips/mips.h (TRULY_NOOP_TRUNCATION): Delete.
11027         * config/mips/mips.c (mips_truly_noop_truncation): New function.
11028         (TARGET_TRULY_NOOP_TRUNCATION): Redefine.
11029         * config/mips/mips.md: Refer to TARGET_TRULY_NOOP_TRUNCATION
11030         rather than TRULY_NOOP_TRUNCATION in comments.
11031         * config/mmix/mmix.h (TRULY_NOOP_TRUNCATION): Delete.
11032         * config/mn10300/mn10300.h (TRULY_NOOP_TRUNCATION): Delete.
11033         * config/moxie/moxie.h (TRULY_NOOP_TRUNCATION): Delete.
11034         * config/msp430/msp430.h (TRULY_NOOP_TRUNCATION): Delete.
11035         * config/nds32/nds32.h (TRULY_NOOP_TRUNCATION): Delete.
11036         * config/nios2/nios2.h (TRULY_NOOP_TRUNCATION): Delete.
11037         * config/nvptx/nvptx.h (TRULY_NOOP_TRUNCATION): Delete.
11038         * config/pa/pa.h (TRULY_NOOP_TRUNCATION): Delete.
11039         * config/pdp11/pdp11.h (TRULY_NOOP_TRUNCATION): Delete.
11040         * config/powerpcspe/powerpcspe.h (TRULY_NOOP_TRUNCATION): Delete.
11041         * config/riscv/riscv.h (TRULY_NOOP_TRUNCATION): Delete.
11042         * config/riscv/riscv.md: Refer to TARGET_TRULY_NOOP_TRUNCATION
11043         rather than TRULY_NOOP_TRUNCATION in comments.
11044         * config/rl78/rl78.h (TRULY_NOOP_TRUNCATION): Delete.
11045         * config/rs6000/rs6000.h (TRULY_NOOP_TRUNCATION): Delete.
11046         * config/rx/rx.h (TRULY_NOOP_TRUNCATION): Delete.
11047         * config/s390/s390.h (TRULY_NOOP_TRUNCATION): Delete.
11048         * config/sh/sh.h (MAYBE_BASE_REGISTER_RTX_P): Remove
11049         TRULY_NOOP_TRUNCATION condition.
11050         (MAYBE_INDEX_REGISTER_RTX_P): Likewise.
11051         (TRULY_NOOP_TRUNCATION): Delete.
11052         * config/sparc/sparc.h (TRULY_NOOP_TRUNCATION): Delete.
11053         * config/spu/spu.h (TRULY_NOOP_TRUNCATION): Delete.
11054         * config/spu/spu.c (spu_truly_noop_truncation): New function.
11055         (TARGET_TRULY_NOOP_TRUNCATION): Redefine.
11056         * config/stormy16/stormy16.h (TRULY_NOOP_TRUNCATION): Delete.
11057         * config/tilegx/tilegx.h (TRULY_NOOP_TRUNCATION): Delete.
11058         * config/tilegx/tilegx.c (tilegx_truly_noop_truncation): New fuction.
11059         (TARGET_TRULY_NOOP_TRUNCATION): Redefine.
11060         * config/tilegx/tilegx.md: Refer to TARGET_TRULY_NOOP_TRUNCATION
11061         rather than TRULY_NOOP_TRUNCATION in comments.
11062         * config/tilepro/tilepro.h (TRULY_NOOP_TRUNCATION): Delete.
11063         * config/v850/v850.h (TRULY_NOOP_TRUNCATION): Delete.
11064         * config/vax/vax.h (TRULY_NOOP_TRUNCATION): Delete.
11065         * config/visium/visium.h (TRULY_NOOP_TRUNCATION): Delete.
11066         * config/xtensa/xtensa.h (TRULY_NOOP_TRUNCATION): Delete.
11067         * system.h (TRULY_NOOP_TRUNCATION): Poison.
11069 2017-09-15  Christophe Lyon  <christophe.lyon@linaro.org>
11071         PR target/67591
11072         * config/arm/arm.md (*cmp_and): Add enabled_for_depr_it attribute.
11073         (*cmp_ior): Likewise.
11074         (*ior_scc_scc): Add alternative for enabled_for_depr_it attribute.
11075         (*ior_scc_scc_cmp): Likewise.
11076         (*and_scc_scc): Likewise.
11077         (*and_scc_scc_cmp): Likewise.
11079 2017-09-15  Richard Sandiford  <richard.sandiford@linaro.org>
11080             Alan Hayard  <alan.hayward@arm.com>
11081             David Sherwood  <david.sherwood@arm.com>
11083         * target.def (can_change_mode_class): New hook.
11084         (mode_rep_extended): Refer to it instead of CANNOT_CHANGE_MODE_CLASS.
11085         (hard_regno_nregs): Likewise.
11086         * hooks.h (hook_bool_mode_mode_reg_class_t_true): Declare.
11087         * hooks.c (hook_bool_mode_mode_reg_class_t_true): New function.
11088         * doc/tm.texi.in (CANNOT_CHANGE_MODE_CLASS): Replace with...
11089         (TARGET_CAN_CHANGE_MODE_CLASS): ...this.
11090         (LOAD_EXTEND_OP): Update accordingly.
11091         * doc/tm.texi: Regenerate.
11092         * doc/rtl.texi: Refer to TARGET_CAN_CHANGE_MODE_CLASS instead of
11093         CANNOT_CHANGE_MODE_CLASS.
11094         * hard-reg-set.h (REG_CANNOT_CHANGE_MODE_P): Replace with...
11095         (REG_CAN_CHANGE_MODE_P): ...this new macro.
11096         * combine.c (simplify_set): Update accordingly.
11097         * emit-rtl.c (validate_subreg): Likewise.
11098         * recog.c (general_operand): Likewise.
11099         * regcprop.c (mode_change_ok): Likewise.
11100         * reload1.c (choose_reload_regs): Likewise.
11101         (inherit_piecemeal_p): Likewise.
11102         * rtlanal.c (simplify_subreg_regno): Likewise.
11103         * postreload.c (reload_cse_simplify_set): Use REG_CAN_CHANGE_MODE_P
11104         instead of CANNOT_CHANGE_MODE_CLASS.
11105         (reload_cse_simplify_operands): Likewise.
11106         * reload.c (push_reload): Use targetm.can_change_mode_class
11107         instead of CANNOT_CHANGE_MODE_CLASS.
11108         (push_reload): Likewise.  Also use REG_CAN_CHANGE_MODE_P instead of
11109         REG_CANNOT_CHANGE_MODE_P.
11110         * config/alpha/alpha.h (CANNOT_CHANGE_MODE_CLASS): Delete.
11111         * config/alpha/alpha.c (alpha_can_change_mode_class): New function.
11112         (TARGET_CAN_CHANGE_MODE_CLASS): Redefine.
11113         * config/arm/arm.h (CANNOT_CHANGE_MODE_CLASS): Delete.
11114         * config/arm/arm.c (TARGET_CAN_CHANGE_MODE_CLASS): Redefine.
11115         (arm_can_change_mode_class): New function.
11116         * config/arm/neon.md: Refer to TARGET_CAN_CHANGE_MODE_CLASS rather
11117         than CANNOT_CHANGE_MODE_CLASS in comments.
11118         * config/i386/i386.h (CANNOT_CHANGE_MODE_CLASS): Delete.
11119         * config/i386/i386-protos.h (ix86_cannot_change_mode_class): Delete.
11120         * config/i386/i386.c (ix86_cannot_change_mode_class): Replace with...
11121         (ix86_can_change_mode_class): ...this new function, inverting the
11122         sense of the return value.
11123         (TARGET_CAN_CHANGE_MODE_CLASS): Redefine.
11124         * config/ia64/ia64.h (CANNOT_CHANGE_MODE_CLASS): Delete.
11125         * config/ia64/ia64.c (TARGET_CAN_CHANGE_MODE_CLASS): Redefine.
11126         (ia64_can_change_mode_class): New function.
11127         * config/m32c/m32c.h (CANNOT_CHANGE_MODE_CLASS): Delete.
11128         * config/m32c/m32c-protos.h (m32c_cannot_change_mode_class): Delete.
11129         * config/m32c/m32c.c (m32c_cannot_change_mode_class): Replace with...
11130         (m32c_can_change_mode_class): ...this new function, inverting the
11131         sense of the return value.
11132         (TARGET_CAN_CHANGE_MODE_CLASS): Redefine.
11133         * config/mips/mips.h (CANNOT_CHANGE_MODE_CLASS): Delete.
11134         * config/mips/mips-protos.h (mips_cannot_change_mode_class): Delete.
11135         * config/mips/mips.c (mips_cannot_change_mode_class): Replace with...
11136         (mips_can_change_mode_class): ...this new function, inverting the
11137         sense of the return value.
11138         (TARGET_CAN_CHANGE_MODE_CLASS): Redefine.
11139         * config/msp430/msp430.h (CANNOT_CHANGE_MODE_CLASS): Delete.
11140         * config/msp430/msp430.c (TARGET_CAN_CHANGE_MODE_CLASS): Redefine.
11141         (msp430_can_change_mode_class): New function.
11142         * config/nvptx/nvptx.h (CANNOT_CHANGE_MODE_CLASS): Delete.
11143         * config/nvptx/nvptx.c (nvptx_can_change_mode_class): New function.
11144         (TARGET_CAN_CHANGE_MODE_CLASS): Redefine.
11145         * config/pa/pa32-regs.h (CANNOT_CHANGE_MODE_CLASS): Delete.
11146         * config/pa/pa64-regs.h (CANNOT_CHANGE_MODE_CLASS): Delete.
11147         * config/pa/pa-protos.h (pa_cannot_change_mode_class): Delete.
11148         * config/pa/pa.c (TARGET_CAN_CHANGE_MODE_CLASS): Redefine.
11149         (pa_cannot_change_mode_class): Replace with...
11150         (pa_can_change_mode_class): ...this new function, inverting the
11151         sense of the return value.
11152         (pa_modes_tieable_p): Refer to TARGET_CAN_CHANGE_MODE_CLASS rather
11153         than CANNOT_CHANGE_MODE_CLASS in comments.
11154         * config/pdp11/pdp11.h (CANNOT_CHANGE_MODE_CLASS): Delete.
11155         * config/pdp11/pdp11-protos.h (pdp11_cannot_change_mode_class): Delete.
11156         * config/pdp11/pdp11.c (TARGET_CAN_CHANGE_MODE_CLASS): Redefine.
11157         (pdp11_cannot_change_mode_class): Replace with...
11158         (pdp11_can_change_mode_class): ...this new function, inverting the
11159         sense of the return value.
11160         * config/powerpcspe/powerpcspe.h (CANNOT_CHANGE_MODE_CLASS): Delete.
11161         * config/powerpcspe/powerpcspe-protos.h
11162         (rs6000_cannot_change_mode_class_ptr): Delete.
11163         * config/powerpcspe/powerpcspe.c
11164         (rs6000_cannot_change_mode_class_ptr): Delete.
11165         (TARGET_CAN_CHANGE_MODE_CLASS): Redefine.
11166         (rs6000_option_override_internal): Assign to
11167         targetm.can_change_mode_class instead of
11168         rs6000_cannot_change_mode_class_ptr.
11169         (rs6000_cannot_change_mode_class): Replace with...
11170         (rs6000_can_change_mode_class): ...this new function, inverting the
11171         sense of the return value.
11172         (rs6000_debug_cannot_change_mode_class): Replace with...
11173         (rs6000_debug_can_change_mode_class): ...this new function.
11174         * config/riscv/riscv.h (CANNOT_CHANGE_MODE_CLASS): Delete.
11175         * config/riscv/riscv.c (riscv_can_change_mode_class): New function.
11176         (TARGET_CAN_CHANGE_MODE_CLASS): Redefine.
11177         * config/rs6000/rs6000.h (CANNOT_CHANGE_MODE_CLASS): Delete.
11178         * config/rs6000/rs6000-protos.h (rs6000_cannot_change_mode_class_ptr):
11179         Delete.
11180         * config/rs6000/rs6000.c (rs6000_cannot_change_mode_class_ptr): Delete.
11181         (TARGET_CAN_CHANGE_MODE_CLASS): Redefine.
11182         (rs6000_option_override_internal): Assign to
11183         targetm.can_change_mode_class instead of
11184         rs6000_cannot_change_mode_class_ptr.
11185         (rs6000_cannot_change_mode_class): Replace with...
11186         (rs6000_can_change_mode_class): ...this new function, inverting the
11187         sense of the return value.
11188         (rs6000_debug_cannot_change_mode_class): Replace with...
11189         (rs6000_debug_can_change_mode_class): ...this new function.
11190         * config/s390/s390.h (CANNOT_CHANGE_MODE_CLASS): Delete.
11191         * config/s390/s390-protos.h (s390_cannot_change_mode_class): Delete.
11192         * config/s390/s390.c (s390_cannot_change_mode_class): Replace with...
11193         (s390_can_change_mode_class): ...this new function, inverting the
11194         sense of the return value.
11195         (TARGET_CAN_CHANGE_MODE_CLASS): Redefine.
11196         * config/sh/sh.h (CANNOT_CHANGE_MODE_CLASS): Delete.
11197         * config/sh/sh-protos.h (sh_cannot_change_mode_class): Delete.
11198         * config/sh/sh.c (TARGET_CAN_CHANGE_MODE_CLASS): Redefine.
11199         (sh_cannot_change_mode_class): Replace with...
11200         (sh_can_change_mode_class): ...this new function, inverting the
11201         sense of the return value.
11202         * config/sparc/sparc.h (CANNOT_CHANGE_MODE_CLASS): Delete.
11203         * config/sparc/sparc.c (TARGET_CAN_CHANGE_MODE_CLASS): Redefine.
11204         (sparc_can_change_mode_class): New function.
11205         * config/spu/spu.h (CANNOT_CHANGE_MODE_CLASS): Delete.
11206         * config/spu/spu.c (spu_can_change_mode_class): New function.
11207         (TARGET_CAN_CHANGE_MODE_CLASS): Redefine.
11208         * config/visium/visium.h (CANNOT_CHANGE_MODE_CLASS): Delete.
11209         * config/visium/visium.c (TARGET_CAN_CHANGE_MODE_CLASS): Redefine.
11210         (visium_can_change_mode_class): New function.
11211         * system.h (CANNOT_CHANGE_MODE_CLASS): Poison.
11213 2017-09-15  Richard Biener  <rguenther@suse.de>
11215         PR tree-optimization/82217
11216         * tree-ssa-sccvn.c (visit_phi): Properly handle all VN_TOP
11217         but not undefined case.
11219 2017-09-15  Jakub Jelinek  <jakub@redhat.com>
11221         PR target/82145
11222         * postreload.c (reload_cse_simplify_operands): Skip
11223         NOTE_INSN_DELETED_LABEL similarly to skipping CODE_LABEL.
11225 2017-09-15  Richard Biener  <rguenther@suse.de>
11227         PR tree-optimization/68823
11228         * graphite-scop-detection.c (build_alias_set): If we have a
11229         possible dependence check whether we can handle them by just
11230         looking at the DRs DR_ACCESS_FNs.
11231         (build_scops): If build_alias_set fails, fail the SCOP.
11233 2017-09-14  Michael Meissner  <meissner@linux.vnet.ibm.com>
11235         * config/rs6000/rs6000-builtin.def (BU_FLOAT128_1_HW): New macros
11236         to support float128 built-in functions that require the ISA 3.0
11237         hardware.
11238         (BU_FLOAT128_3_HW): Likewise.
11239         (SQRTF128): Add support for the IEEE 128-bit square root and fma
11240         built-in functions.
11241         (FMAF128): Likewise.
11242         (FMAQ): Likewise.
11243         * config/rs6000/rs6000.c (rs6000_builtin_mask_calculate): Add
11244         support for built-in functions that need the ISA 3.0 IEEE 128-bit
11245         floating point instructions.
11246         (rs6000_invalid_builtin): Likewise.
11247         (rs6000_builtin_mask_names): Likewise.
11248         * config/rs6000/rs6000.h (MASK_FLOAT128_HW): Likewise.
11249         (RS6000_BTM_FLOAT128_HW): Likewise.
11250         (RS6000_BTM_COMMON): Likewise.
11251         * config/rs6000/rs6000.md (fma<mode>4_hw): Add a generator
11252         function.
11253         * doc/extend.texi (RS/6000 built-in functions): Document the
11254         IEEE 128-bit floating point square root and fused multiply-add
11255         built-in functions.
11257 2017-09-14  Pat Haugen  <pthaugen@us.ibm.com>
11259         * config/rs6000/rs6000.c (rs6000_set_up_by_prologue): Make sure the TOC
11260         reg (r2) isn't in the set of registers defined in the prologue.
11262 2017-09-14  Richard Sandiford  <richard.sandiford@linaro.org>
11263             Alan Hayward  <alan.hayward@arm.com>
11264             David Sherwood  <david.sherwood@arm.com>
11266         * tree-vectorizer.h (_loop_vec_info): Add max_vectorization_factor.
11267         (LOOP_VINFO_MAX_VECT_FACTOR): New macro.
11268         (LOOP_VINFO_ORIG_VECT_FACTOR): Replace with...
11269         (LOOP_VINFO_ORIG_MAX_VECT_FACTOR): ...this new macro.
11270         * tree-vect-data-refs.c (vect_analyze_data_ref_dependences): Update
11271         accordingly.
11272         * tree-vect-loop.c (_loop_vec_info::_loop_vec_info): Initialize
11273         max_vectorization_factor.
11274         (vect_analyze_loop_2): Set LOOP_VINFO_MAX_VECT_FACTOR.
11276 2017-09-14  Richard Sandiford  <richard.sandiford@linaro.org>
11277             Alan Hayward  <alan.hayward@arm.com>
11278             David Sherwood  <david.sherwood@arm.com>
11280         * tree-vectorizer.h (vect_min_worthwhile_factor): Delete.
11281         (vect_worthwhile_without_simd_p): Declare.
11282         * tree-vect-loop.c (vect_worthwhile_without_simd_p): New function.
11283         (vectorizable_reduction): Use it.
11284         * tree-vect-stmts.c (vectorizable_shift): Likewise.
11285         (vectorizable_operation): Likewise.
11287 2017-09-14  Richard Sandiford  <richard.sandiford@linaro.org>
11288             Alan Hayward  <alan.hayward@arm.com>
11289             David Sherwood  <david.sherwood@arm.com>
11291         * tree-vectorizer.h (vect_get_num_copies): New function.
11292         * tree-vect-data-refs.c (vect_get_data_access_cost): Use it.
11293         * tree-vect-loop.c (vectorizable_reduction): Likewise.
11294         (vectorizable_induction): Likewise.
11295         (vectorizable_live_operation): Likewise.
11296         * tree-vect-stmts.c (vectorizable_mask_load_store): Likewise.
11297         (vectorizable_bswap): Likewise.
11298         (vectorizable_call): Likewise.
11299         (vectorizable_conversion): Likewise.
11300         (vectorizable_assignment): Likewise.
11301         (vectorizable_shift): Likewise.
11302         (vectorizable_operation): Likewise.
11303         (vectorizable_store): Likewise.
11304         (vectorizable_load): Likewise.
11305         (vectorizable_condition): Likewise.
11306         (vectorizable_comparison): Likewise.
11307         (vect_analyze_stmt): Pass the slp node to vectorizable_live_operation.
11309 2017-09-14  Richard Sandiford  <richard.sandiford@linaro.org>
11310             Alan Hayward  <alan.hayward@arm.com>
11311             David Sherwood  <david.sherwood@arm.com>
11313         * tree-vect-loop.c (vectorizable_induction): Use gimple_build instead
11314         of vect_init_vector.
11316 2017-09-14  Richard Sandiford  <richard.sandiford@linaro.org>
11317             Alan Hayward  <alan.hayward@arm.com>
11318             David Sherwood  <david.sherwood@arm.com>
11320         * gimple-fold.h (gimple_build_vector_from_val): Declare, and provide
11321         an inline wrapper that provides a location.
11322         (gimple_build_vector): Likewise.
11323         * gimple-fold.c (gimple_build_vector_from_val): New function.
11324         (gimple_build_vector): Likewise.
11325         * tree-vect-loop.c (get_initial_def_for_reduction): Use the new
11326         functions to build the initial value.  Always return a gimple value.
11327         (get_initial_defs_for_reduction): Likewise.  Only compute
11328         neutral_vec once.
11329         (vect_create_epilog_for_reduction): Don't call force_gimple_operand or
11330         vect_init_vector on the results from get_initial_def(s)_for_reduction.
11331         (vectorizable_induction): Use gimple_build_vector rather than
11332         vect_init_vector.
11334 2017-09-14  Richard Sandiford  <richard.sandiford@linaro.org>
11335             Alan Hayward  <alan.hayward@arm.com>
11336             David Sherwood  <david.sherwood@arm.com>
11338         * target.h (vec_perm_indices): New typedef.
11339         (auto_vec_perm_indices): Likewise.
11340         * optabs-query.h: Include target.h
11341         (can_vec_perm_p): Take a vec_perm_indices *.
11342         * optabs-query.c (can_vec_perm_p): Likewise.
11343         (can_mult_highpart_p): Update accordingly.  Use auto_vec_perm_indices.
11344         * tree-ssa-forwprop.c (simplify_vector_constructor): Likewise.
11345         * tree-vect-generic.c (lower_vec_perm): Likewise.
11346         * tree-vect-data-refs.c (vect_grouped_store_supported): Likewise.
11347         (vect_grouped_load_supported): Likewise.
11348         (vect_shift_permute_load_chain): Likewise.
11349         (vect_permute_store_chain): Use auto_vec_perm_indices.
11350         (vect_permute_load_chain): Likewise.
11351         * fold-const.c (fold_vec_perm): Take vec_perm_indices.
11352         (fold_ternary_loc): Update accordingly.  Use auto_vec_perm_indices.
11353         Update uses of can_vec_perm_p.
11354         * tree-vect-loop.c (calc_vec_perm_mask_for_shift): Replace the
11355         mode with a number of elements.  Take a vec_perm_indices *.
11356         (vect_create_epilog_for_reduction): Update accordingly.
11357         Use auto_vec_perm_indices.
11358         (have_whole_vector_shift): Likewise.  Update call to can_vec_perm_p.
11359         * tree-vect-slp.c (vect_build_slp_tree_1): Likewise.
11360         (vect_transform_slp_perm_load): Likewise.
11361         (vect_schedule_slp_instance): Use auto_vec_perm_indices.
11362         * tree-vectorizer.h (vect_gen_perm_mask_any): Take a vec_perm_indices.
11363         (vect_gen_perm_mask_checked): Likewise.
11364         * tree-vect-stmts.c (vect_gen_perm_mask_any): Take a vec_perm_indices.
11365         (vect_gen_perm_mask_checked): Likewise.
11366         (vectorizable_mask_load_store): Use auto_vec_perm_indices.
11367         (vectorizable_store): Likewise.
11368         (vectorizable_load): Likewise.
11369         (perm_mask_for_reverse): Likewise.  Update call to can_vec_perm_p.
11370         (vectorizable_bswap): Likewise.
11372 2017-09-14  Richard Sandiford  <richard.sandiford@linaro.org>
11373             Alan Hayward  <alan.hayward@arm.com>
11374             David Sherwood  <david.sherwood@arm.com>
11376         * tree.h (build_vector): Take a vec<tree> instead of a tree *.
11377         * tree.c (build_vector): Likewise.
11378         (build_vector_from_ctor): Update accordingly.
11379         (build_vector_from_val): Likewise.
11380         * gimple-fold.c (gimple_fold_stmt_to_constant_1): Likewise.
11381         * tree-ssa-forwprop.c (simplify_vector_constructor): Likewise.
11382         * tree-vect-generic.c (add_rshift): Likewise.
11383         (expand_vector_divmod): Likewise.
11384         (optimize_vector_constructor): Likewise.
11385         * tree-vect-slp.c (vect_get_constant_vectors): Likewise.
11386         (vect_transform_slp_perm_load): Likewise.
11387         (vect_schedule_slp_instance): Likewise.
11388         * tree-vect-stmts.c (vectorizable_bswap): Likewise.
11389         (vectorizable_call): Likewise.
11390         (vect_gen_perm_mask_any): Likewise.  Add elements in order.
11391         * expmed.c (make_tree): Likewise.
11392         * fold-const.c (fold_negate_expr_1): Use auto_vec<tree> when building
11393         a vector passed to build_vector.
11394         (fold_convert_const): Likewise.
11395         (exact_inverse): Likewise.
11396         (fold_ternary_loc): Likewise.
11397         (fold_relational_const): Likewise.
11398         (const_binop): Likewise.  Use VECTOR_CST_ELT directly when operating
11399         on VECTOR_CSTs, rather than going through vec_cst_ctor_to_array.
11400         (const_unop): Likewise.  Store the reduction accumulator in a
11401         variable rather than an array.
11402         (vec_cst_ctor_to_array): Take the number of elements as a parameter.
11403         (fold_vec_perm): Update calls accordingly.  Use auto_vec<tree> for
11404         the new vector, rather than constructing it after the input arrays.
11405         (native_interpret_vector): Use auto_vec<tree> when building
11406         a vector passed to build_vector.  Add elements in order.
11407         * tree-vect-loop.c (get_initial_defs_for_reduction): Use
11408         auto_vec<tree> when building a vector passed to build_vector.
11409         (vect_create_epilog_for_reduction): Likewise.
11410         (vectorizable_induction): Likewise.
11411         (get_initial_def_for_reduction): Likewise.  Fix indentation of
11412         case statements.
11413         * config/sparc/sparc.c (sparc_handle_vis_mul8x16): Change n_elts
11414         to a vec<tree> *.
11415         (sparc_fold_builtin): Use auto_vec<tree> when building a vector
11416         passed to build_vector.
11418 2017-09-14  Richard Sandiford  <richard.sandiford@linaro.org>
11419             Alan Hayward  <alan.hayward@arm.com>
11420             David Sherwood  <david.sherwood@arm.com>
11422         * tree-core.h (tree_base::u): Add an "nelts" field.
11423         (tree_vector): Use VECTOR_CST_NELTS as the length.
11424         * tree.c (tree_size): Likewise.
11425         (make_vector): Initialize VECTOR_CST_NELTS.
11426         * tree.h (VECTOR_CST_NELTS): Use the u.nelts field.
11427         * cfgexpand.c (expand_debug_expr): Use VECTOR_CST_NELTS instead of
11428         TYPE_VECTOR_SUBPARTS.
11429         * expr.c (const_vector_mask_from_tree): Consistently use "units"
11430         as the number of units, setting it from VECTOR_CST_NELTS.
11431         (const_vector_from_tree): Likewise.
11432         * fold-const.c (negate_expr_p): Use VECTOR_CST_NELTS instead of
11433         TYPE_VECTOR_SUBPARTS for the number of elements in a VECTOR_CST.
11434         (fold_negate_expr_1): Likewise.
11435         (fold_convert_const): Likewise.
11436         (const_binop): Likewise.  Differentiate the number of output and
11437         input elements.
11438         (const_unop): Likewise.
11439         (fold_ternary_loc): Use VECTOR_CST_NELTS for the number of elements
11440         in a VECTOR_CST, asserting that it is the same as TYPE_VECTOR_SUBPARTS
11441         in cases that did the opposite.
11443 2017-09-14  Richard Biener  <rguenther@suse.de>
11445         * tree-ssa-sccvn.c (visit_phi): Merge undefined values similar
11446         to VN_TOP.
11448 2017-09-14  Eric Botcazou  <ebotcazou@adacore.com>
11450         * dwarf2out.c (dwarf2out_source_line): Remove superfluous test.
11452 2017-09-14  Jakub Jelinek  <jakub@redhat.com>
11454         PR target/81325
11455         * cfgbuild.c (find_bb_boundaries): Ignore debug insns in decisions
11456         if and where to split a bb, except for splitting before debug insn
11457         sequences followed by non-label real insn.  Delete debug insns
11458         in between basic blocks.
11460         * combine.c (make_compound_operation_int): Formatting fixes.
11462         * config/alpha/elf.h (LINK_EH_SPEC): Add -static-pie support.
11463         * config/alpha/linux.h (LINK_GCC_C_SEQUENCE_SPEC): Likewise.
11464         * config/netbsd.h (LINK_EH_SPEC): Likewise.
11465         * config/sol2.h (LINK_EH_SPEC): Likewise.
11466         * config/arm/uclinux-elf.h (LINK_GCC_C_SEQUENCE_SPEC): Likewise.
11467         * config/s390/linux.h (LINK_SPEC): Likewise.
11468         * config/freebsd.h (LINK_EH_SPEC): Likewise.
11469         * config/openbsd.h (LINK_EH_SPEC): Likewise.
11470         * config/lm32/uclinux-elf.h (LINK_GCC_C_SEQUENCE_SPEC): Likewise.
11471         * config/aarch64/aarch64-linux.h (LINUX_TARGET_LINK_SPEC): Likewise.
11472         * config/powerpcspe/sysv4.h (LINK_EH_SPEC): Likewise.
11473         * config/bfin/linux.h (LINK_GCC_C_SEQUENCE_SPEC): Likewise.
11474         * config/i386/gnu-user64.h (GNU_USER_TARGET_LINK_SPEC): Fix a typo.
11475         * config/i386/gnu-user.h (GNU_USER_TARGET_LINK_SPEC): Formatting fix.
11477 2017-09-13  Jakub Jelinek  <jakub@redhat.com>
11479         * config/rs6000/sysv4.h (STARTFILE_LINUX_SPEC): Add -static-pie
11480         support.
11481         (ENDFILE_LINUX_SPEC): Likewise.
11482         (LINK_EH_SPEC): Likewise.
11483         * config/rs6000/linux64.h (LINK_SHLIB_SPEC): Likewise.
11484         (LINK_OS_LINUX_SPEC32): Likewise.
11485         (LINK_OS_LINUX_SPEC64): Likewise.
11486         * config/rs6000/linux.h (LINK_SHLIB_SPEC): Likewise.
11487         (LINK_OS_LINUX_SPEC): Likewise.
11489 2017-09-13  Martin Liska  <mliska@suse.cz>
11491         PR middle-end/82154
11492         * stmt.c (expand_sjlj_dispatch_table): Use CASE_LOW when
11493         CASE_HIGH is NULL_TREE.
11495 2017-09-13  Richard Sandiford  <richard.sandiford@linaro.org>
11496             Alan Hayward  <alan.hayward@arm.com>
11497             David Sherwood  <david.sherwood@arm.com>
11499         * target.def (secondary_memory_needed): New hook.
11500         (secondary_reload): Refer to TARGET_SECONDARY_MEMORY_NEEDED
11501         instead of SECONDARY_MEMORY_NEEDED.
11502         (secondary_memory_needed_mode): Likewise.
11503         * hooks.h (hook_bool_mode_reg_class_t_reg_class_t_false): Declare.
11504         * hooks.c (hook_bool_mode_reg_class_t_reg_class_t_false): New function.
11505         * doc/tm.texi.in (SECONDARY_MEMORY_NEEDED): Replace with...
11506         (TARGET_SECONDARY_MEMORY_NEEDED): ...this.
11507         (SECONDARY_MEMORY_NEEDED_RTX): Update reference accordingly.
11508         * doc/tm.texi: Regenerate.
11509         * config/alpha/alpha.h (SECONDARY_MEMORY_NEEDED): Delete.
11510         * config/alpha/alpha.c (alpha_secondary_memory_needed): New function.
11511         (TARGET_SECONDARY_MEMORY_NEEDED): Redefine.
11512         * config/i386/i386.h (SECONDARY_MEMORY_NEEDED): Delete.
11513         * config/i386/i386-protos.h (ix86_secondary_memory_needed): Delete.
11514         * config/i386/i386.c (inline_secondary_memory_needed): Put the
11515         mode argument first and change the reg_class arguments to reg_class_t.
11516         (ix86_secondary_memory_needed): Likewise.  Remove the strict parameter.
11517         Make static.  Update the call to inline_secondary_memory_needed.
11518         (ix86_register_move_cost): Update the call to
11519         inline_secondary_memory_needed.
11520         (TARGET_SECONDARY_MEMORY_NEEDED): Redefine.
11521         * config/ia64/ia64.h (SECONDARY_MEMORY_NEEDED): Delete commented-out
11522         definition.
11523         * config/ia64/ia64.c (spill_xfmode_rfmode_operand): Refer to
11524         TARGET_SECONDARY_MEMORY_NEEDED rather than SECONDARY_MEMORY_NEEDED
11525         in comment.
11526         * config/mips/mips.h (SECONDARY_MEMORY_NEEDED): Delete.
11527         * config/mips/mips-protos.h (mips_secondary_memory_needed): Delete.
11528         * config/mips/mips.c (mips_secondary_memory_needed): Make static
11529         and match hook interface.  Add comment from mips.h.
11530         (TARGET_SECONDARY_MEMORY_NEEDED): Redefine.
11531         * config/mmix/mmix.md (truncdfsf2): Refer to
11532         TARGET_SECONDARY_MEMORY_NEEDED rather than SECONDARY_MEMORY_NEEDED
11533         in comment.
11534         * config/pa/pa-64.h (SECONDARY_MEMORY_NEEDED): Rename to...
11535         (PA_SECONDARY_MEMORY_NEEDED): ...this, and put the mode argument first.
11536         * config/pa/pa.c (TARGET_SECONDARY_MEMORY_NEEDED): Redefine.
11537         (pa_secondary_memory_needed): New function.
11538         * config/pdp11/pdp11.h (SECONDARY_MEMORY_NEEDED): Delete.
11539         * config/pdp11/pdp11-protos.h (pdp11_secondary_memory_needed): Delete.
11540         * config/pdp11/pdp11.c (TARGET_SECONDARY_MEMORY_NEEDED): Redefine.
11541         (pdp11_secondary_memory_needed): Make static and match hook interface.
11542         * config/powerpcspe/powerpcspe.h (SECONDARY_MEMORY_NEEDED): Delete.
11543         * config/powerpcspe/powerpcspe-protos.h
11544         (rs6000_secondary_memory_needed_ptr): Delete.
11545         * config/powerpcspe/powerpcspe.c (rs6000_secondary_memory_needed_ptr):
11546         Delete.
11547         (TARGET_SECONDARY_MEMORY_NEEDED): Redefine.
11548         (rs6000_option_override_internal): Assign to
11549         targetm.secondary_memory_needed rather than
11550         rs6000_secondary_memory_needed_ptr.
11551         (rs6000_secondary_memory_needed): Match hook interface.
11552         (rs6000_debug_secondary_memory_needed): Likewise.
11553         * config/riscv/riscv.h (SECONDARY_MEMORY_NEEDED): Delete.
11554         * config/riscv/riscv.c (riscv_secondary_memory_needed): New function.
11555         (riscv_register_move_cost): Use it instead of SECONDARY_MEMORY_NEEDED.
11556         (TARGET_SECONDARY_MEMORY_NEEDED): Redefine.
11557         * config/rs6000/rs6000.h (SECONDARY_MEMORY_NEEDED): Delete.
11558         * config/rs6000/rs6000-protos.h (rs6000_secondary_memory_needed_ptr):
11559         Delete.
11560         * config/rs6000/rs6000.c (rs6000_secondary_memory_needed_ptr): Delete.
11561         (TARGET_SECONDARY_MEMORY_NEEDED): Redefine.
11562         (rs6000_option_override_internal): Assign to
11563         targetm.secondary_memory_needed rather than
11564         rs6000_secondary_memory_needed_ptr.
11565         (rs6000_secondary_memory_needed): Match hook interface.
11566         (rs6000_debug_secondary_memory_needed): Likewise.
11567         * config/s390/s390.h (SECONDARY_MEMORY_NEEDED): Delete.
11568         * config/s390/s390.c (s390_secondary_memory_needed): New function.
11569         (TARGET_SECONDARY_MEMORY_NEEDED): Redefine.
11570         * config/sparc/sparc.h (SECONDARY_MEMORY_NEEDED): Delete.
11571         * config/sparc/sparc.c (TARGET_SECONDARY_MEMORY_NEEDED): Redefine.
11572         (sparc_secondary_memory_needed): New function.
11573         * lra-constraints.c (check_and_process_move): Refer to
11574         TARGET_SECONDARY_MEMORY_NEEDED rather than SECONDARY_MEMORY_NEEDED
11575         in comment.
11576         (curr_insn_transform): Likewise.
11577         (process_alt_operands): Use targetm.secondary_memory_needed
11578         instead of TARGET_SECONDARY_MEMORY_NEEDED.
11579         (check_secondary_memory_needed_p): Likewise.
11580         (choose_split_class): Likewise.
11581         * reload.c: Unconditionally include code that was previously
11582         conditional on SECONDARY_MEMORY_NEEDED.
11583         (push_secondary_reload): Use targetm.secondary_memory_needed
11584         instead of TARGET_SECONDARY_MEMORY_NEEDED.
11585         (push_reload): Likewise.
11586         * reload1.c: Unconditionally include code that was previously
11587         conditional on SECONDARY_MEMORY_NEEDED.
11588         (choose_reload_regs): Use targetm.secondary_memory_needed
11589         instead of TARGET_SECONDARY_MEMORY_NEEDED.
11590         (gen_reload): Likewise.
11591         * system.h (SECONDARY_MEMORY_NEEDED): Poison.
11593 2017-09-13  Richard Sandiford  <richard.sandiford@linaro.org>
11594             Alan Hayward  <alan.hayward@arm.com>
11595             David Sherwood  <david.sherwood@arm.com>
11597         * target.def (secondary_memory_needed_mode): New hook:
11598         * targhooks.c (default_secondary_memory_needed_mode): Declare.
11599         * targhooks.h (default_secondary_memory_needed_mode): New function.
11600         * doc/tm.texi.in (SECONDARY_MEMORY_NEEDED_MODE): Replace with...
11601         (TARGET_SECONDARY_MEMORY_NEEDED_MODE): ...this.
11602         * doc/tm.texi: Regenerate.
11603         * lra-constraints.c (check_and_process_move): Use
11604         targetm.secondary_memory_needed_mode instead of
11605         TARGET_SECONDARY_MEMORY_NEEDED_MODE.
11606         (curr_insn_transform): Likewise.
11607         * reload.c (get_secondary_mem): Likewise.
11608         * config/alpha/alpha.h (SECONDARY_MEMORY_NEEDED_MODE): Delete.
11609         * config/alpha/alpha.c (alpha_secondary_memory_needed_mode): New
11610         function.
11611         (TARGET_SECONDARY_MEMORY_NEEDED_MODE): Redefine.
11612         * config/i386/i386.h (SECONDARY_MEMORY_NEEDED_MODE): Delete.
11613         * config/i386/i386.c (ix86_secondary_memory_needed_mode): New function.
11614         (TARGET_SECONDARY_MEMORY_NEEDED_MODE): Redefine.
11615         * config/powerpcspe/powerpcspe.h (SECONDARY_MEMORY_NEEDED_MODE):
11616         Delete.
11617         * config/powerpcspe/powerpcspe-protos.h
11618         (rs6000_secondary_memory_needed_mode): Delete.
11619         * config/powerpcspe/powerpcspe.c
11620         (TARGET_SECONDARY_MEMORY_NEEDED_MODE): Redefine.
11621         (rs6000_secondary_memory_needed_mode): Make static.
11622         * config/rs6000/rs6000.h (SECONDARY_MEMORY_NEEDED_MODE): Delete.
11623         * config/rs6000/rs6000-protos.h (rs6000_secondary_memory_needed_mode):
11624         Delete.
11625         * config/rs6000/rs6000.c (TARGET_SECONDARY_MEMORY_NEEDED_MODE):
11626         Redefine.
11627         (rs6000_secondary_memory_needed_mode): Make static.
11628         * config/s390/s390.h (SECONDARY_MEMORY_NEEDED_MODE): Delete.
11629         * config/s390/s390.c (s390_secondary_memory_needed_mode): New function.
11630         (TARGET_SECONDARY_MEMORY_NEEDED_MODE): Redefine.
11631         * config/sparc/sparc.h (SECONDARY_MEMORY_NEEDED_MODE): Delete.
11632         * config/sparc/sparc.c (TARGET_SECONDARY_MEMORY_NEEDED_MODE):
11633         Redefine.
11634         (sparc_secondary_memory_needed_mode): New function.
11635         * system.h (TARGET_SECONDARY_MEMORY_NEEDED_MODE): Poison.
11637 2017-09-13  Jackson Woodruff  <jackson.woodruff@arm.com>
11639         * config/aarch64/constraints.md (Umq): New constraint.
11640         * config/aarch64/aarch64-simd.md (*aarch64_simd_mov<mode>):
11641         Change to use Umq.
11642         (mov<mode>): Update condition.
11644 2017-09-13  Kyrylo Tkachov  <kyrylo.tkachov@arm.com>
11646         * gimple-ssa-store-merging.c (sort_by_bitpos): Compare store order
11647         when bitposition is the same.
11649 2017-09-13  Richard Biener  <rguenther@suse.de>
11651         * dwarf2out.c (output_die_symbol): Remove.
11652         (output_die): Do not output a DIEs symbol.
11654 2017-09-13  Richard Biener  <rguenther@suse.de>
11656         PR middle-end/82128
11657         * gimple-fold.c (gimple_fold_call): Update SSA name in-place to
11658         default-def to avoid breaking iterator update with the weird
11659         interaction with cgraph_update_edges_for_call_stmt_node.
11661 2017-09-13  Richard Biener  <rguenther@suse.de>
11663         * tree-cfg.c (verify_gimple_assign_binary): Add verification
11664         for WIDEN_SUM_EXPR, VEC_WIDEN_MULT_{HI,LO,EVEN,ODD}_EXPR,
11665         VEC_PACK_{TRUNC,SAT,FIX_TRUNC}_EXPR.
11666         (verify_gimple_assign_ternary): Add verification for DOT_PROD_EXPR.
11668 2017-09-13  Kugan Vivekanandarajah  <kuganv@linaro.org>
11670         * config/aarch64/aarch64.c (aarch64_override_options_after_change_1):
11671         Disable pc relative literal load irrespective of
11672         TARGET_FIX_ERR_A53_84341 for default.
11674 2017-09-12  Eric Botcazou  <ebotcazou@adacore.com>
11676         * config/sparc/sparc.c (output_return): Output the source location of
11677         the insn in the delay slot, if any.
11678         (output_sibcall): Likewise.
11680 2017-09-12  H.J. Lu  <hongjiu.lu@intel.com>
11682         PR driver/81498
11683         * common.opt (-static-pie): New alias.
11684         (shared): Negate static-pie.
11685         (-no-pie): Update help text.
11686         (-pie): Likewise.
11687         (static-pie): New option.
11688         * config/gnu-user.h (GNU_USER_TARGET_STARTFILE_SPEC): Add
11689         -static-pie support.
11690         (GNU_USER_TARGET_ENDFILE_SPEC): Likewise.
11691         (LINK_EH_SPEC): Likewise.
11692         (LINK_GCC_C_SEQUENCE_SPEC): Likewise.
11693         * config/i386/gnu-user.h (GNU_USER_TARGET_LINK_SPEC): Likewise.
11694         * config/i386/gnu-user64.h (GNU_USER_TARGET_LINK_SPEC): Likewise.
11695         * gcc.c (LINK_COMMAND_SPEC): Likewise.
11696         (init_gcc_specs): Likewise.
11697         (init_spec): Likewise.
11698         (display_help): Update help message for -pie.
11699         * doc/invoke.texi: Update -pie, -no-pie and -static.  Document
11700         -static-pie.
11702 2017-09-12  Wilco Dijkstra  <wdijkstr@arm.com>
11704         * config/aarch64/aarch64.md (movsi_aarch64): Remove all '*'.
11705         (movdi_aarch64): Likewise.
11706         (movti_aarch64): Likewise.
11708 2017-09-12 Simon Wright <simon@pushface.org>
11710         PR target/80204
11711         * config/darwin-driver.c (darwin_find_version_from_kernel): Eliminate
11712         calculation of the minor version, always output as 0.
11714 2017-09-12  Jakub Jelinek  <jakub@redhat.com>
11716         PR target/82112
11717         * config/rs6000/rs6000-c.c (altivec_resolve_overloaded_builtin): For
11718         ALTIVEC_BUILTIN_VEC_LD if arg1 has array type call default_conversion
11719         on it early, rather than manual conversion late.  For
11720         ALTIVEC_BUILTIN_VEC_ST if arg2 has array type call default_conversion
11721         instead of performing manual conversion.
11723 2017-09-12  Carl Love  <cel@us.ibm.com>
11725         * config/rs6000/altivec.md (vec_widen_umult_even_v4si,
11726         vec_widen_smult_even_v4si): Add define expands for vmuleuw, vmulesw,
11727         vmulouw, vmulosw.
11728         * config/rs6000/rs6000-builtin.def (VMLEUW, VMULESW, VMULOUW,
11729         VMULOSW): Add definitions.
11730         * config/rs6000/rs6000-c.c (altivec_overloaded_builtins): Add
11731         ALTIVEC_BUILTIN_VMULESW, ALTIVEC_BUILTIN_VMULEUW,
11732         ALTIVEC_BUILTIN_VMULOSW, ALTIVEC_BUILTIN_VMULOUW entries.
11733         * config/rs6000/rs6000.c (rs6000_gimple_fold_builtin,
11734         builtin_function_type): Add ALTIVEC_BUILTIN_* case statements.
11736 2017-09-12  James Greenhalgh  <james.greenhalgh@arm.com>
11738         * config/aarch64/aarch64.md (movdi_aarch64): Set load/store
11739         types correctly.
11740         (movti_aarch64): Likewise.
11741         (movdf_aarch64): Likewise.
11742         (movtf_aarch64): Likewise.
11743         (load_pairdi): Likewise.
11744         (store_pairdi): Likewise.
11745         (load_pairdf): Likewise.
11746         (store_pairdf): Likewise.
11747         (loadwb_pair<GPI:mode>_<P:mode>): Likewise.
11748         (storewb_pair<GPI:mode>_<P:mode>): Likewise.
11749         (ldr_got_small_<mode>): Likewise.
11750         (ldr_got_small_28k_<mode>): Likewise.
11751         (ldr_got_tiny): Likewise.
11752         * config/aarch64/iterators.md (ldst_sz): New.
11753         (ldpstp_sz): Likewise.
11754         * config/aarch64/thunderx.md (thunderx_storepair): Split store_8
11755         to store_16.
11756         (thunderx_load): Split load_8 to load_16.
11757         * config/aarch64/thunderx2t99.md (thunderx2t99_loadpair): Split
11758         load_8 to load_16.
11759         (thunderx2t99_storepair_basic): Split store_8 to store_16.
11760         * config/arm/xgene1.md (xgene1_load_pair): Split load_8 to load_16.
11761         (xgene1_store_pair): Split store_8 to store_16.
11762         * config/aarch64/falkor.md (falkor_ld_3_ld): Split load_8 to load_16.
11763         (falkor_st_0_st_sd): Split store_8 to store_16.
11765 2017-09-12  James Greenhalgh  <james.greenhalgh@arm.com>
11767         * config/arm/types.md (type): Rename load1/2/3/4 to load_4/8/12/16
11768         and store1/2/3/4 to store_4/8/12/16.
11769         * config/aarch64/aarch64.md: Update for rename.
11770         * config/arm/arm.md: Likewise.: Likewise.
11771         * config/arm/arm.c: Likewise.
11772         * config/arm/thumb1.md: Likewise.
11773         * config/arm/thumb2.md: Likewise.
11774         * config/arm/vfp.md: Likewise.
11775         * config/arm/arm-generic.md: Likewise.
11776         * config/arm/arm1020e.md: Likewise.
11777         * config/arm/arm1026ejs.md: Likewise.
11778         * config/arm/arm1136jfs.md: Likewise.
11779         * config/arm/arm926ejs.md: Likewise.
11780         * config/arm/cortex-a15.md: Likewise.
11781         * config/arm/cortex-a17.md: Likewise.
11782         * config/arm/cortex-a5.md: Likewise.
11783         * config/arm/cortex-a53.md: Likewise.
11784         * config/arm/cortex-a57.md: Likewise.
11785         * config/arm/cortex-a7.md: Likewise.
11786         * config/arm/cortex-a8.md: Likewise.
11787         * config/arm/cortex-a9.md: Likewise.
11788         * config/arm/cortex-m4.md: Likewise.
11789         * config/arm/cortex-m7.md: Likewise.
11790         * config/arm/cortex-r4.md: Likewise.
11791         * config/arm/exynos-m1.md: Likewise.
11792         * config/arm/fa526.md: Likewise.
11793         * config/arm/fa606te.md: Likewise.
11794         * config/arm/fa626te.md: Likewise.
11795         * config/arm/fa726te.md: Likewise.
11796         * config/arm/fmp626.md: Likewise.
11797         * config/arm/iwmmxt.md: Likewise.
11798         * config/arm/ldmstm.md: Likewise.
11799         * config/arm/marvell-pj4.md: Likewise.
11800         * config/arm/xgene1.md: Likewise.
11801         * config/aarch64/thunderx.md: Likewise.
11802         * config/aarch64/thunderx2t99.md: Likewise.
11803         * config/aarch64/falkor.md: Likewise.
11805 2017-09-12  Martin Liska  <mliska@suse.cz>
11807         * attribs.c (private_lookup_attribute): New function.
11808         * attribs.h (private_lookup_attribute): Declared here.
11809         (lookup_attribute): Called from this place.
11811 2017-09-12  Richard Biener  <rguenther@suse.de>
11813         PR tree-optimization/82157
11814         * tree-ssa-pre.c (remove_dead_inserted_code): Do not remove
11815         stmts with side-effects.
11817 2017-09-12  Richard Sandiford  <richard.sandiford@linaro.org>
11818             Alan Hayward  <alan.hayward@arm.com>
11819             David Sherwood <david.sherwood@arm.com>
11821         * target.def (hard_regno_nregs): New hook.
11822         (class_max_nregs): Refer to it instead of HARD_REGNO_NREGS.
11823         * targhooks.h (default_hard_regno_nregs): Declare.
11824         * targhooks.c (default_hard_regno_nregs): New function.
11825         * doc/tm.texi.in (HARD_REGNO_NREGS): Replace with...
11826         (TARGET_HARD_REGNO_NREGS): ...this hook.
11827         (HARD_REGNO_NREGS_HAS_PADDING): Update accordingly.
11828         (CLASS_MAX_NREGS): Likewise.
11829         * doc/tm.texi: Regenerate.
11830         * reginfo.c (init_reg_modes_target): Use targetm.hard_regno_nregs
11831         instead of HARD_REGNO_NREGS.
11832         * rtl.h (REG_NREGS): Refer to TARGET_HARD_REGNO_NREGS rather than
11833         HARD_REGNO_NREGS in the comment.
11834         * config/aarch64/aarch64.h (HARD_REGNO_NREGS): Delete.
11835         * config/aarch64/aarch64-protos.h (aarch64_hard_regno_nregs): Delete.
11836         * config/aarch64/aarch64.c (aarch64_hard_regno_nregs): Make static.
11837         Return an unsigned int.
11838         (TARGET_HARD_REGNO_NREGS): Redefine.
11839         * config/alpha/alpha.h (HARD_REGNO_NREGS): Delete.
11840         * config/arc/arc.h (HARD_REGNO_NREGS): Delete.
11841         * config/arc/arc.c (TARGET_HARD_REGNO_NREGS): Redefine.
11842         (arc_hard_regno_nregs): New function.
11843         * config/arm/arm.h (HARD_REGNO_NREGS): Delete.
11844         * config/arm/arm.c (TARGET_HARD_REGNO_NREGS): Redefine.
11845         (arm_hard_regno_nregs): New function.
11846         * config/avr/avr.h (HARD_REGNO_NREGS): Delete.
11847         * config/bfin/bfin.h (HARD_REGNO_NREGS): Delete.
11848         * config/bfin/bfin.c (bfin_hard_regno_nregs): New function.
11849         (TARGET_HARD_REGNO_NREGS): Redefine.
11850         * config/c6x/c6x.h (HARD_REGNO_NREGS): Delete.
11851         * config/cr16/cr16.h (LONG_REG_P): Use targetm.hard_regno_nregs.
11852         (HARD_REGNO_NREGS): Delete.
11853         * config/cr16/cr16.c (TARGET_HARD_REGNO_NREGS): Redefine.
11854         (cr16_hard_regno_nregs): New function.
11855         (cr16_memory_move_cost): Use it instead of HARD_REGNO_NREGS.
11856         * config/cris/cris.h (HARD_REGNO_NREGS): Delete.
11857         * config/cris/cris.c (TARGET_HARD_REGNO_NREGS): Redefine.
11858         (cris_hard_regno_nregs): New function.
11859         * config/epiphany/epiphany.h (HARD_REGNO_NREGS): Delete.
11860         * config/fr30/fr30.h (HARD_REGNO_NREGS): Delete.
11861         (CLASS_MAX_NREGS): Use targetm.hard_regno_nregs.
11862         * config/frv/frv.h (HARD_REGNO_NREGS): Delete.
11863         (CLASS_MAX_NREGS): Remove outdated copy of documentation.
11864         * config/frv/frv-protos.h (frv_hard_regno_nregs): Delete.
11865         * config/frv/frv.c (TARGET_HARD_REGNO_NREGS): Redefine.
11866         (frv_hard_regno_nregs): Make static.  Take and return an
11867         unsigned int.
11868         (frv_class_max_nregs): Remove outdated copy of documentation.
11869         * config/ft32/ft32.h (HARD_REGNO_NREGS): Delete.
11870         * config/h8300/h8300.h (HARD_REGNO_NREGS): Delete.
11871         * config/h8300/h8300-protos.h (h8300_hard_regno_nregs): Delete.
11872         * config/h8300/h8300.c (h8300_hard_regno_nregs): Delete.
11873         * config/i386/i386.h (HARD_REGNO_NREGS): Delete.
11874         * config/i386/i386.c (ix86_hard_regno_nregs): New function.
11875         (TARGET_HARD_REGNO_NREGS): Redefine.
11876         * config/ia64/ia64.h (HARD_REGNO_NREGS): Delete.
11877         (CLASS_MAX_NREGS): Update comment.
11878         * config/ia64/ia64.c (TARGET_HARD_REGNO_NREGS): Redefine.
11879         (ia64_hard_regno_nregs): New function.
11880         * config/iq2000/iq2000.h (HARD_REGNO_NREGS): Delete.
11881         * config/lm32/lm32.h (HARD_REGNO_NREGS): Delete.
11882         * config/m32c/m32c.h (HARD_REGNO_NREGS): Delete.
11883         * config/m32c/m32c-protos.h (m32c_hard_regno_nregs): Delete.
11884         * config/m32c/m32c.c (m32c_hard_regno_nregs_1): Take and return
11885         an unsigned int.
11886         (m32c_hard_regno_nregs): Likewise.  Make static.
11887         (TARGET_HARD_REGNO_NREGS): Redefine.
11888         * config/m32r/m32r.h (HARD_REGNO_NREGS): Delete.
11889         * config/m68k/m68k.h (HARD_REGNO_NREGS): Delete.
11890         * config/m68k/m68k.c (TARGET_HARD_REGNO_NREGS): Redefine.
11891         (m68k_hard_regno_nregs): New function.
11892         * config/mcore/mcore.h (HARD_REGNO_NREGS): Delete.
11893         * config/microblaze/microblaze.h (HARD_REGNO_NREGS): Delete.
11894         * config/mips/mips.h (HARD_REGNO_NREGS): Delete.
11895         * config/mips/mips-protos.h (mips_hard_regno_nregs): Delete.
11896         * config/mips/mips.c (mips_hard_regno_nregs): Make static.
11897         Take and return an unsigned int.
11898         (TARGET_HARD_REGNO_NREGS): Redefine.
11899         * config/mmix/mmix.h (HARD_REGNO_NREGS): Delete.
11900         (CLASS_MAX_NREGS): Use targetm.hard_regno_nregs.
11901         * config/mn10300/mn10300.h (HARD_REGNO_NREGS): Delete.
11902         * config/moxie/moxie.h (HARD_REGNO_NREGS): Delete.
11903         * config/msp430/msp430.h (HARD_REGNO_NREGS): Delete.
11904         * config/msp430/msp430-protos.h (msp430_hard_regno_nregs): Delete.
11905         * config/msp430/msp430.c (TARGET_HARD_REGNO_NREGS): Redefine.
11906         (msp430_hard_regno_nregs): Make static.  Take and return an
11907         unsigned int.
11908         * config/nds32/nds32.h (HARD_REGNO_NREGS): Delete.
11909         * config/nds32/nds32-protos.h (nds32_hard_regno_nregs): Delete.
11910         * config/nds32/nds32.c (nds32_hard_regno_nregs): Delete.
11911         (nds32_hard_regno_mode_ok): Use targetm.hard_regno_nregs.
11912         * config/nios2/nios2.h (HARD_REGNO_NREGS): Delete.
11913         * config/nvptx/nvptx.h (HARD_REGNO_NREGS): Delete.
11914         * config/nvptx/nvptx.c (nvptx_hard_regno_nregs): New function.
11915         (TARGET_HARD_REGNO_NREGS): Redefine.
11916         * config/pa/pa32-regs.h (HARD_REGNO_NREGS): Rename to...
11917         (PA_HARD_REGNO_NREGS): ...this.
11918         * config/pa/pa64-regs.h (HARD_REGNO_NREGS): Rename to...
11919         (PA_HARD_REGNO_NREGS): ...this.
11920         * config/pa/pa.c (TARGET_HARD_REGNO_NREGS): Redefine.
11921         (pa_hard_regno_nregs): New function.
11922         * config/pdp11/pdp11.h (HARD_REGNO_NREGS): Delete.
11923         * config/pdp11/pdp11.c (TARGET_HARD_REGNO_NREGS): Redefine.
11924         (pdp11_hard_regno_nregs): New function.
11925         * config/powerpcspe/powerpcspe.h (HARD_REGNO_NREGS): Delete.
11926         * config/powerpcspe/powerpcspe.c (TARGET_HARD_REGNO_NREGS): Redefine.
11927         (rs6000_hard_regno_nregs_hook): New function.
11928         * config/riscv/riscv.h (HARD_REGNO_NREGS): Delete.
11929         * config/riscv/riscv-protos.h (riscv_hard_regno_nregs): Delete.
11930         * config/riscv/riscv.c (riscv_hard_regno_nregs): Make static.
11931         Take and return an unsigned int.  Move earlier in file.
11932         (TARGET_HARD_REGNO_NREGS): Redefine.
11933         * config/rl78/rl78.h (HARD_REGNO_NREGS): Delete.
11934         * config/rl78/rl78-protos.h (rl78_hard_regno_nregs): Delete.
11935         * config/rl78/rl78.c (TARGET_HARD_REGNO_NREGS): Reefine.
11936         (rl78_hard_regno_nregs): Make static.  Take and return an
11937         unsigned int.
11938         * config/rs6000/rs6000.h (HARD_REGNO_NREGS): Delete.
11939         * config/rs6000/rs6000.c (TARGET_HARD_REGNO_NREGS): Redefine.
11940         (rs6000_hard_regno_nregs_hook): New function.
11941         * config/rx/rx.h (HARD_REGNO_NREGS): Delete.
11942         * config/rx/rx.c (rx_hard_regno_nregs): New function.
11943         (TARGET_HARD_REGNO_NREGS): Redefine.
11944         * config/s390/s390.h (HARD_REGNO_NREGS): Delete.
11945         * config/s390/s390.c (REGNO_PAIR_OK): Use s390_hard_regno_nregs
11946         instead of HARD_REGNO_NREGS.
11947         (s390_hard_regno_nregs): New function.
11948         (s390_hard_regno_mode_ok): Add comment from s390.h.
11949         (TARGET_HARD_REGNO_NREGS): Redefine.
11950         * config/sh/sh.h (HARD_REGNO_NREGS): Delete.
11951         * config/sh/sh.c (TARGET_HARD_REGNO_NREGS): Redefine.
11952         (sh_hard_regno_nregs): New function.
11953         (sh_pass_in_reg_p): Use it.
11954         * config/sparc/sparc.h (HARD_REGNO_NREGS): Delete.
11955         * config/sparc/sparc.c (TARGET_HARD_REGNO_NREGS): Redefine.
11956         (sparc_hard_regno_nregs): New function.
11957         * config/spu/spu.h (HARD_REGNO_NREGS): Delete.
11958         * config/spu/spu.c (spu_hard_regno_nregs): New function.
11959         (spu_function_arg_advance): Use it, supplying a valid register number.
11960         (TARGET_HARD_REGNO_NREGS): Redefine.
11961         * config/stormy16/stormy16.h (HARD_REGNO_NREGS): Delete.
11962         * config/tilegx/tilegx.h (HARD_REGNO_NREGS): Delete.
11963         * config/tilepro/tilepro.h (HARD_REGNO_NREGS): Delete.
11964         * config/v850/v850.h (HARD_REGNO_NREGS): Delete.
11965         * config/vax/vax.h (HARD_REGNO_NREGS): Delete.
11966         * config/visium/visium.h (HARD_REGNO_NREGS): Delete.
11967         (CLASS_MAX_NREGS): Remove copy of old documentation.
11968         * config/visium/visium.c (TARGET_HARD_REGNO_NREGS): Redefine.
11969         (visium_hard_regno_nregs): New function.
11970         (visium_hard_regno_mode_ok): Use it instead of HARD_REGNO_NREGS.
11971         * config/xtensa/xtensa.h (HARD_REGNO_NREGS): Delete.
11972         * config/xtensa/xtensa.c (TARGET_HARD_REGNO_NREGS): Redefine.
11973         xtensa_hard_regno_nregs): New function.
11974         * system.h (HARD_REGNO_NREGS): Poison.
11976 2017-09-12  Richard Sandiford  <richard.sandiford@linaro.org>
11978         * config/arm/arm.h (THUMB_SECONDARY_INPUT_RELOAD_CLASS): Use
11979         hard_regno_nregs instead of HARD_REGNO_NREGS.
11980         (THUMB_SECONDARY_OUTPUT_RELOAD_CLASS): Likewise.
11981         * config/c6x/c6x.c (c6x_expand_prologue): Likewise.
11982         (c6x_expand_epilogue): Likewise.
11983         * config/frv/frv.c (frv_alloc_temp_reg): Likewise.
11984         (frv_read_iacc_argument): Likewise.
11985         * config/sh/sh.c: Include regs.h.
11986         (sh_print_operand): Use hard_regno_nregs instead of HARD_REGNO_NREGS.
11987         (regs_used): Likewise.
11988         (output_stack_adjust): Likewise.
11989         * config/xtensa/xtensa.c (xtensa_copy_incoming_a7): Likewise.
11990         * expmed.c: Include regs.h.
11991         (store_bit_field_1): Use hard_regno_nregs instead of HARD_REGNO_NREGS.
11992         * ree.c: Include regs.h.
11993         (combine_reaching_defs): Use hard_regno_nregs instead of
11994         HARD_REGNO_NREGS.
11995         (add_removable_extension): Likewise.
11997 2017-09-12  Richard Sandiford  <richard.sandiford@linaro.org>
11999         * regs.h (hard_regno_nregs): Turn into a function.
12000         (end_hard_regno): Update accordingly.
12001         * caller-save.c (setup_save_areas): Likewise.
12002         (save_call_clobbered_regs): Likewise.
12003         (replace_reg_with_saved_mem): Likewise.
12004         (insert_restore): Likewise.
12005         (insert_save): Likewise.
12006         * combine.c (can_change_dest_mode): Likewise.
12007         (move_deaths): Likewise.
12008         (distribute_notes): Likewise.
12009         * config/mips/mips.c (mips_hard_regno_call_part_clobbered): Likewise.
12010         * config/powerpcspe/powerpcspe.c (rs6000_cannot_change_mode_class)
12011         (rs6000_split_multireg_move): Likewise.
12012         (rs6000_register_move_cost): Likewise.
12013         (rs6000_memory_move_cost): Likewise.
12014         * config/rs6000/rs6000.c (rs6000_cannot_change_mode_class): Likewise.
12015         (rs6000_split_multireg_move): Likewise.
12016         (rs6000_register_move_cost): Likewise.
12017         (rs6000_memory_move_cost): Likewise.
12018         * cselib.c (cselib_reset_table): Likewise.
12019         (cselib_lookup_1): Likewise.
12020         * emit-rtl.c (set_mode_and_regno): Likewise.
12021         * function.c (aggregate_value_p): Likewise.
12022         * ira-color.c (setup_profitable_hard_regs): Likewise.
12023         (check_hard_reg_p): Likewise.
12024         (calculate_saved_nregs): Likewise.
12025         (assign_hard_reg): Likewise.
12026         (improve_allocation): Likewise.
12027         (calculate_spill_cost): Likewise.
12028         * ira-emit.c (modify_move_list): Likewise.
12029         * ira-int.h (ira_hard_reg_set_intersection_p): Likewise.
12030         (ira_hard_reg_in_set_p): Likewise.
12031         * ira.c (setup_reg_mode_hard_regset): Likewise.
12032         (clarify_prohibited_class_mode_regs): Likewise.
12033         (check_allocation): Likewise.
12034         * lra-assigns.c (find_hard_regno_for_1): Likewise.
12035         (lra_setup_reg_renumber): Likewise.
12036         (setup_try_hard_regno_pseudos): Likewise.
12037         (spill_for): Likewise.
12038         (assign_hard_regno): Likewise.
12039         (setup_live_pseudos_and_spill_after_risky_transforms): Likewise.
12040         * lra-constraints.c (in_class_p): Likewise.
12041         (lra_constraint_offset): Likewise.
12042         (simplify_operand_subreg): Likewise.
12043         (lra_constraints): Likewise.
12044         (split_reg): Likewise.
12045         (split_if_necessary): Likewise.
12046         (invariant_p): Likewise.
12047         (inherit_in_ebb): Likewise.
12048         * lra-lives.c (process_bb_lives): Likewise.
12049         * lra-remat.c (reg_overlap_for_remat_p): Likewise.
12050         (get_hard_regs): Likewise.
12051         (do_remat): Likewise.
12052         * lra-spills.c (assign_spill_hard_regs): Likewise.
12053         * mode-switching.c (create_pre_exit): Likewise.
12054         * postreload.c (reload_combine_recognize_pattern): Likewise.
12055         * recog.c (peep2_find_free_register): Likewise.
12056         * regcprop.c (kill_value_regno): Likewise.
12057         (set_value_regno): Likewise.
12058         (copy_value): Likewise.
12059         (maybe_mode_change): Likewise.
12060         (find_oldest_value_reg): Likewise.
12061         (copyprop_hardreg_forward_1): Likewise.
12062         * regrename.c (check_new_reg_p): Likewise.
12063         (regrename_do_replace): Likewise.
12064         * reload.c (push_reload): Likewise.
12065         (combine_reloads): Likewise.
12066         (find_dummy_reload): Likewise.
12067         (operands_match_p): Likewise.
12068         (find_reloads): Likewise.
12069         (find_equiv_reg): Likewise.
12070         (reload_adjust_reg_for_mode): Likewise.
12071         * reload1.c (count_pseudo): Likewise.
12072         (count_spilled_pseudo): Likewise.
12073         (find_reg): Likewise.
12074         (clear_reload_reg_in_use): Likewise.
12075         (free_for_value_p): Likewise.
12076         (allocate_reload_reg): Likewise.
12077         (choose_reload_regs): Likewise.
12078         (reload_adjust_reg_for_temp): Likewise.
12079         (emit_reload_insns): Likewise.
12080         (delete_output_reload): Likewise.
12081         * rtlanal.c (subreg_get_info): Likewise.
12082         * sched-deps.c (sched_analyze_reg): Likewise.
12083         * sel-sched.c (init_regs_for_mode): Likewise.
12084         (mark_unavailable_hard_regs): Likewise.
12085         (choose_best_reg_1): Likewise.
12086         (verify_target_availability): Likewise.
12087         * valtrack.c (dead_debug_insert_temp): Likewise.
12088         * var-tracking.c (track_loc_p): Likewise.
12089         (emit_note_insn_var_location): Likewise.
12090         * varasm.c (make_decl_rtl): Likewise.
12091         * reginfo.c (choose_hard_reg_mode): Likewise.
12092         (init_reg_modes_target): Refer directly to
12093         this_target_regs->x_hard_regno_nregs.
12095 2017-09-12  Richard Sandiford  <richard.sandiford@linaro.org>
12097         * ira-costs.c (record_operand_costs): Use in_hard_reg_set_p
12098         instead of hard_regno_nregs.
12100 2017-09-12  Richard Sandiford  <richard.sandiford@linaro.org>
12102         * config/aarch64/aarch64.c (aarch64_hard_regno_mode_ok): Use
12103         end_hard_regno instead of hard_regno_nregs.
12104         * config/s390/s390.c (s390_reg_clobbered_rtx): Likewise.
12105         * config/sparc/sparc.h (ASM_DECLARE_REGISTER_GLOBAL): Likewise.
12106         * config/visium/visium.c (visium_hard_regno_mode_ok): Likewise.
12107         * ira-color.c (improve_allocation): Likewise.
12108         * lra-assigns.c (find_hard_regno_for_1): Likewise.
12109         * lra-lives.c (mark_regno_live): Likewise.
12110         (mark_regno_dead): Likewise.
12111         * lra-remat.c (operand_to_remat): Likewise.
12112         * lra.c (collect_non_operand_hard_regs): Likewise.
12113         * postreload.c (reload_combine_note_store): Likewise.
12114         (move2add_valid_value_p): Likewise.
12115         * reload.c (regno_clobbered_p): Likewise.
12117 2017-09-12  Richard Sandiford  <richard.sandiford@linaro.org>
12119         * config/frv/frv.c (FOR_EACH_REGNO): Use END_REGNO instead of
12120         hard_regno_nregs.
12121         * config/v850/v850.c (v850_reorg): Likewise.
12122         * reload.c (refers_to_regno_for_reload_p): Likewise.
12123         (find_equiv_reg): Likewise.
12124         * reload1.c (reload_reg_reaches_end_p): Likewise.
12126 2017-09-12  Richard Sandiford  <richard.sandiford@linaro.org>
12128         * caller-save.c (add_used_regs): Use REG_NREGS instead of
12129         hard_regno_nregs.
12130         * config/aarch64/aarch64.c (aarch64_split_combinev16qi): Likewise.
12131         * config/arm/arm.c (output_move_neon): Likewise.
12132         (arm_attr_length_move_neon): Likewise.
12133         (neon_split_vcombine): Likewise.
12134         * config/c6x/c6x.c (c6x_mark_reg_read): Likewise.
12135         (c6x_mark_reg_written): Likewise.
12136         (c6x_dwarf_register_span): Likewise.
12137         * config/i386/i386.c (ix86_save_reg): Likewise.
12138         * config/ia64/ia64.c (mark_reg_gr_used_mask): Likewise.
12139         (rws_access_reg): Likewise.
12140         * config/s390/s390.c (s390_call_saved_register_used): Likewise.
12141         * mode-switching.c (create_pre_exit): Likewise.
12142         * ree.c (combine_reaching_defs): Likewise.
12143         (add_removable_extension): Likewise.
12144         * regcprop.c (find_oldest_value_reg): Likewise.
12145         (copyprop_hardreg_forward_1): Likewise.
12146         * reload.c (reload_inner_reg_of_subreg): Likewise.
12147         (push_reload): Likewise.
12148         (combine_reloads): Likewise.
12149         (find_dummy_reload): Likewise.
12150         (reload_adjust_reg_for_mode): Likewise.
12151         * reload1.c (find_reload_regs): Likewise.
12152         (forget_old_reloads_1): Likewise.
12153         (reload_reg_free_for_value_p): Likewise.
12154         (reload_adjust_reg_for_temp): Likewise.
12155         (emit_reload_insns): Likewise.
12156         (delete_output_reload): Likewise.
12157         * sel-sched.c (choose_best_reg_1): Likewise.
12158         (choose_best_pseudo_reg): Likewise.
12160 2017-09-12  Richard Sandiford  <richard.sandiford@linaro.org>
12161             Alan Hayward  <alan.hayward@arm.com>
12162             David Sherwood <david.sherwood@arm.com>
12164         * defaults.h (SLOW_UNALIGNED_ACCESS): Delete.
12165         * target.def (slow_unaligned_access): New hook.
12166         * targhooks.h (default_slow_unaligned_access): Declare.
12167         * targhooks.c (default_slow_unaligned_access): New function.
12168         * doc/tm.texi.in (SLOW_UNALIGNED_ACCESS): Replace with...
12169         (TARGET_SLOW_UNALIGNED_ACCESS): ...this.
12170         * doc/tm.texi: Regenerate.
12171         * config/alpha/alpha.h (SLOW_UNALIGNED_ACCESS): Delete.
12172         * config/arm/arm.h (SLOW_UNALIGNED_ACCESS): Delete.
12173         * config/i386/i386.h (SLOW_UNALIGNED_ACCESS): Delete commented-out
12174         definition.
12175         * config/powerpcspe/powerpcspe.h (SLOW_UNALIGNED_ACCESS): Delete.
12176         * config/powerpcspe/powerpcspe.c (TARGET_SLOW_UNALIGNED_ACCESS):
12177         Redefine.
12178         (rs6000_slow_unaligned_access): New function.
12179         (rs6000_emit_move): Use it instead of SLOW_UNALIGNED_ACCESS.
12180         (expand_block_compare): Likewise.
12181         (expand_strn_compare): Likewise.
12182         (rs6000_rtx_costs): Likewise.
12183         * config/riscv/riscv.h (SLOW_UNALIGNED_ACCESS): Delete.
12184         (riscv_slow_unaligned_access): Likewise.
12185         * config/riscv/riscv.c (riscv_slow_unaligned_access): Rename to...
12186         (riscv_slow_unaligned_access_p): ...this and make static.
12187         (riscv_option_override): Update accordingly.
12188         (riscv_slow_unaligned_access): New function.
12189         (TARGET_SLOW_UNALIGNED_ACCESS): Redefine.
12190         * config/rs6000/rs6000.h (SLOW_UNALIGNED_ACCESS): Delete.
12191         * config/rs6000/rs6000.c (TARGET_SLOW_UNALIGNED_ACCESS): Redefine.
12192         (rs6000_slow_unaligned_access): New function.
12193         (rs6000_emit_move): Use it instead of SLOW_UNALIGNED_ACCESS.
12194         (rs6000_rtx_costs): Likewise.
12195         * config/rs6000/rs6000-string.c (expand_block_compare)
12196         (expand_strn_compare): Use targetm.slow_unaligned_access instead
12197         of SLOW_UNALIGNED_ACCESS.
12198         * config/tilegx/tilegx.h (SLOW_UNALIGNED_ACCESS): Delete.
12199         * config/tilepro/tilepro.h (SLOW_UNALIGNED_ACCESS): Delete.
12200         * calls.c (expand_call): Use targetm.slow_unaligned_access instead
12201         of SLOW_UNALIGNED_ACCESS.
12202         * expmed.c (simple_mem_bitfield_p): Likewise.
12203         * expr.c (alignment_for_piecewise_move): Likewise.
12204         (emit_group_load_1): Likewise.
12205         (emit_group_store): Likewise.
12206         (copy_blkmode_from_reg): Likewise.
12207         (emit_push_insn): Likewise.
12208         (expand_assignment): Likewise.
12209         (store_field): Likewise.
12210         (expand_expr_real_1): Likewise.
12211         * gimple-fold.c (gimple_fold_builtin_memory_op): Likewise.
12212         * lra-constraints.c (simplify_operand_subreg): Likewise.
12213         * stor-layout.c (bit_field_mode_iterator::next_mode): Likewise.
12214         * gimple-ssa-store-merging.c: Likewise in block comment at start
12215         of file.
12216         * tree-ssa-strlen.c: Include target.h.
12217         (handle_builtin_memcmp): Use targetm.slow_unaligned_access instead
12218         of SLOW_UNALIGNED_ACCESS.
12219         * system.h (SLOW_UNALIGNED_ACCESS): Poison.
12221 2017-09-12  Richard Sandiford  <richard.sandiford@linaro.org>
12223         PR rtl-optimization/82185
12224         * expmed.c (emit_store_flag_int): Only test tem if it has been
12225         initialized.
12227 2017-09-12  Richard Biener  <rguenther@suse.de>
12229         PR middle-end/82149
12230         * match.pd ((FTYPE) N CMP CST): Fix typo.
12232 2017-09-12  Simon Atanasyan  <simon.atanasyan@imgtec.com>
12234         * config/mips/mips.c (mips_attribute_table): Add 'short_call'
12235         attribute.
12236         (mips_near_type_p): Add 'short_call' attribute as a synonym
12237         for 'near'.
12238         * doc/extend.texi (short_call): Document new function attribute.
12240 2017-09-12  Jakub Jelinek  <jakub@redhat.com>
12242         PR target/82112
12243         * c-common.c (sync_resolve_size): Instead of c_dialect_cxx ()
12244         assertion check that in the condition.
12245         (get_atomic_generic_size): Likewise.  Before testing if parameter
12246         has pointer type, if it has array type, call for C++
12247         default_conversion to perform array-to-pointer conversion.
12249 2017-09-12  Richard Biener  <rguenther@suse.de>
12251         * tree-vect-generic.c (expand_vector_operations_1): Do nothing
12252         for operations we cannot scalarize.
12254 2017-09-12  Aldy Hernandez  <aldyh@redhat.com>
12256         * tree-ssa-threadbackward.c (fsm_find_thread_path): Make GC
12257         vectors heap vectors.  Clean up comments.
12258         Make visited_bbs a reference.
12259         (profitable_jump_thread_path): Make GC
12260         vectors heap vectors.  Clean up comments.
12261         Misc cleanups.
12262         (convert_and_register_jump_thread_path): Make GC vectors heap
12263         vectors.
12264         (check_subpath_and_update_thread_path): Same.  Clean up comments.
12265         Make visited_bbs a reference.
12266         (handle_phi): Abstract common code to to
12267         register_jump_thread_path_if_profitable.
12268         Rename VAR_BB to DEF_BB.
12269         Update comments.
12270         Make GC vectors heap vectors.
12271         Make visited_bbs a reference.
12272         (handle_assignment): Same.
12273         (register_jump_thread_path_if_profitable): New.
12274         (fsm_find_control_statement_thread_paths): Rename VAR_BB to
12275         DEF_BB.
12276         Make GC vectors heap vectors.  Clean up comments.
12277         Make visited_bbs a reference.
12278         (find_jump_threads_backwards): Make visited_bbs live in the stack.
12279         * tree-ssa-threadupdate.c (delete_jump_thread_path): Fix typo in
12280         comment.
12282 2017-09-11  Max Filippov  <jcmvbkbc@gmail.com>
12284         PR target/82181
12285         * config/xtensa/xtensa.c (xtensa_mem_offset): Check that both
12286         words of E_DImode object are reachable by xtensa_uimm8x4 access.
12288 2017-09-11  Vidya Praveen  <vidyapraveen@arm.com>
12290         Revert r251800 and r251799.
12292 2017-09-11  Martin Jambor  <mjambor@suse.cz>
12294         PR hsa/82119
12295         * hsa-gen.c (gen_hsa_phi_from_gimple_phi): Process ADDR_EXPRs in
12296         arguments in advance.
12297         * hsa-regalloc.c (naive_process_phi): New parameter predecessors,
12298         use it to find predecessor edges.
12299         (naive_outof_ssa): Collect vector of predecessors.
12301 2017-09-08  Jason Merrill  <jason@redhat.com>
12303         PR c++/70029 - ICE with ref-qualifier and -flto
12304         * langhooks.h (struct lang_hooks_for_types): Add
12305         copy_lang_qualifiers.
12306         * attribs.c (build_type_attribute_qual_variant): Use it.
12307         * langhooks-def.h (LANG_HOOKS_COPY_LANG_QUALIFIERS): Default to
12308         NULL.
12309         (LANG_HOOKS_FOR_TYPES_INITIALIZER): Use it.
12310         * tree.c (verify_type): Re-enable TYPE_CANONICAL main variant check.
12312 2017-09-08  Eric Botcazou  <ebotcazou@adacore.com>
12314         PR target/81988
12315         * config/sparc/sparc.md (mulsi3): Rename into *mulsi3_sp32.
12316         (*mulsi3_sp64): New instruction.
12317         (mulsi3): New expander.
12319 2017-09-08  Uros Bizjak  <ubizjak@gmail.com>
12321         * config/alpha/alpha.c (alpha_print_operand) <case 'S'>: Remove.
12323 2017-09-08  Rainer Orth  <ro@CeBiTec.Uni-Bielefeld.DE>
12325         * sancov.c: Include memmodel.h.
12327 2017-09-07  Eric Botcazou  <ebotcazou@adacore.com>
12329         PR target/80897
12330         * config/sparc/sparc.c (sparc_emit_set_symbolic_const64): Deal with too
12331         large offsets.
12333 2017-09-07  Carl Love  <cel@us.ibm.com>
12335         * config/rs6000/vsx.md (define_insn "*stxvl"): Add missing argument to
12336         the sldi instruction.
12338 2017-09-07  David Edelsohn  <dje.gcc@gmail.com>
12340         * sancov.c: Include tm_p.h.
12342 2017-09-07  Jakub Jelinek  <jakub@redhat.com>
12344         PR target/81979
12345         * output.h (switch_to_other_text_partition): New declaration.
12346         * varasm.c (switch_to_other_text_partition): New function.
12347         * config/rs6000/rs6000.c (uses_TOC): Return 2 if
12348         NOTE_INSN_SWITCH_TEXT_SECTIONS is seen before finding load_toc_* insn.
12349         (rs6000_elf_declare_function_name): If uses_TOC returned 2, switch
12350         to the other text partition before emitting LCL label and switch back
12351         after emitting the word after it.
12353 2017-09-07  Richard Biener  <rguenther@suse.de>
12355         * passes.def (pass_split_crit_edges): Remove instance before PRE.
12356         * tree-ssa-pre.c (pass_pre::execute): Instead manually split
12357         critical edges here, after loop init.
12358         (pass_data_pre): Remove PROP_no_crit_edges flags.
12359         * tree-ssa-sccvn.c (vn_reference_lookup_3): Use vn_valueize
12360         for valueization of call args to avoid leaking VN_TOP.
12361         (visit_use): Assert we do not visit default defs.
12362         (init_scc_vn): Use build_decl for VN_TOP to make name nicer.
12363         Use error_mark_node to more easily detect leaking VN_TOP.
12364         All default-defs are varying, not VN_TOP.  Mark them visited.
12365         (run_scc_vn): Make code match comment.
12367 2017-09-07  Michael Meissner  <meissner@linux.vnet.ibm.com>
12369         * config/rs6000/rs6000-cpus.def (OTHER_VSX_VECTOR_MASKS): Delete
12370         OPTION_MASK_FLOAT128_KEYWORD.
12371         (POWERPC_MASKS): Likewise.
12372         * config/rs6000/rs6000-c.c (rs6000_target_modify_macros): Delete
12373         support for the -mfloat128-type option, and make -mfloat128
12374         default on PowerPC Linux systems.  Define or undefine
12375         __FLOAT128__ and  __FLOAT128_HARDWARE__ for the current options.
12376         Define __float128 to be __ieee128 if IEEE 128-bit support is
12377         enabled, or undefine it.
12378         (rs6000_cpu_cpp_builtins): Delete defining __FLOAT128__ here.
12379         Delete defining __FLOAT128_TYPE__.
12380         * config/rs6000/rs6000.opt (x_TARGET_FLOAT128_TYPE): Delete the
12381         -mfloat128-type option and make -mfloat128 default on PowerPC
12382         Linux systems.
12383         (TARGET_FLOAT128_TYPE): Likewise.
12384         (-mfloat128-type): Likewise.
12385         * config/rs6000/rs6000.c (rs6000_option_override_internal):
12386         Delete the -mfloat128-type option and make -mfloat128 default on
12387         PowerPC Linux systems.  Always use __ieee128 to be the keyword for
12388         the IEEE 128-bit type, and map __float128 to __ieee128 if IEEE
12389         128-bit floating point is enabled.  Change tests from using
12390         -mfloat128-type to -mfloat128.
12391         (rs6000_mangle_type): Use the correct mangling for the __float128
12392         type even if normal long double is restricted to 64-bits.
12393         (floatn_mode): Enable the _Float128 type by default on VSX Linux
12394         systems.
12395         * config/rs6000/rs6000.h (MASK_FLOAT128_TYPE): Delete.
12396         (MASK_FLOAT128_KEYWORD): Define new shortcut macro.
12397         (RS6000BTM_FLOAT128): Define in terms of -mfloat128, not
12398         -mfloat128-type.
12399         * doc/invoke.texi (RS/6000 and PowerPC Options): Update
12400         documentation for -mfloat128.
12402 2017-09-06  Olivier Hainque  <hainque@adacore.com>
12404         * config.gcc (powerpc-wrs-vxworksspe): Now match as vxworks*spe.
12406 2017-09-06  Wish Wu  <wishwu007@gmail.com>
12407             Jakub Jelinek  <jakub@redhat.com>
12409         * asan.c (initialize_sanitizer_builtins): Add
12410         BT_FN_VOID_UINT8_UINT8, BT_FN_VOID_UINT16_UINT16,
12411         BT_FN_VOID_UINT32_UINT32, BT_FN_VOID_UINT64_UINT64,
12412         BT_FN_VOID_FLOAT_FLOAT, BT_FN_VOID_DOUBLE_DOUBLE and
12413         BT_FN_VOID_UINT64_PTR variables.
12414         * builtin-types.def (BT_FN_VOID_UINT8_UINT8): New fn type.
12415         (BT_FN_VOID_UINT16_UINT16): Likewise.
12416         (BT_FN_VOID_UINT32_UINT32): Likewise.
12417         (BT_FN_VOID_FLOAT_FLOAT): Likewise.
12418         (BT_FN_VOID_DOUBLE_DOUBLE): Likewise.
12419         (BT_FN_VOID_UINT64_PTR): Likewise.
12420         * common.opt (flag_sanitize_coverage): New variable.
12421         (fsanitize-coverage=trace-pc): Remove.
12422         (fsanitize-coverage=): Add.
12423         * flag-types.h (enum sanitize_coverage_code): New enum.
12424         * fold-const.c (fold_range_test): Disable non-short-circuit
12425         optimization if flag_sanitize_coverage.
12426         (fold_truth_andor): Likewise.
12427         * tree-ssa-ifcombine.c (ifcombine_ifandif): Likewise.
12428         * opts.c (COVERAGE_SANITIZER_OPT): Define.
12429         (coverage_sanitizer_opts): New array.
12430         (get_closest_sanitizer_option): Add OPTS argument, handle also
12431         OPT_fsanitize_coverage_.
12432         (parse_sanitizer_options): Adjusted to also handle
12433         OPT_fsanitize_coverage_.
12434         (common_handle_option): Add OPT_fsanitize_coverage_.
12435         * sancov.c (instrument_comparison, instrument_switch): New function.
12436         (sancov_pass): Add trace-cmp support.
12437         * sanitizer.def (BUILT_IN_SANITIZER_COV_TRACE_CMP1,
12438         BUILT_IN_SANITIZER_COV_TRACE_CMP2, BUILT_IN_SANITIZER_COV_TRACE_CMP4,
12439         BUILT_IN_SANITIZER_COV_TRACE_CMP8,
12440         BUILT_IN_SANITIZER_COV_TRACE_CONST_CMP1,
12441         BUILT_IN_SANITIZER_COV_TRACE_CONST_CMP2,
12442         BUILT_IN_SANITIZER_COV_TRACE_CONST_CMP4,
12443         BUILT_IN_SANITIZER_COV_TRACE_CONST_CMP8,
12444         BUILT_IN_SANITIZER_COV_TRACE_CMPF, BUILT_IN_SANITIZER_COV_TRACE_CMPD,
12445         BUILT_IN_SANITIZER_COV_TRACE_SWITCH): New builtins.
12446         * doc/invoke.texi: Document -fsanitize-coverage=trace-cmp.
12448 2017-09-06  Richard Earnshaw  <rearnsha@arm.com>
12450         * config/arm/parsecpu.awk (fatal): Note that we've encountered an
12451         error.  Only quit immediately if parsing is complete.
12452         (BEGIN): Initialize fatal_err and parse_done.
12453         (begin fpu, end fpu): Check number of arguments.
12454         (begin arch, end arch): Likewise.
12455         (begin cpu, end cpu): Likewise.
12456         (cname, tune for, tune flags, architecture, fpu, option): Likewise.
12457         (optalias): Likewise.
12459 2017-09-06  Richard Earnshaw  <rearnsha@arm.com>
12461         * config.gcc (arm*-*-*): Don't add arm-isa.h to tm_p_file.
12462         * config/arm/arm-isa.h: Delete.  Move definitions to ...
12463         * arm-cpus.in: ... here.  Use new feature and fgroup values.
12464         * config/arm/arm.c (arm_option_override): Use lower case for feature
12465         bit names.
12466         * config/arm/arm.h (TARGET_HARD_FLOAT): Likewise.
12467         (TARGET_VFP3, TARGET_VFP5, TARGET_FMA): Likewise.
12468         * config/arm/parsecpu.awk (END): Add new command 'isa'.
12469         (isa_pfx): Delete.
12470         (print_isa_bits_for): New function.
12471         (gen_isa): New function.
12472         (gen_comm_data): Use print_isa_bits_for.
12473         (define feature): New keyword.
12474         (define fgroup): New keyword.
12475         * config/arm/t-arm (OPTIONS_H_EXTRA): Add arm-isa.h
12476         (arm-isa.h): Add rule to generate file.
12477         * common/config/arm/arm-common.c: (arm_canon_arch_option): Use lower
12478         case for feature bit names.
12480 2017-09-06  Richard Biener  <rguenther@suse.de>
12482         * tree-ssa-pre.c (NECESSARY): Remove.
12483         (create_expression_by_pieces): Do not touch pass-local flags.
12484         (insert_into_preds_of_block): Likewise.
12485         (do_pre_regular_insertion): Likewise.
12486         (eliminate_insert): Likewise.
12487         (eliminate_dom_walker::before_dom_children): Likewise.
12488         (fini_eliminate): Do not look at inserted_exprs.
12489         (mark_operand_necessary): Remove.
12490         (remove_dead_inserted_code): Replace with simple work-list
12491         algorithm based on inserted_exprs and SSA uses.
12492         (pass_pre::execute): Re-order fini_eliminate and
12493         remove_dead_inserted_code.
12495 2017-09-06  Olivier Hainque  <hainque@adacore.com>
12497         * config/powerpcspe/vxworks.h (VXCPU_FOR_8548): Correct definition
12498         for VxWorks 7.  Adjust surrounding comments.
12500 2017-09-06  Richard Biener  <rguenther@suse.de>
12502         * gimple-ssa-strength-reduction.c
12503         (find_candidates_dom_walker::before_dom_children): Also allow
12504         pointer types.
12506 2017-09-06  Richard Biener  <rguenther@suse.de>
12508         PR tree-optimization/82108
12509         * tree-vect-stmts.c (vectorizable_load): Fix pointer adjustment
12510         for gap in the non-permutation SLP case.
12512 2017-09-06  Martin Jambor  <mjambor@suse.cz>
12514         PR tree-optimization/82078
12515         * tree-sra.c (sort_and_splice_var_accesses): Move call to
12516         add_access_to_work_queue...
12517         (build_accesses_from_assign): ...here.
12518         (propagate_all_subaccesses): Make sure racc is the group
12519         representative, if there is one.
12521 2017-09-06  Jakub Jelinek  <jakub@redhat.com>
12523         PR middle-end/82095
12524         * varasm.c (categorize_decl_for_section): Use SECCAT_TBSS for TLS vars with
12525         NULL DECL_INITIAL.
12527 2017-09-06  Richard Biener  <rguenther@suse.de>
12529         * gimple-ssa-strength-reduction.c
12530         (find_candidates_dom_walker::before_doom_children): Use a
12531         type and not a mode check.
12533 2017-09-06  Bernd Edlinger  <bernd.edlinger@hotmail.de>
12535         PR target/77308
12536         * config/arm/predicates.md (arm_general_adddi_operand): Create new
12537         non-vfp predicate.
12538         * config/arm/arm.md (*arm_adddi3, *arm_subdi3): Use new predicates.
12540 2017-09-05  Jeff Law  <law@redhat.com>
12542         PR tree-optimization/64910
12543         * tree-ssa-reassoc.c (reassociate_bb): Restrict last change to
12544         cases where we have 3 or more operands.
12546 2017-09-05  Jakub Jelinek  <jakub@redhat.com>
12548         PR middle-end/81768
12549         * omp-low.c (lower_omp_for): Recompute tree invariant if
12550         gimple_omp_for_initial/final is ADDR_EXPR.
12552         PR middle-end/81768
12553         * omp-expand.c (expand_omp_simd): Force second operands of COND_EXPR
12554         into gimple val before gimplification fo the COND_EXPR.
12556 2017-09-05  Aldy Hernandez  <aldyh@redhat.com>
12558         * tree-ssa-threadupdate.c (duplicate_thread_path): Remove unused
12559         REGION_COPY argument.
12560         (thread_through_all_blocks): Remove unused argument to
12561         duplicate_thread_path.
12563 2017-09-05  Richard Sandiford  <richard.sandiford@linaro.org>
12564             Alan Hayward  <alan.hayward@arm.com>
12565             David Sherwood  <david.sherwood@arm.com>
12567         * config/aarch64/aarch64-protos.h (aarch64_gen_adjusted_ldpstp):
12568         Take a scalar_mode rather than a machine_mode.
12569         (aarch64_operands_adjust_ok_for_ldpstp): Likewise.
12570         * config/aarch64/aarch64.c (aarch64_simd_container_mode): Likewise.
12571         (aarch64_operands_adjust_ok_for_ldpstp): Likewise.
12572         (aarch64_gen_adjusted_ldpstp): Likewise.
12573         (aarch64_expand_vector_init): Use scalar_mode instead of machine_mode.
12575 2017-09-05  Richard Sandiford  <richard.sandiford@linaro.org>
12576             Alan Hayward  <alan.hayward@arm.com>
12577             David Sherwood  <david.sherwood@arm.com>
12579         * config/aarch64/aarch64-protos.h (aarch64_is_extend_from_extract):
12580         Take a scalar_int_mode instead of a machine_mode.
12581         (aarch64_mask_and_shift_for_ubfiz_p): Likewise.
12582         (aarch64_output_scalar_simd_mov_immediate): Likewise.
12583         (aarch64_simd_scalar_immediate_valid_for_move): Likewise.
12584         (aarch64_simd_attr_length_rglist): Delete.
12585         * config/aarch64/aarch64.c (aarch64_is_extend_from_extract): Take
12586         a scalar_int_mode instead of a machine_mode.
12587         (aarch64_add_offset): Likewise.
12588         (aarch64_internal_mov_immediate): Likewise
12589         (aarch64_add_constant_internal): Likewise.
12590         (aarch64_add_constant): Likewise.
12591         (aarch64_movw_imm): Likewise.
12592         (aarch64_rtx_arith_op_extract_p): Likewise.
12593         (aarch64_mask_and_shift_for_ubfiz_p): Likewise.
12594         (aarch64_simd_scalar_immediate_valid_for_move): Likewise.
12595         Remove assert that the mode isn't a vector.
12596         (aarch64_output_scalar_simd_mov_immediate): Likewise.
12597         (aarch64_expand_mov_immediate): Update calls after above changes.
12598         (aarch64_output_casesi): Use as_a <scalar_int_mode>.
12599         (aarch64_and_bitmask_imm): Check for scalar integer modes.
12600         (aarch64_move_imm): Likewise.
12601         (aarch64_can_const_movi_rtx_p): Likewise.
12602         (aarch64_strip_extend): Likewise.
12603         (aarch64_extr_rtx_p): Likewise.
12604         (aarch64_rtx_costs): Likewise, using wode_mode as the mode of
12605         a CONST_INT when the mode parameter is VOIDmode.
12606         (aarch64_float_const_rtx_p): Use scalar_int_mode for a temporary.
12608 2017-09-05  Richard Sandiford  <richard.sandiford@linaro.org>
12610         * machmode.h (bitwise_mode_for_mode): Return opt_mode.
12611         * stor-layout.c (bitwise_mode_for_mode): Likewise.
12612         (bitwise_type_for_mode): Update accordingly.
12614 2017-09-05  Richard Sandiford  <richard.sandiford@linaro.org>
12616         * stor-layout.h (mode_for_size_tree): Return an opt_mode.
12617         * stor-layout.c (mode_for_size_tree): Likewise.
12618         (mode_for_array): Update accordingly.
12619         (layout_decl): Likewise.
12620         (compute_record_mode): Likewise.  Only set the mode once.
12622 2017-09-05  Richard Sandiford  <richard.sandiford@linaro.org>
12624         * target.def (get_mask_mode): Change return type to opt_mode.
12625         Expand commentary.
12626         * doc/tm.texi: Regenerate.
12627         * targhooks.h (default_get_mask_mode): Return an opt_mode.
12628         * targhooks.c (default_get_mask_mode): Likewise.
12629         * config/i386/i386.c (ix86_get_mask_mode): Likewise.
12630         * optabs-query.c (can_vec_mask_load_store_p): Update use of
12631         targetm.get_mask_mode.
12632         * tree.c (build_truth_vector_type): Likewise.
12634 2017-09-05  Richard Sandiford  <richard.sandiford@linaro.org>
12636         * machmode.h (mode_for_vector): Return an opt_mode.
12637         * stor-layout.c (mode_for_vector): Likewise.
12638         (mode_for_int_vector): Update accordingly.
12639         (layout_type): Likewise.
12640         * config/i386/i386.c (emit_memmov): Likewise.
12641         (ix86_expand_set_or_movmem): Likewise.
12642         (ix86_expand_vector_init): Likewise.
12643         (ix86_get_mask_mode): Likewise.
12644         * config/powerpcspe/powerpcspe.c (rs6000_expand_vec_perm_const_1):
12645         Likewise.
12646         * config/rs6000/rs6000.c (rs6000_expand_vec_perm_const_1): Likewise.
12647         * expmed.c (extract_bit_field_1): Likewise.
12648         * expr.c (expand_expr_real_2): Likewise.
12649         * optabs-query.c (can_vec_perm_p): Likewise.
12650         (can_vec_mask_load_store_p): Likewise.
12651         * optabs.c (expand_vec_perm): Likewise.
12652         * targhooks.c (default_get_mask_mode): Likewise.
12653         * tree-vect-stmts.c (vectorizable_store): Likewise.
12654         (vectorizable_load): Likewise.
12655         (get_vectype_for_scalar_type_and_size): Likewise.
12657 2017-09-05  Richard Sandiford  <richard.sandiford@linaro.org>
12659         * machmode.h (mode_for_int_vector): New function.
12660         * stor-layout.c (mode_for_int_vector): Likewise.
12661         * config/aarch64/aarch64.c (aarch64_emit_approx_sqrt): Use it.
12662         * config/powerpcspe/powerpcspe.c (rs6000_do_expand_vec_perm): Likewise.
12663         * config/rs6000/rs6000.c (rs6000_do_expand_vec_perm): Likewise.
12664         * config/s390/s390.c (s390_expand_vec_compare_cc): Likewise.
12665         (s390_expand_vcond): Likewise.
12667 2017-09-05  Richard Sandiford  <richard.sandiford@linaro.org>
12669         * machmode.h (opt_machine_mode): New type.
12670         (opt_mode<T>): Allow construction from anything that can be
12671         converted to a T.
12672         (is_a, as_a, dyn_cast): Add overloads for opt_mode.
12673         (mode_for_size): Return an opt_machine_mode.
12674         * stor-layout.c (mode_for_size): Likewise.
12675         (mode_for_size_tree): Update call accordingly.
12676         (bitwise_mode_for_mode): Likewise.
12677         (make_fract_type): Likewise.
12678         (make_accum_type): Likewise.
12679         * caller-save.c (replace_reg_with_saved_mem): Update call
12680         accordingly.
12681         * config/alpha/alpha.h (SECONDARY_MEMORY_NEEDED_MODE): Likewise.
12682         * config/i386/i386.h (SECONDARY_MEMORY_NEEDED_MODE): Likewise.
12683         * config/s390/s390.h (SECONDARY_MEMORY_NEEDED_MODE): Likewise.
12684         * config/sparc/sparc.h (SECONDARY_MEMORY_NEEDED_MODE): Likewise.
12685         * expmed.c (extract_bit_field_1): Likewise.
12686         * reload.c (get_secondary_mem): Likewise.
12687         * varasm.c (assemble_integer): Likewise.
12688         * lower-subreg.c (simplify_subreg_concatn): Likewise.  Move
12689         early-out.
12691 2017-09-05  Richard Sandiford  <richard.sandiford@linaro.org>
12693         * machmode.h (decimal_float_mode_for_size): New function.
12694         * real.h (REAL_VALUE_TO_TARGET_LONG_DOUBLE): Use float_mode_for_size.
12695         (REAL_VALUE_TO_TARGET_DOUBLE): Likewise.
12696         (REAL_VALUE_TO_TARGET_SINGLE): Likewise.
12697         (REAL_VALUE_TO_TARGET_DECIMAL128): Use decimal_float_mode_for_size.
12698         (REAL_VALUE_TO_TARGET_DECIMAL64): Likewise.
12699         (REAL_VALUE_TO_TARGET_DECIMAL32): Likewise.
12701 2017-09-05  Richard Sandiford  <richard.sandiford@linaro.org>
12703         * builtins.c (expand_builtin_powi): Use int_mode_for_size.
12704         (get_builtin_sync_mode): Likewise.
12705         (expand_ifn_atomic_compare_exchange): Likewise.
12706         (expand_builtin_atomic_clear): Likewise.
12707         (expand_builtin_atomic_test_and_set): Likewise.
12708         (fold_builtin_atomic_always_lock_free): Likewise.
12709         * calls.c (compute_argument_addresses): Likewise.
12710         (emit_library_call_value_1): Likewise.
12711         (store_one_arg): Likewise.
12712         * combine.c (combine_instructions): Likewise.
12713         * config/aarch64/aarch64.c (aarch64_function_value): Likewise.
12714         * config/arm/arm.c (arm_function_value): Likewise.
12715         (aapcs_allocate_return_reg): Likewise.
12716         * config/c6x/c6x.c (c6x_expand_movmem): Likewise.
12717         * config/i386/i386.c (construct_container): Likewise.
12718         (ix86_gimplify_va_arg): Likewise.
12719         (ix86_expand_sse_cmp): Likewise.
12720         (emit_memmov): Likewise.
12721         (emit_memset): Likewise.
12722         (expand_small_movmem_or_setmem): Likewise.
12723         (ix86_expand_pextr): Likewise.
12724         (ix86_expand_pinsr): Likewise.
12725         * config/lm32/lm32.c (lm32_block_move_inline): Likewise.
12726         * config/microblaze/microblaze.c (microblaze_block_move_straight):
12727         Likewise.
12728         * config/mips/mips.c (mips_function_value_1) Likewise.
12729         (mips_block_move_straight): Likewise.
12730         (mips_expand_ins_as_unaligned_store): Likewise.
12731         * config/powerpcspe/powerpcspe.c
12732         (rs6000_darwin64_record_arg_advance_flush): Likewise.
12733         (rs6000_darwin64_record_arg_flush): Likewise.
12734         * config/rs6000/rs6000.c
12735         (rs6000_darwin64_record_arg_advance_flush): Likewise.
12736         (rs6000_darwin64_record_arg_flush): Likewise.
12737         * config/sparc/sparc.c (sparc_function_arg_1): Likewise.
12738         (sparc_function_value_1): Likewise.
12739         * config/spu/spu.c (adjust_operand): Likewise.
12740         (spu_emit_branch_or_set): Likewise.
12741         (arith_immediate_p): Likewise.
12742         * emit-rtl.c (gen_lowpart_common): Likewise.
12743         * expr.c (expand_expr_real_1): Likewise.
12744         * function.c (assign_parm_setup_block): Likewise.
12745         * gimple-ssa-store-merging.c (encode_tree_to_bitpos): Likewise.
12746         * reload1.c (alter_reg): Likewise.
12747         * stor-layout.c (mode_for_vector): Likewise.
12748         (layout_type): Likewise.
12750 2017-09-05  Richard Sandiford  <richard.sandiford@linaro.org>
12752         * config/spu/spu.c (exp2_immediate_p): Use int_mode_for_mode.
12753         (spu_convert_move): Likewise.
12754         * lower-subreg.c (resolve_simple_move): Likewise.
12756 2017-09-05  Bill Schmidt  <wschmidt@linux.vnet.ibm.com>
12758         PR target/81833
12759         * config/rs6000/altivec.md (altivec_vsum2sws): Convert from a
12760         define_insn to a define_expand.
12761         (altivec_vsum2sws_direct): New define_insn.
12762         (altivec_vsumsws): Convert from a define_insn to a define_expand.
12764 2017-09-05  Wilco Dijkstra  <wdijkstr@arm.com>
12766         * config/arm/arm.c (arm_option_params_internal): Improve setting of
12767         max_insns_skipped.
12769 2017-09-05  H.J. Lu  <hongjiu.lu@intel.com>
12771         PR target/59501
12772         PR target/81624
12773         PR target/81769
12774         * config/i386/i386.c (ix86_finalize_stack_frame_flags): Don't
12775         realign stack if stack alignment needed is less than incoming
12776         stack boundary.
12778 2017-09-05  Marek Polacek  <polacek@redhat.com>
12780         PR sanitizer/82072
12781         * convert.c (convert_to_integer_1) <case NEGATE_EXPR>: Move the ubsan
12782         check earlier.
12784 2017-09-05  Wilco Dijkstra  <wdijkstr@arm.com>
12786         * explow.c (get_dynamic_stack_size): Improve dynamic alignment.
12788 2017-09-05  Richard Biener  <rguenther@suse.de>
12790         PR tree-optimization/82084
12791         * fold-const.c (can_native_encode_string_p): Handle wide characters.
12793 2017-09-05  Richard Biener  <rguenther@suse.de>
12795         PR tree-optimization/82102
12796         * tree-ssa-pre.c (fini_eliminate): Check if lhs is NULL.
12798 2017-09-05  Martin Liska  <mliska@suse.cz>
12800         PR tree-optimization/82032
12801         * tree-cfg.c (generate_range_test): New function.
12802         * tree-cfg.h (generate_range_test): Declared here.
12803         * tree-cfgcleanup.c (convert_single_case_switch): New function.
12804         (cleanup_control_expr_graph): Use it.
12805         * tree-switch-conversion.c (try_switch_expansion): Remove
12806         assert.
12807         (emit_case_nodes): Use generate_range_test.
12809 2017-09-04  Uros Bizjak  <ubizjak@gmail.com>
12811         PR target/82098
12812         * config/i386/i386.md (*<btsc><mode>_mask): Add
12813         TARGET_USE_BT to insn constraint.
12814         (*btr<mode>_mask): Ditto.
12816 2017-09-04  Wilco Dijkstra  <wdijkstr@arm.com>
12818         * config/arm/arm.c (arm_legitimate_index_p): Add comment.
12819         (thumb2_legitimate_index_p): Use correct range for DI/DF mode.
12821 2017-09-04  Bernd Edlinger  <bernd.edlinger@hotmail.de>
12823         PR target/77308
12824         * config/arm/arm.md (*arm_adddi3, *arm_subdi3): Split early except for
12825         TARGET_NEON and TARGET_IWMMXT.
12826         (anddi3, iordi3, xordi3, one_cmpldi2): Split while expanding except for
12827         TARGET_NEON and TARGET_IWMMXT.
12828         (*one_cmpldi2_insn): Moved the body of one_cmpldi2 here.
12830 2017-09-04  Uros Bizjak  <ubizjak@gmail.com>
12832         * config/i386/i386-protos.h (ix86_tls_address_pattern_p) New prototype.
12833         (ix86_rewrite_tls_address): Ditto.
12834         * config/i386/i386.c (ix86_tls_address_pattern_p) New function.
12835         (ix86_rewrite_tls_address_1): Ditto.
12836         (ix86_rewrite_tls_address): Ditto.
12837         * config/i386/predicates.md (tls_address_pattern): New predicate.
12838         * config/i386/i386.md (TLS address splitter): New splitter.
12840 2017-09-04  Richard Biener  <rguenther@suse.de>
12842         PR tree-optimization/82084
12843         * fold-const.h (can_native_encode_string_p): Declare.
12844         * fold-const.c (can_native_encode_string_p): Factor out from ...
12845         (native_encode_string): ... here.
12846         * tree-vect-stmts.c (vectorizable_store): Call it to avoid
12847         vectorizing stores from constants we later cannot handle.
12849 2017-09-04  Marek Polacek  <polacek@redhat.com>
12851         PR c/81783
12852         * doc/invoke.texi: Update -Wtautological-compare documentation.
12854 2017-09-04  Jeff Law  <law@redhat.com>
12856         PR tree-optimization/64910
12857         * tree-ssa-reassoc.c (reassociate_bb): For bitwise binary ops,
12858         swap the first and last operand if the last is a constant.
12860 2017-09-04  Marek Polacek  <polacek@redhat.com>
12862         PR sanitizer/82072
12863         * convert.c (do_narrow): When sanitizing signed integer overflows,
12864         bail out for signed types.
12865         (convert_to_integer_1) <case NEGATE_EXPR>: Likewise.
12867 2017-09-04  Richard Biener  <rguenther@suse.de>
12869         PR tree-optimization/82060
12870         * tree-ssa-pre.c (eliminate_dom_walker::before_dom_children):
12871         Move devirtualization after stmt folding and before EH/AB/noreturn
12872         cleanup to get the stmt refs canonicalized.  Use a bool instead
12873         of gimple_modified_p since that doesn't work for NOPs.  Schedule
12874         NOPs generated by folding for removal.
12876 2017-09-04  Richard Sandiford  <richard.sandiford@linaro.org>
12877             Alan Hayward  <alan.hayward@arm.com>
12878             David Sherwood  <david.sherwood@arm.com>
12880         * coretypes.h (pad_direction): New enum.
12881         * defaults.h (DEFAULT_FUNCTION_ARG_PADDING): Delete.
12882         (FUNCTION_ARG_PADDING): Likewise.
12883         * target.def (function_arg_padding): New hook.
12884         * targhooks.h (default_function_arg_padding): Declare.
12885         * targhooks.c (default_function_arg_padding): New function.
12886         * doc/tm.texi.in (FUNCTION_ARG_PADDING): Replace with...
12887         (TARGET_FUNCTION_ARG_PADDING): ...this.
12888         * doc/tm.texi: Regenerate.
12889         * calls.c (store_unaligned_arguments_into_pseudos): Use pad_direction
12890         instead of direction.
12891         (compute_argument_addresses): Likewise.
12892         (load_register_parameters): Likewise.
12893         (emit_library_call_value_1): Likewise.
12894         (store_one_arg): Use targetm.calls.function_arg_padding instead
12895         of FUNCTION_ARG_PADDING.
12896         (must_pass_in_stack_var_size_or_pad): Likewise.
12897         * expr.c (emit_group_load_1): Use pad_direction instead of direction.
12898         (emit_group_store): Likewise.
12899         (emit_single_push_insn_1): Use targetm.calls.function_arg_padding
12900         instead of FUNCTION_ARG_PADDING.
12901         (emit_push_insn): Likewise, and propagate enum change throughout
12902         function.
12903         * function.h (direction): Delete.
12904         (locate_and_pad_arg_data::where_pad): Use pad_direction instead
12905         of direction.
12906         * function.c (assign_parm_find_stack_rtl): Likewise.
12907         (assign_parm_setup_block_p): Likewise.
12908         (assign_parm_setup_block): Likewise.
12909         (gimplify_parameters): Likewise.
12910         (locate_and_pad_parm): Use targetm.calls.function_arg_padding
12911         instead of FUNCTION_ARG_PADDING, and propagate enum change throughout
12912         function.
12913         * config/aarch64/aarch64.h (FUNCTION_ARG_PADDING): Delete.
12914         (BLOCK_REG_PADDING): Use pad_direction instead of direction.
12915         * config/aarch64/aarch64-protos.h (aarch64_pad_arg_upward): Delete.
12916         * config/aarch64/aarch64.c (aarch64_pad_arg_upward): Replace with...
12917         (aarch64_function_arg_padding): ...this new function.
12918         (aarch64_gimplify_va_arg_expr): Use pad_direction instead of direction.
12919         (TARGET_FUNCTION_ARG_PADDING): Redefine.
12920         * config/arm/arm.h (FUNCTION_ARG_PADDING): Delete.
12921         (BLOCK_REG_PADDING): Use pad_direction instead of direction.
12922         * config/arm/arm-protos.h (arm_pad_arg_upward): Delete.
12923         * config/arm/arm.c (TARGET_FUNCTION_ARG_PADDING): Redefine.
12924         (arm_pad_arg_upward): Replace with...
12925         (arm_function_arg_padding): ...this new function.
12926         * config/c6x/c6x.h (BLOCK_REG_PADDING): Use pad_direction instead
12927         of direction.
12928         * config/ia64/hpux.h (FUNCTION_ARG_PADDING): Delete.
12929         * config/ia64/ia64-protos.h (ia64_hpux_function_arg_padding): Delete.
12930         * config/ia64/ia64.c (TARGET_FUNCTION_ARG_PADDING): Redefine.
12931         (ia64_hpux_function_arg_padding): Replace with...
12932         (ia64_function_arg_padding): ...this new function.  Use pad_direction
12933         instead of direction.  Check for TARGET_HPUX.
12934         * config/iq2000/iq2000.h (FUNCTION_ARG_PADDING): Delete.
12935         * config/iq2000/iq2000.c (TARGET_FUNCTION_ARG_PADDING): Redefine.
12936         (iq2000_function_arg_padding): New function.
12937         * config/mips/mips-protos.h (mips_pad_arg_upward): Delete.
12938         * config/mips/mips.c (mips_pad_arg_upward): Replace with...
12939         (mips_function_arg_padding): ...this new function.
12940         (mips_pad_reg_upward): Update accordingly.
12941         (TARGET_FUNCTION_ARG_PADDING): Redefine.
12942         * config/mips/mips.h (PAD_VARARGS_DOWN): Use
12943         targetm.calls.function_arg_padding.
12944         (FUNCTION_ARG_PADDING): Delete.
12945         (BLOCK_REG_PADDING): Use pad_direction instead of direction.
12946         * config/nios2/nios2.h (FUNCTION_ARG_PADDING): Delete.
12947         (PAD_VARARGS_DOWN): Use targetm.calls.function_arg_padding.
12948         * config/nios2/nios2-protos.h (nios2_function_arg_padding): Delete.
12949         (nios2_block_reg_padding): Return pad_direction instead of direction.
12950         * config/nios2/nios2.c (nios2_block_reg_padding): Return pad_direction
12951         instead of direction.
12952         (nios2_function_arg_padding): Likewise.  Make static.
12953         (TARGET_FUNCTION_ARG_PADDING): Redefine.
12954         * config/pa/pa.h (FUNCTION_ARG_PADDING): Delete.
12955         (BLOCK_REG_PADDING): Use targetm.calls.function_arg_padding.
12956         * config/pa/pa-protos.h (pa_function_arg_padding): Delete.
12957         * config/pa/pa.c (TARGET_FUNCTION_ARG_PADDING): Redefine.
12958         (pa_function_arg_padding): Make static.  Return pad_direction instead
12959         of direction.
12960         * config/powerpcspe/powerpcspe.h (FUNCTION_ARG_PADDING): Delete.
12961         (PAD_VARARGS_DOWN): Use targetm.calls.function_arg_padding.
12962         * config/powerpcspe/aix.h (BLOCK_REG_PADDING): Use pad_direction
12963         instead of direction.  Use targetm.calls.function_arg_padding.
12964         * config/powerpcspe/darwin.h (BLOCK_REG_PADDING): Likewise.
12965         * config/powerpcspe/freebsd64.h (BLOCK_REG_PADDING): Likewise.
12966         * config/powerpcspe/linux64.h (BLOCK_REG_PADDING): Likewise.
12967         * config/powerpcspe/powerpcspe-protos.h (function_arg_padding): Delete.
12968         * config/powerpcspe/powerpcspe.c (TARGET_FUNCTION_ARG_PADDING):
12969         Redefine.
12970         (function_arg_padding): Rename to...
12971         (rs6000_function_arg_padding): ...this.  Make static.  Return
12972         pad_direction instead of direction.
12973         (rs6000_return_in_msb): Use rs6000_function_arg_padding.
12974         * config/rs6000/rs6000.h (FUNCTION_ARG_PADDING): Delete.
12975         (PAD_VARARGS_DOWN): Use targetm.calls.function_arg_padding.
12976         * config/rs6000/aix.h (BLOCK_REG_PADDING): Use pad_direction
12977         instead of direction.  Use targetm.calls.function_arg_padding.
12978         * config/rs6000/darwin.h (BLOCK_REG_PADDING): Likewise.
12979         * config/rs6000/freebsd64.h (BLOCK_REG_PADDING): Likewise.
12980         * config/rs6000/linux64.h (BLOCK_REG_PADDING): Likewise.
12981         * config/rs6000/rs6000-protos.h (function_arg_padding): Delete.
12982         * config/rs6000/rs6000.c (TARGET_FUNCTION_ARG_PADDING): Redefine.
12983         (function_arg_padding): Rename to...
12984         (rs6000_function_arg_padding): ...this.  Make static.  Return
12985         pad_direction instead of direction.
12986         (rs6000_return_in_msb): Use rs6000_function_arg_padding.
12987         * config/s390/s390.h (FUNCTION_ARG_PADDING): Delete.
12988         * config/s390/s390.c (s390_function_arg_padding): New function.
12989         (TARGET_FUNCTION_ARG_PADDING): Redefine.
12990         * config/sparc/sparc.h (FUNCTION_ARG_PADDING): Delete.
12991         * config/sparc/sparc-protos.h (function_arg_padding): Delete.
12992         * config/sparc/sparc.c (TARGET_FUNCTION_ARG_PADDING): Redefine.
12993         (function_arg_padding): Rename to...
12994         (sparc_function_arg_padding): ...this.  Make static.  Return
12995         pad_direction instead of direction.
12996         * config/spu/spu.h (FUNCTION_ARG_PADDING): Delete.
12997         * config/spu/spu.c (spu_function_arg_padding): New function.
12998         (TARGET_FUNCTION_ARG_PADDING): Redefine.
12999         * system.h (FUNCTION_ARG_PADDING): Poison.
13001 2017-09-04  Richard Sandiford  <richard.sandiford@linaro.org>
13002             Alan Hayward  <alan.hayward@arm.com>
13003             David Sherwood  <david.sherwood@arm.com>
13005         * target.def (modes_tieable_p): New hook.
13006         * doc/tm.texi (MODES_TIEABLE_P): Replace with...
13007         (TARGET_MODES_TIEABLE_P): ...this.
13008         * doc/tm.texi.in: Regenerate.
13009         * hooks.h (hook_bool_mode_mode_true): Declare.
13010         * hooks.c (hook_bool_mode_mode_true): New function.
13011         * combine.c (subst): Use targetm.modes_tieable_p instead of
13012         MODES_TIEABLE_P.
13013         * dse.c (find_shift_sequence): Likewise.
13014         * expmed.c (extract_low_bits): Likewise.
13015         * lower-subreg.c: Include target.h.
13016         (find_decomposable_subregs): Use targetm.modes_tieable_p instead of
13017         MODES_TIEABLE_P.
13018         * rtlanal.c (rtx_cost): Likewise.
13019         * config/aarch64/aarch64.h (MODES_TIEABLE_P): Delete.
13020         * config/aarch64/aarch64-protos.h (aarch64_modes_tieable_p): Delete.
13021         * config/aarch64/aarch64.c (aarch64_modes_tieable_p): Make static.
13022         (TARGET_MODES_TIEABLE_P): Redefine.
13023         * config/alpha/alpha.h (MODES_TIEABLE_P): Delete.
13024         * config/alpha/alpha.c (alpha_modes_tieable_p): New function.
13025         (TARGET_MODES_TIEABLE_P): Redefine.
13026         * config/arc/arc.h (MODES_TIEABLE_P): Delete.
13027         * config/arc/arc.c (TARGET_MODES_TIEABLE_P): Redefine.
13028         (arc_modes_tieable_p): New function.
13029         * config/arm/arm.h (MODES_TIEABLE_P): Delete.
13030         * config/arm/arm-protos.h (arm_modes_tieable_p): Delete.
13031         * config/arm/arm.c (TARGET_MODES_TIEABLE_P): Redefine.
13032         (arm_modes_tieable_p): Make static.
13033         * config/avr/avr.h (MODES_TIEABLE_P): Delete.
13034         * config/bfin/bfin.h (MODES_TIEABLE_P): Delete.
13035         * config/bfin/bfin.c (bfin_modes_tieable_p): New function.
13036         (TARGET_MODES_TIEABLE_P): Redefine.
13037         * config/c6x/c6x.h (MODES_TIEABLE_P): Delete.
13038         * config/c6x/c6x.c (c6x_modes_tieable_p): New function.
13039         (TARGET_MODES_TIEABLE_P): Redefine.
13040         * config/cr16/cr16.h (MODES_TIEABLE_P): Delete.
13041         * config/cr16/cr16.c (TARGET_MODES_TIEABLE_P): Redefine.
13042         (cr16_modes_tieable_p): New function.
13043         * config/cris/cris.h (MODES_TIEABLE_P): Delete.
13044         * config/epiphany/epiphany.h (MODES_TIEABLE_P): Delete.
13045         * config/fr30/fr30.h (MODES_TIEABLE_P): Delete.
13046         (TRULY_NOOP_TRUNCATION): Update comment.
13047         * config/frv/frv.h (MODES_TIEABLE_P): Delete.
13048         (TRULY_NOOP_TRUNCATION): Update comment.
13049         * config/frv/frv.c (TARGET_MODES_TIEABLE_P): Redefine.
13050         (frv_modes_tieable_p): New function.
13051         * config/ft32/ft32.h (MODES_TIEABLE_P): Delete.
13052         * config/h8300/h8300.h (MODES_TIEABLE_P): Delete.
13053         * config/h8300/h8300.c (h8300_modes_tieable_p): New function.
13054         (TARGET_MODES_TIEABLE_P): Redefine.
13055         * config/i386/i386.h (MODES_TIEABLE_P): Delete.
13056         * config/i386/i386-protos.h (ix86_modes_tieable_p): Delete.
13057         * config/i386/i386.c (ix86_modes_tieable_p): Make static.
13058         (TARGET_MODES_TIEABLE_P): Redefine.
13059         * config/ia64/ia64.h (MODES_TIEABLE_P): Delete.
13060         * config/ia64/ia64.c (TARGET_MODES_TIEABLE_P): Redefine.
13061         (ia64_modes_tieable_p): New function.
13062         * config/iq2000/iq2000.h (MODES_TIEABLE_P): Delete.
13063         * config/iq2000/iq2000.c (TARGET_MODES_TIEABLE_P): Redefine.
13064         (iq2000_modes_tieable_p): New function.
13065         * config/lm32/lm32.h (MODES_TIEABLE_P): Delete.
13066         * config/lm32/lm32.c (TARGET_MODES_TIEABLE_P): Redefine.
13067         (lm32_modes_tieable_p): New function.
13068         * config/m32c/m32c.h (MODES_TIEABLE_P): Delete.
13069         * config/m32c/m32c-protos.h (m32c_modes_tieable_p): Delete.
13070         * config/m32c/m32c.c (m32c_modes_tieable_p): Make static.
13071         (TARGET_MODES_TIEABLE_P): Redefine.
13072         * config/m32r/m32r.h (MODES_TIEABLE_P): Delete.
13073         * config/m32r/m32r.c (TARGET_MODES_TIEABLE_P): Redefine.
13074         (m32r_modes_tieable_p): New function.
13075         * config/m68k/m68k.h (MODES_TIEABLE_P): Delete.
13076         * config/m68k/m68k.c (TARGET_MODES_TIEABLE_P): Redefine.
13077         (m68k_modes_tieable_p): New function.
13078         * config/mcore/mcore.h (MODES_TIEABLE_P): Delete.
13079         * config/mcore/mcore.c (TARGET_MODES_TIEABLE_P): Redefine.
13080         (mcore_modes_tieable_p): New function.
13081         * config/microblaze/microblaze.h (MODES_TIEABLE_P): Delete.
13082         * config/microblaze/microblaze.c (microblaze_modes_tieable_p): New
13083         function.
13084         (TARGET_MODES_TIEABLE_P): Redefine.
13085         * config/mips/mips.h (MODES_TIEABLE_P): Delete.
13086         * config/mips/mips-protos.h (mips_modes_tieable_p): Delete.
13087         * config/mips/mips.c (mips_modes_tieable_p): Make static.
13088         (TARGET_MODES_TIEABLE_P): Redefine.
13089         * config/mmix/mmix.h (MODES_TIEABLE_P): Delete.
13090         * config/mn10300/mn10300.h (MODES_TIEABLE_P): Delete.
13091         * config/mn10300/mn10300-protos.h (mn10300_modes_tieable): Delete.
13092         * config/mn10300/mn10300.c (mn10300_modes_tieable): Rename to...
13093         (mn10300_modes_tieable_p): ...this and make static.
13094         (TARGET_MODES_TIEABLE_P): Redefine.
13095         * config/moxie/moxie.h (MODES_TIEABLE_P): Delete.
13096         * config/msp430/msp430.h (MODES_TIEABLE_P): Delete.
13097         * config/msp430/msp430-protos.h (msp430_modes_tieable_p): Delete.
13098         * config/msp430/msp430.c (TARGET_MODES_TIEABLE_P): Redefine.
13099         (msp430_modes_tieable_p): Make static.
13100         * config/nds32/nds32.h (MODES_TIEABLE_P): Delete.
13101         * config/nds32/nds32.c (nds32_modes_tieable_p): New function.
13102         (TARGET_MODES_TIEABLE_P): Redefine.
13103         * config/nios2/nios2.h (MODES_TIEABLE_P): Delete.
13104         * config/nvptx/nvptx.h (MODES_TIEABLE_P): Delete.
13105         * config/nvptx/nvptx.c (nvptx_modes_tieable_p): New function.
13106         (TARGET_MODES_TIEABLE_P): Redefine.
13107         * config/pa/pa.h (MODES_TIEABLE_P): Delete.
13108         * config/pa/pa-protos.h (pa_modes_tieable_p): Delete.
13109         * config/pa/pa.c (pa_modes_tieable_p): Make static.
13110         (TARGET_MODES_TIEABLE_P): Redefine.
13111         * config/pdp11/pdp11.h (MODES_TIEABLE_P): Delete.
13112         * config/pdp11/pdp11.c (TARGET_MODES_TIEABLE_P): Redefine.
13113         (pdp11_modes_tieable_p): New function.
13114         * config/powerpcspe/powerpcspe.h (MODES_TIEABLE_P): Delete.
13115         * config/powerpcspe/powerpcspe.c (TARGET_MODES_TIEABLE_P): Redefine.
13116         (rs6000_modes_tieable_p): New function.
13117         (rs6000_debug_reg_global): Use it instead of MODES_TIEABLE_P.
13118         * config/powerpcspe/powerpcspe.md: Update comment.
13119         * config/riscv/riscv.h (MODES_TIEABLE_P): Delete.
13120         * config/riscv/riscv.c (riscv_modes_tieable_p): New function.
13121         (TARGET_MODES_TIEABLE_P): Redefine.
13122         * config/rl78/rl78.h (MODES_TIEABLE_P): Delete.
13123         * config/rl78/rl78.c (TARGET_MODES_TIEABLE_P): Redefine.
13124         (rl78_modes_tieable_p): New function.
13125         * config/rs6000/rs6000.h (MODES_TIEABLE_P): Delete.
13126         * config/rs6000/rs6000.c (TARGET_MODES_TIEABLE_P): Redefine.
13127         (rs6000_modes_tieable_p): New function.
13128         (rs6000_debug_reg_global): Use it instead of MODES_TIEABLE_P.
13129         * config/rs6000/rs6000.md: Update comment.
13130         * config/rx/rx.h (MODES_TIEABLE_P): Delete.
13131         * config/rx/rx.c (rx_modes_tieable_p): New function.
13132         (TARGET_MODES_TIEABLE_P): Redefine.
13133         * config/s390/s390.h (MODES_TIEABLE_P): Delete.
13134         * config/s390/s390.c (s390_modes_tieable_p): New function.
13135         (TARGET_MODES_TIEABLE_P): Redefine.
13136         * config/sh/sh.h (MODES_TIEABLE_P): Delete.
13137         * config/sh/sh.c (TARGET_MODES_TIEABLE_P): Redefine.
13138         (sh_modes_tieable_p): New function.
13139         * config/sparc/sparc.h (MODES_TIEABLE_P): Delete.
13140         * config/sparc/sparc-protos.h (sparc_modes_tieable_p): Delete.
13141         * config/sparc/sparc.c (TARGET_MODES_TIEABLE_P): Redefine.
13142         (sparc_modes_tieable_p): Make static.
13143         * config/spu/spu.h (MODES_TIEABLE_P): Delete.
13144         * config/spu/spu.c (spu_modes_tieable_p): New function.
13145         (TARGET_MODES_TIEABLE_P): Redefine.
13146         * config/stormy16/stormy16.h (MODES_TIEABLE_P): Delete.
13147         * config/stormy16/stormy16.c (xstormy16_modes_tieable_p): New function.
13148         (TARGET_MODES_TIEABLE_P): Redefine.
13149         * config/tilegx/tilegx.h (MODES_TIEABLE_P): Delete.
13150         * config/tilepro/tilepro.h (MODES_TIEABLE_P): Delete.
13151         * config/v850/v850.h (MODES_TIEABLE_P): Delete.
13152         * config/v850/v850.c (v850_modes_tieable_p): New function.
13153         (TARGET_MODES_TIEABLE_P): Redefine.
13154         * config/vax/vax.h (MODES_TIEABLE_P): Delete.
13155         * config/visium/visium.h (MODES_TIEABLE_P): Delete.
13156         * config/visium/visium.c (TARGET_MODES_TIEABLE_P): Redefine.
13157         (visium_modes_tieable_p): New function.
13158         * config/xtensa/xtensa.h (MODES_TIEABLE_P): Delete.
13159         * config/xtensa/xtensa.c (TARGET_MODES_TIEABLE_P): Redefine.
13160         (xtensa_modes_tieable_p): New function.
13161         * system.h (MODES_TIEABLE_P): Poison.
13163 2017-09-04  Richard Sandiford  <richard.sandiford@linaro.org>
13164             Alan Hayward  <alan.hayward@arm.com>
13165             David Sherwood  <david.sherwood@arm.com>
13167         * target.def (hard_regno_mode_ok): New hook.
13168         * doc/tm.texi (HARD_REGNO_MODE_OK): Replace with...
13169         (TARGET_HARD_REGNO_MODE_OK): ...this.
13170         * doc/tm.texi.in: Regenerate.
13171         * hooks.h (hook_bool_uint_mode_true): Declare.
13172         * hooks.c (hook_bool_uint_mode_true): New function.
13173         * doc/md.texi: Refer to targetm.hard_regno_mode_ok instead of
13174         HARD_REGNO_MODE_OK.
13175         * genpreds.c (write_insn_preds_c): Add an include of target.h.
13176         * alias.c (init_alias_target): Use targetm.hard_regno_mode_ok
13177         instead of HARD_REGNO_MODE_OK.
13178         * caller-save.c: Include target.h.
13179         (reg_save_code): Use targetm.hard_regno_mode_ok instead of
13180         HARD_REGNO_MODE_OK.
13181         * combine.c (can_combine_p): Likewise.
13182         (combinable_i3pat): Likewise.
13183         (can_change_dest_mode): Likewise.
13184         * expr.c (init_expr_target): Likewise.
13185         (convert_move): Likewise.
13186         (convert_modes): Likewise.
13187         * ira.c (setup_prohibited_class_mode_regs): Likewise.
13188         (setup_prohibited_mode_move_regs): Likewise.
13189         * ira.h (target_ira): Likewise.
13190         * lra-assigns.c (find_hard_regno_for_1): Likewise.
13191         * lra-constraints.c (process_alt_operands): Likewise.
13192         (split_reg): Likewise.
13193         * recog.c (peep2_find_free_register): Likewise.
13194         * ree.c (combine_reaching_defs): Likewise.
13195         * regcprop.c (maybe_mode_change): Likewise.
13196         * reginfo.c (init_reg_sets_1): Likewise.
13197         (choose_hard_reg_mode): Likewise.
13198         (simplifiable_subregs): Likewise.
13199         * regrename.c (check_new_reg_p): Likewise.
13200         * reload.c (find_valid_class): Likewise.
13201         (find_valid_class_1): Likewise.
13202         (reload_inner_reg_of_subreg): Likewise.
13203         (push_reload): Likewise.
13204         (combine_reloads): Likewise.
13205         (find_dummy_reload): Likewise.
13206         (find_reloads): Likewise.
13207         * reload1.c (find_reg): Likewise.
13208         (set_reload_reg): Likewise.
13209         (allocate_reload_reg): Likewise.
13210         (choose_reload_regs): Likewise.
13211         (reload_adjust_reg_for_temp): Likewise.
13212         * rtlanal.c (subreg_size_offset_from_lsb): Likewise.
13213         (simplify_subreg_regno): Likewise.
13214         * sel-sched.c (init_regs_for_mode): Likewise.
13215         * varasm.c (make_decl_rtl): Likewise.
13216         * config/aarch64/aarch64.h (HARD_REGNO_MODE_OK): Delete.
13217         (MODES_TIEABLE_P): Use targetm.hard_regno_mode_ok instead of
13218         HARD_REGNO_MODE_OK.
13219         * config/aarch64/aarch64-protos.h (aarch64_hard_regno_mode_ok): Delete.
13220         * config/aarch64/aarch64.c (aarch64_hard_regno_mode_ok): Make static.
13221         (TARGET_HARD_REGNO_MODE_OK): Redefine.
13222         * config/alpha/alpha.h (HARD_REGNO_MODE_OK): Delete.
13223         * config/alpha/alpha.c (alpha_hard_regno_mode_ok): New function.
13224         (TARGET_HARD_REGNO_MODE_OK): Redefine.
13225         * config/arc/arc.h (arc_hard_regno_mode_ok): Delete.
13226         (arc_mode_class): Delete.
13227         (HARD_REGNO_MODE_OK): Delete.
13228         * config/arc/arc.c (TARGET_HARD_REGNO_MODE_OK): Redefine.
13229         (arc_hard_regno_mode_ok): Rename old array to...
13230         (arc_hard_regno_mode_ok_modes): ...this.
13231         (arc_conditional_register_usage): Update accordingly.
13232         (arc_mode_class): Make static.
13233         (arc_hard_regno_mode_ok): New function.
13234         * config/arm/arm.h (HARD_REGNO_MODE_OK): Delete.
13235         * config/arm/arm-protos.h (arm_hard_regno_mode_ok): Delete.
13236         * config/arm/arm.c (TARGET_HARD_REGNO_MODE_OK): Redefine.
13237         (arm_hard_regno_mode_ok): Make static.
13238         * config/arm/arm.md (movdi): Use targetm.hard_regno_mode_ok instead of
13239         HARD_REGNO_MODE_OK.
13240         * config/avr/avr-protos.h (avr_hard_regno_mode_ok): Delete.
13241         * config/avr/avr.h (HARD_REGNO_MODE_OK): Delete.
13242         * config/avr/avr.c (avr_hard_regno_mode_ok): Make static and
13243         return a bool.
13244         (TARGET_HARD_REGNO_MODE_OK): Redefine.
13245         * config/bfin/bfin-protos.h (hard_regno_mode_ok): Delete.
13246         * config/bfin/bfin.h (HARD_REGNO_MODE_OK): Delete.
13247         * config/bfin/bfin.c (hard_regno_mode_ok): Rename to...
13248         (bfin_hard_regno_mode_ok): ...this.  Make static and return a bool.
13249         (TARGET_HARD_REGNO_MODE_OK): Redefine.
13250         * config/bfin/predicates.md (valid_reg_operand): Use
13251         targetm.hard_regno_mode_ok instead of HARD_REGNO_MODE_OK.
13252         * config/c6x/c6x.h (HARD_REGNO_MODE_OK): Delete.
13253         * config/c6x/c6x.c (c6x_hard_regno_mode_ok): New function.
13254         (TARGET_HARD_REGNO_MODE_OK): Redefine.
13255         * config/cr16/cr16.h (HARD_REGNO_MODE_OK): Delete.
13256         * config/cr16/cr16-protos.h (cr16_hard_regno_mode_ok): Delete.
13257         * config/cr16/cr16.c (TARGET_HARD_REGNO_MODE_OK): Redefine.
13258         (cr16_hard_regno_mode_ok): Make static and return a bool.
13259         * config/cris/cris.h (HARD_REGNO_MODE_OK): Delete.
13260         * config/cris/cris.c (TARGET_HARD_REGNO_MODE_OK): Redefine.
13261         (cris_hard_regno_mode_ok): New function.
13262         * config/epiphany/epiphany.h (epiphany_hard_regno_mode_ok): Delete.
13263         (epiphany_mode_class): Delete.
13264         (HARD_REGNO_MODE_OK): Delete.
13265         * config/epiphany/epiphany-protos.h (hard_regno_mode_ok): Delete.
13266         * config/epiphany/epiphany.c (TARGET_HARD_REGNO_MODE_OK): Redefine.
13267         (hard_regno_mode_ok): Rename to...
13268         (epiphany_hard_regno_mode_ok): ...this.  Make static and return a bool.
13269         * config/fr30/fr30.h (HARD_REGNO_MODE_OK): Delete.
13270         * config/fr30/fr30.md: Refer to targetm.hard_regno_mode_ok instead of
13271         HARD_REGNO_MODE_OK.
13272         * config/frv/frv.h (HARD_REGNO_MODE_OK): Delete.
13273         * config/frv/frv-protos.h (frv_hard_regno_mode_ok): Delete.
13274         * config/frv/frv.c (TARGET_HARD_REGNO_MODE_OK): Redefine.
13275         (frv_hard_regno_mode_ok): Make static and return a bool.
13276         * config/frv/frv.md: Refer to targetm.hard_regno_mode_ok instead of
13277         HARD_REGNO_MODE_OK.
13278         * config/ft32/ft32.h (HARD_REGNO_MODE_OK): Delete.
13279         * config/h8300/h8300.h (HARD_REGNO_MODE_OK): Delete.
13280         * config/h8300/h8300-protos.h (h8300_hard_regno_mode_ok): Delete.
13281         * config/h8300/h8300.c (h8300_hard_regno_mode_ok): Make static
13282         and return a bool.
13283         (TARGET_HARD_REGNO_MODE_OK): Redefine.
13284         * config/i386/i386.h (HARD_REGNO_MODE_OK): Delete.
13285         * config/i386/i386-protos.h (ix86_hard_regno_mode_ok): Delete.
13286         * config/i386/i386.c (ix86_hard_regno_mode_ok): Make static and
13287         return a bool.
13288         (TARGET_HARD_REGNO_MODE_OK): Redefine.
13289         * config/ia64/ia64.h (HARD_REGNO_MODE_OK): Delete.
13290         * config/ia64/ia64.c (TARGET_HARD_REGNO_MODE_OK): Redefine.
13291         (ia64_hard_regno_mode_ok): New function.
13292         * config/iq2000/iq2000.h (HARD_REGNO_MODE_OK): Delete.
13293         * config/iq2000/iq2000.c (TARGET_HARD_REGNO_MODE_OK): Redefine.
13294         (iq2000_hard_regno_mode_ok): New function.
13295         * config/lm32/lm32.h (HARD_REGNO_MODE_OK): Delete.
13296         * config/lm32/lm32.c (TARGET_HARD_REGNO_MODE_OK): Redefine.
13297         (lm32_hard_regno_mode_ok): New function.
13298         * config/m32c/m32c.h (HARD_REGNO_MODE_OK): Delete.
13299         * config/m32c/m32c-protos.h (m32c_hard_regno_ok): Delete.
13300         * config/m32c/m32c.c (class_can_hold_mode): Use m32c_hard_regno_mode_ok
13301         instead of HARD_REGNO_MODE_OK.
13302         (m32c_hard_regno_ok): Rename to...
13303         (m32c_hard_regno_mode_ok): ...this.  Make static and return a bool.
13304         (m32c_cannot_change_mode_class): Update accordingly.
13305         (TARGET_HARD_REGNO_MODE_OK): Redefine.
13306         * config/m32r/m32r.h (m32r_hard_regno_mode_ok): Delete.
13307         (m32r_mode_class): Delete.
13308         (HARD_REGNO_MODE_OK): Delete.
13309         * config/m32r/m32r.c (TARGET_HARD_REGNO_MODE_OK): Redefine.
13310         (m32r_hard_regno_mode_ok): Rename to...
13311         (m32r_hard_regno_modes): ...this.
13312         (m32r_mode_class): Make static.
13313         (m32r_hard_regno_mode_ok): New function.
13314         * config/m68k/m68k.h (HARD_REGNO_MODE_OK): Delete.
13315         * config/m68k/m68k-protos.h (m68k_regno_mode_ok): Delete.
13316         * config/m68k/m68k.c (TARGET_HARD_REGNO_MODE_OK): Redefine.
13317         (m68k_hard_regno_mode_ok): Make static.
13318         * config/mcore/mcore.h (HARD_REGNO_MODE_OK): Delete.
13319         * config/mcore/mcore.c (TARGET_HARD_REGNO_MODE_OK): Redefine.
13320         (mcore_hard_regno_mode_ok): New function.
13321         * config/microblaze/microblaze.h (microblaze_hard_regno_mode_ok)
13322         (HARD_REGNO_MODE_OK): Delete.
13323         * config/microblaze/microblaze.c (microblaze_hard_regno_mode_ok):
13324         Rename to...
13325         (microblaze_hard_regno_mode_ok_p): ...this and make static.
13326         (microblaze_hard_regno_mode_ok): New function.
13327         (TARGET_HARD_REGNO_MODE_OK): Redefine.
13328         * config/mips/mips.h (HARD_REGNO_MODE_OK): Delete.
13329         (mips_hard_regno_mode_ok): Delete.
13330         * config/mips/mips.c (mips_hard_regno_mode_ok): Rename to...
13331         (mips_hard_regno_mode_ok_p): ...this and make static.
13332         (mips_hard_regno_mode_ok_p): Rename to...
13333         (mips_hard_regno_mode_ok_uncached): ...this.
13334         (mips_hard_regno_mode_ok): New function.
13335         (mips_class_max_nregs): Use mips_hard_regno_mode_ok instead
13336         of HARD_REGNO_MODE_OK.
13337         (mips_option_override): Update after above name changes.
13338         (TARGET_HARD_REGNO_MODE_OK): Redefine.
13339         * config/mmix/mmix.h (HARD_REGNO_MODE_OK): Delete.
13340         * config/mn10300/mn10300.h (HARD_REGNO_MODE_OK): Delete.
13341         * config/mn10300/mn10300-protos.h (mn10300_hard_regno_mode_ok): Delete.
13342         * config/mn10300/mn10300.c (mn10300_hard_regno_mode_ok): Make static.
13343         (TARGET_HARD_REGNO_MODE_OK): Redefine.
13344         * config/moxie/moxie.h (HARD_REGNO_MODE_OK): Delete.
13345         * config/msp430/msp430.h (HARD_REGNO_MODE_OK): Delete.
13346         * config/msp430/msp430-protos.h (msp430_hard_regno_mode_ok): Delete.
13347         * config/msp430/msp430.c (TARGET_HARD_REGNO_MODE_OK): Redefine.
13348         (msp430_hard_regno_mode_ok): Make static and return a bool.
13349         * config/nds32/nds32.h (HARD_REGNO_MODE_OK): Delete.
13350         * config/nds32/nds32-protos.h (nds32_hard_regno_mode_ok): Delete.
13351         * config/nds32/nds32.c (nds32_hard_regno_mode_ok): Make static
13352         and return a bool.
13353         (TARGET_HARD_REGNO_MODE_OK): Redefine.
13354         * config/nios2/nios2.h (HARD_REGNO_MODE_OK): Delete.
13355         * config/nvptx/nvptx.h (HARD_REGNO_MODE_OK): Delete.
13356         * config/pa/pa.h (MODES_TIEABLE_P): Update commentary.
13357         * config/pa/pa32-regs.h (HARD_REGNO_MODE_OK): Rename to...
13358         (PA_HARD_REGNO_MODE_OK): ...this
13359         * config/pa/pa64-regs.h (HARD_REGNO_MODE_OK): Rename to...
13360         (PA_HARD_REGNO_MODE_OK): ...this.
13361         * config/pa/pa.c (TARGET_HARD_REGNO_MODE_OK): Redefine.
13362         (pa_hard_regno_mode_ok): New function.
13363         * config/pdp11/pdp11.h (HARD_REGNO_MODE_OK): Delete.
13364         * config/pdp11/pdp11.c (TARGET_HARD_REGNO_MODE_OK): Redefine.
13365         (pdp11_hard_regno_mode_ok): New function.
13366         * config/powerpcspe/powerpcspe.h (HARD_REGNO_MODE_OK): Delete.
13367         * config/powerpcspe/powerpcspe-protos.h (rs6000_hard_regno_mode_ok_p):
13368         Delete.
13369         * config/powerpcspe/powerpcspe.c (rs6000_hard_regno_mode_ok_p):
13370         Make static.
13371         (TARGET_HARD_REGNO_MODE_OK): Redefine.
13372         (rs6000_hard_regno_mode_ok): Rename to...
13373         (rs6000_hard_regno_mode_ok_uncached): ...this.
13374         (rs6000_init_hard_regno_mode_ok): Update accordingly.
13375         (rs6000_hard_regno_mode_ok): New function.
13376         * config/riscv/riscv.h (HARD_REGNO_MODE_OK): Delete.
13377         * config/riscv/riscv-protos.h (riscv_hard_regno_mode_ok_p): Delete.
13378         * config/riscv/riscv.c (riscv_hard_regno_mode_ok_p): Rename to...
13379         (riscv_hard_regno_mode_ok): ...this and make static.
13380         (TARGET_HARD_REGNO_MODE_OK): Redefine.
13381         * config/rl78/rl78.h (HARD_REGNO_MODE_OK): Delete.
13382         * config/rl78/rl78-protos.h (rl78_hard_regno_mode_ok): Delete.
13383         * config/rl78/rl78.c (TARGET_HARD_REGNO_MODE_OK): Redefine.
13384         (rl78_hard_regno_mode_ok): Make static and return bool.
13385         * config/rs6000/rs6000.h (HARD_REGNO_MODE_OK): Delete.
13386         * config/rs6000/rs6000-protos.h (rs6000_hard_regno_mode_ok_p):
13387         Delete.
13388         * config/rs6000/rs6000.c (rs6000_hard_regno_mode_ok_p): Make static.
13389         (TARGET_HARD_REGNO_MODE_OK): Redefine.
13390         (rs6000_hard_regno_mode_ok): Rename to...
13391         (rs6000_hard_regno_mode_ok_uncached): ...this.
13392         (rs6000_init_hard_regno_mode_ok): Update accordingly.
13393         (rs6000_hard_regno_mode_ok): New function.
13394         * config/rx/rx.h (HARD_REGNO_MODE_OK): Delete.
13395         * config/rx/rx.c (rx_hard_regno_mode_ok): New function.
13396         (TARGET_HARD_REGNO_MODE_OK): Redefine.
13397         * config/s390/s390.h (HARD_REGNO_MODE_OK): Delete.
13398         * config/s390/s390-protos.h (s390_hard_regno_mode_ok): Delete.
13399         * config/s390/s390.c (s390_hard_regno_mode_ok): Make static.
13400         (TARGET_HARD_REGNO_MODE_OK): Redefine.
13401         * config/sh/sh.h (HARD_REGNO_MODE_OK): Delete.
13402         * config/sh/sh-protos.h (sh_hard_regno_mode_ok): Delete.
13403         * config/sh/sh.c (TARGET_HARD_REGNO_MODE_OK): Redefine.
13404         (sh_hard_regno_mode_ok): Make static.
13405         * config/sparc/constraints.md: Refer to targetm.hard_regno_mode_ok
13406         instead of HARD_REGNO_MODE_OK.
13407         * config/sparc/sparc.h (hard_regno_mode_classes): Delete.
13408         (sparc_mode_class): Delete.
13409         (HARD_REGNO_MODE_OK): Delete.
13410         * config/sparc/sparc.c (TARGET_HARD_REGNO_MODE_OK): Redefine.
13411         (hard_regno_mode_classes): Make static.
13412         (sparc_mode_class): Likewise.
13413         (sparc_hard_regno_mode_ok): New function.
13414         * config/spu/spu.h (HARD_REGNO_MODE_OK): Delete.
13415         * config/stormy16/stormy16.h (HARD_REGNO_MODE_OK): Delete.
13416         * config/stormy16/stormy16.c (xstormy16_hard_regno_mode_ok): New
13417         function.
13418         (TARGET_HARD_REGNO_MODE_OK): Redefine.
13419         * config/tilegx/tilegx.h (HARD_REGNO_MODE_OK): Delete.
13420         * config/tilepro/tilepro.h (HARD_REGNO_MODE_OK): Delete.
13421         * config/v850/v850.h (HARD_REGNO_MODE_OK): Delete.
13422         * config/v850/v850.c (v850_hard_regno_mode_ok): New function.
13423         (TARGET_HARD_REGNO_MODE_OK): Redefine.
13424         * config/vax/vax.h (HARD_REGNO_MODE_OK): Delete.
13425         * config/visium/visium.h (HARD_REGNO_MODE_OK): Delete.
13426         * config/visium/visium.c (TARGET_HARD_REGNO_MODE_OK): Redefine.
13427         (visium_hard_regno_mode_ok): New function.
13428         * config/visium/visium.md: Refer to targetm.hard_regno_mode_ok
13429         instead of HARD_REGNO_MODE_OK.
13430         * config/xtensa/xtensa.h (xtensa_hard_regno_mode_ok): Delete.
13431         (HARD_REGNO_MODE_OK): Delete.
13432         * config/xtensa/xtensa.c (xtensa_hard_regno_mode_ok): Rename to...
13433         (xtensa_hard_regno_mode_ok_p): ...this and make static.
13434         (xtensa_option_override): Update accordingly.
13435         (TARGET_HARD_REGNO_MODE_OK): Redefine.
13436         (xtensa_hard_regno_mode_ok): New function.
13437         * system.h (HARD_REGNO_MODE_OK): Poison.
13439 2017-09-04  Richard Sandiford  <richard.sandiford@linaro.org>
13440             Alan Hayward  <alan.hayward@arm.com>
13441             David Sherwood  <david.sherwood@arm.com>
13443         * target.def (hard_regno_call_part_clobbered): New hook.
13444         * doc/tm.texi.in (HARD_REGNO_CALL_PART_CLOBBERED): Replace with...
13445         (TARGET_HARD_REGNO_CALL_PART_CLOBBERED): ...this hook.
13446         * doc/tm.texi: Regenerate.
13447         * hooks.h (hook_bool_uint_mode_false): Declare.
13448         * hooks.c (hook_bool_uint_mode_false): New function.
13449         * regs.h (HARD_REGNO_CALL_PART_CLOBBERED): Delete.
13450         * cselib.c (cselib_process_insn): Use
13451         targetm.hard_regno_call_part_clobbered instead of
13452         HARD_REGNO_CALL_PART_CLOBBERED.
13453         * ira-conflicts.c (ira_build_conflicts): Likewise.
13454         * ira-costs.c (ira_tune_allocno_costs): Likewise.
13455         * lra-constraints.c (need_for_call_save_p): Likewise.
13456         * lra-lives.c: Include target.h.
13457         (check_pseudos_live_through_calls): Use
13458         targetm.hard_regno_call_part_clobbered instead of
13459         HARD_REGNO_CALL_PART_CLOBBERED.
13460         * regcprop.c: Include target.h.
13461         (copyprop_hardreg_forward_1): Use
13462         targetm.hard_regno_call_part_clobbered instead of
13463         HARD_REGNO_CALL_PART_CLOBBERED.
13464         * reginfo.c (choose_hard_reg_mode): Likewise.
13465         * regrename.c (check_new_reg_p): Likewise.
13466         * reload.c (find_equiv_reg): Likewise.
13467         * reload1.c (emit_reload_insns): Likewise.
13468         * sched-deps.c (deps_analyze_insn): Likewise.
13469         * sel-sched.c (init_regs_for_mode): Likewise.
13470         (mark_unavailable_hard_regs): Likewise.
13471         * targhooks.c (default_dwarf_frame_reg_mode): Likewise.
13472         * config/aarch64/aarch64.h (HARD_REGNO_CALL_PART_CLOBBERED): Delete.
13473         * config/aarch64/aarch64.c (aarch64_hard_regno_call_part_clobbered):
13474         New function.
13475         (TARGET_HARD_REGNO_CALL_PART_CLOBBERED): Redefine.
13476         * config/avr/avr.h (HARD_REGNO_CALL_PART_CLOBBERED): Delete.
13477         * config/avr/avr-protos.h (avr_hard_regno_call_part_clobbered):
13478         Delete.
13479         * config/avr/avr.c (avr_hard_regno_call_part_clobbered): Make static
13480         and return a bool.
13481         (TARGET_HARD_REGNO_CALL_PART_CLOBBERED): Redefine.
13482         * config/i386/i386.h (HARD_REGNO_CALL_PART_CLOBBERED): Delete.
13483         * config/i386/i386.c (ix86_hard_regno_call_part_clobbered): New
13484         function.
13485         (TARGET_HARD_REGNO_CALL_PART_CLOBBERED): Redefine.
13486         * config/mips/mips.h (HARD_REGNO_CALL_PART_CLOBBERED): Delete.
13487         * config/mips/mips.c (mips_hard_regno_call_part_clobbered): New
13488         function.
13489         (TARGET_HARD_REGNO_CALL_PART_CLOBBERED): Redefine.
13490         * config/powerpcspe/powerpcspe.h (HARD_REGNO_CALL_PART_CLOBBERED):
13491         Delete.
13492         * config/powerpcspe/powerpcspe.c
13493         (rs6000_hard_regno_call_part_clobbered): New function.
13494         (TARGET_HARD_REGNO_CALL_PART_CLOBBERED): Redefine.
13495         * config/rs6000/rs6000.h (HARD_REGNO_CALL_PART_CLOBBERED): Delete.
13496         * config/rs6000/rs6000.c (rs6000_hard_regno_call_part_clobbered):
13497         New function.
13498         (TARGET_HARD_REGNO_CALL_PART_CLOBBERED): Redefine.
13499         * config/s390/s390.h (HARD_REGNO_CALL_PART_CLOBBERED): Delete.
13500         * config/s390/s390.c (s390_hard_regno_call_part_clobbered): New
13501         function.
13502         (TARGET_HARD_REGNO_CALL_PART_CLOBBERED): Redefine.
13503         * config/sh/sh.h (HARD_REGNO_CALL_PART_CLOBBERED): Delete.
13504         * system.h (HARD_REGNO_CALL_PART_CLOBBERED): Poison.
13506 2017-09-04  Richard Sandiford  <richard.sandiford@linaro.org>
13507             Alan Hayward  <alan.hayward@arm.com>
13508             David Sherwood  <david.sherwood@arm.com>
13510         * rtl.h (subreg_memory_offset): Declare.
13511         * emit-rtl.c (subreg_memory_offset): New function.
13512         * expmed.c (store_bit_field_1): Use it.
13513         * expr.c (undefined_operand_subword_p): Likewise.
13514         * simplify-rtx.c (simplify_subreg): Likewise.
13516 2017-09-04  Alexander Monakov  <amonakov@ispras.ru>
13518         PR rtl-optimization/57448
13519         PR target/67458
13520         PR target/81316
13521         * optabs.c (expand_atomic_load): Place compiler memory barriers if
13522         using atomic_load pattern.
13523         (expand_atomic_store): Likewise.
13525 2017-09-04  Jakub Jelinek  <jakub@redhat.com>
13527         PR sanitizer/81981
13528         * gimple-fold.c (gimple_fold_call): Optimize away useless UBSAN_PTR
13529         and UBSAN_BOUNDS internal calls.  Clean up IFN_UBSAN_OBJECT_SIZE
13530         handling.  Use replace_call_with_value with NULL instead of
13531         gsi_replace, unlink_stmt_vdef and release_defs.
13533         * gdbhooks.py (OptMachineModePrinter.to_string): Use 8 spaces
13534         instead of tab.
13536         * lra-remat.c (reg_overlap_for_remat_p): Fix a pasto.
13538 2017-09-04  Richard Sandiford  <richard.sandiford@linaro.org>
13540         PR bootstrap/82045
13541         * rtl.h (emit_library_call_value_1): Declare.
13542         (emit_library_call): Replace declaration with a series of overloads.
13543         Remove the parameter count argument.
13544         (emit_library_call_value): Likewise.
13545         * calls.c (emit_library_call_value_1): Make global.  Replace varargs
13546         with an "rtx_mode_t *".
13547         (emit_library_call_value): Delete.
13548         (emit_library_call): Likewise.
13549         * asan.c (asan_emit_stack_protection): Update calls accordingly.
13550         (asan_emit_allocas_unpoison): Likewise.
13551         * builtins.c (expand_builtin_powi): Likewise.
13552         (expand_asan_emit_allocas_unpoison): Likewise.
13553         * cfgexpand.c (expand_main_function): Likewise.
13554         * config/aarch64/aarch64.c (aarch64_trampoline_init): Likewise.
13555         * config/aarch64/aarch64.h (PROFILE_HOOK): Likewise.
13556         * config/alpha/alpha.c (alpha_trampoline_init): Likewise.
13557         * config/arm/arm.c (arm_trampoline_init): Likewise.
13558         (arm_call_tls_get_addr): Likewise.
13559         (arm_expand_divmod_libfunc): Likewise.
13560         * config/bfin/bfin.md (umulsi3_highpart): Likewise.
13561         (smulsi3_highpart): Likewise.
13562         * config/c6x/c6x.c (c6x_initialize_trampoline): Likewise.
13563         (c6x_expand_compare): Likewise.
13564         (c6x_expand_movmem): Likewise.
13565         * config/frv/frv.c (frv_trampoline_init): Likewise.
13566         * config/i386/i386.c (ix86_trampoline_init): Likewise.
13567         (ix86_expand_divmod_libfunc): Likewise.
13568         * config/ia64/ia64.c (ia64_expand_tls_address): Likewise.
13569         (ia64_expand_compare): Likewise.
13570         (ia64_profile_hook): Likewise.
13571         * config/ia64/ia64.md (save_stack_nonlocal): Likewise.
13572         (nonlocal_goto): Likewise.
13573         (restore_stack_nonlocal): Likewise.
13574         * config/m32r/m32r.c (block_move_call): Likewise.
13575         (m32r_trampoline_init): Likewise.
13576         * config/m68k/linux.h (FINALIZE_TRAMPOLINE): Likewise.
13577         * config/m68k/m68k.c (m68k_call_tls_get_addr): Likewise.
13578         (m68k_call_m68k_read_tp): Likewise.
13579         * config/microblaze/microblaze.c (microblaze_call_tls_get_addr)
13580         (microblaze_expand_divide): Likewise.
13581         * config/mips/mips.h (mips_args): Likewise.
13582         * config/mips/sdemtk.h (mips_sync_icache): Likewise.
13583         (MIPS_ICACHE_SYNC): Likewise.
13584         * config/nios2/nios2.c (nios2_emit_expensive_div): Likewise.
13585         (nios2_trampoline_init): Likewise.
13586         * config/pa/pa.c (hppa_tls_call): Likewise.
13587         (pa_trampoline_init): Likewise.
13588         * config/pa/pa.md (canonicalize_funcptr_for_compare): Likewise.
13589         * config/powerpcspe/powerpcspe.c (rs6000_legitimize_tls_address)
13590         (expand_strn_compare): Likewise.
13591         (rs6000_generate_compare): Likewise.
13592         (rs6000_expand_float128_convert): Likewise.
13593         (output_profile_hook): Likewise.
13594         (rs6000_trampoline_init): Likewise.
13595         * config/powerpcspe/powerpcspe.md (neg<mode>2): Likewise.
13596         * config/riscv/riscv.h (PROFILE_HOOK): Likewise.
13597         * config/rs6000/rs6000-string.c (expand_strn_compare): Likewise.
13598         * config/rs6000/rs6000.c (rs6000_legitimize_tls_address): Likewise.
13599         (rs6000_generate_compare): Likewise.
13600         (rs6000_expand_float128_convert): Likewise.
13601         (output_profile_hook): Likewise.
13602         (rs6000_trampoline_init): Likewise.
13603         * config/rs6000/rs6000.md (neg<mode>2): Likewise.
13604         * config/sh/sh.c (sh_trampoline_init): Likewise.
13605         * config/sparc/sparc.c (emit_soft_tfmode_libcall): Likewise.
13606         (sparc_emit_float_lib_cmp): Likewise.
13607         (sparc32_initialize_trampoline): Likewise.
13608         (sparc64_initialize_trampoline): Likewise.
13609         (sparc_profile_hook): Likewise.
13610         * config/spu/spu.c (ea_load_store): Likewise.
13611         * config/spu/spu.md (floatunssidf2): Likewise.
13612         * config/tilegx/tilegx.c (tilegx_trampoline_init): Likewise.
13613         * config/tilepro/tilepro.c (tilepro_trampoline_init): Likewise.
13614         * config/visium/visium.c (expand_block_move_4): Likewise.
13615         (expand_block_move_2): Likewise.
13616         (expand_block_move_1): Likewise.
13617         (expand_block_set_4): Likewise.
13618         (expand_block_set_2): Likewise.
13619         (expand_block_set_1): Likewise.
13620         (visium_trampoline_init): Likewise.
13621         (visium_profile_hook): Likewise.
13622         * config/xtensa/xtensa.c (xtensa_expand_nonlocal_goto): Likewise.
13623         (xtensa_setup_frame_addresses): Likewise.
13624         (xtensa_trampoline_init): Likewise.
13625         * except.c (sjlj_emit_function_enter): Likewise.
13626         (sjlj_emit_function_exit): Likewise.
13627         * explow.c (allocate_dynamic_stack_space): Likewise.
13628         (probe_stack_range): Likewise.
13629         * expr.c (convert_mode_scalar): Likewise.
13630         * optabs.c (expand_binop): Likewise.
13631         (expand_twoval_binop_libfunc): Likewise.
13632         (expand_unop): Likewise.
13633         (prepare_cmp_insn): Likewise.
13634         (prepare_float_lib_cmp): Likewise.
13635         (expand_float): Likewise.
13636         (expand_fix): Likewise.
13637         (expand_fixed_convert): Likewise.
13638         (maybe_emit_sync_lock_test_and_set): Likewise.
13639         (expand_atomic_compare_and_swap): Likewise.
13640         (expand_mem_thread_fence): Likewise.
13641         (expand_atomic_fetch_op): Likewise.
13643 2017-09-03  Gerald Pfeifer  <gerald@pfeifer.com>
13645         * doc/generic.texi (OpenACC): Adjust URL.
13646         * doc/invoke.texi (C Dialect Options): Ditto.
13648 2017-09-03  Uros Bizjak  <ubizjak@gmail.com>
13650         * config/i386/i386.md (*bt<mode>): Use nonimmediate_operand
13651         predicate for operand 1.  Add (m,<S>) constraint.
13652         (*jcc_bt<mode>): Use nonimmediate_operand predicate for operand 1.
13653         Prevent memory operand 1 with register operand 2.
13655 2017-09-01  Segher Boessenkool  <segher@kernel.crashing.org>
13657         PR rtl-optimization/82024
13658         * combine.c (try_combine): If the combination result is a PARALLEL,
13659         and we only need to retain the SET in there that would be placed
13660         at I2, check that we can place that at I3 instead, before doing so.
13662 2017-09-01  Jakub Jelinek  <jakub@redhat.com>
13664         PR target/81766
13665         * config/i386/i386.c (ix86_init_large_pic_reg): Return label
13666         instead of void.
13667         (ix86_init_pic_reg): Remember label from ix86_init_large_pic_reg,
13668         if non-NULL and preceded by NOTE_INSN_BASIC_BLOCK, swap the note
13669         and label.
13671 2017-09-01  Joerg Sonnenberger  <joerg@bec.de>
13672             Jeff Law  <law@redhat.com>
13674         * varasm.c (bss_initializer_p): Do not put constants into .bss
13675         (categorize_decl_for_section): Handle bss_initializer_p returning
13676         false when DECL_INITIAL is NULL.
13678 2017-09-01  Andreas Krebbel  <krebbel@linux.vnet.ibm.com>
13680         PR target/82012
13681         * config/s390/s390.c (s390_can_inline_p): New function.
13683 2017-09-01  Jeff Law  <law@redhat.com>
13685         PR tree-optimization/82052
13686         * tree-ssa-scopedtables.c (avail_exprs_stack::lookup_avail_expr):
13687         Always initialize the returned slot after a hash table miss
13688         when INSERT is true.
13690 2017-09-01  Alexander Monakov  <amonakov@ispras.ru>
13692         * config/s390/s390.md (mem_signal_fence): Remove.
13693         * doc/md.texi (mem_signal_fence): Remove.
13694         * optabs.c (expand_mem_signal_fence): Remove uses of mem_signal_fence.
13695         Update comments.
13696         * target-insns.def (mem_signal_fence): Remove.
13698 2017-09-01  Jakub Jelinek  <jakub@redhat.com>
13700         PR sanitizer/81902
13701         * doc/invoke.texi: Document -fsanitize=pointer-overflow.
13703         PR sanitizer/81923
13704         * asan.c (create_odr_indicator): Strip name encoding from assembler
13705         name before appending it after __odr_asan_.
13707 2017-09-01  Martin Liska  <mliska@suse.cz>
13709         PR tree-optimization/82059
13710         * gimple-ssa-isolate-paths.c (isolate_path): Add profile and
13711         frequency only when an edge is redirected.
13713 2017-09-01  Claudiu Zissulescu  <claziss@synopsys.com>
13715         * config/arc/arc-c.c (__ARC_LPC_WIDTH__): Add builtin define.
13716         * config/arc/arc.c (ARC_MAX_LOOP_LENGTH): Define.
13717         (arc_conditional_register_usage): Remove ARC600 lp_count
13718         exception.
13719         (arc_file_start): Emit Tag_ARC_CPU_variation.
13720         (arc_can_use_doloop_p): New conditions to use ZOLs.
13721         (hwloop_fail): New function.
13722         (hwloop_optimize): Likewise.
13723         (hwloop_pattern_reg): Likewise.
13724         (arc_doloop_hooks): New struct, to be used with reorg_loops.
13725         (arc_reorg_loops): New function, calls reorg_loops.
13726         (arc_reorg): Call arc_reorg_loops.  Remove old ZOL handling.
13727         (arc600_corereg_hazard): Remove ZOL checking, case handled by
13728         hwloop_optimize.
13729         (arc_loop_hazard): Remove function, functionality moved into
13730         hwloop_optimize.
13731         (arc_hazard): Remove arc_loop_hazard call.
13732         (arc_adjust_insn_length): Remove ZOL handling, functionality moved
13733         into hwloop_optimize.
13734         (arc_label_align): Remove ZOL handling.
13735         * config/arc/arc.h (LOOP_ALIGN): Changed to 0.
13736         * config/arc/arc.md (doloop_begin): Remove pattern.
13737         (doloop_begin_i): Likewise.
13738         (doloop_end_i): Likewise.
13739         (doloop_fallback): Likewise.
13740         (doloop_fallback_m): Likewise.
13741         (doloop_end): Reimplement expand.
13742         (arc_lp): New pattern for LP instruction.
13743         (loop_end): New pattern.
13744         (loop_fail): Likewise.
13745         (decrement_and_branch_until_zero): Likewise.
13746         * config/arc/arc.opt (mlpc-width): New option.
13747         * doc/invoke.texi (mlpc-width): Document option.
13749 2017-09-01  Claudiu Zissulescu  <claziss@synopsys.com>
13751         * config/arc/arc.c (arc_ifcvt): Remove use of merge_blocks call.
13752         (arc_ccfsm_advance): Fix checking for delay slots.
13753         (arc_reorg): Add rtl dump after each call to arc_ifcvt.
13755 2017-09-01  Claudiu Zissulescu  <claziss@synopsys.com>
13757         * config/arc/arc.md (movqi_insn): Add stores to save constant long
13758         immediates.
13759         (movhi_insn): Update store instruction constraint which are saving
13760         6-bit short immediates.
13761         (movsi_insn): Consider also short scaled load operations.
13762         (zero_extendhisi2_i): Use Usd constraint instead of T.
13763         (extendhisi2_i): Add q constraint.
13764         (arc_clzsi2): Add type and length attributes.
13765         (arc_ctzsi2): Likewise.
13766         * config/arc/constraints.md (Usc): Update constraint, the
13767         assembler can parse two relocations for a single instruction.
13769 2017-09-01  Claudiu Zissulescu  <claziss@synopsys.com>
13771         * config/arc/arc.c (arc_use_anchors_for_symbol_p): New function.
13772         (TARGET_USE_ANCHORS_FOR_SYMBOL_P): Define.
13774 2017-08-31  Olivier Hainque  <hainque@adacore.com>
13776         * config.gcc (powerpc-wrs-vxworks|vxworksae|vxworksmils): Now
13777         match as powerpc-wrs-vxworks*.
13779 2017-08-31  James Greenhalgh  <james.greenhalgh@arm.com>
13781         * config/aarch64/aarch64-simd.md (aarch64_mla_elt_merge<mode>): Fix
13782         register constraint for by-element operand.
13783         (aarch64_mls_elt_merge<mode>): Likewise.
13785 2017-08-31  Claudiu Zissulescu  <claziss@synopsys.com>
13787         * config/arc/arc.c (arc_can_follow_jump): Check for short
13788         branches.
13790 2017-08-31  Claudiu Zissulescu  <claziss@synopsys.com>
13792         * config.gcc: Use g.opt for arc.
13793         * config/arc/arc.c (LEGITIMATE_SCALED_ADDRESS_P): Deleted,
13794         functionality moved to ...
13795         (legitimate_scaled_address_p): New function, ...here.
13796         (LEGITIMATE_SMALL_DATA_OFFSET_P): New define.
13797         (LEGITIMATE_SMALL_DATA_ADDRESS_P): Use the above define.
13798         (legitimate_offset_address_p): Delete TARGET_NO_SDATA_SET
13799         condition.
13800         (arc_override_options): Handle G option.
13801         (arc_output_pic_addr_const): Correct function definition.
13802         (arc_legitimate_address_p): Use legitimate_scaled_address_p.
13803         (arc_decl_anon_ns_mem_p): Delete.
13804         (arc_in_small_data_p): Overhaul this function to take into
13805         consideration the value given via G option.
13806         (arc_rewrite_small_data_1): Renamed and corrected old
13807         arc_rewrite_small_data function.
13808         (arc_rewrite_small_data): New function.
13809         (small_data_pattern): Don't use pic_offset_table_rtx.
13810         * config/arc/arc.h (CC1_SPEC): Recognize G option.
13811         * config/arc/simdext.md (movmisalignv2hi): Use
13812         prepare_move_operands function.
13813         (mov*): Likewise.
13814         (movmisalign*): Likewise.
13815         * doc/invoke.texi (ARC options): Document -G option.
13817 2017-08-31  Claudiu Zissulescu  <claziss@synopsys.com>
13819         * config/arc/arc-protos.h (compact_sda_memory_operand): Update
13820         prototype.
13821         * config/arc/arc.c (arc_print_operand): Output scalled address for
13822         sdata whenever is possible.
13823         (arc_in_small_data_p): Allow sdata for 64bit datum when double
13824         load/stores are available.
13825         (compact_sda_memory_operand): Check for the alignment required by
13826         code density instructions.
13827         * config/arc/arc.md (movsi_insn): Use newly introduced Us0
13828         constraint.
13829         * config/arc/constraints.md (Usd): Update constraint.
13830         (Us0): New constraint.
13831         (Usc): Update constraint.
13833 2017-08-31  Richard Biener  <rguenther@suse.de>
13835         PR middle-end/82054
13836         * dwarf2out.c (dwarf2out_early_global_decl): Process each
13837         function only once.
13839 2017-08-31  Tamar Christina  <tamar.christina@arm.com>
13841         * config/aarch64/aarch64-builtins.c (aarch64_init_simd_builtins):
13842         Resize type_signature.
13844 2017-08-31  Richard Sandiford  <richard.sandiford@linaro.org>
13845             Alan Hayward  <alan.hayward@arm.com>
13846             David Sherwood  <david.sherwood@arm.com>
13848         * config/aarch64/aarch64.c (aarch64_base_register_rtx_p): Only allow
13849         subregs whose inner modes can be stored in GPRs.
13850         (aarch64_classify_index): Likewise.
13852 2017-08-31  Richard Sandiford  <richard.sandiford@linaro.org>
13853             Alan Hayward  <alan.hayward@arm.com>
13854             David Sherwood  <david.sherwood@arm.com>
13856         * config/aarch64/iterators.md (V_cmp_result): Rename to...
13857         (V_INT_EQUIV): ...this.
13858         (v_cmp_result): Rename to...
13859         (v_int_equiv): ...this.
13860         * config/aarch64/aarch64.md (xorsign<mode>3): Update accordingly.
13861         * config/aarch64/aarch64-simd.md (xorsign<mode>3): Likewise.
13862         (copysign<mode>3): Likewise.
13863         (aarch64_simd_bsl<mode>_internal): Likewise.
13864         (aarch64_simd_bsl<mode>): Likewise.
13865         (vec_cmp<mode><mode>): Likewise.
13866         (vcond<mode><mode>): Likewise.
13867         (vcond<v_cmp_mixed><mode>): Likewise.
13868         (vcondu<mode><v_cmp_mixed>): Likewise.
13869         (aarch64_cm<optab><mode>): Likewise.
13870         (aarch64_cmtst<mode>): Likewise.
13871         (aarch64_fac<optab><mode>): Likewise.
13872         (vec_perm_const<mode>): Likewise.
13873         (vcond_mask_<mode><v_cmp_result>): Rename to...
13874         (vcond_mask_<mode><v_int_equiv>): ...this.
13875         (vec_cmp<mode><v_cmp_result>): Rename to...
13876         (vec_cmp<mode><v_int_equiv>): ...this.
13878 2017-08-31  Richard Sandiford  <richard.sandiford@linaro.org>
13879             Alan Hayward  <alan.hayward@arm.com>
13880             David Sherwood  <david.sherwood@arm.com>
13882         * config/aarch64/aarch64-modes.def: Remove 32-, 48- and 64-byte
13883         vector modes.
13884         * config/aarch64/iterators.md (VRL2, VRL3, VRL4): Delete.
13885         * config/aarch64/aarch64.md (UNSPEC_LD2_DREG, UNSPEC_LD3_DREG)
13886         (UNSPEC_LD4_DREG): New unspecs.
13887         * config/aarch64/aarch64-simd.md (aarch64_ld2<mode>_dreg_le)
13888         (aarch64_ld2<mode>_dreg_be): Replace with...
13889         (aarch64_ld2<mode>_dreg): ...this pattern and use the new DREG
13890         unspec.
13891         (aarch64_ld3<mode>_dreg_le)
13892         (aarch64_ld3<mode>_dreg_be): Replace with...
13893         (aarch64_ld3<mode>_dreg): ...this pattern and use the new DREG
13894         unspec.
13895         (aarch64_ld4<mode>_dreg_le)
13896         (aarch64_ld4<mode>_dreg_be): Replace with...
13897         (aarch64_ld4<mode>_dreg): ...this pattern and use the new DREG
13898         unspec.
13900 2017-08-30  Bill Schmidt  <wschmidt@linux.vnet.ibm.com>
13902         PR tree-optimization/81987
13903         * gimple-ssa-strength-reduction.c (insert_initializers): Don't
13904         insert an initializer in a location not dominated by the stride
13905         definition.
13907 2017-08-30  Eric Botcazou  <ebotcazou@adacore.com>
13909         * tree-eh.c (lower_try_finally_switch): Set the location of the finally
13910         on the entire header of the finally block in the fallthru case.
13912 2017-08-30  Eric Botcazou  <ebotcazou@adacore.com>
13914         * varasm.c (decode_addr_const): Deal with INDIRECT_REF <INTEGER_CST>.
13916 2017-08-30  Pat Haugen  <pthaugen@us.ibm.com>
13918         * config/rs6000/rs6000.c (rs6000_emit_prologue_move_from_cr): Rename from
13919         rs6000_emit_move_from_cr and call renamed function.
13920         (rs6000_emit_prologue): Call renamed functions.
13921         * config/rs6000/rs6000.md (prologue_movesi_from_cr): Rename from
13922         movesi_from_cr, remove volatile CRs.
13924 2017-08-30  Jon Beniston  <jon@beniston.com>
13925             Richard Biener  <rguenther@suse.de>
13927         * tree-vect-patterns.c (vect_pattern_recog_1): Use VECTOR_TYPE_P instead
13928         of VECTOR_MODE_P check.
13929         * tree-vect-stmts.c (get_vectype_for_scalar_type_and_size): Allow single
13930         element vector types.
13932 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
13934         * df.h (df_read_modify_subreg_p): Remove in favor of...
13935         * rtl.h (read_modify_subreg_p): ...this new function.  Take a
13936         const_rtx instead of an rtx.
13937         * cprop.c (local_cprop_find_used_regs): Update accordingly.
13938         * df-problems.c (df_word_lr_mark_ref): Likewise.
13939         * ira-lives.c (mark_pseudo_reg_live): Likewise.
13940         (mark_pseudo_reg_dead): Likewise.
13941         (mark_ref_dead): Likewise.
13942         * reginfo.c (init_subregs_of_mode): Likewise.
13943         * sched-deps.c (sched_analyze_1): Likewise.
13944         * df-scan.c (df_def_record_1): Likewise.
13945         (df_uses_record): Likewise.
13946         (df_read_modify_subreg_p): Remove in favor of...
13947         * rtlanal.c (read_modify_subreg_p): ...this new function.  Take a
13948         const_rtx instead of an rtx.
13950 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
13951             Alan Hayward  <alan.hayward@arm.com>
13952             David Sherwood  <david.sherwood@arm.com>
13954         * rtl.h (partial_subreg_p): New function.
13955         * caller-save.c (save_call_clobbered_regs): Use it.
13956         * calls.c (expand_call): Likewise.
13957         * combine.c (combinable_i3pat): Likewise.
13958         (simplify_set): Likewise.
13959         (make_extraction): Likewise.
13960         (make_compound_operation_int): Likewise.
13961         (gen_lowpart_or_truncate): Likewise.
13962         (force_to_mode): Likewise.
13963         (make_field_assignment): Likewise.
13964         (reg_truncated_to_mode): Likewise.
13965         (record_truncated_value): Likewise.
13966         (move_deaths): Likewise.
13967         * cse.c (record_jump_cond): Likewise.
13968         (cse_insn): Likewise.
13969         * cselib.c (cselib_lookup_1): Likewise.
13970         * expmed.c (extract_bit_field_using_extv): Likewise.
13971         * function.c (assign_parm_setup_reg): Likewise.
13972         * ifcvt.c (noce_convert_multiple_sets): Likewise.
13973         * ira-build.c (create_insn_allocnos): Likewise.
13974         * lra-coalesce.c (merge_pseudos): Likewise.
13975         * lra-constraints.c (match_reload): Likewise.
13976         (simplify_operand_subreg): Likewise.
13977         (curr_insn_transform): Likewise.
13978         * lra-lives.c (process_bb_lives): Likewise.
13979         * lra.c (new_insn_reg): Likewise.
13980         (lra_substitute_pseudo): Likewise.
13981         * regcprop.c (mode_change_ok): Likewise.
13982         (maybe_mode_change): Likewise.
13983         (copyprop_hardreg_forward_1): Likewise.
13984         * reload.c (push_reload): Likewise.
13985         (find_reloads): Likewise.
13986         (find_reloads_subreg_address): Likewise.
13987         * reload1.c (alter_reg): Likewise.
13988         (eliminate_regs_1): Likewise.
13989         * simplify-rtx.c (simplify_unary_operation_1): Likewise.
13991 2017-08-30  David Edelsohn  <dje.gcc@gmail.com>
13993         * config/rs6000/rs6000.c (rs6000_expand_binop_builtin): Revert
13994         back to if statements, including unpack.
13996 2017-08-30  Martin Liska  <mliska@suse.cz>
13998         PR inline-asm/82001
13999         * ipa-icf-gimple.c (func_checker::compare_tree_list_operand):
14000         Rename to ...
14001         (func_checker::compare_asm_inputs_outputs): ... this function.
14002         (func_checker::compare_gimple_asm): Use the function to compare
14003         also ASM constrains.
14004         * ipa-icf-gimple.h: Rename the function.
14006 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
14007             Alan Hayward  <alan.hayward@arm.com>
14008             David Sherwood  <david.sherwood@arm.com>
14010         * coretypes.h (complex_mode): New type.
14011         * gdbhooks.py (build_pretty_printer): Handle it.
14012         * machmode.h (complex_mode): New class.
14013         (complex_mode::includes_p): New function.
14014         (is_complex_int_mode): Likewise.
14015         (is_complex_float_mode): Likewise.
14016         * genmodes.c (get_mode_class): Handle complex mode classes.
14017         * function.c (expand_function_end): Use is_complex_int_mode.
14019 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
14020             Alan Hayward  <alan.hayward@arm.com>
14021             David Sherwood  <david.sherwood@arm.com>
14023         * coretypes.h (scalar_mode_pod): New typedef.
14024         * gdbhooks.py (build_pretty_printer): Handle it.
14025         * machmode.h (gt_ggc_mx, gt_pch_nx): New functions.
14026         * fixed-value.h (fixed_value::mode): Change type to scalar_mode_pod.
14027         * fold-const.c (fold_convert_const_int_from_fixed): Use scalar_mode.
14028         * tree-streamer-in.c (unpack_ts_fixed_cst_value_fields): Use
14029         as_a <scalar_mode>.
14031 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
14032             Alan Hayward  <alan.hayward@arm.com>
14033             David Sherwood  <david.sherwood@arm.com>
14035         * machmode.h (mode_for_vector): Take a scalar_mode instead
14036         of a machine_mode.
14037         * stor-layout.c (mode_for_vector): Likewise.
14038         * explow.c (promote_mode): Use as_a <scalar_mode>.
14039         * sdbout.c (sdbout_parms): Use is_a <scalar_mode>.
14041 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
14042             Alan Hayward  <alan.hayward@arm.com>
14043             David Sherwood  <david.sherwood@arm.com>
14045         * target.def (preferred_simd_mode): Take a scalar_mode
14046         instead of a machine_mode.
14047         * targhooks.h (default_preferred_simd_mode): Likewise.
14048         * targhooks.c (default_preferred_simd_mode): Likewise.
14049         * config/arc/arc.c (arc_preferred_simd_mode): Likewise.
14050         * config/arm/arm.c (arm_preferred_simd_mode): Likewise.
14051         * config/c6x/c6x.c (c6x_preferred_simd_mode): Likewise.
14052         * config/epiphany/epiphany.c (epiphany_preferred_simd_mode): Likewise.
14053         * config/i386/i386.c (ix86_preferred_simd_mode): Likewise.
14054         * config/mips/mips.c (mips_preferred_simd_mode): Likewise.
14055         * config/nvptx/nvptx.c (nvptx_preferred_simd_mode): Likewise.
14056         * config/powerpcspe/powerpcspe.c (rs6000_preferred_simd_mode):
14057         Likewise.
14058         * config/rs6000/rs6000.c (rs6000_preferred_simd_mode): Likewise.
14059         * config/s390/s390.c (s390_preferred_simd_mode): Likewise.
14060         * config/sparc/sparc.c (sparc_preferred_simd_mode): Likewise.
14061         * config/aarch64/aarch64.c (aarch64_preferred_simd_mode): Likewise.
14062         (aarch64_simd_scalar_immediate_valid_for_move): Update accordingly.
14063         * doc/tm.texi: Regenerate.
14064         * optabs-query.c (can_vec_mask_load_store_p): Return false for
14065         non-scalar modes.
14067 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
14068             Alan Hayward  <alan.hayward@arm.com>
14069             David Sherwood  <david.sherwood@arm.com>
14071         * target.def (scalar_mode_supported_p): Take a scalar_mode
14072         instead of a machine_mode.
14073         * targhooks.h (default_scalar_mode_supported_p): Likewise.
14074         * targhooks.c (default_scalar_mode_supported_p): Likewise.
14075         * config/aarch64/aarch64.c (aarch64_scalar_mode_supported_p): Likewise.
14076         * config/alpha/alpha.c (alpha_scalar_mode_supported_p): Likewise.
14077         * config/arm/arm.c (arm_scalar_mode_supported_p): Likewise.
14078         * config/avr/avr.c (avr_scalar_mode_supported_p): Likewise.
14079         * config/c6x/c6x.c (c6x_scalar_mode_supported_p): Likewise.
14080         * config/i386/i386.c (ix86_scalar_mode_supported_p): Likewise.
14081         * config/ia64/ia64.c (ia64_scalar_mode_supported_p): Likewise.
14082         * config/mips/mips.c (mips_scalar_mode_supported_p): Likewise.
14083         * config/msp430/msp430.c (msp430_scalar_mode_supported_p): Likewise.
14084         * config/pa/pa.c (pa_scalar_mode_supported_p): Likewise.
14085         * config/pdp11/pdp11.c (pdp11_scalar_mode_supported_p): Likewise.
14086         * config/powerpcspe/powerpcspe.c (rs6000_scalar_mode_supported_p):
14087         Likewise.
14088         * config/rs6000/rs6000.c (rs6000_scalar_mode_supported_p): Likewise.
14089         * config/s390/s390.c (s390_scalar_mode_supported_p): Likewise.
14090         * config/spu/spu.c (spu_scalar_mode_supported_p): Likewise.
14091         * config/tilegx/tilegx.c (tilegx_scalar_mode_supported_p): Likewise.
14092         * config/tilepro/tilepro.c (tilepro_scalar_mode_supported_p):
14093         Likewise.
14094         * doc/tm.texi: Regenerate.
14096 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
14097             Alan Hayward  <alan.hayward@arm.com>
14098             David Sherwood  <david.sherwood@arm.com>
14100         * coretypes.h (opt_scalar_mode): New typedef.
14101         * gdbhooks.py (build_pretty_printers): Handle it.
14102         * machmode.h (mode_iterator::get_2xwider): Add overload for
14103         opt_mode<T>.
14104         * emit-rtl.c (init_emit_once): Use opt_scalar_mode when iterating
14105         over scalar modes.
14106         * expr.c (convert_mode_scalar): Likewise.
14107         * omp-low.c (omp_clause_aligned_alignment): Likewise.
14108         * optabs.c (expand_float): Likewise.
14109         (expand_fix): Likewise.
14110         * tree-vect-stmts.c (vectorizable_conversion): Likewise.
14112 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
14113             Alan Hayward  <alan.hayward@arm.com>
14114             David Sherwood  <david.sherwood@arm.com>
14116         * optabs.c (expand_float): Explicitly check for scalars before
14117         using a branching expansion.
14118         (expand_fix): Likewise.
14120 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
14121             Alan Hayward  <alan.hayward@arm.com>
14122             David Sherwood  <david.sherwood@arm.com>
14124         * expr.c (convert_mode): Split scalar handling out into...
14125         (convert_mode_scalar): ...this new function.  Treat the modes
14126         as scalar_modes.
14128 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
14129             Alan Hayward  <alan.hayward@arm.com>
14130             David Sherwood  <david.sherwood@arm.com>
14132         * omp-expand.c (expand_omp_atomic): Use is_int_mode, is_float_mode
14133         and scalar_mode.
14134         * tree-vect-stmts.c (get_vectype_for_scalar_type_and_size): Likewise.
14136 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
14137             Alan Hayward  <alan.hayward@arm.com>
14138             David Sherwood  <david.sherwood@arm.com>
14140         * fixed-value.h (fixed_from_double_int): Take a scalar_mode
14141         rather than a machine_mode.
14142         (fixed_from_string): Likewise.
14143         (fixed_convert): Likewise.
14144         (fixed_convert_from_int): Likewise.
14145         (fixed_convert_from_real): Likewise.
14146         (real_convert_from_fixed): Likewise.
14147         * fixed-value.c (fixed_from_double_int): Likewise.
14148         (fixed_from_string): Likewise.
14149         (fixed_convert): Likewise.
14150         (fixed_convert_from_int): Likewise.
14151         (fixed_convert_from_real): Likewise.
14152         (real_convert_from_fixed): Likewise.
14153         * config/avr/avr.c (avr_out_round): Use as_a <scalar_mode>.
14155 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
14156             Alan Hayward  <alan.hayward@arm.com>
14157             David Sherwood  <david.sherwood@arm.com>
14159         * emit-rtl.c (immed_double_const): Use is_a <scalar_mode> instead
14160         of separate mode class checks.  Do not allow vector modes here.
14161         (immed_wide_int_const): Use as_a <scalar_mode>.
14162         * explow.c (trunc_int_for_mode): Likewise.
14163         * rtl.h (wi::int_traits<rtx_mode_t>::get_precision): Likewise.
14164         (wi::shwi): Likewise.
14165         (wi::min_value): Likewise.
14166         (wi::max_value): Likewise.
14167         * dwarf2out.c (loc_descriptor): Likewise.
14168         * simplify-rtx.c (simplify_immed_subreg): Fix rtx_mode_t argument
14169         for CONST_WIDE_INT.
14171 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
14172             Alan Hayward  <alan.hayward@arm.com>
14173             David Sherwood  <david.sherwood@arm.com>
14175         * tree.h (SCALAR_TYPE_MODE): New macro.
14176         * expr.c (expand_expr_addr_expr_1): Use it.
14177         (expand_expr_real_2): Likewise.
14178         * fold-const.c (fold_convert_const_fixed_from_fixed): Likeise.
14179         (fold_convert_const_fixed_from_int): Likewise.
14180         (fold_convert_const_fixed_from_real): Likewise.
14181         (native_encode_fixed): Likewise
14182         (native_encode_complex): Likewise
14183         (native_encode_vector): Likewise.
14184         (native_interpret_fixed): Likewise.
14185         (native_interpret_real): Likewise.
14186         (native_interpret_complex): Likewise.
14187         (native_interpret_vector): Likewise.
14188         * omp-simd-clone.c (simd_clone_adjust_return_type): Likewise.
14189         (simd_clone_adjust_argument_types): Likewise.
14190         (simd_clone_init_simd_arrays): Likewise.
14191         (simd_clone_adjust): Likewise.
14192         * stor-layout.c (layout_type): Likewise.
14193         * tree.c (build_minus_one_cst): Likewise.
14194         * tree-cfg.c (verify_gimple_assign_ternary): Likewise.
14195         * tree-inline.c (estimate_move_cost): Likewise.
14196         * tree-ssa-math-opts.c (convert_plusminus_to_widen): Likewise.
14197         * tree-vect-loop.c (vect_create_epilog_for_reduction): Likewise.
14198         (vectorizable_reduction): Likewise.
14199         * tree-vect-patterns.c (vect_recog_widen_mult_pattern): Likewise.
14200         (vect_recog_mixed_size_cond_pattern): Likewise.
14201         (check_bool_pattern): Likewise.
14202         (adjust_bool_pattern): Likewise.
14203         (search_type_for_mask_1): Likewise.
14204         * tree-vect-slp.c (vect_schedule_slp_instance): Likewise.
14205         * tree-vect-stmts.c (vectorizable_conversion): Likewise.
14206         (vectorizable_load): Likewise.
14207         (vectorizable_store): Likewise.
14208         * ubsan.c (ubsan_encode_value): Likewise.
14209         * varasm.c (output_constant): Likewise.
14211 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
14212             Alan Hayward  <alan.hayward@arm.com>
14213             David Sherwood  <david.sherwood@arm.com>
14215         * coretypes.h (scalar_mode): New class.
14216         * machmode.h (scalar_mode): Likewise.
14217         (scalar_mode::includes_p): New function.
14218         (mode_to_inner): Return a scalar_mode rather than a machine_mode.
14219         * gdbhooks.py (build_pretty_printers): Handle scalar_mode.
14220         * genmodes.c (get_mode_class): Handle remaining scalar modes.
14221         * cfgexpand.c (expand_debug_expr): Use scalar_mode.
14222         * expmed.c (store_bit_field_1): Likewise.
14223         (extract_bit_field_1): Likewise.
14224         * expr.c (write_complex_part): Likewise.
14225         (read_complex_part): Likewise.
14226         (emit_move_complex_push): Likewise.
14227         (expand_expr_real_2): Likewise.
14228         * function.c (assign_parm_setup_reg): Likewise.
14229         (assign_parms_unsplit_complex): Likewise.
14230         * optabs.c (expand_binop): Likewise.
14231         * rtlanal.c (subreg_get_info): Likewise.
14232         * simplify-rtx.c (simplify_immed_subreg): Likewise.
14233         * varasm.c (output_constant_pool_2): Likewise.
14235 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
14236             Alan Hayward  <alan.hayward@arm.com>
14237             David Sherwood  <david.sherwood@arm.com>
14239         * expmed.c (extract_high_half): Use scalar_int_mode and remove
14240         assertion.
14241         (expmed_mult_highpart_optab): Likewise.
14242         (expmed_mult_highpart): Likewise.
14244 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
14245             Alan Hayward  <alan.hayward@arm.com>
14246             David Sherwood  <david.sherwood@arm.com>
14248         * builtins.h (builtin_strncpy_read_str): Take a scalar_int_mode
14249         instead of a machine_mode.
14250         (builtin_memset_read_str): Likewise.
14251         * builtins.c (c_readstr): Likewise.
14252         (builtin_memcpy_read_str): Likewise.
14253         (builtin_strncpy_read_str): Likewise.
14254         (builtin_memset_read_str): Likewise.
14255         (builtin_memset_gen_str): Likewise.
14256         (expand_builtin_signbit): Use scalar_int_mode for local variables.
14257         * cfgexpand.c (convert_debug_memory_address): Take a scalar_int_mode
14258         instead of a machine_mode.
14259         * combine.c (simplify_if_then_else): Use scalar_int_mode for local
14260         variables.
14261         (make_extraction): Likewise.
14262         (try_widen_shift_mode): Take and return scalar_int_modes instead
14263         of machine_modes.
14264         * config/aarch64/aarch64.c (aarch64_libgcc_cmp_return_mode): Return
14265         a scalar_int_mode instead of a machine_mode.
14266         * config/avr/avr.c (avr_addr_space_address_mode): Likewise.
14267         (avr_addr_space_pointer_mode): Likewise.
14268         * config/cr16/cr16.c (cr16_unwind_word_mode): Likewise.
14269         * config/msp430/msp430.c (msp430_addr_space_pointer_mode): Likewise.
14270         (msp430_unwind_word_mode): Likewise.
14271         * config/spu/spu.c (spu_unwind_word_mode): Likewise.
14272         (spu_addr_space_pointer_mode): Likewise.
14273         (spu_addr_space_address_mode): Likewise.
14274         (spu_libgcc_cmp_return_mode): Likewise.
14275         (spu_libgcc_shift_count_mode): Likewise.
14276         * config/rl78/rl78.c (rl78_addr_space_address_mode): Likewise.
14277         (rl78_addr_space_pointer_mode): Likewise.
14278         (fl78_unwind_word_mode): Likewise.
14279         (rl78_valid_pointer_mode): Take a scalar_int_mode instead of a
14280         machine_mode.
14281         * config/alpha/alpha.c (vms_valid_pointer_mode): Likewise.
14282         * config/ia64/ia64.c (ia64_vms_valid_pointer_mode): Likewise.
14283         * config/mips/mips.c (mips_mode_rep_extended): Likewise.
14284         (mips_valid_pointer_mode): Likewise.
14285         * config/tilegx/tilegx.c (tilegx_mode_rep_extended): Likewise.
14286         * config/ft32/ft32.c (ft32_valid_pointer_mode): Likewise.
14287         (ft32_addr_space_pointer_mode): Return a scalar_int_mode instead
14288         of a machine_mode.
14289         (ft32_addr_space_address_mode): Likewise.
14290         * config/m32c/m32c.c (m32c_valid_pointer_mode): Take a
14291         scalar_int_mode instead of a machine_mode.
14292         (m32c_addr_space_pointer_mode): Return a scalar_int_mode instead
14293         of a machine_mode.
14294         (m32c_addr_space_address_mode): Likewise.
14295         * config/powerpcspe/powerpcspe.c (rs6000_abi_word_mode): Likewise.
14296         (rs6000_eh_return_filter_mode): Likewise.
14297         * config/rs6000/rs6000.c (rs6000_abi_word_mode): Likewise.
14298         (rs6000_eh_return_filter_mode): Likewise.
14299         * config/s390/s390.c (s390_libgcc_cmp_return_mode): Likewise.
14300         (s390_libgcc_shift_count_mode): Likewise.
14301         (s390_unwind_word_mode): Likewise.
14302         (s390_valid_pointer_mode): Take a scalar_int_mode rather than a
14303         machine_mode.
14304         * target.def (mode_rep_extended): Likewise.
14305         (valid_pointer_mode): Likewise.
14306         (addr_space.valid_pointer_mode): Likewise.
14307         (eh_return_filter_mode): Return a scalar_int_mode rather than
14308         a machine_mode.
14309         (libgcc_cmp_return_mode): Likewise.
14310         (libgcc_shift_count_mode): Likewise.
14311         (unwind_word_mode): Likewise.
14312         (addr_space.pointer_mode): Likewise.
14313         (addr_space.address_mode): Likewise.
14314         * doc/tm.texi: Regenerate.
14315         * dojump.c (prefer_and_bit_test): Take a scalar_int_mode rather than
14316         a machine_mode.
14317         (do_jump): Use scalar_int_mode for local variables.
14318         * dwarf2cfi.c (init_return_column_size): Take a scalar_int_mode
14319         rather than a machine_mode.
14320         * dwarf2out.c (convert_descriptor_to_mode): Likewise.
14321         (scompare_loc_descriptor_wide): Likewise.
14322         (scompare_loc_descriptor_narrow): Likewise.
14323         * emit-rtl.c (adjust_address_1): Use scalar_int_mode for local
14324         variables.
14325         * except.c (sjlj_emit_dispatch_table): Likewise.
14326         (expand_builtin_eh_copy_values): Likewise.
14327         * explow.c (convert_memory_address_addr_space_1): Likewise.
14328         Take a scalar_int_mode rather than a machine_mode.
14329         (convert_memory_address_addr_space): Take a scalar_int_mode rather
14330         than a machine_mode.
14331         (memory_address_addr_space): Use scalar_int_mode for local variables.
14332         * expmed.h (expand_mult_highpart_adjust): Take a scalar_int_mode
14333         rather than a machine_mode.
14334         * expmed.c (mask_rtx): Likewise.
14335         (init_expmed_one_conv): Likewise.
14336         (expand_mult_highpart_adjust): Likewise.
14337         (extract_high_half): Likewise.
14338         (expmed_mult_highpart_optab): Likewise.
14339         (expmed_mult_highpart): Likewise.
14340         (expand_smod_pow2): Likewise.
14341         (expand_sdiv_pow2): Likewise.
14342         (emit_store_flag_int): Likewise.
14343         (adjust_bit_field_mem_for_reg): Use scalar_int_mode for local
14344         variables.
14345         (extract_low_bits): Likewise.
14346         * expr.h (by_pieces_constfn): Take a scalar_int_mode rather than
14347         a machine_mode.
14348         * expr.c (pieces_addr::adjust):  Likewise.
14349         (can_store_by_pieces): Likewise.
14350         (store_by_pieces): Likewise.
14351         (clear_by_pieces_1): Likewise.
14352         (expand_expr_addr_expr_1): Likewise.
14353         (expand_expr_addr_expr): Use scalar_int_mode for local variables.
14354         (expand_expr_real_1): Likewise.
14355         (try_casesi): Likewise.
14356         * final.c (shorten_branches): Likewise.
14357         * fold-const.c (fold_convert_const_int_from_fixed): Change the
14358         type of "mode" to machine_mode.
14359         * internal-fn.c (expand_arith_overflow_result_store): Take a
14360         scalar_int_mode rather than a machine_mode.
14361         (expand_mul_overflow): Use scalar_int_mode for local variables.
14362         * loop-doloop.c (doloop_modify): Likewise.
14363         (doloop_optimize): Likewise.
14364         * optabs.c (expand_subword_shift): Take a scalar_int_mode rather
14365         than a machine_mode.
14366         (expand_doubleword_shift_condmove): Likewise.
14367         (expand_doubleword_shift): Likewise.
14368         (expand_doubleword_clz): Likewise.
14369         (expand_doubleword_popcount): Likewise.
14370         (expand_doubleword_parity): Likewise.
14371         (expand_absneg_bit): Use scalar_int_mode for local variables.
14372         (prepare_float_lib_cmp): Likewise.
14373         * rtl.h (convert_memory_address_addr_space_1): Take a scalar_int_mode
14374         rather than a machine_mode.
14375         (convert_memory_address_addr_space): Likewise.
14376         (get_mode_bounds): Likewise.
14377         (get_address_mode): Return a scalar_int_mode rather than a
14378         machine_mode.
14379         * rtlanal.c (get_address_mode): Likewise.
14380         * stor-layout.c (get_mode_bounds): Take a scalar_int_mode rather
14381         than a machine_mode.
14382         * targhooks.c (default_mode_rep_extended): Likewise.
14383         (default_valid_pointer_mode): Likewise.
14384         (default_addr_space_valid_pointer_mode): Likewise.
14385         (default_eh_return_filter_mode): Return a scalar_int_mode rather
14386         than a machine_mode.
14387         (default_libgcc_cmp_return_mode): Likewise.
14388         (default_libgcc_shift_count_mode): Likewise.
14389         (default_unwind_word_mode): Likewise.
14390         (default_addr_space_pointer_mode): Likewise.
14391         (default_addr_space_address_mode): Likewise.
14392         * targhooks.h (default_eh_return_filter_mode): Likewise.
14393         (default_libgcc_cmp_return_mode): Likewise.
14394         (default_libgcc_shift_count_mode): Likewise.
14395         (default_unwind_word_mode): Likewise.
14396         (default_addr_space_pointer_mode): Likewise.
14397         (default_addr_space_address_mode): Likewise.
14398         (default_mode_rep_extended): Take a scalar_int_mode rather than
14399         a machine_mode.
14400         (default_valid_pointer_mode): Likewise.
14401         (default_addr_space_valid_pointer_mode): Likewise.
14402         * tree-ssa-address.c (addr_for_mem_ref): Use scalar_int_mode for
14403         local variables.
14404         * tree-ssa-loop-ivopts.c (get_shiftadd_cost): Take a scalar_int_mode
14405         rather than a machine_mode.
14406         * tree-switch-conversion.c (array_value_type): Use scalar_int_mode
14407         for local variables.
14408         * tree-vrp.c (simplify_float_conversion_using_ranges): Likewise.
14409         * var-tracking.c (use_narrower_mode): Take a scalar_int_mode rather
14410         than a machine_mode.
14412 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
14413             Alan Hayward  <alan.hayward@arm.com>
14414             David Sherwood  <david.sherwood@arm.com>
14416         * dojump.c (do_jump_by_parts_greater_rtx): Change the type of
14417         the mode argument to scalar_int_mode.
14418         (do_jump_by_parts_zero_rtx): Likewise.
14419         (do_jump_by_parts_equality_rtx): Likewise.
14420         (do_jump_by_parts_greater): Take a mode argument.
14421         (do_jump_by_parts_equality): Likewise.
14422         (do_jump_1): Update calls accordingly.
14424 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
14425             Alan Hayward  <alan.hayward@arm.com>
14426             David Sherwood  <david.sherwood@arm.com>
14428         * is-a.h (safe_dyn_cast): New function.
14429         * rtl.h (rtx_jump_table_data::get_data_mode): New function.
14430         (jump_table_for_label): Likewise.
14431         * final.c (final_addr_vec_align): Take an rtx_jump_table_data *
14432         instead of an rtx_insn *.
14433         (shorten_branches): Use dyn_cast instead of LABEL_P and
14434         JUMP_TABLE_DATA_P.  Use jump_table_for_label and
14435         rtx_jump_table_data::get_data_mode.
14436         (final_scan_insn): Likewise.
14438 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
14439             Alan Hayward  <alan.hayward@arm.com>
14440             David Sherwood  <david.sherwood@arm.com>
14442         * combine.c (try_combine): Use is_a <scalar_int_mode> when
14443         trying to combine a full-register integer set with a subreg
14444         integer set.
14446 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
14447             Alan Hayward  <alan.hayward@arm.com>
14448             David Sherwood  <david.sherwood@arm.com>
14450         * expr.c (expand_expr_addr_expr): Add a new_tmode local variable
14451         that is always either address_mode or pointer_mode.
14453 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
14454             Alan Hayward  <alan.hayward@arm.com>
14455             David Sherwood  <david.sherwood@arm.com>
14457         * expr.c (expand_expr_real_2): Use word_mode instead of innermode
14458         when the two are known to be equal.
14460 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
14461             Alan Hayward  <alan.hayward@arm.com>
14462             David Sherwood  <david.sherwood@arm.com>
14464         * simplify-rtx.c (simplify_const_unary_operation): Use
14465         is_a <scalar_int_mode> instead of checking for a nonzero
14466         precision.  Forcibly convert op_mode to a scalar_int_mode
14467         in that case.  More clearly differentiate the operand and
14468         result modes and use the former when deciding what the value
14469         of a count-bits operation should be.  Use is_int_mode instead
14470         of checking for a MODE_INT.  Remove redundant check for whether
14471         this mode has a zero precision.
14473 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
14474             Alan Hayward  <alan.hayward@arm.com>
14475             David Sherwood  <david.sherwood@arm.com>
14477         * optabs.c (widen_leading): Change the type of the mode argument
14478         to scalar_int_mode.  Use opt_scalar_int_mode for the mode iterator.
14479         (widen_bswap): Likewise.
14480         (expand_parity): Likewise.
14481         (expand_ctz): Change the type of the mode argument to scalar_int_mode.
14482         (expand_ffs): Likewise.
14483         (epand_unop): Check for scalar integer modes before calling the
14484         above routines.
14486 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
14487             Alan Hayward  <alan.hayward@arm.com>
14488             David Sherwood  <david.sherwood@arm.com>
14490         * expr.c (const_scalar_mask_from_tree): Add a mode argument.
14491         Expand commentary.
14492         (expand_expr_real_1): Update call accordingly.
14494 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
14495             Alan Hayward  <alan.hayward@arm.com>
14496             David Sherwood  <david.sherwood@arm.com>
14498         * expmed.c (store_bit_field_using_insv): Add op0_mode and
14499         value_mode arguments.  Use scalar_int_mode internally.
14500         (store_bit_field_1): Rename the new integer mode from imode
14501         to op0_mode and use it instead of GET_MODE (op0).  Update calls
14502         to store_split_bit_field, store_bit_field_using_insv and
14503         store_fixed_bit_field.
14504         (store_fixed_bit_field): Add op0_mode and value_mode arguments.
14505         Use scalar_int_mode internally.  Use a bit count rather than a mode
14506         when calculating the largest bit size for get_best_mode.
14507         Update calls to store_split_bit_field and store_fixed_bit_field_1.
14508         (store_fixed_bit_field_1): Add mode and value_mode arguments.
14509         Remove assertion that OP0 has a scalar integer mode.
14510         (store_split_bit_field): Add op0_mode and value_mode arguments.
14511         Update calls to extract_fixed_bit_field.
14512         (extract_bit_field_using_extv): Add an op0_mode argument.
14513         Use scalar_int_mode internally.
14514         (extract_bit_field_1): Rename the new integer mode from imode to
14515         op0_mode and use it instead of GET_MODE (op0).  Update calls to
14516         extract_split_bit_field, extract_bit_field_using_extv and
14517         extract_fixed_bit_field.
14518         (extract_fixed_bit_field): Add an op0_mode argument.  Update calls
14519         to extract_split_bit_field and extract_fixed_bit_field_1.
14520         (extract_fixed_bit_field_1): Add a mode argument.  Remove assertion
14521         that OP0 has a scalar integer mode.  Use as_a <scalar_int_mode>
14522         on the target mode.
14523         (extract_split_bit_field): Add an op0_mode argument.  Update call
14524         to extract_fixed_bit_field.
14526 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
14527             Alan Hayward  <alan.hayward@arm.com>
14528             David Sherwood  <david.sherwood@arm.com>
14530         * cse.c (cse_insn): Use opt_scalar_int_mode for the mode iterator.
14531         * explow.c (hard_function_value): Likewise.
14532         * expmed.c (extract_fixed_bit_field_1): Likewise.  Move the
14533         convert_to_mode call outside the loop.
14534         * expr.c (alignment_for_piecewise_move): Use opt_scalar_int_mode
14535         for the mode iterator.  Require the mode specified by max_pieces
14536         to exist.
14537         (emit_block_move_via_movmem): Use opt_scalar_int_mode for the
14538         mode iterator.
14539         (copy_blkmode_to_reg): Likewise.
14540         (set_storage_via_setmem): Likewise.
14541         * optabs.c (prepare_cmp_insn): Likewise.
14542         * rtlanal.c (init_num_sign_bit_copies_in_rep): Likewise.
14543         * stor-layout.c (finish_bitfield_representative): Likewise.
14545 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
14546             Alan Hayward  <alan.hayward@arm.com>
14547             David Sherwood  <david.sherwood@arm.com>
14549         * rtl.h (subreg_unpromoted_mode, subreg_promoted_mode): New functions.
14550         * expr.c (convert_move): Use them.
14551         (convert_modes): Likewise.
14552         (store_expr_with_bounds): Likewise.
14554 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
14555             Alan Hayward  <alan.hayward@arm.com>
14556             David Sherwood  <david.sherwood@arm.com>
14558         * rtl.h (rtl_hooks::reg_nonzero_bits): Add a scalar_int_mode
14559         parameter for the mode of "x".  Remove the "known_x", "known_mode"
14560         and "known_ret" arguments.  Change the type of the mode argument
14561         to scalar_int_mode.
14562         (rtl_hooks:reg_num_sign_bit_copies): Likewise.
14563         * combine.c (reg_nonzero_bits_for_combine): Update accordingly.
14564         (reg_num_sign_bit_copies_for_combine): Likewise.
14565         * rtlanal.c (nonzero_bits1): Likewise.
14566         (num_sign_bit_copies1): Likewise.
14567         * rtlhooks-def.h (reg_nonzero_bits_general): Likewise.
14568         (reg_num_sign_bit_copies_general): Likewise.
14569         * rtlhooks.c (reg_num_sign_bit_copies_general): Likewise.
14570         (reg_nonzero_bits_general): Likewise.
14572 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
14573             Alan Hayward  <alan.hayward@arm.com>
14574             David Sherwood  <david.sherwood@arm.com>
14576         * rtlanal.c (num_sign_bit_copies): Handle VOIDmode here rather
14577         than in subroutines.  Return 1 for non-integer modes.
14578         (cached_num_sign_bit_copies): Change the type of the mode parameter
14579         to scalar_int_mode.
14580         (num_sign_bit_copies1): Likewise.  Remove early exit for other mode
14581         classes.  Handle CONST_INT_P first and then check whether X also
14582         has a scalar integer mode.  Check the same thing for inner registers
14583         of a SUBREG and for values that are being extended or truncated.
14585 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
14586             Alan Hayward  <alan.hayward@arm.com>
14587             David Sherwood  <david.sherwood@arm.com>
14589         * rtlanal.c (nonzero_bits): Handle VOIDmode here rather than
14590         in subroutines.  Return the mode mask for non-integer modes.
14591         (cached_nonzero_bits): Change the type of the mode parameter
14592         to scalar_int_mode.
14593         (nonzero_bits1): Likewise.  Remove early exit for other mode
14594         classes.  Handle CONST_INT_P first and then check whether X
14595         also has a scalar integer mode.
14597 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
14598             Alan Hayward  <alan.hayward@arm.com>
14599             David Sherwood  <david.sherwood@arm.com>
14601         * expr.c (widest_int_mode_for_size): Make the comment match the code.
14602         Return a scalar_int_mode and assert that the size is greater than
14603         one byte.
14604         (by_pieces_ninsns): Update accordingly and remove VOIDmode handling.
14605         (op_by_pieces_d::op_by_pieces_d): Likewise.
14606         (op_by_pieces_d::run): Likewise.
14607         (can_store_by_pieces): Likewise.
14609 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
14610             Alan Hayward  <alan.hayward@arm.com>
14611             David Sherwood  <david.sherwood@arm.com>
14613         * combine.c (extract_left_shift): Add a mode argument and update
14614         recursive calls.
14615         (make_compound_operation_int): Change the type of the mode parameter
14616         to scalar_int_mode and update the call to extract_left_shift.
14618 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
14619             Alan Hayward  <alan.hayward@arm.com>
14620             David Sherwood  <david.sherwood@arm.com>
14622         * combine.c (simplify_and_const_int): Change the type of the mode
14623         parameter to scalar_int_mode.
14624         (simplify_and_const_int_1): Likewise.  Update recursive call.
14626 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
14627             Alan Hayward  <alan.hayward@arm.com>
14628             David Sherwood  <david.sherwood@arm.com>
14630         * combine.c (simplify_compare_const): Check that the mode is a
14631         scalar_int_mode (rather than VOIDmode) before testing its
14632         precision.
14633         (simplify_comparison): Move COMPARISON_P handling out of the
14634         loop and restrict the latter part of the loop to scalar_int_modes.
14635         Check is_a <scalar_int_mode> before calling HWI_COMPUTABLE_MODE_P
14636         and when considering SUBREG_REGs.  Use is_int_mode instead of
14637         checking GET_MODE_CLASS against MODE_INT.
14639 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
14640             Alan Hayward  <alan.hayward@arm.com>
14641             David Sherwood  <david.sherwood@arm.com>
14643         * combine.c (try_widen_shift_mode): Move check for equal modes to...
14644         (simplify_shift_const_1): ...here.  Use scalar_int_mode for
14645         shift_unit_mode and for modes involved in scalar shifts.
14647 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
14648             Alan Hayward  <alan.hayward@arm.com>
14649             David Sherwood  <david.sherwood@arm.com>
14651         * combine.c (force_int_to_mode): New function, split out from...
14652         (force_to_mode): ...here.  Keep xmode up-to-date and use it
14653         instead of GET_MODE (x).
14655 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
14656             Alan Hayward  <alan.hayward@arm.com>
14657             David Sherwood  <david.sherwood@arm.com>
14659         * optabs-query.h (extraction_insn::struct_mode): Change type to
14660         opt_scalar_int_mode and update comment.
14661         (extraction_insn::field_mode): Change type to scalar_int_mode.
14662         (extraction_insn::pos_mode): Likewise.
14663         * combine.c (make_extraction): Update accordingly.
14664         * optabs-query.c (get_traditional_extraction_insn): Likewise.
14665         (get_optab_extraction_insn): Likewise.
14666         * recog.c (simplify_while_replacing): Likewise.
14667         * expmed.c (narrow_bit_field_mem): Change the type of the mode
14668         parameter to opt_scalar_int_mode.
14670 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
14671             Alan Hayward  <alan.hayward@arm.com>
14672             David Sherwood  <david.sherwood@arm.com>
14674         * machmode.h (bit_field_mode_iterator::next_mode): Take a pointer
14675         to a scalar_int_mode instead of a machine_mode.
14676         (bit_field_mode_iterator::m_mode): Change type to opt_scalar_int_mode.
14677         (get_best_mode): Return a boolean and use a pointer argument to store
14678         the selected mode.  Replace the limit mode parameter with a bit limit.
14679         * expmed.c (adjust_bit_field_mem_for_reg): Use scalar_int_mode
14680         for the values returned by bit_field_mode_iterator::next_mode.
14681         (store_bit_field): Update call to get_best_mode.
14682         (store_fixed_bit_field): Likewise.
14683         (extract_fixed_bit_field): Likewise.
14684         * expr.c (optimize_bitfield_assignment_op): Likewise.
14685         * fold-const.c (optimize_bit_field_compare): Likewise.
14686         (fold_truth_andor_1): Likewise.
14687         * stor-layout.c (bit_field_mode_iterator::next_mode): As above.
14688         Update for new type of m_mode.
14689         (get_best_mode): As above.
14691 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
14692             Alan Hayward  <alan.hayward@arm.com>
14693             David Sherwood  <david.sherwood@arm.com>
14695         * expmed.c (strict_volatile_bitfield_p): Change the type of fieldmode
14696         to scalar_int_mode.  Remove check for SCALAR_INT_MODE_P.
14697         (store_bit_field): Check is_a <scalar_int_mode> before calling
14698         strict_volatile_bitfield_p.
14699         (extract_bit_field): Likewise.
14701 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
14702             Alan Hayward  <alan.hayward@arm.com>
14703             David Sherwood  <david.sherwood@arm.com>
14705         * target.def (cstore_mode): Return a scalar_int_mode.
14706         * doc/tm.texi: Regenerate.
14707         * config/sparc/sparc.c (sparc_cstore_mode): Return a scalar_int_mode.
14708         * targhooks.h (default_cstore_mode): Likewise.
14709         * targhooks.c (default_cstore_mode): Likewise, using a forced
14710         conversion.
14711         * expmed.c (emit_cstore): Expect the target of the cstore to be
14712         a scalar_int_mode.
14714 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
14715             Alan Hayward  <alan.hayward@arm.com>
14716             David Sherwood  <david.sherwood@arm.com>
14718         * cfgloop.h (rtx_iv): Change type of extend_mode and mode to
14719         scalar_int_mode.
14720         (niter_desc): Likewise mode.
14721         (iv_analyze): Add a mode parameter.
14722         (biv_p): Likewise.
14723         (iv_analyze_expr): Pass the mode paraeter before the rtx it describes
14724         and change its type to scalar_int_mode.
14725         * loop-iv.c: Update commentary at head of file.
14726         (iv_constant): Pass the mode paraeter before the rtx it describes
14727         and change its type to scalar_int_mode.  Remove VOIDmode handling.
14728         (iv_subreg): Change the type of the mode parameter to scalar_int_mode.
14729         (iv_extend): Likewise.
14730         (shorten_into_mode): Likewise.
14731         (iv_add): Use scalar_int_mode.
14732         (iv_mult): Likewise.
14733         (iv_shift): Likewise.
14734         (canonicalize_iv_subregs): Likewise.
14735         (get_biv_step_1): Pass the outer_mode parameter before the rtx
14736         it describes and change its mode to scalar_int_mode.   Also change
14737         the type of the returned inner_mode to scalar_int_mode.
14738         (get_biv_step): Likewise, turning outer_mode from a pointer
14739         into a direct parameter.  Update call to get_biv_step_1.
14740         (iv_analyze_biv): Add an outer_mode parameter.  Update calls to
14741         iv_constant and get_biv_step.
14742         (iv_analyze_expr): Pass the mode parameter before the rtx it describes
14743         and change its type to scalar_int_mode.  Don't initialise iv->mode
14744         to VOIDmode and remove later checks for its still being VOIDmode.
14745         Update calls to iv_analyze_op and iv_analyze_expr.  Check
14746         is_a <scalar_int_mode> when changing the mode under consideration.
14747         (iv_analyze_def): Ignore registers that don't have a scalar_int_mode.
14748         Update call to iv_analyze_expr.
14749         (iv_analyze_op): Add a mode parameter.  Reject subregs whose
14750         inner register is not also a scalar_int_mode.  Update call to
14751         iv_analyze_biv.
14752         (iv_analyze): Add a mode parameter.  Update call to iv_analyze_op.
14753         (biv_p): Add a mode parameter.  Update call to iv_analyze_biv.
14754         (iv_number_of_iterations): Use is_a <scalar_int_mode> instead of
14755         separate mode class checks.  Update calls to iv_analyze.  Remove
14756         fix-up of VOIDmodes after iv_analyze_biv.
14757         * loop-unroll.c (analyze_iv_to_split_insn): Reject registers that
14758         don't have a scalar_int_mode.  Update call to biv_p.
14760 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
14761             Alan Hayward  <alan.hayward@arm.com>
14762             David Sherwood  <david.sherwood@arm.com>
14764         * cfgexpand.c (convert_debug_memory_address): Use
14765         as_a <scalar_int_mode>.
14766         * combine.c (expand_compound_operation): Likewise.
14767         (make_extraction): Likewise.
14768         (change_zero_ext): Likewise.
14769         (simplify_comparison): Likewise.
14770         * cse.c (cse_insn): Likewise.
14771         * dwarf2out.c (minmax_loc_descriptor): Likewise.
14772         (mem_loc_descriptor): Likewise.
14773         (loc_descriptor): Likewise.
14774         * expmed.c (init_expmed_one_mode): Likewise.
14775         (synth_mult): Likewise.
14776         (emit_store_flag_1): Likewise.
14777         (expand_divmod): Likewise.  Use HWI_COMPUTABLE_MODE_P instead
14778         of a comparison with size.
14779         * expr.c (expand_assignment): Use as_a <scalar_int_mode>.
14780         (reduce_to_bit_field_precision): Likewise.
14781         * function.c (expand_function_end): Likewise.
14782         * internal-fn.c (expand_arith_overflow_result_store): Likewise.
14783         * loop-doloop.c (doloop_modify): Likewise.
14784         * optabs.c (expand_binop): Likewise.
14785         (expand_unop): Likewise.
14786         (expand_copysign_absneg): Likewise.
14787         (prepare_cmp_insn): Likewise.
14788         (maybe_legitimize_operand): Likewise.
14789         * recog.c (const_scalar_int_operand): Likewise.
14790         * rtlanal.c (get_address_mode): Likewise.
14791         * simplify-rtx.c (simplify_unary_operation_1): Likewise.
14792         (simplify_cond_clz_ctz): Likewise.
14793         * tree-nested.c (get_nl_goto_field): Likewise.
14794         * tree.c (build_vector_type_for_mode): Likewise.
14795         * var-tracking.c (use_narrower_mode): Likewise.
14797 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
14798             Alan Hayward  <alan.hayward@arm.com>
14799             David Sherwood  <david.sherwood@arm.com>
14801         * tree.h (SCALAR_INT_TYPE_MODE): New macro.
14802         * builtins.c (expand_builtin_signbit): Use it.
14803         * cfgexpand.c (expand_debug_expr): Likewise.
14804         * dojump.c (do_jump): Likewise.
14805         (do_compare_and_jump): Likewise.
14806         * dwarf2cfi.c (expand_builtin_init_dwarf_reg_sizes): Likewise.
14807         * expmed.c (make_tree): Likewise.
14808         * expr.c (expand_expr_real_2): Likewise.
14809         (expand_expr_real_1): Likewise.
14810         (try_casesi): Likewise.
14811         * fold-const-call.c (fold_const_call_ss): Likewise.
14812         * fold-const.c (unextend): Likewise.
14813         (extract_muldiv_1): Likewise.
14814         (fold_single_bit_test): Likewise.
14815         (native_encode_int): Likewise.
14816         (native_encode_string): Likewise.
14817         (native_interpret_int): Likewise.
14818         * gimple-fold.c (gimple_fold_builtin_memset): Likewise.
14819         * internal-fn.c (expand_addsub_overflow): Likewise.
14820         (expand_neg_overflow): Likewise.
14821         (expand_mul_overflow): Likewise.
14822         (expand_arith_overflow): Likewise.
14823         * match.pd: Likewise.
14824         * stor-layout.c (layout_type): Likewise.
14825         * tree-cfg.c (verify_gimple_assign_ternary): Likewise.
14826         * tree-ssa-math-opts.c (convert_mult_to_widen): Likewise.
14827         * tree-ssanames.c (get_range_info): Likewise.
14828         * tree-switch-conversion.c (array_value_type) Likewise.
14829         * tree-vect-patterns.c (vect_recog_rotate_pattern): Likewise.
14830         (vect_recog_divmod_pattern): Likewise.
14831         (vect_recog_mixed_size_cond_pattern): Likewise.
14832         * tree-vrp.c (extract_range_basic): Likewise.
14833         (simplify_float_conversion_using_ranges): Likewise.
14834         * tree.c (int_fits_type_p): Likewise.
14835         * ubsan.c (instrument_bool_enum_load): Likewise.
14836         * varasm.c (mergeable_string_section): Likewise.
14837         (narrowing_initializer_constant_valid_p): Likewise.
14838         (output_constant): Likewise.
14840 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
14841             Alan Hayward  <alan.hayward@arm.com>
14842             David Sherwood  <david.sherwood@arm.com>
14844         * machmode.h (NARROWEST_INT_MODE): New macro.
14845         * expr.c (alignment_for_piecewise_move): Use it instead of
14846         GET_CLASS_NARROWEST_MODE (MODE_INT).
14847         (push_block): Likewise.
14848         * stor-layout.c (bit_field_mode_iterator::bit_field_mode_iterator):
14849         Likewise.
14850         * tree-vrp.c (simplify_float_conversion_using_ranges): Likewise.
14852 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
14853             Alan Hayward  <alan.hayward@arm.com>
14854             David Sherwood  <david.sherwood@arm.com>
14856         * postreload.c (move2add_valid_value_p): Change the type of the
14857         mode parameter to scalar_int_mode.
14858         (move2add_use_add2_insn): Add a mode parameter and use it instead
14859         of GET_MODE (reg).
14860         (move2add_use_add3_insn): Likewise.
14861         (reload_cse_move2add): Update accordingly.
14863 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
14864             Alan Hayward  <alan.hayward@arm.com>
14865             David Sherwood  <david.sherwood@arm.com>
14867         * expr.c (expand_expr_real_2): Use scalar_int_mode for the
14868         double-word mode.
14869         * lower-subreg.c (resolve_shift_zext): Use is_a <scalar_int_mode>.
14870         * optabs.c (expand_unop): Likewise.
14872 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
14873             Alan Hayward  <alan.hayward@arm.com>
14874             David Sherwood  <david.sherwood@arm.com>
14876         * dwarf2out.c (typed_binop): Change mode parameter to scalar_int_mode.
14877         (clz_loc_descriptor): Likewise.  Remove SCALAR_INT_MODE_P check.
14878         (popcount_loc_descriptor): Likewise.
14879         (bswap_loc_descriptor): Likewise.
14880         (rotate_loc_descriptor): Likewise.
14881         (mem_loc_descriptor): Add is_a <scalar_int_mode> checks before
14882         calling the functions above.
14884 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
14885             Alan Hayward  <alan.hayward@arm.com>
14886             David Sherwood  <david.sherwood@arm.com>
14888         * combine.c (sign_extend_short_imm): Add is_a <scalar_int_mode>
14889         checks.
14890         (try_combine): Likewise.
14891         (simplify_if_then_else): Likewise.
14892         * cse.c (cse_insn): Likewise.
14893         * dwarf2out.c (mem_loc_descriptor): Likewise.
14894         * emit-rtl.c (gen_lowpart_common): Likewise.
14895         * simplify-rtx.c (simplify_truncation): Likewise.
14896         (simplify_binary_operation_1): Likewise.
14897         (simplify_const_relational_operation): Likewise.
14898         (simplify_ternary_operation): Likewise.
14899         * tree-ssa-loop-ivopts.c (force_expr_to_var_cost): Likewise.
14901 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
14902             Alan Hayward  <alan.hayward@arm.com>
14903             David Sherwood  <david.sherwood@arm.com>
14905         * cse.c (cse_insn): Add is_a <scalar_int_mode> checks.
14906         * reload.c (push_reload): Likewise.
14907         (find_reloads): Likewise.
14909 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
14910             Alan Hayward  <alan.hayward@arm.com>
14911             David Sherwood  <david.sherwood@arm.com>
14913         * combine.c (find_split_point): Add is_a <scalar_int_mode> checks.
14914         (make_compound_operation_int): Likewise.
14915         (change_zero_ext): Likewise.
14916         * expr.c (convert_move): Likewise.
14917         (convert_modes): Likewise.
14918         * fwprop.c (forward_propagate_subreg): Likewise.
14919         * loop-iv.c (get_biv_step_1): Likewise.
14920         * optabs.c (widen_operand): Likewise.
14921         * postreload.c (move2add_valid_value_p): Likewise.
14922         * recog.c (simplify_while_replacing): Likewise.
14923         * simplify-rtx.c (simplify_unary_operation_1): Likewise.
14924         (simplify_binary_operation_1): Likewise.  Remove redundant
14925         mode equality check.
14927 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
14928             Alan Hayward  <alan.hayward@arm.com>
14929             David Sherwood  <david.sherwood@arm.com>
14931         * combine.c (combine_simplify_rtx): Add checks for
14932         is_a <scalar_int_mode>.
14933         (simplify_if_then_else): Likewise.
14934         (make_field_assignment): Likewise.
14935         (simplify_comparison): Likewise.
14936         * ifcvt.c (noce_try_bitop): Likewise.
14937         * loop-invariant.c (canonicalize_address_mult): Likewise.
14938         * simplify-rtx.c (simplify_unary_operation_1): Likewise.
14940 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
14941             Alan Hayward  <alan.hayward@arm.com>
14942             David Sherwood  <david.sherwood@arm.com>
14944         * gimple-fold.c (gimple_fold_builtin_memory_op): Use
14945         is_a <scalar_int_mode> instead of != BLKmode.
14947 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
14948             Alan Hayward  <alan.hayward@arm.com>
14949             David Sherwood  <david.sherwood@arm.com>
14951         * cfgexpand.c (expand_debug_expr): Use is_a <scalar_int_mode>
14952         instead of != VOIDmode.
14953         * combine.c (if_then_else_cond): Likewise.
14954         (change_zero_ext): Likewise.
14955         * dwarf2out.c (mem_loc_descriptor): Likewise.
14956         (loc_descriptor): Likewise.
14957         * rtlanal.c (canonicalize_condition): Likewise.
14958         * simplify-rtx.c (simplify_relational_operation_1): Likewise.
14960 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
14961             Alan Hayward  <alan.hayward@arm.com>
14962             David Sherwood  <david.sherwood@arm.com>
14964         * simplify-rtx.c (simplify_binary_operation_1): Use
14965         is_a <scalar_int_mode> instead of !VECTOR_MODE_P.
14967 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
14968             Alan Hayward  <alan.hayward@arm.com>
14969             David Sherwood  <david.sherwood@arm.com>
14971         * wide-int.h (int_traits<unsigned char>) New class.
14972         (int_traits<unsigned short>) Likewise.
14973         * cfgexpand.c (expand_debug_expr): Use is_a <scalar_int_mode>.
14974         Use GET_MODE_UNIT_PRECISION and remove redundant test for
14975         SCALAR_INT_MODE_P.
14976         * combine.c (set_nonzero_bits_and_sign_copies): Use
14977         is_a <scalar_int_mode>.
14978         (find_split_point): Likewise.
14979         (combine_simplify_rtx): Likewise.
14980         (simplify_logical): Likewise.
14981         (expand_compound_operation): Likewise.
14982         (expand_field_assignment): Likewise.
14983         (make_compound_operation): Likewise.
14984         (extended_count): Likewise.
14985         (change_zero_ext): Likewise.
14986         (simplify_comparison): Likewise.
14987         * dwarf2out.c (scompare_loc_descriptor): Likewise.
14988         (ucompare_loc_descriptor): Likewise.
14989         (minmax_loc_descriptor): Likewise.
14990         (mem_loc_descriptor): Likewise.
14991         (loc_descriptor): Likewise.
14992         * expmed.c (init_expmed_one_mode): Likewise.
14993         * lra-constraints.c (lra_constraint_offset): Likewise.
14994         * optabs.c (prepare_libcall_arg): Likewise.
14995         * postreload.c (move2add_note_store): Likewise.
14996         * reload.c (operands_match_p): Likewise.
14997         * rtl.h (load_extend_op): Likewise.
14998         * rtlhooks.c (gen_lowpart_general): Likewise.
14999         * simplify-rtx.c (simplify_truncation): Likewise.
15000         (simplify_unary_operation_1): Likewise.
15001         (simplify_binary_operation_1): Likewise.
15002         (simplify_const_binary_operation): Likewise.
15003         (simplify_const_relational_operation): Likewise.
15004         (simplify_subreg): Likewise.
15005         * stor-layout.c (bitwise_mode_for_mode): Likewise.
15006         * var-tracking.c (adjust_mems): Likewise.
15007         (prepare_call_arguments): Likewise.
15009 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
15010             Alan Hayward  <alan.hayward@arm.com>
15011             David Sherwood  <david.sherwood@arm.com>
15013         * machmode.h (is_int_mode): New fuction.
15014         * combine.c (find_split_point): Use it.
15015         (combine_simplify_rtx): Likewise.
15016         (simplify_if_then_else): Likewise.
15017         (simplify_set): Likewise.
15018         (simplify_shift_const_1): Likewise.
15019         (simplify_comparison): Likewise.
15020         * config/aarch64/aarch64.c (aarch64_rtx_costs): Likewise.
15021         * cse.c (notreg_cost): Likewise.
15022         (cse_insn): Likewise.
15023         * cselib.c (cselib_lookup_1): Likewise.
15024         * dojump.c (do_jump_1): Likewise.
15025         (do_compare_rtx_and_jump): Likewise.
15026         * dse.c (get_call_args): Likewise.
15027         * dwarf2out.c (rtl_for_decl_init): Likewise.
15028         (native_encode_initializer): Likewise.
15029         * expmed.c (emit_store_flag_1): Likewise.
15030         (emit_store_flag): Likewise.
15031         * expr.c (convert_modes): Likewise.
15032         (store_field): Likewise.
15033         (expand_expr_real_1): Likewise.
15034         * fold-const.c (fold_read_from_constant_string): Likewise.
15035         * gimple-ssa-sprintf.c (get_format_string): Likewise.
15036         * optabs-libfuncs.c (gen_int_libfunc): Likewise.
15037         * optabs.c (expand_binop): Likewise.
15038         (expand_unop): Likewise.
15039         (expand_abs_nojump): Likewise.
15040         (expand_one_cmpl_abs_nojump): Likewise.
15041         * simplify-rtx.c (mode_signbit_p): Likewise.
15042         (val_signbit_p): Likewise.
15043         (val_signbit_known_set_p): Likewise.
15044         (val_signbit_known_clear_p): Likewise.
15045         (simplify_relational_operation_1): Likewise.
15046         * tree.c (vector_type_mode): Likewise.
15048 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
15049             Alan Hayward  <alan.hayward@arm.com>
15050             David Sherwood  <david.sherwood@arm.com>
15052         * machmode.h (smallest_mode_for_size): Fix formatting.
15053         (smallest_int_mode_for_size): New function.
15054         * cfgexpand.c (expand_debug_expr): Use smallest_int_mode_for_size
15055         instead of smallest_mode_for_size.
15056         * combine.c (make_extraction): Likewise.
15057         * config/arc/arc.c (arc_expand_movmem): Likewise.
15058         * config/arm/arm.c (arm_expand_divmod_libfunc): Likewise.
15059         * config/i386/i386.c (ix86_get_mask_mode): Likewise.
15060         * config/s390/s390.c (s390_expand_insv): Likewise.
15061         * config/sparc/sparc.c (assign_int_registers): Likewise.
15062         * config/spu/spu.c (spu_function_value): Likewise.
15063         (spu_function_arg): Likewise.
15064         * coverage.c (get_gcov_type): Likewise.
15065         (get_gcov_unsigned_t): Likewise.
15066         * dse.c (find_shift_sequence): Likewise.
15067         * expmed.c (store_bit_field_1): Likewise.
15068         * expr.c (convert_move): Likewise.
15069         (store_field): Likewise.
15070         * internal-fn.c (expand_arith_overflow): Likewise.
15071         * optabs-query.c (get_best_extraction_insn): Likewise.
15072         * optabs.c (expand_twoval_binop_libfunc): Likewise.
15073         * stor-layout.c (layout_type): Likewise.
15074         (initialize_sizetypes): Likewise.
15075         * targhooks.c (default_get_mask_mode): Likewise.
15076         * tree-ssa-loop-manip.c (canonicalize_loop_ivs): Likewise.
15078 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
15079             Alan Hayward  <alan.hayward@arm.com>
15080             David Sherwood  <david.sherwood@arm.com>
15082         * machmode.h (opt_mode::else_blk): New function.
15083         (int_mode_for_mode): Declare.
15084         * stor-layout.c (int_mode_for_mode): Return an opt_scalar_int_mode.
15085         * builtins.c (expand_builtin_signbit): Adjust for new int_mode_for_mode
15086         return type.
15087         * cfgexpand.c (expand_debug_expr): Likewise.
15088         * combine.c (gen_lowpart_or_truncate): Likewise.
15089         (gen_lowpart_for_combine): Likewise.
15090         * config/aarch64/aarch64.c (aarch64_emit_approx_sqrt): Likewise.
15091         * config/avr/avr.c (avr_to_int_mode): Likewise.
15092         (avr_out_plus_1): Likewise.
15093         (avr_out_plus): Likewise.
15094         (avr_out_round): Likewise.
15095         * config/i386/i386.c (ix86_split_to_parts): Likewise.
15096         * config/s390/s390.c (s390_expand_vec_compare_cc): Likewise.
15097         (s390_expand_vcond): Likewise.
15098         * config/spu/spu.c (spu_split_immediate): Likewise.
15099         (spu_expand_mov): Likewise.
15100         * dse.c (get_stored_val): Likewise.
15101         * expmed.c (store_bit_field_1): Likewise.
15102         (convert_extracted_bit_field): Use int_mode_for_mode instead of
15103         int_mode_for_size.
15104         (extract_bit_field_1): Adjust for new int_mode_for_mode return type.
15105         (extract_low_bits): Likewise.
15106         * expr.c (emit_group_load_1): Likewise.  Separate out the BLKmode
15107         handling rather than repeating the check.
15108         (emit_group_store): Likewise.
15109         (emit_move_via_integer): Adjust for new int_mode_for_mode return type.
15110         * optabs.c (expand_absneg_bit): Likewise.
15111         (expand_copysign_absneg): Likewise.
15112         (expand_copysign_bit): Likewise.
15113         * tree-if-conv.c (ifcvt_can_use_mask_load_store): Likewise.
15114         * tree-vect-slp.c (vect_transform_slp_perm_load): Likewise.
15115         * tree-vect-stmts.c (vect_gen_perm_mask_any): Likewise.
15116         * var-tracking.c (prepare_call_arguments):  Likewise.
15117         * config/powerpcspe/powerpcspe.c (rs6000_do_expand_vec_perm): Use
15118         int_mode_for_mode instead of mode_for_size.
15119         * config/rs6000/rs6000.c (rs6000_do_expand_vec_perm): Likewise.
15121 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
15122             Alan Hayward  <alan.hayward@arm.com>
15123             David Sherwood  <david.sherwood@arm.com>
15125         * machmode.h (int_mode_for_size): New function.
15126         * builtins.c (set_builtin_user_assembler_name): Use int_mode_for_size
15127         instead of mode_for_size.
15128         * calls.c (save_fixed_argument_area): Likewise.  Make use of BLKmode
15129         explicit.
15130         * combine.c (expand_field_assignment): Use int_mode_for_size
15131         instead of mode_for_size.
15132         (make_extraction): Likewise.
15133         (simplify_shift_const_1): Likewise.
15134         (simplify_comparison): Likewise.
15135         * dojump.c (do_jump): Likewise.
15136         * dwarf2out.c (mem_loc_descriptor): Likewise.
15137         * emit-rtl.c (init_derived_machine_modes): Likewise.
15138         * expmed.c (flip_storage_order): Likewise.
15139         (convert_extracted_bit_field): Likewise.
15140         * expr.c (copy_blkmode_from_reg): Likewise.
15141         * graphite-isl-ast-to-gimple.c (max_mode_int_precision): Likewise.
15142         * internal-fn.c (expand_mul_overflow): Likewise.
15143         * lower-subreg.c (simple_move): Likewise.
15144         * optabs-libfuncs.c (init_optabs): Likewise.
15145         * simplify-rtx.c (simplify_unary_operation_1): Likewise.
15146         * tree.c (vector_type_mode): Likewise.
15147         * tree-ssa-strlen.c (handle_builtin_memcmp): Likewise.
15148         * tree-vect-data-refs.c (vect_lanes_optab_supported_p): Likewise.
15149         * tree-vect-generic.c (expand_vector_parallel): Likewise.
15150         * tree-vect-stmts.c (vectorizable_load): Likewise.
15151         (vectorizable_store): Likewise.
15153 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
15154             Alan Hayward  <alan.hayward@arm.com>
15155             David Sherwood  <david.sherwood@arm.com>
15157         * coretypes.h (pod_mode): New type.
15158         (scalar_int_mode_pod): New typedef.
15159         * machmode.h (pod_mode): New class.
15160         (int_n_data_t::m): Change type to scalar_int_mode_pod.
15161         * genmodes.c (emit_mode_int_n): Update accordingly.
15162         * lower-subreg.h (target_lower_subreg): Change type to
15163         scalar_int_mode_pod.
15164         * gdbhooks.py (build_pretty_printer): Handle pod_mode and
15165         scalar_int_mode_pod.
15167 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
15168             Alan Hayward  <alan.hayward@arm.com>
15169             David Sherwood  <david.sherwood@arm.com>
15171         * config/powerpcspe/powerpcspe.h (rs6000_pmode): Change type from
15172         machine_mode to scalar_int_mode.
15173         * config/powerpcspe/powerpcspe.c (rs6000_pmode): Likewise.
15174         (rs6000_option_override_internal): Remove cast to int.
15175         * config/rs6000/rs6000.h (rs6000_pmode): Change type from
15176         machine_mode to scalar_int_mode.
15177         * config/rs6000/rs6000.c (rs6000_pmode): Likewise.
15178         (rs6000_option_override_internal): Remove cast to int.
15179         * config/s390/s390.h (Pmode): Remove cast to machine_mode.
15180         * config/epiphany/epiphany.h (RTX_OK_FOR_OFFSET_P): Add cast
15181         to machine_mode.
15182         * config/s390/s390.c (s390_expand_builtin): Likewise.
15183         * coretypes.h (scalar_int_mode): New type.
15184         (opt_scalar_int_mode): New typedef.
15185         * machmode.h (scalar_int_mode): New class.
15186         (scalar_int_mode::includes_p): New function.
15187         (byte_mode): Change type to scalar_int_mode.
15188         (word_mode): Likewise.
15189         (ptr_mode): Likewise.
15190         * emit-rtl.c (byte_mode): Likewise.
15191         (word_mode): Likewise.
15192         (ptr_mode): Likewise.
15193         (init_derived_machine_modes): Update accordingly.
15194         * genmodes.c (get_mode_class): Return scalar_int_mode for MODE_INT
15195         and MODE_PARTIAL_INT.
15196         * gdbhooks.py (build_pretty_printer): Handle scalar_int_mode and
15197         opt_scalar_int_mode.
15199 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
15200             Alan Hayward  <alan.hayward@arm.com>
15201             David Sherwood  <david.sherwood@arm.com>
15203         * target.def (libgcc_floating_mode_supported_p): Take a
15204         scalar_float_mode.
15205         * doc/tm.texi: Regenerate.
15206         * targhooks.h (default_libgcc_floating_mode_supported_p): Take a
15207         scalar_float_mode.
15208         * targhooks.c (default_libgcc_floating_mode_supported_p): Likewise.
15209         * config/aarch64/aarch64.c (aarch64_libgcc_floating_mode_supported_p):
15210         Likewise.
15212 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
15213             Alan Hayward  <alan.hayward@arm.com>
15214             David Sherwood  <david.sherwood@arm.com>
15216         * target.def (default_floatn_mode): Return an opt_scalar_float_mode.
15217         * doc/tm.texi: Regenerate.
15218         * config/arm/arm.c (arm_floatn_mode): Return an opt_scalar_float_mode.
15219         * config/powerpcspe/powerpcspe.c (rs6000_floatn_mode): Likewise.
15220         * config/rs6000/rs6000.c (rs6000_floatn_mode): Likewise.
15221         * targhooks.h (default_floatn_mode): Likewise.
15222         * targhooks.c (default_floatn_mode): Likewise.
15223         * tree.c (build_common_tree_nodes): Update accordingly.
15225 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
15226             Alan Hayward  <alan.hayward@arm.com>
15227             David Sherwood  <david.sherwood@arm.com>
15229         * machmode.h (mode_iterator::start): Provide overload for opt_modes.
15230         (mode_iterator::iterate_p): Likewise.
15231         (mode_iterator::get_wider): Likewise.
15232         * expr.c (init_expr_target): Use opt_scalar_float_mode.
15234 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
15235             Alan Hayward  <alan.hayward@arm.com>
15236             David Sherwood  <david.sherwood@arm.com>
15238         * coretypes.h (opt_scalar_float_mode): New typedef.
15239         * machmode.h (float_mode_for_size): New function.
15240         * emit-rtl.c (double_mode): Delete.
15241         (init_emit_once): Use float_mode_for_size.
15242         * stor-layout.c (layout_type): Likewise.
15243         * gdbhooks.py (build_pretty_printer): Handle opt_scalar_float_mode.
15245 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
15246             Alan Hayward  <alan.hayward@arm.com>
15247             David Sherwood  <david.sherwood@arm.com>
15249         * output.h (assemble_real): Take a scalar_float_mode.
15250         * config/arm/arm.c (arm_assemble_integer): Update accordingly.
15251         * config/arm/arm.md (consttable_4): Likewise.
15252         (consttable_8): Likewise.
15253         (consttable_16): Likewise.
15254         * config/mips/mips.md (consttable_float): Likewise.
15255         * config/s390/s390.c (s390_output_pool_entry): Likewise.
15256         * varasm.c (assemble_real): Take a scalar_float_mode.
15257         (output_constant_pool_2): Update accordingly.
15258         (output_constant): Likewise.
15260 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
15261             Alan Hayward  <alan.hayward@arm.com>
15262             David Sherwood  <david.sherwood@arm.com>
15264         * tree.h (SCALAR_FLOAT_TYPE_MODE): New macro.
15265         * builtins.c (expand_builtin_signbit): Use it instead of TYPE_MODE.
15266         * fold-const.c (fold_convert_const_real_from_fixed): Likewise.
15267         (native_encode_real): Likewise.
15268         (native_interpret_real): Likewise.
15269         * hsa-brig.c (emit_immediate_scalar_to_buffer): Likewise.
15270         * tree-vrp.c (simplify_float_conversion_using_ranges): Likewise.
15272 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
15273             Alan Hayward  <alan.hayward@arm.com>
15274             David Sherwood  <david.sherwood@arm.com>
15276         * optabs-libfuncs.c (gen_trunc_conv_libfunc): Use is_a
15277         <scalar_float_mode>.  Simplify.
15278         (gen_extend_conv_libfunc): Likewise.
15280 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
15281             Alan Hayward  <alan.hayward@arm.com>
15282             David Sherwood  <david.sherwood@arm.com>
15284         * coretypes.h (scalar_float_mode): New type.
15285         * machmode.h (mode_traits::from_int): Use machine_mode if
15286         USE_ENUM_MODES is defined.
15287         (is_a): New function.
15288         (as_a): Likewise.
15289         (dyn_cast): Likewise.
15290         (scalar_float_mode): New class.
15291         (scalar_float_mode::includes_p): New function.
15292         (is_float_mode): Likewise.
15293         * gdbhooks.py (MachineModePrinter): New class.
15294         (build_pretty_printer): Use it for scalar_float_mode.
15295         * real.h (FLOAT_MODE_FORMAT): Use as_a <scalar_float_mode>.
15296         (format_helper::format_helper): Turn into a template.
15297         * genmodes.c (get_mode_class): New function.
15298         (emit_insn_modes_h): Give modes the class returned by get_mode_class,
15299         or machine_mode if none.
15300         * config/aarch64/aarch64.c (aarch64_simd_valid_immediate): Use
15301         as_a <scalar_float_mode>.
15302         * dwarf2out.c (mem_loc_descriptor): Likewise.
15303         (insert_float): Likewise.
15304         (add_const_value_attribute): Likewise.
15305         * simplify-rtx.c (simplify_immed_subreg): Likewise.
15306         * optabs.c (expand_absneg_bit): Take a scalar_float_mode.
15307         (expand_unop): Update accordingly.
15308         (expand_abs_nojump): Likewise.
15309         (expand_copysign_absneg): Take a scalar_float_mode.
15310         (expand_copysign_bit): Likewise.
15311         (expand_copysign): Update accordingly.
15313 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
15314             Alan Hayward  <alan.hayward@arm.com>
15315             David Sherwood  <david.sherwood@arm.com>
15317         * coretypes.h (opt_mode): New class.
15318         * machmode.h (opt_mode): Likewise.
15319         (opt_mode::else_void): New function.
15320         (opt_mode::require): Likewise.
15321         (opt_mode::exists): Likewise.
15322         (GET_MODE_WIDER_MODE): Turn into a function and return an opt_mode.
15323         (GET_MODE_2XWIDER_MODE): Likewise.
15324         (mode_iterator::get_wider): Update accordingly.
15325         (mode_iterator::get_2xwider): Likewise.
15326         (mode_iterator::get_known_wider): Likewise, turning into a template.
15327         * combine.c (make_extraction): Update use of GET_MODE_WIDER_MODE,
15328         forcing a wider mode to exist.
15329         * config/cr16/cr16.h (LONG_REG_P): Likewise.
15330         * rtlanal.c (init_num_sign_bit_copies_in_rep): Likewise.
15331         * config/c6x/c6x.c (c6x_rtx_costs): Update use of
15332         GET_MODE_2XWIDER_MODE, forcing a wider mode to exist.
15333         * lower-subreg.c (init_lower_subreg): Likewise.
15334         * optabs-libfuncs.c (init_sync_libfuncs_1): Likewise, but not
15335         on the final iteration.
15336         * config/i386/i386.c (ix86_expand_set_or_movmem): Check whether
15337         a wider mode exists before asking for a move pattern.
15338         (get_mode_wider_vector): Update use of GET_MODE_WIDER_MODE,
15339         forcing a wider mode to exist.
15340         (expand_vselect_vconcat): Update use of GET_MODE_2XWIDER_MODE,
15341         returning false if no such mode exists.
15342         * config/ia64/ia64.c (expand_vselect_vconcat): Likewise.
15343         * config/mips/mips.c (mips_expand_vselect_vconcat): Likewise.
15344         * expmed.c (init_expmed_one_mode): Update use of GET_MODE_WIDER_MODE.
15345         Avoid checking for a MODE_INT if we already know the mode is not a
15346         SCALAR_INT_MODE_P.
15347         (extract_high_half): Update use of GET_MODE_WIDER_MODE,
15348         forcing a wider mode to exist.
15349         (expmed_mult_highpart_optab): Likewise.
15350         (expmed_mult_highpart): Likewise.
15351         * expr.c (expand_expr_real_2): Update use of GET_MODE_WIDER_MODE,
15352         using else_void.
15353         * lto-streamer-in.c (lto_input_mode_table): Likewise.
15354         * optabs-query.c (find_widening_optab_handler_and_mode): Likewise.
15355         * stor-layout.c (bit_field_mode_iterator::next_mode): Likewise.
15356         * internal-fn.c (expand_mul_overflow): Update use of
15357         GET_MODE_2XWIDER_MODE.
15358         * omp-low.c (omp_clause_aligned_alignment): Likewise.
15359         * tree-ssa-math-opts.c (convert_mult_to_widen): Update use of
15360         GET_MODE_WIDER_MODE.
15361         (convert_plusminus_to_widen): Likewise.
15362         * tree-switch-conversion.c (array_value_type): Likewise.
15363         * var-tracking.c (emit_note_insn_var_location): Likewise.
15364         * tree-vrp.c (simplify_float_conversion_using_ranges): Likewise.
15365         Return false inside rather than outside the loop if no wider mode
15366         exists
15367         * optabs.c (expand_binop): Update use of GET_MODE_WIDER_MODE
15368         and GET_MODE_2XWIDER_MODE
15369         (can_compare_p): Use else_void.
15370         * gdbhooks.py (OptMachineModePrinter): New class.
15371         (build_pretty_printer): Use it for opt_mode.
15373 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
15374             Alan Hayward  <alan.hayward@arm.com>
15375             David Sherwood  <david.sherwood@arm.com>
15377         * tree-switch-conversion.c (array_value_type): Only read TYPE_MODE
15378         once.  Use get_narrowest_mode instead of GET_CLASS_NARROWEST_MODE.
15380 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
15381             Alan Hayward  <alan.hayward@arm.com>
15382             David Sherwood  <david.sherwood@arm.com>
15384         * machmode.h (mode_traits): New structure.
15385         (get_narrowest_mode): New function.
15386         (mode_iterator::start): Likewise.
15387         (mode_iterator::iterate_p): Likewise.
15388         (mode_iterator::get_wider): Likewise.
15389         (mode_iterator::get_known_wider): Likewise.
15390         (mode_iterator::get_2xwider): Likewise.
15391         (FOR_EACH_MODE_IN_CLASS): New mode iterator.
15392         (FOR_EACH_MODE): Likewise.
15393         (FOR_EACH_MODE_FROM): Likewise.
15394         (FOR_EACH_MODE_UNTIL): Likewise.
15395         (FOR_EACH_WIDER_MODE): Likewise.
15396         (FOR_EACH_2XWIDER_MODE): Likewise.
15397         * builtins.c (expand_builtin_strlen): Use new mode iterators.
15398         * combine.c (simplify_comparison): Likewise
15399         * config/i386/i386.c (type_natural_mode): Likewise.
15400         * cse.c (cse_insn): Likewise.
15401         * dse.c (find_shift_sequence): Likewise.
15402         * emit-rtl.c (init_derived_machine_modes): Likewise.
15403         (init_emit_once): Likewise.
15404         * explow.c (hard_function_value): Likewise.
15405         * expmed.c (extract_fixed_bit_field_1): Likewise.
15406         (extract_bit_field_1): Likewise.
15407         (expand_divmod): Likewise.
15408         (emit_store_flag_1): Likewise.
15409         * expr.c (init_expr_target): Likewise.
15410         (convert_move): Likewise.
15411         (alignment_for_piecewise_move): Likewise.
15412         (widest_int_mode_for_size): Likewise.
15413         (emit_block_move_via_movmem): Likewise.
15414         (copy_blkmode_to_reg): Likewise.
15415         (set_storage_via_setmem): Likewise.
15416         (compress_float_constant): Likewise.
15417         * omp-low.c (omp_clause_aligned_alignment): Likewise.
15418         * optabs-query.c (get_best_extraction_insn): Likewise.
15419         * optabs.c (expand_binop): Likewise.
15420         (expand_twoval_unop): Likewise.
15421         (expand_twoval_binop): Likewise.
15422         (widen_leading): Likewise.
15423         (widen_bswap): Likewise.
15424         (expand_parity): Likewise.
15425         (expand_unop): Likewise.
15426         (prepare_cmp_insn): Likewise.
15427         (prepare_float_lib_cmp): Likewise.
15428         (expand_float): Likewise.
15429         (expand_fix): Likewise.
15430         (expand_sfix_optab): Likewise.
15431         * postreload.c (move2add_use_add2_insn): Likewise.
15432         * reg-stack.c (reg_to_stack): Likewise.
15433         * reginfo.c (choose_hard_reg_mode): Likewise.
15434         * rtlanal.c (init_num_sign_bit_copies_in_rep): Likewise.
15435         * stor-layout.c (mode_for_size): Likewise.
15436         (smallest_mode_for_size): Likewise.
15437         (mode_for_vector): Likewise.
15438         (finish_bitfield_representative): Likewise.
15439         * tree-ssa-math-opts.c (target_supports_divmod_p): Likewise.
15440         * tree-vect-generic.c (type_for_widest_vector_mode): Likewise.
15441         * tree-vect-stmts.c (vectorizable_conversion): Likewise.
15442         * var-tracking.c (prepare_call_arguments): Likewise.
15444 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
15445             Alan Hayward  <alan.hayward@arm.com>
15446             David Sherwood  <david.sherwood@arm.com>
15448         * genconditions.c (write_header): Add a "#define USE_ENUM_MODES".
15449         * genmodes.c (emit_insn_modes_h): Define FOOmode to E_FOOmode if
15450         USE_ENUM_MODES is defined and to ((void) 0, E_FOOmode) otherwise.
15451         * machmode.h (mode_size): Move earlier in file.
15452         (mode_precision): Likewise.
15453         (mode_inner): Likewise.
15454         (mode_nunits): Likewise.
15455         (mode_unit_size): Likewise.
15456         (unit_unit_precision): Likewise.
15457         (mode_wider): Likewise.
15458         (mode_2xwider): Likewise.
15459         (machine_mode): New class.
15460         (mode_to_bytes): New function.
15461         (mode_to_bits): Likewise.
15462         (mode_to_precision): Likewise.
15463         (mode_to_inner): Likewise.
15464         (mode_to_unit_size): Likewise.
15465         (mode_to_unit_precision): Likewise.
15466         (mode_to_nunits): Likewise.
15467         (GET_MODE_SIZE): Use mode_to_bytes.
15468         (GET_MODE_BITSIZE): Use mode_to_bits.
15469         (GET_MODE_PRECISION): Use mode_to_precision.
15470         (GET_MODE_INNER): Use mode_to_inner.
15471         (GET_MODE_UNIT_SIZE): Use mode_to_unit_size.
15472         (GET_MODE_UNIT_PRECISION): Use mode_to_unit_precision.
15473         (GET_MODE_NUNITS): Use mode_to_nunits.
15474         * system.h (ALWAYS_INLINE): New macro.
15475         * config/powerpcspe/powerpcspe-c.c
15476         (altivec_resolve_overloaded_builtin): Use machine_mode instead of
15477         int for arg1_mode and arg2_mode.
15479 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
15480             Alan Hayward  <alan.hayward@arm.com>
15481             David Sherwood  <david.sherwood@arm.com>
15483         * config/aarch64/aarch64-builtins.c (aarch64_simd_builtin_std_type):
15484         Prefix mode names with E_ in case statements.
15485         * config/aarch64/aarch64-elf.h (ASM_OUTPUT_ADDR_DIFF_ELT): Likewise.
15486         * config/aarch64/aarch64.c (aarch64_split_simd_combine): Likewise.
15487         (aarch64_split_simd_move): Likewise.
15488         (aarch64_gen_storewb_pair): Likewise.
15489         (aarch64_gen_loadwb_pair): Likewise.
15490         (aarch64_gen_store_pair): Likewise.
15491         (aarch64_gen_load_pair): Likewise.
15492         (aarch64_get_condition_code_1): Likewise.
15493         (aarch64_constant_pool_reload_icode): Likewise.
15494         (get_rsqrte_type): Likewise.
15495         (get_rsqrts_type): Likewise.
15496         (get_recpe_type): Likewise.
15497         (get_recps_type): Likewise.
15498         (aarch64_gimplify_va_arg_expr): Likewise.
15499         (aarch64_simd_container_mode): Likewise.
15500         (aarch64_emit_load_exclusive): Likewise.
15501         (aarch64_emit_store_exclusive): Likewise.
15502         (aarch64_expand_compare_and_swap): Likewise.
15503         (aarch64_gen_atomic_cas): Likewise.
15504         (aarch64_emit_bic): Likewise.
15505         (aarch64_emit_atomic_swap): Likewise.
15506         (aarch64_emit_atomic_load_op): Likewise.
15507         (aarch64_evpc_trn): Likewise.
15508         (aarch64_evpc_uzp): Likewise.
15509         (aarch64_evpc_zip): Likewise.
15510         (aarch64_evpc_ext): Likewise.
15511         (aarch64_evpc_rev): Likewise.
15512         (aarch64_evpc_dup): Likewise.
15513         (aarch64_gen_ccmp_first): Likewise.
15514         (aarch64_gen_ccmp_next): Likewise.
15515         * config/alpha/alpha.c (alpha_scalar_mode_supported_p): Likewise.
15516         (alpha_emit_xfloating_libcall): Likewise.
15517         (emit_insxl): Likewise.
15518         (alpha_arg_type): Likewise.
15519         * config/arc/arc.c (arc_vector_mode_supported_p): Likewise.
15520         (arc_preferred_simd_mode): Likewise.
15521         (arc_secondary_reload): Likewise.
15522         (get_arc_condition_code): Likewise.
15523         (arc_print_operand): Likewise.
15524         (arc_legitimate_constant_p): Likewise.
15525         * config/arc/arc.h (ASM_OUTPUT_ADDR_DIFF_ELT): Likewise.
15526         * config/arc/arc.md (casesi_load): Likewise.
15527         (casesi_compact_jump): Likewise.
15528         * config/arc/predicates.md (proper_comparison_operator): Likewise.
15529         (cc_use_register): Likewise.
15530         * config/arm/aout.h (ASM_OUTPUT_ADDR_DIFF_ELT): Likewise.
15531         * config/arm/arm-builtins.c (arm_simd_builtin_std_type): Likewise.
15532         (arm_init_iwmmxt_builtins): Likewise.
15533         * config/arm/arm.c (thumb1_size_rtx_costs): Likewise.
15534         (neon_expand_vector_init): Likewise.
15535         (arm_attr_length_move_neon): Likewise.
15536         (maybe_get_arm_condition_code): Likewise.
15537         (arm_emit_vector_const): Likewise.
15538         (arm_preferred_simd_mode): Likewise.
15539         (arm_output_iwmmxt_tinsr): Likewise.
15540         (thumb1_output_casesi): Likewise.
15541         (thumb2_output_casesi): Likewise.
15542         (arm_emit_load_exclusive): Likewise.
15543         (arm_emit_store_exclusive): Likewise.
15544         (arm_expand_compare_and_swap): Likewise.
15545         (arm_evpc_neon_vuzp): Likewise.
15546         (arm_evpc_neon_vzip): Likewise.
15547         (arm_evpc_neon_vrev): Likewise.
15548         (arm_evpc_neon_vtrn): Likewise.
15549         (arm_evpc_neon_vext): Likewise.
15550         (arm_validize_comparison): Likewise.
15551         * config/arm/neon.md (neon_vc<cmp_op><mode>): Likewise.
15552         * config/avr/avr-c.c (avr_resolve_overloaded_builtin): Likewise.
15553         * config/avr/avr.c (avr_rtx_costs_1): Likewise.
15554         * config/c6x/c6x.c (c6x_vector_mode_supported_p): Likewise.
15555         (c6x_preferred_simd_mode): Likewise.
15556         * config/epiphany/epiphany.c (get_epiphany_condition_code): Likewise.
15557         (epiphany_rtx_costs): Likewise.
15558         * config/epiphany/predicates.md (proper_comparison_operator):
15559         Likewise.
15560         * config/frv/frv.c (condexec_memory_operand): Likewise.
15561         (frv_emit_move): Likewise.
15562         (output_move_single): Likewise.
15563         (output_condmove_single): Likewise.
15564         (frv_hard_regno_mode_ok): Likewise.
15565         (frv_matching_accg_mode): Likewise.
15566         * config/h8300/h8300.c (split_adds_subs): Likewise.
15567         (h8300_rtx_costs): Likewise.
15568         (h8300_print_operand): Likewise.
15569         (compute_mov_length): Likewise.
15570         (output_logical_op): Likewise.
15571         (compute_logical_op_length): Likewise.
15572         (compute_logical_op_cc): Likewise.
15573         (h8300_shift_needs_scratch_p): Likewise.
15574         (output_a_shift): Likewise.
15575         (compute_a_shift_length): Likewise.
15576         (compute_a_shift_cc): Likewise.
15577         (expand_a_rotate): Likewise.
15578         (output_a_rotate): Likewise.
15579         * config/i386/i386.c (classify_argument): Likewise.
15580         (function_arg_advance_32): Likewise.
15581         (function_arg_32): Likewise.
15582         (function_arg_64): Likewise.
15583         (function_value_64): Likewise.
15584         (ix86_gimplify_va_arg): Likewise.
15585         (ix86_legitimate_constant_p): Likewise.
15586         (put_condition_code): Likewise.
15587         (split_double_mode): Likewise.
15588         (ix86_avx256_split_vector_move_misalign): Likewise.
15589         (ix86_expand_vector_logical_operator): Likewise.
15590         (ix86_split_idivmod): Likewise.
15591         (ix86_expand_adjust_ufix_to_sfix_si): Likewise.
15592         (ix86_build_const_vector): Likewise.
15593         (ix86_build_signbit_mask): Likewise.
15594         (ix86_match_ccmode): Likewise.
15595         (ix86_cc_modes_compatible): Likewise.
15596         (ix86_expand_branch): Likewise.
15597         (ix86_expand_sse_cmp): Likewise.
15598         (ix86_expand_sse_movcc): Likewise.
15599         (ix86_expand_int_sse_cmp): Likewise.
15600         (ix86_expand_vec_perm_vpermi2): Likewise.
15601         (ix86_expand_vec_perm): Likewise.
15602         (ix86_expand_sse_unpack): Likewise.
15603         (ix86_expand_int_addcc): Likewise.
15604         (ix86_split_to_parts): Likewise.
15605         (ix86_vectorize_builtin_gather): Likewise.
15606         (ix86_vectorize_builtin_scatter): Likewise.
15607         (avx_vpermilp_parallel): Likewise.
15608         (inline_memory_move_cost): Likewise.
15609         (ix86_tieable_integer_mode_p): Likewise.
15610         (x86_maybe_negate_const_int): Likewise.
15611         (ix86_expand_vector_init_duplicate): Likewise.
15612         (ix86_expand_vector_init_one_nonzero): Likewise.
15613         (ix86_expand_vector_init_one_var): Likewise.
15614         (ix86_expand_vector_init_concat): Likewise.
15615         (ix86_expand_vector_init_interleave): Likewise.
15616         (ix86_expand_vector_init_general): Likewise.
15617         (ix86_expand_vector_set): Likewise.
15618         (ix86_expand_vector_extract): Likewise.
15619         (emit_reduc_half): Likewise.
15620         (ix86_emit_i387_round): Likewise.
15621         (ix86_mangle_type): Likewise.
15622         (ix86_expand_round_sse4): Likewise.
15623         (expand_vec_perm_blend): Likewise.
15624         (canonicalize_vector_int_perm): Likewise.
15625         (ix86_expand_vec_one_operand_perm_avx512): Likewise.
15626         (expand_vec_perm_1): Likewise.
15627         (expand_vec_perm_interleave3): Likewise.
15628         (expand_vec_perm_even_odd_pack): Likewise.
15629         (expand_vec_perm_even_odd_1): Likewise.
15630         (expand_vec_perm_broadcast_1): Likewise.
15631         (ix86_vectorize_vec_perm_const_ok): Likewise.
15632         (ix86_expand_vecop_qihi): Likewise.
15633         (ix86_expand_mul_widen_hilo): Likewise.
15634         (ix86_expand_sse2_abs): Likewise.
15635         (ix86_expand_pextr): Likewise.
15636         (ix86_expand_pinsr): Likewise.
15637         (ix86_preferred_simd_mode): Likewise.
15638         (ix86_simd_clone_compute_vecsize_and_simdlen): Likewise.
15639         * config/i386/sse.md (*andnot<mode>3): Likewise.
15640         (<mask_codefor><code><mode>3<mask_name>): Likewise.
15641         (*<code><mode>3): Likewise.
15642         * config/ia64/ia64.c (ia64_expand_vecint_compare): Likewise.
15643         (ia64_expand_atomic_op): Likewise.
15644         (ia64_arg_type): Likewise.
15645         (ia64_mode_to_int): Likewise.
15646         (ia64_scalar_mode_supported_p): Likewise.
15647         (ia64_vector_mode_supported_p): Likewise.
15648         (expand_vec_perm_broadcast): Likewise.
15649         * config/iq2000/iq2000.c (iq2000_move_1word): Likewise.
15650         (iq2000_function_arg_advance): Likewise.
15651         (iq2000_function_arg): Likewise.
15652         * config/m32c/m32c.c (m32c_preferred_reload_class): Likewise.
15653         * config/m68k/m68k.c (output_dbcc_and_branch): Likewise.
15654         (m68k_libcall_value): Likewise.
15655         (m68k_function_value): Likewise.
15656         (sched_attr_op_type): Likewise.
15657         * config/mcore/mcore.c (mcore_output_move): Likewise.
15658         * config/microblaze/microblaze.c (microblaze_function_arg_advance):
15659         Likewise.
15660         (microblaze_function_arg): Likewise.
15661         * config/mips/mips.c (mips16_build_call_stub): Likewise.
15662         (mips_print_operand): Likewise.
15663         (mips_mode_ok_for_mov_fmt_p): Likewise.
15664         (mips_vector_mode_supported_p): Likewise.
15665         (mips_preferred_simd_mode): Likewise.
15666         (mips_expand_vpc_loongson_even_odd): Likewise.
15667         (mips_expand_vec_unpack): Likewise.
15668         (mips_expand_vi_broadcast): Likewise.
15669         (mips_expand_vector_init): Likewise.
15670         (mips_expand_vec_reduc): Likewise.
15671         (mips_expand_msa_cmp): Likewise.
15672         * config/mips/mips.md (casesi_internal_mips16_<mode>): Likewise.
15673         * config/mn10300/mn10300.c (mn10300_print_operand): Likewise.
15674         (cc_flags_for_mode): Likewise.
15675         * config/msp430/msp430.c (msp430_print_operand): Likewise.
15676         * config/nds32/nds32-md-auxiliary.c (nds32_mem_format): Likewise.
15677         (nds32_output_casesi_pc_relative): Likewise.
15678         * config/nds32/nds32.h (ASM_OUTPUT_ADDR_DIFF_ELT): Likewise.
15679         * config/nvptx/nvptx.c (nvptx_ptx_type_from_mode): Likewise.
15680         (nvptx_gen_unpack): Likewise.
15681         (nvptx_gen_pack): Likewise.
15682         (nvptx_gen_shuffle): Likewise.
15683         (nvptx_gen_wcast): Likewise.
15684         (nvptx_preferred_simd_mode): Likewise.
15685         * config/pa/pa.c (pa_secondary_reload): Likewise.
15686         * config/pa/predicates.md (base14_operand): Likewise.
15687         * config/powerpcspe/powerpcspe-c.c
15688         (altivec_resolve_overloaded_builtin): Likewise.
15689         * config/powerpcspe/powerpcspe.c (rs6000_setup_reg_addr_masks):
15690         Likewise.
15691         (rs6000_preferred_simd_mode): Likewise.
15692         (output_vec_const_move): Likewise.
15693         (rs6000_expand_vector_extract): Likewise.
15694         (rs6000_split_vec_extract_var): Likewise.
15695         (reg_offset_addressing_ok_p): Likewise.
15696         (rs6000_legitimate_offset_address_p): Likewise.
15697         (rs6000_legitimize_address): Likewise.
15698         (rs6000_emit_set_const): Likewise.
15699         (rs6000_const_vec): Likewise.
15700         (rs6000_emit_move): Likewise.
15701         (spe_build_register_parallel): Likewise.
15702         (rs6000_darwin64_record_arg_recurse): Likewise.
15703         (swap_selector_for_mode): Likewise.
15704         (spe_init_builtins): Likewise.
15705         (paired_init_builtins): Likewise.
15706         (altivec_init_builtins): Likewise.
15707         (do_load_for_compare): Likewise.
15708         (rs6000_generate_compare): Likewise.
15709         (rs6000_expand_float128_convert): Likewise.
15710         (emit_load_locked): Likewise.
15711         (emit_store_conditional): Likewise.
15712         (rs6000_output_function_epilogue): Likewise.
15713         (rs6000_handle_altivec_attribute): Likewise.
15714         (rs6000_function_value): Likewise.
15715         (emit_fusion_gpr_load): Likewise.
15716         (emit_fusion_p9_load): Likewise.
15717         (emit_fusion_p9_store): Likewise.
15718         * config/powerpcspe/predicates.md (easy_fp_constant): Likewise.
15719         (fusion_gpr_mem_load): Likewise.
15720         (fusion_addis_mem_combo_load): Likewise.
15721         (fusion_addis_mem_combo_store): Likewise.
15722         * config/rs6000/predicates.md (easy_fp_constant): Likewise.
15723         (fusion_gpr_mem_load): Likewise.
15724         (fusion_addis_mem_combo_load): Likewise.
15725         (fusion_addis_mem_combo_store): Likewise.
15726         * config/rs6000/rs6000-c.c (altivec_resolve_overloaded_builtin):
15727         Likewise.
15728         * config/rs6000/rs6000-string.c (do_load_for_compare): Likewise.
15729         * config/rs6000/rs6000.c (rs6000_setup_reg_addr_masks): Likewise.
15730         (rs6000_preferred_simd_mode): Likewise.
15731         (output_vec_const_move): Likewise.
15732         (rs6000_expand_vector_extract): Likewise.
15733         (rs6000_split_vec_extract_var): Likewise.
15734         (reg_offset_addressing_ok_p): Likewise.
15735         (rs6000_legitimate_offset_address_p): Likewise.
15736         (rs6000_legitimize_address): Likewise.
15737         (rs6000_emit_set_const): Likewise.
15738         (rs6000_const_vec): Likewise.
15739         (rs6000_emit_move): Likewise.
15740         (rs6000_darwin64_record_arg_recurse): Likewise.
15741         (swap_selector_for_mode): Likewise.
15742         (paired_init_builtins): Likewise.
15743         (altivec_init_builtins): Likewise.
15744         (rs6000_expand_float128_convert): Likewise.
15745         (emit_load_locked): Likewise.
15746         (emit_store_conditional): Likewise.
15747         (rs6000_output_function_epilogue): Likewise.
15748         (rs6000_handle_altivec_attribute): Likewise.
15749         (rs6000_function_value): Likewise.
15750         (emit_fusion_gpr_load): Likewise.
15751         (emit_fusion_p9_load): Likewise.
15752         (emit_fusion_p9_store): Likewise.
15753         * config/rx/rx.c (rx_gen_move_template): Likewise.
15754         (flags_from_mode): Likewise.
15755         * config/s390/predicates.md (s390_alc_comparison): Likewise.
15756         (s390_slb_comparison): Likewise.
15757         * config/s390/s390.c (s390_handle_vectorbool_attribute): Likewise.
15758         (s390_vector_mode_supported_p): Likewise.
15759         (s390_cc_modes_compatible): Likewise.
15760         (s390_match_ccmode_set): Likewise.
15761         (s390_canonicalize_comparison): Likewise.
15762         (s390_emit_compare_and_swap): Likewise.
15763         (s390_branch_condition_mask): Likewise.
15764         (s390_rtx_costs): Likewise.
15765         (s390_secondary_reload): Likewise.
15766         (__SECONDARY_RELOAD_CASE): Likewise.
15767         (s390_expand_cs): Likewise.
15768         (s390_preferred_simd_mode): Likewise.
15769         * config/s390/vx-builtins.md (vec_packsu_u<mode>): Likewise.
15770         * config/sh/sh.c (sh_print_operand): Likewise.
15771         (dump_table): Likewise.
15772         (sh_secondary_reload): Likewise.
15773         * config/sh/sh.h (ASM_OUTPUT_ADDR_DIFF_ELT): Likewise.
15774         * config/sh/sh.md (casesi_worker_1): Likewise.
15775         (casesi_worker_2): Likewise.
15776         * config/sparc/predicates.md (icc_comparison_operator): Likewise.
15777         (fcc_comparison_operator): Likewise.
15778         * config/sparc/sparc.c (sparc_expand_move): Likewise.
15779         (emit_soft_tfmode_cvt): Likewise.
15780         (sparc_preferred_simd_mode): Likewise.
15781         (output_cbranch): Likewise.
15782         (sparc_print_operand): Likewise.
15783         (sparc_expand_vec_perm_bmask): Likewise.
15784         (vector_init_bshuffle): Likewise.
15785         * config/spu/spu.c (spu_scalar_mode_supported_p): Likewise.
15786         (spu_vector_mode_supported_p): Likewise.
15787         (spu_expand_insv): Likewise.
15788         (spu_emit_branch_or_set): Likewise.
15789         (spu_handle_vector_attribute): Likewise.
15790         (spu_builtin_splats): Likewise.
15791         (spu_builtin_extract): Likewise.
15792         (spu_builtin_promote): Likewise.
15793         (spu_expand_sign_extend): Likewise.
15794         * config/tilegx/tilegx.c (tilegx_scalar_mode_supported_p): Likewise.
15795         (tilegx_simd_int): Likewise.
15796         * config/tilepro/tilepro.c (tilepro_scalar_mode_supported_p): Likewise.
15797         (tilepro_simd_int): Likewise.
15798         * config/v850/v850.c (const_double_split): Likewise.
15799         (v850_print_operand): Likewise.
15800         (ep_memory_offset): Likewise.
15801         * config/vax/vax.c (vax_rtx_costs): Likewise.
15802         (vax_output_int_move): Likewise.
15803         (vax_output_int_add): Likewise.
15804         (vax_output_int_subtract): Likewise.
15805         * config/visium/predicates.md (visium_branch_operator): Likewise.
15806         * config/visium/visium.c (rtx_ok_for_offset_p): Likewise.
15807         (visium_print_operand_address): Likewise.
15808         * config/visium/visium.h (ASM_OUTPUT_ADDR_DIFF_ELT): Likewise.
15809         * config/xtensa/xtensa.c (xtensa_mem_offset): Likewise.
15810         (xtensa_expand_conditional_branch): Likewise.
15811         (xtensa_copy_incoming_a7): Likewise.
15812         (xtensa_output_literal): Likewise.
15813         * dfp.c (decimal_real_maxval): Likewise.
15814         * targhooks.c (default_libgcc_floating_mode_supported_p): Likewise.
15816 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
15817             Alan Hayward  <alan.hayward@arm.com>
15818             David Sherwood  <david.sherwood@arm.com>
15820         * genmodes.c (mode_size_inline): Add an E_ prefix to mode names.
15821         (mode_nunits_inline): Likewise.
15822         (mode_inner_inline): Likewise.
15823         (mode_unit_size_inline): Likewise.
15824         (mode_unit_precision_inline): Likewise.
15825         (emit_insn_modes_h): Likewise.  Also emit a #define of the
15826         unprefixed name.
15827         (emit_mode_wider): Add an E_ prefix to mode names.
15828         (emit_mode_complex): Likewise.
15829         (emit_mode_inner): Likewise.
15830         (emit_mode_adjustments): Likewise.
15831         (emit_mode_int_n): Likewise.
15832         * config/aarch64/aarch64-builtins.c (v8qi_UP, v4hi_UP, v4hf_UP)
15833         (v2si_UP, v2sf_UP, v1df_UP, di_UP, df_UP, v16qi_UP, v8hi_UP, v8hf_UP)
15834         (v4si_UP, v4sf_UP, v2di_UP, v2df_UP, ti_UP, oi_UP, ci_UP, xi_UP)
15835         (si_UP, sf_UP, hi_UP, hf_UP, qi_UP): Likewise.
15836         (CRC32_BUILTIN, ENTRY): Likewise.
15837         * config/aarch64/aarch64.c (aarch64_push_regs): Likewise.
15838         (aarch64_pop_regs): Likewise.
15839         (aarch64_process_components): Likewise.
15840         * config/alpha/alpha.c (alpha_emit_conditional_move): Likewise.
15841         * config/arm/arm-builtins.c (v8qi_UP, v4hi_UP, v4hf_UP, v2si_UP)
15842         (v2sf_UP, di_UP, v16qi_UP, v8hi_UP, v8hf_UP, v4si_UP, v4sf_UP)
15843         (v2di_UP, ti_UP, ei_UP, oi_UP, hf_UP, si_UP, void_UP): Likewise.
15844         * config/arm/arm.c (arm_init_libfuncs): Likewise.
15845         * config/i386/i386-builtin-types.awk (ix86_builtin_type_vect_mode):
15846         Likewise.
15847         * config/i386/i386-builtin.def (pcmpestr): Likewise.
15848         (pcmpistr): Likewise.
15849         * config/microblaze/microblaze.c (double_memory_operand): Likewise.
15850         * config/mmix/mmix.c (mmix_output_condition): Likewise.
15851         * config/powerpcspe/powerpcspe.c (rs6000_init_hard_regno_mode_ok):
15852         Likewise.
15853         * config/rl78/rl78.c (mduc_regs): Likewise.
15854         * config/rs6000/rs6000.c (rs6000_init_hard_regno_mode_ok): Likewise.
15855         (htm_expand_builtin): Likewise.
15856         * config/sh/sh.h (REGISTER_NATURAL_MODE): Likewise.
15857         * config/sparc/sparc.c (emit_save_or_restore_regs): Likewise.
15858         * config/xtensa/xtensa.c (print_operand): Likewise.
15859         * expmed.h (NUM_MODE_PARTIAL_INT): Likewise.
15860         (NUM_MODE_VECTOR_INT): Likewise.
15861         * genoutput.c (null_operand): Likewise.
15862         (output_operand_data): Likewise.
15863         * genrecog.c (print_parameter_value): Likewise.
15864         * lra.c (debug_operand_data): Likewise.
15866 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
15868         * dwarf2out.c (scompare_loc_descriptor_wide)
15869         (scompare_loc_descriptor_narrow): New functions, split out from...
15870         (scompare_loc_descriptor): ...here.
15871         * expmed.c (emit_store_flag_int): New function, split out from...
15872         (emit_store_flag): ...here.
15874 2017-08-30  Richard Biener  <rguenther@suse.de>
15876         * dwarf2out.c (dwarf2out_finish): Remove setting AT_pubnames.
15877         (dwarf2out_early_finish): Move setting of AT_pubnames from
15878         early debug output to early finish.
15880 2017-08-30  Jozef Lawrynowicz  <jozef.l@somniumtech.com>
15882         * gcc/config/msp430/msp430.h: Pass -mcode/data-region to the linker
15883         and -mdata-region to the assembler.
15885 2017-08-30  Richard Biener  <rguenther@suse.de>
15887         * dwarf2out.c (add_dwarf_attr): Check we don't add duplicate
15888         attributes.
15889         (gen_subprogram_die): Add DW_AT_object_pointer only early.
15890         (dwarf2out_early_global_decl): Only generate a DIE for the
15891         abstract origin if it doesn't already exist or is a declaration DIE.
15892         (resolve_addr): Do not add the linkage name twice when
15893         generating a stub DIE for the DW_TAG_GNU_call_site target.
15895 2017-08-30  Richard Sandiford  <richard.sandiford@linaro.org>
15897         * config/rs6000/rs6000-c.c (altivec_resolve_overloaded_builtin):
15898         Use machine_mode rather than int for arg1_mode.
15900 2017-08-29  Michael Meissner  <meissner@linux.vnet.ibm.com>
15902         PR target/82015
15903         * config/rs6000/rs6000.c (rs6000_expand_binop_builtin): Insure
15904         that the second argument of the built-in functions to unpack
15905         128-bit scalar types to 64-bit values is 0 or 1.  Change to use a
15906         switch statement instead a lot of if statements.
15907         * config/rs6000/rs6000.md (unpack<mode>, FMOVE128_VSX iterator):
15908         Allow 64-bit values to be in Altivec registers as well as
15909         traditional floating point registers.
15910         (pack<mode>, FMOVE128_VSX iterator): Likewise.
15912 2017-08-29  Alexander Monakov  <amonakov@ispras.ru>
15914         * ira-costs.c (record_address_regs): Handle both operands of PLUS for
15915         MAX_REGS_PER_ADDRESS == 1.
15917 2017-08-29  Uros Bizjak  <ubizjak@gmail.com>
15919         * config/i386/i386.opt (flag_fentry): Do not init to -1.
15920         * config/i386/i386.c (ix86_option_override_internal): Simplify
15921         setting of opts->x_flag_entry.
15923 2017-08-29  Bill Schmidt  <wschmidt@linux.vnet.ibm.com>
15924             Jakub Jelinek  <jakub@redhat.com>
15925             Richard Biener  <rguenther@suse.de>
15927         PR tree-optimization/81503
15928         * gimple-ssa-strength-reduction.c (replace_mult_candidate): Ensure
15929         folded constant fits in the target type; reorder tests for clarity.
15931 2017-08-29  Martin Liska  <mliska@suse.cz>
15933         * passes.def: Include pass_lower_switch.
15934         * stmt.c (dump_case_nodes): Remove and move to
15935         tree-switch-conversion.
15936         (case_values_threshold): Likewise.
15937         (expand_switch_as_decision_tree_p): Likewise.
15938         (emit_case_decision_tree): Likewise.
15939         (expand_case): Likewise.
15940         (balance_case_nodes): Likewise.
15941         (node_has_low_bound): Likewise.
15942         (node_has_high_bound): Likewise.
15943         (node_is_bounded): Likewise.
15944         (emit_case_nodes): Likewise.
15945         (struct simple_case_node): New struct.
15946         (add_case_node): Remove.
15947         (emit_case_dispatch_table): Use vector instead of case_list.
15948         (reset_out_edges_aux): Remove.
15949         (compute_cases_per_edge): Likewise.
15950         (expand_case): Build list of simple_case_node.
15951         (expand_sjlj_dispatch_table): Use it.
15952         * tree-switch-conversion.c (struct case_node): Moved from
15953         stmt.c and adjusted.
15954         (emit_case_nodes): Likewise.
15955         (node_has_low_bound): Likewise.
15956         (node_has_high_bound): Likewise.
15957         (node_is_bounded): Likewise.
15958         (case_values_threshold): Likewise.
15959         (reset_out_edges_aux): Likewise.
15960         (compute_cases_per_edge): Likewise.
15961         (add_case_node): Likewise.
15962         (dump_case_nodes): Likewise.
15963         (balance_case_nodes): Likewise.
15964         (expand_switch_as_decision_tree_p): Likewise.
15965         (emit_jump): Likewise.
15966         (emit_case_decision_tree): Likewise.
15967         (try_switch_expansion): Likewise.
15968         (do_jump_if_equal): Likewise.
15969         (emit_cmp_and_jump_insns): Likewise.
15970         (fix_phi_operands_for_edge): New function.
15971         (record_phi_operand_mapping): Likewise.
15972         (class pass_lower_switch): New pass.
15973         (pass_lower_switch::execute): New function.
15974         (make_pass_lower_switch): Likewise.
15975         (conditional_probability):
15976         * timevar.def: Add TV_TREE_SWITCH_LOWERING.
15977         * tree-pass.h: Add make_pass_lower_switch.
15979 2017-08-29  Jozef Lawrynowicz  <jozef.l@somniumtech.com>
15981         PR target/80993
15982         * gcc/config/msp430/msp430.c (msp430_attr): Mark interrupt
15983         handlers as used.
15985 2017-08-29  Richard Biener  <rguenther@suse.de>
15987         * dwarf2out.c (add_dwarf_attr): When checking is enabled verify
15988         we do not add a DW_AT_inline attribute twice.
15989         (gen_subprogram_die): Remove code setting DW_AT_inline on
15990         DECL_ABSTRACT_P nodes.
15992 2017-08-29  Richard Sandiford  <richard.sandiford@linaro.org>
15994         * gimplify.c (gimplify_call_expr): Copy the nothrow flag to
15995         calls to internal functions.
15996         (gimplify_modify_expr): Likewise.
15997         * tree-call-cdce.c (use_internal_fn): Likewise.
15998         * tree-ssa-math-opts.c (pass_cse_reciprocals::execute): Likewise.
15999         (convert_to_divmod): Set the nothrow flag.
16000         * tree-if-conv.c (predicate_mem_writes):  Likewise.
16001         * tree-vect-stmts.c (vectorizable_mask_load_store): Likewise.
16002         (vectorizable_call): Likewise.
16003         (vectorizable_store): Likewise.
16004         (vectorizable_load): Likewise.
16005         * tree-vect-patterns.c (vect_recog_pow_pattern): Likewise.
16006         (vect_recog_mask_conversion_pattern): Likewise.
16008 2017-08-29  Martin Liska  <mliska@suse.cz>
16010         PR other/39851
16011         * gcc.c (driver_handle_option): Add new argument.
16012         * opts-common.c (handle_option): Pass
16013         target_option_override_hook.
16014         * opts-global.c (lang_handle_option): Add new option.
16015         (set_default_handlers):  Add new argument.
16016         (decode_options): Likewise.
16017         * opts.c (target_handle_option): Likewise.
16018         (common_handle_option): Call target_option_override_hook.
16019         * opts.h (struct cl_option_handler_func): Add hook for
16020         target option override.
16021         (struct cl_option_handlers): Likewise.
16022         (set_default_handlers): Add new argument.
16023         (decode_options): Likewise.
16024         (common_handle_option): Likewise.
16025         (target_handle_option): Likewise.
16026         * toplev.c (toplev::main): Pass targetm.target_option.override
16027         hook.
16029 2017-08-29  Richard Biener  <rguenther@suse.de>
16030         Dominik Infuehr <dominik.infuehr@theobroma-systems.com>
16032         * tree-vect-slp.c (vect_bb_slp_scalar_cost): Properly confine
16033         life to the active subtree.
16035 2017-08-28  Jeff Law  <law@redhat.com>
16037         * tree-ssa-dom.c (edge_info::record_simple_equiv): Call
16038         derive_equivalences.
16039         (derive_equivalences_from_bit_ior, record_temporary_equivalences):
16040         Code moved into....
16041         (edge_info::derive_equivalences): New private member function
16043         * tree-ssa-dom.c (class edge_info): Changed from a struct
16044         to a class.  Add ctor/dtor, methods and data members.
16045         (edge_info::edge_info): Renamed from allocate_edge_info.
16046         Initialize additional members.
16047         (edge_info::~edge_info): New.
16048         (free_dom_edge_info): Delete the edge info.
16049         (record_edge_info): Use new class & associated member functions.
16050         Tighten forms for testing for edge equivalences.
16051         (record_temporary_equivalences): Iterate over the simple
16052         equivalences rather than assuming there's only one per edge.
16053         (cprop_into_successor_phis): Iterate over the simple
16054         equivalences rather than assuming there's only one per edge.
16055         (optimize_stmt): Use operand_equal_p rather than pointer
16056         equality for mini-DSE code.
16058 2017-08-28  Nathan Sidwell  <nathan@acm.org>
16060         * gcc.c (execute): Fold SIGPIPE handling into switch
16061         statement.  Adjust internal error message.
16063 2017-08-28  Richard Biener  <rguenther@suse.de>
16065         PR debug/81993
16066         * dwarf2out.c (gen_remaining_tmpl_value_param_die_attributes):
16067         Do nothing for removed DIEs.
16069 2017-08-28  Richard Biener  <rguenther@suse.de>
16071         PR tree-optimization/81977
16072         * tree-ssa-sccvn.c (vn_reference_lookup_3): Fix look through
16073         memcpy.
16075 2017-08-28  Alexander Monakov  <amonakov@ispras.ru>
16077         PR target/80640
16078         * doc/md.texi (mem_thread_fence): Remove mention of mode.  Rewrite.
16079         * optabs.c (expand_mem_thread_fence): Emit a compiler barrier when
16080         using targetm.gen_mem_thread_fence.
16082 2017-08-27  Uros Bizjak  <ubizjak@gmail.com>
16084         PR target/81995
16085         * config/i386/i386.md (*<btsc><mode>): Change operand 2
16086         predicate to register_operand.  Reorder operands.
16087         (*btr<mode>): Ditto.
16088         (*<btsc><mode>_mask): Change operand 3 predicate to register_operand.
16089         (*btr<mode>_mask): Ditto.
16091 2017-08-25  Steven Munroe  <munroesj@gcc.gnu.org>
16093         * config.gcc (powerpc*-*-*): Add xmmintrin.h and mm_malloc.h.
16094         * config/rs6000/xmmintrin.h: New file.
16095         * config/rs6000/x86intrin.h [__ALTIVEC__]: Include xmmintrin.h.
16097 2017-08-25  Bill Schmidt  <wschmidt@linux.vnet.ibm.com>
16099         PR target/81504
16100         * config/rs6000/rs6000-p8swap.c (find_alignment_op): Add reference
16101         parameter and_insn and return it.
16102         (recombine_lvx_pattern): Insert a copy to ensure availability of
16103         the base register of the copied masking operation at the point of
16104         the instruction replacement.
16105         (recombine_stvx_pattern): Likewise.
16107 2017-08-25  Michael Meissner  <meissner@linux.vnet.ibm.com>
16109         * config/rs6000/rs6000.opt (-mpower9-dform-scalar): Delete
16110         undocumented switches.
16111         (-mpower9-dform-vector): Likewise.
16112         (-mpower9-dform): Likewise.
16113         * config/rs6000/rs6000-c.c (rs6000_target_modify_macros): Update
16114         comments to delete references to -mpower9-dform* switches.
16115         * config/rs6000/predicates.md (vsx_quad_dform_memory_operand):
16116         Delete reference to -mpower9-dform* switches, test for
16117         -mpower9-vector instead.
16118         * config/rs6000/rs6000-cpus.def (ISA_3_0_MASKS_SERVER): Likewise.
16119         (OTHER_P9_VECTOR_MASKS): Likewise.
16120         (POWERPC_MASKS): Likewise.
16121         * config/rs6000/rs6000.c (rs6000_setup_reg_addr_masks): Change
16122         tests against -mpower9-dform* to -mpower9-vector.  Delete code
16123         that checked for -mpower9-dform* consistancy with other options.
16124         Add test for -mpower9-misc to enable other power9 switches.
16125         (rs6000_init_hard_regno_mode_ok): Likewise.
16126         (rs6000_option_override_internal): Likewise.
16127         (rs6000_emit_prologue): Likewise.
16128         (rs6000_emit_epilogue): Likewise.
16129         (rs6000_opt_masks): Delete -mpower9-dform-{scalar,vector}.
16130         (rs6000_disable_incompatiable_switches): Delete -mpower9-dform.
16131         (emit_fusion_p9_load): Change tests for -mpower9-dform-scalar
16132         -mpower9-vector.
16133         (emit_fusion_p9_store): Likewise.
16134         * config/rs6000/rs6000.h (TARGET_P9_DFORM_SCALAR): Delete
16135         resetting these macros if the assembler does not support ISA 3.0
16136         instructions.
16137         (TARGET_P9_DFORM_VECTOR): Likewise.
16138         * config/rs6000/rs6000.md (peepholes to optimize altivec memory):
16139         Change to use -mpower9-vector instead of -mpower9-dform-scalar.
16141 2017-08-25  Alan Modra  <amodra@gmail.com>
16143         PR rtl-optimization/81747
16144         * cse.c (cse_extended_basic_block): Don't attempt to record
16145         equivalences for degenerate conditional branches that branch
16146         to their fall-through.
16148 2017-08-24  Martin Sebor  <msebor@redhat.com>
16150         PR middle-end/81908
16151         * gimple-fold.c (size_must_be_zero_p): New function.
16152         (gimple_fold_builtin_memory_op): Call it.
16154 2017-08-24  Steven Munroe  <munroesj@gcc.gnu.org>
16156         * config/rs6000/mm_malloc.h: New file.
16158 2017-08-24  Bin Cheng  <bin.cheng@arm.com>
16160         PR tree-optimization/81913
16161         * tree-ssa-loop-niter.c (number_of_iterations_cond): Skip niter
16162         analysis when either IVs in condition can wrap.
16164 2017-08-24  Uros Bizjak  <ubizjak@gmail.com>
16166         * dwarf2out.c (MAX_ARTIFICIAL_LABEL_BYTES): Increase to 40.
16167         * dwarf2cfi.c (MAX_ARTIFICIAL_LABEL_BYTES): Remove.
16169 2017-08-24  Richard Biener  <rguenther@suse.de>
16171         PR target/81921
16172         * targhooks.c (default_target_can_inline_p): Properly
16173         use target_option_default_node when no DECL_FUNCTION_SPECIFIC_TARGET
16174         is present and always compare.
16175         * config/i386/i386.c (ix86_valid_target_attribute_tree): Do not
16176         infer -mfpmath=sse from TARGET_SSE_P.
16177         (ix86_can_inline_p): Properly use target_option_default_node when
16178         no DECL_FUNCTION_SPECIFIC_TARGET is present and always compare.
16180 2017-08-24  Richard Biener  <rguenther@suse.de>
16182         PR debug/81936
16183         * dwarf2out.c (output_die): Handle flag_generate_offload like
16184         flag_generate_lto.
16185         (output_comp_unit): Likewise.
16186         (gen_array_type_die): Likewise.
16187         (dwarf2out_early_finish): Likewise.
16188         (note_variable_value_in_expr): Likewise.
16189         (dwarf2out_finish): Likewise.  Adjust assert.
16190         * cgraphunit.c (symbol_table::compile): Move setting of
16191         flag_generate_offload earlier ...
16192         (symbol_table::finalize_compilation_unit): ... here, before
16193         early debug finalization.
16195 2017-08-24  Richard Biener  <rguenther@suse.de>
16197         * config/i386/i386.c: Include symbol-summary.h, ipa-prop.h
16198         and ipa-fnsummary.h.
16199         (ix86_can_inline_p): When ix86_fpmath flags do not match
16200         check whether the callee uses FP math at all.
16202 2017-08-24  Aldy Hernandez  <aldyh@redhat.com>
16204         PR middle-end/81931
16205         * tree-ssanames.c (get_nonzero_bits): Use element_precision
16206         instead of TYPE_PRECISION.
16208 2017-08-24  Richard Sandiford  <richard.sandiford@linaro.org>
16209             Alan Hayward  <alan.hayward@arm.com>
16210             David Sherwood  <david.sherwood@arm.com>
16212         * combine.c (make_extraction): Use subreg_offset_from_lsb.
16214 2017-08-23  Daniel Santos  <daniel.santos@pobox.com>
16216         * config/i386/i386.h (ix86_frame::stack_realign_allocate_offset):
16217         Remove field.
16218         (ix86_frame::stack_realign_allocate): New field.
16219         (struct machine_frame_state): Modify comments.
16220         (machine_frame_state::sp_realigned_fp_end): New field.
16221         * config/i386/i386.c (ix86_compute_frame_layout): Rework stack frame
16222         layout calculation.
16223         (sp_valid_at): Add assertion to assure no attempt to access invalid
16224         offset of a realigned stack.
16225         (fp_valid_at): Likewise.
16226         (choose_baseaddr): Modify comments.
16227         (ix86_emit_outlined_ms2sysv_save): Adjust to changes in
16228         ix86_expand_prologue.
16229         (ix86_expand_prologue): Modify stack realignment and allocation.
16230         (ix86_expand_epilogue): Modify comments.
16231         * doc/sourcebuild.texi: Add documentation for target selectors avx2,
16232         avx2_runtime, avx512f, and avx512f_runtime.
16234 2017-08-23  Uros Bizjak  <ubizjak@gmail.com>
16236         * config/i386/i386.opt: Remove unneeded Init(0) initializations.
16237         (mstackrealign): Do not init to -1.
16238         * config/i386/i386.c (ix86_option_override_internal):
16239         Check opts_set, not opts when setting default value of
16240         opts->x_ix86_force_align_arg_pointer.
16242 2017-08-23  Richard Biener  <rguenther@suse.de>
16244         * function.c (fndecl_name): Use verbosity 1 (no arguments) for
16245         lang_hooks.decl_printable_name.
16246         * print-rtl-function.c (print_rtx_function): Likewise.
16247         * tree-pretty-print.c (dump_function_header): Likewise.
16249 2017-08-23  Richard Biener  <rguenther@suse.de>
16251         PR lto/81940
16252         * dwarf2out.c (dwarf2out_abstract_function): Handle LTO with
16253         -g0 at compile-time.
16255 2017-08-23  Tamar Christina  <tamar.christina@arm.com>
16257         PR middle-end/19706
16258         * doc/sourcebuild.texi (Other hardware attributes):
16259         Document xorsign.
16261 2017-08-23  Tamar Christina  <tamar.christina@arm.com>
16263         PR middle-end/19706
16264         * tree-ssa-math-opts.c (convert_expand_mult_copysign):
16265         Fix single-use check.
16267 2017-08-23  Thomas Preud'homme  <thomas.preudhomme@arm.com>
16269         * gcc.c (execute): Only test for SIGKILL and SIGQUIT if available.
16271 2017-08-22  Daniel Santos  <daniel.santos@pobox.com>
16273         * doc/install.texi: Modify to add more details on running selected
16274         tests.
16276 2017-08-22  Daniel Santos  <daniel.santos@pobox.com>
16278         * config/i386/i386.c (ix86_option_override_internal): Error when -mx32
16279         is combined with -mabi=ms.
16280         (ix86_function_type_abi): Limit errors for mixing -mx32 with attribute
16281         ms_abi.
16283 2017-08-22  Bill Schmidt  <wschmidt@linux.vnet.ibm.com>
16285         PR tree-optimization/81488
16286         * gimple-ssa-strength-reduction (struct slsr_cand_d): Add visited
16287         and cached_basis fields.
16288         (MAX_SPREAD): New constant.
16289         (alloc_cand_and_find_basis): Initialize new fields.
16290         (clear_visited): New function.
16291         (create_phi_basis_1): Rename from create_phi_basis, set visited
16292         and cached_basis fields.
16293         (create_phi_basis): New wrapper function.
16294         (phi_add_costs_1): Rename from phi_add_costs, add spread
16295         parameter, set visited field, short-circuit when limits reached.
16296         (phi_add_costs): New wrapper function.
16297         (record_phi_increments_1): Rename from record_phi_increments, set
16298         visited field.
16299         (record_phi_increments): New wrapper function.
16300         (phi_incr_cost_1): Rename from phi_incr_cost, set visited field.
16301         (phi_incr_cost): New wrapper function.
16302         (all_phi_incrs_profitable_1): Rename from
16303         all_phi_incrs_profitable, set visited field.
16304         (all_phi_incrs_profitable): New wrapper function.
16306 2017-08-22  Richard Sandiford  <richard.sandiford@linaro.org>
16307             Alan Hayward  <alan.hayward@arm.com>
16308             David Sherwood  <david.sherwood@arm.com>
16310         * rtl.h (paradoxical_subreg_p): Define inline, and add a version
16311         that takes the outer and inner modes.
16312         * doc/rtl.texi: Use paradoxical_subreg_p instead of a GET_MODE_SIZE
16313         comparison as the canonical test for a paradoxical subreg.
16314         * combine.c (simplify_set): Use paradoxical_subreg_p.
16315         (make_extraction): Likewise.
16316         (force_to_mode): Likewise.
16317         (rtx_equal_for_field_assignment_p): Likewise.
16318         (gen_lowpart_for_combine): Likewise.
16319         (simplify_comparison): Likewise.
16320         * cse.c (equiv_constant): Likewise.
16321         * expmed.c (store_bit_field_1): Likewise.
16322         * final.c (alter_subreg): Likewise.
16323         * fwprop.c (propagate_rtx): Likewise.
16324         (forward_propagate_subreg): Likewise.
16325         * ira-conflicts.c (ira_build_conflicts): Likewise.
16326         * lower-subreg.c (simplify_gen_subreg_concatn): Likewise.
16327         * lra-constraints.c (curr_insn_transform): Likewise.
16328         (split_reg): Likewise.
16329         * lra-eliminations.c (move_plus_up): Likewise.
16330         (lra_eliminate_regs_1): Likewise.
16331         * recog.c (general_operand): Likewise.
16332         * ree.c (combine_reaching_defs): Likewise.
16333         * reload.c (push_reload): Likewise.
16334         (find_reloads): Likewise.
16335         * reload1.c (elimination_effects): Likewise.
16336         (compute_reload_subreg_offset): Likewise.
16337         (choose_reload_regs): Likewise.
16338         * rtlanal.c (subreg_lsb_1): Likewise.
16339         * simplify-rtx.c (simplify_unary_operation_1): Likewise.
16340         (simplify_subreg): Likewise.
16341         * var-tracking.c (track_loc_p): Likewise.
16342         * emit-rtl.c (byte_lowpart_offset): Likewise.
16343         (paradoxical_subreg_p): Delete out-of-line definition.
16345 2017-08-22  Jeff Law  <law@redhat.com>
16347         PR tree-optimization/81741
16348         PR tree-optimization/71947
16349         * tree-ssa-dom.c: Include tree-inline.h.
16350         (record_temporary_equivalences): Only record SSA_NAME = SSA_NAME
16351         equivalences if one is more expensive to compute than the other.
16352         * tree-ssa-scopedtables.h (class const_or_copies): Make
16353         record_const_or_copy_raw method private.
16354         (class avail_exprs_stack): New method simplify_binary_operation.
16355         * tree-ssa-scopedtables.c (avail_exprs_stack::lookup_avail_expr): Call
16356         avail_exprs_stack::simplify_binary_operation as needed.
16357         (avail_exprs_stack::simplify_binary_operation): New function.
16359 2017-08-22  Sebastian Huber  <sebastian.huber@embedded-brains.de>
16361         * config.gcc (powerpc-*-rtems*): Add rs6000/linux64.opt.
16362         * config/rs6000/rtems.h (ASM_PREFERRED_EH_DATA_FORMAT): New define.
16363         (DOT_SYMBOLS): Likewise.
16364         (MINIMAL_TOC_SECTION_ASM_OP): Likewise.
16365         (RELOCATABLE_NEEDS_FIXUP): Likewise.
16366         (RS6000_ABI_NAME): Likewise.
16367         (TARGET_CMODEL): Likewise.
16368         (TOC_SECTION_ASM_OP): Likewise.
16369         (SET_CMODEL): New macro.
16370         (SUBSUBTARGET_OVERRIDE_OPTIONS): Evaluate cmodel options.
16372 2017-08-22  Richard Biener  <rguenther@suse.de>
16374         * tree-inline.c (remap_type_1): Change asserts on TYPE_SIZE[_UNIT]
16375         to allow for free-lang-data replacements similar to verify_type_variant.
16377 2017-08-22  Richard Sandiford  <richard.sandiford@linaro.org>
16378             Alan Hayward  <alan.hayward@arm.com>
16379             David Sherwood  <david.sherwood@arm.com>
16381         * config/aarch64/aarch64.md (casesi): Use DImode rather than
16382         VOIDmode for the LABEL_REF.
16384 2017-08-22  Richard Biener  <rguenther@suse.de>
16386         * tree-cfg.c (gimple_split_edge): Avoid reallocating target PHI nodes.
16388 2017-08-22  Richard Biener  <rguenther@suse.de>
16390         * common.opt (feliminate-dwarf2-dups): Ignore.
16391         * doc/invoke.texi (feliminate-dwarf2-dups): Remove documentation.
16392         * dwarf2out.c (push_new_compile_unit, pop_compile_unit,
16393         same_die_p_wrap, compute_section_prefix,
16394         is_symbol_die, assign_symbol_names, break_out_includes): Remove.
16395         (comdat_symbol_id, comdat_symbol_number): Likewise.
16396         (cu_hash_table_entry, cu_hash_table_entry_hasher, cu_hash_type):
16397         Likewise.
16398         (check_duplicate_cu, record_comdat_symbol_number): Likewise.
16399         (output_die): Mark unreachable path unreachable.
16400         (dwarf2out_start_source_file): Do not create DW_TAG_GNU_BINCL.
16401         (dwarf2out_end_source_file): Do not create DW_TAG_GNU_EINCL.
16402         (dwarf2out_init): Remove code handling flag_eliminate_dwarf2_dups.
16403         (dwarf2out_early_finish): Likewise.
16405 2017-08-22  Aldy Hernandez  <aldyh@redhat.com>
16407         * wide-int.h (hwi_with_prec::hwi_with_prec): Sign extend.
16409 2017-08-22  Georg-Johann Lay  <avr@gjlay.de>
16411         PR target/81910
16412         * config/avr/avr.c (avr_handle_addr_attribute): Early return if
16413         not VAR_P. Filter attribute warnings with OPT_Wattributes.
16414         (avr_attribute_table) <io, io_low, address>: Initialize
16415         .decl_required with true.
16417 2017-08-21  Michael Meissner  <meissner@linux.vnet.ibm.com>
16419         * config/rs6000/rs6000-cpus.def (-mvsx-scalar-float): Delete
16420         undocumented debugging options.
16421         (-mvsx-scalar-double): Likewise.
16422         (-mallow-df-permute): Likewise.
16423         (-mvectorize-builtins): Likewise.
16424         * config/rs6000/rs6000.c (rs6000_init_hard_regno_mode_ok): Likewise.
16425         (rs6000_builtin_vectorized_function): Likewise.
16426         (rs6000_builtin_md_vectorized_function): Likewise.
16427         (rs6000_opt_vars): Likewise.
16429 2017-08-21  Uros Bizjak  <ubizjak@gmail.com>
16431         PR target/46091
16432         * config/i386/i386.md (*btsq_imm): Rename from *btsq.
16433         (*btrq_imm): Rename from *btrq.
16434         (*btcq_imm): Rename from *btcq.
16435         (btsc): New code attribute.
16436         (*<btsc><mode>): New insn pattern.
16437         (*btr<mode>): Ditto.
16438         (*<btsc><mode>_mask): New insn_and_split pattern.
16439         (*btr<mode>_mask): Ditto.
16441 2017-08-21  Richard Sandiford  <richard.sandiford@linaro.org>
16442             Alan Hayward  <alan.hayward@arm.com>
16443             David Sherwood  <david.sherwood@arm.com>
16445         * function.c (pad_below): Simplify padding calculation.
16447 2017-08-21  Richard Sandiford  <richard.sandiford@linaro.org>
16448             Alan Hayward  <alan.hayward@arm.com>
16449             David Sherwood  <david.sherwood@arm.com>
16451         * target.def (function_prologue): Remove frame size argument.
16452         (function_epilogue): Likewise.
16453         * doc/tm.texi: Regenerate.
16454         * final.c (final_start_function): Update call to function_prologue.
16455         (final_end_function): Update call to function_epilogue.
16456         (default_function_pro_epilogue): Remove frame size argument.
16457         * output.h (default_function_pro_epilogue): Likewise.
16458         * config/arm/arm.c (arm_output_function_epilogue): Likewise.
16459         (arm_output_function_prologue): Likewise.
16460         * config/frv/frv.c (frv_function_prologue): Likewise.
16461         (frv_function_epilogue): Likewise.
16462         * config/i386/i386.c (ix86_output_function_epilogue): Likewise.
16463         * config/ia64/ia64.c (ia64_output_function_prologue): Likewise.
16464         (ia64_output_function_epilogue): Likewise.
16465         * config/m32r/m32r.c (m32r_output_function_prologue): Likewise.
16466         (m32r_output_function_epilogue): Likewise.
16467         * config/microblaze/microblaze.c (microblaze_function_prologue)
16468         (microblaze_function_epilogue): Likewise.
16469         * config/mips/mips.c (mips_output_function_prologue): Likewise.
16470         (mips_output_function_epilogue): Likewise.
16471         * config/mmix/mmix.c (mmix_target_asm_function_prologue): Likewise.
16472         (mmix_target_asm_function_epilogue): Likewise.
16473         * config/msp430/msp430.c (msp430_start_function): Likewise.
16474         * config/nds32/nds32.c (nds32_asm_function_prologue): Likewise.
16475         (nds32_asm_function_epilogue): Likewise.
16476         * config/nios2/nios2.c (nios2_asm_function_prologue): Likewise.
16477         * config/pa/pa.c (pa_output_function_prologue): Likewise.
16478         (pa_output_function_epilogue): Likewise.
16479         * config/powerpcspe/powerpcspe.c (rs6000_output_function_prologue)
16480         (rs6000_output_function_epilogue): Likewise.
16481         * config/rl78/rl78.c (rl78_start_function): Likewise.
16482         * config/rs6000/rs6000.c (rs6000_output_function_prologue): Likewise.
16483         (rs6000_output_function_epilogue): Likewise.
16484         * config/rx/rx.c (rx_output_function_prologue): Likewise.
16485         * config/sh/sh.c (sh_output_function_epilogue): Likewise.
16486         * config/sparc/sparc.c (sparc_asm_function_prologue): Likewise.
16487         (sparc_asm_function_epilogue): Likewise.
16489 2017-08-21  Richard Sandiford  <richard.sandiford@linaro.org>
16491         * tree.h (type_has_mode_precision_p): New function.
16492         * convert.c (convert_to_integer_1): Use it.
16493         * expr.c (expand_expr_real_2): Likewise.
16494         (expand_expr_real_1): Likewise.
16495         * fold-const.c (fold_single_bit_test_into_sign_test): Likewise.
16496         * match.pd: Likewise.
16497         * tree-ssa-forwprop.c (simplify_rotate): Likewise.
16498         * tree-ssa-math-opts.c (convert_mult_to_fma): Likewise.
16499         * tree-tailcall.c (process_assignment): Likewise.
16500         * tree-vect-loop.c (vectorizable_reduction): Likewise.
16501         * tree-vect-patterns.c (vect_recog_vector_vector_shift_pattern)
16502         (vect_recog_mult_pattern, vect_recog_divmod_pattern): Likewise.
16503         * tree-vect-stmts.c (vectorizable_conversion): Likewise.
16504         (vectorizable_assignment): Likewise.
16505         (vectorizable_shift): Likewise.
16506         (vectorizable_operation): Likewise.
16507         * tree-vrp.c (register_edge_assert_for_2): Likewise.
16509 2017-08-21  Wilco Dijkstra  <wdijkstr@arm.com>
16511         * match.pd: Add pow (C, x) simplification.
16513 2017-08-21  Richard Biener  <rguenther@suse.de>
16515         PR tree-optimization/81900
16516         * tree-ssa-pre.c (compute_antic_aux): Properly compute changed
16517         for blocks with abnormal predecessors.
16518         (compute_antic): Do not set visited flag prematurely.
16520 2017-08-21  Georg-Johann Lay  <avr@gjlay.de>
16522         PR target/79883
16523         * config/avr/avr.c (avr_set_current_function): Typo in diagnostic.
16525 2017-08-21  Richard Sandiford  <richard.sandiford@linaro.org>
16527         * stor-layout.h (vector_type_mode): Move to...
16528         * tree.h (vector_type_mode): ...here.
16529         * stor-layout.c (vector_type_mode): Move to...
16530         * tree.c (vector_type_mode): ...here.  Include rtl.h and regs.h.
16532 2017-08-21  Richard Biener  <rguenther@suse.de>
16534         * debug.h (struct gcc_debug_hooks): Add die_ref_for_decl and
16535         register_external_die hooks.
16536         (debug_false_tree_charstarstar_uhwistar): Declare.
16537         (debug_nothing_tree_charstar_uhwi): Likewise.
16538         * debug.c (do_nothing_debug_hooks): Adjust.
16539         (debug_false_tree_charstarstar_uhwistar): New do nothing.
16540         (debug_nothing_tree_charstar_uhwi): Likewise.
16541         * dbxout.c (dbx_debug_hooks): Adjust.
16542         (xcoff_debug_hooks): Likewise.
16543         * sdbout.c (sdb_debug_hooks): Likewise.
16544         * vmsdbgout.c (vmsdbg_debug_hooks): Likewise.
16545         * dwarf2out.c (macinfo_label_base): New global.
16546         (dwarf2out_register_external_die): New function for the
16547         register_external_die hook.
16548         (dwarf2out_die_ref_for_decl): Likewise for die_ref_for_decl.
16549         (dwarf2_debug_hooks): Use them.
16550         (dwarf2_lineno_debug_hooks): Adjust.
16551         (struct die_struct): Add with_offset flag.
16552         (DEBUG_LTO_DWO_INFO_SECTION, DEBUG_LTO_INFO_SECTION,
16553         DEBUG_LTO_DWO_ABBREV_SECTION, DEBUG_LTO_ABBREV_SECTION,
16554         DEBUG_LTO_DWO_MACINFO_SECTION, DEBUG_LTO_MACINFO_SECTION,
16555         DEBUG_LTO_DWO_MACRO_SECTION, DEBUG_LTO_MACRO_SECTION,
16556         DEBUG_LTO_LINE_SECTION, DEBUG_LTO_DWO_STR_OFFSETS_SECTION,
16557         DEBUG_LTO_STR_DWO_SECTION, DEBUG_STR_LTO_SECTION): New macros
16558         defining section names for the early LTO debug variants.
16559         (reset_indirect_string): New helper.
16560         (add_AT_external_die_ref): Helper for dwarf2out_register_external_die.
16561         (print_dw_val): Add support for offsetted symbol references.
16562         (get_ultimate_context): Split out from is_cxx.
16563         (is_cxx): Use get_ultimate_context.
16564         (is_fortran): Add decl overload.
16565         (compute_comp_unit_symbol): Split out worker from
16566         compute_section_prefix.
16567         (compute_section_prefix): Call compute_comp_unit_symbol and
16568         set comdat_type_p here.
16569         (output_die): Skip DIE symbol output for the LTO added one.
16570         Handle DIE symbol references with offset.
16571         (output_comp_unit): Guard section name mangling properly.
16572         For LTO debug sections emit a symbol at the section beginning
16573         which we use to refer to its DIEs.
16574         (add_abstract_origin_attribute): For DIEs registered via
16575         dwarf2out_register_external_die directly refer to the early
16576         DIE rather than indirectly through the shadow one we created.
16577         Remove obsolete call to dwarf2out_abstract_function for
16578         non-function/block origins.
16579         (gen_array_type_die): When generating early LTO debug do
16580         not emit DW_AT_string_length.
16581         (gen_formal_parameter_die): Do not re-create DIEs for PARM_DECLs
16582         late when in LTO.  As suggested place a gcc_unreachable for
16583         the DECL_ABSTRACT_P case.
16584         (gen_subprogram_die): Avoid another specification DIE
16585         for early built declarations/definitions for the late LTO case.
16586         (gen_variable_die): Add type references for late duplicated VLA dies
16587         when in late LTO.
16588         (gen_inlined_subroutine_die): Do not call dwarf2out_abstract_function,
16589         we have the abstract instance already.
16590         (process_scope_var): Adjust decl DIE contexts in LTO which
16591         first puts them in limbo.
16592         (gen_decl_die): Do not generate type DIEs late apart from
16593         types for VLAs or for decls we do not yet have a DIE.  Do not
16594         call dwarf2out_abstract_function late.
16595         (dwarf2out_early_global_decl): Make sure to create DIEs
16596         for abstract instances of a decl first.
16597         (dwarf2out_late_global_decl): Adjust comment.
16598         (output_macinfo_op): With multiple macro sections use
16599         macinfo_label_base to distinguish labels.
16600         (output_macinfo): Likewise.  Update macinfo_label_base.
16601         Pass in the line info label.
16602         (note_variable_value_in_expr): When generating LTO resolve
16603         all variable values here by generating DIEs as needed.
16604         (init_sections_and_labels): Add early LTO debug flag parameter
16605         and generate different sections and names if set.  Add generation
16606         counter for the labels so we can have multiple of them.
16607         (reset_dies): Helper to allow DIEs to be output multiple times.
16608         (dwarf2out_finish): When outputting DIEs to the fat part of an
16609         LTO object first reset DIEs.
16610         (dwarf2out_early_finish): Output early DIEs when generating LTO.
16611         (modified_type_die): Check for decl_ultimate_origin being self
16612         before recursing.
16613         (gen_type_die_with_usage): Likewise.
16614         (gen_typedef_die): Allow decl_ultimate_origin being self.
16615         (set_decl_abstract_flags): Remove.
16616         (set_block_abstract_flags): Likewise.
16617         (dwarf2out_abstract_function): Treat the early generated DIEs
16618         as the abstract copy and only add DW_AT_inline and
16619         DW_AT_artificial here and call set_decl_origin_self.
16620         If the DIE has an abstract origin don't do anything.
16621         * tree.c (free_lang_data): Build a dummy TRANSLATION_UNIT_DECL
16622         if we have none yet (Go fails to build one, PR78628).
16623         (variably_modified_type_p): Prevent endless recursion for Ada
16624         cyclic pointer types.
16625         * lto-streamer-in.c: Include debug.h.
16626         (dref_queue): New global.
16627         (lto_read_tree_1): Stream in DIE references.
16628         (lto_input_tree): Register DIE references.
16629         (input_function): Stream DECL_DEBUG_ARGS.
16630         * lto-streamer-out.c: Include debug.h.
16631         (lto_write_tree_1): Output DIE references.
16632         (DFS::DFS_write_tree_body): Follow DECL_ABSTRACT_ORIGIN.
16633         Force a TRANSLATION_UNIT_DECL DECL_CONTEXT for file-scope decls.
16634         (output_function): Stream DECL_DEBUG_ARGS.
16635         * tree-streamer-in.c (lto_input_ts_decl_common_tree_pointers):
16636         Stream DECL_ABSTRACT_ORIGIN.
16637         * tree-streamer-out.c (write_ts_decl_common_tree_pointers): Likewise.
16638         (write_ts_decl_minimal_tree_pointers): Force a TRANSLATION_UNIT_DECL
16639         DECL_CONTEXT for file-scope decls.
16640         * lto-streamer.h (struct dref_entry): Declare.
16641         (dref_queue): Likewise.
16642         * cfgexpand.c (pass_expand::execute): Do not call the
16643         outlining_inline_function hook here.
16644         * lto-wrapper.c (debug_obj): New global.
16645         (tool_cleanup): Unlink it if required.
16646         (debug_objcopy): New function.
16647         (run_gcc): Handle early debug sections in the IL files by
16648         extracting them to separate files, partially linkin them and
16649         feeding the result back as result to the linker.
16650         * config/darwin.h (DEBUG_LTO_INFO_SECTION, DEBUG_LTO_ABBREV_SECTION,
16651         DEBUG_LTO_MACINFO_SECTION, DEBUG_LTO_LINE_SECTION,
16652         DEBUG_STR_LTO_SECTION, DEBUG_LTO_MACRO_SECTION): Put early debug
16653         sections into a separate segment.
16654         * config/darwin.c (darwin_asm_named_section): Handle __GNU_DWARF_LTO
16655         segments.
16656         (darwin_asm_dwarf_section): Likewise.
16657         (darwin_asm_output_dwarf_offset): Likewise.
16658         * config/i386/i386.c (make_resolver_func): Set DECL_IGNORED_P.
16660 2017-08-21  Richard Sandiford  <richard.sandiford@linaro.org>
16661             Alan Hayward  <alan.hayward@arm.com>
16662             David Sherwood  <david.sherwood@arm.com>
16664         * read-md.h (md_reader::record_potential_iterator_use): Replace
16665         pointer argument with an rtx and an index.
16666         * read-rtl.c (iterator_group::apply_iterator): Likewise.
16667         (apply_mode_iterator): Likewise.
16668         (apply_code_iterator): Likewise.
16669         (apply_int_iterator): Likewise.
16670         (apply_subst_iterator): Likewise.
16671         (record_iterator_use): Likewise.
16672         (record_attribute_use): Likewise.
16673         (md_reader::record_potential_iterator_use): Likewise.  Update calls
16674         to record_iterator_use and apply_iterator.
16675         (iterator_use): Replace ptr with x and index.
16676         (attribute_use): Likewise.
16677         (apply_attribute_uses): Update calls to apply_iterator.
16678         (apply_iterators): Likewise.  Update initialization of iterator_use.
16679         (rtx_reader::read_rtx_code): Update calls to record_iterator_use
16680         and record_potential_iterator_use.
16681         (rtx_reader::read_rtx_operand): Likewise.
16683 2017-08-21  Richard Sandiford  <richard.sandiford@linaro.org>
16684             Alan Hayward  <alan.hayward@arm.com>
16685             David Sherwood  <david.sherwood@arm.com>
16687         * varasm.c (const_rtx_hash_1): Don't hash in the mode of a
16688         CONST_WIDE_INT.
16690 2017-08-21  Richard Biener  <rguenther@suse.de>
16692         PR middle-end/81884
16693         * tree-ssa-alias.c (stmt_kills_ref_p): Handle array accesses
16694         at struct end conservatively when comparing common bases.
16696 2017-08-21  Richard Biener  <rguenther@suse.de>
16698         * tree-ssa-loop-im.c (struct lim_aux_data): Add ref index member.
16699         (mem_ref_in_stmt): Remove.
16700         (determine_max_movement): Use ref index to get at the reference.
16701         (invariantness_dom_walker::before_dom_children): Deal with
16702         lim data already initialized.
16703         (gather_mem_refs_stmt): Initialize lim data and record ref index.
16705 2017-08-19  Uros Bizjak  <ubizjak@gmail.com>
16707         * config/i386/i386.h (OPTION_MASK_ISA_ROUND): Remove.
16708         (TARGET_ISA_ROUND): Ditto.
16709         (TARGET_ROUND): Ditto.
16710         * config/i386/i386.c: Substitute TARGET_ROUND with TARGET_SSE4_1.
16711         * config/i386/i386.md: Ditto.
16712         * config/i386/sse.md: Ditto.
16713         * config/i386/i386-builtin.def: Substitute OPTION_MASK_ISA_ROUND
16714         with OPTION_MASK_ISA_SSE4_1.
16716 2017-08-19  Uros Bizjak  <ubizjak@gmail.com>
16718         PR target/81894
16719         * doc/extend.texi (x86 Built-in Functions): Correct the name of
16720         __builtin_ia32_lzcnt_u16.
16722 2017-08-18  Peter Bergner  <bergner@vnet.ibm.com>
16724         PR target/80210
16725         * config/rs6000/rs6000.c (rs6000_activate_target_options): New function.
16726         (rs6000_set_current_function): Rewrite function to use it.
16728 2017-08-18  H.J. Lu  <hongjiu.lu@intel.com>
16730         PR c/53037
16731         * print-tree.c (print_node): Support DECL_WARN_IF_NOT_ALIGN
16732         and TYPE_WARN_IF_NOT_ALIGN.
16733         * stor-layout.c (do_type_align): Merge DECL_WARN_IF_NOT_ALIGN.
16734         (handle_warn_if_not_align): New.
16735         (place_union_field): Call handle_warn_if_not_align.
16736         (place_field): Call handle_warn_if_not_align.
16737         Copy TYPE_WARN_IF_NOT_ALIGN.
16738         (finish_builtin_struct): Copy TYPE_WARN_IF_NOT_ALIGN.
16739         (layout_type): Likewise.
16740         * tree-core.h (tree_type_common): Add warn_if_not_align.  Set
16741         spare to 18.
16742         (tree_decl_common): Add warn_if_not_align.
16743         * tree.c (build_range_type_1): Copy TYPE_WARN_IF_NOT_ALIGN.
16744         * tree.h (TYPE_WARN_IF_NOT_ALIGN): New.
16745         (SET_TYPE_WARN_IF_NOT_ALIGN): Likewise.
16746         (DECL_WARN_IF_NOT_ALIGN): Likewise.
16747         (SET_DECL_WARN_IF_NOT_ALIGN): Likewise.
16748         * doc/extend.texi: Document warn_if_not_aligned attribute.
16749         * doc/invoke.texi: Document -Wif-not-aligned and -Wpacked-not-aligned.
16751 2017-08-17  Martin Liska  <mliska@suse.cz>
16753         PR bootstrap/81864
16754         * tree-loop-distribution.c (ddrs_table): Change type to pointer type.
16755         (get_data_dependence): Use it as pointer type.
16756         (distribute_loop): Likewise.
16758 2017-08-17  Bill Schmidt  <wschmidt@linux.vnet.ibm.com>
16760         * config/rs6000/altivec.md (UNSPEC_VMRGOW_DIRECT): New constant.
16761         (p8_vmrgew_v4sf_direct): Generalize to p8_vmrgew_<mode>_direct.
16762         (p8_vmrgow_<mode>_direct): New define_insn.
16763         * config/rs6000/rs6000.c (altivec_expand_vec_perm_const): Properly
16764         handle endianness for vmrgew and vmrgow permute patterns.
16766 2017-08-17  Peter Bergner  <bergner@vnet.ibm.com>
16768         * config/rs6000/altivec.md (VParity): Remove TARGET_VSX_TIMODE.
16769         * config/rs6000/rs6000-cpus.def: Remove comment.
16770         (ISA_2_7_MASKS_SERVER): Delete OPTION_MASK_VSX_TIMODE;
16771         (POWERPC_MASKS): Likewise.
16772         * config/rs6000/rs6000.c (rs6000_hard_regno_mode_ok): Remove unneeded
16773         use of TARGET_VSX_TIMODE.
16774         (rs6000_setup_reg_addr_masks): Change TARGET_VSX_TIMODE to TARGET_VSX.
16775         (rs6000_init_hard_regno_mode_ok): Remove unneeded uses of
16776         TARGET_VSX_TIMODE.  Change use of TARGET_VSX_TIMODE to TARGET_VSX.
16777         (rs6000_option_override_internal): Remove dead code.
16778         (rs6000_legitimize_address): Change TARGET_VSX_TIMODE to TARGET_VSX.
16779         (rs6000_legitimize_reload_address): Likewise.
16780         (rs6000_legitimate_address_p): Likewise.
16781         (rs6000_opt_masks): Delete "vsx-timode".
16782         (rs6000_disable_incompatible_switches): Remove mention of -mvsx-timode
16783         from function comment.
16784         * config/rs6000/rs6000.h (MASK_VSX_TIMODE): Delete.
16785         * config/rs6000/rs6000.md (FMOVE128_GPR): Remove TARGET_VSX_TIMODE.
16786         (V16QI, V8HI, V4SI, V4SF, V2DI, V2DF, V1TI): Remove useless empty
16787         condition.
16788         * config/rs6000/rs6000.opt (mvsx-timode): Replace with stub.
16789         * config/rs6000/vector.md (VEC_IP): Remove TARGET_VSX_TIMODE.
16790         * config/rs6000/vsx.md (VSX_LE_128): Likewise.
16791         (VSX_TI): Likewise.
16792         (VSX_M): Likewise.
16793         (define_peephole2): Likewise.
16795 2017-08-17  Martin Sebor  <msebor@redhat.com>
16797         PR c/81859
16798         * pretty-print.c (pp_format): Use strnlen in %.*s to avoid reading
16799         past the end of an array.
16800         (test_pp_format): Add test cases.
16802 2017-08-17  Richard Sandiford  <richard.sandiford@linaro.org>
16804         * internal-fn.def (CLRSB, CLZ, CTZ, FFS, PARITY, POPCOUNT): Add
16805         missing ECF_NOTHROW flags.
16807 2017-08-17  Peter Bergner  <bergner@vnet.ibm.com>
16809         PR target/72804
16810         * config/rs6000/vsx.md (*vsx_le_permute_<mode>): Add support for
16811         operands residing in integer registers.
16812         (*vsx_le_perm_load_<mode>): Likewise.
16813         (*vsx_le_perm_store_<mode>): Likewise.
16814         (define_peephole2): Add peepholes to optimize the above.
16816 2017-08-17  Marek Polacek  <polacek@redhat.com>
16818         PR middle-end/81814
16819         * fold-const.c (operand_equal_for_comparison_p): Remove code that used
16820         to mimic what shorten_compare did.  Change the return type to bool.
16821         (fold_cond_expr_with_comparison): Update call to
16822         operand_equal_for_comparison_p.
16823         (fold_ternary_loc): Likewise.
16825 2017-08-17  Jackson Woodruff  <jackson.woodruff@arm.com>
16827         * aarch64-simd.md (mov<mode>): No longer force zero immediate into
16828         register.
16829         (*aarch64_simd_mov<mode>): Add new case for stp using zero immediate.
16831 2017-08-17  Richard Biener  <rguenther@suse.de>
16833         * tree-ssa-structalias.c (solve_graph): When propagating
16834         to successors update the graphs succ edges and avoid duplicate work.
16836 2017-08-17  Maxim Ostapenko  <m.ostapenko@samsung.com>
16838         PR target/81861
16839         * config/i386/i386.c (ix86_option_override_internal): Save target
16840         specific options after ix86_stack_protector_guard_reg was changed.
16842 2017-08-17  Richard Biener  <rguenther@suse.de>
16844         PR tree-optimization/81827
16845         * tree-ssa-structalias.c (struct variable_info): Add is_reg_var flag.
16846         (new_var_info): Initialize it conservatively.
16847         (get_call_vi): Mark register vars.
16848         (new_scalar_tmp_constraint_exp): Likewise.
16849         (handle_rhs_call): Likewise.
16850         (handle_const_call): Likewise.
16851         (create_function_info_for): Likewise.
16852         (solve_constraints): Sort varinfos to separate register from
16853         non-register vars to pack points-to solution bitmaps during
16854         iteration.
16856 2017-08-17  Marek Polacek  <polacek@redhat.com>
16858         * gimplify.c (gimplify_adjust_omp_clauses): Compare with 0 instead of 1.
16860 2017-08-17  Richard Biener  <rguenther@suse.de>
16862         * tree-vrp.c (vrp_int_const_binop): Do not set *overflow_p
16863         to true when overflow is undefined and we saturated the result.
16865 2017-08-17  Alan Modra  <amodra@gmail.com>
16867         PR target/80938
16868         * config/rs6000/rs6000.c (rs6000_savres_strategy): Revert 2017-08-09.
16869         Don't use store multiple if only one reg needs saving.
16870         (interesting_frame_related_regno): New function.
16871         (rs6000_frame_related): Don't emit frame info for regs that
16872         don't need saving.
16873         (rs6000_emit_epilogue): Likewise.
16875 2017-08-16  Nathan Sidwell  <nathan@acm.org>
16877         * tree-core.h (tree_type_non_common): Rename binfo to lang_1.
16878         * tree.h (TYPE_BINFO): Use type_non_common.maxval.
16879         (TYPE_LANG_SLOT_1): Use type_non_common.lang_1, for any type.
16880         * tree.c (free_lang_data_in_type): Use else-if chain.  Always
16881         clear TYPE_LANG_1.  Remove obsolete member-function stripping.
16882         (find_decls_types_r): Comment about TYPE_MAX_VALUES_RAW.
16883         (verify_type): Adjust for TYPE_BINFO move.
16884         * lto-streamer-out.c (DFS::DFS_write_tree_body): No need to
16885         process TYPE_BINFO directly.
16886         (hash_tree): Likewise.
16887         * tree-streamer-in.c (lto_input_ts_type_non_common_tree_pointers):
16888         Likewise.
16889         * tree-streamer-out.c (write_ts_type_non_common_tree_pointers):
16890         Likewise.
16892 2017-08-16  David Malcolm  <dmalcolm@redhat.com>
16894         * diagnostic-show-locus.c (colorizer::m_caret): Remove unused field.
16896 2017-08-16  Uros Bizjak  <ubizjak@gmail.com>
16898         PR target/46091
16899         * config/i386/i386.md (*anddi_1_btr): Change predicates of
16900         operand 0 and operand 1 to nomimmediate_operand. Add "m" constraint.
16901         Add ix86_binary_operator_ok to insn constraint.
16902         (*iordi_1_bts): Ditto.
16903         (*xordi_1_btc): Ditto.
16904         (*btsq): Change predicate of operand 0 to nonimmediate_operand.
16905         Update corresponding peephole2 pattern.
16906         (*btrq): Ditto.
16907         (*btcq): Ditto.
16909 2017-08-16  Bin Cheng  <bin.cheng@arm.com>
16911         PR tree-optimization/81832
16912         * tree-ssa-loop-ch.c (should_duplicate_loop_header_p): Don't
16913         copy loop header which has IFN_LOOP_DIST_ALIAS call.
16915 2017-08-16  Marek Polacek  <polacek@redhat.com>
16917         PR middle/81695
16918         * fold-const.c (fold_indirect_ref_1): Restore original behavior
16919         regarding size_zero_node.
16921 2017-08-16  Martin Liska  <mliska@suse.cz>
16923         PR target/81753
16924         * config.gcc: Respect previously set extra_objs in case
16925         of darwin target.
16927 2017-08-16  Richard Sandiford  <richard.sandiford@linaro.org>
16929         PR tree-optimization/81835
16930         * tree-vect-loop.c (vect_is_simple_reduction): Simply checks for
16931         the phi SSA_NAME.  Check that the condition in a COND_EXPR does
16932         not depend on the phi.
16934 2017-08-16  Alan Modra  <amodra@gmail.com>
16936         * config/rs6000/rs6000.c (rs6000_init_hard_regno_mode_ok): Delete
16937         dead code.
16939 2017-08-16  Alan Modra  <amodra@gmail.com>
16941         * config/rs6000/rs6000.c (rs6000_reg_live_or_pic_offset_p): Merge..
16942         (save_reg_p): ..into this.  Update all callers.
16943         (first_reg_to_save): Simplify.
16945 2017-08-16  Alan Modra  <amodra@gmail.com>
16947         * config/rs6000/rs6000.c (rs6000_savres_strategy): Don't restore
16948         fixed regs.
16950 2017-08-15  Joseph Myers  <joseph@codesourcery.com>
16952         PR target/78460
16953         PR target/67712
16954         * config/sh/sh-mem.cc (sh_expand_cmpnstr): Only unroll for
16955         constant count if that count is less than 32.
16957 2017-08-15  Nathan Sidwell  <nathan@acm.org>
16959         * gcc.c (execute): Emit friendlier message if inferior is killed
16960         by an external cause.
16962 2017-08-15  Richard Biener  <rguenther@suse.de>
16964         PR tree-optimization/81790
16965         * tree-ssa-sccvn.c (vn_lookup_simplify_result): Handle both
16966         CONSTRUCTORs from simplifying and VN.
16968 2017-08-14  Martin Sebor  <msebor@redhat.com>
16970         * builtin-attrs.def: Add comments.
16972 2017-08-14  Martin Sebor  <msebor@redhat.com>
16974         PR c/81117
16975         * doc/extend.texi (attribute nonstring): Document new attribute.
16977 2017-08-14  Martin Sebor  <msebor@redhat.com>
16979         PR c/81117
16980         * tree-diagnostic.c (default_tree_printer): Handle %G.
16981         * gimple-pretty-print.h (percent_G_format): Declare new function.
16982         * gimple-pretty-print.c (percent_G_format): Define.
16983         * tree-pretty-print.c (percent_K_format): Add argument.
16985 2017-08-14  Martin Sebor  <msebor@redhat.com>
16987         PR translation/79998
16988         * gimple-ssa-sprintf.c (pass_sprintf_length::handle_gimple_call):
16989         Remove a stray space.
16991 2017-08-14  Uros Bizjak  <ubizjak@gmail.com>
16993         PR target/46091
16994         * config/i386/i386.md (*anddi_1_btr): New insn_and_split pattern.
16995         (*iordi_1_bts): Ditto.
16996         (*xordi_1_btc): Ditto.
16998 2017-08-14  Bill Schmidt  <wschmidt@linux.vnet.ibm.com>
17000         PR target/79845
17001         * config/rs6000/linux64.h (INVALID_64BIT): Use quoted strings.
17002         * config/rs6000/rs6000-c.c (altivec_resolve_overloaded_builtin):
17003         Likewise.
17004         * config/rs6000/rs6000.c (rs6000_init_hard_regno_mode_ok): Use
17005         quoted strings, and make more translator-friendly.
17006         (darwin_rs6000_override_options): Likewise.
17007         (rs6000_option_override_internal): Likewise.
17008         (rs6000_return_in_memory): Fix overlong line.
17009         (init_cmulative_args): Use quoted strings, and make more
17010         translator-friendly.
17011         (rs6000_pass_by_reference): Fix overlong line.
17012         (def_builtin): Use quoted strings.
17013         (altivec_expand_predicate_builtin): Use quoted strings, and make
17014         more translator-friendly.
17015         (htm_expand_builtin): Use quoted strings.
17016         (cpu_expand_builtin): Use quoted strings, and make more
17017         translator-friendly.
17018         (altivec_expand_builtin): Likewise.
17019         (paired_expand_predicate_builtin): Likewise.
17020         (rs6000_invalid_builtin): Likewise.
17021         (builtin_function_type): Use quoted strings.
17022         (rs6000_expand_split_stack_prologue): Use quoted strings, and make
17023         more translator-friendly.
17024         (rs6000_trampoline_init): Likewise.
17025         (rs6000_handle_altivec_attribute): Likewise.
17026         (rs6000_inner_target_options): Use quoted strings.
17027         (rs6000_disable_incompatible_switches): Likewise.
17028         * config/rs6000/sysv4.h (SUBTARGET_OVERRIDE_OPTIONS): Use quoted
17029         strings, and make more translator-friendly.
17030         (SUBSUBTARGET_OVERRIDE_OPTIONS): Use quoted strings.
17032 2017-08-14  Bin Cheng  <bin.cheng@arm.com>
17034         PR tree-optimization/81799
17035         * tree-loop-distribution.c (version_loop_by_alias_check): Force
17036         cond_expr to simple gimple operand.
17038 2017-08-14  Wilco Dijkstra  <wdijkstr@arm.com>
17040         PR middle-end/46932
17041         * doc/sourcebuild.texi (autoincdec): Add autoincdec description.
17043 2017-08-14  Georg-Johann Lay  <avr@gjlay.de>
17045         PR target/81754
17046         PR target/81268
17047         * config/avr/avr.opt (mgas-isr-prologues): New Var avr_gasisr_prologues.
17048         * config/avr/avr.md (gasisr, *gasisr): Use it instead of
17049         TARGET_GASISR_PROLOGUES.
17050         * config/avr/avr.c (avr_option_override): Same.
17051         (avr_pass_pre_proep::execute): Same.
17053 2017-08-13  H.J. Lu  <hongjiu.lu@intel.com>
17055         PR target/81820
17056         * config/i386/i386.c (ix86_finalize_stack_frame_flags): Replace
17057         frame pointer with stack pointer - UNITS_PER_WORD in debug insns.
17059 2017-08-13  Uros Bizjak  <ubizjak@gmail.com>
17061         * config/i386/i386.md (*load_tp_<mode>): Redefine as
17062         define_insn_and_split.  Split to a memory load from 0 in
17063         DEFAULT_TLS_SEG_REG address space.  Merge with *load_tp_x32
17064         using PTR mode iterator.
17065         (*load_tp_x32_zext"): Redefine as define_insn_and_split.
17066         Split to a memory load from 0 in DEFAULT_TLS_SEG_REG address space.
17067         (*add_tp_<mode>): Redefine as define_insn_and_split.
17068         Split to an add with a memory load from 0 in DEFAULT_TLS_SEG_REG
17069         address space.  Merge with *add_tp_x32 using PTR mode iterator.
17070         (*add_tp_x32_zext"): Redefine as define_insn_and_split.
17071         Split to an add with a  memory load from 0 in
17072         DEFAULT_TLS_SEG_REG address space.
17074 2017-08-12  Andrew Pinski  <apinski@cavium.com>
17076         * config/aarch64/aarch64-option-extensions.def (rdma):
17077         Fix feature string to what Linux prints out in /proc/cpuinfo.
17079 2017-08-12  Pierre-Marie de Rodat  <derodat@adacore.com>
17081         PR ada/79542
17082         * dwarf2out.c (modified_type_die): For C typedef types that have
17083         an ultimate origin, process the ultimate origin instead of the
17084         input type.
17085         (gen_typedef_die): Assert that input DECLs have no ultimate
17086         origin.
17087         (gen_type_die_with_usage): For typedef variants that have an
17088         ultimate origin, just call gen_decl_die on the original DECL.
17089         (process_scope_var): Avoid creating DIEs for local typedefs and
17090         concrete static variables.
17092 2017-08-12  Alan Modra  <amodra@gmail.com>
17094         PR target/81170
17095         PR target/81295
17096         * config/rs6000/sysv4.h (STARTFILE_LINUX_SPEC): Upgrade to
17097         match gnu-user.h startfile.
17098         (ENDFILE_LINUX_SPEC): Similarly.
17100 2017-08-11  Thomas Schwinge  <thomas@codesourcery.com>
17102         PR lto/81430
17103         * config/nvptx/nvptx.c (nvptx_override_options_after_change):
17104         Remove function.
17105         (TARGET_OVERRIDE_OPTIONS_AFTER_CHANGE): Remove definition.
17107 2017-08-11  Tamar Christina  <tamar.christina@arm.com>
17108         * config/aarch64/aarch64.md (mov<mode>): Change.
17109         (*movhf_aarch64, *movsf_aarch64, *movdf_aarch64):
17110         aarch64_reg_or_fp_float into aarch64_reg_or_fp_zero.
17111         * config/aarch64/predicates.md (aarch64_reg_or_fp_float): Removed.
17113 2017-08-11  Eric Botcazou  <ebotcazou@adacore.com>
17115         * tree-sra.c (build_access_from_expr_1): Use more precise diagnostics
17116         for storage order barriers.
17118 2017-08-11  Martin Liska  <mliska@suse.cz>
17120         PR tree-opt/79987
17121         * tree-chkp.c (chkp_get_bounds_for_decl_addr): Do not instrument
17122         variables of void type.
17124 2017-08-11  Martin Liska  <mliska@suse.cz>
17126         * asan.c (asan_protect_global): Replace ASM_OUTPUT_DEF with
17127         TARGET_SUPPORTS_ALIASES.
17128         * cgraph.c (cgraph_node::create_same_body_alias): Likewise.
17129         * ipa-visibility.c (can_replace_by_local_alias): Likewise.
17130         (optimize_weakref): Likewise.
17131         * symtab.c (symtab_node::noninterposable_alias): Likewise.
17132         * varpool.c (varpool_node::create_extra_name_alias): Likewise.
17133         * defaults.h: Introduce TARGET_SUPPORTS_ALIASES.
17135 2017-08-11  Martin Liska  <mliska@suse.cz>
17137         PR ipa/81213
17138         * config/i386/i386.c (make_resolver_func): Do complete
17139         refactoring of the function.
17141 2017-08-10  Uros Bizjak  <ubizjak@gmail.com>
17143         PR target/81708
17144         * config/i386/i386.opt (mstack-protector-guard-symbol=): New option
17145         * config/i386/i386.c (ix86_stack_protect_guard): Use
17146         ix86_stack_protect_guard_symbol_str to generate varible declaration.
17147         * doc/invoke.texi (x86 Options): Document
17148         -mstack-protector-guard-symbol= option.
17150 2017-08-10  Uros Bizjak  <ubizjak@gmail.com>
17152         * config/i386/i386-protos.h (ix86_split_stack_guard): New prototype.
17153         * config/i386/i386.c (ix86_split_stack_guard): New function.
17154         (ix86_xpand_split_stack_prologue): Call ix86_split_stack_guard.
17155         (ix86_legitimate_address_p) <case UNSPEC_STACK_CHECK>: Remove.
17156         (i386_asm_output_addr_const_extra) <case UNSPEC_STACK_CHECK>: Ditto.
17157         (optput_pic_addr_const): Remove UNSPEC_STACK_CHECK handling.
17158         * config/i386/i386.md (unspec): Remove UNSPEC_STACK_CHECK.
17159         (split_stack_space_check): Call ix86_split_stack_guard.
17161 2017-08-10  Martin Sebor  <msebor@redhat.com>
17163         * print-tree.c (print_node): Print location using the established
17164         format %s:%i%i.
17165         Replace spaces with colons.
17166         (debug_raw, debug): Ditto.
17168 2017-08-10  Martin Sebor  <msebor@redhat.com>
17170         PR c++/81586
17171         * pretty-print.c (pp_format): Correct the handling of %s precision.
17173 2017-08-10  H.J. Lu  <hongjiu.lu@intel.com>
17175         PR target/81736
17176         * config/i386/i386.c (ix86_finalize_stack_realign_flags): Renamed
17177         to ...
17178         (ix86_finalize_stack_frame_flags): This.  Also clear
17179         frame_pointer_needed if -fno-omit-frame-pointer is used without
17180         stack access.
17181         (ix86_expand_prologue): Replace ix86_finalize_stack_realign_flags
17182         with ix86_finalize_stack_frame_flags.
17183         (ix86_expand_epilogue): Likewise.
17184         (ix86_expand_split_stack_prologue): Likewise.
17185         * doc/invoke.texi: Add a note for -fno-omit-frame-pointer.
17187 2017-08-10  Martin Liska  <mliska@suse.cz>
17189         PR c++/81355
17190         * c-attribs.c (handle_target_attribute):
17191         Report warning for an empty string argument of target attribute.
17193 2017-08-09  Jakub Jelinek  <jakub@redhat.com>
17195         PR c/81687
17196         * omp-low.c (omp_copy_decl): Don't remap FORCED_LABEL or DECL_NONLOCAL
17197         LABEL_DECLs.
17198         * tree-cfg.c (move_stmt_op): Don't adjust DECL_CONTEXT of FORCED_LABEL
17199         or DECL_NONLOCAL labels.
17200         (move_stmt_r) <case GIMPLE_LABEL>: Adjust DECL_CONTEXT of FORCED_LABEL
17201         or DECL_NONLOCAL labels here.
17203 2017-08-09  Will Schmidt  <will_schmidt@vnet.ibm.com>
17205         * config/rs6000/rs6000.c (rs6000_option_override_internal): Add blurb
17206         to indicate when early gimple folding has been disabled.
17207         (rs6000_gimple_fold_builtin): Add debug content.
17208         (rs6000_invalid_builtin): Fix whitespace.
17209         (rs6000_expand_builtin): Fix whitespace.
17210         * config/rs6000/rs6000.opt: Add option for -mfold-gimple.
17212 2017-08-09  Segher Boessenkool  <segher@kernel.crashing.org>
17214         PR target/80938
17215         * config/rs6000/rs6000.c (rs6000_savres_strategy): Don't use
17216         SAVE_MULTIPLE if not all the registers that saves, should be saved.
17218 2017-08-09  Jim Wilson  <jim.wilson@linaro.org>
17220         * config/aarch64/aarch64-cores.def (falkor): Use falkor pipeline.
17221         (qdf24xx): Likewise.
17222         * config/aarch64/aarch64.md: Include falkor.md.
17223         * config/aarch64/falkor.md: New.
17225 2017-08-09  Marek Polacek  <polacek@redhat.com>
17227         PR c/81233
17228         * diagnostic-core.h (emit_diagnostic_valist): Add declaration.
17229         * diagnostic.c (emit_diagnostic): Add a comment.
17230         (emit_diagnostic_valist): New function.
17232 2017-08-09  Marek Polacek  <polacek@redhat.com>
17234         PR c/81417
17235         * input.c (make_location): New overload.
17236         * input.h (make_location): Declare.
17238 2017-08-08  Alan Modra  <amodra@gmail.com>
17239             H.J. Lu  <hongjiu.lu@intel.com>
17241         PR driver/81523
17242         * gcc.c (NO_PIE_SPEC): Delete.
17243         (PIE_SPEC): Define as !no-pie/pie.  Move static|shared|r
17244         exclusion..
17245         (LINK_PIE_SPEC): ..to here.
17246         (LINK_COMMAND_SPEC): Support -no-pie.
17247         * config/gnu-user.h (GNU_USER_TARGET_STARTFILE_SPEC): Correct
17248         chain of crtbegin*.o selection, update for PIE_SPEC changes and
17249         format.
17250         (GNU_USER_TARGET_ENDFILE_SPEC): Similarly.
17251         * config/sol2.h (STARTFILE_CRTBEGIN_SPEC): Similarly.
17252         (ENDFILE_CRTEND_SPEC): Similarly.
17254 2017-08-08  Uros Bizjak  <ubizjak@gmail.com>
17256         PR target/81708
17257         * config/i386/i386.opt (mstack-protector-guard-reg=): New option
17258         (mstack-protector-guard-offset=): Ditto.
17259         * config/i386/i386.c (ix86_option_override): Handle
17260         -mstack-protector-guard-reg= and -mstack-protector-guard-offset=
17261         options.
17262         (ix86_stack_protect_guard): Use ix86_stack_protect_guard_reg and
17263         ix86_stack_protect_guard_offset variables.
17264         (TARGET_STACK_PROTECT_GUARD): Always define.
17265         * doc/invoke.texi (x86 Options): Document -mstack-protector-guard-reg=
17266         and -mstack-protector-guard-offset= options.
17268 2017-08-08  Bin Cheng  <bin.cheng@arm.com>
17270         * tree-ssa-loop-ivopts.c (relate_compare_use_with_all_cands): Handle
17271         boundary case for the last candidate.
17273 2017-08-08  Bin Cheng  <bin.cheng@arm.com>
17275         * doc/invoke.texi: Document -ftree-loop-distribution for O3.
17276         * opts.c (default_options_table): Add OPT_ftree_loop_distribution.
17278 2017-08-08  Tamar Christina  <tamar.christina@arm.com>
17280         PR middle-end/19706
17281         * config/aarch64/aarch64.md (xorsign<mode>3): New optabs.
17282         * config/aarch64/aarch64-builtins.c
17283         (aarch64_builtin_vectorized_function): Added CASE_CFN_XORSIGN.
17284         * config/aarch64/aarch64-simd-builtins.def: Added xorsign BINOP.
17285         * config/aarch64/aarch64-simd.md: Added xorsign<mode>3
17287 2017-08-08  Tamar Christina  <tamar.christina@arm.com>
17288             Andrew Pinski <pinskia@gmail.com>
17290         PR middle-end/19706
17291         * internal-fn.def (XORSIGN): New.
17292         * optabs.def (xorsign_optab): New.
17293         * tree-ssa-math-opts.c (is_copysign_call_with_1): New.
17294         (convert_expand_mult_copysign): New.
17295         (pass_optimize_widening_mul::execute): Call
17296         convert_expand_mult_copysign.
17298 2017-08-08  Bill Schmidt  <wschmidt@linux.vnet.ibm.com>
17300         PR tree-optimization/81354
17301         * gimple-ssa-strength-reduction.c (create_add_on_incoming_edge):
17302         Insert on edges rather than explicitly creating landing pads.
17303         (analyze_candidates_and_replace): Commit edge inserts.
17305 2017-08-08  Richard Biener  <rguenther@suse.de>
17307         PR middle-end/81719
17308         * tree-ssa-loop-niter.c: Include tree-dfa.h.
17309         (expand_simple_operations): Also look through ADDR_EXPRs with
17310         MEM_REF bases treating them as POINTER_PLUS_EXPR.
17312 2017-08-08  Richard Biener  <rguenther@suse.de>
17314         PR tree-optimization/81723
17315         * tree-vect-slp.c (struct bst_traits): New hash traits.
17316         (bst_fail): New global.
17317         (vect_build_slp_tree_2): New worker, split out from ...
17318         (vect_build_slp_tree): ... this now wrapping it with using
17319         bst_fail set to cache SLP tree build fails.  Properly handle
17320         max_tree_size.
17321         (vect_analyze_slp_instance): Allocate and free bst_fail.
17323 2017-08-08  Martin Liska  <mliska@suse.cz>
17325         PR tree-opt/81696
17326         * ipa-icf-gimple.c (func_checker::compare_cst_or_decl): Consider
17327         LABEL_DECLs that can be from a different function.
17329 2017-08-08  Bin Cheng  <bin.cheng@arm.com>
17331         PR tree-optimization/81744
17332         * tree-predcom.c (prepare_finalizers_chain): Deep copy expr of
17333         loop's number of iterations.
17335 2017-08-08  Martin Liska  <mliska@suse.cz>
17337         * asan.c: Include header files.
17338         * attribs.c (build_decl_attribute_variant): New function moved
17339         from tree.[ch].
17340         (build_type_attribute_qual_variant): Likewise.
17341         (cmp_attrib_identifiers): Likewise.
17342         (simple_cst_list_equal): Likewise.
17343         (omp_declare_simd_clauses_equal): Likewise.
17344         (attribute_value_equal): Likewise.
17345         (comp_type_attributes): Likewise.
17346         (build_type_attribute_variant): Likewise.
17347         (lookup_ident_attribute): Likewise.
17348         (remove_attribute): Likewise.
17349         (merge_attributes): Likewise.
17350         (merge_type_attributes): Likewise.
17351         (merge_decl_attributes): Likewise.
17352         (merge_dllimport_decl_attributes): Likewise.
17353         (handle_dll_attribute): Likewise.
17354         (attribute_list_equal): Likewise.
17355         (attribute_list_contained): Likewise.
17356         * attribs.h (lookup_attribute): New function moved from tree.[ch].
17357         (lookup_attribute_by_prefix): Likewise.
17358         * bb-reorder.c: Include header files.
17359         * builtins.c: Likewise.
17360         * calls.c: Likewise.
17361         * cfgexpand.c: Likewise.
17362         * cgraph.c: Likewise.
17363         * cgraphunit.c: Likewise.
17364         * convert.c: Likewise.
17365         * dwarf2out.c: Likewise.
17366         * final.c: Likewise.
17367         * fold-const.c: Likewise.
17368         * function.c: Likewise.
17369         * gimple-expr.c: Likewise.
17370         * gimple-fold.c: Likewise.
17371         * gimple-pretty-print.c: Likewise.
17372         * gimple.c: Likewise.
17373         * gimplify.c: Likewise.
17374         * hsa-common.c: Likewise.
17375         * hsa-gen.c: Likewise.
17376         * internal-fn.c: Likewise.
17377         * ipa-chkp.c: Likewise.
17378         * ipa-cp.c: Likewise.
17379         * ipa-devirt.c: Likewise.
17380         * ipa-fnsummary.c: Likewise.
17381         * ipa-inline.c: Likewise.
17382         * ipa-visibility.c: Likewise.
17383         * ipa.c: Likewise.
17384         * lto-cgraph.c: Likewise.
17385         * omp-expand.c: Likewise.
17386         * omp-general.c: Likewise.
17387         * omp-low.c: Likewise.
17388         * omp-offload.c: Likewise.
17389         * omp-simd-clone.c: Likewise.
17390         * opts-global.c: Likewise.
17391         * passes.c: Likewise.
17392         * predict.c: Likewise.
17393         * sancov.c: Likewise.
17394         * sanopt.c: Likewise.
17395         * symtab.c: Likewise.
17396         * toplev.c: Likewise.
17397         * trans-mem.c: Likewise.
17398         * tree-chkp.c: Likewise.
17399         * tree-eh.c: Likewise.
17400         * tree-into-ssa.c: Likewise.
17401         * tree-object-size.c: Likewise.
17402         * tree-parloops.c: Likewise.
17403         * tree-profile.c: Likewise.
17404         * tree-ssa-ccp.c: Likewise.
17405         * tree-ssa-live.c: Likewise.
17406         * tree-ssa-loop.c: Likewise.
17407         * tree-ssa-sccvn.c: Likewise.
17408         * tree-ssa-structalias.c: Likewise.
17409         * tree-ssa.c: Likewise.
17410         * tree-streamer-in.c: Likewise.
17411         * tree-vectorizer.c: Likewise.
17412         * tree-vrp.c: Likewise.
17413         * tsan.c: Likewise.
17414         * ubsan.c: Likewise.
17415         * varasm.c: Likewise.
17416         * varpool.c: Likewise.
17417         * tree.c: Remove functions moved to attribs.[ch].
17418         * tree.h: Likewise.
17419         * config/aarch64/aarch64.c: Add attrs.h header file.
17420         * config/alpha/alpha.c: Likewise.
17421         * config/arc/arc.c: Likewise.
17422         * config/arm/arm.c: Likewise.
17423         * config/avr/avr.c: Likewise.
17424         * config/bfin/bfin.c: Likewise.
17425         * config/c6x/c6x.c: Likewise.
17426         * config/cr16/cr16.c: Likewise.
17427         * config/cris/cris.c: Likewise.
17428         * config/darwin.c: Likewise.
17429         * config/epiphany/epiphany.c: Likewise.
17430         * config/fr30/fr30.c: Likewise.
17431         * config/frv/frv.c: Likewise.
17432         * config/ft32/ft32.c: Likewise.
17433         * config/h8300/h8300.c: Likewise.
17434         * config/i386/winnt.c: Likewise.
17435         * config/ia64/ia64.c: Likewise.
17436         * config/iq2000/iq2000.c: Likewise.
17437         * config/lm32/lm32.c: Likewise.
17438         * config/m32c/m32c.c: Likewise.
17439         * config/m32r/m32r.c: Likewise.
17440         * config/m68k/m68k.c: Likewise.
17441         * config/mcore/mcore.c: Likewise.
17442         * config/microblaze/microblaze.c: Likewise.
17443         * config/mips/mips.c: Likewise.
17444         * config/mmix/mmix.c: Likewise.
17445         * config/mn10300/mn10300.c: Likewise.
17446         * config/moxie/moxie.c: Likewise.
17447         * config/msp430/msp430.c: Likewise.
17448         * config/nds32/nds32-isr.c: Likewise.
17449         * config/nds32/nds32.c: Likewise.
17450         * config/nios2/nios2.c: Likewise.
17451         * config/nvptx/nvptx.c: Likewise.
17452         * config/pa/pa.c: Likewise.
17453         * config/pdp11/pdp11.c: Likewise.
17454         * config/powerpcspe/powerpcspe.c: Likewise.
17455         * config/riscv/riscv.c: Likewise.
17456         * config/rl78/rl78.c: Likewise.
17457         * config/rx/rx.c: Likewise.
17458         * config/s390/s390.c: Likewise.
17459         * config/sh/sh.c: Likewise.
17460         * config/sol2.c: Likewise.
17461         * config/sparc/sparc.c: Likewise.
17462         * config/spu/spu.c: Likewise.
17463         * config/stormy16/stormy16.c: Likewise.
17464         * config/tilegx/tilegx.c: Likewise.
17465         * config/tilepro/tilepro.c: Likewise.
17466         * config/v850/v850.c: Likewise.
17467         * config/vax/vax.c: Likewise.
17468         * config/visium/visium.c: Likewise.
17469         * config/xtensa/xtensa.c: Likewise.
17471 2017-08-07  Michael Meissner  <meissner@linux.vnet.ibm.com>
17473         PR target/81593
17474         * config/rs6000/vsx.md (vsx_concat_<mode>, VSX_D): Cleanup
17475         constraints since the -mupper-regs-* switches have been
17476         eliminated.
17477         (vsx_concat_<mode>_1): New combiner insns to recognize inserting
17478         into a vector from a double word element that was extracted from
17479         another vector, and eliminate extra XXPERMDI instructions.
17480         (vsx_concat_<mode>_2): Likewise.
17481         (vsx_concat_<mode>_3): Likewise.
17482         (vsx_set_<mode>, VSX_D): Rewrite vector set in terms of vector
17483         concat to allow optimizing inserts from previous extracts.
17485 2017-08-07  Uros Bizjak  <ubizjak@gmail.com>
17487         * config/i386/i386.c (ix86_stack_protect_guard): Generate
17488         memory reference to a SSP offset in TLS address space.
17489         (ix86_print_operand) <case '@'>: Remove.
17490         (ix86_print_operand_punct_valid_p): Remove '@' code.
17491         * config/i386/i386.md (unspec): Remove UNSPEC_SP_TLS_SET and
17492         UNSPEC_SP_TLS_TEST.
17493         (stack_tls_protect_set_<mode>): Remove.
17494         (stack_protect_set): Do not call gen_stack_tls_protect_set_<mode>.
17495         (stack_tls_protect_test_<mode>): Remove.
17496         (stack_protect_test): Do not call gen_stack_tls_protect_test_<mode>.
17498 2017-08-07  Olivier Hainque  <hainque@adacore.com>
17500         PR target/81755
17501         * config/vxworksae.h (VXWORKS_HAVE_TLS): Define.
17503 2017-08-07  Douglas Rupp  <rupp@adacore.com>
17505         * Makefile.in (install-mkheaders): Fix typo, where the multi_dir
17506         variable was referenced as multidir in command.
17508 2017-08-07  Jakub Jelinek  <jakub@redhat.com>
17510         PR c/69389
17511         * gimplify.c (goa_stabilize_expr): Handle BIT_INSERT_EXPR and
17512         BIT_FIELD_REF.
17514 2017-08-07  Martin Liska  <mliska@suse.cz>
17516         * config/m32c/m32c.c: Add include of stringpool.h and attribs.h.
17517         * config/rl78/rl78.c: Add include of attribs.h.
17518         * config/sh/sh.c: Likewise.
17519         * config/v850/v850.c: Likewise.
17521 2017-08-07  Tom de Vries  <tom@codesourcery.com>
17523         PR middle-end/78266
17524         * omp-expand.c (expand_oacc_for): Ensure diff_type is large enough.
17526 2017-08-07  Martin Liska  <mliska@suse.cz>
17528         * config/mips/mips.c: Include attribs.h.
17530 2017-08-07  Thomas Koenig  <tkoenig@gcc.gnu.org>
17532         PR fortran/68829
17533         * doc/invoke.texi: Document change in behvaior for -Ofast for
17534         Fortran.
17536 2017-08-07  Wilco Dijkstra  <wdijkstr@arm.com>
17538         * config/aarch64/aarch64.c (aarch64_pushwb_single_reg):
17539         Use gen_frame_mem.
17540         (aarch64_pop_regs): Likewise.
17541         (aarch64_gen_load_pair): Likewise.
17542         (aarch64_save_callee_saves): Likewise.
17543         (aarch64_restore_callee_saves): Likewise.
17545 2017-08-07  H.J. Lu  <hongjiu.lu@intel.com>
17547         * config/i386/i386.c: Revert the last change.
17549 2017-08-07  H.J. Lu  <hongjiu.lu@intel.com>
17551         PR target/81736
17552         * config/i386/i386.c (ix86_finalize_stack_realign_flags): Renamed
17553         to ...
17554         (ix86_finalize_stack_frame_flags): This.  Also clear
17555         frame_pointer_needed if -fno-omit-frame-pointer is used without
17556         stack access.
17557         (ix86_expand_prologue): Replace ix86_finalize_stack_realign_flags
17558         with ix86_finalize_stack_frame_flags.
17559         (ix86_expand_epilogue): Likewise.
17560         (ix86_expand_split_stack_prologue): Likewise.
17562 2017-08-07  H.J. Lu  <hongjiu.lu@intel.com>
17564         PR target/81743
17565         * config/i386/i386.c (get_builtin_code_for_version): Set priority
17566         to P_AES for Westmere.
17568 2017-08-07  Jonathan Yong  <10walls@gmail.com>
17570         * config/i386/mingw.opt (fset-stack-executable): Removed.
17571         * config/i386/cygming.opt (fset-stack-executable): Moved
17572         from mingw.opt.
17573         * config/i386/cygwin.h: Define CHECK_EXECUTE_STACK_ENABLED.
17575 2017-08-07  Segher Boessenkool  <segher@kernel.crashing.org>
17577         * print-rtl.c (print_exp): Print NOT as "~" instead of as "!".
17579 2017-08-07  Marek Polacek  <polacek@redhat.com>
17581         PR middle-end/81737
17582         * fold-const.c (fold_indirect_ref_1): Check type_domain.
17584 2017-08-07  Martin Liska  <mliska@suse.cz>
17586         * attribs.h (canonicalize_attr_name): New function.
17587         (cmp_attribs): Move from c-format.c and adjusted.
17588         (is_attribute_p): Moved from tree.h.
17589         * tree-inline.c: Add new includes.
17590         * tree.c (cmp_attrib_identifiers): Use cmp_attribs.
17591         (private_is_attribute_p): Remove.
17592         (private_lookup_attribute): Likewise.
17593         (private_lookup_attribute_by_prefix): Simplify.
17594         (remove_attribute): Use is_attribute_p.
17595         * tree.h: Remove removed declarations.
17597 2017-08-07  Jakub Jelinek  <jakub@redhat.com>
17599         PR middle-end/81698
17600         * stmt.c (emit_case_dispatch_table): Add DEFAULT_EDGE argument,
17601         instead of computing it in the function.  Formatting fix.
17602         (expand_case): Don't rely on default_edge being the first edge,
17603         clear it if removing it, pass default_edge to
17604         emit_case_dispatch_table.
17605         (expand_sjlj_dispatch_table): Pass NULL as DEFAULT_EDGE, formatting
17606         fix.
17608 2017-08-06  Uros Bizjak  <ubizjak@gmail.com>
17610         * config/alpha/alpha.c (alpha_reorg): If trap is the last active
17611         insn in the function, emit NOP after the insn.
17613 2017-08-06  Tom de Vries  <tom@codesourcery.com>
17615         * omp-expand.c (expand_oacc_for): Add missing edge probability for tile
17616         and element loops.
17618 2017-08-06  Tom de Vries  <tom@codesourcery.com>
17620         * omp-expand.c (expand_oacc_for): Add missing edge probability for chunk
17621         loop.
17623 2017-08-04  Yury Gribov  <tetra2005@gmail.com>
17625         PR tree-optimization/57371
17626         * match.pd: New pattern.
17628 2017-08-04  Marek Polacek  <polacek@redhat.com>
17630         PR middle-end/81695
17631         * fold-const.c (fold_indirect_ref_1): For ((int *)&a + 4 -> a[1],
17632         perform the computation in offset_int.
17634 2017-08-04  Richard Sandiford  <richard.sandiford@linaro.org>
17636         PR tree-optimization/81136
17637         * tree-vectorizer.h: Include tree-hash-traits.h.
17638         (vec_base_alignments): New typedef.
17639         (vec_info): Add a base_alignments field.
17640         (vect_record_base_alignments): Declare.
17641         * tree-data-ref.h (data_reference): Add an is_conditional_in_stmt
17642         field.
17643         (DR_IS_CONDITIONAL_IN_STMT): New macro.
17644         (create_data_ref): Add an is_conditional_in_stmt argument.
17645         * tree-data-ref.c (create_data_ref): Likewise.  Use it to initialize
17646         the is_conditional_in_stmt field.
17647         (data_ref_loc): Add an is_conditional_in_stmt field.
17648         (get_references_in_stmt): Set the is_conditional_in_stmt field.
17649         (find_data_references_in_stmt): Update call to create_data_ref.
17650         (graphite_find_data_references_in_stmt): Likewise.
17651         * tree-ssa-loop-prefetch.c (determine_loop_nest_reuse): Likewise.
17652         * tree-vect-data-refs.c (vect_analyze_data_refs): Likewise.
17653         (vect_record_base_alignment): New function.
17654         (vect_record_base_alignments): Likewise.
17655         (vect_compute_data_ref_alignment): Adjust base_addr and aligned_to
17656         for nested statements even if we fail to compute a misalignment.
17657         Use pooled base alignments for unconditional references.
17658         (vect_find_same_alignment_drs): Compare base addresses instead
17659         of base objects.
17660         (vect_analyze_data_refs_alignment): Call vect_record_base_alignments.
17661         * tree-vect-slp.c (vect_slp_analyze_bb_1): Likewise.
17663 2017-08-04  Richard Sandiford  <richard.sandiford@linaro.org>
17665         * tree-vectorizer.h (vec_info): Add a constructor and destructor.
17666         Add an explicit name for the enum.  Use auto_vec for slp_instances
17667         and grouped_stores.
17668         (_loop_vec_info): Add a constructor and destructor.  Use auto_vec
17669         for all vectors.
17670         (_bb_vec_info): Add a constructor and destructor.
17671         (vinfo_for_stmt): Return NULL for uids of -1 as well.
17672         (destroy_loop_vec_info): Delete.
17673         (vect_destroy_datarefs): Likewise.
17674         * tree-vectorizer.c (vect_destroy_datarefs): Delete.
17675         (vec_info::vec_info): New function.
17676         (vec_info::~vec_info): Likewise.
17677         (vectorize_loops): Use delete instead of destroy_loop_vec_info.
17678         * tree-parloops.c (gather_scalar_reductions): Use delete instead of
17679         destroy_loop_vec_info.
17680         * tree-vect-loop.c (new_loop_vec_info): Replace with...
17681         (_loop_vec_info::_loop_vec_info): ...this.
17682         (destroy_loop_vec_info): Replace with...
17683         (_loop_vec_info::~_loop_vec_info): ...this.  Unconditionally delete
17684         the stmt_vec_infos.  Leave handling of vec_info information to its
17685         destructor.  Remove explicit vector releases.
17686         (vect_analyze_loop_form): Use new instead of new_loop_vec_info.
17687         (vect_analyze_loop): Use delete instead of destroy_loop_vec_info.
17688         * tree-vect-slp.c (new_bb_vec_info): Replace with...
17689         (_bb_vec_info::_bb_vec_info): ...this.  Don't reserve space in
17690         BB_VINFO_GROUPED_STORES or BB_VINFO_SLP_INSTANCES.
17691         (destroy_bb_vec_info): Replace with...
17692         (_bb_vec_info::~_bb_vec_info): ...this.  Leave handling of vec_info
17693         information to its destructor.
17694         (vect_slp_analyze_bb_1): Use new and delete instead of
17695         new_bb_vec_info and destroy_bb_vec_info.
17696         (vect_slp_bb): Replace 2 calls to destroy_bb_vec_info with a
17697         single delete.
17699 2017-08-04  Richard Sandiford  <richard.sandiford@linaro.org>
17701         * tree-data-ref.h (subscript): Add access_fn field.
17702         (data_dependence_relation): Add could_be_independent_p.
17703         (SUB_ACCESS_FN, DDR_COULD_BE_INDEPENDENT_P): New macros.
17704         (same_access_functions): Move to tree-data-ref.c.
17705         * tree-data-ref.c (ref_contains_union_access_p): New function.
17706         (access_fn_component_p): Likewise.
17707         (access_fn_components_comparable_p): Likewise.
17708         (dr_analyze_indices): Add a reference to access_fn_component_p.
17709         (dump_data_dependence_relation): Use SUB_ACCESS_FN instead of
17710         DR_ACCESS_FN.
17711         (constant_access_functions): Likewise.
17712         (add_other_self_distances): Likewise.
17713         (same_access_functions): Likewise.  (Moved from tree-data-ref.h.)
17714         (initialize_data_dependence_relation): Use XCNEW and remove
17715         explicit zeroing of DDR_REVERSED_P.  Look for a subsequence
17716         of access functions that have the same type.  Allow the
17717         subsequence to end with different bases in some circumstances.
17718         Record the chosen access functions in SUB_ACCESS_FN.
17719         (build_classic_dist_vector_1): Replace ddr_a and ddr_b with
17720         a_index and b_index.  Use SUB_ACCESS_FN instead of DR_ACCESS_FN.
17721         (subscript_dependence_tester_1): Likewise dra and drb.
17722         (build_classic_dist_vector): Update calls accordingly.
17723         (subscript_dependence_tester): Likewise.
17724         * tree-ssa-loop-prefetch.c (determine_loop_nest_reuse): Check
17725         DDR_COULD_BE_INDEPENDENT_P.
17726         * tree-vectorizer.h (LOOP_REQUIRES_VERSIONING_FOR_ALIAS): Test
17727         comp_alias_ddrs instead of may_alias_ddrs.
17728         * tree-vect-data-refs.c (vect_analyze_possibly_independent_ddr):
17729         New function.
17730         (vect_analyze_data_ref_dependence): Use it if
17731         DDR_COULD_BE_INDEPENDENT_P, but fall back to using the recorded
17732         distance vectors if that fails.
17733         (dependence_distance_ge_vf): New function.
17734         (vect_prune_runtime_alias_test_list): Use it.  Don't clear
17735         LOOP_VINFO_MAY_ALIAS_DDRS.
17737 2017-08-04  Richard Biener  <rguenther@suse.de>
17739         PR middle-end/81705
17740         * fold-const.c (fold_binary_loc): Properly restrict
17741         minus_var0 && minus_var1 case when associating undefined overflow
17742         entities.
17744 2017-08-04  Tom de Vries  <tom@codesourcery.com>
17746         * omp-simd-clone.c (simd_clone_adjust): Add missing edge probability.
17748 2017-08-03  Bill Schmidt  <wschmidt@linux.vnet.ibm.com>
17750         * config/rs6000/rs6000-c.c (altivec_resolve_overloaded_builtin):
17751         Don't start diagnostic messages with a capital letter.
17752         * config/rs6000/rs6000.c (rs6000_option_override_internal):
17753         Likewise.
17754         (rs6000_invalid_builtin): Likewise.
17755         (rs6000_trampoline_init): Likewise.
17757 2017-08-03  Jakub Jelinek  <jakub@redhat.com>
17759         PR target/81621
17760         * bb-reorder.c (pass_partition_blocks::execute): Return TODO_df_finish
17761         after setting changeable df flags.
17763 2017-08-03  Richard Biener  <rguenther@suse.de>
17765         * tree-ssa-reassoc.c (should_break_up_subtract): Also break
17766         up if the use is in USE - X.
17768 2017-08-03  Alexander Monakov  <amonakov@ispras.ru>
17770         * toplev.c (dumpfile.h): New include.
17771         (internal_error_reentered): New static function.  Use it...
17772         (internal_error_function): ...here to handle reentered internal_error.
17774 2017-08-03  Richard Biener  <rguenther@suse.de>
17776         PR middle-end/81148
17777         * fold-const.c (split_tree): Add minus_var and minus_con
17778         arguments, remove unused loc arg.  Never generate NEGATE_EXPRs
17779         here but always use minus_*.
17780         (associate_trees): Assert we never associate with MINUS_EXPR
17781         and NULL first operand.  Do not recurse for PLUS_EXPR operands
17782         when associating as MINUS_EXPR either.
17783         (fold_binary_loc): Track minus_var and minus_con.
17785 2017-08-03  Tom de Vries  <tom@codesourcery.com>
17787         PR lto/81430
17788         * tree-streamer-in.c (lto_input_ts_function_decl_tree_pointers): If
17789         ACCEL_COMPILER, apply finish_options on
17790         DECL_FUNCTION_SPECIFIC_OPTIMIZATION.
17792 2017-08-03  Tom de Vries  <tom@codesourcery.com>
17794         PR target/81662
17795         * config/nvptx/nvptx.c (nvptx_option_override): Emit sorry if
17796         function_entry_patch_area_size > 0.
17798 2017-08-03  Jakub Jelinek  <jakub@redhat.com>
17800         PR driver/81650
17801         * calls.c (alloc_max_size): Use HOST_WIDE_INT_UC (10??)
17802         instead of 10??LU, perform unit multiplication in wide_int,
17803         don't change alloc_object_size_limit if the limit is larger
17804         than SSIZE_MAX.
17806         PR tree-optimization/81655
17807         PR tree-optimization/81588
17808         * tree-ssa-reassoc.c (optimize_range_tests_var_bound): Handle also
17809         the case when ranges[i].low and high are 1 for unsigned type with
17810         precision 1.
17812         PR middle-end/81052
17813         * omp-low.c (diagnose_sb_0): Handle flag_openmp_simd like flag_openmp.
17814         (pass_diagnose_omp_blocks::gate): Enable also for flag_openmp_simd.
17816 2017-08-03  Prathamesh Kulkarni  <prathamesh.kulkarni@linaro.org>
17818         * tree-vrp.h: Add include guard.
17820 2017-08-02  Uros Bizjak  <ubizjak@gmail.com>
17822         PR target/81644
17823         * config/i386/i386.md (unspecv): Add UNSPECV_UD2.
17824         (ud2): New insn pattern.
17825         * config/i386/i386.c (ix86_expand_epilogue):
17826         For naked functions, generate ud2 instead of trap insn.
17828 2017-08-02  Marek Polacek  <polacek@redhat.com>
17830         PR other/81667
17831         * alloc-pool.h (base_pool_allocator): Initialize m_elt_size.
17833 2017-08-02  Tom de Vries  <tom@codesourcery.com>
17834             Cesar Philippidis  <cesar@codesourcery.com>
17836         * config/nvptx/nvptx.c (nvptx_lockless_update, nvptx_lockfull_update):
17837         Add missing edge probabilities.
17839 2017-08-02  Tamar Christina  <tamar.christina@arm.com>
17841         * config/aarch64/aarch64.c (aarch64_reinterpret_float_as_int):
17842         Correct endianness.
17844 2017-08-02  Jakub Jelinek  <jakub@redhat.com>
17846         PR middle-end/79499
17847         * function.c (thread_prologue_and_epilogue_insns): Determine blocks
17848         for find_many_sub_basic_blocks bitmap by looking up BLOCK_FOR_INSN
17849         of first NONDEBUG_INSN_P in each of the split_prologue_seq and
17850         prologue_seq sequences - if any.
17852 2017-08-02  Richard Biener  <rguenther@suse.de>
17854         * tree-vect-stmts.c (vectorizable_store): Perform vector extracts
17855         via vectors if supported, integer extracts via punning if supported
17856         or otherwise vector extracts.
17858 2017-08-02  Richard Biener  <rguenther@suse.de>
17860         * tree-ssa-pre.c (bitmap_insert_into_set_1): Remove and inline
17861         into ...
17862         (bitmap_insert_into_set): ... this.
17864 2017-08-02  Richard Biener  <rguenther@suse.de>
17866         PR tree-optimization/81633
17867         Revert
17868         2015-08-17  Alan Hayward  <alan.hayward@arm.com>
17870         PR tree-optimization/71752
17871         * tree-vect-slp.c (vect_get_slp_defs): Handle null operands.
17873 2017-08-01  Daniel Santos  <daniel.santos@pobox.com>
17875         * config/i386/i386.h (ix86_frame::outlined_save_offset): Remove field.
17876         (machine_function::call_ms2sysv_pad_out): Remove field.
17877         * config/i386/i386.c (xlogue_layout::get_stack_space_used): Modify.
17878         (ix86_compute_frame_layout): Likewise.
17880 2017-08-01  H.J. Lu  <hongjiu.lu@intel.com>
17882         PR target/81654
17883         * config/i386/i386.c (ix86_set_func_type): Disallow naked
17884         attribute with interrupt attribute.
17886 2017-08-01  Andrew Pinski  <apinski@cavium.com>
17888         * tree-ssa-scopedtables.c (hashable_expr_equal_p): Check
17889         BIT_INSERT_EXPR's operand 1
17890         to see if the types precision matches.
17892 2017-08-01  Martin Liska  <mliska@suse.cz>
17894         PR middle-end/70140
17895         * builtins.c (expand_builtin_memcpy_args): Remove.
17896         (expand_builtin_memcpy): Call newly added function
17897         expand_builtin_memory_copy_args.
17898         (expand_builtin_memcpy_with_bounds): Likewise.
17899         (expand_builtin_mempcpy): Remove last argument.
17900         (expand_builtin_mempcpy_with_bounds): Likewise.
17901         (expand_builtin_memory_copy_args): New function created from
17902         expand_builtin_mempcpy_args with small modifications.
17903         (expand_builtin_mempcpy_args): Remove.
17904         (expand_builtin_stpcpy): Remove unused argument.
17905         (expand_builtin): Likewise.
17906         (expand_builtin_with_bounds): Likewise.
17908 2017-08-01  Martin Liska  <mliska@suse.cz>
17910         Revert r250771
17911         Make mempcpy more optimal (PR middle-end/70140).
17913 2017-08-01  Jakub Jelinek  <jakub@redhat.com>
17915         PR target/81622
17916         * config/rs6000/rs6000-c.c (altivec_resolve_overloaded_builtin): For
17917         __builtin_vec_cmpne verify both arguments are compatible vectors
17918         before looking at TYPE_MODE on the element type.  For __builtin_vec_ld
17919         verify arg1_type is a pointer or array type.  For __builtin_vec_st,
17920         move computation of aligned to after checking the argument types.
17921         Formatting fixes.
17923         PR target/80846
17924         * config/rs6000/vsx.md (vextract_fp_from_shorth,
17925         vextract_fp_from_shortl): Add element mode after mode in gen_vec_init*
17926         calls.
17928 2017-08-01  Jerome Lambourg  <lambourg@adacore.com>
17929             Doug Rupp  <rupp@adacore.com>
17930             Olivier Hainque  <hainque@adacore.com>
17932         * config.gcc (arm-wrs-vxworks*): Rework to handle arm-wrs-vxworks7 as
17933         well as arm-wrs-vxworks. Update target_cpu_name from arm6 (arch v3) to
17934         arm8 (arch v4).
17935         * config/arm/vxworks.h (MAYBE_TARGET_BPABI_CPP_BUILTINS): New, helper
17936         for TARGET_OS_CPP_BUILTIN.
17937         (TARGET_OS_CPP_BUILTIN): Invoke MAYBE_TARGET_BPABI_CPP_BUILTINS(),
17938         refine CPU definitions for arm_arch5 and add those for arm_arch6 and
17939         arm_arch7.
17940         (MAYBE_ASM_ABI_SPEC): New, helper for SUBTARGET_EXTRA_ASM_SPEC,
17941         passing required abi options to the assembler for EABI configurations.
17942         (EXTRA_CC1_SPEC): New macro, to help prevent the implicit production
17943         of .text.hot and .text.unlikely sections for kernel modules when
17944         using ARM style exceptions.
17945         (CC1_SPEC): Remove obsolete attempt at mimicking Diab toolchain
17946         options. Add EXTRA_CC1_SPEC.
17947         (VXWORKS_ENDIAN_SPEC): Adjust comment and remove handling of Diab
17948         toolchain options.
17949         (DWARF2_UNWIND_INFO): Redefine to handle the pre/post VxWorks 7
17950         transition.
17951         (ARM_TARGET2_DWARF_FORMAT): Define.
17952         * config/arm/t-vxworks: Adjust multilib control to removal of the
17953         Diab command line options.
17955 2017-08-01  Martin Liska  <mliska@suse.cz>
17957         PR gcov-profile/81561
17958         * gcov.c (unblock): Make unblocking safe as we need to preserve
17959         index correspondence of blocks and block_lists.
17961 2017-08-01  Richard Biener  <rguenther@suse.de>
17963         PR tree-optimization/81181
17964         * tree-ssa-pre.c (compute_antic_aux): Defer clean() to ...
17965         (compute_antic): ... end of iteration here.
17967 2017-08-01  James Greenhalgh  <james.greenhalgh@arm.com>
17969         * common.opt (ftree-vectorize): No longer set flag_tree_vectorize.
17970         (ftree-loop-vectorize): Set as EnabledBy ftree-vectorize.
17971         (ftree-slp-vectorize): Likewise.
17972         * omp-expand (expand_omp_simd): Remove flag_tree_vectorize, as it
17973         can no longer be set independent of flag_tree_loop_vectorize.
17974         * omp-general.c (emp_max_vf): Likewise.
17975         * opts.c (enable_fdo_optimizations): Remove references to
17976         flag_tree_vectorize, these are now implicit.
17977         (common_handle_option): Remove handling for OPT_ftree_vectorize,
17978         and leave it for the options machinery.
17980 2017-08-01  Martin Liska  <mliska@suse.cz>
17982         PR middle-end/70140
17983         * builtins.c (expand_builtin_memcpy_args): Remove.
17984         (expand_builtin_memcpy): Call newly added function
17985         expand_builtin_memory_copy_args.
17986         (expand_builtin_memcpy_with_bounds): Likewise.
17987         (expand_builtin_mempcpy): Remove last argument.
17988         (expand_builtin_mempcpy_with_bounds): Likewise.
17989         (expand_builtin_memory_copy_args): New function created from
17990         expand_builtin_mempcpy_args with small modifications.
17991         (expand_builtin_mempcpy_args): Remove.
17992         (expand_builtin_stpcpy): Remove unused argument.
17993         (expand_builtin): Likewise.
17994         (expand_builtin_with_bounds): Likewise.
17996 2017-08-01  Uros Bizjak  <ubizjak@gmail.com>
17998         PR target/81641
17999         * config/i386/i386.c (ix86_print_operand_address_as): For -masm=intel
18000         print "ds:" only for immediates in generic address space.
18002 2017-08-01  Uros Bizjak  <ubizjak@gmail.com>
18004         PR target/81639
18005         * config/i386/i386.c (ix86_funciton_naked): New prototype.
18006         (ix86_function_ok_for_sibcall): Return false for naked functions.
18008 2017-08-01  Richard Biener  <rguenther@suse.de>
18010         * tree-ssa-pre.c (print_pre_expr): Handle NULL expr.
18011         (compute_antic): Seed worklist with exit block predecessors.
18012         * cfganal.c (dfs_find_deadend): For a cycle return the source
18013         of the edge closing it.
18015 2017-08-01  Tamar Christina  <tamar.christina@arm.com>
18017         * config/aarch64/aarch64.c
18018         (aarch64_can_const_movi_rtx_p): Move 0 check.
18020 2017-08-01  Bin Cheng  <bin.cheng@arm.com>
18022         * tree.h (POINTER_TYPE_OVERFLOW_UNDEFINED): Delete.
18023         * fold-const.c (fold_comparison, fold_binary_loc): Delete use of
18024         above macro.
18025         * match.pd: Ditto in address comparison pattern.
18027 2017-08-01  Bin Cheng  <bin.cheng@arm.com>
18029         PR tree-optimization/81627
18030         * tree-predcom.c (prepare_finalizers): Always rewrite into loop
18031         closed ssa form for store-store chain.
18033 2017-08-01  Bin Cheng  <bin.cheng@arm.com>
18035         PR tree-optimization/81620
18036         * tree-predcom.c (add_ref_to_chain): Don't set has_max_use_after
18037         for store-store chain.
18039 2017-08-01  Jakub Jelinek  <jakub@redhat.com>
18041         PR tree-optimization/81588
18042         * tree-ssa-reassoc.c (optimize_range_tests_var_bound): If
18043         ranges[i].in_p, invert comparison code ccode.  For >/>=,
18044         swap rhs1 and rhs2 and comparison code unconditionally,
18045         for </<= don't do that.  Don't swap rhs1/rhs2 again if
18046         ranges[i].in_p, instead invert comparison code ccode if
18047         opcode or oe->rank is BIT_IOR_EXPR.
18049         PR target/80846
18050         * optabs.def (vec_extract_optab, vec_init_optab): Change from
18051         a direct optab to conversion optab.
18052         * optabs.c (expand_vector_broadcast): Use convert_optab_handler
18053         with GET_MODE_INNER as last argument instead of optab_handler.
18054         * expmed.c (extract_bit_field_1): Likewise.  Use vector from
18055         vector extraction if possible and optab is available.
18056         * expr.c (store_constructor): Use convert_optab_handler instead
18057         of optab_handler.  Use vector initialization from smaller
18058         vectors if possible and optab is available.
18059         * tree-vect-stmts.c (vectorizable_load): Likewise.
18060         * doc/md.texi (vec_extract, vec_init): Document that the optabs
18061         now have two modes.
18062         * config/i386/i386.c (ix86_expand_vector_init): Handle expansion
18063         of vec_init from half-sized vectors with the same element mode.
18064         * config/i386/sse.md (ssehalfvecmode): Add V4TI case.
18065         (ssehalfvecmodelower, ssescalarmodelower): New mode attributes.
18066         (reduc_plus_scal_v8df, reduc_plus_scal_v4df, reduc_plus_scal_v2df,
18067         reduc_plus_scal_v16sf, reduc_plus_scal_v8sf, reduc_plus_scal_v4sf,
18068         reduc_<code>_scal_<mode>, reduc_umin_scal_v8hi): Add element mode
18069         after mode in gen_vec_extract* calls.
18070         (vec_extract<mode>): Renamed to ...
18071         (vec_extract<mode><ssescalarmodelower>): ... this.
18072         (vec_extract<mode><ssehalfvecmodelower>): New expander.
18073         (rotl<mode>3, rotr<mode>3, <shift_insn><mode>3, ashrv2di3): Add
18074         element mode after mode in gen_vec_init* calls.
18075         (VEC_INIT_HALF_MODE): New mode iterator.
18076         (vec_init<mode>): Renamed to ...
18077         (vec_init<mode><ssescalarmodelower>): ... this.
18078         (vec_init<mode><ssehalfvecmodelower>): New expander.
18079         * config/i386/mmx.md (vec_extractv2sf): Renamed to ...
18080         (vec_extractv2sfsf): ... this.
18081         (vec_initv2sf): Renamed to ...
18082         (vec_initv2sfsf): ... this.
18083         (vec_extractv2si): Renamed to ...
18084         (vec_extractv2sisi): ... this.
18085         (vec_initv2si): Renamed to ...
18086         (vec_initv2sisi): ... this.
18087         (vec_extractv4hi): Renamed to ...
18088         (vec_extractv4hihi): ... this.
18089         (vec_initv4hi): Renamed to ...
18090         (vec_initv4hihi): ... this.
18091         (vec_extractv8qi): Renamed to ...
18092         (vec_extractv8qiqi): ... this.
18093         (vec_initv8qi): Renamed to ...
18094         (vec_initv8qiqi): ... this.
18095         * config/rs6000/vector.md (VEC_base_l): New mode attribute.
18096         (vec_init<mode>): Renamed to ...
18097         (vec_init<mode><VEC_base_l>): ... this.
18098         (vec_extract<mode>): Renamed to ...
18099         (vec_extract<mode><VEC_base_l>): ... this.
18100         * config/rs6000/paired.md (vec_initv2sf): Renamed to ...
18101         (vec_initv2sfsf): ... this.
18102         * config/rs6000/altivec.md (splitter, altivec_copysign_v4sf3,
18103         vec_unpacku_hi_v16qi, vec_unpacku_hi_v8hi, vec_unpacku_lo_v16qi,
18104         vec_unpacku_lo_v8hi, mulv16qi3, altivec_vreve<mode>2): Add
18105         element mode after mode in gen_vec_init* calls.
18106         * config/aarch64/aarch64-simd.md (vec_init<mode>): Renamed to ...
18107         (vec_init<mode><Vel>): ... this.
18108         (vec_extract<mode>): Renamed to ...
18109         (vec_extract<mode><Vel>): ... this.
18110         * config/aarch64/iterators.md (Vel): New mode attribute.
18111         * config/s390/s390.c (s390_expand_vec_strlen, s390_expand_vec_movstr):
18112         Add element mode after mode in gen_vec_extract* calls.
18113         * config/s390/vector.md (non_vec_l): New mode attribute.
18114         (vec_extract<mode>): Renamed to ...
18115         (vec_extract<mode><non_vec_l>): ... this.
18116         (vec_init<mode>): Renamed to ...
18117         (vec_init<mode><non_vec_l>): ... this.
18118         * config/s390/s390-builtins.def (s390_vlgvb, s390_vlgvh, s390_vlgvf,
18119         s390_vlgvf_flt, s390_vlgvg, s390_vlgvg_dbl): Add element mode after
18120         vec_extract mode.
18121         * config/arm/iterators.md (V_elem_l): New mode attribute.
18122         * config/arm/neon.md (vec_extract<mode>): Renamed to ...
18123         (vec_extract<mode><V_elem_l>): ... this.
18124         (vec_extractv2di): Renamed to ...
18125         (vec_extractv2didi): ... this.
18126         (vec_init<mode>): Renamed to ...
18127         (vec_init<mode><V_elem_l>): ... this.
18128         (reduc_plus_scal_<mode>, reduc_plus_scal_v2di, reduc_smin_scal_<mode>,
18129         reduc_smax_scal_<mode>, reduc_umin_scal_<mode>,
18130         reduc_umax_scal_<mode>, neon_vget_lane<mode>, neon_vget_laneu<mode>):
18131         Add element mode after gen_vec_extract* calls.
18132         * config/mips/mips-msa.md (vec_init<mode>): Renamed to ...
18133         (vec_init<mode><unitmode>): ... this.
18134         (vec_extract<mode>): Renamed to ...
18135         (vec_extract<mode><unitmode>): ... this.
18136         * config/mips/loongson.md (vec_init<mode>): Renamed to ...
18137         (vec_init<mode><unitmode>): ... this.
18138         * config/mips/mips-ps-3d.md (vec_initv2sf): Renamed to ...
18139         (vec_initv2sfsf): ... this.
18140         (vec_extractv2sf): Renamed to ...
18141         (vec_extractv2sfsf): ... this.
18142         (reduc_plus_scal_v2sf, reduc_smin_scal_v2sf, reduc_smax_scal_v2sf):
18143         Add element mode after gen_vec_extract* calls.
18144         * config/mips/mips.md (unitmode): New mode iterator.
18145         * config/spu/spu.c (spu_expand_prologue, spu_allocate_stack,
18146         spu_builtin_extract): Add element mode after gen_vec_extract* calls.
18147         * config/spu/spu.md (inner_l): New mode attribute.
18148         (vec_init<mode>): Renamed to ...
18149         (vec_init<mode><inner_l>): ... this.
18150         (vec_extract<mode>): Renamed to ...
18151         (vec_extract<mode><inner_l>): ... this.
18152         * config/sparc/sparc.md (veltmode): New mode iterator.
18153         (vec_init<VMALL:mode>): Renamed to ...
18154         (vec_init<VMALL:mode><VMALL:veltmode>): ... this.
18155         * config/ia64/vect.md (vec_initv2si): Renamed to ...
18156         (vec_initv2sisi): ... this.
18157         (vec_initv2sf): Renamed to ...
18158         (vec_initv2sfsf): ... this.
18159         (vec_extractv2sf): Renamed to ...
18160         (vec_extractv2sfsf): ... this.
18161         * config/powerpcspe/vector.md (VEC_base_l): New mode attribute.
18162         (vec_init<mode>): Renamed to ...
18163         (vec_init<mode><VEC_base_l>): ... this.
18164         (vec_extract<mode>): Renamed to ...
18165         (vec_extract<mode><VEC_base_l>): ... this.
18166         * config/powerpcspe/paired.md (vec_initv2sf): Renamed to ...
18167         (vec_initv2sfsf): ... this.
18168         * config/powerpcspe/altivec.md (splitter, altivec_copysign_v4sf3,
18169         vec_unpacku_hi_v16qi, vec_unpacku_hi_v8hi, vec_unpacku_lo_v16qi,
18170         vec_unpacku_lo_v8hi, mulv16qi3): Add element mode after mode in
18171         gen_vec_init* calls.
18173 2017-08-01  Richard Biener  <rguenther@suse.de>
18175         PR tree-optimization/81297
18176         * tree-vrp.c (get_single_symbol): Remove assert, instead drop
18177         TREE_OVERFLOW from INTEGER_CSTs.
18179 2017-07-31  Segher Boessenkool  <segher@kernel.crashing.org>
18181         * config/rs6000/rs6000.c (enum rs6000_reg_type): Delete trailing comma.
18183 2017-07-31  Carl Love  <cel@us.ibm.com>
18185         * config/rs6000/rs6000-c: Add support for built-in functions
18186         vector signed char vec_xl_be (signed long long, signed char *);
18187         vector unsigned char vec_xl_be (signed long long, unsigned char *);
18188         vector signed int vec_xl_be (signed long long, signed int *);
18189         vector unsigned int vec_xl_be (signed long long, unsigned int *);
18190         vector signed long long vec_xl_be (signed long long, signed long long *);
18191         vector unsigned long long vec_xl_be (signed long long, unsigned long long *);
18192         vector signed short vec_xl_be (signed long long, signed short *);
18193         vector unsigned short vec_xl_be (signed long long, unsigned short *);
18194         vector double vec_xl_be (signed long long, double *);
18195         vector float vec_xl_be (signed long long, float *);
18196         * config/rs6000/altivec.h (vec_xl_be): Add #define.
18197         * config/rs6000/rs6000-builtin.def (XL_BE_V16QI, XL_BE_V8HI, XL_BE_V4SI)
18198         XL_BE_V2DI, XL_BE_V4SF, XL_BE_V2DF, XL_BE): Add definitions
18199         for the builtins.
18200         * config/rs6000/rs6000.c (altivec_expand_xl_be_builtin): Add function.
18201         (altivec_expand_builtin): Add switch statement to call
18202         altivec_expand_xl_be for each builtin.
18203         (altivec_init_builtins): Add def_builtin for _builtin_vsx_le_be_v8hi,
18204         __builtin_vsx_le_be_v4si, __builtin_vsx_le_be_v2di,
18205         __builtin_vsx_le_be_v4sf, __builtin_vsx_le_be_v2df,
18206         __builtin_vsx_le_be_v16qi.
18207         * doc/extend.texi: Update the built-in documentation file for the
18208         new built-in functions.
18210 2017-07-31  Uros Bizjak  <ubizjak@gmail.com>
18212         PR target/25967
18213         * config/i386/i386.c (ix86_allocate_stack_slots_for_args):
18214         New function.
18215         (TARGET_ALLOCATE_STACK_SLOTS_FOR_ARGS): Define.
18217 2017-07-31  Andreas Krebbel  <krebbel@linux.vnet.ibm.com>
18219         * config.gcc: Add z14.
18220         * config/s390/driver-native.c (s390_host_detect_local_cpu): Add
18221         CPU model numbers for z13s and z14.
18222         * config/s390/s390-c.c (s390_resolve_overloaded_builtin): Replace
18223         arch12 with z14.
18224         * config/s390/s390-opts.h (enum processor_type): Rename
18225         PROCESSOR_ARCH12 to PROCESSOR_3906_Z14.
18226         * config/s390/s390.c (processor_table): Add field for CPU name to
18227         be passed to Binutils.
18228         (s390_asm_output_machine_for_arch): Use the new field in
18229         processor_table for Binutils.
18230         (s390_expand_builtin): Replace arch12 with z14.
18231         (s390_issue_rate): Rename PROCESSOR_ARCH12 to PROCESSOR_3906_Z14.
18232         (s390_get_sched_attrmask): Likewise.
18233         (s390_get_unit_mask): Likewise.
18234         * config/s390/s390.opt: Add z14 to processor_type enum.
18236 2017-07-31  Martin Jambor  <mjambor@suse.cz>
18238         PR hsa/81477
18239         * ipa-fnsummary.c (ipa_fn_summary_generate): Set versionable
18240         regardless of optimization level.
18242 2017-07-31  Jan Hubicka <hubicka@ucw.cz>
18243             Martin Liska  <mliska@suse.cz>
18245         * predict.def: Remove old comment and adjust probability.
18246         * gimplify.c (should_warn_for_implicit_fallthrough): Ignore
18247         PREDICT statements.
18249 2017-07-31  Uros Bizjak  <ubizjak@gmail.com>
18251         PR target/25967
18252         * config/i386/i386.c (ix86_function_naked): New function.
18253         (ix86_can_use_return_insn_p): Return false for naked functions.
18254         (ix86_expand_prologue): Skip prologue for naked functions.
18255         (ix86_expand_epilogue): Skip epilogue for naked functions
18256         and emit trap instruction.
18257         (ix86_warn_func_return): New function.
18258         (ix86_attribute_table): Add "naked" attribute specification.
18259         (TARGET_WARN_FUNC_RETURN): Define.
18260         * doc/extend.texi (x86 Function Attributes) <naked>: Document it.
18262 2017-07-31  Martin Liska  <mliska@suse.cz>
18264         * gimple-pretty-print.c (dump_gimple_label): Never dump BB info.
18265         (dump_gimple_bb_header): Always dump BB info.
18266         (pp_cfg_jump): Do not append info about BB when dumping a jump.
18268 2017-07-31  Martin Liska  <mliska@suse.cz>
18270         PR sanitize/81530
18271         * convert.c (convert_to_integer_1): Guard condition with flag_sanitize_p
18272         also with current_function_decl non-null equality.
18274 2017-07-31  Jakub Jelinek  <jakub@redhat.com>
18276         PR sanitizer/81604
18277         * ubsan.c (ubsan_type_descriptor): For UBSAN_PRINT_ARRAY don't
18278         change type to the element type, instead add eltype variable and
18279         use it where we are interested in the element type.
18281         PR tree-optimization/81603
18282         * ipa-polymorphic-call.c
18283         (ipa_polymorphic_call_context::ipa_polymorphic_call_context): Perform
18284         offset arithmetic in offset_int, bail out if the resulting bit offset
18285         doesn't fit into shwi.
18287 2017-07-31  Martin Liska  <mliska@suse.cz>
18289         * gimplify.c (mostly_copy_tree_r): Remove Java specific hunk.
18290         (gimplify_save_expr): Fix comment.
18292 2017-07-30  H.J. Lu  <hongjiu.lu@intel.com>
18294         PR target/79793
18295         * config/i386/i386.c (ix86_function_arg): Update arguments for
18296         exception handler.
18297         (ix86_compute_frame_layout): Set the initial stack offset to
18298         INCOMING_FRAME_SP_OFFSET.  Update red-zone offset with
18299         INCOMING_FRAME_SP_OFFSET.
18300         (ix86_expand_epilogue): Don't pop the 'ERROR_CODE' off the
18301         stack before exception handler returns.
18302         * config/i386/i386.h (INCOMING_FRAME_SP_OFFSET): Add the
18303         the 'ERROR_CODE' for exception handler.
18305 2017-07-30  Uros Bizjak  <ubizjak@gmail.com>
18307         * config/i386/i386.h (ASM_PRINTF_EXTENSIONS): New macro.
18308         (ASM_OUTPUT_REG_PUSH): Rewrite with new operand modifiers.
18309         (ASM_OUTPUT_REG_POP): Ditto.
18310         * config/i386/i386.c (ix86_asm_output_function_label): Use fputs
18311         instead of asm_fprintf to output pure string.
18313 2017-07-29  Jakub Jelinek  <jakub@redhat.com>
18315         * debug.h (struct gcc_debug_hooks): Add IMPLICIT argument
18316         to imported_module_or_decl hook.
18317         (debug_nothing_tree_tree_tree_bool): Remove.
18318         (debug_nothing_tree_tree_tree_bool_bool): New declaration.
18319         * debug.c (do_nothing_debug_hooks): Use
18320         debug_nothing_tree_tree_tree_bool_bool instead of
18321         debug_nothing_tree_tree_tree_bool.
18322         * vmsdbgout.c (vmsdbg_debug_hooks): Likewise.
18323         * dbxout.c (dbx_debug_hooks, xcoff_debug_hooks): Likewise.
18324         * sdbout.c (sdb_debug_hooks): Likewise.
18325         * dwarf2out.c (dwarf2_lineno_debug_hooks): Likewise.
18326         (gen_namespace_die): Add DW_AT_export_symbols attribute if
18327         langhook wants it.
18328         (dwarf2out_imported_module_or_decl): Add IMPLICIT argument,
18329         if true, -gdwarf-5 and decl will have DW_AT_export_symbols
18330         attribute, don't add anything.
18332 2017-07-28  Trevor Saunders  <tbsaunde+gcc@tbsaunde.org>
18334         * fold-const.c (fold_build1_stat_loc): Remove _stat from name.
18335         (fold_build2_stat_loc): Likewise.
18336         (fold_build3_stat_loc): Likewise.
18337         * fold-const.h (fold_build1, fold_build2, fold_build3): Adjust.
18338         (fold_build1_loc): Remove macro.
18339         (fold_build2_loc): Likewise.
18340         (fold_build3_loc): Likewise.
18342 2017-07-28  Trevor Saunders  <tbsaunde+gcc@tbsaunde.org>
18344         * gimple.c (gimple_build_debug_bind_stat): Remove _stat from name.
18345         (gimple_build_debug_bind_source_stat): Likewise.
18346         * gimple.h (gimple_build_debug_bind): Remove macro.
18347         (gimple_build_debug_bind_source): Likewise.
18349 2017-07-28  Trevor Saunders  <tbsaunde+gcc@tbsaunde.org>
18351         * bitmap.c (bitmap_alloc): Adjust.
18352         (bitmap_gc_alloc): Likewise.
18353         * bitmap.h (bitmap_initialize_stat): Remove _stat from name.
18355 2017-07-28  Trevor Saunders  <tbsaunde+gcc@tbsaunde.org>
18357         * bitmap.c (bitmap_obstack_alloc_stat): Rename to bitmap_alloc.
18358         (bitmap_gc_alloc_stat): Rename to bitmap_gc_alloc.
18359         * bitmap.h (bitmap_obstack_alloc_stat): Adjust prototype.
18360         (bitmap_gc_alloc_stat): Likewise.
18361         (BITMAP_ALLOC, BITMAP_GGC_ALLOC): Adjust.
18363 2017-07-28  Trevor Saunders  <tbsaunde+gcc@tbsaunde.org>
18365         * rtl.c (shallow_copy_rtx_stat): Remove _stat from name.
18366         * rtl.h (shallow_copy_rtx): Remove macro.
18368 2017-07-28  Trevor Saunders  <tbsaunde+gcc@tbsaunde.org>
18370         * emit-rtl.c (gen_raw_REG): Adjust.
18371         * gengenrtl.c (gendef): Likewise.
18372         * rtl.c (rtx_alloc_stat): Remove _stat from name.
18373         * rtl.h (rtx_alloc): Remove macro.
18375 2017-07-28  Trevor Saunders  <tbsaunde+gcc@tbsaunde.org>
18377         * tree.c (build_tree_list_vec_stat): Remove _stat from name.
18378         (build_tree_list_stat): Likewise.
18379         * tree.h (build_tree_list): Remove macro.
18380         (build_tree_list_vec): Likewise.
18382 2017-07-28  Trevor Saunders  <tbsaunde+gcc@tbsaunde.org>
18384         * tree.c (make_vector_stat): Remove _stat from name.
18385         (build_vector_stat): Likewise.
18386         * tree.h (make_vector_stat): Remove macro.
18387         (build_vector_stat): Likewise.
18389 2017-07-28  Trevor Saunders  <tbsaunde+gcc@tbsaunde.org>
18391         * tree.h (build_var_debug_value): Remove prototype.
18393 2017-07-28  Trevor Saunders  <tbsaunde+gcc@tbsaunde.org>
18395         * tree.c (tree_cons_stat): Remove _stat from name.
18396         * tree.h (tree_cons): Remove macro.
18398 2017-07-28  Trevor Saunders  <tbsaunde+gcc@tbsaunde.org>
18400         * tree.c (build_vl_exp_stat): Remove _stat from name.
18401         * tree.h (build_vl_exp): Remove macro.
18403 2017-07-28  Trevor Saunders  <tbsaunde+gcc@tbsaunde.org>
18405         * tree.c (build_decl_stat): Remove _stat from name.
18406         * tree.h (build_decl): Remove macro.
18408 2017-07-28  Trevor Saunders  <tbsaunde+gcc@tbsaunde.org>
18410         * gimple.c (gimple_build_with_ops_stat): Adjust.
18411         (gimple_alloc_stat): Remove _stat from name.
18412         * gimple.h (gimple_alloc): Remove macro.
18414 2017-07-28  Trevor Saunders  <tbsaunde+gcc@tbsaunde.org>
18416         * tree.c (make_tree_vec_stat): Remove _stat from name.
18417         (grow_tree_vec_stat): Likewise.
18418         * tree.h (make_tree_vec_stat): Adjust prototype.
18419         (grow_tree_vec_stat): Likewise.
18420         (make_tree_vec): Remove macro.
18421         (grow_tree_vec): Likewise.
18423 2017-07-28  Trevor Saunders  <tbsaunde+gcc@tbsaunde.org>
18425         * fold-const.c (fold_build1_stat_loc): Adjust.
18426         (fold_build2_stat_loc): Likewise.
18427         (fold_build3_stat_loc): Likewise.
18428         * tree.c (build0_stat): Remove _stat from name.
18429         (build1_stat): Likewise.
18430         (build2_stat): Likewise.
18431         (build3_stat): Likewise.
18432         (build4_stat): Likewise.
18433         (build5_stat): Likewise.
18434         * tree.h (build1_loc): Remove macro, and rename _stat function
18435         to this.
18436         (build2_loc): Likewise.
18437         (build3_loc): Likewise.
18438         (build4_loc): Likewise.
18439         (build5_loc): Likewise.
18441 2017-07-28  Trevor Saunders  <tbsaunde+gcc@tbsaunde.org>
18443         * tree.c (make_int_cst_stat): Remove _stat from name.
18444         * tree.h (make_int_cst_stat): Adjust prototype.
18445         (make_int_cst): Remove macro.
18447 2017-07-28  Trevor Saunders  <tbsaunde+gcc@tbsaunde.org>
18449         * tree.c (make_tre_binfo_stat): Remove _stat from name.
18450         * tree.h (make_tree_binfo_stat): Adjust prototype.
18451         (make_tree_binfo): Remove.
18453 2017-07-28  Trevor Saunders  <tbsaunde+gcc@tbsaunde.org>
18455         * tree.c (copy_node_stat): Rename to copy_node.
18456         (build_distinct_type_copy): Adjust.
18457         * tree.h (copy_node_stat): Adjust prototype.
18458         (copy_node): Remove macro.
18460 2017-07-28  Trevor Saunders  <tbsaunde+gcc@tbsaunde.org>
18462         * tree.c (make_node_stat): rename to make_node.
18463         (build_tree_list_stat): Adjust.
18464         (build0_stat): Likewise.
18465         (build2_stat): Likewise.
18466         (build3_stat): Likewise.
18467         (build4_stat): Likewise.
18468         (build5_stat): Likewise.
18469         (build_decl_stat): Likewise.
18470         * tree.h (make_node_stat): Adjust prototype.
18471         (make_node): remove macro.
18473 2017-07-28  Peter Bergner  <bergner@vnet.ibm.com>
18475         * config/rs6000/ppc-auxv.h (PPC_FEATURE2_DARN): New define.
18476         (PPC_FEATURE2_SCV): Likewise.
18477         * config/rs6000/rs6000.c (cpu_supports_info): Use them.
18479 2017-07-28  Tamar Christina  <tamar.christina@arm.com>
18481         * config/aarch64/aarch64.c
18482         (aarch64_internal_mov_immediate): Add new special pattern.
18483         * config/aarch64/aarch64.md (*movdi_aarch64):
18484         Add reg/32bit const mov case.
18486 2017-07-28  Tamar Christina  <tamar.christina@arm.com>
18487             Richard Sandiford <richard.sandiford@linaro.org>
18489         * config/aarch64/aarch64.md (mov<mode>): Generalize.
18490         (*movhf_aarch64, *movsf_aarch64, *movdf_aarch64):
18491         Add integer and movi cases.
18492         (movi-split-hf-df-sf split, fp16): New.
18493         (enabled): Added TARGET_FP_F16INST.
18494         * config/aarch64/iterators.md (GPF_HF): New.
18495         * config/aarch64/predicates.md (aarch64_reg_or_fp_float): New.
18497 2017-07-28  Tamar Christina  <tamar.christina@arm.com>
18499         * config/aarch64/aarch64.c
18500         (aarch64_simd_container_mode): Add prototype.
18501         (aarch64_expand_mov_immediate): Add HI support.
18502         (aarch64_reinterpret_float_as_int, aarch64_float_const_rtx_p: New.
18503         (aarch64_can_const_movi_rtx_p): New.
18504         (aarch64_preferred_reload_class):
18505         Remove restrictions of using FP registers for certain SIMD operations.
18506         (aarch64_rtx_costs): Added new cost for CONST_DOUBLE moves.
18507         (aarch64_valid_floating_const): Add integer move validation.
18508         (aarch64_simd_imm_scalar_p): Remove.
18509         (aarch64_output_scalar_simd_mov_immediate): Generalize function.
18510         (aarch64_legitimate_constant_p): Expand list of supported cases.
18511         * config/aarch64/aarch64-protos.h
18512         (aarch64_float_const_rtx_p, aarch64_can_const_movi_rtx_p): New.
18513         (aarch64_reinterpret_float_as_int): New.
18514         (aarch64_simd_imm_scalar_p): Remove.
18515         * config/aarch64/constraints.md (Uvi): New.
18516         (Dd): Split into Ds and new Dd.
18517         * config/aarch64/aarch64.md (*movsi_aarch64):
18518         Add SIMD mov case.
18519         (*movdi_aarch64): Add SIMD mov case.
18521 2017-07-28  Bin Cheng  <bin.cheng@arm.com>
18523         * tree-predcom.c: (struct chain): Handle store-store chain in which
18524         stores for elimination only store loop invariant values.
18525         (execute_pred_commoning_chain): Ditto.
18526         (prepare_initializers_chain_store_elim): Ditto.
18527         (prepare_finalizers): Ditto.
18528         (is_inv_store_elimination_chain): New function.
18529         (initialize_root_vars_store_elim_1): New function.
18531 2017-07-28  Bin Cheng  <bin.cheng@arm.com>
18533         * tree-predcom.c: Revise general description of the pass.
18534         (enum chain_type): New enum type for store elimination.
18535         (struct chain): New field supporting store elimination.
18536         (struct component): Ditto.
18537         (dump_chain): Dump store-stores chain.
18538         (release_chain): Release resources.
18539         (split_data_refs_to_components): Compute and create component
18540         contains only stores for elimination.
18541         (get_chain_last_ref_at): New function.
18542         (make_invariant_chain): Initialization.
18543         (make_rooted_chain): Specify chain type in parameter and record it.
18544         (add_looparound_copies): Skip for store-stores chain.
18545         (determine_roots_comp): Compute type of chain and pass it to
18546         make_rooted_chain.
18547         (initialize_root_vars_store_elim_2): New function.
18548         (finalize_eliminated_stores): New function.
18549         (remove_stmt): Handle store for elimination.
18550         (execute_pred_commoning_chain): Execute predictive commoning on
18551         store-store chains.
18552         (determine_unroll_factor): Skip unroll for store-stores chain.
18553         (prepare_initializers_chain_store_elim): New function.
18554         (prepare_initializers_chain): Hanlde store-store chain.
18555         (prepare_finalizers_chain, prepare_finalizers): New function.
18556         (tree_predictive_commoning_loop): Return integer value indicating
18557         if loop is unrolled or lcssa form is corrupted.
18558         (tree_predictive_commoning): Rewrite for lcssa form if necessary.
18560 2017-07-28  Bin Cheng  <bin.cheng@arm.com>
18562         * tree-predcom.c (initialize_root): Delete.
18563         (execute_pred_commoning_chain): Initialize root vars and replace
18564         reference of non-combined chain directly, rather than call above
18565         function.
18567 2017-07-28  Bin Cheng  <bin.cheng@arm.com>
18569         * tree-predcom.c (ref_at_iteration): Add parameter NITERS.  Compute
18570         memory reference to DR at (NITERS + ITERS)-th iteration of loop.
18572 2017-07-28  Bin Cheng  <bin.cheng@arm.com>
18574         * tree-predcom.c (struct chain): New field init_seq.
18575         (release_chain): Release init_seq.
18576         (prepare_initializers_chain): Record intialization stmts in above
18577         field.
18578         (insert_init_seqs): New function.
18579         (tree_predictive_commoning_loop): Call insert_init_seqs.
18581 2017-07-28  Bin Cheng  <bin.cheng@arm.com>
18583         * tree-predcom.c (determine_roots_comp): Skip trivial components.
18585 2017-07-28  Richard Biener  <rguenther@suse.de>
18587         * match.pd: Remove superfluous :c.
18588         * genmatch.c (simplify::id): Add member.
18589         (lower_commutative, lower_opt_convert, lower_cond, lower_for):
18590         Copy id.
18591         (current_id): New global.
18592         (dt_node::parent): Move from ...
18593         (dt_operand::parent): ... here.  Add for_id member.
18594         (is_a_helper <dt_operand *>::test): DT_TRUE is also a dt_operand.
18595         (decision_tree::find_node): Relax order requirement when
18596         merging DT_TRUE nodes to ones inbetween the current simplify
18597         and the one we try to merge with.  Add diagnostic whenever
18598         we need to enforce pattern order by not merging.
18599         (decision_tree::insert): Set current_id.
18600         (decision_tree::print_node): Dump parent node and for_id.
18601         (parser::last_id): Add member.
18602         (parser::push_simplify): Assign unique id.
18603         (parser::parser): Initialize last_id.
18605 2017-07-28  Martin Liska  <mliska@suse.cz>
18607         PR sanitizer/81340
18608         * sanopt.c (sanitize_rewrite_addressable_params): Set VALUE_EXPR after
18609         gimple_build_debug_bind.
18611 2017-07-28  Richard Biener  <rguenther@suse.de>
18613         PR tree-optimization/81502
18614         * match.pd: Add pattern combining BIT_INSERT_EXPR with
18615         BIT_FIELD_REF.
18616         * tree-cfg.c (verify_expr): Verify types of BIT_FIELD_REF
18617         size/pos operands.
18618         (verify_gimple_assign_ternary): Likewise for BIT_INSERT_EXPR pos.
18619         * gimple-fold.c (maybe_canonicalize_mem_ref_addr): Use bitsizetype
18620         for BIT_FIELD_REF args.
18621         * fold-const.c (make_bit_field_ref): Likewise.
18622         * tree-vect-stmts.c (vectorizable_simd_clone_call): Likewise.
18624 2017-07-28  Jakub Jelinek  <jakub@redhat.com>
18626         PR sanitizer/80998
18627         * sanopt.c (pass_sanopt::execute): Handle IFN_UBSAN_PTR.
18628         * tree-ssa-alias.c (call_may_clobber_ref_p_1): Likewise.
18629         * flag-types.h (enum sanitize_code): Add SANITIZER_POINTER_OVERFLOW.
18630         Or it into SANITIZER_UNDEFINED.
18631         * ubsan.c: Include gimple-fold.h and varasm.h.
18632         (ubsan_expand_ptr_ifn): New function.
18633         (instrument_pointer_overflow): New function.
18634         (maybe_instrument_pointer_overflow): New function.
18635         (instrument_object_size): Formatting fix.
18636         (pass_ubsan::execute): Call instrument_pointer_overflow
18637         and maybe_instrument_pointer_overflow.
18638         * internal-fn.c (expand_UBSAN_PTR): New function.
18639         * ubsan.h (ubsan_expand_ptr_ifn): Declare.
18640         * sanitizer.def (__ubsan_handle_pointer_overflow,
18641         __ubsan_handle_pointer_overflow_abort): New builtins.
18642         * tree-ssa-tail-merge.c (merge_stmts_p): Handle IFN_UBSAN_PTR.
18643         * internal-fn.def (UBSAN_PTR): New internal function.
18644         * opts.c (sanitizer_opts): Add pointer-overflow.
18645         * lto-streamer-in.c (input_function): Handle IFN_UBSAN_PTR.
18646         * fold-const.c (build_range_check): Compute pointer range check in
18647         integral type if pointer arithmetics would be needed.  Formatting
18648         fixes.
18650 2017-07-28  Martin Liska  <mliska@suse.cz>
18652         PR sanitizer/81460
18653         * sanopt.c (sanitize_rewrite_addressable_params): Do not rewrite
18654         parameters that are of a variable-length.
18656 2017-07-28  Sebastian Huber  <sebastian.huber@embedded-brains.de>
18658         * config.gcc (powerpc-*-rtems*): Remove rs6000/eabi.h.  Add
18659         rs6000/biarch64.h.
18660         * config/rs6000/rtems.h (ASM_DECLARE_FUNCTION_SIZE): New macro.
18661         (ASM_OUTPUT_SPECIAL_POOL_ENTRY_P): Likewise.
18662         (CRT_CALL_STATIC_FUNCTION): Likewise.
18663         (ASM_DEFAULT_SPEC): New define.
18664         (ASM_SPEC32): Likewise.
18665         (ASM_SPEC64): Likewise.
18666         (ASM_SPEC_COMMON): Likewise.
18667         (ASM_SPEC): Likewise.
18668         (INVALID_64BIT): Likewise.
18669         (LINK_OS_DEFAULT_SPEC): Likewise.
18670         (LINK_OS_SPEC32): Likewise.
18671         (LINK_OS_SPEC64): Likewise.
18672         (POWERPC_LINUX): Likewise.
18673         (PTRDIFF_TYPE): Likewise.
18674         (RESTORE_FP_PREFIX): Likewise.
18675         (RESTORE_FP_SUFFIX): Likewise.
18676         (SAVE_FP_PREFIX): Likewise.
18677         (SAVE_FP_SUFFIX): Likewise.
18678         (SIZE_TYPE): Likewise.
18679         (SUBSUBTARGET_OVERRIDE_OPTIONS): Likewise.
18680         (TARGET_64BIT): Likewise.
18681         (TARGET_64BIT): Likewise.
18682         (TARGET_AIX): Likewise.
18683         (WCHAR_TYPE_SIZE): Likewise.
18684         (WCHAR_TYPE): Undefine.
18685         (TARGET_OS_CPP_BUILTINS): Add 64-bit PowerPC defines.
18686         (CPP_OS_DEFAULT_SPEC): Use previous CPP_OS_RTEMS_SPEC.
18687         (CPP_OS_RTEMS_SPEC): Delete.
18688         (SUBSUBTARGET_EXTRA_SPECS): Remove cpp_os_rtems.  Add
18689         asm_spec_common, asm_spec32, asm_spec64, link_os_spec32, and
18690         link_os_spec64.
18691         * config/rs6000/t-rtems: Add mcpu=e6500/m64 multilibs.
18693 2017-07-28  Jakub Jelinek  <jakub@redhat.com>
18695         PR tree-optimization/81578
18696         * tree-parloops.c (build_new_reduction): Bail out if
18697         reduction_code isn't one of the standard OpenMP reductions.
18698         Move the details printing after that decision.
18700 2017-07-27  Peter Bergner  <bergner@vnet.ibm.com>
18702         * config/rs6000/predicates.md (volatile_mem_operand): Remove code
18703         related to reload_in_progress.
18704         (splat_input_operand): Likewise.
18705         * config/rs6000/rs6000-protos.h (rs6000_secondary_memory_needed_rtx):
18706         Delete prototype.
18707         * config/rs6000/rs6000.c (machine_function): Remove sdmode_stack_slot
18708         field.
18709         (TARGET_EXPAND_TO_RTL_HOOK): Delete.
18710         (TARGET_INSTANTIATE_DECLS): Likewise.
18711         (legitimate_indexed_address_p): Delete reload_in_progress code.
18712         (rs6000_debug_legitimate_address_p): Likewise.
18713         (rs6000_eliminate_indexed_memrefs): Likewise.
18714         (rs6000_emit_le_vsx_store): Likewise.
18715         (rs6000_emit_move_si_sf_subreg): Likewise.
18716         (rs6000_emit_move): Likewise.
18717         (register_to_reg_type): Likewise.
18718         (rs6000_pre_atomic_barrier): Likewise.
18719         (rs6000_machopic_legitimize_pic_address): Likewise.
18720         (rs6000_allocate_stack_temp): Likewise.
18721         (rs6000_address_for_fpconvert): Likewise.
18722         (rs6000_address_for_altivec): Likewise.
18723         (rs6000_secondary_memory_needed_rtx): Delete function.
18724         (rs6000_check_sdmode): Likewise.
18725         (rs6000_alloc_sdmode_stack_slot): Likewise.
18726         (rs6000_instantiate_decls): Likewise.
18727         * config/rs6000/rs6000.h (SECONDARY_MEMORY_NEEDED_RTX): Delete.
18728         * config/rs6000/rs6000.md (splitter for *movsi_got_internal):
18729         Delete reload_in_progress.
18730         (*vec_reload_and_plus_<mptrsize>): Likewise.
18731         * config/rs6000/vsx.md (vsx_mul_v2di): Likewise.
18732         (vsx_div_v2di): Likewise.
18733         (vsx_udiv_v2di): Likewise.
18735 2017-07-27  Peter Bergner  <bergner@vnet.ibm.com>
18737         * config/rs6000/rs6000.opt (mlra): Replace with stub.
18738         * config/rs6000/rs6000-cpus.def (POWERPC_MASKS): Delete OPTION_MASK_LRA.
18739         * config/rs6000/rs6000.c (TARGET_LRA_P): Delete.
18740         (rs6000_debug_reg_global): Delete print of LRA status.
18741         (rs6000_option_override_internal): Delete dead LRA related code.
18742         (rs6000_lra_p): Delete function.
18743         * doc/invoke.texi (RS/6000 and PowerPC Options): Delete -mlra.
18745 2017-07-27  Sebastian Huber  <sebastian.huber@embedded-brains.de>
18747         * config.gcc (riscv*-*-elf*): Add (riscv*-*-rtems*).
18748         * config/riscv/rtems.h: New file.
18750 2017-07-27  Kyrylo Tkachov  <kyrylo.tkachov@arm.com>
18751             Sudakshina Das  <sudi.das@arm.com>
18753         * config/aarch64/aarch64.md
18754         (define_split for and<mode>3nr_compare): Move
18755         non aarch64_logical_operand to a register.
18756         (define_split for and_<SHIFT:optab><mode>3nr_compare0): Move non
18757         register immediate operand to a register.
18758         * config/aarch64/predicates.md (aarch64_mov_imm_operand): New.
18760 2017-07-27  Peter Bergner  <bergner@vnet.ibm.com>
18762         PR middle-end/81564
18763         * tree-cfg.c (group_case_labels_stmt): Handle already deleted blocks.
18765 2017-07-27  Richard Biener  <rguenther@suse.de>
18767         PR tree-optimization/81573
18768         PR tree-optimization/81494
18769         * tree-vect-loop.c (vect_create_epilog_for_reduction): Handle
18770         multi defuse cycle case.
18772 2017-07-27  Richard Biener  <rguenther@suse.de>
18774         PR tree-optimization/81571
18775         * tree-vect-slp.c (vect_build_slp_tree): Properly verify reduction
18776         PHIs.
18778 2017-07-27  Eric Botcazou  <ebotcazou@adacore.com>
18780         * config/sparc/sparc.c (sparc_option_override): Set MASK_FSMULD flag
18781         earlier and only if MASK_FPU is set.  Adjust formatting.
18783 2017-07-27  Martin Liska  <mliska@suse.cz>
18785         * opt-functions.awk: Add validation of value of Init.
18786         * optc-gen.awk: Pass new argument.
18788 2017-07-27  Martin Liska  <mliska@suse.cz>
18790         * auto-profile.c (autofdo_source_profile::update_inlined_ind_target):
18791         Fix wrong condition.
18793 2017-07-27  Martin Liska  <mliska@suse.cz>
18795         * auto-profile.c (afdo_annotate_cfg): Assign zero counts to
18796         BBs and edges seen by autoFDO.
18798 2017-07-27  Richard Biener  <rguenther@suse.de>
18800         PR tree-optimization/81502
18801         * tree-ssa.c (non_rewritable_lvalue_p): Handle BIT_INSERT_EXPR
18802         with incompatible but same sized type.
18803         (execute_update_addresses_taken): Likewise.
18805 2017-07-27  James Greenhalgh  <james.greenhalgh@arm.com>
18807         * tree-ssa-loop-ch.c (pass_ch::process_loop_p): Guard on
18808         flag_tree_loop_vectorize rather than flag_tree_vectorize.
18810 2017-07-27  Andreas Krebbel  <krebbel@linux.vnet.ibm.com>
18812         PR target/81534
18813         * config/s390/s390.md ("*atomic_compare_and_swap<mode>_1")
18814         ("*atomic_compare_and_swapdi_2", "*atomic_compare_and_swapsi_3"):
18815         Change s_operand to memory_operand.
18817 2017-07-27  Richard Sandiford  <richard.sandiford@linaro.org>
18819         * config/rs6000/rs6000-protos.h (rs6000_emit_le_vsx_permute): Declare.
18820         * config/rs6000/rs6000.c (rs6000_gen_le_vsx_permute): Replace with...
18821         (rs6000_emit_le_vsx_permute): ...this.  Take the destination as input.
18822         Emit instructions rather than returning an expression.  Handle TFmode
18823         and KFmode by casting to TImode.
18824         (rs6000_emit_le_vsx_load): Update to use rs6000_emit_le_vsx_permute.
18825         (rs6000_emit_le_vsx_store): Likewise.
18826         * config/rs6000/vsx.md (VSX_TI): New iterator.
18827         (*vsx_le_permute_<mode>): Use it instead of VSX_LE_128.
18828         (*vsx_le_undo_permute_<mode>): Likewise.
18829         (*vsx_le_perm_load_<mode>): Use rs6000_emit_le_vsx_permute to
18830         emit the split sequence.
18831         (*vsx_le_perm_store_<mode>): Likewise.
18833 2017-07-27  Jakub Jelinek  <jakub@redhat.com>
18835         PR tree-optimization/81555
18836         PR tree-optimization/81556
18837         * tree-ssa-reassoc.c (rewrite_expr_tree): Add NEXT_CHANGED argument,
18838         if true, force CHANGED for the recursive invocation.
18839         (reassociate_bb): Remember original length of ops array, pass
18840         len != orig_len as NEXT_CHANGED in rewrite_expr_tree call.
18842         * attribs.c (decl_attributes): Imply noinline, noclone and no_icf
18843         attributes for noipa attribute.  For naked attribute use
18844         lookup_attribute first before lookup_attribute_spec.
18845         * final.c (rest_of_handle_final): Disable IPA RA for functions with
18846         noipa attribute.
18847         * ipa-visibility.c (non_local_p): Fix comment typos.  Return true
18848         for functions with noipa attribute.
18849         (cgraph_externally_visible_p): Return true for functions with noipa
18850         attribute.
18851         * cgraph.c (cgraph_node::get_availability): Return AVAIL_INTERPOSABLE
18852         for functions with noipa attribute.
18853         * doc/extend.texi: Document noipa function attribute.
18854         * tree-ssa-structalias.c (refered_from_nonlocal_fn): Set *nonlocal_p
18855         also for functions with noipa attribute.
18856         (ipa_pta_execute): Set nonlocal_p also for nodes with noipa attribute.
18858 2017-07-26  Andrew Pinski  <apinski@cavium.com>
18860         * config/aarch64/aarch64.c (thunderx_vector_cost): Decrease cost of
18861         vec_unalign_load_cost and vec_unalign_store_cost.
18863 2017-07-26  Michael Meissner  <meissner@linux.vnet.ibm.com>
18865         * config/rs6000/rs6000-cpus.def (ISA_2_7_MASKS_SERVER): Delete
18866         -mvsx-small-integer option.
18867         (ISA_3_0_MASKS_IEEE): Likewise.
18868         (OTHER_VSX_VECTOR_MASKS): Likewise.
18869         (POWERPC_MASKS): Likewise.
18870         * config/rs6000/rs6000.opt (-mvsx-small-integer): Likewise.
18871         * config/rs6000/rs6000.c (rs6000_hard_regno_mode_ok): Simplify
18872         code, only testing for DImode being allowed in non-VSX floating
18873         point registers.
18874         (rs6000_init_hard_regno_mode_ok): Change TARGET_VSX_SMALL_INTEGER
18875         to TARGET_P8_VECTOR test.  Remove redundant VSX test inside of
18876         another VSX test.
18877         (rs6000_option_override_internal): Delete -mvsx-small-integer.
18878         (rs6000_expand_vector_set): Change TARGET_VSX_SMALL_INTEGER to
18879         TARGET_P8_VECTOR test.
18880         (rs6000_secondary_reload_simple_move): Likewise.
18881         (rs6000_preferred_reload_class): Delete TARGET_VSX_SMALL_INTEGER,
18882         since TARGET_P9_VECTOR was already tested.
18883         (rs6000_opt_masks): Remove -mvsx-small-integer.
18884         * config/rs6000/vsx.md (vsx_extract_<mode>): Delete
18885         TARGET_VSX_SMALL_INTEGER, since a test for TARGET_P9_VECTOR was
18886         used.
18887         (vsx_extract_<mode>_p9): Delete TARGET_VSX_SMALL_INTEGER, since a
18888         test for TARGET_VEXTRACTUB was used, and that uses
18889         TARGET_P9_VECTOR.
18890         (p9 extract splitter): Likewise.
18891         (vsx_extract_<mode>_di_p9): Likewise.
18892         (vsx_extract_<mode>_store_p9): Likewise.
18893         (vsx_extract_si): Delete TARGET_VSX_SMALL_INTEGER, since a test
18894         for TARGET_P9_VECTOR was used.  Delete code that is now dead with
18895         the elimination of TARGET_VSX_SMALL_INTEGER.
18896         (vsx_extract_<mode>_p8): Likewise.
18897         (vsx_ext_<VSX_EXTRACT_I:VS_scalar>_fl_<FL_CONV:mode>): Likewise.
18898         (vsx_ext_<VSX_EXTRACT_I:VS_scalar>_ufl_<FL_CONV:mode>): Likewise.
18899         (vsx_set_<mode>_p9): Likewise.
18900         (vsx_set_v4sf_p9): Likewise.
18901         (vsx_set_v4sf_p9_zero): Likewise.
18902         (vsx_insert_extract_v4sf_p9): Likewise.
18903         (vsx_insert_extract_v4sf_p9_2): Likewise.
18904         * config/rs6000/rs6000.md (sign extend splitter): Change
18905         TARGET_VSX_SMALL_INTEGER to TARGET_P8_VECTOR test.
18906         (floatsi<mode>2_lfiwax_mem): Likewise.
18907         (floatunssi<mode>2_lfiwzx_mem): Likewise.
18908         (float<QHI:mode><FP_ISA3:mode>2): Delete TARGET_VSX_SMALL_INTEGER,
18909         since a test for TARGET_P9_VECTOR was used.
18910         (float<QHI:mode><FP_ISA3:mode>2_internal): Likewise.
18911         (floatuns<QHI:mode><FP_ISA3:mode>2): Likewise.
18912         (floatuns<QHI:mode><FP_ISA3:mode>2_internal): Likewise.
18913         (fix_trunc<mode>si2): Change TARGET_VSX_SMALL_INTEGER to
18914         TARGET_P8_VECTOR test.
18915         (fix_trunc<mode>si2_stfiwx): Likewise.
18916         (fix_trunc<mode>si2_internal): Likewise.
18917         (fix_trunc<SFDF:mode><QHI:mode>2): Delete
18918         TARGET_VSX_SMALL_INTEGER, since a test for TARGET_P9_VECTOR was
18919         used.
18920         (fix_trunc<SFDF:mode><QHI:mode>2_internal): Likewise.
18921         (fixuns_trunc<mode>si2): Change TARGET_VSX_SMALL_INTEGER to
18922         TARGET_P8_VECTOR test.
18923         (fixuns_trunc<mode>si2_stfiwx): Likewise.
18924         (fixuns_trunc<SFDF:mode><QHI:mode>2): Delete
18925         TARGET_VSX_SMALL_INTEGER, since a test for TARGET_P9_VECTOR was
18926         used.
18927         (fixuns_trunc<SFDF:mode><QHI:mode>2_internal): Likewise.
18928         (fctiw<u>z_<mode>_smallint): Delete TARGET_VSX_SMALL_INTEGER,
18929         since a test for TARGET_P9_VECTOR was used.
18930         (splitter for loading small constants): Likewise.
18932 2017-07-26  Andrew Pinski  <apinski@cavium.com>
18934         * config/aarch64/aarch64.c (thunderx_vector_cost): Fix
18935         vec_fp_stmt_cost.
18937 2017-07-26  H.J. Lu  <hongjiu.lu@intel.com>
18939         PR target/81563
18940         * config/i386/i386.c (sp_valid_at): Properly check CFA offset.
18941         (fp_valid_at): Likewise.
18943 2017-07-26  James Greenhalgh  <james.greenhalgh@arm.com>
18945         * config/aarch64/aarch64.c (cortexa57_addrcost_table): Remove.
18946         (qdf24xx_addrcost_table): Likewise.
18947         (cortexa57_tunings): Update to use generic_branch_cost.
18948         (cortexa72_tunings): Likewise.
18949         (cortexa73_tunings): Likewise.
18950         (qdf24xx_tunings): Likewise.
18952 2017-07-26  James Greenhalgh  <james.greenhalgh@arm.com>
18954         * config/aarch64/aarch64.c (cortexa57_branch_cost): Remove.
18955         (thunderx2t99_branch_cost): Likewise.
18956         (cortexa35_tunings): Update to use generic_branch_cost.
18957         (cortexa53_tunings): Likewise.
18958         (cortexa57_tunings): Likewise.
18959         (cortexa72_tunings): Likewise.
18960         (cortexa73_tunings): Likewise.
18961         (thunderx2t99_tunings): Likewise.
18963 2017-07-26  Sebastian Huber  <sebastian.huber@embedded-brains.de>
18965         * config/sparc/sparc.c (dump_target_flag_bits): Dump MASK_FSMULD.
18966         (sparc_option_override): Honour MASK_FSMULD.
18967         * config/sparc/sparc.h (MASK_FEATURES): Add MASK_FSMULD.
18968         * config/sparc/sparc.md (muldf3_extend): Use TARGET_FSMULD.
18969         * config/sparc/sparc.opt (mfsmuld): New option.
18970         * doc/invoke.texi (mfsmuld): Document option.
18972 2017-07-26  Marek Polacek  <polacek@redhat.com>
18974         PR middle-end/70992
18975         * tree.c (build2_stat): Don't set TREE_CONSTANT on divisions by zero.
18977 2017-07-26  Richard Biener  <rguenther@suse.de>
18979         * gimple-match-head.c (do_valueize): Return OP if valueize
18980         returns NULL_TREE.
18981         (get_def): New helper to get at the def stmt of a SSA name
18982         if valueize allows.
18983         * genmatch.c (dt_node::gen_kids_1): Use get_def instead of
18984         do_valueize to get at the def stmt.
18985         (dt_operand::gen_gimple_expr): Simplify do_valueize calls.
18987 2017-07-26  Wilco Dijkstra  <wdijkstr@arm.com>
18989         PR middle-end/46932
18990         * auto-inc-dec.c (parse_add_or_inc): Block autoinc on sfp.
18992 2017-07-26  Martin Liska  <mliska@suse.cz>
18994         PR sanitize/81186
18995         * function.c (expand_function_start): Make expansion of
18996         nonlocal_goto_save_area after parm_birth_insn.
18998 2017-07-26  Sebastian Huber  <sebastian.huber@embedded-brains.de>
19000         * config/sparc/sparc.c (sparc_option_override): Remove MASK_FPU
19001         from all CPU target flags enable members.
19003 2017-07-26  Richard Biener  <rguenther@suse.de>
19005         * genmatch.c (dt_simplify::gen): Make iterator vars const.
19006         (decision_tree::gen): Make 'type' const.
19007         (write_predicate): Likewise.
19009 2017-07-24  Michael Meissner  <meissner@linux.vnet.ibm.com>
19011         * config/rs6000/rs6000.c (rs6000_init_hard_regno_mode_ok):
19012         Eliminate TARGET_UPPER_REGS_{DF,DI,SF} usage.
19013         (rs6000_option_override_internal): Likewise.
19014         (rs6000_expand_vector_set): Likewise.
19015         * config/rs6000/rs6000.h (TARGET_UPPER_REGS_DF): Delete.
19016         (TARGET_UPPER_REGS_SF): Likewise.
19017         (TARGET_UPPER_REGS_DI): Likewise.
19018         (TARGET_VEXTRACTUB): Eliminate TARGET_UPPER_REGS_{DF,DI,SF}.
19019         (TARGET_DIRECT_MOVE_64BIT): Likewise.
19020         * config/rs6000/rs6000.md (ALTIVEC_DFORM): Likewise.
19021         (float<QHI:mode><FP_ISA3:mode>2_internal): Likewise.
19022         (Splitters for DI constants in Altivec registers): Likewise.
19023         * config/rs6000/vsx.md (vsx_set_<mode>_p9): Likewise.
19024         (vsx_set_v4sf_p9): Likewise.
19025         (vsx_set_v4sf_p9_zero): Likewise.
19026         (vsx_insert_extract_v4sf_p9): Likewise.
19027         (vsx_insert_extract_v4sf_p9_2): Likewise.
19029 2017-07-25  Carl Love  <cel@us.ibm.com>
19031         * doc/extend.texi: Update the built-in documentation file for the
19032         existing built-in functions
19033         vector signed char vec_cnttz (vector signed char);
19034         vector unsigned char vec_cnttz (vector unsigned char);
19035         vector signed short vec_cnttz (vector signed short);
19036         vector unsigned short vec_cnttz (vector unsigned short);
19037         vector signed int vec_cnttz (vector signed int);
19038         vector unsigned int vec_cnttz (vector unsigned int);
19039         vector signed long long vec_cnttz (vector signed long long);
19040         vector unsigned long long vec_cnttz (vector unsigned long long);
19042 2017-07-25  Andrew Pinski  <apinski@cavium.com>
19044         * tree-ssa-uninit.c (warn_uninitialized_vars): Don't warn about memory
19045         accesses where the use is for the first operand of a BIT_INSERT.
19047 2017-07-25  Jim Wilson  <jim.wilson@linaro.org>
19049         PR bootstrap/81521
19050         * config/i386/winnt-cxx.c (i386_pe_adjust_class_at_definition): Look
19051         for FUNCTION_DECLs in TYPE_FIELDS rather than TYPE_METHODS.
19053 2017-07-25  Jim Wilson  <jim.wilson@linaro.org>
19055         * config/i386/gstabs.h: Delete.
19056         * config/i386/openbsd.h, config/i386/t-openbsd: Likewise.
19058 2017-07-25  Uros Bizjak  <ubizjak@gmail.com>
19060         * config/i386/i386.c (ix86_decompose_address): Do not check for
19061         register RTX when looking at index_reg or base_reg.
19062         * config/i386/i386.h (INCOMING_RETURN_ADDR_RTX): Use stack_pointer_rtx.
19064 2017-07-25  Eric Botcazou  <ebotcazou@adacore.com>
19066         * gimple.c (gimple_assign_set_rhs_with_ops): Do not ask gsi_replace
19067         to update EH info here.
19069 2017-07-25  Alexander Monakov  <amonakov@ispras.ru>
19071         * match.pd ((X * CST1) * CST2): Simplify to X * (CST1 * CST2).
19073 2017-07-25  Alexander Monakov  <amonakov@ispras.ru>
19075         * match.pd ((X * CST) * Y): Reassociate to (X * Y) * CST.
19077 2017-07-25  Torsten Duwe  <duwe@suse.de>
19079         * common.opt: Introduce -fpatchable-function-entry
19080         command line option, and its variables function_entry_patch_area_size
19081         and function_entry_patch_area_start.
19082         * opts.c (common_handle_option): Add -fpatchable_function_entry_ case,
19083         including a two-value parser.
19084         * target.def (print_patchable_function_entry): New target hook.
19085         * targhooks.h (default_print_patchable_function_entry): New function.
19086         * targhooks.c (default_print_patchable_function_entry): Likewise.
19087         * toplev.c (process_options): Switch off IPA-RA if
19088         patchable function entries are being generated.
19089         * varasm.c (assemble_start_function): Look at the
19090         patchable-function-entry command line switch and current
19091         function attributes and maybe generate NOP instructions by
19092         calling the print_patchable_function_entry hook.
19093         * doc/extend.texi: Document patchable_function_entry attribute.
19094         * doc/invoke.texi: Document -fpatchable_function_entry
19095         command line option.
19096         * doc/tm.texi.in (TARGET_ASM_PRINT_PATCHABLE_FUNCTION_ENTRY):
19097         New target hook.
19098         * doc/tm.texi: Re-generate.
19100 2017-07-25  Jakub Jelinek  <jakub@redhat.com>
19102         PR target/81532
19103         * config/i386/constraints.md (Yd, Ye): Use ALL_SSE_REGS for
19104         TARGET_AVX512DQ rather than TARGET_AVX512BW.
19106 2017-07-25  Tamar Christina  <tamar.christina@arm.com>
19108         * config/arm/parsecpu.awk (all_cores): Remove duplicates.
19110 2017-07-25  Richard Biener  <rguenther@suse.de>
19112         PR tree-optimization/81455
19113         * tree-ssa-loop-unswitch.c (find_loop_guard): Make sure to
19114         not walk in cycles when looking for guards.
19116 2017-07-25  Richard Biener  <rguenther@suse.de>
19118         PR tree-optimization/81529
19119         * tree-vect-stmts.c (process_use): Disregard live induction PHIs
19120         when optimizing backedge uses.
19122 2017-07-25  David Edelsohn  <dje.gcc@gmail.com>
19124         * dwarf2asm.c (dw2_asm_output_nstring): Encode double quote
19125         character for AIX.
19126         * dwarf2out.c (output_macinfo): Copy debug_line_section_label
19127         to dl_section_ref.  On AIX, append an expression to subtract
19128         the size of the section length to dl_section_ref.
19130 2017-07-25  Segher Boessenkool  <segher@kernel.crashing.org>
19132         * configure.ac: If any of the config.* scripts fail, exit 1.
19133         * configure: Regenerate.
19135 2017-07-25  Richard Biener  <rguenther@suse.de>
19137         PR middle-end/81546
19138         * tree-ssa-operands.c (verify_imm_links): Remove cap on number
19139         of immediate uses, be more verbose on errors.
19141 2017-07-25  Richard Biener  <rguenther@suse.de>
19143         PR tree-optimization/81510
19144         * tree-vect-loop.c (vect_is_simple_reduction): When the
19145         reduction stmt is not inside the loop bail out.
19147 2017-07-25  Richard Biener  <rguenther@suse.de>
19149         PR tree-optimization/81303
19150         * tree-vect-loop-manip.c (vect_loop_versioning): Build
19151         profitability check against LOOP_VINFO_NITERSM1.
19153 2017-07-25  Alexander Monakov  <amonakov@ispras.ru>
19155         * domwalk.c (cmp_bb_postorder): Simplify.
19156         (sort_bbs_postorder): New function.  Use it...
19157         (dom_walker::walk): ...here to optimize common cases.
19159 2017-07-25  Martin Liska  <mliska@suse.cz>
19161         PR ipa/81520
19162         * ipa-visibility.c (function_and_variable_visibility): Make the
19163         redirection just on target that supports aliasing.
19164         Fix GNU coding style.
19166 2017-07-25  Sebastian Huber  <sebastian.huber@embedded-brains.de>
19168         PR libgcc/61152
19169         * config/aarch64/rtems.h: Add GCC Runtime Library Exception.
19170         Format changes.
19171         * config/arm/rtems.h: Likewise.
19172         * config/bfin/rtems.h: Likewise.
19173         * config/i386/rtemself.h: Likewise.
19174         * config/lm32/rtems.h: Likewise.
19175         * config/m32c/rtems.h: Likewise.
19176         * config/m68k/rtemself.h: Likewise.
19177         * config/microblaze/rtems.h: Likewise.
19178         * config/mips/rtems.h: Likewise.
19179         * config/moxie/rtems.h: Likewise.
19180         * config/nios2/rtems.h: Likewise.
19181         * config/powerpcspe/rtems.h: Likewise.
19182         * config/rs6000/rtems.h: Likewise.
19183         * config/rtems.h: Likewise.
19184         * config/sh/rtems.h: Likewise.
19185         * config/sh/rtemself.h: Likewise.
19186         * config/sparc/rtemself.h: Likewise.
19188 2017-07-25  Georg-Johann Lay  <avr@gjlay.de>
19190         PR 81487
19191         * hsa-brig.c (brig_init): Use xasprintf instead of asprintf.
19192         * gimple-pretty-print.c (dump_profile, dump_probability): Same.
19193         * tree-ssa-structalias.c (alias_get_name): Same.
19195 2017-07-25  Bin Cheng  <bin.cheng@arm.com>
19197         PR target/81414
19198         * config/aarch64/cortex-a57-fma-steering.c (analyze): Skip fmul/fmac
19199         instructions if no du chain is found.
19201 2017-07-25  Georg-Johann Lay  <avr@gjlay.de>
19203         * config/avr/avr-log.c (avr_log_vadump) ['T']: Print NULL-TREE.
19205 2017-07-25  Richard Biener  <rguenther@suse.de>
19207         PR middle-end/81505
19208         * fold-const.c (fold_negate_const): TREE_OVERFLOW should be
19209         sticky.
19211 2017-07-24  Michael Meissner  <meissner@linux.vnet.ibm.com>
19213         * config/rs6000/rs6000-cpus.def (ISA_2_6_MASKS_SERVER): Delete
19214         upper-regs options.
19215         (ISA_2_7_MASKS_SERVER): Likewise.
19216         (ISA_3_0_MASKS_IEEE): Likewise.
19217         (OTHER_P8_VECTOR_MASKS): Likewise.
19218         (OTHER_VSX_VECTOR_MASKS): Likewise.
19219         (POWERPC_MASKS): Likewise.
19220         (power7 cpu): Use ISA_2_6_MASKS_SERVER instead of using a
19221         duplicate list of options.
19222         * config/rs6000/rs6000-c.c (rs6000_target_modify_macros): Remove
19223         explicit -mupper-regs options.
19224         * config/rs6000/rs6000.opt (-mvsx-scalar-memory): Delete
19225         -mupper-regs* options.  Delete -mvsx-scalar-memory, which was an
19226         alias for -mupper-regs-df.
19227         * config/rs6000/rs6000.c (rs6000_setup_reg_addr_masks): Likewise.
19228         (rs6000_init_hard_regno_mode_ok): Likewise.
19229         (rs6000_option_override_internal): Likewise.
19230         (rs6000_opt_masks): Likewise.
19231         * config/rs6000/rs6000.h (TARGET_UPPER_REGS_DF): Define upper regs
19232         options in terms of whether -mvsx or -mpower8-vector was used.
19233         (TARGET_UPPER_REGS_DI): Likewise.
19234         (TARGET_UPPER_REGS_SF): Likewise.
19235         * doc/invoke.texi (RS/6000 and PowerPC Options): Delete the
19236         -mupper-regs-* options.
19238 2017-07-24  Segher Boessenkool  <segher@kernel.crashing.org>
19240         * passes.c (emergency_dump_function): Print some empty lines and a
19241         header before the RTL dump.
19243 2017-07-24  Segher Boessenkool  <segher@kernel.crashing.org>
19245         * cfgrtl.c (rtl_dump_bb): Don't call NEXT_INSN on NULL.
19247 2017-07-24  Wilco Dijkstra  <wdijkstr@arm.com>
19249         PR target/79041
19250         * config/aarch64/aarch64.c (aarch64_classify_symbol):
19251         Avoid SYMBOL_SMALL_ABSOLUTE for literals with pc-relative literals.
19253 2017-07-24  Carl Love  <cel@us.ibm.com>
19255         * config/rs6000/rs6000-c.c: Add support for built-in functions
19256         vector float vec_extract_fp32_from_shorth (vector unsigned short);
19257         vector float vec_extract_fp32_from_shortl (vector unsigned short);
19258         * config/rs6000/altivec.h (vec_extract_fp_from_shorth,
19259         vec_extract_fp_from_shortl): Add defines for the two builtins.
19260         * config/rs6000/rs6000-builtin.def (VEXTRACT_FP_FROM_SHORTH,
19261         VEXTRACT_FP_FROM_SHORTL): Add BU_P9V_OVERLOAD_1 and BU_P9V_VSX_1
19262         new builtins.
19263         * config/rs6000/vsx.md vsx_xvcvhpsp): Add define_insn.
19264         (vextract_fp_from_shorth, vextract_fp_from_shortl): Add define_expands.
19265         * doc/extend.texi: Update the built-in documentation file for the
19266         new built-in function.
19268 2017-07-24  Jakub Jelinek  <jakub@redhat.com>
19270         PR bootstrap/81521
19271         * tree.def: Remove TYPE_METHODS documentation, adjust TYPE_FIELDS
19272         documentation.
19273         * doc/generic.texi: Likewise.
19274         * config/i386/winnt-cxx.c (i386_pe_adjust_class_at_definition): Look
19275         for FUNCTION_DECLs in TYPE_FIELDS rather than TYPE_METHODS.
19277 2017-07-24  Jackson Woodruff  <jackson.woodruff@arm.com>
19279         * config/aarch64/aarch64-simd.md (aarch64_mla_elt_merge<mode>): New.
19280         (aarch64_mls_elt_merge<mode>): Likewise.
19282 2017-07-23  Krister Walfridsson  <krister.walfridsson@gmail.com>
19284         * config.gcc (*-*-netbsd*): Remove check for NetBSD versions not
19285         having __cxa_atexit.
19287 2017-07-23  Michael Collison  <michael.collison@arm.com>
19289         * config/arm/arm.c (arm_option_override): Deprecate
19290         use of -mstructure-size-boundary.
19291         * config/arm/arm.opt: Deprecate -mstructure-size-boundary.
19292         * doc/invoke.texi: Deprecate -mstructure-size-boundary.
19294 2017-07-23  Bill Schmidt  <wschmidt@linux.vnet.ibm.com>
19296         PR target/80695
19297         * config/rs6000/rs6000.c (rs6000_builtin_vectorization_cost):
19298         Reduce cost estimate for direct moves.
19300 2017-07-23  Uros Bizjak  <ubizjak@gmail.com>
19302         PR target/80569
19303         * config/i386/i386.c (ix86_option_override_internal): Disable
19304         BMI, BMI2 and TBM instructions for -m16.
19306 2017-07-21  Carl Love  <cel@us.ibm.com>
19308         * config/rs6000/rs6000-c.c (altivec_overloaded_builtins): Add
19309         ALTIVEC_BUILTIN_VMULESW, ALTIVEC_BUILTIN_VMULEUW,
19310         ALTIVEC_BUILTIN_VMULOSW, ALTIVEC_BUILTIN_VMULOUW entries.
19311         * config/rs6000/rs6000.c (rs6000_gimple_fold_builtin,
19312         builtin_function_type): Add ALTIVEC_BUILTIN_* case statements.
19313         * config/rs6000/altivec.md (MVULEUW, VMULESW, VMULOUW,
19314         VMULOSW): New enum "unspec" values.
19315         (altivec_vmuleuw, altivec_vmulesw, altivec_vmulouw,
19316         altivec_vmulosw): New patterns.
19317         * config/rs6000/rs6000-builtin.def (VMLEUW, VMULESW, VMULOUW,
19318         VMULOSW): Add definitions.
19320 2017-07-21  Jim Wilson  <jim.wilson@linaro.org>
19322         * config/aarch64/aarch64-cores.def (falkor): Add AARCH64_FL_RDMA.
19323         (qdf24xx): Likewise.
19324         * config/aarch64/aarch64-options-extensions.def (rdma); New.
19325         * config/aarch64/aarch64.h (AARCH64_FL_RDMA): New.
19326         (AARCH64_FL_V8_1): Renumber.
19327         (AARCH64_FL_FOR_ARCH8_1): Add AARCH64_FL_RDMA.
19328         (AARCH64_ISA_RDMA): Use AARCH64_FL_RDMA.
19329         * config/aarch64/arm_neon.h: Use +rdma instead of arch=armv8.1-a.
19330         * doc/invoke.texi (AArch64 Options): Mention +rmda in -march docs.  Add
19331         rdma to feature modifiers list.
19333 2017-07-21  Yury Gribov  <tetra2005@gmail.com>
19335         PR middle-end/56727
19336         * ipa-visibility (function_and_variable_visibility): Convert
19337         recursive PLT call to direct call if appropriate.
19339 2017-07-21  Andrew Pinski  <apinski@cavium.com>
19341         * tree-ssa-sccvn.c (vn_nary_op_eq): Check BIT_INSERT_EXPR's
19342         operand 1 to see if the types precision matches.
19343         * fold-const.c (operand_equal_p): Likewise.
19345 2017-07-21  Richard Biener  <rguenther@suse.de>
19347         PR tree-optimization/81303
19348         * tree-vect-data-refs.c (vect_get_peeling_costs_all_drs): Pass
19349         in datarefs vector.  Allow NULL dr0 for no peeling cost estimate.
19350         (vect_peeling_hash_get_lowest_cost): Adjust.
19351         (vect_enhance_data_refs_alignment): Likewise.  Use
19352         vect_get_peeling_costs_all_drs to compute the penalty for no
19353         peeling to match up costs.
19355 2017-07-21  Richard Biener  <rguenther@suse.de>
19357         PR tree-optimization/81500
19358         * tree-vect-loop.c (vect_is_simple_reduction): Properly fail if
19359         we didn't identify a reduction path.
19361 2017-07-21  Tom de Vries  <tom@codesourcery.com>
19362             Cesar Philippidis  <cesar@codesourcery.com>
19364         PR gcov-profile/81442
19365         * config/nvptx/nvptx.c (nvptx_goacc_reduction_init): Add missing edge
19366         probabilities.
19368 2017-07-21  Tom de Vries  <tom@codesourcery.com>
19370         PR lto/81430
19371         * config/nvptx/nvptx.c (nvptx_override_options_after_change): New
19372         function.
19373         (TARGET_OVERRIDE_OPTIONS_AFTER_CHANGE): Define to
19374         nvptx_override_options_after_change.
19376 2017-07-21  Ulrich Drepper  <drepper@redhat.com>
19378         * dwarf2out.c (output_file_names): Avoid double testing for
19379         dwarf_version >= 5.
19381 2017-07-21  Georg-Johann Lay  <avr@gjlay.de>
19383         * doc/invoke.texi (AVR Built-in Functions): Re-layout section.
19385 2016-07-21  Jan Hubicka  <hubicka@ucw.cz>
19387         * cfgcleanup.c (flow_find_cross_jump): Do not crossjump across
19388         hot/cold regions.
19389         (try_crossjump_to_edge): Do not punt on partitioned functions.
19391 2016-07-21  Jan Hubicka  <hubicka@ucw.cz>
19393         * bb-reorder.c (find_rarely_executed_basic_blocks_and_crossing_edges):
19394         Put all BBs reachable only via paths crossing cold region to cold
19395         region.
19396         * cfgrtl.c (find_bbs_reachable_by_hot_paths): New function.
19398 2016-07-21  Richard Biener  <rguenther@suse.de>
19400         PR tree-optimization/81303
19401         * tree-vect-loop.c (vect_estimate_min_profitable_iters): Take
19402         into account prologue and epilogue iterations when raising
19403         min_profitable_iters to sth at least covering one vector iteration.
19405 2017-07-21  Tamar Christina  <tamar.christina@arm.com>
19407         * config/arm/arm.c (arm_test_cpu_arch_dat):
19408         Check for overlap.
19410 2017-07-20  Nathan Sidwell  <nathan@acm.org>
19412         Remove TYPE_METHODS.
19413         * tree.h (TYPE_METHODS): Delete.
19414         * dwarf2out.c (gen_member_die): Member fns are on TYPE_FIELDS.
19415         * dbxout.c (dbxout_type_fields): Ignore FUNCTION_DECLs.
19416         (dbxout_type_methods): Scan TYPE_FIELDS.
19417         (dbxout_type): Don't check TYPE_METHODS here.
19418         * function.c (use_register_for_decl): Always ignore register for
19419         class types when not optimizing.
19420         * ipa-devirt.c (odr_types_equivalent_p): Delete TYPE_METHODS scan.
19421         * tree.c (free_lang_data_in_type): Stitch out member functions and
19422         templates from TYPE_FIELDS.
19423         (build_distinct_type_copy, verify_type_variant,
19424         verify_type): Member fns are on TYPE_FIELDS.
19425         * tree-dump.c (dequeue_and_dump): No TYPE_METHODS.
19426         * tree-pretty-print.c (dump_generic_node): Likewise.
19428 2017-07-20  Jakub Jelinek  <jakub@redhat.com>
19430         PR target/80846
19431         * config/i386/i386.c (ix86_expand_vector_init_general): Handle
19432         V2TImode and V4TImode.
19433         (ix86_expand_vector_extract): Likewise.
19434         * config/i386/sse.md (VMOVE): Enable V4TImode even for just
19435         TARGET_AVX512F, instead of only for TARGET_AVX512BW.
19436         (ssescalarmode): Handle V4TImode and V2TImode.
19437         (VEC_EXTRACT_MODE): Add V4TImode and V2TImode.
19438         (*vec_extractv2ti, *vec_extractv4ti): New insns.
19439         (VEXTRACTI128_MODE): New mode iterator.
19440         (splitter for *vec_extractv?ti first element): New.
19441         (VEC_INIT_MODE): New mode iterator.
19442         (vec_init<mode>): Consolidate 3 expanders into one using
19443         VEC_INIT_MODE mode iterator.
19445 2017-07-20  Alexander Monakov  <amonakov@ispras.ru>
19447         * lra-assigns.c (pseudo_compare_func): Fix comparison step based on
19448         non_spilled_static_chain_regno_p.
19450 2017-07-20  Alexander Monakov  <amonakov@ispras.ru>
19452         * gimple-ssa-store-merging.c (sort_by_bitpos): Return 0 on equal bitpos.
19454 2017-07-20  Jan Hubicka  <hubicka@ucw.cz>
19456         * bb-reorder.c (connect_traces): Allow copying of blocks within
19457         single partition.
19459 2017-07-20  Richard Biener  <rguenther@suse.de>
19461         * gimple.h (gimple_phi_result): Add gphi * overload.
19462         (gimple_phi_result_ptr): Likewise.
19463         (gimple_phi_arg): Likewise.  Adjust index assert to only
19464         allow actual argument accesses rather than all slots available
19465         by capacity.
19466         (gimple_phi_arg_def): Add gphi * overload.
19467         * tree-phinodes.c (make_phi_node): Initialize only actual
19468         arguments.
19469         (resize_phi_node): Clear memory not covered by old node,
19470         do not initialize excess argument slots.
19471         (reserve_phi_args_for_new_edge): Initialize new argument slot
19472         completely.
19474 2017-07-20  Bin Cheng  <bin.cheng@arm.com>
19476         PR tree-optimization/81388
19477         Revert r238585:
19478         2016-07-21  Bin Cheng  <bin.cheng@arm.com>
19480         * tree-ssa-loop-niter.c (number_of_iterations_lt_to_ne): Clean up
19481         by removing computation of may_be_zero.
19483 2017-07-18  Jan Hubicka  <hubicka@ucw.cz>
19484             Tom de Vries  <tom@codesourcery.com>
19486         PR middle-end/81030
19487         * cfgbuild.c (find_many_sub_basic_blocks): Update REG_BR_PROB note
19488         when gimple level profile disagrees with what RTL expander did.
19490 2017-07-20  Richard Biener  <rguenther@suse.de>
19492         PR tree-optimization/61171
19493         * tree-vectorizer.h (slp_instance): Add reduc_phis member.
19494         (vect_analyze_stmt): Add slp instance parameter.
19495         (vectorizable_reduction): Likewise.
19496         * tree-vect-loop.c (vect_analyze_loop_operations): Adjust.
19497         (vect_is_simple_reduction): Deal with chains not detected
19498         as SLP reduction chain, specifically not properly associated
19499         chains containing a mix of plus/minus.
19500         (get_reduction_op): Remove.
19501         (get_initial_defs_for_reduction): Simplify, pass in whether
19502         this is a reduction chain, pass in the SLP node for the PHIs.
19503         (vect_create_epilog_for_reduction): Get the SLP instance as
19504         arg and adjust.
19505         (vectorizable_reduction): Get the SLP instance as arg.
19506         During analysis remember the SLP node with the PHIs in the
19507         instance.  Simplify getting at the vectorized reduction PHIs.
19508         * tree-vect-slp.c (vect_slp_analyze_node_operations): Pass
19509         through SLP instance.
19510         (vect_slp_analyze_operations): Likewise.
19511         * tree-vect-stms.c (vect_analyze_stmt): Likewise.
19512         (vect_transform_stmt): Likewise.
19514 2017-07-20  Tom de Vries  <tom@codesourcery.com>
19516         PR tree-optimization/81489
19517         * gimple-ssa-isolate-paths.c (find_implicit_erroneous_behavior): Move
19518         read of phi arg location to before loop that modifies phi.
19520 2017-07-20  Naveen H.S  <Naveen.Hurugalawadi@cavium.com>
19522         * match.pd (((m1 >/</>=/<= m2) * d -> (m1 >/</>=/<= m2) ? d : 0):
19523         New pattern.
19525 2017-07-19  Jan Hubicka  <hubicka@ucw.cz>
19527         PR middle-end/81331
19528         * except.c (execute): Fix ordering issue.
19530 2018-07-19  Segher Boessenkool  <segher@kernel.crashing.org>
19532         PR rtl-optimization/81423
19533         * combine.c (make_compound_operation_int): Don't try to optimize
19534         the AND of a SUBREG of an LSHIFTRT if that SUBREG is paradoxical.
19536 2017-07-19  Segher Boessenkool  <segher@kernel.crashing.org>
19538         PR rtl-optimization/81423
19539         * simplify-rtx.c (simplify_truncation): Handle truncating an IOR
19540         with a constant that is -1 in the truncated to mode.
19542 2017-07-19  Jan Hubicka  <hubicka@ucw.cz>
19544         * predict.c (propagate_unlikely_bbs_forward): Break out from ...
19545         (determine_unlikely_bbs): ... here.
19546         * predict.h (propagate_unlikely_bbs_forward): Declare.
19547         * cfgexpand.c (pass_expand::execute): Use it.
19548         * bb-reorder.c (sanitize_hot_paths): Do not consider known to be
19549         unlikely edges.
19550         (find_rarely_executed_basic_blocks_and_crossing_edges): Use
19551         propagate_unlikely_bbs_forward.
19553 2017-07-19  Jan Hubicka  <hubicka@ucw.cz>
19555         PR middle-end/81331
19556         * except.c (maybe_add_nop_after_section_switch): New function.
19557         (execute): Use it.
19559 2017-07-19  Tom de Vries  <tom@codesourcery.com>
19561         * gimple.h (gimple_phi_set_arg): Make assert more strict.
19563 2017-07-19  Tom de Vries  <tom@codesourcery.com>
19565         * gimple.h (gimple_phi_arg): Make assert more strict.
19567 2017-07-19  Steven Munroe  <munroesj@gcc.gnu.org>
19569         * config.gcc (powerpc*-*-*): Add mmintrin.h.
19570         * config/rs6000/mmintrin.h: New file.
19571         * config/rs6000/x86intrin.h [__ALTIVEC__]: Include mmintrin.h.
19573 2017-07-19  Jakub Jelinek  <jakub@redhat.com>
19575         PR tree-optimization/81346
19576         * match.pd: Optimize (X - 1U) <= INT_MAX-1U into (int) X > 0.
19578 2017-07-19  Tom de Vries  <tom@codesourcery.com>
19580         * config/nvptx/nvptx.md (VECIM): Add V2DI.
19582 2017-07-19  Tom de Vries  <tom@codesourcery.com>
19584         * config/nvptx/nvptx-modes.def: Add V2DImode.
19585         * config/nvptx/nvptx-protos.h (nvptx_data_alignment): Declare.
19586         * config/nvptx/nvptx.c (nvptx_ptx_type_from_mode): Handle V2DImode.
19587         (nvptx_output_mov_insn): Handle lack of mov.b128.
19588         (nvptx_print_operand): Handle 'H' and 'L' codes.
19589         (nvptx_vector_mode_supported): Allow V2DImode.
19590         (nvptx_preferred_simd_mode): New function.
19591         (nvptx_data_alignment): New function.
19592         (TARGET_VECTORIZE_PREFERRED_SIMD_MODE): Redefine to
19593         nvptx_preferred_simd_mode.
19594         * config/nvptx/nvptx.h (STACK_BOUNDARY, BIGGEST_ALIGNMENT): Change from
19595         64 to 128 bits.
19596         (DATA_ALIGNMENT): Define.  Set to nvptx_data_alignment.
19598 2017-07-19  Tom de Vries  <tom@codesourcery.com>
19600         * config/nvptx/nvptx-modes.def: New file.  Add V2SImode.
19601         * config/nvptx/nvptx.c (nvptx_ptx_type_from_mode): Handle V2SImode.
19602         (nvptx_vector_mode_supported): New function.  Allow V2SImode.
19603         (TARGET_VECTOR_MODE_SUPPORTED_P): Redefine to nvptx_vector_mode_supported.
19604         * config/nvptx/nvptx.md (VECIM): New mode iterator. Add V2SI.
19605         (mov<VECIM>_insn): New define_insn.
19606         (define_expand "mov<VECIM>): New define_expand.
19608 2017-07-19  Tom de Vries  <tom@codesourcery.com>
19610         * config/nvptx/nvptx.c (nvptx_print_operand): Handle v2 vector mode.
19612 2017-07-19  Jakub Jelinek  <jakub@redhat.com>
19614         PR tree-optimization/81346
19615         * fold-const.h (fold_div_compare, range_check_type): Declare.
19616         * fold-const.c (range_check_type): New function.
19617         (build_range_check): Use range_check_type.
19618         (fold_div_compare): No longer static, rewritten into
19619         a match.pd helper function.
19620         (fold_comparison): Don't call fold_div_compare here.
19621         * match.pd (X / C1 op C2): New optimization using fold_div_compare
19622         as helper function.
19624 2017-07-19  Nathan Sidwell  <nathan@acm.org>
19626         * tree.h (TYPE_MINVAL, TYPE_MAXVAL): Rename to ...
19627         (TYPE_MIN_VALUE_RAW, TYPE_MAX_VALUE_RAW): ... these.
19628         * tree.c (find_decls_types_r, verify_type): Use
19629         TYPE_{MIN,MAX}_VALUE_RAW.
19630         * lto-streamer-out.c (DFS::DFS_write_tree_body): Likewise.
19631         (hash_tree): Likewise.
19632         * tree-streamer-in.c (lto_input_ts_type_non_common_tree_pointers):
19633         Likewise.
19634         * tree-streamer-out.c (write_ts_type_non_common_tree_pointers):
19635         Likewise.
19637 2017-07-18  Tom de Vries  <tom@codesourcery.com>
19639         PR middle-end/81464
19640         * omp-expand.c (expand_omp_for_static_chunk): Handle
19641         equal-argument loop exit phi.
19643 2017-07-18  Uros Bizjak  <ubizjak@gmail.com>
19645         PR target/81471
19646         * config/i386/i386.md (rorx_immediate_operand): New mode attribute.
19647         (*bmi2_rorx<mode>3_1): Use rorx_immediate_operand as
19648         operand 2 predicate.
19649         (*bmi2_rorxsi3_1_zext): Use const_0_to_31_operand as
19650         operand 2 predicate.
19651         (ror,rol -> rorx splitters): Use const_int_operand as
19652         operand 2 predicate.
19654 2017-06-18  Richard Biener  <rguenther@suse.de>
19656         PR tree-optimization/81410
19657         * tree-vect-stmts.c (vectorizable_load): Properly adjust for
19658         the gap in the ! slp_perm SLP case after each group.
19660 2017-07-18  Jan Hubicka  <hubicka@ucw.cz>
19662         PR middle-end/81463
19663         * cfgloopmanip.c (scale_loop_profile): Watch out for zero frequency
19664         again.
19666 2017-07-18  Jan Hubicka  <hubicka@ucw.cz>
19668         PR middle-end/81462
19669         * predict.c (set_even_probabilities): Cleanup; do not affect
19670         probabilities that are already known.
19671         (combine_predictions_for_bb): Call even when count is set.
19673 2017-07-18  Nathan Sidwell  <nathan@acm.org>
19675         * tree-parloops.c (try_transform_to_exit_first_loop_alt): Use
19676         TYPE_MAX_VALUE.
19678 2017-07-18  Bin Cheng  <bin.cheng@arm.com>
19680         PR target/81408
19681         * tree-ssa-loop-niter.c (number_of_iterations_exit): Dump missed
19682         optimization for loop niter analysis.
19684 2017-07-18  Georg-Johann Lay  <avr@gjlay.de>
19686         PR target/81473
19687         * config/avr/avr.c (avr_optimize_casesi): Don't use
19688         INT8_MIN, INT8_MAX, UINT8_MAX, INT16_MIN, INT16_MAX, UINT16_MAX.
19690 2017-07-18  Robin Dapp  <rdapp@linux.vnet.ibm.com>
19692         * tree-vect-data-refs.c (vect_enhance_data_refs_alignment): Remove
19693         body_cost_vec from _vect_peel_extended_info.
19694         (vect_peeling_hash_get_lowest_cost): Do not set body_cost_vec.
19695         (vect_peeling_hash_choose_best_peeling): Remove body_cost_vec and
19696         npeel.
19698 2017-07-18  Bin Cheng  <bin.cheng@arm.com>
19700         * config/arm/arm.c (emit_unlikely_jump): Remove unused var.
19702 2017-07-18  Richard Biener  <rguenther@suse.de>
19704         PR tree-optimization/80620
19705         PR tree-optimization/81403
19706         * tree-ssa-pre.c (phi_translate_1): Clear range and points-to
19707         info when re-using a VN table entry.
19709 2017-07-18  Richard Biener  <rguenther@suse.de>
19711         PR tree-optimization/81418
19712         * tree-vect-loop.c (vectorizable_reduction): Properly compute
19713         vectype_in.  Verify that with lane-reducing reduction operations
19714         we have a single def-use cycle.
19716 2017-07-17  Carl Love  <cel@us.ibm.com>
19718         Revert commit r249424   2017-06-20  Carl Love  <cel@us.ibm.com>
19720         * config/rs6000/rs6000-c.c (altivec_overloaded_builtins): Add
19721         ALTIVEC_BUILTIN_VMULESW, ALTIVEC_BUILTIN_VMULEUW,
19722         ALTIVEC_BUILTIN_VMULOSW, ALTIVEC_BUILTIN_VMULOUW entries.
19723         * config/rs6000/rs6000.c (rs6000_gimple_fold_builtin,
19724         builtin_function_type): Add ALTIVEC_BUILTIN_* case statements.
19725         * config/rs6000/altivec.md (MVULEUW, VMULESW, VMULOUW,
19726         VMULOSW): New enum "unspec" values.
19727         (vec_widen_umult_even_v4si, vec_widen_smult_even_v4si,
19728         vec_widen_umult_odd_v4si, vec_widen_smult_odd_v4si,
19729         altivec_vmuleuw, altivec_vmulesw, altivec_vmulouw,
19730         altivec_vmulosw): New patterns.
19731         * config/rs6000/rs6000-builtin.def (VMLEUW, VMULESW, VMULOUW,
19732         VMULOSW): Add definitions.
19733 2017-07-17  Uros Bizjak  <ubizjak@gmail.com>
19735         * config/alpha/alpha.c: Include predict.h.
19737 2017-07-17  Yury Gribov  <tetra2005@gmail.com>
19739         * tree-vrp.c (compare_assert_loc): Fix comparison function
19740         to return predictable results.
19742 2017-07-17  Claudiu Zissulescu  <claziss@synopsys.com>
19744         * config/arc/arc.md (adddi3): Remove support for mexpand-adddi
19745         option.
19746         (subdi3): Likewise.
19747         * config/arc/arc.opt (mexpand-adddi): Deprecate it.
19748         * doc/invoke.texi (mexpand-adddi): Update text.
19750 2017-07-17  Claudiu Zissulescu  <claziss@synopsys.com>
19752         * config/arc/arc.md (clzsi2): Expand to an arc_clzsi2 instruction
19753         that also clobbers the CC register. The old expand code is moved
19754         to ...
19755         (*arc_clzsi2): ... here.
19756         (ctzsi2): Expand to an arc_ctzsi2 instruction that also clobbers
19757         the CC register. The old expand code is moved to ...
19758         (arc_ctzsi2): ... here.
19760 2017-07-17  Claudiu Zissulescu  <claziss@synopsys.com>
19762         * config/arc/arc.opt (mindexed-loads): Use initial value
19763         TARGET_INDEXED_LOADS_DEFAULT.
19764         (mauto-modify-reg): Use initial value
19765         TARGET_AUTO_MODIFY_REG_DEFAULT.
19766         * config/arc/elf.h (TARGET_INDEXED_LOADS_DEFAULT): Define.
19767         (TARGET_AUTO_MODIFY_REG_DEFAULT): Likewise.
19768         * config/arc/linux.h (TARGET_INDEXED_LOADS_DEFAULT): Define.
19769         (TARGET_AUTO_MODIFY_REG_DEFAULT): Likewise.
19771 2017-07-17  Martin Liska  <mliska@suse.cz>
19773         PR sanitizer/81302
19774         * opts.c (finish_options): Do not allow -fgnu-tm
19775         w/ -fsanitize={kernel-,}address.  Say sorry.
19777 2017-07-17  Bin Cheng  <bin.cheng@arm.com>
19779         PR target/81369
19780         * tree-loop-distribution.c (classify_partition): Only assert on
19781         numer of iterations.
19782         (merge_dep_scc_partitions): Delete prameter.  Update function call.
19783         (distribute_loop): Remove code handling loop with unknown niters.
19784         (pass_loop_distribution::execute): Skip loop with unknown niters.
19786 2017-07-17  Bin Cheng  <bin.cheng@arm.com>
19788         PR target/81369
19789         * tree-loop-distribution.c (merge_dep_scc_partitions): Sink call to
19790         function sort_partitions_by_post_order.
19792 2017-07-17  Bin Cheng  <bin.cheng@arm.com>
19794         PR tree-optimization/81374
19795         * tree-loop-distribution.c (pass_loop_distribution::execute): Record
19796         the max index of basic blocks, rather than number of basic blocks.
19798 2017-07-17  Claudiu Zissulescu  <claziss@synopsys.com>
19800         * config/arc/arc-protos.h (arc_legitimate_pc_offset_p): Remove
19801         proto.
19802         (arc_legitimate_pic_operand_p): Likewise.
19803         * config/arc/arc.c (arc_legitimate_pic_operand_p): Remove
19804         function.
19805         (arc_needs_pcl_p): Likewise.
19806         (arc_legitimate_pc_offset_p): Likewise.
19807         (arc_legitimate_pic_addr_p): Remove LABEL_REF case, as this
19808         function is also used in constrains.md.
19809         (arc_legitimate_constant_p): Use arc_legitimate_pic_addr_p to
19810         validate pic constants. Handle CONST_INT, CONST_DOUBLE, MINUS and
19811         PLUS.  Only return true/false in known cases, otherwise assert.
19812         (arc_legitimate_address_p): Remove arc_legitimate_pic_addr_p as it
19813         is already called in arc_legitimate_constant_p.
19814         * config/arc/arc.h (CONSTANT_ADDRESS_P): Consider also LABEL for
19815         pic addresses.
19816         (LEGITIMATE_PIC_OPERAND_P): Use
19817         arc_raw_symbolic_reference_mentioned_p function.
19818         * config/arc/constraints.md (Cpc): Use arc_legitimate_pic_addr_p
19819         function.
19820         (Cal): Likewise.
19821         (C32): Likewise.
19823 2017-07-17  Claudiu Zissulescu  <claziss@synopsys.com>
19824         Andrew Burgess  <andrew.burgess@embecosm.com>
19826         * config/arc/arc-protos.h (arc_compute_function_type): Change prototype.
19827         (arc_return_address_register): New function.
19828         * config/arc/arc.c (arc_handle_fndecl_attribute): New function.
19829         (arc_handle_fndecl_attribute): Add naked attribute.
19830         (TARGET_ALLOCATE_STACK_SLOTS_FOR_ARGS): Define.
19831         (TARGET_WARN_FUNC_RETURN): Likewise.
19832         (arc_allocate_stack_slots_for_args): New function.
19833         (arc_warn_func_return): Likewise.
19834         (machine_function): Change type fn_type.
19835         (arc_compute_function_type): Consider new naked function type,
19836         change function return type.
19837         (arc_must_save_register): Adapt to handle new
19838         arc_compute_function_type's return type.
19839         (arc_expand_prologue): Likewise.
19840         (arc_expand_epilogue): Likewise.
19841         (arc_return_address_regs): Delete.
19842         (arc_return_address_register): New function.
19843         (arc_epilogue_uses): Use above function.
19844         * config/arc/arc.h (arc_return_address_regs): Delete prototype.
19845         (arc_function_type): Change encoding, add naked type.
19846         (ARC_INTERRUPT_P): Change to handle the new encoding.
19847         (ARC_FAST_INTERRUPT_P): Likewise.
19848         (ARC_NORMAL_P): Define.
19849         (ARC_NAKED_P): Likewise.
19850         (arc_compute_function_type): Delete prototype.
19851         * config/arc/arc.md (in_ret_delay_slot): Use
19852         arc_return_address_register function.
19853         (simple_return): Likewise.
19854         (p_return_i): Likewise.
19856 2017-07-17  Jakub Jelinek  <jakub@redhat.com>
19858         PR tree-optimization/81428
19859         * match.pd (X / X -> one): Don't optimize _Fract divisions, as 1
19860         can't be built for those types.
19862 2017-07-17  Georg-Johann Lay  <avr@gjlay.de>
19864         Remove stuff dead since r239246.
19866         * config/avr/avr-arch.h (avr_inform_devices): Remove dead proto.
19867         * config/avr/avr-devices.c (mcu_name, comparator, avr_mcus_str)
19868         (avr_inform_devices): Remove dead stuff.
19870 2017-07-17  Tamar Christina  <tamar.christina@arm.com>
19872         * config/arm/arm_neon.h: Fix softp typo.
19874 2017-07-17  Jakub Jelinek  <jakub@redhat.com>
19876         PR tree-optimization/81365
19877         * tree-ssa-phiprop.c (propagate_with_phi): When considering hoisting
19878         aggregate moves onto bb predecessor edges, make sure there are no
19879         loads that could alias the lhs in between the start of bb and the
19880         loads from *phi.
19882 2017-07-17  Georg-Johann Lay  <avr@gjlay.de>
19884         PR 80929
19885         * config/avr/avr.c (avr_mul_highpart_cost): New static function.
19886         (avr_rtx_costs_1) [TRUNCATE]: Use it to compute mul_highpart cost.
19887         [LSHIFTRT, outer_code = TRUNCATE]: Same.
19889 2017-07-17  Jakub Jelinek  <jakub@redhat.com>
19891         PR tree-optimization/81396
19892         * tree-ssa-math-opts.c (struct symbolic_number): Add n_ops field.
19893         (init_symbolic_number): Initialize it to 1.
19894         (perform_symbolic_merge): Add n_ops from both operands into the new
19895         n_ops.
19896         (find_bswap_or_nop): Don't consider n->n == cmpnop computations
19897         without base_addr as useless if they need more than one operation.
19898         (bswap_replace): Handle !bswap case for NULL base_addr.
19900 2017-07-17  Tom de Vries  <tom@codesourcery.com>
19902         PR target/81069
19903         * config/nvptx/nvptx.c (nvptx_single): Insert diverging branch as late
19904         as possible.
19906 2017-07-17  Sebastian Huber  <sebastian.huber@embedded-brains.de>
19908         * config/sparc/rtemself.h (TARGET_OS_CPP_BUILTINS): Add
19909         conditional builtin define __FIX_LEON3FT_B2BST.
19911 2017-07-17  Daniel Cederman  <cederman@gaisler.com>
19913         * config/sparc/t-rtems: Add mfix-gr712rc multilibs. Replace
19914         MULTILIB_EXCEPTIONS with MULTILIB_REQUIRED. Match -mfix-gr712rc
19915         with -mfix-ut700.
19917 2017-07-16  Eric Botcazou  <ebotcazou@adacore.com>
19919         PR rtl-optimization/81424
19920         * optabs.c (prepare_cmp_insn): Use copy_to_reg instead of force_reg
19921         to remove potential trapping from operands if -fnon-call-exceptions.
19923 2017-07-16  Jan Hubicka  <hubicka@ucw.cz>
19925         * tree-ssa-loop-manip.c (tree_transform_and_unroll_loop): Use
19926         profile_proability for scalling.
19927         * scale_profile_for_vect_loop.c (scale_profile_for_vect_loop): Likewise.
19929 2017-07-16  Jan Hubicka  <hubicka@ucw.cz>
19931         * cgraph.c (cgraph_edge::redirect_call_stmt_to_caller): Cleanup.
19933 2017-07-16  Jan Hubicka  <hubicka@ucw.cz>
19935         * cfgloopmanip.c (scale_loop_profile): Avoid use of REG_BR_PROB_BASE
19936         fixpoint arithmetics.
19938 2017-07-16  Jan Hubicka  <hubicka@ucw.cz>
19940         * tree-ssa-loop-unswitch.c (hoist_guard): Avoid use of REG_BR_PROB_BASE
19941         fixpoint arithmetics.
19943 2017-07-16  Jan Hubicka  <hubicka@ucw.cz>
19945         * asan.c (create_cond_insert_point): Avoid use of REG_BR_PROB_BASE
19946         fixpoint arithmetics.
19948 2017-07-16  Jan Hubicka  <hubicka@ucw.cz>
19950         * profile-count.h (profile_probability::from_reg_br_prob_note,
19951         profile_probability::to_reg_br_prob_note): New functions.
19952         * doc/rtl.texi (REG_BR_PROB_NOTE): Update documentation.
19953         * reg-notes.h (REG_BR_PROB, REG_BR_PRED): Update docs.
19954         * predict.c (probability_reliable_p): Update.
19955         (edge_probability_reliable_p): Update.
19956         (br_prob_note_reliable_p): Update.
19957         (invert_br_probabilities): Update.
19958         (add_reg_br_prob_note): New function.
19959         (combine_predictions_for_insn): Update.
19960         * asan.c (asan_clear_shadow): Update.
19961         * cfgbuild.c (compute_outgoing_frequencies): Update.
19962         * cfgrtl.c (force_nonfallthru_and_redirect): Update.
19963         (update_br_prob_note): Update.
19964         (rtl_verify_edges): Update.
19965         (purge_dead_edges): Update.
19966         (fixup_reorder_chain): Update.
19967         * emit-rtl.c (try_split): Update.
19968         * ifcvt.c (cond_exec_process_insns): Update.
19969         (cond_exec_process_if_block): Update.
19970         (dead_or_predicable): Update.
19971         * internal-fn.c (expand_addsub_overflow): Update.
19972         (expand_neg_overflow): Update.
19973         (expand_mul_overflow): Update.
19974         * loop-doloop.c (doloop_modify): Update.
19975         * loop-unroll.c (compare_and_jump_seq): Update.
19976         * optabs.c (emit_cmp_and_jump_insn_1): Update.
19977         * predict.h: Update.
19978         * reorg.c (mostly_true_jump): Update.
19979         * rtl.h: Update.
19980         * config/aarch64/aarch64.c (aarch64_emit_unlikely_jump): Update.
19981         * config/alpha/alpha.c (emit_unlikely_jump): Update.
19982         * config/arc/arc.c: (emit_unlikely_jump): Update.
19983         * config/arm/arm.c: (emit_unlikely_jump): Update.
19984         * config/bfin/bfin.c (cbranch_predicted_taken_p): Update.
19985         * config/frv/frv.c (frv_print_operand_jump_hint): Update.
19986         * config/i386/i386.c (ix86_expand_split_stack_prologue): Update.
19987         (ix86_print_operand): Update.
19988         (ix86_split_fp_branch): Update.
19989         (predict_jump): Update.
19990         * config/ia64/ia64.c (ia64_print_operand): Update.
19991         * config/mmix/mmix.c (mmix_print_operand): Update.
19992         * config/powerpcspe/powerpcspe.c (output_cbranch): Update.
19993         (rs6000_expand_split_stack_prologue): Update.
19994         * config/rs6000/rs6000.c: Update.
19995         * config/s390/s390.c (s390_expand_vec_strlen): Update.
19996         (s390_expand_vec_movstr): Update.
19997         (s390_expand_cs_tdsi): Update.
19998         (s390_expand_split_stack_prologue): Update.
19999         * config/sh/sh.c (sh_print_operand): Update.
20000         (expand_cbranchsi4): Update.
20001         (expand_cbranchdi4): Update.
20002         * config/sparc/sparc.c (output_v9branch): Update.
20003         * config/spu/spu.c (get_branch_target): Update.
20004         (ea_load_store_inline): Update.
20005         * config/tilegx/tilegx.c (cbranch_predicted_p): Update.
20006         * config/tilepro/tilepro.c: Update.
20008 2017-07-16  Eric Botcazou  <ebotcazou@adacore.com>
20010         * gimplify.c (mostly_copy_tree_r): Revert latest change.
20011         (gimplify_save_expr): Likewise.
20013 2017-07-07  Jan Hubicka  <hubicka@ucw.cz>
20015         * ipa-visibility.c (function_and_variable_visibility): Fix pasto.
20017 2017-07-07  Jan Hubicka  <hubicka@ucw.cz>
20019         * ipa-fnsummary.c (pass_data_ipa_fn_summary): Use
20020         TV_IPA_FNSUMMARY.
20021         * timevar.def (TV_IPA_FNSUMMARY): Define.
20023 2017-07-16  Daniel Cederman  <cederman@gaisler.com>
20025         * config/sparc/sparc.md (divdf3_fix): Add NOP to prevent back
20026         to back store errata sensitive sequence from being generated.
20027         (sqrtdf2_fix): Likewise.
20029 2017-07-07  Jan Hubicka  <hubicka@ucw.cz>
20031         * tree-ssa-threadupdate.c (compute_path_counts,
20032         update_joiner_offpath_counts): Use profile_probability.
20034 2017-07-15  Thomas Preud'homme  <thomas.preudhomme@arm.com>
20036         Revert:
20037         2017-07-14  Thomas Preud'homme  <thomas.preudhomme@arm.com>
20039         * config/arm/arm-c.c (arm_cpu_builtins): Define
20040         __ARM_FEATURE_NUMERIC_MAXMIN solely based on TARGET_VFP5.
20042 2017-07-14  Kelvin Nilsen  <kelvin@gcc.gnu.org>
20044         * config/rs6000/rs6000-c.c (altivec_overloaded_builtins): Add
20045         array entries to represent __ieee128 versions of the
20046         scalar_test_data_class, scalar_test_neg, scalar_extract_exp,
20047         scalar_extract_sig, and scalar_insert_exp built-in functions.
20048         (altivec_resolve_overloaded_builtin): Add special case handling
20049         for the __builtin_scalar_insert_exp function, as represented by
20050         the P9V_BUILTIN_VEC_VSIEDP constant.
20051         * config/rs6000/rs6000-builtin.def (VSEEQP): Add scalar extract
20052         exponent support for __ieee128 argument.
20053         (VSESQP): Add scalar extract signature support for __ieee128
20054         argument.
20055         (VSTDCNQP): Add scalar test negative support for __ieee128
20056         argument.
20057         (VSIEQP): Add scalar insert exponent support for __int128 argument
20058         with __ieee128 result.
20059         (VSIEQPF): Add scalar insert exponent support for __ieee128
20060         argument with __ieee128 result.
20061         (VSTDCQP): Add scalar test data class support for __ieee128
20062         argument.
20063         (VSTDCNQP): Add overload support for scalar test negative with
20064         __ieee128 argument.
20065         (VSTDCQP): Add overload support for scalar test data class
20066         __ieee128 argument.
20067         * config/rs6000/vsx.md (UNSPEC_VSX_SXSIG) Replace
20068         UNSPEC_VSX_SXSIGDP.
20069         (UNSPEC_VSX_SIEXPQP): New constant.
20070         (xsxexpqp): New insn for VSX scalar extract exponent quad
20071         precision.
20072         (xsxsigqp): New insn for VSX scalar extract significand quad
20073         precision.
20074         (xsiexpqpf): New insn for VSX scalar insert exponent quad
20075         precision with floating point argument.
20076         (xststdcqp): New expand for VSX scalar test data class quad
20077         precision.
20078         (xststdcnegqp): New expand for VSX scalar test negative quad
20079         precision.
20080         (xststdcqp): New insn to match expansions for VSX scalar test data
20081         class quad precision and VSX scalar test negative quad precision.
20082         * config/rs6000/rs6000.c (rs6000_expand_binop_builtin): Add
20083         special case operand checking to enforce that second operand of
20084         VSX scalar test data class with quad precision argument is a 7-bit
20085         unsigned literal.
20086         * doc/extend.texi (PowerPC AltiVec Built-in Functions): Add
20087         prototypes and descriptions of __ieee128 versions of
20088         scalar_extract_exp, scalar_extract_sig, scalar_insert_exp,
20089         scalar_test_data_class, and scalar_test_neg built-in functions.
20091 2016-07-14  Bill Schmidt  <wschmidt@linux.vnet.ibm.com>
20093         PR tree-optimization/81162
20094         * gimple-ssa-strength-reduction.c (replace_mult_candidate): Don't
20095         replace a negate with an add.
20097 2017-07-14  James Greenhalgh  <james.greenhalgh@arm.com>
20099         * doc/invoke.texi (arm/-mcpu): Document +crypto.
20101 2017-07-14  Thomas Preud'homme  <thomas.preudhomme@arm.com>
20103         * config/arm/arm-c.c (arm_cpu_builtins): Define
20104         __ARM_FEATURE_NUMERIC_MAXMIN solely based on TARGET_VFP5.
20106 2017-07-14  Thomas Preud'homme  <thomas.preudhomme@arm.com>
20108         * config/arm/arm-cpus.in (cortex-r52): Add new entry.
20109         (armv8-r): Set ARM Cortex-R52 as default CPU.
20110         * config/arm/arm-tables.opt: Regenerate.
20111         * config/arm/arm-tune.md: Regenerate.
20112         * config/arm/driver-arm.c (arm_cpu_table): Add entry for ARM
20113         Cortex-R52.
20114         * doc/invoke.texi: Mention -mtune=cortex-r52 and availability of fp.dp
20115         extension for -mcpu=cortex-r52.
20117 2017-07-14  Thomas Preud'homme  <thomas.preudhomme@arm.com>
20119         * config/arm/arm-isa.h (isa_bit_FP_ARMv8): Delete enumerator.
20120         (ISA_FP_ARMv8): Define as ISA_FPv5 and ISA_FP_D32.
20121         * config/arm/arm-cpus.in (armv8-r): Define fp.sp as enabling FPv5.
20122         (fp-armv8): Define it as FP_ARMv8 only.
20123         config/arm/arm.h (TARGET_FPU_ARMV8): Delete.
20124         (TARGET_VFP_FP16INST): Define using TARGET_VFP5 rather than
20125         TARGET_FPU_ARMV8.
20126         config/arm/arm.c (arm_rtx_costs_internal): Replace checks against
20127         TARGET_FPU_ARMV8 by checks against TARGET_VFP5.
20128         * config/arm/arm-builtins.c (arm_builtin_vectorized_function): Define
20129         first ARM_CHECK_BUILTIN_MODE definition using TARGET_VFP5 rather
20130         than TARGET_FPU_ARMV8.
20131         * config/arm/arm-c.c (arm_cpu_builtins): Likewise for
20132         __ARM_FEATURE_NUMERIC_MAXMIN macro definition.
20133         * config/arm/arm.md (cmov<mode>): Condition on TARGET_VFP5 rather than
20134         TARGET_FPU_ARMV8.
20135         * config/arm/neon.md (neon_vrint): Likewise.
20136         (neon_vcvt): Likewise.
20137         (neon_<fmaxmin_op><mode>): Likewise.
20138         (<fmaxmin><mode>3): Likewise.
20139         * config/arm/vfp.md (l<vrint_pattern><su_optab><mode>si2): Likewise.
20140         * config/arm/predicates.md (arm_cond_move_operator): Check against
20141         TARGET_VFP5 rather than TARGET_FPU_ARMV8 and fix spacing.
20143 2017-07-14  Jackson Woodruff  <jackson.woodruff@arm.com>
20145         * config/aarch64/aarch64.c (aarch64_print_operand): Move comments
20146         to top of function.
20148 2017-07-14  Kyrylo Tkachov  <kyrylo.tkachov@arm.com>
20150         * gimple-ssa-store-merging.c (clear_bit_region): Replace reference to
20151         loop in comment with memset.
20153 2017-07-14  Martin Liska  <mliska@suse.cz>
20155         * cfgexpand.c (expand_gimple_basic_block): Remove dead comment.
20156         * dwarf2out.c (is_java): Remove the function.
20157         (output_pubname): Remove usage of the function.
20158         (lower_bound_default): Remove usage of DW_LANG_Java.
20159         (gen_compile_unit_die): Likewise.
20160         * gcc.c: Remove compiler defaults for .java and .zip files.
20161         * gimple-expr.c (remove_suffix): Change as there's no longer
20162         extension than 4-letter one.
20163         * gimplify.c (mostly_copy_tree_r): Remove Java-special part.
20164         (gimplify_save_expr): Likewise.
20165         * ipa-utils.h (polymorphic_type_binfo_p): Remove the comment
20166         as it's possible even for other languages than Java.
20167         * langhooks.h (struct lang_hooks): Remove Java from a comment.
20168         * lto-opts.c (lto_write_options): Remove reference to Java.
20169         * opts.c (strip_off_ending): Update file extension handling.
20170         * tree-cfg.c (verify_gimple_call): Remove comment with Java.
20171         * tree-eh.c (lower_resx): Likewise.
20172         * tree.c (free_lang_data_in_type): Remove dead code.
20173         (find_decls_types_r): Likewise.
20174         (build_common_builtin_nodes): Remove Java from a comment.
20175         (verify_type): Remove dead code.
20176         * varasm.c (assemble_external): Remove Java from a comment.
20178 2017-07-14  Martin Liska  <mliska@suse.cz>
20180         * opts.c (finish_options): Add quotes.
20181         (common_handle_option): Likewise.
20183 2017-07-14  Martin Liska  <mliska@suse.cz>
20185         * dbxout.c (get_lang_number): Do not handle GNU Pascal.
20186         * dbxout.h (extern void dbxout_stab_value_internal_label_diff):
20187         Remove N_SO_PASCAL.
20188         * dwarf2out.c (lower_bound_default): Do not handle
20189         DW_LANG_Pascal83.
20190         (gen_compile_unit_die): Likewise.
20191         * gcc.c: Remove default extension binding for GNU Pascal.
20192         * stmt.c: Remove Pascal language from a comment.
20193         * xcoffout.c: Likewise.
20195 2017-07-13  David Malcolm  <dmalcolm@redhat.com>
20197         PR c/81405
20198         * diagnostic-show-locus.c (fixit_cmp): New function.
20199         (layout::layout): Sort m_fixit_hints.
20200         (column_range::column_range): Assert that the values are valid.
20201         (struct char_span): New struct.
20202         (correction::overwrite): New method.
20203         (struct source_line): New struct.
20204         (line_corrections::add_hint): Add assertions.  Reimplement memcpy
20205         calls in terms of classes source_line and char_span, and
20206         correction::overwrite.
20207         (selftest::test_overlapped_fixit_printing_2): New function.
20208         (selftest::diagnostic_show_locus_c_tests): Call it.
20210 2017-07-13  Will Schmidt  <will_schmidt@vnet.ibm.com>
20212         * config/rs6000/rs6000.c (rs6000_gimple_fold_builtin): Return
20213         early if there is no lhs.
20215 2017-07-13  Martin Liska  <mliska@suse.cz>
20217         * dwarf2out.c (gen_pointer_type_die): Remove dead code.
20218         (gen_reference_type_die): Likewise.
20219         * stor-layout.c: Remove Pascal-related comment.
20221 2017-07-13  Martin Liska  <mliska@suse.cz>
20223         * opts.c (finish_options): Add quotes to error messages.
20224         (parse_sanitizer_options): Likewise.
20226 2017-07-13  Thomas Preud'homme  <thomas.preudhomme@arm.com>
20228         * doc/invoke.texi (armv8-r): Document +fp.sp ARMv8-R extension.
20230 2017-07-13  Richard Earnshaw  <rearnsha@arm.com>
20232         * config/arm/vxworks.h (TARGET_ENDIAN_DEFAULT): Define.
20234 2017-07-13  Maxim Ostapenko  <m.ostapenko@samsung.com>
20236         * asan.c (asan_emit_allocas_unpoison): Use ptr_mode for arguments
20237         during expansion.
20238         * builtins.c (expand_asan_emit_allocas_unpoison): Likewise.
20240 2017-07-12  Michael Meissner  <meissner@linux.vnet.ibm.com>
20242         PR target/81193
20243         * config/rs6000/rs6000-c.c (rs6000_cpu_cpp_builtins): If GLIBC
20244         provides the hardware capability bits, define the macro
20245         __BUILTIN_CPU_SUPPORTS__.
20246         * config/rs6000/rs6000.c (cpu_expand_builtin): Generate a warning
20247         if GLIBC does not provide the hardware capability bits.  Add a
20248         gcc_unreachable call if the built-in cpu function is neither
20249         __builtin_cpu_is nor __builtin_cpu_supports.
20250         (rs6000_get_function_versions_dispatcher): Change the warning
20251         that an old GLIBC is used which does not export the capability
20252         bits to be an error.
20253         * doc/extend.texi (target_clones attribute): Document the
20254         restriction that GLIBC 2.23 or newer is needed on the PowerPC.
20255         (PowerPC built-in functions): Document that GLIBC 2.23 or newer is
20256         needed by __builtin_cpu_is and __builtin_cpu_supports.  Document
20257         the macros defined by GCC if the newer GLIBC is available.
20259 2017-07-12  Jeff Law  <law@redhat.com>
20261         * config/riscv/riscv.c: Remove unnecessary includes.  Reorder
20262         remaining includes slightly.
20263         * config/riscv/riscv-builtins.c: Include profile-count.h.
20265 2017-07-12  Georg-Johann Lay  <avr@gjlay.de>
20267         PR target/79883
20268         * config/avr/avr.c (avr_set_current_function): In diagnostic
20269         messages: Quote keywords and (parts of) identifiers.
20270         [WITH_AVRLIBC]: Warn for functions named "ISR", "SIGNAL" or
20271         "INTERUPT".
20273 2017-07-12  Carl Love  <cel@us.ibm.com>
20275         * config/rs6000/rs6000-c.c: Add support for built-in functions
20276         vector bool char vec_revb (vector bool char);
20277         vector bool short vec_revb (vector short char);
20278         vector bool int vec_revb (vector bool int);
20279         vector bool long long vec_revb (vector bool long long);
20280         * doc/extend.texi: Update the built-in documentation file for the
20281         new built-in functions.
20283 2017-07-12  Andreas Krebbel  <krebbel@linux.vnet.ibm.com>
20285         * config/s390/s390.md: Remove movcc splitter.
20287 2017-07-12  Andreas Krebbel  <krebbel@linux.vnet.ibm.com>
20289         * config/s390/s390.c (s390_rtx_costs): Return proper costs for
20290         load/store on condition.
20292 2017-07-12  Georg-Johann Lay  <avr@gjlay.de>
20294         PR target/81407
20295         * config/avr/avr.c (avr_encode_section_info)
20296         [progmem && !TREE_READONLY]: Error if progmem object needs
20297         constructing.
20299 2017-07-11  Michael Collison  <michael.collison@arm.com>
20301         * config/aarch64/aarch64-simd.md (aarch64_sub<mode>_compare0):
20302         New pattern.
20304 2017-07-11  Carl Love  <cel@us.ibm.com>
20306         * config/rs6000/rs6000-c.c: Add support for builtins
20307         vector unsigned int vec_parity_lsbb (vector signed int);
20308         vector unsigned int vec_parity_lsbb (vector unsigned int);
20309         vector unsigned __int128 vec_parity_lsbb (vector signed __int128);
20310         vector unsigned __int128 vec_parity_lsbb (vector unsigned __int128);
20311         vector unsigned long long vec_parity_lsbb (vector signed long long);
20312         vector unsigned long long vec_parity_lsbb (vector unsigned long long);
20313         * config/rs6000/rs6000-builtin.def (VPARITY_LSBB): Add BU_P9V_OVERLOAD1.
20314         * config/rs6000/altivec.h (vec_parity_lsbb): Add define.
20315         * doc/extend.texi: Update the built-in documentation file for the
20316         new built-in functions.
20318 2017-07-11  David Malcolm  <dmalcolm@redhat.com>
20320         * diagnostic-show-locus.c: Include "gcc-rich-location.h".
20321         (layout::m_primary_loc): New field.
20322         (layout::layout): Initialize new field.  Move location filtering
20323         logic from here to...
20324         (layout::maybe_add_location_range): ...this new method.  Add
20325         support for filtering to just the lines already specified by other
20326         locations.
20327         (layout::will_show_line_p): New method.
20328         (gcc_rich_location::add_location_if_nearby): New method.
20329         (selftest::test_add_location_if_nearby): New test function.
20330         (selftest::diagnostic_show_locus_c_tests): Call it.
20331         * gcc-rich-location.h (gcc_rich_location::add_location_if_nearby):
20332         New method.
20334 2017-07-11  Tom de Vries  <tom@codesourcery.com>
20336         * config/nvptx/nvptx.c (WORKAROUND_PTXJIT_BUG): New macro.
20337         (bb_first_real_insn): New function.
20338         (nvptx_single): Add extra initialization of broadcasted condition
20339         variables.
20341 2017-07-11  Nathan Sidwell  <nathan@acm.org>
20343         * dwarf2out.c (gen_member_die): Remove useless check for anon ctors.
20345 2017-07-11  Georg-Johann Lay  <avr@gjlay.de>
20347         * doc/extend.texi (AVR Function Attributes): Remove weblink to
20348         Binutils doc as TEXI will mess them up.
20349         * doc/invoke.texi (AVR Options): Same here.
20351 2017-07-11  Daniel Cederman  <cederman@gaisler.com>
20353         * config/sparc/sparc.opt (mfix-ut700): New option.
20354         (mfix-gr712rc): Likewise.
20355         (sparc_fix_b2bst): New variable.
20356         * doc/invoke.texi (SPARC options): Document them.
20357         (ARM options): Fix warnings.
20358         * config/sparc/sparc.c (sparc_do_work_around_errata): Insert NOP
20359         instructions to prevent sequences that can trigger the store-store
20360         errata for certain LEON3FT processors.
20361         (pass_work_around_errata::gate): Also test sparc_fix_b2bst.
20362         (sparc_option_override): Set sparc_fix_b2bst appropriately.
20363         * config/sparc/sparc.md (fix_b2bst): New attribute.
20364         (in_branch_delay): Prevent stores in delay slot if fix_b2bst.
20366 2017-07-10  Uros Bizjak  <ubizjak@gmail.com>
20368         PR target/81375
20369         * config/i386/i386.md (divsf3): Add TARGET_SSE to TARGET_SSE_MATH.
20370         (rcpps): Ditto.
20371         (*rsqrtsf2_sse): Ditto.
20372         (rsqrtsf2): Ditto.
20373         (div<mode>3): Macroize insn from divdf3 and divsf3
20374         using MODEF mode iterator.
20376 2017-07-10  Martin Sebor  <msebor@redhat.com>
20378         PR tree-optimization/80397
20379         * gimple-ssa-sprintf.c (format_integer): Use INTEGRAL_TYPE_P()
20380         instead of testing for equality to INTEGER_TYPE.
20382 2017-07-10  Vineet Gupta <vgupta@synopsys.com>
20384         * config.gcc: Remove uclibc from arc target spec.
20386 2017-07-10  Claudiu Zissulescu  <claziss@synopsys.com>
20388         * config/arc/arc.h (ADDITIONAL_REGISTER_NAMES): Define.
20390 2017-07-07  Jan Hubicka  <hubicka@ucw.cz>
20392         PR lto/80838
20393         * lto-wrapper.c (remove_option): New function.
20394         (merge_and_complain): Merge PIC/PIE options more realistically.
20396 2017-07-10  Georg-Johann Lay  <avr@gjlay.de>
20398         Better ISR prologues by supporting GASes __gcc_isr pseudo insn.
20400         PR target/20296
20401         PR target/81268
20402         * configure.ac [target=avr]: Add GAS check for -mgcc-isr.
20403         (HAVE_AS_AVR_MGCCISR_OPTION):  If so, AC_DEFINE it.
20404         * config.in: Regenerate.
20405         * configure: Regenerate.
20406         * doc/extend.texi (AVR Function Attributes) <no_gccisr>: Document it.
20407         * doc/invoke.texi (AVR Options) <-mgas-isr-prologues>: Document it.
20408         * config/avr/avr.opt (-mgas-isr-prologues): New option and...
20409         (TARGET_GASISR_PROLOGUES): ...target mask.
20410         * common/config/avr/avr-common.c
20411         (avr_option_optimization_table) [OPT_LEVELS_1_PLUS_NOT_DEBUG]:
20412         Set -mgas-isr-prologues.
20413         * config/avr/avr-passes.def (avr_pass_pre_proep): Add
20414         INSERT_PASS_BEFORE for it.
20415         * config/avr/avr-protos.h (make_avr_pass_pre_proep): New proto.
20416         * config/avr/avr.c (avr_option_override)
20417         [!HAVE_AS_AVR_MGCCISR_OPTION]: Unset TARGET_GASISR_PROLOGUES.
20418         (avr_no_gccisr_function_p, avr_hregs_split_reg): New static functions.
20419         (avr_attribute_table) <no_gccisr>: Add new function attribute.
20420         (avr_set_current_function) <is_no_gccisr>: Init machine field.
20421         (avr_pass_data_pre_proep, avr_pass_pre_proep): New pass data
20422         and rtl_opt_pass.
20423         (make_avr_pass_pre_proep): New function.
20424         (emit_push_sfr) <treg>: Add argument to function and use it
20425         instead of TMP_REG.
20426         (avr_expand_prologue) [machine->gasisr.maybe]: Emit gasisr insn
20427         and set machine->gasisr.yes.
20428         (avr_expand_epilogue) [machine->gasisr.yes]: Similar.
20429         (avr_asm_function_end_prologue) [machine->gasisr.yes]: Add
20430         __gcc_isr.n_pushed to .L__stack_usage.
20431         (TARGET_ASM_FINAL_POSTSCAN_INSN): Define to...
20432         (avr_asm_final_postscan_insn): ...this new static function.
20433         * config/avr/avr.h (machine_function)
20434         <is_no_gccisr, use_L__stack_usage>: New fields.
20435         <gasisr, gasisr.yes, gasisr.maybe, gasisr.regno>: New fields.
20436         * config/avr/avr.md (UNSPECV_GASISR): Add unspecv enum.
20437         (GASISR_Prologue, GASISR_Epilogue, GASISR_Done): New define_constants.
20438         (gasisr, *gasisr): New expander and insn.
20439         * config/avr/gen-avr-mmcu-specs.c (print_mcu)
20440         [HAVE_AS_AVR_MGCCISR_OPTION]: Print asm_gccisr spec.
20441         * config/avr/specs.h (ASM_SPEC) <asm_gccisr>: Add sub spec.
20443 2017-07-10  Richard Earnshaw  <rearnsha@arm.com>
20445         * config/arm/parsecpu.awk (gen_comm_data): Do not escape single quotes
20446         in quoted strings.
20448 2017-07-10  Georg-Johann Lay  <avr@gjlay.de>
20450         Move jump-tables out of .text again.
20452         PR target/81075
20453         * config/avr/avr.c (ASM_OUTPUT_ADDR_VEC_ELT): Remove function.
20454         (ASM_OUTPUT_ADDR_VEC): New function.
20455         (avr_adjust_insn_length) [JUMP_TABLE_DATA_P]: Return 0.
20456         (avr_final_prescan_insn) [avr_log.insn_addresses]: Dump
20457         INSN_ADDRESSes as asm comment.
20458         * config/avr/avr.h (JUMP_TABLES_IN_TEXT_SECTION): Adjust comment.
20459         (ASM_OUTPUT_ADDR_VEC_ELT): Remove define.
20460         (ASM_OUTPUT_ADDR_VEC): Define to avr_output_addr_vec.
20461         * config/avr/avr.md (*tablejump): Adjust comment.
20462         * config/avr/elf.h (ASM_OUTPUT_BEFORE_CASE_LABEL): Remove.
20463         * config/avr/avr-log.c (avr_log_set_avr_log) <insn_addresses>:
20464         New detail.
20465         * config/avr/avr-protos.h (avr_output_addr_vec_elt): Remove proto.
20466         (avr_output_addr_vec): New proto.
20467         (avr_log_t) <insn_addresses>: New field.
20469 2017-07-09  H.J. Lu  <hongjiu.lu@intel.com>
20471         PR target/81313
20472         * config/i386/i386.c (ix86_function_arg_advance): Set
20473         outgoing_args_on_stack to true if there are outgoing arguments
20474         on stack.
20475         (ix86_function_arg): Likewise.
20476         (ix86_get_drap_rtx): Use DRAP only if there are outgoing
20477         arguments on stack and ACCUMULATE_OUTGOING_ARGS is false.
20478         * config/i386/i386.h (machine_function): Add
20479         outgoing_args_on_stack.
20481 2017-07-09  Krister Walfridsson  <krister.walfridsson@gmail.com>
20483         * config.gcc (*-*-netbsd*): Remove check for NetBSD versions not
20484         supporting pthreds.
20485         * config/netbsd.h (NETBSD_LIBGCC_SPEC): Always enable pthreads.
20487 2017-07-08  Richard Sandiford  <richard.sandiford@linaro.org>
20489         * Makefile.in (HOOKS_H, RTL_BASE_H, FUNCTION_H, EXPR_H, REGS_H)
20490         (REAL_H): Remove $(MACHMODE_H).
20491         (FIXED_VALUE_H, TREE_CORE_H, CFGLOOP_H): Remove $(MACHMODE_H) and
20492         double-int.h.
20493         (CORETYPES_H): Add signop.h, wide-int.h, wide-int-print.h,
20494         $(MACHMODE_H) and double-int.h.
20495         (build/min-insn-modes.o): Depend on $(CORETYPES_H) rather than
20496         $(MACHMODE_H).
20497         (gengtype-state.o, gengtype.o, build/gengtype.o): Don't depend on
20498         double-int.h.
20500 2017-07-07  Andrew Pinski  <apinski@cavium.com>
20502         * config/aarch64/aarch64.c (aarch_macro_fusion_pair_p): Check
20503         prev_set and curr_set for AARCH64_FUSE_ALU_BRANCH.
20505 2017-07-07  Michael Meissner  <meissner@linux.vnet.ibm.com>
20507         * config/rs6000/rs6000.c (rs6000_get_function_versions_dispatcher):
20508         Add warning if GCC was not configured to link against a GLIBC that
20509         exports the hardware capability bits.
20510         (make_resolver_func): Make resolver function private and not a
20511         COMDAT function.  Create the name with clone_function_name instead
20512         of make_unique_name.
20514         PR target/81348
20515         * config/rs6000/rs6000.md (HI sign_extend splitter): Use the
20516         correct operand in doing the split.
20518 2017-07-07 Carl Love  <cel@us.ibm.com>
20520         * config/rs6000/rs6000-c: Add support for built-in function
20521         vector unsigned short vec_pack_to_short_fp32 (vector float,
20522                                                       vector float).
20523         * config/rs6000/rs6000-builtin.def (CONVERT_4F32_8I16): Add
20524         BU_P9V_AV_2 and BU_P9V_OVERLOAD_2 definitions.
20525         * config/rs6000/altivec.h (vec_pack_to_short_fp32): Add define.
20526         * config/rs6000/altivec.md(UNSPEC_CONVERT_4F32_8I16): Add UNSPEC.
20527         (convert_4f32_8i16): Add define_expand.
20528         * doc/extend.texi: Update the built-in documentation file for the
20529         new built-in function.
20531 2017-07-07  Jose E. Marchesi  <jose.marchesi@oracle.com>
20533         * config/sparc/m8.md: New file.
20534         * config/sparc/sparc.md: Include m8.md.
20536 2017-07-07  Jose E. Marchesi  <jose.marchesi@oracle.com>
20538         * config/sparc/sparc.opt: New option -mvis4b.
20539         * config/sparc/sparc.c (dump_target_flag_bits): Handle MASK_VIS4B.
20540         (sparc_option_override): Handle VIS4B.
20541         (enum sparc_builtins): Define
20542         SPARC_BUILTIN_DICTUNPACK{8,16,32},
20543         SPARC_BUILTIN_FPCMP{LE,GT,EQ,NE}{8,16,32}SHL,
20544         SPARC_BUILTIN_FPCMPU{LE,GT}{8,16,32}SHL,
20545         SPARC_BUILTIN_FPCMPDE{8,16,32}SHL and
20546         SPARC_BUILTIN_FPCMPUR{8,16,32}SHL.
20547         (check_constant_argument): New function.
20548         (sparc_vis_init_builtins): Define builtins
20549         __builtin_vis_dictunpack{8,16,32},
20550         __builtin_vis_fpcmp{le,gt,eq,ne}{8,16,32}shl,
20551         __builtin_vis_fpcmpu{le,gt}{8,16,32}shl,
20552         __builtin_vis_fpcmpde{8,16,32}shl and
20553         __builtin_vis_fpcmpur{8,16,32}shl.
20554         (sparc_expand_builtin): Check that the constant operands to
20555         __builtin_vis_fpcmp*shl and _builtin_vis_dictunpack* are indeed
20556         constant and in range.
20557         * config/sparc/sparc-c.c (sparc_target_macros): Handle
20558         TARGET_VIS4B.
20559         * config/sparc/sparc.h (SPARC_IMM2_P): Define.
20560         (SPARC_IMM5_P): Likewise.
20561         * config/sparc/sparc.md (cpu_feature): Add new feagure "vis4b".
20562         (enabled): Handle vis4b.
20563         (UNSPEC_DICTUNPACK): New unspec.
20564         (UNSPEC_FPCMPSHL): Likewise.
20565         (UNSPEC_FPUCMPSHL): Likewise.
20566         (UNSPEC_FPCMPDESHL): Likewise.
20567         (UNSPEC_FPCMPURSHL): Likewise.
20568         (cpu_feature): New CPU feature `vis4b'.
20569         (dictunpack{8,16,32}): New insns.
20570         (FPCSMODE): New mode iterator.
20571         (fpcscond): New code iterator.
20572         (fpcsucond): Likewise.
20573         (fpcmp{le,gt,eq,ne}{8,16,32}{si,di}shl): New insns.
20574         (fpcmpu{le,gt}{8,16,32}{si,di}shl): Likewise.
20575         (fpcmpde{8,16,32}{si,di}shl): Likewise.
20576         (fpcmpur{8,16,32}{si,di}shl): Likewise.
20577         * config/sparc/constraints.md: Define constraints `q' for unsigned
20578         2-bit integer constants and `t' for unsigned 5-bit integer
20579         constants.
20580         * config/sparc/predicates.md (imm5_operand_dictunpack8): New
20581         predicate.
20582         (imm5_operand_dictunpack16): Likewise.
20583         (imm5_operand_dictunpack32): Likewise.
20584         (imm2_operand): Likewise.
20585         * doc/invoke.texi (SPARC Options): Document -mvis4b.
20586         * doc/extend.texi (SPARC VIS Built-in Functions): Document the
20587         ditunpack* and fpcmp*shl builtins.
20589 2017-07-07  Jose E. Marchesi  <jose.marchesi@oracle.com>
20591         * config.gcc: Handle m8 in --with-{cpu,tune} options.
20592         * config.in: Add HAVE_AS_SPARC6 define.
20593         * config/sparc/driver-sparc.c (cpu_names): Add entry for the SPARC
20594         M8.
20595         * config/sparc/sol2.h (CPP_CPU64_DEFAULT_SPEC): Define for
20596         TARGET_CPU_m8.
20597         (ASM_CPU32_DEFAUILT_SPEC): Likewise.
20598         (CPP_CPU_SPEC): Handle m8.
20599         (ASM_CPU_SPEC): Likewise.
20600         * config/sparc/sparc-opts.h (enum processor_type): Add
20601         PROCESSOR_M8.
20602         * config/sparc/sparc.c (m8_costs): New struct.
20603         (sparc_option_override): Handle TARGET_CPU_m8.
20604         (sparc32_initialize_trampoline): Likewise.
20605         (sparc64_initialize_trampoline): Likewise.
20606         (sparc_issue_rate): Likewise.
20607         (sparc_register_move_cost): Likewise.
20608         * config/sparc/sparc.h (TARGET_CPU_m8): Define.
20609         (CPP_CPU64_DEFAULT_SPEC): Define for M8.
20610         (ASM_CPU64_DEFAULT_SPEC): Likewise.
20611         (CPP_CPU_SPEC): Handle M8.
20612         (ASM_CPU_SPEC): Likewise.
20613         (AS_M8_FLAG): Define.
20614         * config/sparc/sparc.md: Add m8 to the cpu attribute.
20615         * config/sparc/sparc.opt: New option -mcpu=m8 for sparc targets.
20616         * configure.ac (HAVE_AS_SPARC6): Check for assembler support for
20617         M8 instructions.
20618         * configure: Regenerate.
20619         * doc/invoke.texi (SPARC Options): Document -mcpu=m8 and
20620         -mtune=m8.
20622 2017-07-07  Jose E. Marchesi  <jose.marchesi@oracle.com>
20624         * config/sparc/niagara7.md: Rework the DFA scheduler to use insn
20625         subtypes.
20626         * config/sparc/sparc.md: Remove the `v3pipe' insn attribute.
20627         ("*movdi_insn_sp32"): Do not set v3pipe.
20628         ("*movsi_insn"): Likewise.
20629         ("*movdi_insn_sp64"): Likewise.
20630         ("*movsf_insn"): Likewise.
20631         ("*movdf_insn_sp32"): Likewise.
20632         ("*movdf_insn_sp64"): Likewise.
20633         ("*zero_extendsidi2_insn_sp64"): Likewise.
20634         ("*sign_extendsidi2_insn"): Likewise.
20635         ("*mov<VM32:mode>_insn"): Likewise.
20636         ("*mov<VM64:mode>_insn_sp64"): Likewise.
20637         ("*mov<VM64:mode>_insn_sp32"): Likewise.
20638         ("<plusminus_insn><VADDSUB:mode>3"): Likewise.
20639         ("<vlop:code><VL:mode>3"): Likewise.
20640         ("*not_<vlop:code><VL:mode>3"): Likewise.
20641         ("*nand<VL:mode>_vis"): Likewise.
20642         ("*<vlnotop:code>_not1<VL:mode>_vis"): Likewise.
20643         ("*<vlnotop:code>_not2<VL:mode>_vis"): Likewise.
20644         ("one_cmpl<VL:mode>2"): Likewise.
20645         ("faligndata<VM64:mode>_vis"): Likewise.
20646         ("alignaddrsi_vis"): Likewise.
20647         ("alignaddrdi_vis"): Likweise.
20648         ("alignaddrlsi_vis"): Likewise.
20649         ("alignaddrldi_vis"): Likewise.
20650         ("fcmp<gcond:code><GCM:gcm_name><P:mode>_vis"): Likewise.
20651         ("bmaskdi_vis"): Likewise.
20652         ("bmasksi_vis"): Likewise.
20653         ("bshuffle<VM64:mode>_vis"): Likewise.
20654         ("cmask8<P:mode>_vis"): Likewise.
20655         ("cmask16<P:mode>_vis"): Likewise.
20656         ("cmask32<P:mode>_vis"): Likewise.
20657         ("pdistn<P:mode>_vis"): Likewise.
20658         ("<vis3_addsub_ss_patname><VASS:mode>3"): Likewise.
20660 2017-07-07  Jose E. Marchesi  <jose.marchesi@oracle.com>
20662         * config/sparc/sparc.md ("subtype"): New insn attribute.
20663         ("*wrgsr_sp64"): Set insn subtype.
20664         ("*rdgsr_sp64"): Likewise.
20665         ("alignaddrsi_vis"): Likewise.
20666         ("alignaddrdi_vis"): Likewise.
20667         ("alignaddrlsi_vis"): Likewise.
20668         ("alignaddrldi_vis"): Likewise.
20669         ("<plusminus_insn><VADDSUB:mode>3"): Likewise.
20670         ("fexpand_vis"): Likewise.
20671         ("fpmerge_vis"): Likewise.
20672         ("faligndata<VM64:mode>_vis"): Likewise.
20673         ("bshuffle<VM64:mode>_vis"): Likewise.
20674         ("cmask8<P:mode>_vis"): Likewise.
20675         ("cmask16<P:mode>_vis"): Likewise.
20676         ("cmask32<P:mode>_vis"): Likewise.
20677         ("fchksm16_vis"): Likewise.
20678         ("v<vis3_shift_patname><GCM:mode>3"): Likewise.
20679         ("fmean16_vis"): Likewise.
20680         ("fp<plusminus_insn>64_vis"): Likewise.
20681         ("<plusminus_insn>v8qi3"): Likewise.
20682         ("<vis3_addsub_ss_patname><VASS:mode>3"): Likewise.
20683         ("<vis4_minmax_patname><VMMAX:mode>3"): Likewise.
20684         ("<vis4_uminmax_patname><VMMAX:mode>3"): Likewise.
20685         ("<vis3_addsub_ss_patname>v8qi3"): Likewise.
20686         ("<vis4_addsub_us_patname><VAUS:mode>3"): Likewise.
20687         ("*movqi_insn"): Likewise.
20688         ("*movhi_insn"): Likewise.
20689         ("*movsi_insn"): Likewise.
20690         ("movsi_pic_gotdata_op"): Likewise.
20691         ("*movdi_insn_sp32"): Likewise.
20692         ("*movdi_insn_sp64"): Likewise.
20693         ("movdi_pic_gotdata_op"): Likewise.
20694         ("*movsf_insn"): Likewise.
20695         ("*movdf_insn_sp32"): Likewise.
20696         ("*movdf_insn_sp64"): Likewise.
20697         ("*zero_extendhisi2_insn"): Likewise.
20698         ("*zero_extendqihi2_insn"): Likewise.
20699         ("*zero_extendqisi2_insn"): Likewise.
20700         ("*zero_extendqidi2_insn"): Likewise.
20701         ("*zero_extendhidi2_insn"): Likewise.
20702         ("*zero_extendsidi2_insn_sp64"): Likewise.
20703         ("ldfsr"): Likewise.
20704         ("prefetch_64"): Likewise.
20705         ("prefetch_32"): Likewise.
20706         ("tie_ld32"): Likewise.
20707         ("tie_ld64"): Likewise.
20708         ("*tldo_ldub_sp32"): Likewise.
20709         ("*tldo_ldub1_sp32"): Likewise.
20710         ("*tldo_ldub2_sp32"): Likewise.
20711         ("*tldo_ldub_sp64"): Likewise.
20712         ("*tldo_ldub1_sp64"): Likewise.
20713         ("*tldo_ldub2_sp64"): Likewise.
20714         ("*tldo_ldub3_sp64"): Likewise.
20715         ("*tldo_lduh_sp32"): Likewise.
20716         ("*tldo_lduh1_sp32"): Likewise.
20717         ("*tldo_lduh_sp64"): Likewise.
20718         ("*tldo_lduh1_sp64"): Likewise.
20719         ("*tldo_lduh2_sp64"): Likewise.
20720         ("*tldo_lduw_sp32"): Likewise.
20721         ("*tldo_lduw_sp64"): Likewise.
20722         ("*tldo_lduw1_sp64"): Likewise.
20723         ("*tldo_ldx_sp64"): Likewise.
20724         ("*mov<VM32:mode>_insn"): Likewise.
20725         ("*mov<VM64:mode>_insn_sp64"): Likewise.
20726         ("*mov<VM64:mode>_insn_sp32"): Likewise.
20728 2017-07-07  Jose E. Marchesi  <jose.marchesi@oracle.com>
20730         * config/sparc/sparc.md ("type"): New insn type viscmp.
20731         ("fcmp<gcond:code><GCM:gcm_name><P:mode>_vis"): Set insn type to
20732         viscmp.
20733         ("fpcmp<gcond:code>8<P:mode>_vis"): Likewise.
20734         ("fucmp<gcond:code>8<P:mode>_vis"): Likewise.
20735         ("fpcmpu<gcond:code><GCM:gcm_name><P:mode>_vis"): Likewise.
20736         * config/sparc/niagara7.md ("n7_vis_logical_v3pipe"): Handle
20737         viscmp.
20738         ("n7_vis_logical_11cycle"): Likewise.
20739         * config/sparc/niagara4.md ("n4_vis_logical"): Likewise.
20740         * config/sparc/niagara2.md ("niag3_vis": Likewise.
20741         * config/sparc/niagara.md ("niag_vis"): Likewise.
20742         * config/sparc/ultra3.md ("us3_fga"): Likewise.
20743         * config/sparc/ultra1_2.md ("us1_fga_double"): Likewise.
20745 2017-07-07  Jose E. Marchesi  <jose.marchesi@oracle.com>
20747         * config/sparc/sparc.md: New instruction type `bmask'.
20748         (bmaskdi_vis): Use the `bmask' type.
20749         (bmasksi_vis): Likewise.
20750         * config/sparc/ultra3.md (us3_array): Likewise.
20751         * config/sparc/niagara7.md (n7_array): Likewise.
20752         * config/sparc/niagara4.md (n4_array): Likewise.
20753         * config/sparc/niagara2.md (niag2_vis): Likewise.
20754         (niag3_vis): Likewise.
20755         * config/sparc/niagara.md (niag_vis): Likewise.
20757 2017-07-06  Jan Hubicka  <hubicka@ucw.cz>
20759         * ipa-comdats.c: Remove optimize check from gate.
20760         * ipa-fnsummary.c (ipa_fn_summary_generate): do not generate summary
20761         for functions not optimized.
20762         (ipa_fn_summary_read): Skip optimize check.
20763         (ipa_fn_summary_write): Likewise.
20764         * ipa-inline-analysis.c (do_estimate_growth_1): Check that caller
20765         is optimized.
20766         * ipa-inline.c (can_inline_edge_p): Not optimized functions are
20767         uninlinable.
20768         (can_inline_edge_p): Check flag_pcc_struct_return for match.
20769         (check_callers): Give up on caller which is not optimized.
20770         (inline_small_functions): Likewise.
20771         (ipa_inline): Do not give up when not optimizing.
20772         * ipa-visbility.c (function_and_variable_visibility): Do not optimize
20773         away unoptimizes cdtors.
20774         (whole_program_function_and_variable_visibility): Do
20775         ipa_discover_readonly_nonaddressable_vars in LTO mode.
20776         * ipa.c (process_references): Do not check optimize.
20777         (symbol_table::remove_unreachable_nodes): Update optimize check.
20778         (set_writeonly_bit): Update optimize check.
20779         (pass_ipa_cdtor_merge::gate): Do not check optimize.
20780         (pass_ipa_single_use::gate): Remove.
20782 2017-07-06  Aaron Sawdey  <acsawdey@linux.vnet.ibm.com>
20784         * config/rs6000/rs6000.c (union_defs, union_uses, insn_is_load_p,
20785         insn_is_store_p, insn_is_swap_p, const_load_sequence_p, v2df_reduction_p,
20786         rtx_is_swappable_p, insn_is_swappable_p, chain_contains_only_swaps,
20787         mark_swaps_for_removal, swap_const_vector_halves, adjust_subreg_index,
20788         permute_load, permute_store, adjust_extract, adjust_splat,
20789         adjust_xxpermdi, adjust_concat, adjust_vperm, handle_special_swappables,
20790         replace_swap_with_copy, dump_swap_insn_table,
20791         alignment_with_canonical_addr, alignment_mask, find_alignment_op,
20792         recombine_lvx_pattern, recombine_stvx_pattern,
20793         recombine_lvx_stvx_patterns, rs6000_analyze_swaps,
20794         make_pass_analyze_swaps): Move all code related to p8 swap optimizations
20795         to file rs6000-p8swap.c.
20796         * config/rs6000/rs6000-p8swap.c: New file.
20797         * config/rs6000/t-rs6000: Add rule to build rs6000-p8swap.o.
20798         * config.gcc: Add rs6000-p8swap.o to extra_objs for powerpc*-*-*
20799         and rs6000*-*-* targets.
20801 2017-07-06  David Malcolm  <dmalcolm@redhat.com>
20803         * Makefile.in (selftest): Remove dependency on s-selftest-c++.
20805 2017-07-06  Jan Hubicka  <hubicka@ucw.cz>
20807         * lto-wrapper.c (merge_and_complain): Do not merge
20808         fexceptions, fnon_call_exceptions, ftrapv, ffp_contract_, fmath_errno,
20809         fsigned_zeros, ftrapping_math, fwrapv.
20810         (append_compiler_options): Do not track these options.
20811         (append_linker_options): Likewie
20813 2017-07-06  Jan Hubicka  <hubicka@ucw.cz>
20815         * cgraphunit.c (cgraph_node::finalize_function): When
20816         !flag_toplevel_reorde set no_reorder flag.
20817         (varpool_node::finalize_decl): Likewise.
20818         (symbol_table::compile): Drop no toplevel reorder path.
20820 2017-07-06  Jan Hubicka  <hubicka@ucw.cz>
20822         * bb-reorder.c (better_edge_p): Do not build traces across abnormal/eh
20823         edges; zero probability is not better than uninitialized.
20825 2017-07-06  Maxim Ostapenko  <m.ostapenko@samsung.com>
20827         * asan.h (asan_sanitize_allocas_p): Declare.
20828         * asan.c (asan_sanitize_allocas_p): New function.
20829         (handle_builtin_stack_restore): Bail out if !asan_sanitize_allocas_p.
20830         (handle_builtin_alloca): Likewise.
20831         * cfgexpand.c (expand_used_vars): Do not add allocas unpoisoning stuff
20832         if !asan_sanitize_allocas_p.
20833         * params.def (asan-instrument-allocas): Add new option.
20834         * params.h (ASAN_PROTECT_ALLOCAS): Define.
20835         * opts.c (common_handle_option): Disable allocas sanitization for
20836         KASan by default.
20838 2017-07-06  Maxim Ostapenko  <m.ostapenko@samsung.com>
20840         * asan.c: Include gimple-fold.h.
20841         (get_last_alloca_addr): New function.
20842         (handle_builtin_stackrestore): Likewise.
20843         (handle_builtin_alloca): Likewise.
20844         (asan_emit_allocas_unpoison): Likewise.
20845         (get_mem_refs_of_builtin_call): Add new parameter, remove const
20846         quallifier from first paramerer. Handle BUILT_IN_ALLOCA,
20847         BUILT_IN_ALLOCA_WITH_ALIGN and BUILT_IN_STACK_RESTORE builtins.
20848         (instrument_builtin_call): Pass gimple iterator to
20849         get_mem_refs_of_builtin_call.
20850         (last_alloca_addr): New global.
20851         * asan.h (asan_emit_allocas_unpoison): Declare.
20852         * builtins.c (expand_asan_emit_allocas_unpoison): New function.
20853         (expand_builtin): Handle BUILT_IN_ASAN_ALLOCAS_UNPOISON.
20854         * cfgexpand.c (expand_used_vars): Call asan_emit_allocas_unpoison
20855         if function calls alloca.
20856         * gimple-fold.c (replace_call_with_value): Remove static keyword.
20857         * gimple-fold.h (replace_call_with_value): Declare.
20858         * internal-fn.c: Include asan.h.
20859         * sanitizer.def (BUILT_IN_ASAN_ALLOCA_POISON,
20860         BUILT_IN_ASAN_ALLOCAS_UNPOISON): New builtins.
20862 2017-07-06  David Malcolm  <dmalcolm@redhat.com>
20864         * Makefile.in (SELFTEST_FLAGS): Drop "-x c", moving it to...
20865         (C_SELFTEST_FLAGS): New.
20866         (CPP_SELFTEST_FLAGS): New.
20867         (SELFTEST_DEPS): New, from deps of s-selftest.
20868         (C_SELFTEST_DEPS): New, from deps of s-selftest.
20869         (CPP_SELFTEST_DEPS): New.
20870         (selftest): Add dependency on s-selftest-c++.
20871         (s-selftest): Rename to...
20872         (s-selftest-c): ...this, moving deps to SELFTEST_DEPS
20873         and C_SELFTEST_DEPS, and using C_SELFTEST_FLAGS rather
20874         than SELFTEST_FLAGS.
20875         (selftest-gdb): Rename to...
20876         (selftest-c-gdb): ...this, using C_SELFTEST_DEPS and
20877         C_SELFTEST_FLAGS.
20878         (selftest-gdb): Reintroduce as an alias for selftest-c-gdb.
20879         (selftest-valgrind): Rename to...
20880         (selftest-c-valgrind): ...this, using C_SELFTEST_DEPS and
20881         C_SELFTEST_FLAGS.
20882         (selftest-valgrind): Reintroduce as an alias for
20883         selftest-c-valgrind.
20884         (s-selftest-c++): New.
20885         (selftest-c++-gdb): New.
20886         (selftest-c++-valgrind): New.
20888 2017-07-06  Olivier Hainque  <hainque@adacore.com>
20890         * gcc.c (process_command): When deciding if undefined variables
20891         should be ignored when processing specs, accept "gcc -v" as well.
20893 2017-07-06  Jan Hubicka  <hubicka@ucw.cz>
20895         * auto-profile.c (afdo_set_bb_count, afdo_propagate_edge,
20896         afdo_annotate_cfg): Set counts/probabilities as determined by afdo.
20898 2017-07-06  Thomas Preud'homme  <thomas.preudhomme@arm.com>
20900         * config/arm/arm-cpus.in (armv8-r): Add new entry.
20901         * config/arm/arm-isa.h (ISA_ARMv8r): Define macro.
20902         * config/arm/arm-tables.opt: Regenerate.
20903         * config/arm/arm.h (enum base_architecture): Add BASE_ARCH_8R
20904         enumerator.
20905         * doc/invoke.texi: Mention -march=armv8-r and its extensions.
20907 2017-07-06  Carl Love  <cel@us.ibm.com>
20909         * ChangeLog: Clean up from mid air collision
20911 2017-07-06  Carl Love  <cel@us.ibm.com>
20913         * config/rs6000/rs6000-c.c: Add support for built-in functions
20914         vector signed int vec_subc (vector signed int, vector signed int);
20915         vector signed __int128 vec_subc (vector signed __int128,
20916                                          vector signed __int128);
20917         vector unsigned __int128 vec_subc (vector unsigned __int128,
20918                                            vector unsigned __int128);
20919         vector signed int vec_sube (vector signed int, vector signed int,
20920                                     vector signed int);
20921         vector unsigned int vec_sube (vector unsigned int,
20922                                       vector unsigned int,
20923                                       vector unsigned int);
20924         vector signed __int128 vec_sube (vector signed __int128,
20925                                          vector signed __int128,
20926                                          vector signed__int128);
20927         vector unsigned __int128 vec_sube (vector unsigned __int128,
20928                                            vector unsigned __int128,
20929                                            vector unsigned __int128);
20930         vector signed int vec_subec (vector signed int, vector signed int,
20931                                      vector signed int);
20932         vector unsigned int vec_subec (vector unsigned int,
20933                                        vector unsigned int,
20934                                        vector unsigned int);
20935         vector signed __int128 vec_subec (vector signed __int128,
20936                                           vector signed __int128,
20937                                           vector signed__int128);
20938         vector unsigned __int128 vec_subec (vector unsigned __int128,
20939                                             vector unsigned __int128,
20940                                             vector unsigned __int128);
20941         * config/rs6000/rs6000.c (ALTIVEC_BUILTIN_VEC_SUBE,
20942         ALTIVEC_BUILTIN_VEC_SUBEC): Add ef_builtins.
20943         * config/rs6000/rs6000-builtin.def (SUBE, SUBEC): Add
20944         BU_ALTIVEC_OVERLOAD_X definitions.
20945         * config/rs6000/altivec.h (vec_sube, vec_subec): Add builtin defines.
20946         * doc/extend.texi: Update the built-in documentation file for the new
20947         built-in functions.
20949 2017-07-06  David Malcolm  <dmalcolm@redhat.com>
20951         PR c++/79300
20952         * diagnostic-show-locus.c (layout::layout): Use start and finish
20953         spelling location for the start and finish of each range.
20954         * genmatch.c (linemap_client_expand_location_to_spelling_point):
20955         Add unused aspect param.
20956         * input.c (expand_location_1): Add "aspect" param, and use it
20957         to access the correct part of the location.
20958         (expand_location): Pass LOCATION_ASPECT_CARET to new param of
20959         expand_location_1.
20960         (expand_location_to_spelling_point): Likewise.
20961         (linemap_client_expand_location_to_spelling_point): Add "aspect"
20962         param, and pass it to expand_location_1.
20964 2017-07-06  Sebastian Peryt  <sebastian.peryt@intel.com>
20966         * config/i386/avx512fintrin.h (_mm_mask_getexp_round_ss,
20967         _mm_maskz_getexp_round_ss, _mm_mask_getexp_round_sd,
20968         _mm_maskz_getexp_round_sd, _mm_mask_getmant_round_sd,
20969         _mm_maskz_getmant_round_sd, _mm_mask_getmant_round_ss,
20970         _mm_maskz_getmant_round_ss, _mm_mask_getexp_ss, _mm_maskz_getexp_ss,
20971         _mm_mask_getexp_sd, _mm_maskz_getexp_sd, _mm_mask_getmant_sd,
20972         _mm_maskz_getmant_sd, _mm_mask_getmant_ss,
20973         _mm_maskz_getmant_ss): New intrinsics.
20974         (__builtin_ia32_getexpss128_mask): Changed to ...
20975         __builtin_ia32_getexpss128_round ... this.
20976         (__builtin_ia32_getexpsd128_mask): Changed to ...
20977         __builtin_ia32_getexpsd128_round ... this.
20978         * config/i386/i386-builtin-types.def
20979         ((V2DF, V2DF, V2DF, INT, V2DF, UQI, INT),
20980         (V4SF, V4SF, V4SF, INT, V4SF, UQI, INT)): New function type aliases.
20981         * config/i386/i386-builtin.def (__builtin_ia32_getexpsd_mask_round,
20982         __builtin_ia32_getexpss_mask_round,     __builtin_ia32_getmantsd_mask_round,
20983         __builtin_ia32_getmantss_mask_round): New builtins.
20984         * config/i386/i386.c (V2DF_FTYPE_V2DF_V2DF_INT_V2DF_UQI_INT,
20985         V4SF_FTYPE_V4SF_V4SF_INT_V4SF_UQI_INT): Handle new types.
20986         (CODE_FOR_avx512f_vgetmantv2df_mask_round,
20987         CODE_FOR_avx512f_vgetmantv4sf_mask_round): New cases.
20988         * config/i386/sse.md
20989         (avx512f_sgetexp<mode><round_saeonly_name>): Changed to ...
20990         avx512f_sgetexp<mode><mask_scalar_name>
20991         <round_saeonly_scalar_name> ... this.
20992         (vgetexp<ssescalarmodesuffix>\t{<round_saeonly_op3>%2, %1, %0|
20993         %0, %1, %2<round_saeonly_op3>}): Changed to ...
20994         vgetexp<ssescalarmodesuffix>
20995         \t{<round_saeonly_scalar_mask_op3>%2, %1, %0<mask_scalar_operand3>|
20996         %0<mask_scalar_operand3>, %1, %2<round_saeonly_scalar_mask_op3>} ... this.
20997         (avx512f_vgetmant<mode><round_saeonly_name>): Changed to ...
20998         avx512f_vgetmant<mode><mask_scalar_name>
20999         <round_saeonly_scalar_name> ... this.
21000         (vgetmant<ssescalarmodesuffix>\t{%3, <round_saeonly_op4>%2, %1, %0|
21001         %0, %1, %2<round_saeonly_op4>, %3}): Changed to ...
21002         vgetmant<ssescalarmodesuffix>
21003         \t{%3, <round_saeonly_scalar_mask_op4>%2, %1, %0<mask_scalar_operand4>|
21004         %0<mask_scalar_operand4>, %1, %2
21005         <round_saeonly_scalar_mask_op4>, %3} ... this.
21006         * config/i386/subst.md (mask_scalar_operand4,
21007         round_saeonly_scalar_mask_operand4,     round_saeonly_scalar_mask_op4,
21008         round_saeonly_scalar_nimm_predicate): New subst attributes.
21010 2017-07-06  Julia Koval  <julia.koval@intel.com>
21012         * config/i386/i386.c (ix86_erase_embedded_rounding):
21013         Remove code for old rounding pattern.
21015 2017-07-06  Richard Earnshaw  <rearnsha@arm.com>
21017         * config/arm/t-arm (GTM_H): Add arm-cpu.h.
21019 2017-07-06  Christophe Lyon  <christophe.lyon@linaro.org>
21021         * doc/sourcebuild.texi (Test Directives, Variants of
21022         dg-require-support): Add documentation for dg-require-stack-check.
21024 2017-07-05  Sebastian Peryt  <sebastian.peryt@intel.com>
21026         * config/i386/subst.md (mask_scalar, round_scalar,
21027         round_saeonly_scalar): New meta-templates.
21028         (mask_scalar_name, mask_scalar_operand3, round_scalar_name,
21029         round_scalar_mask_operand3, round_scalar_mask_op3,
21030         round_scalar_constraint, round_scalar_prefix, round_saeonly_scalar_name,
21031         round_saeonly_scalar_mask_operand3, round_saeonly_scalar_mask_op3,
21032         round_saeonly_scalar_constraint,
21033         round_saeonly_scalar_prefix): New subst attribute.
21034         * config/i386/sse.md
21035         (<sse>_vm<plusminus_insn><mode>3<mask_name><round_name>): Renamed to ...
21036         <sse>_vm<plusminus_insn><mode>3<mask_scalar_name>
21037         <round_scalar_name> ... this.
21038         (<sse>_vm<multdiv_mnemonic><mode>3<mask_name><round_name>): Renamed to ...
21039         <sse>_vm<multdiv_mnemonic><mode>3<mask_scalar_name>
21040         <round_scalar_name> ... this.
21041         (<sse>_vm<code><mode>3<mask_name><round_saeonly_name>): Renamed to ...
21042         <sse>_vm<code><mode>3<mask_scalar_name>
21043         <round_saeonly_scalar_name> ... this.
21044         (v<plusminus_mnemonic><ssescalarmodesuffix>
21045         \t{<round_mask_op3>%2, %1, %0<mask_operand3>|
21046         %0<mask_operand3>, %1, %<iptr>2<round_mask_op3>}): Changed to ...
21047         v<plusminus_mnemonic><ssescalarmodesuffix>
21048         \t{<round_scalar_mask_op3>%2, %1, %0<mask_scalar_operand3>|
21049         %0<mask_scalar_operand3>, %1, %<iptr>2<round_scalar_mask_op3>} ... this.
21050         (v<multdiv_mnemonic><ssescalarmodesuffix>
21051         \t{<round_mask_op3>%2, %1, %0<mask_operand3>|
21052         %0<mask_operand3>, %1, %<iptr>2<round_mask_op3>}): Changed to ...
21053         v<multdiv_mnemonic><ssescalarmodesuffix>
21054         \t{<round_scalar_mask_op3>%2, %1, %0<mask_scalar_operand3>|
21055         %0<mask_scalar_operand3>, %1, %<iptr>2<round_scalar_mask_op3>} ... this.
21056         (v<maxmin_float><ssescalarmodesuffix>
21057         \t{<round_saeonly_mask_op3>%2, %1, %0<mask_operand3>|
21058         %0<mask_operand3>, %1, %<iptr>2<round_saeonly_mask_op3>}): Changed to ...
21059         v<maxmin_float><ssescalarmodesuffix>
21060         \t{<round_saeonly_scalar_mask_op3>%2, %1, %0<mask_scalar_operand3>|
21061         %0<mask_scalar_operand3>, %1, %<iptr>2
21062         <round_saeonly_scalar_mask_op3>} ... this.
21064 2017-07-05  Richard Earnshaw  <rearnsha@arm.com>
21066         * config/arm/arm.c (arm_fixed_condition_code_regs): New function.
21067         (TARGET_FIXED_CONDITION_CODE_REGS): Redefine.
21069 2017-07-05  Richard Sandiford  <richard.sandiford@linaro.org>
21070             Alan Hayward  <alan.hayward@arm.com>
21071             David Sherwood  <david.sherwood@arm.com>
21073         * combine.c (simplify_if_then_else): Remove "enum" before
21074         "machine_mode".
21075         * compare-elim.c (can_eliminate_compare): Likewise.
21076         * config/aarch64/aarch64-builtins.c (aarch64_simd_builtin_std_type):
21077         Likewise.
21078         (aarch64_lookup_simd_builtin_type): Likewise.
21079         (aarch64_simd_builtin_type): Likewise.
21080         (aarch64_init_simd_builtin_types): Likewise.
21081         (aarch64_simd_expand_args): Likewise.
21082         * config/aarch64/aarch64-protos.h (aarch64_simd_attr_length_rglist):
21083         Likewise.
21084         (aarch64_reverse_mask): Likewise.
21085         (aarch64_simd_emit_reg_reg_move): Likewise.
21086         (aarch64_gen_adjusted_ldpstp): Likewise.
21087         (aarch64_ccmp_mode_to_code): Likewise.
21088         (aarch64_operands_ok_for_ldpstp): Likewise.
21089         (aarch64_operands_adjust_ok_for_ldpstp): Likewise.
21090         * config/aarch64/aarch64.c (aarch64_ira_change_pseudo_allocno_class):
21091         Likewise.
21092         (aarch64_min_divisions_for_recip_mul): Likewise.
21093         (aarch64_reassociation_width): Likewise.
21094         (aarch64_get_condition_code_1): Likewise.
21095         (aarch64_simd_emit_reg_reg_move): Likewise.
21096         (aarch64_simd_attr_length_rglist): Likewise.
21097         (aarch64_reverse_mask): Likewise.
21098         (aarch64_operands_ok_for_ldpstp): Likewise.
21099         (aarch64_operands_adjust_ok_for_ldpstp): Likewise.
21100         (aarch64_gen_adjusted_ldpstp): Likewise.
21101         * config/aarch64/cortex-a57-fma-steering.c (fma_node::rename):
21102         Likewise.
21103         * config/arc/arc.c (legitimate_offset_address_p): Likewise.
21104         * config/arm/arm-builtins.c (arm_simd_builtin_std_type): Likewise.
21105         (arm_lookup_simd_builtin_type): Likewise.
21106         (arm_simd_builtin_type): Likewise.
21107         (arm_init_simd_builtin_types): Likewise.
21108         (arm_expand_builtin_args): Likewise.
21109         * config/arm/arm-protos.h (arm_expand_builtin): Likewise.
21110         * config/ft32/ft32.c (ft32_libcall_value): Likewise.
21111         (ft32_setup_incoming_varargs): Likewise.
21112         (ft32_function_arg): Likewise.
21113         (ft32_function_arg_advance): Likewise.
21114         (ft32_pass_by_reference): Likewise.
21115         (ft32_arg_partial_bytes): Likewise.
21116         (ft32_valid_pointer_mode): Likewise.
21117         (ft32_addr_space_pointer_mode): Likewise.
21118         (ft32_addr_space_legitimate_address_p): Likewise.
21119         * config/i386/i386-protos.h (ix86_operands_ok_for_move_multiple):
21120         Likewise.
21121         * config/i386/i386.c (ix86_setup_incoming_vararg_bounds): Likewise.
21122         (ix86_emit_outlined_ms2sysv_restore): Likewise.
21123         (iamcu_alignment): Likewise.
21124         (canonicalize_vector_int_perm): Likewise.
21125         (ix86_noce_conversion_profitable_p): Likewise.
21126         (ix86_mpx_bound_mode): Likewise.
21127         (ix86_operands_ok_for_move_multiple): Likewise.
21128         * config/microblaze/microblaze-protos.h
21129         (microblaze_expand_conditional_branch_reg): Likewise.
21130         * config/microblaze/microblaze.c
21131         (microblaze_expand_conditional_branch_reg): Likewise.
21132         * config/powerpcspe/powerpcspe.c (rs6000_init_hard_regno_mode_ok):
21133         Likewise.
21134         (rs6000_reassociation_width): Likewise.
21135         (rs6000_invalid_binary_op): Likewise.
21136         (fusion_p9_p): Likewise.
21137         (emit_fusion_p9_load): Likewise.
21138         (emit_fusion_p9_store): Likewise.
21139         * config/riscv/riscv-protos.h (riscv_regno_mode_ok_for_base_p):
21140         Likewise.
21141         (riscv_hard_regno_mode_ok_p): Likewise.
21142         (riscv_address_insns): Likewise.
21143         (riscv_split_symbol): Likewise.
21144         (riscv_legitimize_move): Likewise.
21145         (riscv_function_value): Likewise.
21146         (riscv_hard_regno_nregs): Likewise.
21147         (riscv_expand_builtin): Likewise.
21148         * config/riscv/riscv.c (riscv_build_integer_1): Likewise.
21149         (riscv_build_integer): Likewise.
21150         (riscv_split_integer): Likewise.
21151         (riscv_legitimate_constant_p): Likewise.
21152         (riscv_cannot_force_const_mem): Likewise.
21153         (riscv_regno_mode_ok_for_base_p): Likewise.
21154         (riscv_valid_base_register_p): Likewise.
21155         (riscv_valid_offset_p): Likewise.
21156         (riscv_valid_lo_sum_p): Likewise.
21157         (riscv_classify_address): Likewise.
21158         (riscv_legitimate_address_p): Likewise.
21159         (riscv_address_insns): Likewise.
21160         (riscv_load_store_insns): Likewise.
21161         (riscv_force_binary): Likewise.
21162         (riscv_split_symbol): Likewise.
21163         (riscv_force_address): Likewise.
21164         (riscv_legitimize_address): Likewise.
21165         (riscv_move_integer): Likewise.
21166         (riscv_legitimize_const_move): Likewise.
21167         (riscv_legitimize_move): Likewise.
21168         (riscv_address_cost): Likewise.
21169         (riscv_subword): Likewise.
21170         (riscv_output_move): Likewise.
21171         (riscv_canonicalize_int_order_test): Likewise.
21172         (riscv_emit_int_order_test): Likewise.
21173         (riscv_function_arg_boundary): Likewise.
21174         (riscv_pass_mode_in_fpr_p): Likewise.
21175         (riscv_pass_fpr_single): Likewise.
21176         (riscv_pass_fpr_pair): Likewise.
21177         (riscv_get_arg_info): Likewise.
21178         (riscv_function_arg): Likewise.
21179         (riscv_function_arg_advance): Likewise.
21180         (riscv_arg_partial_bytes): Likewise.
21181         (riscv_function_value): Likewise.
21182         (riscv_pass_by_reference): Likewise.
21183         (riscv_setup_incoming_varargs): Likewise.
21184         (riscv_print_operand): Likewise.
21185         (riscv_elf_select_rtx_section): Likewise.
21186         (riscv_save_restore_reg): Likewise.
21187         (riscv_for_each_saved_reg): Likewise.
21188         (riscv_register_move_cost): Likewise.
21189         (riscv_hard_regno_mode_ok_p): Likewise.
21190         (riscv_hard_regno_nregs): Likewise.
21191         (riscv_class_max_nregs): Likewise.
21192         (riscv_memory_move_cost): Likewise.
21193         * config/rl78/rl78-protos.h (rl78_split_movsi): Likewise.
21194         * config/rl78/rl78.c (rl78_split_movsi): Likewise.
21195         (rl78_addr_space_address_mode): Likewise.
21196         * config/rs6000/rs6000-c.c (altivec_resolve_overloaded_builtin):
21197         Likewise.
21198         * config/rs6000/rs6000.c (rs6000_init_hard_regno_mode_ok): Likewise.
21199         (rs6000_reassociation_width): Likewise.
21200         (rs6000_invalid_binary_op): Likewise.
21201         (fusion_p9_p): Likewise.
21202         (emit_fusion_p9_load): Likewise.
21203         (emit_fusion_p9_store): Likewise.
21204         * config/visium/visium-protos.h (prepare_move_operands): Likewise.
21205         (ok_for_simple_move_operands): Likewise.
21206         (ok_for_simple_move_strict_operands): Likewise.
21207         (ok_for_simple_arith_logic_operands): Likewise.
21208         (visium_legitimize_reload_address): Likewise.
21209         (visium_select_cc_mode): Likewise.
21210         (output_cbranch): Likewise.
21211         (visium_split_double_move): Likewise.
21212         (visium_expand_copysign): Likewise.
21213         (visium_expand_int_cstore): Likewise.
21214         (visium_expand_fp_cstore): Likewise.
21215         * config/visium/visium.c (visium_pass_by_reference): Likewise.
21216         (visium_function_arg): Likewise.
21217         (visium_function_arg_advance): Likewise.
21218         (visium_libcall_value): Likewise.
21219         (visium_setup_incoming_varargs): Likewise.
21220         (visium_legitimate_constant_p): Likewise.
21221         (visium_legitimate_address_p): Likewise.
21222         (visium_legitimize_address): Likewise.
21223         (visium_secondary_reload): Likewise.
21224         (visium_register_move_cost): Likewise.
21225         (visium_memory_move_cost): Likewise.
21226         (prepare_move_operands): Likewise.
21227         (ok_for_simple_move_operands): Likewise.
21228         (ok_for_simple_move_strict_operands): Likewise.
21229         (ok_for_simple_arith_logic_operands): Likewise.
21230         (visium_function_value_1): Likewise.
21231         (rtx_ok_for_offset_p): Likewise.
21232         (visium_legitimize_reload_address): Likewise.
21233         (visium_split_double_move): Likewise.
21234         (visium_expand_copysign): Likewise.
21235         (visium_expand_int_cstore): Likewise.
21236         (visium_expand_fp_cstore): Likewise.
21237         (visium_split_cstore): Likewise.
21238         (visium_select_cc_mode): Likewise.
21239         (visium_split_cbranch): Likewise.
21240         (output_cbranch): Likewise.
21241         (visium_print_operand_address): Likewise.
21242         * expmed.c (flip_storage_order): Likewise.
21243         * expmed.h (emit_cstore): Likewise.
21244         (flip_storage_order): Likewise.
21245         * genrecog.c (validate_pattern): Likewise.
21246         * hsa-gen.c (gen_hsa_addr): Likewise.
21247         * internal-fn.c (expand_arith_overflow): Likewise.
21248         * ira-color.c (allocno_copy_cost_saving): Likewise.
21249         * lra-assigns.c (find_hard_regno_for_1): Likewise.
21250         * lra-constraints.c (prohibited_class_reg_set_mode_p): Likewise.
21251         (process_invariant_for_inheritance): Likewise.
21252         * lra-eliminations.c (move_plus_up): Likewise.
21253         * omp-low.c (lower_oacc_reductions): Likewise.
21254         * simplify-rtx.c (simplify_subreg): Likewise.
21255         * target.def (TARGET_SETUP_INCOMING_VARARG_BOUNDS): Likewise.
21256         (TARGET_CHKP_BOUND_MODE): Likewise..
21257         * targhooks.c (default_chkp_bound_mode): Likewise.
21258         (default_setup_incoming_vararg_bounds): Likewise.
21259         * targhooks.h (default_chkp_bound_mode): Likewise.
21260         (default_setup_incoming_vararg_bounds): Likewise.
21261         * tree-ssa-math-opts.c (divmod_candidate_p): Likewise.
21262         * tree-vect-loop.c (calc_vec_perm_mask_for_shift): Likewise.
21263         (have_whole_vector_shift): Likewise.
21264         * tree-vect-stmts.c (vectorizable_load): Likewise.
21265         * doc/tm.texi: Regenerate.
21267 2017-07-05  Georg-Johann Lay  <avr@gjlay.de>
21269         Graceful degrade if Binutils PR21472 is not available.
21271         PR target/81072
21272         * configure.ac [target=avr]: WARN instead of ERROR if avrxmega3
21273         .rodata in flash test fails.
21274         (HAVE_LD_AVR_AVRXMEGA3_RODATA_IN_FLASH): Define it if test passes.
21275         * confgure: Regenerate.
21276         * config.in: Regenerate.
21277         * config/avr/avr.c (avr_asm_named_section)
21278         [HAVE_LD_AVR_AVRXMEGA3_RODATA_IN_FLASH]: Only trigger
21279         __do_copy_data for stuff in .rodata if flash_pm_offset = 0.
21280         (avr_asm_init_sections): Same.
21282 2017-07-05  Ramana Radhakrishnan  <ramana.radhakrishnan@arm.com>
21284         * config/arm/neon.md (fma<VCVTF:mode>4): Remove %?.
21285         (fma<VH:mode>4_intrinsic): Likewise.
21286         (*fmsub<VCVTF:mode>4): Likewise.
21287         (*fmsub<VH:mode>4_intrinsic): Likewise.
21289 2017-07-05  Georg-Johann Lay  <avr@gjlay.de>
21291         PR target/81305
21292         * config/avr/avr.c (avr_out_movhi_mr_r_xmega) [CONSTANT_ADDRESS_P]:
21293         Don't depend on "optimize > 0".
21294         (out_movhi_r_mr, out_movqi_mr_r): Same.
21295         (out_movhi_mr_r, out_movqi_r_mr): Same.
21296         (avr_address_cost) [CONSTANT_ADDRESS_P]: Don't depend cost for
21297         io_address_operand on "optimize > 0".
21299 2017-07-05  Bin Cheng  <bin.cheng@arm.com>
21301         * tree-loop-distribution.c: Add general explanantion on the pass.
21302         (generate_loops_for_partition): Mark distributed loop.
21303         (pg_add_dependence_edges): New parameter.  Handle alias data
21304         dependence specially and record it in the parameter if asked.
21305         (struct pg_vdata, pg_edata, pg_edge_callback_data): New structs.
21306         (init_partition_graph_vertices, add_partition_graph_edge): New.
21307         (pg_skip_alias_edge, free_partition_graph_edata_cb): New.
21308         (free_partition_graph_vdata, build_partition_graph): New.
21309         (sort_partitions_by_post_order, merge_dep_scc_partitions): New.
21310         (pg_collect_alias_ddrs, break_alias_scc_partitions): New.
21311         (data_ref_segment_size, latch_dominated_by_data_ref): New.
21312         (compute_alias_check_pairs, version_loop_by_alias_check): New.
21313         (version_for_distribution_p, finalize_partitions): New.
21314         (distribute_loop): Handle alias data dependence specially.  Factor
21315         out loop fusion code as functions and call these functions.
21317 2017-07-05  Bin Cheng  <bin.cheng@arm.com>
21319         * tree-loop-distribution.c (classify_partition): New parameter and
21320         better handle reduction statement.
21321         (rdg_build_partitions): Revise comment.
21322         (distribute_loop): Compute statements in all partitions and pass it
21323         to classify_partition.
21325 2017-07-05  Bin Cheng  <bin.cheng@arm.com>
21327         * tree-loop-distribution.c (enum partition_type): New.
21328         (struct partition): New field type.
21329         (partition_merge_into): Add parameter.  Update partition type.
21330         (data_dep_in_cycle_p, update_type_for_merge): New functions.
21331         (build_rdg_partition_for_vertex): Compute partition type.
21332         (rdg_build_partitions): Dump partition type.
21333         (distribute_loop): Update calls to partition_merge_into.
21335 2017-07-05  Bin Cheng  <bin.cheng@arm.com>
21337         * tree-loop-distribution.c (struct ddr_hasher): New.
21338         (ddr_hasher::hash, ::equal, get_data_dependence): New function.
21339         (ddrs_table): New.
21340         (classify_partition): Call get_data_dependence.
21341         (pg_add_dependence_edges): Ditto.
21342         (distribute_loop): Release data dependence hash table.
21344 2017-07-05  Bin Cheng  <bin.cheng@arm.com>
21346         * tree-loop-distribution.c (ref_base_address): Delete.
21347         (similar_memory_accesses): Rename ...
21348         (share_memory_accesses): ... to this.  Check if partitions access
21349         the same memory reference.
21350         (distribute_loop): Call share_memory_accesses.
21352 2017-07-05  Bin Cheng  <bin.cheng@arm.com>
21354         * tree-loop-distribution.c (struct partition): New field recording
21355         its data reference.
21356         (partition_alloc, partition_free): Init and release data refs.
21357         (partition_merge_into): Merge data refs.
21358         (build_rdg_partition_for_vertex): Collect data refs for partition.
21359         (pg_add_dependence_edges): Change parameters from vector to bitmap.
21360         Update uses.
21361         (distribute_loop): Remve data refs from vertice data of partition
21362         graph.
21364 2017-07-05  Bin Cheng  <bin.cheng@arm.com>
21366         * tree-loop-distribution.c (params.h): Include header file.
21367         (MAX_DATAREFS_NUM, DR_INDEX): New macro.
21368         (datarefs_vec): New global var.
21369         (create_rdg_vertices): Use datarefs_vec directly.
21370         (free_rdg): Don't free data references.
21371         (build_rdg): Update use.  Don't free data references.
21372         (distribute_loop): Compute global variable for data references.
21373         Bail out if there are too many data references.
21375 2017-07-05  Bin Cheng  <bin.cheng@arm.com>
21377         * tree-loop-distribution.c (loop_nest): New global var.
21378         (build_rdg): Use loop directly, rather than loop nest.
21379         (pg_add_dependence_edges): Remove loop nest parameter.  Use global
21380         variable directly.
21381         (distribute_loop): Compute global variable loop nest.  Update use.
21383 2017-07-05  Bin Cheng  <bin.cheng@arm.com>
21385         * tree-loop-distribution.c (enum fuse_type, fuse_message): New.
21386         (partition_merge_into): New parameter.  Dump reason for fusion.
21387         (distribute_loop): Update use of partition_merge_into.
21389 2017-07-05  Bin Cheng  <bin.cheng@arm.com>
21391         * tree-loop-distribution.c (bb_top_order_index): New.
21392         (bb_top_order_index_size, bb_top_order_cmp): New.
21393         (stmts_from_loop): Use topological order.
21394         (pass_loop_distribution::execute): Compute and release topological
21395         order for basic blocks.
21397 2017-07-05  Bin Cheng  <bin.cheng@arm.com>
21399         * tree-loop-distribution.c (pass_loop_distribution::execute): Skip
21400         if no loops.
21402 2017-07-05  Bin Cheng  <bin.cheng@arm.com>
21404         * cfgloop.h (struct loop): Add comment.  New field orig_loop_num.
21405         * cfgloopmanip.c (lv_adjust_loop_entry_edge): Comment change.
21406         * internal-fn.c (expand_LOOP_DIST_ALIAS): New function.
21407         * internal-fn.def (LOOP_DIST_ALIAS): New.
21408         * tree-vectorizer.c (fold_loop_vectorized_call): Rename to ...
21409         (fold_loop_internal_call): ... this.
21410         (vect_loop_dist_alias_call): New function.
21411         (set_uid_loop_bbs): Call fold_loop_internal_call.
21412         (vectorize_loops): Fold IFN_LOOP_VECTORIZED and IFN_LOOP_DIST_ALIAS
21413         internal calls.
21415 2017-07-04  Uros Bizjak  <ubizjak@gmail.com>
21417         PR target/81300
21418         * config/i386/i386.md (setcc + movzbl/and to xor + setcc peepholes):
21419         Require dead FLAGS_REG at the beginning of a peephole.
21421 2017-07-04  Uros Bizjak  <ubizjak@gmail.com>
21423         PR target/81294
21424         * config/i386/adxintrin.h (_subborrow_u32): Swap _X and _Y
21425         arguments in the call to __builtin_ia32_sbb_u32.
21426         (_subborrow_u64): Swap _X and _Y arguments in the call to
21427         __builtin_ia32_sbb_u64.
21429 2017-07-04  Jakub Jelinek  <jakub@redhat.com>
21431         PR debug/81278
21432         * tree-vrp.c (compare_assert_loc): Turn into a function template
21433         with stable template parameter.  Only test if a->e is NULL,
21434         !a->e == !b->e has been verified already.  Use e == NULL or
21435         e != NULL instead of e or ! e tests.  If stable is true, don't use
21436         iterative_hash_expr, on the other side allow a or b or both NULL
21437         and sort the NULLs last.
21438         (process_assert_insertions): Sort using compare_assert_loc<false>
21439         instead of compare_assert_loc, later sort using
21440         compare_assert_loc<true> before calling process_assert_insertions_for
21441         in a loop.  Use break instead of continue once seen NULL pointer.
21443 2017-07-04  Thomas Preud'homme  <thomas.preudhomme@arm.com>
21445         * config/arm/driver-arm.c (arm_cpu_table): Add entry for ARM
21446         Cortex-R7 and Cortex-R8 processors.
21448 2017-07-04  Jan Hubicka  <hubicka@ucw.cz>
21450         * ipa-utils.c (ipa_merge_profiles): Fix merging when dst is
21451         uninitialized while src is not.
21453 2017-07-04  Richard Earnshaw  <rearnsha@arm.com>
21455         * common/config/arm/arm-common.c: Adjust include path for
21456         arm-cpu-cdata.h
21457         * config/arm/t-arm (TM_H): Adjust path for arm-cpu.h.
21458         (arm-cpu.h): Create in build directory.  Adjust dependency rules.
21459         (arm-cpu-data.h): Likewise.
21460         (arm-cpu-cdata.h): Likewise.
21461         * config/arm/arm-cpu.h: Delete.
21462         * config/arm/arm-cpu-cdata.h: Delete.
21463         * config/arm/arm-cpu-data.h: Delete.
21465 2017-07-04  James Greenhalgh  <james.greenhalgh@arm.com>
21467         * config/arm/arm-cpus.in (cortex-a55): New.
21468         (cortex-a75): Likewise.
21469         (cortex-a75.cortex-a55): Likewise.
21470         * config/arm/driver-arm.c (arm_cpu_table): Add cortex-a55 and
21471         cortex-a75.
21472         * doc/invoke.texi (-mcpu): Document cortex-a55 and cortex-a75.
21473         * config/arm/arm-cpu-cdata.h: Regenerate.
21474         * config/arm/arm-cpu-data.h: Regenerate.
21475         * config/arm/arm-cpu.h: Regenerate.
21476         * config/arm/arm-tables.opt: Regenerate.
21477         * config/arm/arm-tune.md: Regenerate.
21479 2017-07-04  Jan Hubicka  <hubicka@ucw.cz>
21481         * haifa-sched.c (sched_create_recovery_edges): Update profile.
21483 2017-07-04  Jan Hubicka  <hubicka@ucw.cz>
21485         * bb-reorder.c (better_edge_p): Fix handling of uninitialized
21486         probability.
21488 2017-07-04  Richard Sandiford  <richard.sandiford@linaro.org>
21490         PR tree-optimization/81292
21491         * tree-ssa-strlen.c (handle_builtin_strlen): When setting
21492         full_string_p, also call adjust_related_strinfos if the adjustment
21493         is simple, otherwise invalidate related strinfos.
21495 2017-07-04  Martin Liska  <mliska@suse.cz>
21497         PR sanitizer/81040
21498         * sanopt.c (sanitize_rewrite_addressable_params): Mark the
21499         newly created variable as DECL_IGNORED_P.
21501 2017-07-04  Martin Liska  <mliska@suse.cz>
21503         PR ipa/81293
21504         * ipa-inline.c (inline_small_functions):
21505         Use xstrdup_for_dump.
21507 2017-07-04  Tom de Vries  <tom@codesourcery.com>
21509         * graph.c (draw_cfg_edges): Save and restore EDGE_DFS_BACK.
21511 2017-07-03  Dominique d'Humieres  <dominiq@lps.ens.fr>
21513         PR target/81033
21514         * config/darwin.c (darwin_function_switched_text_sections):
21515         Fix spaces.
21517 2017-07-03  Jan Hubicka  <hubicka@ucw.cz>
21519         * tree-vect-loop-manip.c (vect_do_peeling): Fix scaling up.
21521 2017-07-03  Richard Earnshaw  <rearnsha@arm.com>
21523         * doc/invoke.texi (ARM Options): Add -mbe8 and -mbe32 to option summary.
21525 2017-07-03  Richard Sandiford  <richard.sandiford@linaro.org>
21527         * tree-vect-loop.c (vect_analyze_loop_2): Treat min_scalar_loop_bound,
21528         min_profitable_iters, and th as inclusive lower bounds.
21529         Fix LOOP_VINFO_PEELING_FOR_GAPS condition.
21530         (vect_estimate_min_profitable_iters): Return inclusive lower bounds
21531         for min_profitable_iters and min_profitable_estimate.
21532         (vect_transform_loop): Treat th as an inclusive lower bound.
21533         * tree-vect-loop-manip.c (vect_loop_versioning): Likewise.
21535 2017-07-03  Dominique d'Humieres  <dominiq@lps.ens.fr>
21537         PR target/81033
21538         * config/darwin.c (darwin_function_switched_text_sections):
21539         Replace DECL_NAME with DECL_ASSEMBLER_NAME, split assemble_name_raw
21540         in two pieces, and suppress the use of buf.
21542 2017-07-03  Nathan Sidwell  <nathan@acm.org>
21544         * hash-table.h (hash_table_mod1): Fix indentation.
21546 2017-07-02  Jan Hubicka  <hubicka@ucw.cz>
21548         PR middle-end/81290
21549         * predict.c (force_edge_cold): Be more careful about propagation
21550         backward.
21551         * profile-count.h (profile_probability::guessed,
21552         profile_probability::fdo, profile_count::guessed, profile_count::fdo):
21553         New.
21554         * tree-ssa-threadupdate.c (recompute_probabilities): Result is guessed.
21556 2017-07-03  James Greenhalgh  <james.greenhalgh@arm.com>
21558         * doc/invoke.texi (rcpc architecture extension): Document it.
21560 2017-07-03  Richard Biener  <rguenther@suse.de>
21562         PR tree-optimization/60510
21563         * tree-vect-loop.c (vect_create_epilog_for_reduction): Pass in
21564         the scalar reduction PHI and use it.
21565         (vectorizable_reduction): Properly guard the single_defuse_cycle
21566         path for non-SLP reduction chains where we cannot use it.
21567         Rework reduc_def/index and vector type deduction.  Rework
21568         vector operand gathering during reduction op code-gen.
21569         * tree-vect-slp.c (vect_analyze_slp): For failed SLP reduction
21570         chains dissolve the chain and leave it to non-SLP reduction
21571         handling.
21573 2017-07-03  Richard Sandiford  <richard.sandiford@linaro.org>
21575         * tree-data-ref.h (dr_alignment): Declare.
21576         * tree-data-ref.c (dr_alignment): New function.
21577         * tree-vectorizer.h (dataref_aux): Remove base_element_aligned.
21578         * tree-vect-data-refs.c (vect_compute_data_ref_alignment): Don't
21579         set it.
21580         * tree-vect-stmts.c (vectorizable_store): Use dr_alignment.
21582 2017-07-03  Richard Sandiford  <richard.sandiford@linaro.org>
21584         * tree-data-ref.h (innermost_loop_behavior): Add base_alignment
21585         and base_misalignment fields.
21586         (DR_BASE_ALIGNMENT, DR_BASE_MISALIGNMENT): New macros.
21587         * tree-data-ref.c: Include builtins.h.
21588         (dr_analyze_innermost): Set up the new innmost_loop_behavior fields.
21589         * tree-vectorizer.h (STMT_VINFO_DR_BASE_ALIGNMENT): New macro.
21590         (STMT_VINFO_DR_BASE_MISALIGNMENT): Likewise.
21591         * tree-vect-data-refs.c: Include tree-cfg.h.
21592         (vect_compute_data_ref_alignment): Use the new innermost_loop_behavior
21593         fields instead of calculating an alignment here.
21594         (vect_analyze_data_refs): Use dr_analyze_innermost.  Dump the new
21595         innermost_loop_behavior fields.
21597 2017-07-03  Richard Sandiford  <richard.sandiford@linaro.org>
21599         * tree-data-ref.h (innermost_loop_behavior): Add a step_alignment
21600         field.
21601         (DR_STEP_ALIGNMENT): New macro.
21602         * tree-vectorizer.h (STMT_VINFO_DR_STEP_ALIGNMENT): Likewise.
21603         * tree-data-ref.c (dr_analyze_innermost): Initalize step_alignment.
21604         (create_data_ref): Print it.
21605         * tree-vect-stmts.c (vectorizable_load): Use the step alignment
21606         to tell whether the step preserves vector (mis)alignment.
21607         * tree-vect-data-refs.c (vect_compute_data_ref_alignment): Likewise.
21608         Move the check for an integer step and generalise to all INTEGER_CST.
21609         (vect_analyze_data_refs): Set DR_STEP_ALIGNMENT when setting DR_STEP.
21610         Print the outer step alignment.
21612 2017-07-03  Richard Sandiford  <richard.sandiford@linaro.org>
21614         * tree-data-ref.h (innermost_loop_behavior): Replace aligned_to
21615         with offset_alignment.
21616         (DR_ALIGNED_TO): Delete.
21617         (DR_OFFSET_ALIGNMENT): New macro.
21618         * tree-vectorizer.h (STMT_VINFO_DR_ALIGNED_TO): Delete.
21619         (STMT_VINFO_DR_OFFSET_ALIGNMENT): New macro.
21620         * tree-data-ref.c (dr_analyze_innermost): Update after above changes.
21621         (create_data_ref): Likewise.
21622         * tree-vect-data-refs.c (vect_compute_data_ref_alignment): Likewise.
21623         (vect_analyze_data_refs): Likewise.
21624         * tree-if-conv.c (if_convertible_loop_p_1): Use memset before
21625         creating dummy innermost behavior.
21627 2017-07-03  Richard Sandiford  <richard.sandiford@linaro.org>
21629         * tree-data-ref.h (dr_analyze_innermost): Replace the dr argument
21630         with a "innermost_loop_behavior *" and refeence tree.
21631         * tree-data-ref.c (dr_analyze_innermost): Likewise.
21632         (create_data_ref): Update call accordingly.
21633         * tree-predcom.c (find_looparound_phi): Likewise.
21635 2017-07-03  Richard Sandiford  <richard.sandiford@linaro.org>
21637         * tree-vectorizer.h (_stmt_vec_info): Replace individual dr_*
21638         fields with dr_wrt_vec_loop.
21639         (STMT_VINFO_DR_BASE_ADDRESS, STMT_VINFO_DR_INIT, STMT_VINFO_DR_OFFSET)
21640         (STMT_VINFO_DR_STEP, STMT_VINFO_DR_ALIGNED_TO): Update accordingly.
21641         (STMT_VINFO_DR_WRT_VEC_LOOP): New macro.
21642         (vect_dr_behavior): New function.
21643         (vect_create_addr_base_for_vector_ref): Remove loop parameter.
21644         * tree-vect-data-refs.c (vect_compute_data_ref_alignment): Use
21645         vect_dr_behavior.  Use a step_preserves_misalignment_p boolean to
21646         track whether the step preserves the misalignment.
21647         (vect_create_addr_base_for_vector_ref): Remove loop parameter.
21648         Use vect_dr_behavior.
21649         (vect_setup_realignment): Update call accordingly.
21650         (vect_create_data_ref_ptr): Likewise.  Use vect_dr_behavior.
21651         * tree-vect-loop-manip.c (vect_gen_prolog_loop_niters): Update
21652         call to vect_create_addr_base_for_vector_ref.
21653         (vect_create_cond_for_align_checks): Likewise.
21654         * tree-vect-patterns.c (vect_recog_bool_pattern): Copy
21655         STMT_VINFO_DR_WRT_VEC_LOOP as a block.
21656         (vect_recog_mask_conversion_pattern): Likewise.
21657         * tree-vect-stmts.c (compare_step_with_zero): Use vect_dr_behavior.
21658         (new_stmt_vec_info): Remove redundant zeroing.
21660 2017-07-03  Richard Earnshaw  <rearnsha@arm.com>
21662         * common/config/arm/arm-common.c (arm_be8_option): New function.
21663         * config/arm/arm-isa.h (isa_feature): Add new feature bit isa_bit_be8.
21664         (ISA_ARMv6): Add isa_bit_be8.
21665         * config/arm/arm.h (arm_be8_option): Add prototype.
21666         (BE8_SPEC_FUNCTION): New define.
21667         (EXTRA_SPEC_FUNCTIONS): Add BE8_SPEC_FUNCTION.
21668         * config/arm/arm.opt (mbig-endian): Mark as Negative of mlittle-endian.
21669         (mlittle-endian): Similarly.
21670         (mbe8, mbe32): New options.
21671         * config/arm/bpabi.h (BE8_LINK_SPEC): Call arm_be8_option.
21672         * doc/invoke.texi (ARM Options): Document -mbe8 and -mbe32.
21674 2017-07-02  Jan Hubicka  <hubicka@ucw.cz>
21676         * tree-cfg.c (gimple_find_sub_bbs): Fix profile updating.
21678 2017-07-02  Jan Hubicka  <hubicka@ucw.cz>
21680         * tree-cfgcleanup.c (want_merge_blocks_p): New function.
21681         (cleanup_tree_cfg_bb): Use it.
21682         * profile-count.h (profile_count::of_for_merging, profile_count::merge):
21683         New functions.
21684         * tree-cfg.c (gimple_merge_blocks): Use profile_count::merge.
21686 2017-07-02  Jan Hubicka  <hubicka@ucw.cz>
21688         PR bootstrap/81285
21689         * loop-doloop.c (add_test): Update profile.
21691 2017-07-03  Martin Liska  <mliska@suse.cz>
21693         PR sanitize/81040
21694         * sanopt.c (rewrite_usage_of_param): New function.
21695         (sanitize_rewrite_addressable_params): Likewise.
21696         (pass_sanopt::execute): Call rewrite_usage_of_param.
21698 2017-07-03  Richard Biener  <rguenther@suse.de>
21700         * tree-vect-loop.c (vect_create_epilog_for_reduction): Revert
21701         back to using VIEW_CONVERT_EXPR.
21703 2017-07-03  Martin Liska  <mliska@suse.cz>
21705         PR other/78366
21706         * doc/extend.texi: Document when a resolver function is
21707         generated for target_clones.
21709 2017-07-03  Martin Liska  <mliska@suse.cz>
21711         * asan.c (asan_emit_stack_protection): Unpoison just red zones
21712         and shadow memory of auto variables which are subject of
21713         use-after-scope sanitization.
21714         (asan_expand_mark_ifn): Add do set only when is_poison.
21716 2016-07-03  Richard Biener  <rguenther@suse.de>
21718         * tree-vect-loop.c (vect_analyze_loop_operations): Also analyze
21719         reduction PHIs.
21720         (vect_force_simple_reduction): Record reduction def -> phi mapping.
21721         (vectorizable_reduction): Perform reduction PHI creation when
21722         visiting a reduction PHI and adjust and simplify code generation
21723         phase of the reduction op.  Cache dts, use fold_binary, not fold_build2.
21724         (vect_transform_loop): Visit reduction PHIs.
21725         * tree-vect-slp.c (vect_get_and_check_slp_defs): Record reduction
21726         defs into the SLP tree.
21727         (vect_build_slp_tree): Reduction defs terminate the recursion.
21728         * tree-vect-stmts.c (vect_get_vec_def_for_operand_1): Allow lookup
21729         of reduction defs.
21730         (vect_get_vec_defs_for_stmt_copy): Export.
21731         (vect_get_vec_defs): Likewise.
21732         * tree-vectorizer.h (struct _stmt_vec_info): Amend reduc_def
21733         purpose.
21734         (vect_get_vec_defs_for_stmt_copy): Declare.
21735         (vect_get_vec_defs): Likewise.
21737 2017-07-03  Richard Sandiford  <richard.sandiford@linaro.org>
21739         * tree-data-ref.c (dr_analyze_innermost): Replace the "nest"
21740         parameter with a "loop" parameter and use it instead of the
21741         loop containing DR_STMT.  Don't check simple_iv when doing
21742         BB analysis.  Describe the two analysis modes in the comment.
21744 2017-07-03  Tom de Vries  <tom@codesourcery.com>
21746         PR tree-optimization/69468
21747         * tree-ssa-tail-merge.c (ignore_edge_flags): New constant.
21748         (find_same_succ_bb): Handle ignore_edge_flags.
21750 2017-07-03  Tom de Vries  <tom@codesourcery.com>
21752         PR tree-optimization/81192
21753         * tree-ssa-tail-merge.c (same_succ_hash): Use bb->loop_father->num in
21754         hash.
21755         (same_succ::equal): Don't find bbs to be equal if bb->loop_father
21756         differs.
21757         (find_same_succ_bb): Remove obsolete test on bb->loop_father->latch.
21759 2017-07-03  Tom de Vries  <tom@codesourcery.com>
21761         PR tree-optimization/81192
21762         * tree-ssa-tail-merge.c (same_succ_flush_bb): Handle
21763         BB_SAME_SUCC (bb) == NULL.
21765 2017-07-02  Jan Hubicka  <hubicka@ucw.cz>
21767         * cfgrtl.c (rtl_verify_edges): Enable checking of profile_probability
21768         consistency.
21770 2017-07-02  Jan Hubicka  <hubicka@ucw.cz>
21772         * dumpfile.c: Include profile-count.h
21773         * tree-cfg.c (gimple_duplicate_sese_tail): Drop UNUSED attributes;
21774         update profile.
21775         (insert_cond_bb): Update profile.
21776         * tree-cfg.h (insert_cond_bb): Update prototype.
21777         * tree-chkp-opt.c (chkp_optimize_string_function_calls): Update.
21778         * tree-dump.c: Do not include tree-cfg.
21780 2017-07-02  Jan Hubicka  <hubicka@ucw.cz>
21782         * bb-reorder.c (fix_up_crossing_landing_pad): Update profile.
21784 2017-07-02  Jan Hubicka  <hubicka@ucw.cz>
21786         * expect.c (dw2_build_landing_pads): Update profile of the landing pad
21787         bb.
21789 2017-07-02  Jan Hubicka  <hubicka@ucw.cz>
21791         * tree-complex.c (expand_complex_div_wide): update profile.
21793 2017-07-02  Richard Sandiford  <richard.sandiford@linaro.org>
21794             Alan Hayward  <alan.hayward@arm.com>
21795             David Sherwood  <david.sherwood@arm.com>
21797         * Makefile.in (MACHMODE_H): Remove insn-modes.h
21798         (CORETYPES_H): New define.
21799         (MOSTLYCLEANFILES): Add insn-modes-inline.h.
21800         (insn-modes-inline.h, s-modes-inline-h): New rules.
21801         (generated_files): Add insn-modes-inline.h.
21802         (RTL_BASE_H, TREE_CORE_H): Use CORETYPES_H instead of coretypes.h.
21803         (build/gensupport.o, build/ggc-none.o, build/print-rtl.o): Likewise.
21804         (build/read-md.o, build/read-rtl.o, build/rtl.o): Likewise.
21805         (build/vec.o, build/hash-table.o, build/inchash.o): Likewise.
21806         (build/gencondmd.o, build/genattr.o, build/genattr-common.o): Likewise.
21807         (build/genattrtab.o, build/genautomata.o, build/gencheck.o): Likewise.
21808         (build/gencodes.o, build/genconditions.o): Likewise.
21809         (build/genconfig.o, build/genconstants.o, build/genemit.o): Likewise.
21810         (build/genenums.o, build/genextract.o, build/genflags.o): Likewise.
21811         (build/gentarget-def.o, build/genmddeps.o, build/genopinit.o)
21812         (build/genoutput.o, build/genpeep.o, build/genpreds.o): Likewise.
21813         (build/genrecog.o, build/genmddump.o, build/genmatch.o): Likewise.
21814         (build/gencfn-macros.o, build/gcov-iov.o): Likewise.
21815         * coretypes.h: Include everything up to real.h for generators.
21816         Include insn-modes.h first.  Include wide-int-print.h after
21817         wide-int.h.  Include insn-modes-inline.h and then machmode.h.
21818         * machmode.h: Don't include insn-modes.h here.
21819         * function-tests.c: Remove includes of signop.h, machmode.h,
21820         double-int.h and wide-int.h.
21821         * rtl.h: Likewise.
21822         * gcc-rich-location.c: Remove includes of machmode.h, double-int.h
21823         and wide-int.h.
21824         * optc-save-gen.awk: Likewise.
21825         * gencheck.c (BITS_PER_UNIT): Delete dummy definition.
21826         * godump.c: Remove include of wide-int-print.h.
21827         * pretty-print.h: Likewise.
21828         * wide-int-print.cc: Likewise.
21829         * wide-int.cc: Likewise.
21830         * hash-map-tests.c: Remove include of signop.h.
21831         * hash-set-tests.c: Likewise.
21832         * rtl-tests.c: Likewise.
21833         * mkconfig.sh: Remove include of machmode.h.
21834         * genmodes.c (emit_insn_modes_h): Split emission of inline functions
21835         into...
21836         (emit_insn_modes_inline_h): ...this new function.  Emit the code
21837         into an insn-modes-inline.h header file, adding appropriate
21838         include guards and end comments.
21839         (emit_insn_modes_c_header): Remove include of machmode.h.
21840         (emit_min_insn_modes_c_header): Include coretypes.h rather than
21841         machmode.h.
21842         (main): Handle -i flag and call emit_insn_modes_inline_h when
21843         it is passed.
21845 2017-07-02  Richard Sandiford  <richard.sandiford@linaro.org>
21847         * tree-ssa-strlen.c (strinfo): Rename the length field to
21848         nonzero_chars.  Add a full_string_p field.
21849         (compare_nonzero_chars, zero_length_string_p): New functions.
21850         (get_addr_stridx): Add an offset_out parameter.
21851         Use compare_nonzero_chars.
21852         (get_stridx): Update accordingly.  Use compare_nonzero_chars.
21853         (new_strinfo): Update after above changes to strinfo.
21854         (set_endptr_and_length): Set full_string_p.
21855         (get_string_length): Update after above changes to strinfo.
21856         (unshare_strinfo): Update call to new_strinfo.
21857         (maybe_invalidate): Likewise.
21858         (get_stridx_plus_constant): Change off to unsigned HOST_WIDE_INT.
21859         Use compare_nonzero_chars and zero_string_p.  Treat nonzero_chars
21860         as a uhwi instead of an shwi.  Update after above changes to
21861         strinfo and new_strinfo.
21862         (zero_length_string): Assert that chainsi contains full strings.
21863         Use zero_length_string_p.  Update call to new_strinfo.
21864         (adjust_related_strinfos): Update after above changes to strinfo.
21865         Copy full_string_p from origsi.
21866         (adjust_last_stmt): Use zero_length_string_p.
21867         (handle_builtin_strlen): Update after above changes to strinfo and
21868         new_strinfo.  Install the lhs as the string length if the previous
21869         entry didn't describe a full string.
21870         (handle_builtin_strchr): Update after above changes to strinfo
21871         and new_strinfo.
21872         (handle_builtin_strcpy): Likewise.
21873         (handle_builtin_strcat): Likewise.
21874         (handle_builtin_malloc): Likewise.
21875         (handle_pointer_plus): Likewise.
21876         (handle_builtin_memcpy): Likewise.  Track nonzero characters
21877         that aren't necessarily followed by a nul terminator.
21878         (handle_char_store): Likewise.
21880 2017-07-02  Richard Sandiford  <richard.sandiford@linaro.org>
21882         PR tree-optimization/80769
21883         * tree-ssa-strlen.c (strinfo): Document that "stmt" is also used
21884         for malloc and calloc.  Document the new invariant that all related
21885         strinfos have delayed lengths or none do.
21886         (verify_related_strinfos): Move earlier in file.
21887         (set_endptr_and_length): New function, split out from...
21888         (get_string_length): ...here.  Also set the lengths of related
21889         strinfos.
21890         (zero_length_string): Assert that chainsi has known (rather than
21891         delayed) lengths.
21892         (adjust_related_strinfos): Likewise.
21894 2017-07-02  Richard Sandiford  <richard.sandiford@linaro.org>
21896         PR tree-optimization/81136
21897         * tree-vect-data-refs.c (vect_update_misalignment_for_peel): Only
21898         assert that two references with the same misalignment have the same
21899         compile-time misalignment if those compile-time misalignments
21900         are known.
21902 2017-07-01  Andi Kleen  <ak@linux.intel.com>
21904         * print-tree.c (print_node): Print all attributes.
21906 2017-07-01  Jan Hubicka  <hubicka@ucw.cz>
21908         * cfg.c (scale_bbs_frequencies): New function.
21909         * cfg.h (scale_bbs_frequencies): Declare it.
21910         * cfgloopanal.c (single_likely_exit): Cleanup.
21911         * cfgloopmanip.c (scale_loop_frequencies): Take profile_probability
21912         as parameter.
21913         (scale_loop_profile): Likewise.
21914         (loop_version): Likewise.
21915         (create_empty_loop_on_edge): Update.
21916         * cfgloopmanip.h (scale_loop_frequencies, scale_loop_profile,
21917         scale_loop_frequencies, scale_loop_profile, loopify,
21918         loop_version): Update prototypes.
21919         * modulo-sched.c (sms_schedule): Update.
21920         * predict.c (unlikely_executed_edge_p): Also check probability.
21921         (probably_never_executed_edge_p): Fix typo.
21922         * tree-if-conv.c (version_loop_for_if_conversion): Update.
21923         * tree-parloops.c (gen_parallel_loop): Update.
21924         * tree-ssa-loop-ivcanon.c (try_peel_loop): Update.
21925         * tree-ssa-loop-manip.c (tree_transform_and_unroll_loop): Update.
21926         * tree-ssa-loop-split.c (split_loop): Update.
21927         * tree-ssa-loop-unswitch.c (tree_unswitch_loop): Update.
21928         * tree-vect-loop-manip.c (vect_do_peeling): Update.
21929         (vect_loop_versioning): Update.
21930         * tree-vect-loop.c (scale_profile_for_vect_loop): Update.
21932 2017-07-01  Jan Hubicka  <hubicka@ucw.cz>
21934         * trans-mem.c (split_bb_make_tm_edge): Update profile.
21936 2017-07-01  Jan Hubicka  <hubicka@ucw.cz>
21938         * tree-if-conv.c (combine_blocks): Use make_single_succ_edge
21939         to keep profile consistent.
21941 2017-07-01  Jan Hubicka  <hubicka@ucw.cz>
21943         * cfgrtl.c (rtl_flow_call_edges_add): Update profile.
21944         * tree-cfg.c (gimple_flow_call_edges_add): Likewise.
21945         * profile-count.h (max_safe_multiplier): Make unsigned.
21946         (profile_count::guessed_zero): New.
21948 2017-07-01  Jan Hubicka  <hubicka@ucw.cz>
21950         * bb-reorder.c (fix_up_crossing_landing_pad,
21951         fix_crossing_conditional_branches): Use make_single_succ_edge
21952         to keep profile consistent.
21954 2017-07-01  Jan Hubicka  <hubicka@ucw.cz>
21956         * tree-vect-loop.c (optimize_mask_stores): Use make_single_succ_edge
21957         to update profile.
21959 2017-07-01  Jakub Jelinek  <jakub@redhat.com>
21961         PR sanitizer/81262
21962         * bb-reorder.c (fix_up_fall_thru_edges): Move variable declarations to
21963         the right scopes, make sure cond_jump isn't preserved between multiple
21964         iterations.  Search for fallthru edge whenever there are 3+ edges and
21965         use find_fallthru_edge for it.
21967 2017-06-29  Jan Hubicka  <hubicka@ucw.cz>
21969         Patch by Alexander Monakov <amonakov@ispras.ru>
21970         * sel-sched-ir.c (compute_succs_info): Handle uninitialized
21971         probabilities consistently.
21973 2017-06-29  Jan Hubicka  <hubicka@ucw.cz>
21975         * pa.c (pa_expand_compare_and_swap_loop): Update call of
21976         emit_cmp_and_jump_insns.
21978 2017-06-29  Jan Hubicka  <hubicka@ucw.cz>
21980         PR ipa/81261
21981         * tree-inline.c (expand_call_inline): Combine profile statuses.
21983 2017-06-30  Andrew Pinski  <apinski@cavium.com>
21985         * tree-if-conv.c (predicate_scalar_phi): Update new_stmt if
21986         fold_stmt returned true.
21988 2017-06-30  Nathan Sidwell  <nathan@acm.org>
21990         * ggc.h (empty_string): Delete.
21991         * cfgexpand.c (expand_asm_stmt): Use plain "".
21992         * optabs.c (expand_asm_memory_barrier): Likewise.
21993         * stringpool.c (empty_string): Delete.
21994         (digit_vector, digit_string): Delete.
21995         (ggc_alloc_string): Use plain "", don't optimize single digit
21996         strings.  Use ggc_alloc_atomic.
21998 2017-06-30  Richard Earnshaw  <rearnsha@arm.com>
22000         * rtlanal.c (insn_rtx_cost): If a parallel contains exactly one
22001         comparison set and one other set, use the cost of the non-comparison
22002         set.
22004 2017-06-30  Nathan Sidwell  <nathan@acm.org>
22006         * ggc.h: Replace all 'static inline' with plain 'inline'.  Fix
22007         some formatting.
22009 2017-06-30  Peter Bergner  <bergner@vnet.ibm.com>
22011         * tree-cfg.c (group_case_labels_stmt): Merge scanning and compressing
22012         loops.  Remove now unneeded calls to gimple_switch_set_label() that
22013         just set removed labels to NULL_TREE.
22015 2017-06-30  Aldy Hernandez  <aldyh@redhat.com>
22017         * tree-ssanames.c (set_range_info_raw): Abstract from ...
22018         (set_range_info): ...here.  Only call set_range_info_raw if domain
22019         is useful.
22020         (set_nonzero_bits): Call set_range_info_raw.
22021         * tree-ssanames.h (set_range_info_raw): New.
22023 2017-06-30  Jakub Jelinek  <jakub@redhat.com>
22025         PR target/81225
22026         * config/i386/sse.md (vec_extract_lo_<mode><mask_name>): For V8FI,
22027         V16FI and VI8F_256 iterators, use <store_mask_predicate> instead
22028         of nonimmediate_operand and <store_mask_constraint> instead of m
22029         for the input operand.  For V8FI iterator, always split if input
22030         is a MEM.  For V16FI and V8SF_256 iterators, don't test if both
22031         operands are MEM if <mask_applied>.  For VI4F_256 iterator, use
22032         <store_mask_predicate> instead of register_operand and
22033         <store_mask_constraint> instead of v for the input operand.  Make
22034         sure both operands aren't MEMs for if not <mask_applied>.
22036 2017-06-30  Sylvestre Ledru  <sylvestre@debian.org>
22038         * lto-wrapper.c (copy_file) Close both file descriptors before
22039         exiting normally.
22041 2017-06-30  Martin Liska  <mliska@suse.cz>
22043         PR ipa/81214
22044         * multiple_target.c (create_dispatcher_calls): Make ifunc
22045         also for function that don't have calls or are not referenced.
22047 2017-06-30  Richard Biener  <rguenther@suse.de>
22049         * tree-vect-slp.c (vect_slp_analyze_node_operations): Only
22050         analyze the first scalar stmt.  Move vector type computation
22051         for the BB case here from ...
22052         * tree-vect-stmts.c (vect_analyze_stmt): ... here.  Guard
22053         live operation processing in the SLP case properly.
22055 2017-06-30  Richard Biener  <rguenther@suse.de>
22057         * graph.c (draw_cfg_node_succ_edges): Fix broken dot syntax.
22059 2017-06-30  Martin Liska  <mliska@suse.cz>
22061         PR sanitizer/81021
22062         * tree-eh.c (lower_resx): Call BUILT_IN_ASAN_HANDLE_NO_RETURN
22063         before BUILT_IN_UNWIND_RESUME when ASAN is used.
22065 2017-06-30  Yvan Roux  <yvan.roux@linaro.org>
22067         * doc/invoke.texi (AArch64): Add missing options and remove redundant
22068         ones.
22070 2017-06-30  Richard Biener  <rguenther@suse.de>
22072         PR tree-optimization/81249
22073         * tree-vect-loop.c (vect_create_epilog_for_reduction): Convert
22074         condition reduction result to original scalar type.
22076 2017-06-30  Andreas Krebbel  <krebbel@linux.vnet.ibm.com>
22078         * profile-count.h (enum profile_quality): Fix typos and whitespace
22079         issues.
22081 2017-06-30  Andreas Krebbel  <krebbel@linux.vnet.ibm.com>
22083         * config/s390/s390.c (s390_expand_setmem): Adjust to the new data
22084         type for branch probabilities.
22086 2017-06-29  Julian Brown  <julian@codesourcery.com>
22087             Naveen H.S  <Naveen.Hurugalawadi@cavium.com>
22089         * config/aarch64/aarch64-fusion-pairs.def: Add ALU_BRANCH entry.
22090         * config/aarch64/aarch64.c (AARCH64_FUSE_ALU_BRANCH): New fusion type.
22091         (thunderx2t99_tunings): Set AARCH64_FUSE_ALU_BRANCH flag.
22092         (aarch_macro_fusion_pair_p): Add support for AARCH64_FUSE_ALU_BRANCH.
22094 2017-06-29  Naveen H.S  <Naveen.Hurugalawadi@cavium.com>
22096         * config/aarch64/aarch64.c (aarch_macro_fusion_pair_p): Push the
22097         check for CC usage into AARCH64_FUSE_CMP_BRANCH.
22098         * config/i386/i386.c (ix86_macro_fusion_pair_p): Push the check for
22099         CC usage from generic code to here.
22100         * sched-deps.c (sched_macro_fuse_insns): Move the condition for
22101         CC usage into the target macros.
22103 2017-06-29  Maya Rashish  <coypu@sdf.org>
22105         * config/netbsd.h (NETBSD_LIB_SPEC): Add -lc when creating shared
22106         objects.
22108 2017-06-29  Jan Hubicka  <hubicka@ucw.cz>
22110         * arm/arm-builtins.c: Include profile-count.h
22111         * except.c (sjlj_emit_function_enter): Use
22112         profile_probability::unlikely.
22114 2017-06-29  Aaron Sawdey  <acsawdey@linux.vnet.ibm.com>
22116         * config/rs6000/rs6000.c (toc_relative_expr_p): Make tocrel_base
22117         and tocrel_offset be pointer args rather than implicitly using
22118         static versions.
22119         (legitimate_constant_pool_address_p, rs6000_emit_move,
22120         const_load_sequence_p, adjust_vperm): Add local tocrel_base and
22121         tocrel_offset and use in toc_relative_expr_p call.
22122         (print_operand, print_operand_address): Use static tocrel_base_oac
22123         and tocrel_offset_oac.
22124         (rs6000_output_addr_const_extra): Use static tocrel_base_oac and
22125         tocrel_offset_oac.
22127 2017-06-29  Maya Rashish  <coypu@sdf.org>
22129         * config/vax/builtins.md (ffssi2_internal): Correct constraint.
22131 2017-06-29  Eric Botcazou  <ebotcazou@adacore.com>
22133         * expr.c (expand_expr) <normal_inner_ref>: When testing for unaligned
22134         objects, take into account only the alignment of 'op0' and 'mode1' if
22135         'op0' is a MEM.
22137 2017-06-29  Steve Ellcey  <sellcey@cavium.com>
22139         * ccmp.c (ccmp_tree_comparison_p): New function.
22140         (ccmp_candidate_p): Update to use above function.
22141         (get_compare_parts): New function.
22142         (expand_ccmp_next): Update to use new functions.
22143         (expand_ccmp_expr_1): Take tree arg instead of gimple, update to use
22144         new functions.
22145         (expand_ccmp_expr): Pass tree instead of gimple to expand_ccmp_expr_1,
22146         take mode as argument.
22147         * ccmp.h (expand_ccmp_expr): Add mode as argument.
22148         * expr.c (expand_expr_real_1): Pass mode as argument.
22150 2017-06-29  Segher Boessenkool  <segher@kernel.crashing.org>
22152         * combine.c (combine_instructions): Print insns to dump_file, together
22153         with their costs.
22155 2017-06-29  Jan Hubicka  <hubicka@ucw.cz>
22157         * asan.c (asan_emit_stack_protection): Update.
22158         (create_cond_insert_point): Update.
22159         * auto-profile.c (afdo_propagate_circuit): Update.
22160         * basic-block.h (struct edge_def): Turn probability to
22161         profile_probability.
22162         (EDGE_FREQUENCY): Update.
22163         * bb-reorder.c (find_traces_1_round): Update.
22164         (better_edge_p): Update.
22165         (sanitize_hot_paths): Update.
22166         * cfg.c (unchecked_make_edge): Initialize probability to uninitialized.
22167         (make_single_succ_edge): Update.
22168         (check_bb_profile): Update.
22169         (dump_edge_info): Update.
22170         (update_bb_profile_for_threading): Update.
22171         * cfganal.c (connect_infinite_loops_to_exit): Initialize new edge
22172         probabilitycount to 0.
22173         * cfgbuild.c (compute_outgoing_frequencies): Update.
22174         * cfgcleanup.c (try_forward_edges): Update.
22175         (outgoing_edges_match): Update.
22176         (try_crossjump_to_edge): Update.
22177         * cfgexpand.c (expand_gimple_cond): Update make_single_succ_edge.
22178         (expand_gimple_tailcall): Update.
22179         (construct_init_block): Use make_single_succ_edge.
22180         (construct_exit_block): Use make_single_succ_edge.
22181         * cfghooks.c (verify_flow_info): Update.
22182         (redirect_edge_succ_nodup): Update.
22183         (split_edge): Update.
22184         (account_profile_record): Update.
22185         * cfgloopanal.c (single_likely_exit): Update.
22186         * cfgloopmanip.c (scale_loop_profile): Update.
22187         (set_zero_probability): Remove.
22188         (duplicate_loop_to_header_edge): Update.
22189         * cfgloopmanip.h (loop_version): Update prototype.
22190         * cfgrtl.c (try_redirect_by_replacing_jump): Update.
22191         (force_nonfallthru_and_redirect): Update.
22192         (update_br_prob_note): Update.
22193         (rtl_verify_edges): Update.
22194         (purge_dead_edges): Update.
22195         (rtl_lv_add_condition_to_bb): Update.
22196         * cgraph.c: (cgraph_edge::redirect_call_stmt_to_calle): Update.
22197         * cgraphunit.c (init_lowered_empty_function): Update.
22198         (cgraph_node::expand_thunk): Update.
22199         * cilk-common.c: Include profile-count.h
22200         * dojump.c (inv): Remove.
22201         (jumpifnot): Update.
22202         (jumpifnot_1): Update.
22203         (do_jump_1): Update.
22204         (do_jump): Update.
22205         (do_jump_by_parts_greater_rtx): Update.
22206         (do_compare_rtx_and_jump): Update.
22207         * dojump.h (jumpifnot, jumpifnot_1, jumpif_1, jumpif, do_jump,
22208         do_jump_1. do_compare_rtx_and_jump): Update prototype.
22209         * dwarf2cfi.c: Include profile-count.h
22210         * except.c (dw2_build_landing_pads): Use make_single_succ_edge.
22211         (sjlj_emit_dispatch_table): Likewise.
22212         * explow.c: Include profile-count.h
22213         * expmed.c (emit_store_flag_force): Update.
22214         (do_cmp_and_jump): Update.
22215         * expr.c (compare_by_pieces_d::generate): Update.
22216         (compare_by_pieces_d::finish_mode): Update.
22217         (emit_block_move_via_loop): Update.
22218         (store_expr_with_bounds): Update.
22219         (store_constructor): Update.
22220         (expand_expr_real_2): Update.
22221         (expand_expr_real_1): Update.
22222         * expr.h (try_casesi, try_tablejump): Update prototypes.
22223         * gimple-pretty-print.c (dump_probability): Update.
22224         (dump_profile): New.
22225         (dump_gimple_label): Update.
22226         (dump_gimple_bb_header): Update.
22227         * graph.c (draw_cfg_node_succ_edges): Update.
22228         * hsa-gen.c (convert_switch_statements): Update.
22229         * ifcvt.c (cheap_bb_rtx_cost_p): Update.
22230         (find_if_case_1): Update.
22231         (find_if_case_2): Update.
22232         * internal-fn.c (expand_arith_overflow_result_store): Update.
22233         (expand_addsub_overflow): Update.
22234         (expand_neg_overflow): Update.
22235         (expand_mul_overflow): Update.
22236         (expand_vector_ubsan_overflow): Update.
22237         * ipa-cp.c (good_cloning_opportunity_p): Update.
22238         * ipa-split.c (split_function): Use make_single_succ_edge.
22239         * ipa-utils.c (ipa_merge_profiles): Update.
22240         * loop-doloop.c (add_test): Update.
22241         (doloop_modify): Update.
22242         * loop-unroll.c (compare_and_jump_seq): Update.
22243         (unroll_loop_runtime_iterations): Update.
22244         * lra-constraints.c (lra_inheritance): Update.
22245         * lto-streamer-in.c (input_cfg): Update.
22246         * lto-streamer-out.c (output_cfg): Update.
22247         * mcf.c (adjust_cfg_counts): Update.
22248         * modulo-sched.c (sms_schedule): Update.
22249         * omp-expand.c (expand_omp_for_init_counts): Update.
22250         (extract_omp_for_update_vars): Update.
22251         (expand_omp_ordered_sink): Update.
22252         (expand_omp_for_ordered_loops): Update.
22253         (expand_omp_for_generic): Update.
22254         (expand_omp_for_static_nochunk): Update.
22255         (expand_omp_for_static_chunk): Update.
22256         (expand_cilk_for): Update.
22257         (expand_omp_simd): Update.
22258         (expand_omp_taskloop_for_outer): Update.
22259         (expand_omp_taskloop_for_inner): Update.
22260         * omp-simd-clone.c (simd_clone_adjust): Update.
22261         * optabs.c (expand_doubleword_shift): Update.
22262         (expand_abs): Update.
22263         (emit_cmp_and_jump_insn_1): Update.
22264         (expand_compare_and_swap_loop): Update.
22265         * optabs.h (emit_cmp_and_jump_insns): Update prototype.
22266         * predict.c (predictable_edge_p): Update.
22267         (edge_probability_reliable_p): Update.
22268         (set_even_probabilities): Update.
22269         (combine_predictions_for_insn): Update.
22270         (combine_predictions_for_bb): Update.
22271         (propagate_freq): Update.
22272         (estimate_bb_frequencies): Update.
22273         (force_edge_cold): Update.
22274         * profile-count.c (profile_count::dump): Add missing space into dump.
22275         (profile_count::debug): Add newline.
22276         (profile_count::differs_from_p): Explicitly convert to unsigned.
22277         (profile_count::stream_in): Update.
22278         (profile_probability::dump): New member function.
22279         (profile_probability::debug): New member function.
22280         (profile_probability::differs_from_p): New member function.
22281         (profile_probability::differs_lot_from_p): New member function.
22282         (profile_probability::stream_in): New member function.
22283         (profile_probability::stream_out): New member function.
22284         * profile-count.h (profile_count_quality): Rename to ...
22285         (profile_quality): ... this one.
22286         (profile_probability): New.
22287         (profile_count): Update.
22288         * profile.c (compute_branch_probabilities): Update.
22289         * recog.c (peep2_attempt): Update.
22290         * sched-ebb.c (schedule_ebbs): Update.
22291         * sched-rgn.c (find_single_block_region): Update.
22292         (compute_dom_prob_ps): Update.
22293         (schedule_region): Update.
22294         * sel-sched-ir.c (compute_succs_info): Update.
22295         * stmt.c (struct case_node): Update.
22296         (do_jump_if_equal): Update.
22297         (get_outgoing_edge_probs): Update.
22298         (conditional_probability): Update.
22299         (emit_case_dispatch_table): Update.
22300         (expand_case): Update.
22301         (expand_sjlj_dispatch_table): Update.
22302         (emit_case_nodes): Update.
22303         * targhooks.c: Update.
22304         * tracer.c (better_p): Update.
22305         (find_best_successor): Update.
22306         * trans-mem.c (expand_transaction): Update.
22307         * tree-call-cdce.c: Update.
22308         * tree-cfg.c (gimple_split_edge): Upate.
22309         (move_sese_region_to_fn): Upate.
22310         * tree-cfgcleanup.c (cleanup_control_expr_graph): Upate.
22311         * tree-eh.c (lower_resx): Upate.
22312         (cleanup_empty_eh_move_lp): Upate.
22313         * tree-if-conv.c (version_loop_for_if_conversion): Update.
22314         * tree-inline.c (copy_edges_for_bb): Update.
22315         (copy_cfg_body): Update.
22316         * tree-parloops.c (gen_parallel_loop): Update.
22317         * tree-profile.c (gimple_gen_ic_func_profiler): Update.
22318         (gimple_gen_time_profiler): Update.
22319         * tree-ssa-dce.c (remove_dead_stmt): Update.
22320         * tree-ssa-ifcombine.c (update_profile_after_ifcombine): Update.
22321         * tree-ssa-loop-im.c (execute_sm_if_changed): Update.
22322         * tree-ssa-loop-ivcanon.c (remove_exits_and_undefined_stmts): Update.
22323         (unloop_loops): Update.
22324         (try_peel_loop): Update.
22325         * tree-ssa-loop-manip.c (tree_transform_and_unroll_loop): Update.
22326         * tree-ssa-loop-split.c (connect_loops): Update.
22327         (split_loop): Update.
22328         * tree-ssa-loop-unswitch.c (tree_unswitch_loop): Update.
22329         (hoist_guard): Update.
22330         * tree-ssa-phionlycprop.c (propagate_rhs_into_lhs): Update.
22331         * tree-ssa-phiopt.c (replace_phi_edge_with_variable): Update.
22332         (value_replacement): Update.
22333         * tree-ssa-reassoc.c (branch_fixup): Update.
22334         * tree-ssa-tail-merge.c (replace_block_by): Update.
22335         * tree-ssa-threadupdate.c (remove_ctrl_stmt_and_useless_edges): Update.
22336         (create_edge_and_update_destination_phis): Update.
22337         (compute_path_counts): Update.
22338         (recompute_probabilities): Update.
22339         (update_joiner_offpath_counts): Update.
22340         (freqs_to_counts_path): Update.
22341         (duplicate_thread_path): Update.
22342         * tree-switch-conversion.c (hoist_edge_and_branch_if_true): Update.
22343         (struct switch_conv_info): Update.
22344         (gen_inbound_check): Update.
22345         * tree-vect-loop-manip.c (slpeel_add_loop_guard): Update.
22346         (vect_do_peeling): Update.
22347         (vect_loop_versioning): Update.
22348         * tree-vect-loop.c (scale_profile_for_vect_loop): Update.
22349         (optimize_mask_stores): Update.
22350         * ubsan.c (ubsan_expand_null_ifn): Update.
22351         * value-prof.c (gimple_divmod_fixed_value): Update.
22352         (gimple_divmod_fixed_value_transform): Update.
22353         (gimple_mod_pow2): Update.
22354         (gimple_mod_pow2_value_transform): Update.
22355         (gimple_mod_subtract): Update.
22356         (gimple_mod_subtract_transform): Update.
22357         (gimple_ic): Update.
22358         (gimple_stringop_fixed_value): Update.
22359         (gimple_stringops_transform): Update.
22360         * value-prof.h: Update.
22362 2017-06-29  Carl Love  <cel@us.ibm.com>
22364         * config/rs6000/rs6000-c.c: Add support for built-in functions
22365         vector signed int vec_signed (vector float);
22366         vector signed long long vec_signed (vector double);
22367         vector signed int vec_signed2 (vector double, vector double);
22368         vector signed int vec_signede (vector double);
22369         vector signed int vec_signedo (vector double);
22370         * config/rs6000/rs6000.c (rs6000_generate_vsigned2_code): Add
22371         instruction generator.
22372         * config/rs6000/vsx.md (UNSPEC_VSX_XVCVSPSXWS, UNSPEC_VSX_XVCVSPSXDS,
22373         UNSPEC_VSX_VSIGNED2): Add UNSPECS.
22374         (vsx_xvcvspsxws, vsx_xvcvdpuxds_scale, vsx_xvcvspuxws, vsigned2_v2df):
22375         Add define_insn.
22376         (vsignedo_v2df, vsignede_v2df, vunsigned2_v2df, vunsignedo_v2df,
22377         vunsignede_v2df): Add define_expands.
22378         * config/rs6000/rs6000-builtin.def (VEC_SIGNED, VEC_UNSIGNED,
22379         VEC_SIGNED2, VEC_UNSIGNED2, VEC_SIGNEDE, VEC_UNSIGNEDE, VEC_SIGNEDO,
22380         VEC_UNSIGNEDO): Add definitions.
22381         * config/vsx.md (UNSPEC_VSX_XVCVSPSXWS, UNSPEC_VSX_XVCVSPSXDS,
22382         UNSPEC_VSX_VSIGNED2): Add UNSPECs.
22383         (vsx_xvcvspsxws, vsx_xvcvspuxws): Add define_insn.
22384         (vsigned2_v2df, vsigendo_v2df, vsignede_v2df,
22385         vunsigned2_v2df, vunsignedo_v2df, vunsignede_v2df): Add define_expands.
22386         * config/rs6000/altivec.h (vec_signed, vec_signed2,
22387         vec_signede and vec_signedo, vec_unsigned, vec_unsigned2,
22388         vec_unsignede, vec_unsignedo): Add builtin defines.
22389         * config/rs6000-protos.h (rs6000_generate_vsigned2_code): Add extern
22390         declaration.
22391         * doc/extend.texi: Update the built-in documentation file for the
22392         new built-in functions.
22394 2017-06-29  Richard Biener  <rguenther@suse.de>
22396         * tree-vect-loop.c (vect_analyze_scalar_cycles_1): Do not add
22397         reduction chains to LOOP_VINFO_REDUCTIONS.
22398         * tree-vect-slp.c (vect_analyze_slp): Continue looking for
22399         SLP reductions after processing reduction chains.
22401 2017-06-29  Nathan Sidwell  <nathan@acm.org>
22403         * builtins.c (fold_builtin_FUNCTION): Use
22404         lang_hooks.decl_printable_name.
22406 2017-06-29  Peter Bergner  <bergner@vnet.ibm.com>
22408         PR middle-end/81194
22409         * cfgexpand.c (expand_gimple_stmt_1): Handle switch statements
22410         with only one label.
22411         * stmt.c (expand_case): Assert NCASES is greater than one.
22413 2017-06-29  Richard Biener  <rguenther@suse.de>
22415         * tree-cfg.c (group_case_labels_stmt): Return whether we changed
22416         anything.
22417         (group_case_labels): Likewise.
22418         (find_taken_edge): Push sanity checking on val to workers...
22419         (find_taken_edge_cond_expr): ... here
22420         (find_taken_edge_switch_expr): ... and here, handle cases
22421         with just a default label.
22422         * tree-cfg.h (group_case_labels_stmt): Adjust prototype.
22423         (group_case_labels): Likewise.
22424         * tree-cfgcleanup.c (execute_cleanup_cfg_post_optimizing): When
22425         group_case_labels does anything cleanup the CFG again.
22427 2017-06-29  Bin Cheng  <bin.cheng@arm.com>
22429         PR tree-optimization/81196
22430         * tree-ssa-loop-niter.c (number_of_iterations_cond): Handle loop
22431         exit condition comparing two IVs.
22433 2017-06-29  Richard Earnshaw  <rearnsha@arm.com>
22435         * config/arm/parsecpu.awk (gen_comm_data): Add initializer for
22436         profile to the dummy entry at the end of the list of architectures.
22437         * config/arm/arm-cpu-cdata.h: Regenerated.
22439 2017-06-29  Kyrylo Tkachov  <kyrylo.tkachov@arm.com>
22440             Michael Collison <michael.collison@arm.com>
22442         PR target/70119
22443         * config/aarch64/aarch64.md (*aarch64_<optab>_reg_<mode>3_mask1):
22444         New pattern.
22445         (*aarch64_reg_<mode>3_neg_mask2): New pattern.
22446         (*aarch64_reg_<mode>3_minus_mask): New pattern.
22447         (*aarch64_<optab>_reg_di3_mask2): New pattern.
22448         * config/aarch64/aarch64.c (aarch64_rtx_costs): Account for cost
22449         of shift when the shift amount is masked with constant equal to
22450         the size of the mode.
22451         * config/aarch64/predicates.md (subreg_lowpart_operator): New
22452         predicate.
22454 2017-06-29  Martin Liska  <mliska@suse.cz>
22456         * config/i386/i386.opt: Change range from [1,5] to [0,5].
22458 2017-06-29  Yury Gribov  <tetra2005@gmail.com>
22460         PR bootstrap/80565
22461         * ipa-cp.c (allocate_and_init_ipcp_value): Add initialization
22462         code.
22463         * ipa-inline.h
22464         (edge_growth_cache_entry::edge_growth_cache_entry): New
22465         function.
22466         (reset_edge_growth_cache): Update to use constructor.
22468 2017-06-28  Ramana Radhakrishnan  <ramana.radhakrishnan@arm.com>
22470         * config/aarch64/aarch64.h (AARCH64_EXPAND_ALIGNMENT): New.
22471         (DATA_ALIGNMENT): Update to use AARCH64_EXPAND_ALIGNMENT.
22472         (LOCAL_ALIGNMENT): Update to use AARCH64_EXPAND_ALIGNMENT.
22474 2017-06-28  Sebastian Peryt  <sebastian.peryt@intel.com>
22476         * config/i386/avx512vlintrin.h (_mm256_permutexvar_epi64)
22477         (_mm256_permutexvar_epi32, _mm256_permutex_epi64): New intrinsics.
22479 2017-06-28  Szabolcs Nagy  <szabolcs.nagy@arm.com>
22481         * config.gcc (*-linux-musl*): Add t-musl tmake_file.
22482         (*-linux-uclibc*): Add t-uclibc tmake_file.
22483         * config/t-musl: New.
22484         * config/t-uclibc: New.
22486 2017-06-28  Richard Earnshaw  <rearnsha@arm.com>
22488         * config/arm/parsecpu.awk (profile): Parse new keyword in an arch
22489         context.
22490         (gen_comm_data): Emit architectural setting of arch_prof.
22491         * config/arm/arm-cpus.in (armv6-m, armv6s-m, armv7-a, armv7ve): Set the
22492         profile.
22493         (armv7-r, armv7-m, armv7e-m, armv8-a, armv8.1-a, armv8.2-a): Likewise.
22494         (armv8-m.base, armv8-m.main): Likewise.
22495         * arm-protos.h (arm_build_target): Add profile field.
22496         (arch_option): Likewise.
22497         * config/arm/arm.c (arm_configure_build_target): Copy the profile to
22498         the active target.
22499         * config/arm/arm.h (TARGET_ARM_ARCH_PROFILE): Use
22500         arm_active_target.profile.
22502 2017-06-28  Richard Biener  <rguenther@suse.de>
22504         PR middle-end/81227
22505         * fold-const.c (negate_expr_p): Use TYPE_UNSIGNED, not
22506         TYPE_OVERFLOW_WRAPS.
22507         * match.pd (negate_expr_p): Likewise.
22508         * tree-ssa-reassoc.c (optimize_range_tests_diff): Use
22509         fold_build2, not fold_binary.
22511 2017-06-28  Wilco Dijkstra  <wdijkstr@arm.com>
22513         * config/aarch64/aarch64 (aarch64_expand_mov_immediate):
22514         Convert memory address to Pmode.
22515         (aarch64_print_operand): Assert MEM operands are always Pmode.
22517 2017-06-28  Wilco Dijkstra  <wdijkstr@arm.com>
22519         PR target/79665
22520         * config/arm/aarch-common.c (arm_no_early_alu_shift_dep):
22521         Remove redundant if.
22522         (aarch_forward_to_shift_is_not_shifted_reg): Remove.
22523         * config/arm/aarch-common-protos.h
22524         (aarch_forward_to_shift_is_not_shifted_re): Remove.
22525         * config/arm/cortex-a53.md: Use arm_no_early_alu_shift_dep in bypass.
22527 2017-06-28  Michael Meissner  <meissner@linux.vnet.ibm.com>
22529         PR ipa/81238
22530         * multiple_target.c (create_dispatcher_calls): Set the default
22531         clone to be static, not public.
22533 2017-06-28  Richard Biener  <rguenther@suse.de>
22535         * tree-vect-loop.c (vectorizable_reduction): Move special
22536         cond reduction IV var creation ...
22537         (vect_create_epilog_for_reduction): ... here.  Remove induction_index
22538         parameter.  Use STMT_VINFO_VECTYPE.
22539         * tree-vect-slp.c (vect_get_constant_vectors): Properly reset
22540         constant_p.
22542 2017-06-28  Martin Liska  <mliska@suse.cz>
22544         PR ipa/81128
22545         * ipa-visibility.c (non_local_p): Handle visibility.
22547 2017-06-28  Martin Liska  <mliska@suse.cz>
22549         PR driver/79659
22550         * common.opt: Add IntegerRange to various options.
22551         * opt-functions.awk (integer_range_info): New function.
22552         * optc-gen.awk: Add integer_range_info to cl_options struct.
22553         * opts-common.c (decode_cmdline_option): Handle
22554         CL_ERR_INT_RANGE_ARG.
22555         (cmdline_handle_error): Likewise.
22556         * opts.c (print_filtered_help): Show valid interval in
22557         when --help is provided.
22558         * opts.h (struct cl_option): Add range_min and range_max fields.
22559         * config/i386/i386.opt: Add IntegerRange for -mbranch-cost.
22561 2017-06-28  Marc Glisse  <marc.glisse@inria.fr>
22563         * match.pd ((X & ~Y) | (~X & Y)): Generalize to + and ^.
22564         (x * C EQ/NE y * C): New transformation.
22566 2017-06-28  Christophe Lyon  <christophe.lyon@linaro.org>
22568         * genmultilib (combination_space): Accept '+' in option names.
22570 2017-06-28  Martin Liska  <mliska@suse.cz>
22572         PR sanitizer/81224
22573         * asan.c (instrument_derefs): Bail out inner references
22574         that are hard register variables.
22576 2017-06-28  Jakub Jelinek  <jakub@redhat.com>
22578         PR target/81175
22579         * config/i386/i386.c (ix86_init_mmx_sse_builtins): Use def_builtin
22580         rather than def_builtin_pure for __builtin_ia32_gatherpf*.
22582 2017-06-28  Richard Biener  <rguenther@suse.de>
22584         * tree-vectorizer.h (vect_get_vec_defs): Remove.
22585         (vect_get_slp_defs): Adjust.
22586         * tree-vect-loop.c (get_initial_defs_for_reduction): Split
22587         out from ...
22588         * tree-vect-slp.c (vect_get_constant_vectors): ... here and
22589         simplify.
22590         * tree-vect-loop.c (vect_create_epilog_for_reduction): Use
22591         get_initial_defs_for_reduction instead of vect_get_vec_defs.
22592         (vectorizable_reduction): Adjust.
22593         * tree-vect-slp.c (vect_get_constant_vectors): Remove reduction
22594         handling.
22595         (vect_get_slp_defs): Likewise.
22596         * tree-vect-stmts.c (vect_get_vec_defs): Make static and adjust.
22597         (vectorizable_bswap): Adjust.
22598         (vectorizable_call): Likewise.
22599         (vectorizable_conversion): Likewise.
22600         (vectorizable_assignment): Likewise.
22601         (vectorizable_shift): Likewise.
22602         (vectorizable_operation): Likewise.
22603         (vectorizable_store): Likewise.
22604         (vectorizable_condition): Likewise.
22605         (vectorizable_comparison): Likewise.
22607 2017-06-28  Michael Collison  <michael.collison@arm.com>
22609         PR target/68535
22610         * config/arm/arm.c (gen_ldm_seq): Remove last unnecessary
22611         set of base_reg
22612         (arm_gen_movmemqi): Removed unused variable 'i'.
22613         Convert 'for' loop into 'while' loop.
22614         (arm_expand_prologue): Remove last unnecessary set of insn.
22615         (thumb_pop): Remove unused variable 'pushed_words'.
22616         (thumb_exit): Remove last unnecessary set of regs_to_pop.
22618 2017-06-28  Andreas Krebbel  <krebbel@linux.vnet.ibm.com>
22620         * config/s390/predicates.md: Use s390_rel_address_ok_p.
22621         * config/s390/s390-protos.h: Add prototype of
22622         s390_rel_address_ok_p.
22623         * config/s390/s390.c (s390_got_symbol): New function.
22624         (s390_rel_address_ok_p): New function.
22625         (legitimize_pic_address): Use s390_rel_address_ok_p.
22626         (s390_load_got): Use s390_got_symbol.
22627         (s390_option_override): Issue error if
22628         -mno-pic-data-is-text-relative is used without -fpic/-fPIC.
22629         * config/s390/s390.h (TARGET_DEFAULT_PIC_DATA_IS_TEXT_RELATIVE):
22630         New macro.
22631         * config/s390/s390.opt: New option mpic-data-is-text-relative.
22633 2017-06-27  Andrew Pinski  <apinski@cavium.com>
22635         * match.pd (X >/>=/</<= 0 ? 1.0 : -1.0): New patterns.
22636         (X * copysign (1.0, X)): New pattern.
22637         (X * copysign (1.0, -X)): New pattern.
22638         (copysign (-1.0, CST)): New pattern.
22640 2017-06-27  Joseph Myers  <joseph@codesourcery.com>
22642         * genmultilib (combination_space): Remove variable.
22643         Validate reuse rules against regular expression for any sequence
22644         of multilib options in any order.
22646 2017-06-27  Michael Collison  <michael.collison@arm.com>
22648         * config/aarch64/aarch64-simd.md (aarch64_combine<mode>): Directly
22649         call aarch64_split_simd_combine.
22650         * (aarch64_combine_internal<mode>): Delete pattern.
22651         * config/aarch64/aarch64.c (aarch64_split_simd_combine):
22652         Allow register and subreg operands.
22654 2017-06-27  Jerome Lambourg  <lambourg@adacore.com>
22656         * config/i386/vxworks.h (ASM_SPEC): Remove definition. No target
22657         specific need, just fallback on defaults.
22658         (ASM_OUTPUT_ALIGNED_BSS): Add #undef before #define.
22660 2017-06-27  Jerome Lambourg  <lambourg@adacore.com>
22661             Olivier Hainque  <hainque@adacore.com>
22663         * config/i386/vxworks.h (DBX_REGISTER_NUMBER): Pick distinct
22664         map for 64bits.
22665         (TARGET_OS_CPP_BUILTINS): builtin_define CPU to X86_64 for 64bit
22666         targets. Pick a default if no particular attempt applied.
22667         (STACK_CHECK_PROTECT): Double for 64bit targets, which have
22668         larger contexts.
22670 2017-06-27  Jerome Lambourg  <lambourg@adacore.com>
22672         * config.gcc (i*86-wrs-vxworks7): Handle new acceptable triplet.
22673         (x86_64-wrs-vxworks7): Likewise.
22675 2017-06-27  Marek Polacek  <polacek@redhat.com>
22677         PR sanitizer/81223
22678         * ubsan.c (instrument_null): Check get_base_address's result for null.
22680 2017-06-27  Marc Glisse  <marc.glisse@inria.fr>
22682         * match.pd ((A+-B)+(C-A), (A+B)-(A-C)): New transformations.
22684 2017-06-27  Marc Glisse  <marc.glisse@inria.fr>
22686         * builtin-types.def (BT_FENV_T_PTR, BT_CONST_FENV_T_PTR,
22687         BT_FEXCEPT_T_PTR, BT_CONST_FEXCEPT_T_PTR): New primitive types.
22688         (BT_FN_INT_FENV_T_PTR, BT_FN_INT_CONST_FENV_T_PTR,
22689         BT_FN_INT_FEXCEPT_T_PTR_INT, BT_FN_INT_CONST_FEXCEPT_T_PTR_INT):
22690         New function types.
22691         * builtins.def (BUILT_IN_FECLEAREXCEPT, BUILT_IN_FEGETENV,
22692         BUILT_IN_FEGETEXCEPTFLAG, BUILT_IN_FEGETROUND,
22693         BUILT_IN_FEHOLDEXCEPT, BUILT_IN_FERAISEEXCEPT,
22694         BUILT_IN_FESETENV, BUILT_IN_FESETEXCEPTFLAG,
22695         BUILT_IN_FESETROUND, BUILT_IN_FETESTEXCEPT,
22696         BUILT_IN_FEUPDATEENV): New builtins.
22697         * tree-core.h (TI_FENV_T_PTR_TYPE, TI_CONST_FENV_T_PTR_TYPE,
22698         TI_FEXCEPT_T_PTR_TYPE, TI_CONST_FEXCEPT_T_PTR_TYPE): New entries.
22699         * tree.h (fenv_t_ptr_type_node, const_fenv_t_ptr_type_node,
22700         fexcept_t_ptr_type_node, const_fexcept_t_ptr_type_node): New
22701         macros.
22702         (builtin_structptr_types): Adjust size.
22703         * tree.c (builtin_structptr_types): Add four entries.
22705 2017-06-27  Jerome Lambourg  <lambourg@adacore.com>
22706             Olivier Hainque  <hainque@adacore.com>
22708         * config/vxworks.h (VXWORKS_LIB_SPEC): Incorporate ...
22709         (TLS_SYM): New local macro, forcing reference to __tls__ on
22710         link command lines for VxWorks 7 RTPs, triggering initialization
22711         of tlsLib.
22712         (VXWORKS_HAVE_TLS): New macro. State whether the target VxWorks
22713         OS features TLS support, true for RTPs on VxWorks 7.
22714         * config/vxworks.c (vxworks_override_options): Setup emutls
22715         accordingly.
22717 2017-06-27  Jakub Jelinek  <jakub@redhat.com>
22719         * predict.c (test_prediction_value_range): Use -1U instead of -1
22720         to avoid narrowing conversion warning.
22721         * dumpfile.c (dump_options): Wrap all value into dump_flags_t cast
22722         to avoid narrowing conversion warning.
22723         * opt-functions.awk (var_ref): Return (unsigned short) -1 instead of
22724         -1.
22725         * optc-gen.awk (END): Expect (unsigned short) -1 instead of -1.
22727 2017-06-27  Jerome Lambourg  <lambourg@adacore.com>
22729         * config/vxworks.h (VXWORKS_LIBS_RTP): Alternative definition for
22730         64bit configurations.
22731         (PTR_DIFF_TYPE): Alternative definition for TARGET_LP64.
22732         (SIZE_TYPE): Likewise.
22733         * config/vxworks.c (vxworks_emutls_var_fields): Use
22734         long_unsigned_type_node instead of unsigned_type_node as the offset
22735         field type, which is "pointer" mode in emutls.c.
22737 2017-06-27  Jakub Jelinek  <jakub@redhat.com>
22739         PR sanitizer/81209
22740         * ubsan.c (ubsan_encode_value): Initialize DECL_CONTEXT on var.
22742         PR middle-end/81207
22743         * gimple-fold.c (replace_call_with_call_and_fold): Handle
22744         gimple_vuse copying separately from gimple_vdef copying.
22746 2017-06-27  Prathamesh Kulkarni  <prathamesh.kulkarni@linaro.org>
22748         * value-prof.c (free_hist): Remove call to memset and the enclosing if
22749         condition.
22751 2017-06-26  Jerome Lambourg  <lambourg@adacore.com>
22752             Olivier Hainque  <hainque@adacore.com>
22754         * config.gcc (*-*-vxworks*): Add TARGET_VXWORKS7=1 to tm_defines
22755         for all vxworks7 targets.
22756         * config/vxworks.h (TARGET_VXWORKS7): If not defined, define to 0.
22757         (VXWORKS_ADDITIONAL_CPP_SPEC): Alternative definition for VXWORKS7.
22758         (VXWORKS_LIBS_RTP, VXWORKS_LIBS_RTP_DIR): New macros, allowing
22759         variations for VX6/VX7 and 32/64bits later on in ...
22760         (VXWORKS_LIB_SPEC): Leverage new macros.
22761         (VXWORKS_OS_CPP_BUILTINS): Define _VSB_CONFIG_FILE for VXWORKS7,
22762         as well as _ALLOW_KEYWORD_MACROS when "inline" is not a keyword.
22764 2017-06-26  Jerome Lambourg  <lambourg@adacore.com>
22766         * config/vxworks.h (VXWORKS_OS_CPP_BUILTINS): builtin_define
22767         _VX_TOOL_FAMILY and _VX_TOOL to gnu.
22769 2017-06-26  Carl Love  <cel@us.ibm.com>
22771         * config/rs6000/rs6000-c.c: Add support for built-in functions
22772         vector bool char vec_reve (vector bool char);
22773         vector signed char vec_reve (vector signed char);
22774         vector unsigned char vec_reve (vector unsigned char);
22775         vector bool int vec_reve (vector bool int);
22776         vector signed int vec_reve (vector signed int);
22777         vector unsigned int vec_reve (vector unsigned int);
22778         vector bool long long vec_reve (vector bool long long);
22779         vector signed long long vec_reve (vector signed long long);
22780         vector unsigned long long vec_reve (vector unsigned long long);
22781         vector bool short vec_reve (vector bool short);
22782         vector signed short vec_reve (vector signed short);
22783         vector double vec_reve (vector double);
22784         vector float vec_reve (vector float);
22785         * config/rs6000/rs6000-builtin.def (VREVE_V2DI, VREVE_V4SI,
22786         VREVE_V8HI, VREVE_V16QI, VREVE_V2DF, VREVE_V4SF, VREVE): New builtin.
22787         * config/rs6000/altivec.md (UNSPEC_VREVEV): New UNSPEC.
22788         (altivec_vreve): New pattern.
22789         * config/rs6000/altivec.h (vec_reve): New define.
22790         * doc/extend.texi (vec_rev): Update the built-in documentation file
22791         for the new built-in functions.
22793 2016-06-26  Bill Schmidt  <wschmidt@linux.vnet.ibm.com>
22795         PR tree-optimization/71815
22796         * gimple-ssa-strength-reduction.c (uses_consumed_by_stmt): New
22797         function.
22798         (find_basis_for_candidate): Call uses_consumed_by_stmt rather than
22799         has_single_use.
22800         (slsr_process_phi): Likewise.
22801         (replace_uncond_cands_and_profitable_phis): Don't replace a
22802         multiply candidate with a stride of 1 (copy or cast).
22803         (phi_incr_cost): Call uses_consumed_by_stmt rather than
22804         has_single_use.
22805         (lowest_cost_path): Likewise.
22806         (total_savings): Likewise.
22808 2017-06-26  Richard Biener  <rguenther@suse.de>
22810         PR target/81175
22811         * config/i386/i386.c (ix86_init_mmx_sse_builtins):
22812         Use def_builtin_pure for all gather builtins.
22814 2017-06-26  Richard Biener  <rguenther@suse.de>
22816         PR tree-optimization/81203
22817         * tree-tailcall.c (find_tail_calls): Do not move stmts into
22818         non-dominating BBs.
22820 2017-06-26  Marek Polacek  <polacek@redhat.com>
22822         PR c/80116
22823         * doc/invoke.texi: Document -Wmultistatement-macros.
22825 2017-06-26  Christophe Lyon  <christophe.lyon@linaro.org>
22827         * doc/sourcebuild.texi (ARM-specific attributes): Document new
22828         arm_neon_ok_no_float_abi effective target.
22830 2017-06-26  Richard Biener  <rguenther@suse.de>
22832         PR tree-optimization/80928
22833         * cfghooks.c (duplicate_block): Do not copy BB_DUPLICATED flag.
22834         (copy_bbs): Set BB_DUPLICATED flag early.
22835         (execute_on_growing_pred): Do not execute for BB_DUPLICATED
22836         marked blocks.
22837         (execute_on_shrinking_pred): Likewise.
22838         * tree-ssa.c (ssa_redirect_edge): Do not look for PHI args in
22839         BB_DUPLICATED blocks.
22840         * tree-ssa-phionlycoprop.c (eliminate_degenerate_phis_1): Properly
22841         iterate over all PHIs considering removal of *gsi.
22843 2017-06-23  Jim Wilson  <jim.wilson@linaro.org>
22845         * doc/invoke.texi (AArch64 Options, -mtune): Re-add falkor and
22846         qdf24xx.
22848 2017-06-23  Aaron Sawdey  <acsawdey@linux.vnet.ibm.com>
22850         * config/rs6000/rs6000-string.c: (expand_block_clear,
22851         do_load_for_compare, select_block_compare_mode,
22852         compute_current_alignment, expand_block_compare,
22853         expand_strncmp_align_check, expand_strn_compare,
22854         expand_block_move, rs6000_output_load_multiple)
22855         Move functions related to string/block move/compare
22856         to a separate file.
22857         * config/rs6000/rs6000.c: Move above functions to rs6000-string.c.
22858         * config/rs6000/rs6000-protos.h (rs6000_emit_dot_insn): Add prototype
22859         for this function which is now used in two files.
22860         * config/rs6000/t-rs6000: Add rule to compile rs6000-string.o.
22861         * config.gcc: Add rs6000-string.o to extra_objs for
22862         targets powerpc*-*-* and rs6000*-*-*.
22864 2017-06-23  Michael Meissner  <meissner@linux.vnet.ibm.com>
22866         PR target/80510
22867         * config/rs6000/rs6000.md (ALTIVEC_DFORM): Do not allow DImode in
22868         32-bit, since indexed is not valid for DImode.
22869         (mov<mode>_hardfloat32): Reorder ISA 2.07 load/stores before ISA
22870         3.0 d-form load/stores to be the same as mov<mode>_hardfloat64.
22871         (define_peephole2 for Altivec d-form load): Add 32-bit support.
22872         (define_peephole2 for Altivec d-form store): Likewise.
22874         PR ipa/81185
22875         * multiple_target.c (create_dispatcher_calls): Only create the
22876         dispatcher call if the function is the default clone of a
22877         versioned function.
22879 2017-06-23  Segher Boessenkool  <segher@kernel.crashing.org>
22881         PR middle-end/80902
22882         * builtins.c (expand_builtin_atomic_fetch_op): If emitting code after
22883         a call, force the call to not be a tail call.
22885 2017-06-23  Jeff Law  <law@redhat.com>
22887         * doc/contrib.texi: Add entry for Steven Pemberton's work on
22888         enquire.
22890 2017-06-23  Will Schmidt  <will_schmidt@vnet.ibm.com>
22892         * config/rs6000/rs6000.c: Add include of ssa-propagate.h for
22893         update_call_from_tree().  (rs6000_gimple_fold_builtin): Add
22894         handling for early expansion of vector shifts (sl,sr,sra,rl).
22895         (builtin_function_type): Add vector shift right instructions
22896         to the unsigned argument list.
22898 2017-06-23  Bernd Edlinger  <bernd.edlinger@hotmail.de>
22900         rtl-optimizatoin/79286
22901         * ira.c (update_equiv_regs): Revert to using may_trap_or_fault_p again.
22902         * rtlanal.c (rtx_addr_can_trap_p_1): SYMBOL_REF_FUNCTION_P can never
22903         trap.  PIC register plus a const unspec without offset can never trap.
22905 2017-06-23  Marc Glisse  <marc.glisse@inria.fr>
22907         * tree.h (builtin_structptr_type): New type.
22908         (builtin_structptr_types): Declare new array.
22909         * tree.c (builtin_structptr_types): New array.
22910         (free_lang_data, build_common_tree_nodes): Use it.
22912 2017-06-23  Jonathan Wakely  <jwakely@redhat.com>
22914         PR c++/81187
22915         * doc/invoke.texi (-Wnoexcept-type): Fix name of option, from
22916         -Wnoexcept.
22918 2017-06-22  Matt Turner  <mattst88@gmail.com>
22920         * config/i386/driver-i386.c (host_detect_local_cpu): Add Kaby
22921         Lake models to skylake case.  Assume skylake for unknown
22922         models with clflushopt.
22924 2017-06-22  Jeff Law  <law@redhat.com>
22926         * config/aarch64/aarch64.c (aarch64_emit_probe_stack_range): Handle
22927         frame sizes that do not satisfy aarch64_uimm12_shift.
22929 2017-06-22  Jan Hubicka <hubicka@ucw.cz>
22931         * profile-count.h (apply_probability,
22932         apply_scale, probability_in): Fix checks for zero.
22934 2017-06-22  Rainer Orth  <ro@CeBiTec.Uni-Bielefeld.DE>
22936         * incpath.c (add_sysroot_to_chain): Allow for $SYSROOT prefix.
22937         * doc/cppdiropts.texi (-I @var{dir}): Document it.
22939 2016-06-22  Richard Biener  <rguenther@suse.de>
22941         * tree-vect-loop.c (vect_model_reduction_cost): Handle
22942         COND_REDUCTION and INTEGER_INDUC_COND_REDUCTION without
22943         REDUC_MAX_EXPR support.
22944         (vectorizable_reduction): Likewise.
22945         (vect_create_epilog_for_reduction): Likewise.
22947 2017-06-22  James Greenhalgh  <james.greenhalgh@arm.com>
22949         * match.pd (A / (1 << B) -> A >> B): New.
22950         * generic-match-head.c: Include optabs-tree.h.
22951         * gimple-match-head.c: Likewise.
22952         * optabs-tree.h (target_supports_op_p): New.
22953         * optabs-tree.c (target_supports_op_p): New.
22955 2017-06-22  Rainer Orth  <ro@CeBiTec.Uni-Bielefeld.DE>
22957         * configure.ac (gcc_cv_ld_static_dynamic): Also check stderr for
22958         $gcc_cv_ld --help output.
22959         (gcc_cv_ld_demangle): Likewise.
22960         (gcc_cv_ld_eh_frame_hdr): Likewise.
22961         (gcc_cv_ld_pie): Likewise.
22962         (gcc_cv_ld_as_needed): Likewise.  Prefer native forms unless $gnu_ld.
22963         (gcc_cv_ld_buildid): Likewise.
22964         (gcc_cv_ld_sysroot): Likewise.
22965         (ld_bndplt_support): Likewise.
22966         (ld_pushpopstate_support): Likewise.
22967         * configure: Regenerate.
22968         * config/sol2.h [!USE_GLD] (SYSROOT_SPEC): Define.
22970 2017-06-21  Jakub Jelinek  <jakub@redhat.com>
22972         PR target/81151
22973         * config/i386/sse.md (round<mode>2): Renumber match_dup and
22974         operands indexes to avoid gap between operands and match_dups.
22976 2017-06-21  Andrew Pinski  <apinski@cavium.com>
22978         * config/aarch64/aarch64-cost-tables.h (thunderx_extra_costs):
22979         Increment Arith_shift and Arith_shift_reg by 1.
22980         * config/aarch64/aarch64-tuning-flags.def (cheap_shift_extend):
22981         New tuning flag.
22982         * config/aarch64/aarch64.c (thunderx_tunings): Enable
22983         AARCH64_EXTRA_TUNE_CHEAP_SHIFT_EXTEND.
22984         (aarch64_strip_extend): Add new argument and test for it.
22985         (aarch64_cheap_mult_shift_p): New function.
22986         (aarch64_rtx_mult_cost): Call aarch64_cheap_mult_shift_p and don't
22987         add a cost if it is true.
22988         Update calls to aarch64_strip_extend.
22989         (aarch64_rtx_costs): Update calls to aarch64_strip_extend.
22991 2017-06-21  Andrew Pinski  <apinski@cavium.com>
22993         * config/aarch64/aarch64-cores.def (thunderxt88p1): Use thunderxt88
22994         tunings.
22995         (thunderxt88): Likewise.
22996         * config/aarch64/aarch64.c (thunderxt88_prefetch_tune): New variable.
22997         (thunderx_prefetch_tune): New variable.
22998         (thunderx2t99_prefetch_tune): Update for the correct values.
22999         (thunderxt88_tunings): New variable.
23000         (thunderx_tunings): Use thunderx_prefetch_tune instead of
23001         generic_prefetch_tune.
23002         (thunderx2t99_tunings): Use AUTOPREFETCHER_WEAK.
23004 2017-06-21  Kyrylo Tkachov  <kyrylo.tkachov@arm.com>
23006         * config/aarch64/atomics.md (aarch64_compare_and_swap<mode>_lse,
23007         SHORT): Relax operand 3 to aarch64_reg_or_zero and constraint to Z.
23008         (aarch64_compare_and_swap<mode>_lse, GPI): Likewise.
23009         (aarch64_atomic_cas<mode>, SHORT): Likewise for operand 2.
23010         (aarch64_atomic_cas<mode>, GPI): Likewise.
23012 2017-06-21  Martin Liska  <mliska@suse.cz>
23014         * gimplify.c (gimplify_label_expr): Insert GIMPLE_PREDICT
23015         statements on cold and hot labels.
23016         * predict.c (tree_estimate_probability_bb): Remove the
23017         prediction from this place.
23019 2017-06-21  Martin Liska  <mliska@suse.cz>
23021         PR tree-optimization/79489
23022         * gimplify.c (maybe_add_early_return_predict_stmt): New
23023         function.
23024         (gimplify_return_expr): Call the function.
23025         * predict.c (tree_estimate_probability_bb): Remove handling
23026         of early return.
23027         * predict.def: Update comment about early return predictor.
23028         * gimple-predict.h (is_gimple_predict): New function.
23029         * predict.def: Change default value of early return to 66.
23030         * tree-tailcall.c (find_tail_calls): Skip GIMPLE_PREDICT
23031         statements.
23032         * passes.def: Put pass_strip_predict_hints to the beginning of
23033         IPA passes.
23035 2017-06-21  Pierre-Marie de Rodat  <derodat@adacore.com>
23037         * dwarf2out.c (gen_decl_die): Remove the guard to skip file-scope
23038         FUNCTION_DECL declarations.
23039         (dwarf2out_early_global_decl): Remove the guard to skip FUNCTION_DECL
23040         declarations.
23041         (dwaf2out_decl): Likewise.
23042         * godump.c (go_early_global_decl): Skip call to the real debug hook
23043         for FUNCTION_DECL declarations.
23044         * passes.c (rest_of_decl_compilation): Skip call to the
23045         early_global_decl debug hook for FUNCTION_DECL declarations, unless
23046         -fdump-go-spec is passed.
23048 2017-06-21  Marc Glisse  <marc.glisse@inria.fr>
23050         * config/i386/i386.c (struct builtin_isa): New field pure_p.
23051         Reorder for compactness.
23052         (def_builtin, def_builtin2, ix86_add_new_builtins): Handle pure_p.
23053         (def_builtin_pure, def_builtin_pure2): New functions.
23054         (ix86_init_mmx_sse_builtins) [__builtin_ia32_stmxcsr]: Mark as pure.
23056 2017-06-21  Marc Glisse  <marc.glisse@inria.fr>
23058         * match.pd (nop_convert): New predicate.
23059         ((A +- CST1) +- CST2): Allow some NOP conversions.
23061 2017-06-21  Jakub Jelinek  <jakub@redhat.com>
23063         PR c++/81130
23064         * gimplify.c (omp_add_variable): Don't force GOVD_SEEN for types
23065         with ctors/dtors if GOVD_SHARED is set.
23067 2017-06-21  Wilco Dijkstra  <wdijkstr@arm.com>
23069         * config/aarch64/aarch64.md (movti_aarch64):
23070         Emit mov rather than orr.
23071         (movtf_aarch64): Likewise.
23072         * config/aarch64/aarch64-simd.md (aarch64_simd_mov):
23073         Emit mov rather than orr.
23075 2017-06-21  Wilco Dijkstra  <wdijkstr@arm.com>
23077         * config/aarch64/aarch64-simd.md (aarch64_simd_dup):
23078         Swap alternatives, make integer dup more expensive.
23080 2017-06-21  Wilco Dijkstra  <wdijkstr@arm.com>
23082         * config/aarch64/aarch64.c (aarch64_legitimate_constant_p):
23083         Return true for non-tls symbols.
23085 2017-06-21  James Greenhalgh  <james.greenhalgh@arm.com>
23087         * config/aarch64/aarch64-cores.def (cortex-a55): New.
23088         (cortex-a75): Likewise.
23089         (cortex-a75.cortex-a55): Likewise.
23090         * config/aarch64/aarch64-tune.md: Regenerate.
23091         * doc/invoke.texi (-mtune): Document new values for -mtune.
23093 2017-06-21  Tom de Vries  <tom@codesourcery.com>
23095         * doc/sourcebuild.texi (Add Options, Features for dg-add-options): Add
23096         stack_size feature.
23097         (Effective-Target Keywords, Other attributes): Suggest using
23098         dg-add-options stack_size feature to get stack limit in stack_size
23099         effective target documentation.
23101 2017-06-21  Julian Brown  <julian@codesourcery.com>
23102             Naveen H.S  <Naveen.Hurugalawadi@cavium.com>
23104         * config/aarch64/aarch64-simd.md (aarch64_crypto_pmulldi)
23105         (aarch64_crypto_pmullv2di): Change type attribute to crypto_pmull.
23106         * config/aarch64/thunderx2t99.md (thunderx2t99_pmull): New
23107         reservation.
23108         * config/arm/cortex-a53.md (cortex_a53_advsimd_type): Add crypto_pmull to
23109         attribute type list for neon_multiply.
23110         * config/arm/cortex-a57.md (cortex_a57_neon_type): Add crypto_pmull to
23111         attribute type list for neon_multiply.
23112         * config/arm/crypto.md (crypto_vmullp64): Change type to crypto_pmull.
23113         * config/arm/exynos-m1.md (exynos_m1_neon_type): Add crypto_pmull to
23114         attribute type list for neon_multiply.
23115         * config/arm/types.md (crypto_pmull): Add.
23116         * config/arm/xgene1.md (xgene1_neon_pmull): Add crypto_pmull to
23117         attribute type list.
23119 2017-06-20  Andreas Tobler  <andreast@gcc.gnu.org>
23121         * config.gcc (armv6*-*-freebsd*): Change the target_cpu_cname to
23122         arm1176jzf-s.
23124 2017-06-20  Jakub Jelinek  <jakub@redhat.com>
23126         * ira-costs.c (find_costs_and_classes): Initialize cost_classes later
23127         to make sure not to dereference a NULL cost_classes_ptr pointer.
23129 2017-06-20  Carl Love  <cel@us.ibm.com>
23131         * config/rs6000/rs6000-c.c (altivec_overloaded_builtins): Add
23132         ALTIVEC_BUILTIN_VMULESW, ALTIVEC_BUILTIN_VMULEUW,
23133         ALTIVEC_BUILTIN_VMULOSW, ALTIVEC_BUILTIN_VMULOUW entries.
23134         * config/rs6000/rs6000.c (rs6000_gimple_fold_builtin,
23135         builtin_function_type): Add ALTIVEC_BUILTIN_* case statements.
23136         * config/rs6000/altivec.md (MVULEUW, VMULESW, VMULOUW,
23137         VMULOSW): New enum "unspec" values.
23138         (vec_widen_umult_even_v4si, vec_widen_smult_even_v4si,
23139         vec_widen_umult_odd_v4si, vec_widen_smult_odd_v4si,
23140         altivec_vmuleuw, altivec_vmulesw, altivec_vmulouw,
23141         altivec_vmulosw): New patterns.
23142         * config/rs6000/rs6000-builtin.def (VMLEUW, VMULESW, VMULOUW,
23143         VMULOSW): Add definitions.
23145 2017-06-20  Julia Koval  <julia.koval@intel.com>
23147         * config/i386/i386.c: Fix rounding expand for new pattern.
23148         * config/i386/subst.md: Fix pattern (parallel -> unspec).
23150 2017-06-20  James Greenhalgh  <james.greenhalgh@arm.com>
23152         * config/aarch64/aarch64-option-extensions.def (rcpc): New.
23153         * config/aarch64/aarch64.h (AARCH64_FL_RCPC): New.
23155 2017-06-20  James Greenhalgh  <james.greenhalgh@arm.com>
23157         * config/aarch64/aarch64-option-extensions.def (fp16): Fix expected
23158         feature string.
23160 2017-06-20  James Greenhalgh  <james.greenhalgh@arm.com>
23162         * config/aarch64/aarch64-cores.def: Rearrange to sort by
23163         architecture, then by implementer ID.
23164         * config/aarch64/aarch64-tune.md: Regenerate.
23166 2017-06-20  Richard Biener  <rguenther@suse.de>
23168         PR middle-end/81097
23169         * fold-const.c (split_tree): Fold to type before negating.
23171 2017-06-20  David Malcolm  <dmalcolm@redhat.com>
23173         * diagnostic-show-locus.c
23174         (selftest::test_fixit_deletion_affecting_newline): New function.
23175         (selftest::diagnostic_show_locus_c_tests): Call it.
23177 2017-06-20  Andreas Schwab  <schwab@suse.de>
23179         PR target/80970
23180         * config/m68k/m68k.md (bsetdreg, bchgdreg, bclrdreg): Use "=d"
23181         instead of "+d".
23183 2017-06-20  Prakhar Bahuguna  <prakhar.bahuguna@arm.com>
23185         * config/arm/arm-c.c (arm_cpu_builtins): New block to define
23186         __ARM_FEATURE_COPROC according to support.
23188 2017-06-20  Jakub Jelinek  <jakub@redhat.com>
23190         * tree-chkp.c (chkp_get_hard_register_var_fake_base_address):
23191         Rewritten to avoid overflow for > 32-bit pointers.
23193         PR sanitizer/81125
23194         * ubsan.h (ubsan_encode_value): Workaround buggy clang++ parser
23195         by removing enum keyword.
23196         (ubsan_type_descriptor): Likewise.  Formatting fix.
23198         PR target/81121
23199         * config/i386/i386.md (TARGET_USE_VECTOR_CONVERTS float si->{sf,df}
23200         splitter): Require TARGET_SSE2 in the condition.
23202 2017-06-20  Michael Meissner  <meissner@linux.vnet.ibm.com>
23204         PR target/79799
23205         * config/rs6000/rs6000.c (rs6000_expand_vector_init): Add support
23206         for doing vector set of SFmode on ISA 3.0.
23207         * config/rs6000/vsx.md (vsx_set_v4sf_p9): Likewise.
23208         (vsx_set_v4sf_p9_zero): Special case setting 0.0f to a V4SF
23209         element.
23210         (vsx_insert_extract_v4sf_p9): Add an optimization for inserting a
23211         SFmode value into a V4SF variable that was extracted from another
23212         V4SF variable without converting the element to double precision
23213         and back to single precision vector format.
23214         (vsx_insert_extract_v4sf_p9_2): Likewise.
23216 2017-06-19  Jakub Jelinek  <jakub@redhat.com>
23218         * tree-ssa-structalias.c (get_constraint_for_ptr_offset): Multiply
23219         in UWHI to avoid undefined overflow.
23221         PR sanitizer/81125
23222         * ubsan.h (enum ubsan_encode_value_phase): New.
23223         (ubsan_encode_value): Change second argument to
23224         enum ubsan_encode_value_phase with default value of
23225         UBSAN_ENCODE_VALUE_GENERIC.
23226         * ubsan.c (ubsan_encode_value): Change second argument to
23227         enum ubsan_encode_value_phase PHASE from bool IN_EXPAND_P,
23228         adjust uses, for UBSAN_ENCODE_VALUE_GENERIC use just
23229         create_tmp_var_raw instead of create_tmp_var and use a
23230         TARGET_EXPR.
23231         (ubsan_expand_bounds_ifn, ubsan_build_overflow_builtin,
23232         instrument_bool_enum_load, ubsan_instrument_float_cast): Adjust
23233         ubsan_encode_value callers.
23235         PR sanitizer/81111
23236         * ubsan.c (ubsan_encode_value): If current_function_decl is NULL,
23237         use create_tmp_var_raw instead of create_tmp_var, mark it addressable
23238         just by setting TREE_ADDRESSABLE on the result and use a TARGET_EXPR.
23240 2017-06-19  Richard Biener  <rguenther@suse.de>
23242         PR middle-end/81118
23243         * tree-cfgcleanup.c (cleanup_tree_cfg_noloop): Clear niter
23244         estimates if we changed anything.
23246 2017-06-19  Richard Biener  <rguenther@suse.de>
23248         PR tree-optimization/80887
23249         * tree-ssa-sccvn.c (mprts_hook_cnt): New global.
23250         (vn_lookup_simplify_result): Allow only mprts_hook_cnt succesful
23251         simplified lookups, then reset mprts_hook.
23252         (vn_nary_build_or_lookup_1): Set mprts_hook_cnt to 9 before
23253         simplifying.
23254         (try_to_simplify): Likewise.
23256 2017-06-19  Martin Liska  <mliska@suse.cz>
23258         PR sanitizer/80879
23259         * gimplify.c (gimplify_switch_expr):
23260         Initialize live_switch_vars for SWITCH_BODY == STATEMENT_LIST.
23262 2017-06-19  Martin Liska  <mliska@suse.cz>
23264         * doc/install.texi: Document that PGO runs in 4 stages.
23266 2017-06-19  Martin Liska  <mliska@suse.cz>
23268         PR ipa/80732
23269         * attribs.c (make_dispatcher_decl): Do not append '.ifunc'
23270         to dispatcher function name.
23271         * multiple_target.c (replace_function_decl): New function.
23272         (create_dispatcher_calls): Redirect both edges and references.
23274 2017-06-19  Jan Hubicka <hubicka@ucw.cz>
23276         * profile-count.c (profile_count::dump): Dump quality.
23277         (profile_count::differs_from_p): Update for unsigned val.
23278         * profile-count.h (profile_count_quality): New enum.
23279         (profile_count): Turn m_val to 62bit unsigned, add quality tracking.
23281 2017-06-19  Richard Biener  <rguenther@suse.de>
23283         * tree-ssa-loop-niter.h (estimate_numbers_of_iterations): Take
23284         struct function as arg.
23285         (estimate_numbers_of_iterations): Export overload with loop arg.
23286         (free_numbers_of_iterations_estimates_loop): Use an overload of
23287         free_numbers_of_iterations_estimates instead.
23288         * tree-cfg.c (remove_bb): Adjust.
23289         * tree-cfgcleanup.c (remove_forwarder_block_with_phi): Likewise.
23290         * tree-parloops.c (gen_parallel_loop): Likewise.
23291         * tree-ssa-loop-ivcanon.c (canonicalize_induction_variables):
23292         Likewise.
23293         (tree_unroll_loops_completely): Likewise.
23294         * tree-ssa-loop-niter.c (estimate_numbers_of_iterations_loop):
23295         Use an overload instead and export.
23296         (estimated_loop_iterations): Adjust.
23297         (max_loop_iterations): Likewise.
23298         (likely_max_loop_iterations): Likewise.
23299         (estimate_numbers_of_iterations): Take struct function as arg
23300         and adjust.
23301         (loop_exits_before_overflow): Adjust.
23302         (free_numbers_of_iterations_estimates_loop): Use an overload.
23303         * tree-vect-loop.c (vect_analyze_loop_form): Adjust.
23304         * tree-vectorizer.c (vect_free_loop_info_assumptions): Likewise.
23306 2017-06-19  Richard Biener  <rguenther@suse.de>
23308         PR ipa/81112
23309         * ipa-prop.c (find_constructor_constant_at_offset): Handle
23310         RANGE_EXPR conservatively.
23312 2017-06-16  Carl Love  <cel@us.ibm.com>
23314         * config/rs6000/rs6000-c.c (altivec_overloaded_builtins): Add
23315         definitions for vec_float, vec_float2, vec_floato,
23316         vec_floate built-ins.
23317         * config/rs6000/vsx.md (define_c_enum "unspec"): Add RTL code
23318         for instructions vsx_xvcvsxws vsx_xvcvuxwsp, float2, floato and
23319         floate.
23320         * config/rs6000/rs6000-builtin.def (FLOAT2_V2DI, FLOATE_V2DF,
23321         FLOATE_2DI, FLOATO_V2DF, FLOATEE_V2DI, XVCVSXWSP_V4SF,
23322         UNS_FLOATO_V2DI, UNS_FLOATE_V2DI): Add definitions.
23323         * config/altivec.md (define_insn "p8_vmrgew_<mode>",
23324         define_mode_attr VF_sxddp): Add V4SF type to p8_vmrgew.
23325         * config/rs6000/altivec.h (vec_float, vec_float2, vec_floate,
23326         vec_floato): Add builtin defines.
23327         * doc/extend.texi (vec_float, vec_float2, vec_floate, vec_floato):
23328         Update the built-in documentation file for the new built-in
23329         functions.
23331 2017-06-16  Richard Earnshaw  <rearnsha@arm.com>
23333         * config/arm/arm.opt (marm): Mark as the negative of of -mthumb.
23334         (mthumb): Mark as the negative of -marm.
23336 2017-06-16  Richard Earnshaw  <rearnsha@arm.com>
23338         * doc/invoke.texi (ARM Options, -mcpu): Document supported
23339         extension options.
23340         (ARM Options, -mtune): Document that this accepts the same
23341         extension options as -mcpu.
23342         (ARM Options, -mfpu): Document addition of -mfpu=auto.
23344 2017-06-16  Richard Earnshaw  <rearnsha@arm.com>
23346         * doc/invoke.texi (ARM Options, -march=): Document new syntax and
23347         permitted extensions.
23349 2017-06-16  Richard Earnshaw  <rearnsha@arm.com>
23351         * config/arm/arm-cpus.in (armv7): Add extension +nofp.
23352         (armv7-r): Add aliases vfpv3xd and vfpv3-d16.
23353         (armv8-m.main): Add option +nodsp.
23354         * config/arm/arm-cpu-cdata.h: Regenerated.
23356 2017-06-16  Richard Earnshaw  <rearnsha@arm.com>
23358         * config/arm/t-fuchsia: New file.
23359         * config.gcc (arm*-*-fuchsia*): Use it.
23361 2017-06-16  Richard Earnshaw  <rearnsha@arm.com>
23363         * config/arm/t-symbian: Rewrite for new option infrastructure.
23365 2017-06-16  Richard Earnshaw  <rearnsha@arm.com>
23367         * config/arm/t-phoenix (MULTILIB_REUSE): Clear variable.
23368         (MULTILIB_REQUIRED): Likewise.
23370 2017-06-16  Richard Earnshaw  <rearnsha@arm.com>
23372         * config/arm/t-linux-eabi (MULTILIB_EXCEPTIONS): Set to empty.
23373         (MULTILIB_RESUE): Likewise.
23374         (MULTILIB_MATCHES): Likewise.
23375         (MULTLIB_REQUIRED): Likewise.
23377 2017-06-16  Richard Earnshaw  <rearnsha@arm.com>
23379         * config/arm/t-rtems: Rewrite for new option framework.
23381 2017-06-16  Richard Earnshaw  <rearnsha@arm.com>
23383         * config/arm/t-aprofile (v7_a_nosimd_variants, v7_a_simd_variants)
23384         (v7ve_nosimd_variatns, v7ve_vfpv3_simd_variants)
23385         (v7ve_vfpv4_simd_variants, v8_a_nosimd_variants, v8_a_simd_variants)
23386         (v8_1_a_simd_variants, v8_2_a_simd_variants): Move to ...
23387         * config/arm/t-multilib: ... here.
23388         (MULTILIB_OPTIONS): Add armv7 and armv7+fp architectures.
23389         (MULTILIB_MATCHES): Use armv7 libraries for armv7-r.  Also use for
23390         armv7-a and armv8*-a when A-profile libraries have not been built.
23391         * config/arm/t-rmprofile: Rewrite.
23393 2017-06-16  Richard Earnshaw  <rearnsha@arm.com>
23395         * genmultilib (multilib_reuse): Allow an explicit period to be escaped
23396         with a backslash.  Remove the backslash after substituting unescaped
23397         periods.
23398         * doc/fragments.texi (MULTILIB_REUSE): Document it.
23400 2017-06-16  Richard Earnshaw  <rearnsha@arm.com>
23402         * config.gcc: (arm*-*-*): When building a-profile libraries, force
23403         the driver to pass through the default setting of -mfloat-abi.
23404         * common/config/arm/arm-common.c (arm_target_thumb_only): Return -marm
23405         rather than NULL.
23406         * config/arm/t-multilib (MULTILIB_REUSE): Initialize to empty.
23407         (all_feat_combs): New rule.
23408         (MULTILIB_OPTIONS): Use explicit ARM and Thumb directories.  Rework
23409         default libraries.
23410         * config/arm/t-aprofile: Rewrite.
23412 2017-06-16  Richard Earnshaw  <rearnsha@arm.com>
23414         * config/arm/arm.h (FPUTYPE_AUTO): Define.
23415         * config/arm/arm.c (arm_option_override): Use FPUTYPE_AUTO if the
23416         fpu is not specified by the user/command-line.
23417         * config/arm/bpabi.h (FPUTYPE_DEFAULT): Delete.
23418         * config/arm/netbsd-elf.h (FPUTYPE_DEFAULT): Delete.
23419         * config/arm/linux-elf.h (FPUTYPE_DEFAULT): Delete.
23420         * config/arm/vxworks.h (FPUTYPE_DEFAULT): Delete.
23421         * common/config/arm/arm-common.c (arm_canon_arch_option): Use
23422         FPUTYPE_AUTO insted of FPUTYPE_DEFAULT.
23424 2017-06-16  Richard Earnshaw  <rearnsha@arm.com>
23426         * config/arm/elf.h (MULTILIB_DEFAULTS): Delete.
23427         * config/arm/t-arm-elf: Rewritten.
23429 2017-06-16  Richard Earnshaw  <rearnsha@arm.com>
23431         * config/arm/arm.h (TARGET_HARD_FLOAT): Also check that we
23432         have some floating-point instructions.
23433         (TARGET_SOFT_FLOAT): Define as inverse of TARGET_HARD_FLOAT.
23434         (TARGET_MAYBE_HARD_FLOAT): New macro.
23435         * config/arm/arm-builtins.c (arm_init_builtins): Use
23436         TARGET_MAYBE_HARD_FLOAT.
23437         * config/arm/arm.c (arm_option_override): Use TARGET_HARD_FLOAT_ABI.
23439 2017-06-16  Richard Earnshaw  <rearnsha@arm.com>
23441         * common/config/arm/arm-common.c: Define INCLUDE_LIST.
23442         (configargs.h): Include it.
23443         (arm_print_hint_for_fpu_option): New function.
23444         (arm_parse_fpu_option): New function.
23445         (candidate_extension): New class.
23446         (arm_canon_for_multilib): New function.
23447         * config/arm/arm.h (CANON_ARCH_SPEC_FUNCTION): New macro.
23448         (EXTRA_SPEC_FUNCTIONS): Add CANON_ARCH_SPEC_FUNCTION.
23449         (ARCH_CANONICAL_SPECS): New macro.
23450         (DRIVER_SELF_SPECS): Add ARCH_CANONICAL_SPECS.
23452 2017-06-16  Richard Earnshaw  <rearnsha@arm.com>
23454         * config.gcc (arm*-*-*): Ensure both target_cpu_cname and with_cpu
23455         are set after handling multilib fragments.  Set target_cpu_default2
23456         from with_cpu.
23458 2017-06-16  Richard Earnshaw  <rearnsha@arm.com>
23460         * config.gcc (arm*-*-fucshia*): Set target_cpu_cname to the real
23461         cpu name.
23462         (arm*-*-*): Set target_cpu_default2 to a quoted string.
23463         * config/arm/parsecpu.awk (check_cpu): Validate any extension
23464         options.
23465         (check_arch): Likewise.
23466         * config/arm/arm.c (arm_configure_build_target): Handle
23467         TARGET_CPU_DEFAULT being a string constant.  Scan any feature
23468         options in the default.
23470 2017-06-16  Richard Earnshaw  <rearnsha@arm.com>
23472         * config/arm/arm-protos.h (cpu_arch_extension): Add field to record
23473         when an option is an alias of another.
23474         * config/arm/parsecpu.awk (optalias): New parser token.
23475         (gen_comm_data): Mark non-alias options as such.  Emit entries
23476         for extension aliases.
23477         * config/arm/arm-cpus.in (armv5e): Make vfpv2 an alias.
23478         (armv5te, armv5tej, armv6, armv6j, armv6k, armv6z): Likewise.
23479         (armv6kz, armv6zk, armv6t2): Likewise.
23480         (armv7): Make vfpv3-d16 an alias.
23481         (armv7-a): Make vfpv3-d16, neon and neon-vfpv3 aliases.  Sort in
23482         canonical order.
23483         (armv7ve): Make vfpv4-d16, neon-vfpv3 and neon-vfpv4 aliases.
23484         Sort in canonical order.
23485         (armv8-a): Sort in canonical order.
23486         (armv8.1-a, armv8.2-a):  Likewise.
23487         (generic-armv7-a): Make neon and neon-vfpv3 aliases.  Sort in
23488         canonical order.
23489         (cortex-a9): Sort in canonical order.
23490         * config/arm/arm.c (selftests.h): Include it.
23491         (arm_test_cpu_arch_data): New function.
23492         (arm_run_self_tests): New function.
23493         (TARGET_RUN_TARGET_SELFTESTS): Redefine.
23494         (targetm): Move declaration to the end of the file.
23495         * arm-cpu-cdata.h: Regenerated.
23497 2017-06-16  Richard Earnshaw  <rearnsha@arm.com>
23499         * config/arm/arm.h (TARGET_MODE_SPECS): Add additional parameter to
23500         call to target_mode_check describing the type of option passed.
23501         * common/config/arm/arm-common.c (arm_arch_core_flag): Delete.
23502         (arm_target_thumb_only): Use arm_parse_arch_option_name or
23503         arm_parse_cpu_option_name to match parameters against list of
23504         available targets.
23505         * config/arm/parsecpu.awk (gen_comm_data): Don't generate
23506         arm_arch_core_flags data structure.
23507         * config/arm/arm-cpu_cdata.h: Regenerated.
23509 2017-06-16  Richard Earnshaw  <rearnsha@arm.com>
23511         * common/config/arm/arm-common.c (arm_initialize_isa): Moved here from
23512         config/arm/arm.c.
23513         (arm_print_hint_for_cpu_option): Likewise.
23514         (arm_print_hint_for_arch_option): Likewise.
23515         (arm_parse_cpu_option_name): Likewise.
23516         (arm_parse_arch_option_name): Likewise.
23517         * config/arm/arm.c (arm_identify_fpu_from_isa): Use the computed number
23518         of entries in the all_fpus list.
23519         * config/arm/arm-protos.h (all_architectures, all_cores): Declare.
23520         (arm_parse_cpu_option_name): Declare.
23521         (arm_parse_arch_option_name): Declare.
23522         (arm_parse_option_features): Declare.
23523         (arm_intialize_isa): Declare.
23524         * config/arm/parsecpu.awk (gen_data): Move CPU and architecture
23525         data tables to ...
23526         (gen_comm_data): ... here.  Make definitions non-static.
23527         * config/arm/arm-cpu-data.h: Regenerated.
23528         * config/arm/arm-cpu-cdata.h: Regenerated.
23530 2017-06-16  Richard Earnshaw  <rearnsha@arm.com>
23532         * config/arm/arm-protos.h (arm_build_target): Remove arch_core.
23533         (cpu_arch_extension): New structure.
23534         (cpu_arch_option, arch_option, cpu_option): New structures.
23535         * config/arm/parsecpu.awk (gen_headers): Build an enumeration of
23536         architecture types.
23537         (gen_data): Generate new format data tables.
23538         * config/arm/arm.c (cpu_tune): New structure.
23539         (cpu_option, processors): Delete.
23540         (arm_print_hint_for_core_or_arch): Delete.  Replace with ...
23541         (arm_print_hint_for_cpu_option): ... this and ...
23542         (arm_print_hint_for_arch_option): ... this.
23543         (arm_parse_arch_cpu_name): Delete.  Replace with ...
23544         (arm_parse_cpu_option_name): ... this and ...
23545         (arm_parse_arch_option_name): ... this.
23546         (arm_unrecognized_feature): Change type of target parameter to
23547         cpu_arch_option.
23548         (arm_parse_arch_cpu_features): Delete.  Replace with ...
23549         (arm_parse_option_features): ... this.
23550         (arm_configure_build_target): Rework to use new configuration data
23551         tables.
23552         (arm_print_tune_info): Rework for new configuration data tables.
23553         * config/arm/arm-cpu-data.h: Regenerated.
23554         * config/arm/arm-cpu.h: Regenerated.
23556 2017-06-16  Richard Earnshaw  <rearnsha@arm.com>
23558         * Makefile.in (OBJS): Move sbitmap.o from here ...
23559         (OBJS-libcommon): ... to here.
23561 2017-06-16  Richard Earnshaw  <rearnsha@arm.com>
23563         * config/arm/arm-isa.h (ISA_ALL_FPU_INTERNAL): Renamed from ISA_ALL_FPU.
23564         (ISA_ALL_CRYPTO): New macro.
23565         (ISA_ALL_SIMD): New macro
23566         (ISA_ALL_FP): New macro.
23567         * config/arm/arm.c (fpu_bitlist): Update initializer.
23568         * config/arm/arm-cpus.in: Use new ISA_ALL macros to disable crypto,
23569         simd or fp.
23570         (arm9e): Add fpu.  Add option for nofp
23571         (arm946e-s, arm966e-s, arm968e-s, arm10e, arm1020e, arm1022e): Likewise.
23572         (arm926ej-s, arm1026ej-s): Likewise.
23573         (generic-armv7-a): Add fpu.  Add options for simd, vfpv3, vfpv3-d16,
23574         vfpv3-fp16, vfpv3-d16-fp16, vfpv4, vfpv4-d16, neon, neon-vfp3,
23575         neon-fp16, neon-vfpv4, nofp and nosimd.
23576         (cortex-a5, cortex-a7): Add fpu.  Add options for nosimd and nofp.
23577         (cortex-a8): Add fpu.  Add option for nofp.
23578         (cortex-a9): Add fpu.  Add options for nosimd and nofp.
23579         (cortex-a12, cortex-a15, cortex-a17): Add fpu.  Add option for nofp.
23580         (cortex-r4f): Add fpu.
23581         (cortex-r5): Add fpu.  Add options for nofp.dp and nofp.
23582         (cortex-r7): Use idiv option from architecture.  Add fpu.  Add option
23583         for nofp.
23584         (cortex-r8): Likewise.
23585         (cortex-m4): Add fpu.  Add option for nofp.
23586         (cortex-a15.cortex-a7): Add fpu.  Add option for nofp.
23587         (cortex-a17.cortex-a7): Likewise.
23588         (cortex-a32): Add fpu.  Add options for crypto and nofp.
23589         (cortex-a35, cortex-a53): Likewise.
23590         (cortex-a57): Add fpu.  Add option for crypto.
23591         (cortex-a72, cortex-a73): Likewise.
23592         (exynos-m1): Likewise.
23593         (cortex-a57.cortex-a53, cortex-a72.cortex-a53): Likewise.
23594         (cortex-a73.cortex-a35, cortex-a73.cortex-a53): Likewise.
23595         (cortex-m33): Add fpu.  Add option for nofp.
23596         * config/arm/arm-cpu-cdata.h: Regenerated
23597         * config/arm/arm-cpu-data.h: Regenerated.
23599 2017-06-16  Richard Earnshaw  <rearnsha@arm.com>
23601         * arm-cpus.in (armv5e): Add options fp, vfpv2 and nofp.
23602         (armv5te, armv5tej): Likewise.
23603         (armv6, armv6j, armv6k, armv6z, armv6kz, armv6zk, armv6t2): Likewise.
23604         (armv7): Add options fp and vfpv3-d16.
23605         (armv7-a): Add options fp, simd, vfpv3, vfpv3-d16, vfpv3-d16-fp16,
23606         vfpv3-fp16, vfpv4, vfpv4-d16, neon, neon-vfpv3, neon-fp16, neon-vfpv4,
23607         nofp and nosimd.
23608         (armv7ve): Likewise.
23609         (armv7-r): Add options fp, fp.sp, idiv, nofp and noidiv.
23610         (armv7e-m): Add options fp, fpv5, fp.dp and nofp.
23611         (armv8-a): Add nocrypto option.
23612         (armv8.1-a, armv8.2-a): Likewise.
23613         (armv8-m.main): add options fp, fp.dp and nofp.
23615 2017-06-16  Richard Earnshaw  <rearnsha@arm.com>
23617         * config/arm/arm-cpus.in (armv8-a): Add options crc, simd crypto and
23618         nofp.
23619         (armv8-a+crc): Delete.
23620         (armv8.1-a): Add options simd, crypto and nofp.
23621         (armv8.2-a): Add options fp16, simd, crypto and nofp.
23622         (armv8.2-a+fp16): Delete.
23623         (armv8-m.main): Add option dsp.
23624         (armv8-m.main+dsp): Delete.
23625         (cortex-a8): Add fpu.  Add nofp option.
23626         (cortex-a9): Add fpu.  Add nofp and nosimd options.
23627         * config/arm/parsecpu.awk (gen_data): Generate option tables and
23628         link to main cpu and architecture data structures.
23629         (gen_comm_data): Only put isa attributes from the main architecture
23630         in common tables.
23631         (option): New statement for architecture and CPU entries.
23632         * arm.c (struct cpu_option): New structure.
23633         (struct processors): Add entry for options.
23634         (arm_unrecognized_feature): New function.
23635         (arm_parse_arch_cpu_name): Ignore any characters after the first
23636         '+' character.
23637         (arm_parse_arch_cpu_feature): New function.
23638         (arm_configure_build_target): Separate out any CPU and architecture
23639         features and parse separately.  Don't error out if -mfpu=auto is
23640         used with only an architecture string.
23641         (arm_print_asm_arch_directives): New function.
23642         (arm_file_start): Call it.
23643         * config/arm/arm-cpu-cdata.h: Regenerated.
23644         * config/arm/arm-cpu-data.h: Likewise.
23645         * config/arm/arm-tables.opt: Likewise.
23647 2017-06-16  Richard Earnshaw  <rearnsha@arm.com>
23649         * config/arm/elf.h (ASM_SPEC): Only pass -mfpu through to the
23650         assembler when it is not -mfpu=auto.
23652 2017-06-16  Richard Earnshaw  <rearnsha@arm.com>
23654         * config/arm/arm.h (BIG_LITTLE_SPEC): Delete macro.
23655         (ASM_REWRITE_SPEC_FUNCTIONS): New macro.
23656         (BIG_LITTLE_CPU_SPEC_FUNCTIONS): Delete macro.
23657         (ASM_CPU_SPEC): Rewrite.
23658         (MCPU_MTUNE_NATIVE_FUNCTIONS): New macro.
23659         (EXTRA_SPEC_FUNCTIONS): Move outside of ifdef.  Use
23660         MCPU_MTUNE_NATIVE_FUNCTIONS and ASM_REWRITE_SPEC_FUNCTIONS.  Remove
23661         reference to BIG_LITTLE_CPU_SPEC_FUNCTIONS.
23662         * common/config/arm/arm-common.c (arm_rewrite_selected_cpu): Ensure
23663         copied string is NUL-terminated.  Also strip any characters prefixed
23664         by '+'.
23665         (arm_rewrite_selected_arch): New function.
23666         (arm_rewrite_march): New function.
23668 2017-06-16  Richard Earnshaw  <rearnsha@arm.com>
23670         * config/arm/arm.opt (x_arm_arch_string): New TargetSave option.
23671         (x_arm_cpu_string, x_arm_tune_string): Likewise.
23672         (march, mcpu, mtune): Convert to string-based options.
23673         * config/arm/arm.c (arm_print_hint_for_core_or_arch): New function.
23674         (arm_parse_arch_cpu_name): New function.
23675         (arm_configure_build_target): Use arm_parse_arch_cpu_name to
23676         identify selected architecture or CPU.
23677         (arm_option_save): New function.
23678         (TARGET_OPTION_SAVE): Redefine.
23679         (arm_option_restore): Restore string options.
23680         (arm_option_print): Print string options.
23682 2017-06-16  Martin Sebor  <msebor@redhat.com>
23684         PR tree-optimization/80933
23685         PR tree-optimization/80934
23686         * builtins.c (fold_builtin_3): Do not handle bcmp here.
23687         * gimple-fold.c (gimple_fold_builtin_bcmp): New function.
23688         (gimple_fold_builtin_bcopy, gimple_fold_builtin_bzero): Likewise.
23689         (gimple_fold_builtin): Call them.
23691 2017-06-16  Jan Hubicka  <hubicka@ucw.cz>
23693         * gimple-ssa-isolate-paths.c (isolate_path): Set edge leading to path
23694         as unlikely; update profile.
23696 2017-06-16  Jan Hubicka  <hubicka@ucw.cz>
23698         * predict.c (force_edge_cold): Handle declaring edges impossible
23699         more aggresively.
23701 2017-06-16  Jan Hubicka  <hubicka@ucw.cz>
23703         * tree-ssa-loop-ivcanon.c (remove_exits_and_undefined_stmts): Update
23704         profile.
23705         (try_unroll_loop_completely): Fix reporting.
23707 2017-06-16  Jan Hubicka  <hubicka@ucw.cz>
23709         * tree-ssa-tail-merge.c (replace_block_by): Fix profile updating.
23711 2017-06-16  James Greenhalgh  <james.greenhalgh@arm.com>
23713         PR target/71778
23714         * config/arm/arm-builtins.c (arm_expand_builtin_args): Return TARGET
23715         if given a non-constant argument for an intrinsic which requires a
23716         constant.
23718 2017-06-16  Jan Hubicka  <hubicka@ucw.cz>
23720         * profile.c (compare_freqs): New function.
23721         (branch_prob): Sort edge list.
23722         (find_spanning_tree): Assume that the list is priority sorted.
23724 2017-06-16  Richard Biener  <rguenther@suse.de>
23726         PR tree-optimization/81090
23727         * passes.def (pass_record_bounds): Remove.
23728         * tree-pass.h (make_pass_record_bounds): Likewise.
23729         * tree-ssa-loop.c (pass_data_record_bounds, pass_record_bounds,
23730         make_pass_record_bounds): Likewise.
23731         * tree-ssa-loop-ivcanon.c (canonicalize_induction_variables): Do
23732         not free niter estimates at the beginning but at the end.
23733         * tree-scalar-evolution.c (scev_finalize): Free niter estimates.
23735 2017-06-16  Richard Biener  <rguenther@suse.de>
23737         * tree-switch-conversion.c (emit_case_bit_tests): Adjust
23738         initializer to workaround ICE in host GCC 4.8.
23740 2017-06-16  Jan Hubicka  <hubicka@ucw.cz>
23742         * ipa-inline-transform.c (update_noncloned_frequencies): Update also
23743         counts.
23744         (clone_inlined_nodes): Update.
23746 2017-06-16  Maxim Kuvyrkov  <maxim.kuvyrkov@linaro.org>
23748         * config/aarch64/aarch64.c (qdf24xx_prefetch_tune): Update
23749         prefetch settings, and enable prefetching by default at -O3.
23751 2017-06-16  Maxim Kuvyrkov  <maxim.kuvyrkov@linaro.org>
23753         * config/aarch64/aarch64.c (aarch64_override_options_internal):
23754         Set flag_prefetch_loop_arrays according to tuning data.
23756 2017-06-16  Maxim Kuvyrkov  <maxim.kuvyrkov@linaro.org>
23758         * config/aarch64/aarch64-protos.h (struct cpu_prefetch_tune):
23759         New tune structure.
23760         (struct tune_params): Use cpu_prefetch_tune instead of cache_line_size.
23761         [Unrelated to main purpose of the patch] Place the pointer field last
23762         to enable type checking errors when tune structure are wrongly merged.
23763         * config/aarch64/aarch64.c (generic_prefetch_tune,)
23764         (exynosm1_prefetch_tune, qdf24xx_prefetch_tune,)
23765         (thunderx2t99_prefetch_tune): New tune constants.
23766         (tune_params *_tunings): Update all tunings (no functional change).
23767         (aarch64_override_options_internal): Set PARAM_SIMULTANEOUS_PREFETCHES,
23768         PARAM_L1_CACHE_SIZE, PARAM_L1_CACHE_LINE_SIZE, and PARAM_L2_CACHE_SIZE
23769         from tunings structures.
23771 2017-06-16  Jakub Jelinek  <jakub@redhat.com>
23773         PR sanitizer/81094
23774         * ubsan.c (instrument_null): Add T argument, use it instead
23775         of computing it based on IS_LHS.
23776         (instrument_object_size): Likewise.
23777         (pass_ubsan::execute): Adjust instrument_null and
23778         instrument_object_size callers to pass gimple_get_lhs or
23779         gimple_assign_rhs1 result to it.  Use instrument_null instead of
23780         calling get_base_address and instrument_mem_ref.  Handle
23781         aggregate call arguments for object-size sanitization.
23783 2017-06-16  Yury Gribov  <tetra2005@gmail.com>
23785         PR tree-optimization/81089
23786         * tree-vrp.c (is_masked_range_test): Validate operands of
23787         subexpression.
23789 2017-06-15  Martin Sebor  <msebor@redhat.com>
23791         PR c++/80560
23792         * dumpfile.c (dump_register): Avoid calling memset to initialize
23793         a class with a default ctor.
23794         * gcc.c (struct compiler): Remove const qualification.
23795         * genattrtab.c (gen_insn_reserv): Replace memset with initialization.
23796         * hash-table.h: Ditto.
23797         * ipa-cp.c (allocate_and_init_ipcp_value): Replace memset with
23798           assignment.
23799         * ipa-prop.c (ipa_free_edge_args_substructures): Ditto.
23800         * omp-low.c (lower_omp_ordered_clauses): Replace memset with
23801         default ctor.
23802         * params.h (struct param_info): Make struct members non-const.
23803         * tree-switch-conversion.c (emit_case_bit_tests): Replace memset
23804         with default initialization.
23805         * vec.h (vec_copy_construct, vec_default_construct): New helper
23806         functions.
23807         (vec<T>::copy, vec<T>::splice, vec<T>::reserve): Replace memcpy
23808         with vec_copy_construct.
23809         (vect<T>::quick_grow_cleared): Replace memset with default ctor.
23810         (vect<T>::vec_safe_grow_cleared, vec_safe_grow_cleared): Same.
23811         * doc/invoke.texi (-Wclass-memaccess): Document.
23813 2017-06-15  Ramana Radhakrishnan  <ramana.radhakrishnan@arm.com>
23815         * emit-rtl.h (is_leaf): Update comment about local
23816         register allocator.
23818 2017-06-15  Jozef Lawrynowicz   <jozef.l@somniumtech.com>
23820         PR target/78818
23821         * config/msp430/msp430.c (msp430_data_attr): Check that it's possible
23822         for a variable to have a section before checking if the section has a
23823         name.
23824         Set section to.persistent if persistent attribute is set.
23825         Warn if .persistent attribute is used on an automatic variable.
23827 2017-06-15  Eric Botcazou  <ebotcazou@adacore.com>
23829         PR rtl-optimization/80474
23830         * reorg.c (update_block): Do not ignore instructions in a delay slot.
23832 2017-06-15  Segher Boessenkool  <segher@kernel.crashing.org>
23834         * config/rs6000/rs6000.md (add<mode>3): Use reg_or_subregno instead
23835         of REGNO.
23837 2017-06-14  Maciej W. Rozycki  <macro@imgtec.com>
23839         * config/mips/mips.md (MIPS16_T_REGNUM): Remove constant.
23840         (casesi): Emit bounds checking as RTL.
23841         (casesi_internal_mips16_<mode>): Remove bounds checking.
23843 2017-06-14  Max Filippov  <jcmvbkbc@gmail.com>
23845         * config/xtensa/xtensa.c (xtensa_option_override): Append
23846         MASK_CONST16 to target_flags in the absence of TARGET_L32R.
23847         (hwloop_optimize, hwloop_fail, hwloop_pattern_reg,
23848          xtensa_doloop_hooks): Define unconditionally.
23849         (xtensa_reorg_loops): Only call reorg_loops in the presence of
23850         TARGET_LOOPS.
23851         * config/xtensa/xtensa.h (TARGET_L32R): New definition.
23852         (TARGET_DEFAULT): Remove XCHAL_HAVE_L32R condition and account
23853         for it in xtensa_option_override.
23854         (HARD_FRAME_POINTER_IS_FRAME_POINTER,
23855          HARD_FRAME_POINTER_IS_ARG_POINTER): New definitions.
23857 2017-06-14  Boris Kolpackov  <boris@codesynthesis.com>
23859         * doc/cppopts.texi: Document '-' special value to -MF.
23861 2017-06-14  Wilco Dijkstra  <wdijkstr@arm.com>
23863         * config/arm/cortex-a53.md (cortex_a53_fpalu) Adjust latency.
23864         (cortex_a53_fconst): Likewise.
23865         (cortex_a53_fpmul): Likewise.
23866         (cortex_a53_f_load_64): Likewise.
23867         (cortex_a53_f_load_many): Likewise.
23868         (cortex_a53_advsimd_alu): Likewise.
23869         (cortex_a53_advsimd_alu_q): Likewise.
23870         (cortex_a53_advsimd_mul): Likewise.
23871         (cortex_a53_advsimd_mul_q): Likewise.
23872         (fpmac bypass): Add new bypass for fpmac-fpmac case.
23873         Add missing fmul, r2f_cvt and fconst cases.
23875 2017-06-14  Richard Biener  <rguenther@suse.de>
23877         PR middle-end/81088
23878         * fold-const.c (split_tree): Drop TREE_OVERFLOW flag from
23879         literal constants.
23880         (fold_binary_loc): When associating do not treat pre-existing
23881         TREE_OVERFLOW on literal constants as a reason to allow
23882         TREE_OVERFLOW on associated literal constants.
23884 2017-06-14  Eric Botcazou  <ebotcazou@adacore.com>
23886         * config/sparc/sparc.h (MASK_ISA): Add MASK_LEON and MASK_LEON3.
23887         (MASK_FEATURES): New macro.
23888         * config/sparc/sparc.c (sparc_option_override): Remove the special
23889         handling of -mfpu and generalize it to all MASK_FEATURES switches.
23891 2017-06-14  Eric Botcazou  <ebotcazou@adacore.com>
23893         * simplify-rtx.c (simplify_binary_operation_1) <UDIV>: Do not simplify
23894         a division of 0 if non-call exceptions are enabled.
23896 2017-06-14  Andrew Pinski  <apinski@cavium.com>
23897             Naveen H.S  <Naveen.Hurugalawadi@cavium.com>
23899         PR target/71663
23900         * config/aarch64/aarch64.c (aarch64_expand_vector_init):
23901         Improve vector initialization code gen for only variable case.
23903 2017-06-14  Eric Botcazou  <ebotcazou@adacore.com>
23905         * config/sparc/driver-sparc.c (cpu_names): Add SPARC-T5 entry.
23907 2017-06-14  Richard Biener  <rguenther@suse.de>
23909         PR tree-optimization/81083
23910         * tree-ssa-sccvn.c (vn_reference_lookup_3): Do not use abnormals
23911         as values.
23913 2017-06-13  Segher Boessenkool  <segher@kernel.crashing.org>
23915         * config/rs6000/rs6000.c: Update all comments that mentioned SPE.
23916         (rs6000_expand_builtin): Remove RS6000_BTC_EVSEL.
23917         * config/rs6000/rs6000.h (RS6000_BTC_EVSEL): Delete.
23918         * config/rs6000/vxworks.h (VXCPU_FOR_8548): Delete.  Adjust former use.
23919         * config/rs6000/vxworksae.h (VXCPU_FOR_8548): Delete.
23920         * config/rs6000/vxworksmils.h (VXCPU_FOR_8548): Delete.
23922 2017-06-13  Segher Boessenkool  <segher@kernel.crashing.org>
23924         * config/rs6000/rs6000-opts.h (enum rs6000_vector): Delete VECTOR_SPE.
23925         * config/rs6000/rs6000.c (rs6000_debug_vector_unit): Delete VECTOR_SPE.
23927 2017-06-13  Segher Boessenkool  <segher@kernel.crashing.org>
23929         * config/rs6000/rs6000.h (FIXED_SCRATCH): Delete.
23931 2017-06-13  Segher Boessenkool  <segher@kernel.crashing.org>
23933         * config/rs6000/t-rtems: Don't handle SPE.
23935 2017-06-13  Segher Boessenkool  <segher@kernel.crashing.org>
23937         * config/rs6000/t-linux: Don't handle SPE.
23939 2017-06-13  Segher Boessenkool  <segher@kernel.crashing.org>
23941         * config/rs6000/eabispe.h: Delete file.
23943 2017-06-13  Segher Boessenkool  <segher@kernel.crashing.org>
23945         * config/rs6000/t-spe: Delete file.
23947 2017-06-13  Segher Boessenkool  <segher@kernel.crashing.org>
23949         * config/rs6000/rs6000.c (SPE_CONST_OFFSET_OK): Delete.
23950         (rs6000_legitimate_offset_address_p): Return false for anything in
23951         V2SImode or V2SFmode.
23953 2017-06-13  Segher Boessenkool  <segher@kernel.crashing.org>
23955         * config/rs6000/rs6000-modes.def: Remove all 8-byte vector modes
23956         except V2SF and V2SI.  Rearrange the vector modes, and add comments.
23957         * config/rs6000/rs6000.c (rs6000_debug_reg_global): Remove V8QImode
23958         and V4HImode.
23959         (reg_offset_addressing_ok_p): Remove V4HImode and V1DImode.
23960         (rs6000_legitimate_offset_address_p): Ditto.
23961         (rs6000_emit_move): Ditto.
23962         (rs6000_init_builtins): Remove V4HI_type_node.
23964 2017-06-13  Martin Liska  <mliska@suse.cz>
23966         PR sanitize/78204
23967         * asan.c (asan_sanitize_stack_p): Use sanitize_flags_p.
23968         (gate_asan): Likewise.
23969         * asan.h (asan_no_sanitize_address_p): Remove the function.
23970         (sanitize_flags_p): New function.
23971         * builtins.def: Fix coding style.
23972         * common.opt: Use renamed enum value.
23973         * convert.c (convert_to_integer_1): Use sanitize_flags_p.
23974         * doc/extend.texi: Document no_sanitize attribute.
23975         * flag-types.h (enum sanitize_code): Rename SANITIZE_NONDEFAULT
23976         to SANITIZE_UNDEFINED_NONDEFAULT.
23977         * gcc.c (sanitize_spec_function): Use the renamed enum value.
23978         * gimple-fold.c (optimize_atomic_compare_exchange_p):
23979         Use sanitize_flags_p.
23980         * gimplify.c (gimplify_function_tree): Likewise.
23981         * ipa-inline.c (sanitize_attrs_match_for_inline_p): Likewise.
23982         * opts.c (parse_no_sanitize_attribute): New function.
23983         (common_handle_option): Use renamed enum value.
23984         * opts.h (parse_no_sanitize_attribute): Declare.
23985         * tree.c (sanitize_flags_p): New function.
23986         * tree.h: Declared here.
23987         * tsan.c: Use sanitize_flags_p.
23988         * ubsan.c (ubsan_expand_null_ifn): Likewise.
23989         (instrument_mem_ref): Likewise.
23990         (instrument_bool_enum_load): Likewise.
23991         (do_ubsan_in_current_function): Remove the function.
23992         (pass_ubsan::execute): Use sanitize_flags_p.
23993         * ubsan.h: Remove do_ubsan_in_current_function
23994         * tree-cfg.c (print_no_sanitize_attr_value): New function.
23995         (dump_function_to_file): Use it here.
23997 2017-06-13  Martin Jambor  <mjambor@suse.cz>
23999         PR tree-optimization/80803
24000         PR tree-optimization/81063
24001         * tree-sra.c (subtree_mark_written_and_enqueue): Move up in the file.
24002         (propagate_subaccesses_across_link): Enqueue subtree whenever
24003         necessary instead of relying on the caller.
24005 2017-06-13  Martin Jambor  <mjambor@suse.cz>
24007         * tree-sra.c (add_access_to_work_queue): Only enqueue accesses
24008         that have a first_link.
24009         (sort_and_splice_var_accesses): Do not check first_link before
24010         enquing.
24011         (subtree_mark_written_and_enqueue): Likewise.
24012         (propagate_all_subaccesses): Likewise and do not stop at first
24013         parent with a first_link.
24015 2017-06-13  Martin Jambor  <mjambor@suse.cz>
24017         * tree-sra.c (dump_access_tree_1): Fix accidental dumping to stderr
24018         instead of f.
24020 2017-06-13  Yury Gribov  <tetra2005@gmail.com>
24022         * match.pd: New pattern.
24024 2017-06-13  Yury Gribov  <tetra2005@gmail.com>
24026         * tree-vrp.c (is_masked_range_test): New function.
24027         (register_edge_assert_for): Determine ranges for
24028         some bit tests.
24030 2017-06-13  Yury Gribov  <tetra2005@gmail.com>
24032         PR tree-optimization/67328
24033         * fold-const.c (maskable_range_p): New function.
24034         (build_range_check): Generate bittests if possible.
24036 2017-06-13  Martin Liska  <mliska@suse.cz>
24038         * gimple-pretty-print.c (dump_probability): Add new argument.
24039         (dump_edge_probability): Dump both probability and count.
24040         (dump_gimple_label): Likewise.
24041         (dump_gimple_bb_header): Likewise.
24043 2017-06-13  Georg-Johann Lay  <avr@gjlay.de>
24045         PR target/81072
24046         * config/avr/avr-devices.c: Fix indentation.
24047         * config/avr/gen-avr-mmcu-specs.c: Dito.
24049 2017-06-13  Richard Biener  <rguenther@suse.de>
24051         * tree-vect-loop.c (vect_model_reduction_cost): Do not fail,
24052         instead get vector type from stmt_info.
24053         (vectorizable_reduction): Adjust.  Remove dead code.
24055 2017-06-13  Richard Biener  <rguenther@suse.de>
24057         PR middle-end/81065
24058         * fold-const.c (extract_muldiv_1): Remove bogus distribution
24059         case of C * (x * C2 + C3).
24060         (fold_addr_of_array_ref_difference): Properly fold index difference.
24062 2017-06-12  David S. Miller  <davem@davemloft.net>
24064         PR target/80968
24065         * config/sparc/sparc.md (return expander): Emit frame blockage if
24066         function uses alloca.
24068 2017-06-12  Richard Sandiford  <richard.sandiford@linaro.org>
24070         * combine.c (make_field_assignment): Check len rather than the mode
24071         precision when calling force_to_mode.
24073 2017-06-12  Georg-Johann Lay  <avr@gjlay.de>
24075         Support multilibs and devices that see flash in RAM address range.
24077         PR target/81072
24078         * config/avr/avr-arch.h (avr_arch_id) <ARCH_AVRXMEGA3>: New enum.
24079         (avr_mcu_t) <flash_pm_offset>: New field.
24080         (avr_device_specific_features) <AVR_ISA_RCALL>: New enum.
24081         * config/avr/avr.h (AVR_SHORT_CALLS): New define.
24082         (AVR_HAVE_JMP_CALL): Don't set if AVR_SHORT_CALLS.
24083         (AVR_TINY_PM_OFFSET): Remove macro.
24084         * config/avr/avr.opt (-mshort-calls): New option.
24085         * config/avr/gen-avr-mmcu-specs.c (print_mcu)
24086         [*self_spec]: Add / remove -mshort-calls depending on AVR_ISA_RCALL.
24087         * config/avr/avr-c.c (avr_cpu_cpp_builtins)
24088         <__AVR_SHORT_CALLS__>: Built-in define if AVR_SHORT_CALLS.
24089         <__AVR_HAVE_JMP_CALL__>: Use AVR_HAVE_JMP_CALL as condition
24090         instead of avr_arch->have_jmp_call.
24091         <__AVR_PM_BASE_ADDRESS__>: Built-in define if avr_arch->flash_pm_offset.
24092         [AVR_TINY] <__AVR_TINY_PM_BASE_ADDRESS__>: Use
24093         avr_arch->flash_pm_offset to define.
24094         * config/avr/avr-devices.c (avr_arch_types): Add initializers for
24095         new field flash_pm_offset.  Add entry for avrxmega3.
24096         (avr_texinfo): Add entry for avrxmega3.
24097         * config/avr/avr-mcus.def: Add entries for: avrxmega3,
24098         attiny212, attiny214,
24099         attiny412, attiny414, attiny416, attiny417,
24100         attiny814, attiny816, attiny817,
24101         attiny1614, attiny1616, attiny1617,
24102         attiny3214, attiny3216, attiny3217.
24103         * config/avr/avr.c (avr_assemble_integer)[AVR_TINY]: Use
24104         avr_arch->flash_pm_offset instead of AVR_TINY_PM_OFFSET.
24105         (avr_print_operand_address) [AVR_TINY]: Same.
24106         (avr_asm_init_sections) <readonly_data_section>: Only patch
24107         callback if avr_arch->flash_pm_offset = 0.
24108         (avr_asm_named_section) <avr_need_copy_data_p>: Skip setting it
24109         for rodata if avr_arch->flash_pm_offset != 0.
24110         (avr_encode_section_info) [AVR_TINY]: Adjust comment.
24111         * config/avr/genmultilib.awk (dir_rcall, opt_rcall): New vars.
24112         (opts) [AVR_ISA_RCALL]: Append opt_rcall.
24113         (m_options): Append opt_rcall.
24114         (m_dirnames): Append dir_rcall.
24115         * config/avr/t-multilib: Regenerate.
24117         * configure.ac [target=avr]: Check whether avrxmega3 default
24118         linker description file works as needed.
24119         * configure: Regenerate.
24120         * doc/avr-mmcu.texi: Regenerate.
24121         * doc/invoke.texi (AVR Options) <-mshort-calls>: Document it.
24122         <__AVR_ARCH__>: Document avrxmega3 and 103.
24123         <__AVR_HAVE_JMP_CALL__>: Adjust documentation.
24124         <__AVR_SHORT_CALLS__>: Document it.
24125         <__AVR_PM_BASE_ADDRESS__>: Document it.
24126         * doc/extend.texi (AVR Options) <-mshort-calls>: Document it.
24127         (AVR Variable Attributes) <progmem>: Document this is
24128         not needed for avrxmega3.
24129         (AVR Named Address Spaces) <__flash>: Dito.
24131 2017-06-12  Jan Hubicka  <hubicka@ucw.cz>
24133         * cgraph.c (cgraph_node::dump): Complain about profile insanities.
24135 2017-06-12  Doug Rupp  <rupp@adacore.com>
24137         * config.gcc (*-*-vxworks*): Set use_gcc_stdint to "provide".
24138         Append vxworks-stdint.h to the tm_file list.
24139         * config/vxworks-stdint.h: New file.
24141 2017-06-12  Martin Liska  <mliska@suse.cz>
24143         PR tree-optimization/81041
24144         * tree-profile.c (gimple_gen_ic_func_profiler):
24145         Create an extra BB in profile-generate
24146         (gimple_gen_time_profiler): Likewise.
24148 2017-06-12  Jakub Jelinek  <jakub@redhat.com>
24150         PR tree-optimization/81003
24151         * tree-ssa-reassoc.c (force_into_ssa_name): New function.
24152         (update_range_test): Use it instead of force_gimple_operand_gsi.
24154 2017-06-12  Richard Biener  <rguenther@suse.de>
24156         PR tree-optimization/81053
24157         * tree-vect-loop.c (vect_is_simple_reduction): Handle PHI
24158         with backedge value not defined in loop.  Simplify def stmt
24159         compute.
24161 2017-06-11  Tom de Vries  <tom@codesourcery.com>
24163         PR target/79939
24164         * config/nvptx/nvptx.c (nvptx_cannot_force_const_mem): New function.
24165         Return true.
24166         (TARGET_CANNOT_FORCE_CONST_MEM): Redefine to
24167         nvptx_cannot_force_const_mem.
24169 2017-06-10  Jan Hubicka  <hubicka@ucw.cz>
24171         * opts.c (finish_options): Move test for flag_split_stack after
24172         it has been initialized.
24174 2017-06-11  Jason Merrill  <jason@redhat.com>
24176         * tree.h (id_equal): New.
24177         * dwarf2out.c, hsa-gen.c, ipa-devirt.c, omp-expand.c,
24178         omp-simd-clone.c, read-rtl-function.c, tree-chkp.c, tree.c: Use it
24179         instead of strcmp of IDENTIFIER_POINTER.
24181 2017-06-10  Jan Hubicka  <hubicka@ucw.cz>
24183         * ipa-inline-transform.c: Include function.h, cfg.h and basic-block.h
24184         (mark_all_inlined_calls_cdtor): Fix formating.
24185         (inline_transform): Rescale profile before inlining.
24187 2017-06-10  Jan Hubicka  <hubicka@ucw.cz>
24189         * cgraph.h (cgraph_edge::clone): Update prototype.
24190         * cgraphclones.c (cgraph_edge::clone): Update profile scaling.
24191         (cgraph_node::create_clone): Update.
24192         (cgraph_node::create_version_clone): Update.
24193         * tree-inline.c (copy_bb): Update.
24194         (expand_call_inline): Update.
24196 2017-06-10  Segher Boessenkool  <segher@kernel.crashing.org>
24198         * config/rs6000/rs6000.c (emit_vrsave_prologue): New function,
24199         factored out from ...
24200         (rs6000_emit_prologue): ... here.
24202 2017-06-10  Segher Boessenkool  <segher@kernel.crashing.org>
24204         * config/rs6000/rs6000.c (emit_split_stack_prologue): New function,
24205         factored out from ...
24206         (rs6000_emit_prologue): ... here.
24208 2017-06-10  Jan Hubicka  <hubicka@ucw.cz>
24210         * predict.c (drop_profile): Also drop individual bb/edge and cgraph
24211         edge counts.
24212         (handle_missing_profiles): Fix computation of tp_first_run.
24213         (counts_to_freqs): Do not touch freqs when count is 0.
24215 2017-06-10  Jan Hubicka  <hubicka@ucw.cz>
24217         * cgraphbuild.c (cgraph_edge::rebuild_references): Do not touch
24218         profile.
24220 2017-06-10  Tom de Vries  <tom@codesourcery.com>
24222         * doc/sourcebuild.texi (Effective-Target Keywords, Environment
24223         attributes): Document signal effective target.
24225 2017-06-10  Tom de Vries  <tom@codesourcery.com>
24227         * doc/sourcebuild.texi (Effective-Target Keywords, Other attributes):
24228         Document effective target stack_size.
24230 2017-06-09  David Malcolm  <dmalcolm@redhat.com>
24232         * diagnostic.c (diagnostic_report_diagnostic): Only add fixits
24233         to the edit_context if they can be auto-applied.
24235 2017-06-9  Ian Lance Taylor  <iant@golang.org>
24237         * opts.c (finish_options): If -fsplit-stack, disable implicit
24238         -forder-blocks-and-partition.
24239         * doc/invoke.texi (Optimize Options): Document that when using
24240         -fsplit-stack -forder-blocks-and-partition is not implicitly
24241         enabled.
24243 2017-06-09  Jan Hubicka  <hubicka@ucw.cz>
24245         * builtin-attrs.def (ATTR_NORETURN_NOTHROW_LEAF_COLD_LIST,
24246         ATTR_CONST_NORETURN_NOTHROW_LEAF_COLD_LIST,
24247         ATTR_TMPURE_NORETURN_NOTHROW_LEAF_COLD_LIST): New.
24248         * builtins.def (abort, trap, unreachable): Declare cold.
24249         * calls.c (flags_from_decl_or_type): Lookup ECF_COLD.
24250         * tree-core.h (ECF_COLD): New.
24251         * tree.c (set_call_expr_flags): Handle ECF_COLD.
24252         (build_common_builtin_nodes): Mark unreachable and abort as cold.
24254 2017-06-09  Jan Hubicka  <hubicka@ucw.cz>
24256         * predict.c (unlikely_executed_stmt_p): Cleanup.
24258 2017-06-09  Richard Biener  <rguenther@suse.de>
24260         * tree-ssa-loop-im.c (execute_sm): Do not force multi-threaded
24261         model if the ref is always written to.
24263 2017-06-09  Tamar Christina  <tamar.christina@arm.com>
24265         * config/aarch64/aarch64.md (lrint<GPF:mode><GPI:mode>2): New.
24267 2017-06-09  Tamar Christina  <tamar.christina@arm.com>
24269         * config/arm/arm.c (arm_rtx_costs_internal): Make sdiv more expensive
24270         than udiv.
24272 2017-06-09  Tom de Vries  <tom@codesourcery.com>
24274         PR target/80855
24275         * config/nvptx/nvptx.md (define_expand "mov<QHSDISDFM>"): Error out with
24276         "target cannot support label values" when encountering LABEL_REF.
24278 2017-06-09  Martin Liska  <mliska@suse.cz>
24280         * tree-profile.c (gimple_gen_ic_profiler): Update comment.
24281         (gimple_gen_ic_func_profiler): Emit direct comparison
24282         of __gcov_indirect_call_callee with NULL.
24283         (gimple_gen_time_profiler): Change probability from
24284         PROB_VERY_UNLIKELY to PROB_UNLIKELY.
24286 2017-06-09  Jan Hubicka  <hubicka@ucw.cz>
24288         * profile.c (edge_gcov_counts): Turn to pointer.
24289         (compute_branch_probabilities, compute_branch_probabilities): Update.
24290         (branch_prob): Do not clear edge_gcov_count.
24291         * profile.h (edge_gcov_counts): Turn to pointer.
24292         (edge_gcov_count): Update.
24294 2017-06-09  Jan Hubicka  <hubicka@ucw.cz>
24296         * gimple.h (gimple_check_failed): Mark cold.
24298 2017-06-09  Richard Biener  <rguenther@suse.de>
24300         PR tree-optimization/66623
24301         * tree-vect-loop.c (vect_is_simple_reduction): Cleanup,
24302         refactor check_reduction into two parts, properly computing
24303         whether we have to check reduction validity for outer loop
24304         vectorization.
24306 2017-06-09  Richard Biener  <rguenther@suse.de>
24308         PR tree-optimization/79483
24309         * graphite-scop-detection.c (order): New global.
24310         (get_order): Compute bb to order mapping that satisfies code
24311         generation constraints.
24312         (cmp_pbbs): New helper.
24313         (build_scops): Start domwalk at entry block, sort generated
24314         pbbs.
24316 2017-06-09  Richard Biener  <rguenther@suse.de>
24318         PR middle-end/81007
24319         * ipa-polymorphic-call.c
24320         (ipa_polymorphic_call_context::restrict_to_inner_class):
24321         Skip FIELD_DECLs with error_mark_node type.
24322         * passes.def (all_lowering_passes): Run pass_build_cgraph_edges
24323         last again.
24325 2017-06-09  Martin Liska  <mliska@suse.cz>
24327         * predict.c (struct branch_predictor): New struct.
24328         (test_prediction_value_range): New test.
24329         (predict_c_tests): New function.
24330         * selftest-run-tests.c (selftest::run_tests): Run the function.
24331         * selftest.h: Declare new tests.
24333 2017-06-09  Segher Boessenkool  <segher@kernel.crashing.org>
24335         PR target/80966
24336         * config/rs6000/rs6000.c (rs6000_emit_allocate_stack): Assert that
24337         gen_add3_insn did not fail.
24338         * config/rs6000/rs6000.md (add<mode>3): If asked to add a constant to
24339         r0, construct that number in a temporary reg and add that reg to r0.
24340         If asked to put the result in r0 as well, fail.
24342 2017-06-08  Will Schmidt  <will_schmidt@vnet.ibm.com>
24344         * config/rs6000/rs6000.c (rs6000_gimple_fold_builtin): Add handling
24345         for early expansion of vec_eqv.
24347 2017-06-08  Jakub Jelinek  <jakub@redhat.com>
24349         PR middle-end/81005
24350         * ubsan.c (instrument_null): Avoid pointless code temporary.
24351         (pass_ubsan::execute): Instrument aggregate arguments of calls.
24353 2017-06-08  Uros Bizjak  <ubizjak@gmail.com>
24355         PR target/81015
24356         Revert:
24357         2016-12-14  Uros Bizjak  <ubizjak@gmail.com>
24359         PR target/59874
24360         * config/i386/i386.md (*ctzhi2): New insn_and_split pattern.
24361         (*clzhi2): Ditto.
24363 2017-06-08  Jan Hubicka  <hubicka@ucw.cz>
24365         * predict.c (unlikely_executed_edge_p): Move ahead.
24366         (probably_never_executed_edge_p): Use it.
24368 2017-06-08  Alexander Ivchenko  <alexander.ivchenko@intel.com>
24370         PR middle-end/79988
24371         * tree-chkp.c (chkp_gimple_call_builtin_p): Remove
24372         gimple_call_builtin_p call.
24374 2017-06-08  Jan Hubicka  <hubicka@ucw.cz>
24376         * system.h (fancy_abort): Annotate by ATTRIBUTE_COLD.
24377         * rtl.h (rtl_check_failed_bounds, rtl_check_failed_type1,
24378         rtl_check_failed_type2, rtl_check_failed_code1,
24379         rtl_check_failed_code2, rtl_check_failed_code_mode,
24380         rtl_check_failed_block_symbol, cwi_check_failed_bounds,
24381         rtvec_check_failed_bounds, rtl_check_failed_flag,
24382         _fatal_insn_not_found, _fatal_insn): Likewise.
24383         * tree.h (tree_contains_struct_check_failed,
24384         tree_check_failed, tree_not_check_failed,
24385         tree_class_check_failed, tree_range_check_failed,
24386         tree_not_class_check_failed, tree_int_cst_elt_check_failed,
24387         tree_vec_elt_check_failed, phi_node_elt_check_failed,
24388         tree_operand_check_failed, omp_clause_check_failed,
24389         omp_clause_operand_check_failed, omp_clause_range_check_failed):
24390         Likewise.
24392 2017-06-08  Jan Hubicka  <hubicka@ucw.cz>
24394         * cgraph.c (cgraph_edge::maybe_hot_p): Do not check
24395         flag_branch_probabilities.
24396         * ipa-inline.c (edge_badness): Likewise.
24397         * ipa-profile.c (ipa_propagate_frequency_1): Likewise.
24398         * postreload-gcse.c (eliminate_partially_redundant_load): Likewise.
24399         * predict.c (maybe_hot_frequency_p): Likewise.
24400         (probably_never_executed): Likewise.
24401         * sched-ebb.c (schedule_ebbs): Likewise.
24402         * sched-rgn.c (find_single_block_region): Likewise.
24403         * tracer.c (tail_duplicate): Likewise.
24405 2017-06-08  Jan Hubicka  <hubicka@ucw.cz>
24407         * opts.c (finish_options): x_flag_reorder_blocks_and_partition no
24408         longer requires x_flag_profile_use.
24410 2017-06-08  Jan Hubicka  <hubicka@ucw.cz>
24412         * cfgrtl.c (cfg_layout_initialize): Check crtl->has_bb_partition
24413         instead of flag_reorder_blocks_and_partition.
24414         * dbxout.c (dbxout_function_end): Likewise.
24415         * dwarf2out.c (gen_subprogram_die): Likewise.
24416         * haifa-sched.c (sched_create_recovery_edges): Likewise.
24417         * hw-doloop.c (reorg_loops): Likewise.
24418         * varasm.c (assemble_start_function,
24419         assemble_end_function): Likewise.
24420         (decide_function_section): Do not check for
24421         flag_reorder_blocks_and_partition.
24423 2017-06-08  Alexander Ivchenko  <alexander.ivchenko@intel.com>
24425         * tree-chkp.c (chkp_get_hard_register_var_fake_base_address):
24426         New function.
24427         (chkp_get_hard_register_fake_addr_expr): Ditto.
24428         (chkp_build_addr_expr): Add check for hard reg case.
24429         (chkp_parse_array_and_component_ref): Ditto.
24430         (chkp_find_bounds_1): Ditto.
24431         (chkp_process_stmt): Don't generate bounds store for
24432         hard reg case.
24434 2017-06-08  Jan Hubicka  <hubicka@ucw.cz>
24436         * predict.c (maybe_hot_bb_p): Do not check profile status.
24437         (maybe_hot_edge_p): Likewise.
24438         (probably_never_executed): Check for zero counts even if profile
24439         is not read.
24440         (unlikely_executed_edge_p): New function.
24441         (unlikely_executed_stmt_p): New function.
24442         (unlikely_executed_bb_p): New function.
24443         (set_even_probabilities): Use unlikely predicates.
24444         (combine_predictions_for_bb): Likewise.
24445         (predict_paths_for_bb): Likewise.
24446         (predict_paths_leading_to_edge): Likewise.
24447         (determine_unlikely_bbs): New function.
24448         (estimate_bb_frequencies): Use it.
24449         (compute_function_frequency): Use zero counts even if profile is
24450         not read.
24451         * profile-count.h: Fix typo.
24453 2017-08-08  Julia Koval  <julia.koval@intel.com>
24455         * config/i386/avx512bwintrin.h (_mm512_mask_cvtepi16_storeu_epi8,
24456         _mm512_mask_cvtsepi16_storeu_epi8,
24457         _mm512_mask_cvtusepi16_storeu_epi8): New intrinsics.
24458         * config/i386/avx512vlbwintrin.h (_mm256_mask_cvtepi16_storeu_epi8,
24459         _mm_mask_cvtsepi16_storeu_epi8, _mm256_mask_cvtsepi16_storeu_epi8,
24460         _mm_mask_cvtusepi16_storeu_epi8, _mm256_mask_cvtusepi16_storeu_epi8,
24461         _mm_mask_cvtepi16_storeu_epi8): New intrinsics.
24462         * config/i386/i386-builtin-types.def (PV8Q, V8QI): New pointer type.
24463         (VOID_FTYPE_PV32QI_V32HI_USI, VOID_FTYPE_PV8QI_V8HI_UQI,
24464         VOID_FTYPE_PV16QI_V16HI_UHI): New function types.
24465         * config/i386/i386-builtin.def (__builtin_ia32_pmovwb128mem_mask,
24466         __builtin_ia32_pmovwb256mem_mask, __builtin_ia32_pmovswb128mem_mask,
24467         __builtin_ia32_pmovswb256mem_mask, __builtin_ia32_pmovuswb128mem_mask,
24468         __builtin_ia32_pmovuswb256mem_mask,
24469         __builtin_ia32_pmovuswb512mem_mask, __builtin_ia32_pmovswb512mem_mask)
24470         __builtin_ia32_pmovwb512mem_mask): New builtins.
24472 2017-08-08  Julia Koval  <julia.koval@intel.com>
24474         PR target/73350,80862
24475         * config/i386/subst.md (round): Fix round pattern.
24476         * config/i386/i386.c (ix86_erase_embedded_rounding):
24477         Fix erasing rounding for the fixed pattern.
24479 2017-06-08  Jan Hubicka  <hubicka@ucw.cz>
24481         * cfgbuild.c (find_many_sub_basic_blocks): Fix thinko.
24483 2017-06-08  Martin Liska  <mliska@suse.cz>
24485         PR gcov-profile/80911
24486         * gcov.c (block_info::block_info): New constructor.
24488 2017-06-07  Carl Love  <cel@us.ibm.com>
24490         * config/rs6000/rs6000-c: The return type of the following
24491         built-in functions was implemented as int not long long.  Fix sign
24492         of return value for the unsigned version of vec_mulo and vec_mule.
24493         vector unsigned long long vec_bperm (vector unsigned long long,
24494                                              vector unsigned char)
24495         vector signed long long vec_mule (vector signed int,
24496                                           vector signed int)
24497         vector unsigned long long vec_mule (vector unsigned int,
24498                                             vector unsigned int)
24499         vector signed long long vec_mulo (vector signed int,
24500                                           vector signed int)
24501         vector unsigned long long vec_mulo (vector unsigned int,
24502                                             vector unsigned int)
24503         * doc/extend.texi: Fix the documentation for the built-in
24504         functions.
24506 2017-06-07  Carl Love  <cel@us.ibm.com>
24508         PR target/80982
24509         * config/rs6000/altivec.md (double<mode>2): Fix the implementation of
24510         for BE.
24512 2017-06-07  Carl Love  <cel@us.ibm.com>
24514         * config/rs6000/altivec.md: Fix argument swizzle in vec_doublel
24515         support, Generate       doublehv for signed int/float for BE case only.
24517 2017-06-07  Alexander Monakov  <amonakov@ispras.ru>
24519         * doc/invoke.texi (mcx16): Rewrite.
24521 2017-06-07  Segher Boessenkool  <segher@kernel.crashing.org>
24523         * config/rs6000/predicates.md (rs6000_nonimmediate_operand): Delete.
24524         * config/rs6000/rs6000.md (*movsi_internal1, movsi_from_sf,
24525         *mov<mode>_softfloat, and an anonymous splitter): Use
24526         nonimmediate_operand instead of rs6000_nonimmediate_operand.
24528 2017-06-07  Segher Boessenkool  <segher@kernel.crashing.org>
24530         * config/rs6000/darwin.h (REGISTER_NAMES): Delete the SPE_ACC and
24531         SPEFSCR registers.
24532         * config/rs6000/rs6000.c (rs6000_reg_names, alt_reg_names): Ditto.
24533         (enum rs6000_reg_type): Delete SPE_ACC_TYPE and SPEFSCR_REG_TYPE.
24534         (rs6000_debug_reg_global): Adjust.
24535         (rs6000_init_hard_regno_mode_ok): Adjust.
24536         (rs6000_dbx_register_number): Adjust.
24537         * config/rs6000/rs6000.h (FIRST_PSEUDO_REGISTER): Change to 115.
24538         (FIXED_REGISTERS, CALL_USED_REGISTERS, CALL_REALLY_USED_REGISTERS):
24539         Remove SPE_ACC and SPEFSCR.
24540         (REG_ALLOC_ORDER): Ditto.
24541         (FRAME_POINTER_REGNUM): Change to 111.
24542         (enum reg_class): Remove the SPE_ACC and SPEFSCR registers.
24543         (REG_CLASS_NAMES): Ditto.
24544         (REG_CLASS_CONTENTS): Delete the SPE_ACC and SPEFSCR registers.
24545         (REGISTER_NAMES): Ditto.
24546         (ADDITIONAL_REG_NAMES): Ditto.
24547         (rs6000_reg_names): Ditto.
24548         * config/rs6000/rs6000.md: Renumber some register number
24549         define_constants.
24551 2017-06-07  Segher Boessenkool  <segher@kernel.crashing.org>
24553         * config/rs6000/darwin.h (REGISTER_NAMES): Delete the SPE high
24554         registers.
24555         * config/rs6000/rs6000.c (rs6000_reg_names, alt_reg_names): Ditto.
24556         * config/rs6000/rs6000.h (FIRST_PSEUDO_REGISTER): Change from 149
24557         to 117.
24558         (DWARF_REG_TO_UNWIND_COLUMN): Do not define.
24559         (FIXED_REGISTERS, CALL_USED_REGISTERS, CALL_REALLY_USED_REGISTERS):
24560         Delete the SPE high registers.
24561         (REG_ALLOC_ORDER): Ditto.
24562         (enum reg_class): Remove SPE_HIGH_REGS.
24563         (REG_CLASS_NAMES): Ditto.
24564         (REG_CLASS_CONTENTS): Delete the SPE high registers.
24565         (REGISTER_NAMES): Ditto.
24566         (rs6000_reg_names): Ditto.
24567         * doc/tm.texi.in: Remove SPE as example.
24568         * doc/tm.texi: Regenerate.
24570 2017-06-07  Segher Boessenkool  <segher@kernel.crashing.org>
24572         * config/rs6000/8540.md (ppc8540_brinc): Delete.
24573         * config/rs6000/e500mc.md (e500mc_brinc): Delete.
24574         * config/rs6000/e500mc64.md (e500mc64_brinc): Delete.
24575         * config/rs6000/rs6000.md (type): Remove "brinc".
24577 2017-06-07  Segher Boessenkool  <segher@kernel.crashing.org>
24579         * config.gcc (powerpc*-*-*): Don't add spe.h to extra_headers.
24580         (powerpc*-linux*spe*): Use ${cpu_type} instead of rs6000.
24581         * config/rs6000/linuxspe.h: Delete file.
24582         * config/rs6000/rs6000.md: Don't include spe.md.
24583         * config/rs6000/spe.h: Delete file.
24584         * config/rs6000/spe.md: Delete file.
24585         * config/rs6000/t-rs6000: Remove spe.md.
24587 2017-06-07  Segher Boessenkool  <segher@kernel.crashing.org>
24589         * config/rs6000/predicates.md (reg_or_mem_operand): Reformat.
24590         (reg_or_none500mem_operand): Delete.
24591         * config/rs6000/rs6000.md (extendsfdf2): Use reg_or_mem_operand
24592         instead of reg_or_none500mem_operand.
24594 2017-06-07  Segher Boessenkool  <segher@kernel.crashing.org>
24596         * config/rs6000/rs6000.c (rs6000_option_override_internal): Delete
24597         handling of SPE flags.
24598         * config/rs6000/rs6000.opt (-mspe, -mspe=no, -mspe=yes): Delete.
24600 2017-06-07  Segher Boessenkool  <segher@kernel.crashing.org>
24602         * config/rs6000/rs6000-common.c (rs6000_handle_option): Remove
24603         SPE ABI handling.
24604         * config/rs6000/paired.md (paired_negv2sf2): Rename to negv2sf2.
24605         (paired_absv2sf2, paired_addv2sf3, paired_subv2sf3, paired_mulv2sf3,
24606         paired_divv2sf3): Similar.
24607         * config/rs6000/predicates.md: Replace TARGET_SPE, TARGET_SPE_ABI,
24608         SPE_VECTOR_MODE and SPE_HIGH_REGNO_P by 0; simplify.
24609         * config/rs6000/rs6000-builtin.def: Delete RS6000_BUILTIN_E and
24610         RS6000_BUILTIN_S.
24611         Delete BU_SPE_1, BU_SPE_2, BU_SPE_3, BU_SPE_E, BU_SPE_P, and BU_SPE_X.
24612         Rename the paired_* instruction patterns.
24613         * config/rs6000/rs6000-c.c (rs6000_target_modify_macros): Do not
24614         define __SPE__.
24615         * config/rs6000/rs6000-protos.h (invalid_e500_subreg): Delete.
24616         * config/rs6000/rs6000.c: Delete RS6000_BUILTIN_E and RS6000_BUILTIN_S.
24617         (struct rs6000_stack): Delete fields spe_gp_save_offset, spe_gp_size,
24618         spe_padding_size, and spe_64bit_regs_used.  Replace TARGET_SPE and
24619         TARGET_SPE_ABI with 0, simplify.  Replace SPE_VECTOR_MODE with
24620         PAIRED_VECTOR_MODE.
24621         (struct machine_function): Delete field spe_insn_chain_scanned_p.
24622         (spe_func_has_64bit_regs_p): Delete.
24623         (spe_expand_predicate_builtin): Delete.
24624         (spe_expand_evsel_builtin): Delete.
24625         (TARGET_DWARF_REGISTER_SPAN): Do not define.
24626         (TARGET_MEMBER_TYPE_FORCES_BLK): Do not define.
24627         (invalid_e500_subreg): Delete.
24628         (rs6000_legitimize_address): Always force_reg op2 as well, for
24629         paired single memory accesses.
24630         (rs6000_member_type_forces_blk): Delete.
24631         (rs6000_spe_function_arg): Delete.
24632         (rs6000_expand_unop_builtin): Delete SPE handling.
24633         (rs6000_expand_binop_builtin): Ditto.
24634         (spe_expand_stv_builtin): Delete.
24635         (bdesc_2arg_spe): Delete.
24636         (spe_expand_builtin): Delete.
24637         (spe_expand_predicate_builtin): Delete.
24638         (spe_expand_evsel_builtin): Delete.
24639         (rs6000_invalid_builtin): Remove RS6000_BTM_SPE handling.
24640         (spe_init_builtins): Delete.
24641         (spe_func_has_64bit_regs_p): Delete.
24642         (savres_routine_name): Delete "info" parameter.  Adjust callers.
24643         (rs6000_emit_stack_reset): Ditto.
24644         (rs6000_dwarf_register_span): Delete.
24645         * config/rs6000/rs6000.h (TARGET_SPE_ABI, TARGET_SPE,
24646         UNITS_PER_SPE_WORD, SPE_HIGH_REGNO_P, SPE_SIMD_REGNO_P,
24647         SPE_VECTOR_MODE, RS6000_BTM_SPE, RS6000_BUILTIN_E, RS6000_BUILTIN_S):
24648         Delete.
24649         * config/rs6000/rs6000.md (FIRST_SPE_HIGH_REGNO, LAST_SPE_HIGH_REGNO):
24650         Delete.
24651         * config/rs6000/rs6000.opt (-mabi=spe, -mabi=no-spe): Delete.
24652         * config/rs6000/spe.md: Delete every pattern that uses TARGET_SPE.
24653         * config/rs6000/vector.md (absv2sf2, negv2sf2, addv2sf3, subv2sf3,
24654         mulv2sf3, divv2sf3): Delete expanders.
24656 2017-06-07  Segher Boessenkool  <segher@kernel.crashing.org>
24658         config/rs6000/rs6000.md (UNSPEC_MV_CR_GT): Delete.
24660 2017-06-07  Segher Boessenkool  <segher@kernel.crashing.org>
24662         * config/rs6000/rs6000-protos.h (output_e500_flip_gt_bit): Delete.
24663         * config/rs6000/rs6000.c: Ditto.
24665 2017-06-07  Segher Boessenkool  <segher@kernel.crashing.org>
24667         * config/rs6000/predicated.md (rs6000_cbranch_operator): Delete.
24668         * config/rs6000/rs6000.md: Replace rs6000_cbranch_operator by
24669         comparison_operator.
24671 2017-06-07  Segher Boessenkool  <segher@kernel.crashing.org>
24673         * config/rs6000/rs6000.c: Remove everything related to -mfloat-gprs.
24674         * config/rs6000/rs6000.opt: Ditto.
24675         * config/rs6000/t-rtems: Ditto.
24677 2017-06-07  Segher Boessenkool  <segher@kernel.crashing.org>
24679         * config/rs6000/predicates.md: Replace TARGET_E500_DOUBLE and
24680         TARGET_E500_SINGLE by 0, simplify.
24681         * config/rs6000/rs6000.c: Ditto.
24682         (rs6000_option_override_internal): Delete CHECK_E500_OPTIONS.
24683         (spe_build_register_parallel): Delete.
24684         * config/rs6000/rs6000.h: Delete TARGET_E500_SINGLE,
24685         TARGET_E500_DOUBLE, and CHECK_E500_OPTIONS.
24686         * config/rs6000/rs6000.md: Replace TARGET_E500_DOUBLE,
24687         TARGET_E500_SINGLE, and <E500_CONVERT> by 0, simplify.
24688         (E500_CONVERT): Delete.
24689         * config/rs6000/spe.md: Remove many patterns and all define_constants.
24691 2017-06-07  Segher Boessenkool  <segher@kernel.crashing.org>
24693         * config/rs6000/darwin.md: Replace TARGET_FPRS by 1 and simplify.
24694         * config/rs6000/dfp.md: Ditto.
24695         (negdd2, *negdd2_fpr): Merge.
24696         (absdd2, *absdd2_fpr): Merge.
24697         (negtd2, *negtd2_fpr): Merge.
24698         (abstd2, *abstd2_fpr): Merge.
24699         * config/rs6000/e500.h: Delete file.
24700         * config/rs6000/predicates.md (rs6000_cbranch_operator): Replace
24701         TARGET_FPRS by 1 and simplify.
24702         * config/rs6000/rs6000-c.c: Ditto.
24703         * config/rs6000/rs6000.c: Ditto.  Also replace TARGET_SF_SPE and
24704         TARGET_DF_SPE by 0.
24705         * config/rs6000/rs6000.h: Ditto.  Delete TARGET_SF_SPE and
24706         TARGET_DF_SPE.
24707         * config/rs6000/rs6000.md: Ditto.
24708         (floatdidf2, *floatdidf2_fpr): Merge.
24709         (move_from_CR_gt_bit): Delete.
24710         * config/rs6000/spe.md: Replace TARGET_FPRS by 1 and simplify.
24711         (E500_CR_IOR_COMPARE): Delete.
24712         (All patterns that require !TARGET_FPRS): Delete.
24713         * config/rs6000/vsx.md: Replace TARGET_FPRS by 1 and simplify.
24715 2017-06-07  Bin Cheng  <bin.cheng@arm.com>
24717         * passes.def (pass_iv_canon): Move before pass_loop_distribution.
24719 2017-06-07  Bin Cheng  <bin.cheng@arm.com>
24721         * graphds.c (add_edge): Intitialize edge's attached data.
24722         (foll_in_subgraph, dfs_fst_edge, dfs_next_edge): New function
24723         pointer parameter.  Call pointed function on each edge during
24724         graph traversing.  Skip traversing the edge when the function
24725         returns true.
24726         (graphds_dfs, graphds_scc): Ditto.
24727         (for_each_edge): New parameter.  Pass the new parameter to callback
24728         function.
24729         * graphds.h (skip_edge_callback): New function pointer type.
24730         (graphds_dfs, graphds_scc): New function pointer parameter.
24731         (graphds_edge_callback, for_each_edge): New parameter.
24733 2017-06-07  Bin Cheng  <bin.cheng@arm.com>
24735         * tree-vect-data-refs.c (vect_mark_for_runtime_alias_test): Factor
24736         out code checking if runtime alias check is possible to below ...
24737         Call the new function.
24738         * tree-data-ref.c (runtime_alias_check_p): ... to new function.
24739         * tree-data-ref.h (runtime_alias_check_p): New decalaration.
24741 2017-06-07  Marek Polacek  <polacek@redhat.com>
24743         PR sanitizer/80932
24744         * fold-const.c (extract_muldiv_1) <case MINUS_EXPR>: Add
24745         TYPE_OVERFLOW_WRAPS check.
24747 2017-06-07  Bin Cheng  <bin.cheng@arm.com>
24749         * tree-vect-loop-manip.c (vect_do_peeling): Don't skip vector loop
24750         if versioning is required.
24751         * tree-vect-loop.c (vect_analyze_loop_2): Merge niter check for loop
24752         peeling with the check for versioning.
24754 2017-06-07  Bin Cheng  <bin.cheng@arm.com>
24756         * tree-vectorizer.h (vect_build_loop_niters): New parameter.
24757         * tree-vect-loop-manip.c (vect_build_loop_niters): New parameter.
24758         Set true to new parameter if new ssa variable is defined.
24759         (vect_gen_vector_loop_niters): Refactor.  Set range information
24760         for the new vector loop bound variable.
24761         (vect_do_peeling): Ditto.
24763 2017-06-07  Bin Cheng  <bin.cheng@arm.com>
24765         * tree-affine.c (ssa.h): Include header file.
24766         (tree_to_aff_combination): Handle (T1)(X - CST) when inner type
24767         has wrapping overflow behavior.
24769 2017-06-07  Bin Cheng  <bin.cheng@arm.com>
24771         * tree-affine.c (tree_to_aff_combination): Handle (T1)(X + X).
24773 2017-06-07  Bin Cheng  <bin.cheng@arm.com>
24775         (aff_combination_expand): Move (T1)(X *+- CST) simplification to ...
24776         (tree_to_aff_combination): ... here.
24778 2017-06-07  Bin Cheng  <bin.cheng@arm.com>
24780         * tree-ssa-loop-ivopts.c (ivopts_estimate_reg_pressure): New
24781         reg_pressure model function.
24782         (ivopts_global_cost_for_size): Delete.
24783         (determine_set_costs, iv_ca_recount_cost): Call new model function
24784         ivopts_estimate_reg_pressure.
24786 2017-06-07  Tamar Christina  <tamar.christina@arm.com>
24788         * config/aarch64/aarch64.c (aarch64_rtx_costs): Make sdiv more
24789         expensive than udiv.  Remove floating point cases from mod.
24791 2017-06-07  Tamar Christina  <tamar.christina@arm.com>
24793         * config/arm/aarch-cost-tables.h (cortexa53_extra_cost):
24794         Increase idiv cost.
24796 2017-06-07  Tamar Christina  <tamar.christina@arm.com>
24798         * config/aarch64/aarch64.md
24799         (copysignsf3): Fix mask generation.
24801 2017-06-07  Jakub Jelinek  <jakub@redhat.com>
24803         * dumpfile.h (enum tree_dump_index): Rename TDI_generic to
24804         TDI_gimple.
24805         (class dump_manager): Add register_dumps method.
24806         * dumpfile.c: Include langhooks.h.
24807         (dump_files): Use 0 instead of 3/4/5 for TDI_{original,gimple,nested}.
24808         (FIRST_AUTO_NUMBERED_DUMP): Decrease to 1.
24809         (FIRST_ME_AUTO_NUMBERED_DUMP): Define.
24810         (dump_manager::dump_register): Start with 512 entries instead of 32.
24811         (dump_manager::register_dumps): New method.
24812         * toplev.c (general_init): Instead of invoking register_dumps
24813         langhook, invoke register_dumps method on the dump manager.
24814         * gimplify.c (gimplify_function_tree): Use TDI_gimple instead of
24815         TDI_generic.
24817 2017-06-07  Richard Sandiford  <richard.sandiford@linaro.org>
24819         * doc/md.texi: Clarify the restrictions on a define_insn condition.
24820         Say that # requires an associated define_split to exist, and that
24821         the define_split must be suitable for use after register allocation.
24823 2017-06-06  Jan Hubicka  <hubicka@ucw.cz>
24825         * cfgbuild.c (find_bb_boundaries): Initialize profile of split blocks.
24826         (compute_outgoing_frequencies): Also initialize zero counts.
24827         (find_many_sub_basic_blocks): Do not produce uninitialized profile
24828         around loops; preserve more of profile when nothing changes.
24830 2017-06-06  Jim Wilson  <jim.wilson@linaro.org>
24832         * config/aarch64/aarch64-cost-tables.h (qdf24xx_extra_costs): Move to
24833         here.
24834         * config/arm/aarch-cost-tables.h (qdf24xx_extra_costs): From here.
24835         * config/arm/arm-cpu-cdata.h: Regenerate.
24836         * config/arm/arm-cpu-data.h, config/arm/arm-cpu.h: Likewise.
24837         * config/arm/arm-tables.opt, config/arm/arm-tune.md: Likewise.
24838         * config/arm/arm-cpus.in: Delete falkor and qdf24xx entries.
24839         * config/arm/arm.c (arm_qdf24xx_tune): Delete.
24840         * config/arm/bpabi.h (BE8_LINK_SPEC): Delete falkor and qdf24xx
24841         support.
24842         * config/arm/t-aprofile (MULTILIB_MATCHES): Delete falkor and qdf24xx
24843         support.
24844         * config/arm/t-rmprofile: Likewise.
24845         * doc/invoke.texi (ARM Options): Drop falkor and qdf24xx support.
24847 2017-06-06  David S. Miller  <davem@davemloft.net>
24849         PR target/80968
24850         * config/sparc/sparc.c (sparc_expand_prologue): Emit frame
24851         blockage if function uses alloca.
24853 2017-06-06  Maxim Kuvyrkov  <maxim.kuvyrkov@linaro.org>
24855         * tree-ssa-loop-prefetch.c (struct mem_ref_group, struct mem_ref):
24856         New "uid" fields to hold pretty-print IDs of group and ref.
24857         Memory references are now identified as <group_id>:<ref_id>
24858         instead of using [random] addresses.
24859         (dump_mem_details): Simplify, no functional change.
24860         (dump_mem_ref): Simplify and make output more concise.
24861         Replace couple of fprintf's throughout code with calls to dump_mem_ref.
24862         (find_or_create_group): Initialize group uid.
24863         (record_ref): Initialize ref uid.  Improve debug output.
24864         (prune_group_by_reuse, should_issue_prefetch_p,)
24865         (should_issue_prefetch_p, schedule_prefetches, issue_prefetch_ref,)
24866         (mark_nontemporal_store, determine_loop_nest_reuse):
24867         Improve debug output.
24869 2017-06-06  Maxim Kuvyrkov  <maxim.kuvyrkov@linaro.org>
24871         * dbgcnt.def (prefetch): New debug counter.
24872         * tree-ssa-loop-prefetch.c (dbgcnt.h): New include.
24873         (schedule_prefetches): Stop issueing prefetches if debug counter
24874         tripped.
24876 2017-06-06  Tom de Vries  <tom@codesourcery.com>
24878         * doc/sourcebuild.texi (Testsuites, C Language Testsuites,
24879         gcc.c-torture/compile): Remove mention of NO_LABEL_VALUES in fixme.
24881 2017-06-06  Kyrylo Tkachov  <kyrylo.tkachov@arm.com>
24883         * config/aarch64/atomics.md (atomic_compare_and_swap<mode> expander):
24884         Use aarch64_reg_or_zero predicate for operand 4.
24885         (aarch64_compare_and_swap<mode> define_insn_and_split):
24886         Use aarch64_reg_or_zero predicate for operand 3.  Add 'Z' constraint.
24887         (aarch64_store_exclusive<mode>): Likewise for operand 2.
24889 2017-06-06  Thomas Preud'homme  <thomas.preudhomme@arm.com>
24891         * config/arm/arm.c (arm_compute_save_reg_mask): Rename into ...
24892         (arm_compute_save_core_reg_mask): This.
24893         (thumb1_compute_save_reg_mask): Rename into ...
24894         (thumb1_compute_save_core_reg_mask): This.
24895         (arm_compute_save_reg0_reg12_mask): Adapt comment.
24896         (arm_compute_frame_layout): Likewise.
24898 2017-06-06  Richard Biener  <rguenther@suse.de>
24900         PR tree-optimization/80974
24901         * tree-ssa-sccvn.c (set_ssa_val_to): Do not change but only
24902         keep or clear leaders SSA info.
24904 2017-06-06  Tom de Vries  <tom@codesourcery.com>
24906         * config/nvptx/nvptx.c (split_mode_p): New function.
24907         (nvptx_declare_function_name, nvptx_print_operand): Use split_mode_p.
24909 2017-06-06  Tom de Vries  <tom@codesourcery.com>
24911         * config/nvptx/nvptx.c (nvptx_print_operand): Use maybe_split_mode.
24913 2017-06-06  Jan Hubicka  <hubicka@ucw.cz>
24915         PR bootstrap/80978
24916         * tree-cfg.c (execute_fixup_cfg): Fix condition on when to rescale
24917         profile.
24919 2017-06-06  Jan Hubicka  <hubicka@ucw.cz>
24921         * shrink-wrap.c (handle_simple_exit): Update profile.
24922         (try_shrink_wrapping): Upate profile.
24924 2017-06-06  Jan Hubicka  <hubicka@ucw.cz>
24926         * predict.c (tree_estimate_probability_bb): Add LOCAL_ONLY.
24927         (tree_guess_outgoing_edge_probabilities): New.
24928         * predict.h (tree_guess_outgoing_edge_probabilities): Declare.
24929         * tree-cfg.c (gimple_find_sub_bbs): Propagate profile.
24931 2017-06-06  Jan Hubicka  <hubicka@ucw.cz>
24933         * ipa-split.c (split_function): Initialize return bb profile.
24935 2017-06-06  Jan Hubicka  <hubicka@ucw.cz>
24937         * profile.c (compute_branch_probabilities): Also initialize
24938         EXIT_BLOCK profile.
24940 2017-06-06  Richard Biener  <rguenther@suse.de>
24942         PR tree-optimization/80928
24943         * tree-vect-loop.c (vect_update_vf_for_slp): Amend dumps.
24944         (vect_analyze_loop_operations): Properly guard analysis for
24945         pure SLP case.
24946         (vect_transform_loop): Likewise.
24947         (vect_analyze_loop_2): Also reset SLP type on PHIs.
24948         (vect_model_induction_cost): Do not cost for pure SLP.
24949         (vectorizable_induction): Pass in SLP node, implement SLP vectorization
24950         of induction in inner loop vectorization.
24951         * tree-vect-slp.c (vect_create_new_slp_node): Handle PHIs.
24952         (vect_get_and_check_slp_defs): Handle vect_induction_def.
24953         (vect_build_slp_tree): Likewise.  Handle PHIs as terminating the
24954         recursion.
24955         (vect_analyze_slp_cost_1): Cost induction.
24956         (vect_detect_hybrid_slp_stmts): Handle PHIs.
24957         (vect_get_slp_vect_defs): Likewise.
24958         * tree-vect-stmts.c (vect_analyze_stmt): Handle induction.
24959         (vect_transform_stmt): Handle SLP reductions.
24960         * tree-vectorizer.h (vectorizable_induction): Adjust.
24962 2017-06-05  Michael Meissner  <meissner@linux.vnet.ibm.com>
24964         * config/rs6000/rs6000.c (make_resolver_func): Update
24965         init_lowered_empty_function call.
24967 2017-06-05  Bernd Edlinger  <bernd.edlinger@hotmail.de>
24969         * doc/invoke.texi: Document the -fprofile-abs-path option.
24970         * common.opt (fprofile-abs-path): New option.
24971         * gcov-io.h (gcov_write_filename): Declare.
24972         * gcov-io.c (gcov_write_filename): New function.
24973         * coverage.c (coverage_begin_function): Use gcov_write_filename.
24974         * profile.c (output_location): Likewise.
24976 2017-06-05  Jan Hubicka  <hubicka@ucw.cz>
24978         * shring-wrap.c: Revert accidental commit.
24980 2017-06-05  Volker Reichelt  <v.reichelt@netcologne.de>
24982         * doc/invoke.texi (-Wduplicated-branches): Add to warning list.
24984 2017-06-05  Jan Hubicka  <hubicka@ucw.cz>
24986         * cfgexpand.c (expand_gimple_tailcall): Initialize profile of
24987         new edge.
24988         * ipa-inline.c (want_inline_self_recursive_call_p): Watch for missing
24989         profile in callgraph edge.
24990         * profile-count.h (apply_probability): If THIS is 0, then result is 0
24991         (apply_scale): Likewise.
24992         * tree-inline.c (copy_bb, copy_edges_for_bb, copy_cfg_body):
24993         Also scale profile when inlining function with zero profile.
24994         (initialize_cfun): Update exit block profile even when it is zero.
24995         * tree-ssa-threadupdate.c (clear_counts_path): Handle correctly case
24996         when profile is read.
24998 2017-06-05  Michael Meissner  <meissner@linux.vnet.ibm.com>
25000         * config/rs6000/rs6000.c (toplevel): Include attribs.h.
25001         (CLONE_*): New constants to define the processors we can generate
25002         code for with the target_clone attribute.
25003         (rs6000_clone_map): New array to identify which clone processors
25004         the current program is running on.
25005         (TARGET_COMPARE_VERSION_PRIORITY): Define to enable the
25006         target_clone attribute.
25007         (TARGET_GENERATE_VERSION_DISPATCHER_BODY): Likewise.
25008         (TARGET_GET_FUNCTION_VERSIONS_DISPATCHER): Likewise.
25009         (TARGET_OPTION_FUNCTION_VERSIONS): Likewise.
25010         (cpu_expand_builtin): Add support for target_clone attribute.
25011         (rs6000_valid_attribute_p): Allow "default" attribute.
25012         (get_decl_name): New debug function to simplify printing the
25013         current function name in debugging statements.
25014         (rs6000_clone_priority): New functions to support the target_clone
25015         attribute, and be able to generate code to switch between ISA 2.05
25016         through ISA 3.0 (power6 through power9).
25017         (rs6000_compare_version_priority): Likewise.
25018         (rs6000_get_function_versions_dispatcher): Likewise.
25019         (make_resolver_func): Likewise.
25020         (add_condition_to_bb): Likewise.
25021         (dispatch_function_versions): Likewise.
25022         (rs6000_generate_version_dispatcher_body): Likewise.
25023         (rs6000_can_inline_p): Call get_decl_name for debugging usage.
25024         (fusion_gpr_load_p): Fix a spacing issue.
25025         * doc/extend.texi (Common Function Attributes): Document that the
25026         PowerPC supports the target_clone attribute.
25028 2017-06-05  Thomas Preud'homme  <thomas.preudhomme@arm.com>
25030         * config/arm/arm.h: explain F symbol found in description of ARM
25031         register allocation in its legend.
25033 2017-06-05  Jan Hubicka  <hubicka@ucw.cz>
25035         * config/mips/frame-header-opt.c: Include profile-count.h.
25036         * config/riscv/riscv.c: Include profile-count.h
25038 2017-06-05  Jan Hubicka  <hubicka@ucw.cz>
25040         * tree-ssa-loop-im.c (execute_sm_if_changed): Add FLAG_BBS parameter;
25041         update profile.
25042         (sm_set_flag_if_changed): Add bbs field.
25043         (execute_sm_if_changed_flag_set): Pass BBS.
25044         (execute_sm): Update.
25046 2017-06-05  Kyrylo Tkachov  <kyrylo.tkachov@arm.com>
25048         * config/aarch64/aarch64-simd.md (aarch64_store_lane0<mode>):
25049         New pattern.
25051 2017-06-05  Kyrylo Tkachov  <kyrylo.tkachov@arm.com>
25053         * config/aarch64/aarch64.md (sub<mode>3_compare1_imm): New define_insn.
25054         (peephole2): New peephole2 to emit the above.
25055         * config/aarch64/predicates.md (aarch64_sub_immediate): New predicate.
25057 2017-06-05  Kyrylo Tkachov  <kyrylo.tkachov@arm.com>
25059         * config/aarch64/aarch64.c (define_peephole2 above
25060         *sub_<shift>_<mode>): New peephole.
25062 2017-05-23  Jan Hubicka  <hubicka@ucw.cz>
25064         * config/i386/i386.c (make_resolver_func): Update.
25065         * Makefile.in: Add profile-count.h and profile-count.o
25066         * auto-profile.c (afdo_indirect_call): Update to new API.
25067         (afdo_set_bb_count): Update.
25068         (afdo_propagate_edge): Update.
25069         (afdo_propagate_circuit): Update.
25070         (afdo_calculate_branch_prob): Update.
25071         (afdo_annotate_cfg): Update.
25072         * basic-block.h: Include profile-count.h
25073         (struct edge_def): Turn count to profile_count.
25074         (struct basic_block_def): Likewie.
25075         (REG_BR_PROB_BASE): Move to profile-count.h
25076         (RDIV): Move to profile-count.h
25077         * bb-reorder.c (max_entry_count): Turn to profile_count.
25078         (find_traces): Update.
25079         (rotate_loop):Update.
25080         (connect_traces):Update.
25081         (sanitize_hot_paths):Update.
25082         * bt-load.c (migrate_btr_defs): Update.
25083         * cfg.c (RDIV): Remove.
25084         (init_flow): Use alloc_block.
25085         (alloc_block): Uninitialize count.
25086         (unchecked_make_edge): Uninitialize count.
25087         (check_bb_profile): Update.
25088         (dump_edge_info): Update.
25089         (dump_bb_info): Update.
25090         (update_bb_profile_for_threading): Update.
25091         (scale_bbs_frequencies_int): Update.
25092         (scale_bbs_frequencies_gcov_type): Update.
25093         (scale_bbs_frequencies_profile_count): New.
25094         * cfg.h (update_bb_profile_for_threading): Update.
25095         (scale_bbs_frequencies_profile_count): Declare.
25096         * cfgbuild.c (compute_outgoing_frequencies): Update.
25097         (find_many_sub_basic_blocks): Update.
25098         * cfgcleanup.c (try_forward_edges): Update.
25099         (try_crossjump_to_edge): Update.
25100         * cfgexpand.c (expand_gimple_tailcall): Update.
25101         (construct_exit_block): Update.
25102         * cfghooks.c (verify_flow_info): Update.
25103         (dump_bb_for_graph): Update.
25104         (split_edge): Update.
25105         (make_forwarder_block): Update.
25106         (duplicate_block): Update.
25107         (account_profile_record): Update.
25108         * cfgloop.c (find_subloop_latch_edge_by_profile): Update.
25109         (get_estimated_loop_iterations): Update.
25110         * cfgloopanal.c (expected_loop_iterations_unbounded): Update.
25111         (single_likely_exit): Update.
25112         * cfgloopmanip.c (scale_loop_profile): Update.
25113         (loopify): Update.
25114         (set_zero_probability): Update.
25115         (lv_adjust_loop_entry_edge): Update.
25116         * cfgrtl.c (force_nonfallthru_and_redirect): Update.
25117         (purge_dead_edges): Update.
25118         (rtl_account_profile_record): Update.
25119         * cgraph.c (cgraph_node::create): Uninitialize count.
25120         (symbol_table::create_edge): Uninitialize count.
25121         (cgraph_update_edges_for_call_stmt_node): Update.
25122         (cgraph_edge::dump_edge_flags): Update.
25123         (cgraph_node::dump): Update.
25124         (cgraph_edge::maybe_hot_p): Update.
25125         * cgraph.h: Include profile-count.h
25126         (create_clone), create_edge, create_indirect_edge): Update.
25127         (cgraph_node): Turn count to profile_count.
25128         (cgraph_edge0: Likewise.
25129         (make_speculative, clone): Update.
25130         (create_edge): Update.
25131         (init_lowered_empty_function): Update.
25132         * cgraphclones.c (cgraph_edge::clone): Update.
25133         (duplicate_thunk_for_node): Update.
25134         (cgraph_node::create_clone): Update.
25135         * cgraphunit.c (cgraph_node::analyze): Update.
25136         (cgraph_node::expand_thunk): Update.
25137         * final.c (dump_basic_block_info): Update.
25138         * gimple-streamer-in.c (input_bb): Update.
25139         * gimple-streamer-out.c (output_bb): Update.
25140         * graphite.c (print_global_statistics): Update.
25141         (print_graphite_scop_statistics): Update.
25142         * hsa-brig.c: Include basic-block.h.
25143         * hsa-dump.c: Include basic-block.h.
25144         * hsa-gen.c (T sum_slice): Update.
25145         (convert_switch_statements):Update.
25146         * hsa-regalloc.c: Include basic-block.h.
25147         * ipa-chkp.c (chkp_produce_thunks): Update.
25148         * ipa-cp.c (struct caller_statistics): Update.
25149         (init_caller_stats): Update.
25150         (gather_caller_stats): Update.
25151         (ipcp_cloning_candidate_p): Update.
25152         (good_cloning_opportunity_p): Update.
25153         (get_info_about_necessary_edges): Update.
25154         (dump_profile_updates): Update.
25155         (update_profiling_info): Update.
25156         (update_specialized_profile): Update.
25157         (perhaps_add_new_callers): Update.
25158         (decide_about_value): Update.
25159         (ipa_cp_c_finalize): Update.
25160         * ipa-devirt.c (struct odr_type_warn_count): Update.
25161         (struct decl_warn_count): Update.
25162         (struct final_warning_record): Update.
25163         (possible_polymorphic_call_targets): Update.
25164         (ipa_devirt): Update.
25165         * ipa-fnsummary.c (redirect_to_unreachable): Update.
25166         * ipa-icf.c (sem_function::merge): Update.
25167         * ipa-inline-analysis.c (do_estimate_edge_time): Update.
25168         * ipa-inline.c (compute_uninlined_call_time): Update.
25169         (compute_inlined_call_time): Update.
25170         (want_inline_small_function_p): Update.
25171         (want_inline_self_recursive_call_p): Update.
25172         (edge_badness): Update.
25173         (lookup_recursive_calls): Update.
25174         (recursive_inlining): Update.
25175         (inline_small_functions): Update.
25176         (dump_overall_stats): Update.
25177         (dump_inline_stats): Update.
25178         * ipa-profile.c (ipa_profile_generate_summary): Update.
25179         (ipa_propagate_frequency): Update.
25180         (ipa_profile): Update.
25181         * ipa-prop.c (ipa_make_edge_direct_to_target): Update.
25182         * ipa-utils.c (ipa_merge_profiles): Update.
25183         * loop-doloop.c (doloop_modify): Update.
25184         * loop-unroll.c (report_unroll): Update.
25185         (unroll_loop_runtime_iterations): Update.
25186         * lto-cgraph.c (lto_output_edge): Update.
25187         (lto_output_node): Update.
25188         (input_node): Update.
25189         (input_edge): Update.
25190         (merge_profile_summaries): Update.
25191         * lto-streamer-in.c (input_cfg): Update.
25192         * lto-streamer-out.c (output_cfg): Update.
25193         * mcf.c (create_fixup_graph): Update.
25194         (adjust_cfg_counts): Update.
25195         (sum_edge_counts): Update.
25196         * modulo-sched.c (sms_schedule): Update.
25197         * postreload-gcse.c (eliminate_partially_redundant_load): Update.
25198         * predict.c (maybe_hot_count_p): Update.
25199         (probably_never_executed): Update.
25200         (dump_prediction): Update.
25201         (combine_predictions_for_bb): Update.
25202         (propagate_freq): Update.
25203         (handle_missing_profiles): Update.
25204         (counts_to_freqs): Update.
25205         (rebuild_frequencies): Update.
25206         (force_edge_cold): Update.
25207         * predict.h: Include profile-count.h
25208         (maybe_hot_count_p, counts_to_freqs): UPdate.
25209         * print-rtl-function.c: Do not include cfg.h
25210         * print-rtl.c: Include basic-block.h
25211         * profile-count.c: New file.
25212         * profile-count.h: New file.
25213         * profile.c (is_edge_inconsistent): Update.
25214         (correct_negative_edge_counts): Update.
25215         (is_inconsistent): Update.
25216         (set_bb_counts): Update.
25217         (read_profile_edge_counts): Update.
25218         (compute_frequency_overlap): Update.
25219         (compute_branch_probabilities): Update; Initialize and deinitialize
25220         gcov_count tables.
25221         (branch_prob): Update.
25222         * profile.h (bb_gcov_counts, edge_gcov_counts): New.
25223         (edge_gcov_count): New.
25224         (bb_gcov_count): New.
25225         * shrink-wrap.c (try_shrink_wrapping): Update.
25226         * tracer.c (better_p): Update.
25227         * trans-mem.c (expand_transaction): Update.
25228         (ipa_tm_insert_irr_call): Update.
25229         (ipa_tm_insert_gettmclone_call): Update.
25230         * tree-call-cdce.c: Update.
25231         * tree-cfg.c (gimple_duplicate_sese_region): Update.
25232         (gimple_duplicate_sese_tail): Update.
25233         (gimple_account_profile_record): Update.
25234         (execute_fixup_cfg): Update.
25235         * tree-inline.c (copy_bb): Update.
25236         (copy_edges_for_bb): Update.
25237         (initialize_cfun): Update.
25238         (freqs_to_counts): Update.
25239         (copy_cfg_body): Update.
25240         (expand_call_inline): Update.
25241         * tree-ssa-ifcombine.c (update_profile_after_ifcombine): Update.
25242         * tree-ssa-loop-ivcanon.c (unloop_loops): Update.
25243         (try_unroll_loop_completely): Update.
25244         (try_peel_loop): Update.
25245         * tree-ssa-loop-manip.c (tree_transform_and_unroll_loop): Update.
25246         * tree-ssa-loop-niter.c (estimate_numbers_of_iterations_loop): Update.
25247         * tree-ssa-loop-split.c (connect_loops): Update.
25248         * tree-ssa-loop-unswitch.c (hoist_guard): Update.
25249         * tree-ssa-reassoc.c (branch_fixup): Update.
25250         * tree-ssa-tail-merge.c (replace_block_by): Update.
25251         * tree-ssa-threadupdate.c (create_block_for_threading): Update.
25252         (compute_path_counts): Update.
25253         (update_profile): Update.
25254         (recompute_probabilities): Update.
25255         (update_joiner_offpath_counts): Update.
25256         (estimated_freqs_path): Update.
25257         (freqs_to_counts_path): Update.
25258         (clear_counts_path): Update.
25259         (ssa_fix_duplicate_block_edges): Update.
25260         (duplicate_thread_path): Update.
25261         * tree-switch-conversion.c (case_bit_test_cmp): Update.
25262         (struct switch_conv_info): Update.
25263         * tree-tailcall.c (decrease_profile): Update.
25264         * tree-vect-loop-manip.c (slpeel_add_loop_guard): Update.
25265         * tree-vect-loop.c (scale_profile_for_vect_loop): Update.
25266         * value-prof.c (check_counter): Update.
25267         (gimple_divmod_fixed_value): Update.
25268         (gimple_mod_pow2): Update.
25269         (gimple_mod_subtract): Update.
25270         (gimple_ic_transform): Update.
25271         (gimple_stringop_fixed_value): Update.
25272         * value-prof.h (gimple_ic): Update.
25274 2017-06-02  Carl Love  <cel@us.ibm.com>
25276         * config/rs6000/rs6000-c: Add support for built-in functions
25277         vector double vec_doublee (vector signed int);
25278         vector double vec_doublee (vector unsigned int);
25279         vector double vec_doublee (vector float);
25280         vector double vec_doubleh (vector signed int);
25281         vector double vec_doubleh (vector unsigned int);
25282         vector double vec_doubleh (vector float);
25283         vector double vec_doublel (vector signed int);
25284         vector double vec_doublel (vector unsigned int);
25285         vector double vec_doublel (vector float);
25286         vector double vec_doubleo (vector signed int);
25287         vector double vec_doubleo (vector unsigned int);
25288         vector double vec_doubleo (vector float);.
25289         * config/rs6000/rs6000-builtin.def: Add definitions for DOUBLEE,
25290         DOUBLEO, DOUBLEH, DOUBLEL, UNS_DOUBLEO, UNS_DOUBLEE, UNS_DOUBLEH,
25291         UNS_DOUBLEL.
25292         * config/rs6000/altivec.md: Add code generator for doublee<mode>2,
25293         unsdoubleev4si2, doubleo<mode>2, unsdoubleov4si2, doubleh<mode>2,
25294         unsdoublehv4si2, doublel<mode>2, unsdoublelv4si2, add mode attribute
25295         VS_sxwsp.
25296         * config/rs6000/altivec.h: Add define for vec_doublee, vec_doubleo,
25297         vec_doublel, vec_doubleh.
25298         * doc/extend.texi: Update the built-in documentation file for the
25299         new built-in functions.
25301 2017-06-02  David Malcolm  <dmalcolm@redhat.com>
25303         PR jit/80954
25304         * ipa-inline-analysis.c (free_growth_caches): Set
25305         edge_removal_hook_holder to NULL after removing it.
25307 2017-06-02  Sudakshina Das  <sudi.das@arm.com>
25309         * config/aarch64/aarch64.c (aarch64_select_cc_mode): Return CC_SWP for
25310         comparision with zero.
25312 2017-06-02  Will Schmidt  <will_schmidt@vnet.ibm.com>
25313         * config/rs6000/rs6000.c (rs6000_gimple_fold_builtin): Add handling
25314         for early expansion of vec_min and vec_max builtins.
25315         (builtin_function_type): Add min/max unsigned variants to those
25316         identified as having unsigned arguments.
25318 2017-06-02  Olivier Hainque  <hainque@adacore.com>
25320         * config/vx-common.h (DWARF_UNWIND_INFO): Switch #define to 1.
25322 2017-06-02  Kyrylo Tkachov  <kyrylo.tkachov@arm.com>
25324         * config/aarch64/aarch64-simd.md (*aarch64_simd_vec_copy_lane<mode>):
25325         Use VALL_F16 iterator rather than VALL.
25327 2017-06-02  Kyrylo Tkachov  <kyrylo.tkachov@arm.com>
25329         * config/aarch64/aarch64.c (aarch64_split_compare_and_swap):
25330         Emit CBNZ inside loop when doing a strong exchange and comparing
25331         against zero.  Generate the CC flags after the loop.
25333 2017-06-02  David Edelsohn  <dje.gcc@gmail.com>
25335         * dwarf2out.c (DWARF_INITIAL_LENGTH_SIZE_STR): New.
25336         (dl_section_ref): New.
25337         (dwarf2out_finish): Copy debug_line_section_label to dl_section_ref.
25338         On AIX, append an expression to subtract the size of the
25339         section length to dl_section_ref.
25341 2017-06-02  Will Schmidt  <will_schmidt@vnet.ibm.com>
25343         * config/rs6000/rs6000.c (rs6000_gimple_fold_builtin): Add handling
25344         for early expansion of vector absolute builtins.
25346 2017-06-02  Richard Biener  <rguenther@suse.de>
25348         * tree-vect-slp.c (vect_detect_hybrid_slp_2): Match up
25349         what we consider a relevant use stmt with vect_detect_hybrid_slp_stmts.
25351 2017-06-02  Richard Biener  <rguenther@suse.de>
25353         PR tree-optimization/80948
25354         * tree-tailcall.c (find_tail_calls): Track stmts to move in
25355         stmt order as well.
25357 2017-06-02  Richard Biener  <rguenther@suse.de>
25359         * tree-vect-loop.c (vect_analyze_loop_operations): Not relevant
25360         PHIs are ok.
25361         * tree-vect-stmts.c (process_use): Do not mark backedge defs
25362         for inductions as relevant.
25364 2017-06-02  Richard Biener  <rguenther@suse.de>
25366         * tree-vect-loop.c (get_initial_def_for_induction): Inline into ...
25367         (vectorizable_induction): ... this.  Remove dead code.
25369 2017-06-02  Eric Botcazou  <ebotcazou@adacore.com>
25371         * builtins. (expand_builtin_alloca): Remove second parameter and
25372         infer its value from the first parameter instead.
25373         (expand_builtin) <BUILT_IN_ALLOCA>: Adjust call to above.
25375 2017-06-02  Jakub Jelinek  <jakub@redhat.com>
25377         PR rtl-optimization/80903
25378         * loop-doloop.c (add_test): Unshare sequence.
25380 2017-06-02  Bernd Edlinger  <bernd.edlinger@hotmail.de>
25382         * doc/invoke.texi: Document the -Wsizeof-pointer-div warning.
25384 2017-06-01  Bernd Edlinger  <bernd.edlinger@hotmail.de>
25386         * config/i386/i386.c (x86_64_ms_sysv_extra_clobbered_registers): Make
25387         static.
25388         (xlogue_layout::get_stack_space_used, xlogue_layout::s_instances,
25389         xlogue_layout::get_instance, logue_layout::xlogue_layout,
25390         sp_valid_at, fp_valid_at, choose_basereg): Formatting.
25391         (xlogue_layout::get_stub_rtx): Make static.
25392         (xlogue_layout::get_stub_name): Avoid const-cast, make static.
25393         (xlogue_layout::compute_stub_managed_regs): Rename to...
25394         (xlogue_layout::count_stub_managed_regs): ...this.
25395         (xlogue_layout::is_stub_managed_reg): New function.
25396         (xlogue_layout::m_stub_names): Rename to...
25397         (xlogue_layout::s_stub_names): ...this, make static.
25398         (xlogue_layout::STUB_INDEX_OFFSET, xlogue_layout::MIN_REGS,
25399         xlogue_layout::MAX_REGS, xlogue_layout::MAX_EXTRA_REGS,
25400         xlogue_layout::VARIANT_COUNT, xlogue_layout::STUB_NAME_MAX_LEN,
25401         xlogue_layout::s_stub_names): Instantiate statics.
25402         (stub_managed_regs): Remove.
25403         (ix86_save_reg): Use xlogue_layout::compute_stub_managed_regs.
25404         (disable_call_ms2sysv_xlogues): Rename to...
25405         (warn_once_call_ms2sysv_xlogues): ...this, and warn only once.
25406         (ix86_initial_elimination_offset, ix86_expand_call): Fix call_ms2sysv
25407         warning logic.
25408         (ix86_static_chain): Make sure that ix86_static_chain_on_stack can't
25409         change after reload_completed.
25410         (ix86_can_use_return_insn_p): Use the ix86_frame data structure
25411         directly.
25412         (ix86_expand_prologue): Likewise.
25413         (ix86_expand_epilogue): Likewise.
25414         (ix86_expand_split_stack_prologue): Likewise.
25415         (ix86_compute_frame_layout): Remove frame parameter ...
25416         (TARGET_COMPUTE_FRAME_LAYOUT): ... and export it as a target hook.
25417         (ix86_finalize_stack_realign_flags): Call ix86_compute_frame_layout
25418         only if necessary.
25419         (ix86_init_machine_status): Don't set use_fast_prologue_epilogue_nregs.
25420         (ix86_frame): Move from here ...
25421         * config/i386/i386.h (ix86_frame): ... to here.
25422         (machine_function): Remove use_fast_prologue_epilogue_nregs, cache the
25423         complete ix86_frame data structure instead.  Remove some_ld_name.
25425 2017-06-01  Pierre-Marie de Rodat  <derodat@adacore.com>
25427         * dwarf2out.c (dwarf2out_late_global_decl): Add locations for
25428         symbols that hold a DECL_VALUE_EXPR.
25430 2017-06-01  Martin Jambor  <mjambor@suse.cz>
25432         PR tree-optimization/80898
25433         * tree-sra.c (process_subtree_disqualification): Removed.
25434         (disqualify_candidate): Do not acll
25435         process_subtree_disqualification.
25436         (subtree_mark_written_and_enqueue): New function.
25437         (propagate_all_subaccesses): Set grp_write of LHS subtree if the
25438         RHS has been disqualified and re-queue LHS if necessary.  Apart
25439         from that, ignore disqualified RHS.
25441 2017-06-01  Andreas Krebbel  <krebbel@linux.vnet.ibm.com>
25443         * config/s390/s390.c (s390_emit_epilogue): Disable early return
25444         address fetch for z10 or later.
25446 2017-06-01  Claudiu Zissulescu  <claziss@synopsys.com>
25448         * config/arc/arc.md (tst_movb): Add guard when splitting.
25450 2017-06-01  Claudiu Zissulescu  <claziss@synopsys.com>
25452         * config/arc/arc.c (arc_can_eliminate): Test against
25453         arc_frame_pointer_needed.
25455 2017-06-01  Claudiu Zissulescu  <claziss@synopsys.com>
25457         * config/arc/arc.c (arc_expand_prologue): Emit a special barrier
25458         to prevent store reordering.
25459         * config/arc/arc.md (UNSPEC_ARC_STKTIE): Define.
25460         (type): Add block type.
25461         (stack_tie): Define special instruction to be used in
25462         expand_prologue.
25464 2017-06-01  Claudiu Zissulescu  <claziss@synopsys.com>
25466         * config/arc/arc.md (commutative_binary_comparison): Remove 'I'
25467         constraint. It is not valid for the pattern.
25468         (noncommutative_binary_comparison): Likewise.
25470 2017-06-01  Claudiu Zissulescu  <claziss@synopsys.com>
25472         * config/arc/simdext.md (movv2hi_insn): Change predicate to avoid
25473         scaled addresses.
25475 2017-06-01  Claudiu Zissulescu  <claziss@synopsys.com>
25477         * config/arc/arc.c (arc_conditional_register_usage): Allow r30 to
25478         be used by the reg-alloc.
25480 2017-06-01  Claudiu Zissulescu  <claziss@synopsys.com>
25482         * config/arc/arc.md (mulsi3): Avoid use of hard registers before
25483         reg-alloc when having mul64 or mul32x16 instructions.
25484         (mulsidi3): Likewise.
25485         (umulsidi3): Likewise.
25486         (mulsi32x16): New pattern.
25487         (mulsi64): Likewise.
25488         (mulsidi64): Likewise.
25489         (umulsidi64): Likewise.
25490         (MUL32x16_REG): Define.
25491         (mul64_600): Use MUL32x16_REG.
25492         (mac64_600): Likewise.
25493         (umul64_600): Likewise.
25494         (umac64_600): Likewise.
25496 2017-06-01  Claudiu Zissulescu  <claziss@synopsys.com>
25498         * config/arc/arc.md (mulsi3_700): Make it commutative.
25500 2017-06-01  Jose E. Marchesi  <jose.marchesi@oracle.com>
25502         * config/sparc/sparc.md (*zero_extendsidi2_insn_sp64): Set insn
25503         type for movstouw.
25504         (*sign_extendsidi2_insn): Likewise for movstosw.
25506 2017-06-01  Pierre-Marie de Rodat  <derodat@adacore.com>
25508         * dwarf2out.c (get_discr_value): Call the get_debug_type hook on
25509         the type of the input discriminant value.  Convert the
25510         discriminant value of signedness vary.
25512 2017-06-01  Volker Reichelt  <v.reichelt@netcologne.de>
25514         * doc/invoke.texi (-Wcatch-value): Document new shortcut.
25515         Add to -Wall section.
25517 2017-06-01  Richard Biener  <rguenther@suse.de>
25519         PR middle-end/66313
25520         * fold-const.c (fold_plusminus_mult_expr): If the factored
25521         factor may be zero use a wrapping type for the inner operation.
25522         * tree-tailcall.c (independent_of_stmt_p): Pass in to_move bitmap
25523         and handle moved defs.
25524         (process_assignment): Properly guard the unary op case.  Return a
25525         tri-state indicating that moving the stmt before the call may allow
25526         to continue.  Pass through to_move.
25527         (find_tail_calls): Handle moving unrelated defs before
25528         the call.
25530 2017-05-31  Segher Boessenkool  <segher@kernel.crashing.org>
25532         PR target/80618
25533         * config/rs6000/vector.md (*vector_uneq<mode>): Write the nor in the
25534         splitter result in the canonical way.
25536 2017-05-31  Uros Bizjak  <ubizjak@gmail.com>
25538         * config/i386/i386.md (*zero_extendsidi2): Enable alternative (?r, *Yj)
25539         also for 32bit target.  Update insn attributes.
25540         (zero-extendsidi2 splitter): Allow all registers for operand 1.
25542 2017-05-31  Sebastian Peryt  <sebastian.peryt@intel.com>
25544         * config/i386/avx512fintrin.h (_mm_mask_max_sd)
25545         (_mm_maskz_max_sd, _mm_mask_max_ss, _mm_maskz_max_ss)
25546         (_mm_mask_min_sd, _mm_maskz_min_sd, _mm_mask_min_ss)
25547         (_mm_maskz_min_ss): New intrinsics.
25549 2017-05-31  Martin Liska  <mliska@suse.cz>
25551         * tree-vect-loop.c (vect_create_epilog_for_reduction):
25552         Change comment style to one we normally use.
25553         (vectorizable_reduction): Likewise.
25554         (vectorizable_induction): Likewise.
25555         * tree-vect-stmts.c (vectorizable_mask_load_store): Likewise.
25556         (vectorizable_call): Likewise.
25557         (vectorizable_simd_clone_call): Likewise.
25558         (vectorizable_conversion): Likewise.
25559         (vectorizable_assignment): Likewise.
25560         (vectorizable_shift): Likewise.
25561         (vectorizable_operation): Likewise.
25562         (vectorizable_store): Likewise.
25563         (vectorizable_load): Likewise.
25564         * tree-vectorizer.h: Likewise.
25566 2017-05-31  Alexander Monakov  <amonakov@ispras.ru>
25568         * passes.c (emergency_dump_function): New.
25569         * tree-pass.h (emergency_dump_function): Declare.
25570         * plugin.c (plugins_internal_error_function): Remove.
25571         * plugin.h (plugins_internal_error_function): Remove declaration.
25572         * toplev.c (internal_error_function): New static function.  Use it...
25573         (general_init): ...here.
25575 2017-05-31  Graham Markall  <graham.markall@embecosm.com>
25577         * config/arc/arc.c (arc_print_operand): Handle constant operands.
25578         (arc_rtx_costs): Add costs for new patterns.
25579         * config/arc/arc.md: Additional *add_n and *sub_n patterns.
25580         * config/arc/predicates.md: Add _1_2_3_operand predicate.
25582 2017-05-31  Richard Sandiford  <richard.sandiford@linaro.org>
25584         * tree-ssa-strlen.c (get_next_strinfo): New function.
25585         (get_stridx_plus_constant): Use it.
25586         (zero_length_string): Likewise.
25587         (adjust_related_strinfos): Likewise.
25588         (adjust_last_stmt): Likewise.
25590 2017-05-31  Richard Biener  <rguenther@suse.de>
25592         PR target/80880
25593         * config/i386/i386.c (ix86_expand_builtin): Remove assert
25594         for arg being an SSA name when expanding IX86_BUILTIN_BNDRET.
25596 2017-05-31  Richard Sandiford  <richard.sandiford@linaro.org>
25598         * tree-vect-data-refs.c (vect_find_same_alignment_drs): Remove
25599         loop_vinfo argument and use of dependence distance vectors.
25600         Check instead whether the two references differ only in their
25601         initial value and assume that they have the same alignment if the
25602         difference is a multiple of the vector alignment.
25603         (vect_analyze_data_refs_alignment): Update call accordingly.
25605 2017-05-31  Martin Liska  <mliska@suse.cz>
25607         PR target/79155
25608         * config/i386/cpuid.h: Fix typo in a comment in cpuid.h.
25610 2017-05-31  Bin Cheng  <bin.cheng@arm.com>
25612         * tree-vect-loop-manip.c (create_intersect_range_checks_index)
25613         (create_intersect_range_checks): Move from ...
25614         * tree-data-ref.c (create_intersect_range_checks_index)
25615         (create_intersect_range_checks): ... to here.
25616         (create_runtime_alias_checks): New function factored from ...
25617         * tree-vect-loop-manip.c (vect_create_cond_for_alias_checks): ...
25618         here.  Call above function.
25619         * tree-data-ref.h (create_runtime_alias_checks): New function.
25621 2017-05-31  Bin Cheng  <bin.cheng@arm.com>
25623         * tree-data-ref.c (prune_runtime_alias_test_list): Relax minimal
25624         segment length for dr_b and compute it in wide_int.
25626 2017-05-31  Richard Biener  <rguenther@suse.de>
25628         PR tree-optimization/80906
25629         * graphite-isl-ast-to-gimple.c (copy_loop_close_phi_nodes): Get
25630         and pass through iv_map.
25631         (copy_bb_and_scalar_dependences): Adjust.
25632         (translate_pending_phi_nodes): Likewise.
25633         (copy_loop_close_phi_args): Handle code-generating IVs instead
25634         of ICEing.
25636 2017-05-30  David Malcolm  <dmalcolm@redhat.com>
25638         * diagnostic-color.c (color_dict): Add "type-diff".
25639         (parse_gcc_colors): Update comment.
25640         * doc/invoke.texi (Diagnostic Message Formatting Options): Add
25641         -fdiagnostics-show-template-tree and -fno-elide-type.
25642         (GCC_COLORS): Add type-diff to example.
25643         (type-diff=): New.
25644         (-fdiagnostics-show-template-tree): New.
25645         (-fno-elide-type): New.
25646         * pretty-print.c (pp_format): Pass quote and formatters[argno] to
25647         the pp_format_decoder callback.  Call any m_format_postprocessor's
25648         "handle" method.
25649         (pretty_printer::pretty_printer): Initialize
25650         m_format_postprocessor.
25651         (pretty_printer::~pretty_printer): Delete any
25652         m_format_postprocessor.
25653         * pretty-print.h (printer_fn): Add bool and const char ** parameters.
25654         (class format_postprocessor): New class.
25655         (struct pretty_printer::format_decoder): Document the new parameters.
25656         (struct pretty_printer::m_format_postprocessor): New field.
25657         * tree-diagnostic.c (default_tree_printer): Update for new
25658         bool and const char ** params.
25659         * tree-diagnostic.h (default_tree_printer): Likewise.
25661 2017-05-30  Segher Boessenkool  <segher@kernel.crashing.org>
25663         * config/rs6000/predicates.md (cc_reg_not_micro_cr0_operand): Delete.
25664         (lwa_operand): Delete rs6000_gen_cell_microcode test.
25665         * config/rs6000/rs6000.c (rs6000_option_override_internal): Delete
25666         rs6000_gen_cell_microcode code.
25667         (rs6000_final_prescan_insn): Delete.
25668         (rs6000_opt_vars): Delete the "gen-cell-microcode" and
25669         "warn-cell-microcode" entries.
25670         * config/rs6000/rs6000.h (FINAL_PRESCAN_INSN): Delete.
25671         * config/rs6000/rs6000.md: Delete rs6000_gen_cell_microcode tests
25672         throughout.  Change cc_reg_not_micro_cr0_operand to
25673         cc_reg_not_cr0_operand throughout.
25674         (*extendhi<mode>2_noload): Delete.
25675         * config/rs6000/rs6000.opt (mgen-cell-microcode): Replace by stub.
25676         (mwarn-cell-microcode): Delete.
25677         * doc/invoke.texi (RS/6000 and PowerPC Options): Delete
25678         -mgen-cell-microcode and -mwarn-cell-microcode.
25680 2017-05-30  Uros Bizjak  <ubizjak@gmail.com>
25682         PR target/80833
25683         * config/i386/constraints.md (Yd): New constraint.
25684         (Ye): Ditto.
25685         * config/i386/i386.md (*movti_internal): Add (?r, Ye)
25686         and (?Yd, r) alternatives.  Update insn attributes.
25687         * config/i386/i386.md (*movti_internal): Add (?r, *Ye)
25688         and (?*Yd, r) alternatives.  Update insn attributes.
25689         (double-mode inter-unit splitters): Add new GR<->XMM splitters.
25691 2017-05-30  Pierre-Marie de Rodat  <derodat@adacore.com>
25693         * gimplify.c (gimplify_modify_expr): Don't create a
25694         DECL_DEBUG_EXPR link if *FROM_P does not belong to the current
25695         function.
25697 2017-05-30  Wilco Dijkstra  <wdijkstr@arm.com>
25699         * config/arm/arm-builtins.c (arm_expand_builtin): Remove const.
25701 2017-05-30  Richard Biener  <rguenther@suse.de>
25703         * tree-vectorizer.h (struct _stmt_vec_info): Add reduc_type
25704         and reduc_def fields.
25705         (STMT_VINFO_REDUC_TYPE): New define.
25706         (STMT_VINFO_REDUC_DEF): Likewise.
25707         (vect_force_simple_reduction): Adjust prototype.
25708         * tree-vect-loop.c (vect_analyze_scalar_cycles_1): Adjust.
25709         (vect_is_simple_reduction): Remove check_reduction argument.
25710         (vect_force_simple_reduction): Adjust and set
25711         STMT_VINFO_REDUC_TYPE and STMT_VINFO_REDUC_DEF.
25712         (vectorizable_reduction): Do not re-do reduction analysis
25713         but use STMT_VINFO_REDUC_TYPE and STMT_VINFO_REDUC_DEF.
25714         * tree-parloops.c (gather_scalar_reductions): Adjust.
25716 2017-05-30  Richard Biener  <rguenther@suse.de>
25718         PR middle-end/80901
25719         * cfgexpand.c (expand_gimple_cond): Match up loop fixup with
25720         split_edge code.
25722 2017-05-24  Robin Dapp  <rdapp@linux.vnet.ibm.com>
25724         * tree-vect-data-refs.c (vect_get_peeling_costs_all_drs):
25725         Introduce unknown_misalignment parameter and remove vf.
25726         (vect_peeling_hash_get_lowest_cost):
25727         Pass unknown_misalignment parameter.
25728         (vect_enhance_data_refs_alignment):
25729         Fix unsupportable data ref treatment.
25731 2017-05-30  Robin Dapp  <rdapp@linux.vnet.ibm.com>
25733         * tree-vect-data-refs.c (vect_get_data_access_cost):
25734         Workaround for SLP handling.
25735         (vect_enhance_data_refs_alignment):
25736         Compute costs for doing no peeling at all, compare to the best
25737         peeling costs so far and avoid peeling if cheaper.
25739 2017-05-30  Robin Dapp  <rdapp@linux.vnet.ibm.com>
25741         * tree-vect-data-refs.c (vect_peeling_hash_choose_best_peeling):
25742         Return peeling info and set costs to zero for unlimited cost
25743         model.
25744         (vect_enhance_data_refs_alignment): Also inspect all datarefs
25745         with unknown misalignment. Compute and costs for unknown
25746         misalignment, compare them to the costs for known misalignment
25747         and choose the cheapest for peeling.
25749 2017-05-30  Robin Dapp  <rdapp@linux.vnet.ibm.com>
25751         * tree-vect-data-refs.c (vect_update_misalignment_for_peel): Rename.
25752         (vect_get_peeling_costs_all_drs): Create function.
25753         (vect_peeling_hash_get_lowest_cost):
25754         Use vect_get_peeling_costs_all_drs.
25755         (vect_peeling_supportable): Create function.
25756         (vect_enhance_data_refs_alignment): Use vect_peeling_supportable.
25758 2017-05-30  Robin Dapp  <rdapp@linux.vnet.ibm.com>
25760         * tree-vect-data-refs.c (vect_compute_data_ref_alignment): Create
25761         DR_HAS_NEGATIVE_STEP.
25762         (vect_update_misalignment_for_peel): Define DR_MISALIGNMENT.
25763         (vect_enhance_data_refs_alignment): Use.
25764         (vect_duplicate_ssa_name_ptr_info): Use.
25765         * tree-vectorizer.h (dr_misalignment): Use.
25766         (known_alignment_for_access_p): Use.
25768 2017-05-30  Jozef Lawrynowicz  <jozef.l@somniumtech.com>
25770         PR target/78838
25771         * config/msp430/msp430.c (gen_prefix): Return NULL when section name is
25772         .lowtext.
25773         (has_section_name): New function.
25775 2017-05-30  Martin Liska  <mliska@suse.cz>
25777         PR other/80909
25778         * auto-profile.c (get_function_decl_from_block): Fix
25779         parenthesis.
25781 2017-05-30  Richard Biener  <rguenther@suse.de>
25783         PR middle-end/80876
25784         * cfgexpand.c (expand_gimple_cond): Fixup preserving loops again.
25786 2017-05-30  Martin Liska  <mliska@suse.cz>
25788         * dumpfile.c: Use newly added macro DUMP_FILE_INFO.
25789         * dumpfile.h (struct dump_file_info): Remove ctors.
25791 2017-05-30  Martin Liska  <mliska@suse.cz>
25793         * predict.def: Fix GNU coding style.
25795 2017-05-29  Max Filippov  <jcmvbkbc@gmail.com>
25797         * config/xtensa/xtensa.c (xtensa_initial_elimination_offset):
25798         Mark 'to' argument with ATTRIBUTE_UNUSED.
25800 2017-05-29  Max Filippov  <jcmvbkbc@gmail.com>
25802         * config/xtensa/xtensa.c (xtensa_emit_call): Use
25803         HOST_WIDE_INT_PRINT_HEX instead of 0x%lx format string.
25804         (print_operand): Use HOST_WIDE_INT_PRINT_DEC instead of %ld
25805         format string.
25807 2017-05-29  Eric Botcazou  <ebotcazou@adacore.com>
25809         * doc/install.texi (Options specification): Restore entry of
25810         --enable-sjlj-exceptions.
25812 2017-05-27  Michael Eager  <eager@eagercon.com>
25814         Revert:
25815         2016-01-21  Ajit Agarwal  <ajitkum@xilinx.com>
25817         See https://gcc.gnu.org/ml/gcc/2017-05/msg00221.html.
25819         * config/microblaze/microblaze.h
25820         (FIXED_REGISTERS): Update in macro.
25821         (CALL_USED_REGISTERS): Update in macro.
25823 2017-05-27  François-Xavier Coudett  <fxcoudert@gcc.gnu.org>
25825         * doc/install.texi: Add links to macOS binary distributions.
25827 2017-05-27  Jakub Jelinek  <jakub@redhat.com>
25829         PR bootstrap/80887
25830         Revert:
25831         2017-05-25  Marc Glisse  <marc.glisse@inria.fr>
25833         * match.pd ((A +- CST1) +- CST2): Allow some conversions.
25835 2017-05-26  Martin Liska  <mliska@suse.cz>
25837         * dumpfile.h (enum dump_kind): Renumber TDF_* flags to be contiguous.
25839 2017-05-26  Martin Liska  <mliska@suse.cz>
25841         * cfg.c (check_bb_profile): Do not use TDF_COMMENT and print
25842         always leading ';; '.
25843         (dump_bb_info): Likewise.
25844         (brief_dump_cfg): Likewise.
25845         * cfgrtl.c (print_rtl_with_bb): Do not use TDF_COMMENT.
25846         * dumpfile.c: Remove usage of TDF_VERBOSE.
25847         * dumpfile.h (enum dump_kind): Likewise.
25848         (dump_gimple_bb_header): Do not use TDF_COMMENT.
25849         * print-tree.c (debug_verbose): Remove.
25850         * tree-cfg.c (gimple_dump_cfg): Do not use TDF_COMMENT.
25851         (dump_function_to_file): Remove dumps guarded with TDF_VERBOSE.
25852         * tree-diagnostic.c (default_tree_printer): Replace
25853         TDF_DIAGNOSTIC with TDF_SLIM.
25855 2017-05-26  Bin Cheng  <bin.cheng@arm.com>
25857         * tree-vect-loop-manip.c (create_intersect_range_checks_index): Pass
25858         in parameter loop, rather than loop_vinfo.
25859         (create_intersect_range_checks): Ditto.
25860         (vect_create_cond_for_alias_checks): Update call to above functions.
25862 2017-05-26  Bin Cheng  <bin.cheng@arm.com>
25864         PR tree-optimization/80815
25865         * tree-data-ref.c (prune_runtime_alias_test_list): Simplify condition
25866         for merging runtime alias checks.  Handle negative DR_STEPs.
25868 2017-05-26  Bin Cheng  <bin.cheng@arm.com>
25870         * tree-vect-data-refs.c (Operator==, comp_dr_with_seg_len_pair):
25871         Move from ...
25872         * tree-data-ref.c (Operator==, comp_dr_with_seg_len_pair): To here.
25873         * tree-vect-data-refs.c (vect_prune_runtime_alias_test_list): Factor
25874         out code pruning runtime alias checks.
25875         * tree-data-ref.c (prune_runtime_alias_test_list): New function
25876         factored out from above.
25877         * tree-vectorizer.h (struct dr_with_seg_len, dr_with_seg_len_pair_t):
25878         Move from ...
25879         * tree-data-ref.h (struct dr_with_seg_len, dr_with_seg_len_pair_t):
25880         ... to here.
25881         (prune_runtime_alias_test_list): New decalaration.
25883 2017-05-26  Bin Cheng  <bin.cheng@arm.com>
25885         * tree-vect-data-refs.c (compare_tree): Rename and move ...
25886         * tree-data-ref.c (data_ref_compare_tree): ... to here.
25887         * tree-data-ref.h (data_ref_compare_tree): New decalaration.
25888         * tree-vect-data-refs.c (dr_group_sort_cmp): Update uses.
25889         (operator==, comp_dr_with_seg_len_pair): Ditto.
25890         (vect_prune_runtime_alias_test_list): Ditto.
25892 2017-05-26  Martin Liska  <mliska@suse.cz>
25894         PR ipa/80663
25895         * params.def: Bound partial-inlining-entry-probability param.
25897 2017-05-26  Marek Polacek  <polacek@redhat.com>
25899         PR sanitizer/80875
25900         * fold-const.c (fold_binary_loc) <case MULT_EXPR>: Check if OP1
25901         can be negated.
25903 2017-05-26  Richard Biener  <rguenther@suse.de>
25905         PR tree-optimization/80842
25906         * tree-ssa-ccp.c (set_lattice_value): Always meet with the old
25907         value.
25909 2017-05-26  Richard Biener  <rguenther@suse.de>
25911         PR tree-optimization/80844
25912         * tree-vectorizer.c (adjust_simduid_builtins): Propagate results.
25914 2017-05-25  Sebastian Peryt  <sebastian.peryt@intel.com>
25916         * doc/md.texi (Machine Constraints): Update x86 family
25917         machine constraints section to match 'config/i386/constraints.md'.
25919 2017-05-25  Volker Reichelt  <v.reichelt@netcologne.de>
25921         * doc/invoke.texi (-Wcatch-value=): Document new warning option.
25923 2017-05-25  Nathan Sidwell  <nathan@acm.org>
25925         * doc/invoke.texi (--enable-languages): Update documentation.
25927 2017-05-25  Martin Liska  <mliska@suse.cz>
25929         * dumpfile.c: Add TDF_FOLDING.
25930         * dumpfile.h (enum dump_kind): Likewise.
25931         * genmatch.c (dt_simplify::gen_1): Use it.
25933 2017-05-25  Marc Glisse  <marc.glisse@inria.fr>
25935         * match.pd (view_convert (convert@0 @1)): Handle zero-extension.
25937 2017-05-25  Marc Glisse  <marc.glisse@inria.fr>
25939         * match.pd ((A +- CST1) +- CST2): Allow some conversions.
25940         * tree.c (drop_tree_overflow): Handle COMPLEX_CST and VECTOR_CST.
25942 2017-05-25  Marc Glisse  <marc.glisse@inria.fr>
25944         * fold-const.c (fold_binary_loc) [(A & C) == D]: Remove transformation.
25945         * match.pd (X == C): Rewrite it here.
25946         (with_possible_nonzero_bits, with_possible_nonzero_bits2,
25947         with_certain_nonzero_bits2): New predicates.
25948         * tree-ssanames.c (get_nonzero_bits): Handle INTEGER_CST.
25950 2017-05-24  Nathan Sidwell  <nathan@acm.org>
25952         * lto-streamer-in.c (lto_input_data_block): Adjust T const cast to
25953         avoid warning.
25955         * auto-profile.c (afdo_propagate): Adjust T const cast to avoid
25956         warning.
25958 2017-05-24  Segher Boessenkool  <segher@kernel.crashing.org>
25960         * config/powerpcspe: New port.  Files are copied from the rs6000
25961         port, with "rs6000" in filenames replaced by "powerpcspe".
25963 2017-05-24  Wilco Dijkstra  <wdijkstr@arm.com>
25965         PR rtl-optimization/80754
25966         * lra-remat.c (do_remat): Add overlap checks for dst_regno.
25968 2017-05-24  Sheldon Lobo  <smlobo@sheldon.us.oracle.com>
25970         * config/sparc/sparc.md (length): Return the correct value for -mflat
25971         sibcalls to match output_sibcall.
25973 2017-05-24  Segher Boessenkool  <segher@kernel.crashing.org>
25975         PR bootstrap/80860
25976         PR bootstrap/80843
25977         * config/rs6000/rs6000.c (struct machine_function): Add new field
25978         n_components.
25979         (rs6000_get_separate_components): Init that field, use it.
25980         (rs6000_components_for_bb): Use the field.
25982 2017-05-24  Thomas Preud'homme  <thomas.preudhomme@arm.com>
25984         * config/arm/arm.c (arm_expand_prologue): Fix typo in comment.
25986 2017-05-24  Peter Bergner  <bergner@vnet.ibm.com>
25988         PR middle-end/80823
25989         * tree-cfg.c (group_case_labels_stmt): Delete increment of "i";
25991 2017-05-24  Andreas Krebbel  <krebbel@linux.vnet.ibm.com>
25993         PR target/80725
25994         * config/s390/s390.c (s390_check_qrst_address): Check incoming
25995         address against address_operand predicate.
25996         * config/s390/s390.md ("*indirect_jump"): Swap alternatives.
25998 2017-05-24  Eric Botcazou  <ebotcazou@adacore.com>
26000         * var-tracking.c (track_expr_p): Do not return 0 for tracked record
26001         parameters passed indirectly.
26003 2017-05-23  Uros Bizjak  <ubizjak@gmail.com>
26005         * config/i386/i386.md (*movdi_internal): Remove SSE4
26006         alternative 18 (?r, *v).  Update insn attributes.
26007         (*movsi_internal): Remove SSE4 alternative 13 (?r, *v).
26008         Update insn attributes.
26009         (*zero_extendsidi2): Remove SSE4 alternative (?r, *x).
26010         Update insn attributes.
26011         * config/i386/sse.md (vec_extract<ssevecmodelower>_0): Remove SSE4
26012         alternative 1 (r, v). Remove isa attribute.
26013         * config/i386/i386.c (dimode_scalar_chain::make_vector_copies):
26014         Always move value through stack for !TARGET_INTER_UNIT_MOVES_TO_VEC
26015         and !TARGET_INTER_UNIT_MOVES_TO_VEC targets.
26017 2017-05-23  Tom de Vries  <tom@codesourcery.com>
26019         * doc/sourcebuild.texi (Directives, Verify compiler message): Document
26020         dg-line directive.
26022 2017-05-23  Jan Hubicka  <hubicka@ucw.cz>
26024         * cgraphunit.c (symbol_table::process_new_functions): Update.
26025         * ipa-fnsummary.c (pass_data_inline_parameters): Remove.
26026         (inline_generate_summary): Rename to ...
26027         (ipa_fn_summary_generate): ... this one.
26028         (inline_read_summary): Rename to ...
26029         (ipa_fn_summary_read): ... this one.
26030         (inline_write_summary): Rename to ...
26031         (ipa_fn_summary_write): ... this one.
26032         (inline_free_summary): Rename to ...
26033         (ipa_free_fn_summary): ... this one.
26034         (pass_data_local_fn_summary, pass_local_fn_summary,
26035         make_pass_local_fn_summary, pass_data_ipa_free_fn_summary,
26036         pass_ipa_free_fn_summary, make_pass_ipa_free_fn_summary,
26037         pass_data_ipa_fn_summary, pass_ipa_fn_summary,
26038         make_pass_ipa_fn_summary): New.
26039         * ipa-fnsummary.h (inline_generate_summary, inline_read_summary,
26040         inline_write_summary, inline_free_summary): Remove.
26041         (ipa_free_fn_summary) : New.
26042         * ipa-inline.c (ipa_inline): Update.
26043         (pass_ipa_inline): Do not generate summaries.
26044         * ipa.c (pass_data_ipa_free_fn_summary, pass_ipa_free_fn_summary):
26045         Remove.
26046         * passes.def: Replace pass_inline_parameters by pass_local_fn_summary
26047         and add pass_ipa_fn_summary.
26048         * tree-pass.h (make_pass_ipa_fn_summary, make_pass_local_fn_summary):
26049         New.
26050         (make_pass_inline_parameters): Remove.
26052 2017-05-23  Thomas Schwinge  <thomas@codesourcery.com>
26054         * omp-low.c (struct omp_context): Remove "default_kind" member.
26055         Adjust all users.
26057         * omp-offload.c (execute_oacc_device_lower): Remove the
26058         parallelism dimensions function attributes for unparallelized
26059         OpenACC kernels constructs.
26061 2017-05-23  Martin Liska  <mliska@suse.cz>
26063         * cgraph.c (cgraph_node::get_create): Use symtab_node::dump_{asm_,}name
26064         functions.
26065         (cgraph_edge::make_speculative): Likewise.
26066         (cgraph_edge::resolve_speculation): Likewise.
26067         (cgraph_edge::redirect_call_stmt_to_callee): Likewise.
26068         (cgraph_node::dump): Likewise.
26069         * cgraph.h: Likewise.
26070         * cgraphunit.c (analyze_functions): Likewise.
26071         (symbol_table::compile): Likewise.
26072         * ipa-cp.c (print_all_lattices): Likewise.
26073         (determine_versionability): Likewise.
26074         (initialize_node_lattices): Likewise.
26075         (ipcp_verify_propagated_values): Likewise.
26076         (estimate_local_effects): Likewise.
26077         (update_profiling_info): Likewise.
26078         (create_specialized_node): Likewise.
26079         (perhaps_add_new_callers): Likewise.
26080         (decide_about_value): Likewise.
26081         (decide_whether_version_node): Likewise.
26082         (identify_dead_nodes): Likewise.
26083         (ipcp_store_bits_results): Likewise.
26084         * ipa-devirt.c (dump_targets): Likewise.
26085         (ipa_devirt): Likewise.
26086         * ipa-icf.c (sem_item::dump): Likewise.
26087         (sem_function::equals): Likewise.
26088         (sem_variable::equals): Likewise.
26089         (sem_item_optimizer::read_section): Likewise.
26090         (sem_item_optimizer::execute): Likewise.
26091         (congruence_class::dump): Likewise.
26092         * ipa-inline-analysis.c (dump_ipa_call_summary): Likewise.
26093         (dump_inline_summary): Likewise.
26094         (estimate_node_size_and_time): Likewise.
26095         (inline_analyze_function): Likewise.
26096         * ipa-inline-transform.c (inline_call): Likewise.
26097         * ipa-inline.c (report_inline_failed_reason): Likewise.
26098         (want_early_inline_function_p): Likewise.
26099         (edge_badness): Likewise.
26100         (update_edge_key): Likewise.
26101         (inline_small_functions): Likewise.
26102         * ipa-profile.c (ipa_profile): Likewise.
26103         * ipa-prop.c (ipa_print_node_jump_functions): Likewise.
26104         (ipa_make_edge_direct_to_target): Likewise.
26105         (remove_described_reference): Likewise.
26106         (ipa_impossible_devirt_target): Likewise.
26107         (propagate_controlled_uses): Likewise.
26108         (ipa_print_node_params): Likewise.
26109         (ipcp_transform_function): Likewise.
26110         * ipa-pure-const.c (pure_const_read_summary): Likewise.
26111         (propagate_pure_const): Likewise.
26112         * ipa-reference.c (generate_summary): Likewise.
26113         (read_write_all_from_decl): Likewise.
26114         (propagate): Likewise.
26115         (ipa_reference_read_optimization_summary): Likewise.
26116         * ipa-utils.c (ipa_merge_profiles): Likewise.
26117         * ipa.c (walk_polymorphic_call_targets): Likewise.
26118         (symbol_table::remove_unreachable_nodes): Likewise.
26119         (ipa_single_use): Likewise.
26120         * passes.c (execute_todo): Likewise.
26121         * predict.c (drop_profile): Likewise.
26122         * symtab.c (symtab_node::get_dump_name): New function.
26123         (symtab_node::dump_name): Likewise.
26124         (symtab_node::dump_asm_name): Likewise.
26125         (symtab_node::dump_references): Likewise.
26126         (symtab_node::dump_referring): Likewise.
26127         (symtab_node::dump_base): Likewise.
26128         (symtab_node::debug_symtab): Likewise.
26129         * tree-sra.c (convert_callers_for_node): Likewise.
26130         * tree-ssa-structalias.c (ipa_pta_execute): Likewise.
26131         * value-prof.c (init_node_map): Likewise.
26133 2017-05-23  Martin Liska  <mliska@suse.cz>
26135         * cgraph.h: Move symtab_node::dump_table to symbol_table::dump
26136         and symtab_node::debug_symtab to symbol_table::debug.
26137         * cgraphunit.c (analyze_functions): Use the renamed function.
26138         (symbol_table::compile): Likewise.
26139         * ipa-cp.c (ipcp_verify_propagated_values): Likewise.
26140         * ipa-icf.c (sem_item_optimizer::execute): Likewise.
26141         * passes.c (execute_todo): Likewise.
26142         * symtab.c (symbol_table::dump): New function.
26143         * tree-ssa-structalias.c (ipa_pta_execute): Use the renamed function.
26145 2017-05-23  Jan Hubicka  <hubicka@ucw.cz>
26147         * ipa-fnsummary.c (estimate_node_size_and_time): Do not sanity check
26148         that nonconst implies exec.
26150 2017-05-23  Jan Hubicka  <hubicka@ucw.cz>
26152         * ipa-inline-analysis.c (cgraph_2edge_hook_list, cgraph_edge_hook_list,
26153         inline_edge_removal_hook, inline_edge_duplication_hook): Remove.
26154         (inline_edge_summary_vec): Turn into ...
26155         (ipa_call_summaries): ... this one.
26156         (redirect_to_unreachable, edge_set_predicate,
26157         evaluate_properties_for_edge, inline_summary_alloc,
26158         reset_ipa_call_summary, reset_inline_summary,
26159         inline_summary_t::duplicate): Update.
26160         (inline_edge_duplication_hook): Turn to ...
26161         (ipa_call_summary_t::duplicate): ... this one.
26162         (inline_edge_removal_hook): Turn to ...
26163         (ipa_call_summary_t::remove): ... this one.
26164         (dump_inline_edge_summary): Turn to ...
26165         (dump_ipa_call_summary): ... this one.
26166         (estimate_function_body_sizes): Update.
26167         (inline_update_callee_summaries): Update.
26168         (remap_edge_change_prob): Update.
26169         (remap_edge_summaries): Update.
26170         (inline_merge_summary): Update.
26171         (do_estimate_edge_time): Update.
26172         (inline_generate_summary): Update.
26173         (inline_read_section): Update.
26174         (inline_read_summary): Update.
26175         (inline_free_summary): Update.
26176         * ipa-inline.c (can_inline_edge_p): Update.
26177         (compute_inlined_call_time): Update.
26178         (want_inline_small_function_p): Update.
26179         (edge_badness): Update.
26180         (early_inliner): Update.
26181         * ipa-inline.h (inline_edge_summary): Turn to ...
26182         (ipa_call_summary): ... this one.
26183         (ipa_call_summary_t): New class.
26184         (inline_edge_summary_t, inline_edge_summary_vec): Remove.
26185         (ipa_call_summaries): New.
26186         (inline_edge_summary): Remove.
26187         (estimate_edge_growth): Update.
26188         * ipa-profile.c (ipa_propagate_frequency_1): Update.
26189         * ipa-prop.c (ipa_make_edge_direct_to_target): Update.
26190         * ipa-split.c (execute_split_functions): Update.
26191         * ipa.c (symbol_table::remove_unreachable_nodes): Update.
26193 2017-05-23  Tom de Vries  <tom@codesourcery.com>
26195         * doc/sourcebuild.texi (Effective-Target Keywords, Other hardware
26196         attributes): Document rdrand effective target.
26198 2017-05-23  Tom de Vries  <tom@codesourcery.com>
26200         * doc/sourcebuild.texi (Effective-Target Keywords, Other hardware
26201         attributes): Sort alphabetically.
26203 2017-05-23  Georg-Johann Lay  <avr@gjlay.de>
26205         * config/avr/genmultilib.awk: Use gsub instead of gensub.
26207 2017-05-22  Michael Meissner  <meissner@linux.vnet.ibm.com>
26209         PR target/80718
26210         * config/rs6000/vsx.md (vsx_splat_<mode>, VSX_D iterator): Split
26211         V2DF/V2DI splat into two separate patterns, one that handles
26212         registers, and the other that only handles memory.  Drop support
26213         for splatting from a GPR on ISA 2.07 and then splitting the
26214         splat into direct move and splat.
26215         (vsx_splat_<mode>_reg): Likewise.
26216         (vsx_splat_<mode>_mem): Likewise.
26218 2017-05-22  Segher Boessenkool  <segher@kernel.crashing.org>
26220         * cfgcleanup.c (bb_is_just_return): Allow CLOBBERs.
26222 2017-05-22  Jakub Jelinek  <jakub@redhat.com>
26224         PR middle-end/80809
26225         * omp-low.c (finish_taskreg_remap): New function.
26226         (finish_taskreg_scan): If unit size of ctx->record_type
26227         is non-constant, unshare the size expression and replace
26228         decls in it with possible outer var refs.
26230         PR middle-end/80809
26231         * gimplify.c (omp_add_variable): For GOVD_DEBUG_PRIVATE use
26232         GOVD_SHARED rather than GOVD_PRIVATE with it.
26233         (gimplify_adjust_omp_clauses_1, gimplify_adjust_omp_clauses): Expect
26234         GOVD_SHARED rather than GOVD_PRIVATE with GOVD_DEBUG_PRIVATE.
26236         PR middle-end/80853
26237         * omp-low.c (lower_reduction_clauses): Pass OMP_CLAUSE_PRIVATE
26238         as last argument to build_outer_var_ref for pointer bases of array
26239         section reductions.
26241 2017-05-19  Martin Sebor  <msebor@redhat.com>
26243         * print-tree.c (print_node): Print DECL_READ_P flag.
26245 2017-05-22  Jan Hubicka  <hubicka@ucw.cz>
26247         * Makefile.in: Add ipa-fnsummary.o and ipa-fnsummary.h
26248         * auto-profile.c: Replace ipa-inline.h by ipa-fnsummary.h
26249         * cgraph.c: Likewise.
26250         * cgraphunit.c: Likewise.
26251         * gengtype.c: Likewise.
26252         * ipa-cp.c: Likewise.
26253         * ipa-devirt.c: Likewise.
26254         * ipa-icf.c: Likewise.
26255         * ipa-predicate.c: Likewise.
26256         * ipa-profile.c: Likewise.
26257         * ipa-prop.c: Likewise.
26258         * ipa-split.c: Likewise.
26259         * ipa.c: Likewise.
26260         * ipa-inline-analysis.c (inline_summaries, ipa_call_summaries,
26261         edge_predicate_pool, dump_inline_hints,
26262         inline_summary::account_size_time, redirect_to_unreachable,
26263         edge_set_predicate, set_hint_predicate,
26264         evaluate_conditions_for_known_args, evaluate_properties_for_edge,
26265         inline_summary_alloc, ipa_call_summary::reset, inline_summary::reset,
26266         inline_summary_t::remove, remap_hint_predicate_after_duplication,
26267         inline_summary_t::duplicate, ipa_call_summary_t::duplicate,
26268         ipa_call_summary_t::remove, initialize_growth_caches,
26269         free_growth_caches, dump_ipa_call_summary, dump_inline_summary,
26270         debug_inline_summary, dump_inline_summaries, initialize_inline_failed,
26271         mark_modified, unmodified_parm_1, unmodified_parm,
26272         unmodified_parm_or_parm_agg_item, eliminated_by_inlining_prob,
26273         set_cond_stmt_execution_predicate, set_switch_stmt_execution_predicate,
26274         compute_bb_predicates, will_be_nonconstant_expr_predicate,
26275         will_be_nonconstant_predicate, record_modified_bb_info,
26276         get_minimal_bb, record_modified, param_change_prob,
26277         phi_result_unknown_predicate, predicate_for_phi_result,
26278         array_index_predicate, clobber_only_eh_bb_p, fp_expression_p,
26279         estimate_function_body_sizes, compute_inline_parameters,
26280         compute_inline_parameters_for_curren, pass_data_inline_parameters,
26281         estimate_node_size_and_time, estimate_ipcp_clone_size_and_time,
26282         inline_update_callee_summaries, remap_edge_change_prob,
26283         remap_edge_summaries, remap_hint_predicate, inline_merge_summary,
26284         inline_update_overall_summary, inline_indirect_intraprocedural_analysis,
26285         inline_analyze_function, inline_summary_t::insert,
26286         inline_generate_summary, read_ipa_call_summary, inline_read_section,
26287         inline_read_summary, write_ipa_call_summary, inline_write_summary,
26288         inline_free_summary): Move to ipa-fnsummary.h
26289         (predicate_t): Remove.
26290         * ipa-fnsummary.c: New file.
26291         * ipa-inline.h:  Do not include sreal.h and ipa-predicate.h
26292         (enum inline_hints_vals, inline_hints, agg_position_info,
26293         INLINE_SIZE_SCALE, size_time_entry, inline_summary, inline_summary_t,
26294         inline_summaries, ipa_call_summary, ipa_call_summary_t,
26295         ipa_call_summaries, debug_inline_summary, dump_inline_summaries,
26296         dump_inline_summary, dump_inline_hints, inline_generate_summary,
26297         inline_read_summary, inline_write_summary, inline_free_summary,
26298         inline_analyze_function, initialize_inline_failed,
26299         inline_merge_summary, inline_update_overall_summary,
26300         compute_inline_parameters): Move to ipa-fnsummary.h
26301         * ipa-fnsummary.h: New file.
26302         * ipa-inline-transform.h: Include ipa-inline.h.
26303         * ipa-inline.c: LIkewise.
26305 2017-05-22  Jan Hubicka  <hubicka@ucw.cz>
26307         * ipa-inline.c (edge_badness): Use inlined_time instead of
26308         inline_summaries->get.
26310 2017-05-22  Jan Hubicka  <hubicka@ucw.cz>
26312         * ipa-inline.c (edge_badness): Use estimate_size_after_inlining.
26314 2017-05-22  Nathan Sidwell  <nathan@acm.org>
26316         * doc/invoke.texi (fdump-translation-unit): Delete documentation.
26317         (fdump-lang): Document 'raw' option.
26318         * dumpfile.h (TDI_tu): Delete.
26319         * dumpfile.c (dump_files): Remove translation-unit.
26320         (FIRST_AUTO_NUMBERED_DUMP): Decrement.
26322 2017-05-22  Georg-Johann Lay  <avr@gjlay.de>
26324         * config/avr/t-avr (AWK) [t-multilib]: Remove "-v FORMAT=Makefile"
26325         command option from $(AWK) call.
26326         * config/avr/genmultilib.awk: Simplify and rewrite so that it
26327         generates MULTILIB_REQUIRED instead of MULTILIB_EXCEPTIONS.
26328         [FORMAT]: Remove handling of variable.
26329         * config/avr/t-multilib: Regenerate.
26331 2017-05-22  Jan Hubicka  <hubicka@ucw.cz>
26333         * ipa-inline-analysis.c (inline_summary::reset): Do not reset
26334         self_time.
26335         (dump_inline_summary): Do not print self_time.
26336         (estimate_function_body_sizes): Do not set self_time.
26337         (compute_inline_parameters): Likewise.
26338         (inline_read_section, inline_write_summary): Do not stream self_time.
26339         * ipa-inline.h (inline_summary): Drop self_time.
26341 2017-05-22  Jan Hubicka  <hubicka@ucw.cz>
26343         * ipa-inline-analysis.c (account_size_time): Rename to ...
26344         (inline_summary::account_size_time): ... this one.
26345         (reset_ipa_call_summary): Turn to ...
26346         (ipa_call_summary::reset): ... this one.
26347         (reset_inline_summary): Turn to ...
26348         (inline_summary::reset): ... this one.
26349         (inline_summary_t::remove): Update.
26350         (inline_summary_t::duplicate): Update.
26351         (ipa_call_summary_t::remove): Update.
26352         (dump_inline_summary): Update.
26353         (estimate_function_body_sizes): Update.
26354         (compute_inline_parameters): Update.
26355         (estimate_node_size_and_time): Update.
26356         (inline_merge_summary): Update.
26357         (inline_update_overall_summary): Update.
26358         (inline_read_section): Update.
26359         (inline_write_summary): Update.
26360         * ipa-inline.h (inline_summary): Rename entry to size_time_table;
26361         add account_size_time and reset member functions.
26362         (ipa_call_summary): Add reset function.
26363         * ipa-predicate.h (predicate::operator &): Constify.
26365 2017-05-22  Richard Biener  <rguenther@suse.de>
26367         * df-scan.c (df_insn_refs_verify): Speedup when not verifying.
26369 2017-05-19  Jason Merrill  <jason@redhat.com>
26371         * tree.c (make_tree_vec_stat, grow_tree_vec_stat): Use size_t.
26373 2017-05-19  Marek Polacek  <polacek@redhat.com>
26375         PR sanitizer/80800
26376         * fold-const.c (extract_muldiv_1) <case TRUNC_DIV_EXPR>: Add
26377         TYPE_OVERFLOW_WRAPS checks.
26379 2017-05-19  Thomas Schwinge  <thomas@codesourcery.com>
26381         * tree-core.h (enum omp_clause_default_kind): Add
26382         "OMP_CLAUSE_DEFAULT_PRESENT".
26383         * tree-pretty-print.c (dump_omp_clause): Handle it.
26384         * gimplify.c (enum gimplify_omp_var_data): Add
26385         "GOVD_MAP_FORCE_PRESENT".
26386         (gimplify_adjust_omp_clauses_1): Map it to
26387         "GOMP_MAP_FORCE_PRESENT".
26388         (oacc_default_clause): Handle "OMP_CLAUSE_DEFAULT_PRESENT".
26390         * gimplify.c (oacc_default_clause): Clarify.
26392 2017-05-19  Nathan Sidwell  <nathan@acm.org>
26394         LANG_HOOK_REGISTER_DUMPS
26395         * toplev.c (general_init): Call register dump lang hook.
26396         * doc/invoke.texi: Document -fdump-lang option family.
26397         * dumpfile.c (dump_files): Remove class dump here.
26398         (FIRST_AUTO_NUMBERED_DUMP): Adjust.
26399         * dumpfile.h (tree_dump_index): Remove TDI_class.
26400         * langhooks-def.h (lhd_register_dumps): Declare.
26401         (LANG_HOOKS_REGISTER_DUMPS): Define.
26402         (LANG_HOOKS_INITIALIZER): Add it.
26403         * langhooks.c (lhd_register_dumps): Define.
26404         * langhooks.h (struct lang_hooks): Add register_dumps.
26406 2017-05-19  Nathan Sidwell  <nathan@acm.org>
26408         * context.h (context::set_passes): New.
26409         * context.c (context::context): Do not create pass manager.
26410         * toplev.c (general_init): Create pass manager here.
26412 2017-05-19  Segher Boessenkool  <segher@kernel.crashing.org>
26414         * config/rs6000/rs6000.md (splitter to load of -1 and mask): Don't
26415         use this splitter if two add or or instructions would also work for
26416         the constant we want to generate.
26418 2017-05-19  Richard Biener  <rguenther@suse.de>
26420         PR build/80821
26421         * genmatch.c (dt_node::gen_kids_1): Add missing scope around
26422         predicate evaluation.
26424 2017-05-19  Jan Hubicka  <hubicka@ucw.cz>
26426         * ipa-inline.h (ipa_call_summary): Turn sizes into signed;
26427         add ctor.
26428         * ipa-inline.c (want_inline_small_function_p): Do not cast to
26429         unsigned.
26431 2017-05-19  Jan Hubicka  <hubicka@ucw.cz>
26433         * ipa-inline-analysis.c (cgraph_2edge_hook_list, cgraph_edge_hook_list,
26434         inline_edge_removal_hook, inline_edge_duplication_hook): Remove.
26435         (inline_edge_summary_vec): Turn into ...
26436         (ipa_call_summaries): ... this one.
26437         (redirect_to_unreachable, edge_set_predicate,
26438         evaluate_properties_for_edge, inline_summary_alloc,
26439         reset_ipa_call_summary, reset_inline_summary,
26440         inline_summary_t::duplicate): Update.
26441         (inline_edge_duplication_hook): Turn to ...
26442         (ipa_call_summary_t::duplicate): ... this one.
26443         (inline_edge_removal_hook): Turn to ...
26444         (ipa_call_summary_t::remove): ... this one.
26445         (dump_inline_edge_summary): Turn to ...
26446         (dump_ipa_call_summary): ... this one.
26447         (estimate_function_body_sizes): Update.
26448         (inline_update_callee_summaries): Update.
26449         (remap_edge_change_prob): Update.
26450         (remap_edge_summaries): Update.
26451         (inline_merge_summary): Update.
26452         (do_estimate_edge_time): Update.
26453         (inline_generate_summary): Update.
26454         (inline_read_section): Update.
26455         (inline_read_summary): Update.
26456         (inline_free_summary): Update.
26457         * ipa-inline.c (can_inline_edge_p): Update.
26458         (compute_inlined_call_time): Update.
26459         (want_inline_small_function_p): Update.
26460         (edge_badness): Update.
26461         (early_inliner): Update.
26462         * ipa-inline.h (inline_edge_summary): Turn to ...
26463         (ipa_call_summary): ... this one.
26464         (ipa_call_summary_t): New class.
26465         (inline_edge_summary_t, inline_edge_summary_vec): Remove.
26466         (ipa_call_summaries): New.
26467         (inline_edge_summary): Remove.
26468         (estimate_edge_growth): Update.
26469         * ipa-profile.c (ipa_propagate_frequency_1): Update.
26470         * ipa-prop.c (ipa_make_edge_direct_to_target): Update.
26471         * ipa-split.c (execute_split_functions): Update.
26472         * ipa.c (symbol_table::remove_unreachable_nodes): Update.
26474 2017-05-19  Richard Biener  <rguenther@suse.de>
26476         PR middle-end/80764
26477         * cfgexpand.c (expand_gimple_cond): Fix loop fixup.
26479 2017-05-18  Segher Boessenkool  <segher@kernel.crashing.org>
26481         * config/rs6000/rs6000.c (struct machine_function): Add field
26482         fpr_is_wrapped_separately.
26483         (rs6000_get_separate_components): Use 64 components.  Handle the
26484         new FPR components.
26485         (rs6000_components_for_bb): Handle the FPR components.
26486         (rs6000_emit_prologue_components): Handle the FPR components.
26487         (rs6000_emit_epilogue_components): Handle the FPR components.
26488         (rs6000_set_handled_components): Handle the FPR components.
26489         (rs6000_emit_prologue): Don't output prologue code for those FPRs
26490         that are already separately shrink-wrapped.
26491         (rs6000_emit_epilogue): Don't output epilogue code for those FPRs
26492         that are already separately shrink-wrapped.
26494 2017-05-18  Michael Meissner  <meissner@linux.vnet.ibm.com>
26496         PR target/80510
26497         * config/rs6000/predicates.md (simple_offsettable_mem_operand):
26498         New predicate.
26500         * config/rs6000/rs6000.md (ALTIVEC_DFORM): New iterator.
26501         (define_peephole2 for Altivec d-form load): Add peepholes to catch
26502         cases where the register allocator uses a move and an offsettable
26503         memory operation to/from a FPR register on ISA 2.06/2.07.
26504         (define_peephole2 for Altivec d-form store): Likewise.
26506 2017-05-18  Uros Bizjak  <ubizjak@gmail.com>
26508         PR target/80799
26509         * config/i386/mmx.md (*mov<mode>_internal): Enable
26510         alternatives 11, 12, 13 and 14 also for 32bit targets.
26511         Remove alternatives 15, 16, 17 and 18.
26512         * config/i386/sse.md (vec_concatv2di): Change
26513         alternative (!x, *y) to (x, ?!*Yn).
26515 2017-05-18  Paolo Carlini  <paolo.carlini@oracle.com>
26517         * dumpfile.h (enum dump_kind): Remove stray comma.
26519 2017-05-18  Jan Hubicka  <hubicka@ucw.cz>
26521         * Makefile.in: Add ipa-predicate.o and ipa-predicate.h
26522         * ipa-inline-analysis.c (NUM_CONDITIONS): turn into
26523         predicate::num_conditions
26524         (IS_NOT_CONSTANT): turn into predicate::is_not_constant.
26525         (CHANGED): turn into predicate::changed.
26526         (agg_position_info): Move to ipa-predicate.h
26527         (add_condition, predicate::add_clause, predicate::operator &=,
26528         predicate::or_with, predicate::evaluate, predicate::probability,
26529         dump_condition, dump_clause, predicate::dump,
26530         predicate::remap_after_duplication, predicate::remap_after_inlining,
26531         predicate::stream_in, predicate::stream_out): Move to ipa-predicate.c
26532         (evaluate_conditions_for_known_args): Update.
26533         (set_cond_stmt_execution_predicate): Update.
26534         * ipa-inline.h: Include ipa-predicate.h
26535         (condition, inline_param_summary, conditions, agg_position_info,
26536         predicate): Move to ipa-predicate.h
26537         * ipa-predicate.c: New file.
26538         * ipa-predicate.h: New file.
26540 2017-05-18  Wilco Dijkstra  <wdijkstr@arm.com>
26542         * final.c (leaf_function_p): Check we are not in a sequence.
26544 2017-05-18  Martin Liska  <mliska@suse.cz>
26546         * cfgrtl.c (rtl_verify_edges): Remove usage of TDF_RTL.
26547         * dumpfile.c (dump_register): Use new enum dump_kind.
26548         (get_dump_file_name): Likewise.
26549         (dump_enable_all): Likewise.
26550         (dump_switch_p_1): Likewise.
26551         (enable_rtl_dump_file): Remove usage of TDF_RTL.
26552         * dumpfile.h (enum dump_kind): New enum type.
26553         (struct dump_file_info): Create constructor and
26554         format fields and comments.
26555         * passes.c (pass_manager::register_one_dump_file):
26556         Use num dump_kind.
26557         * statistics.c (statistics_early_init): Likewise.
26558         * tree-ssa-loop-prefetch.c (dump_mem_details): Replace
26559         TDF_TREE with TDF_SLIM.
26560         (gather_memory_references_ref): Likewise.
26562 2017-05-18  Martin Liska  <mliska@suse.cz>
26564         * vec.h (struct vnull): Use it.
26566 2017-05-18  Jan Hubicka  <hubicka@ucw.cz>
26568         * ipa-inline-analysis.c (predicate_conditions): Move to ipa-inline.h
26569         (true_predicate, false_predicate, true_predicate_p,
26570         false_predicate_p): Remove.
26571         (single_cond_predicate, not_inlined_predicate): Turn to member function
26572         in ipa-inline.h
26573         (add_condition): Update.
26574         (add_clause): Turn to...
26575         (predicate::add_clause): ... this one; update; allow passing NULL
26576         as parameter.
26577         (and_predicates): Turn to ...
26578         (predicate::operator &=): ... this one.
26579         (predicates_equal_p): Move to predicate::operator == in ipa-inline.h
26580         (or_predicates): Turn to ...
26581         (predicate::or_with): ... this one.
26582         (evaluate_predicate): Turn to ...
26583         (predicate::evaluate): ... this one.
26584         (predicate_probability): Turn to ...
26585         (predicate::probability): ... this one.
26586         (dump_condition): Update.
26587         (dump_predicate): Turn to ...
26588         (predicate::dump): ... this one.
26589         (account_size_time): Update.
26590         (edge_set_predicate): Update.
26591         (set_hint_predicate): UPdate.
26592         (evaluate_conditions_for_known_args): Update.
26593         (evaluate_properties_for_edge): Update.
26594         (remap_predicate_after_duplication): Turn to...
26595         (predicate::remap_after_duplication): ... this one.
26596         (remap_hint_predicate_after_duplication): Update.
26597         (inline_summary_t::duplicate): UPdate.
26598         (dump_inline_edge_summary): Update.
26599         (dump_inline_summary): Update.
26600         (set_cond_stmt_execution_predicate): Update.
26601         (set_switch_stmt_execution_predicate): Update.
26602         (compute_bb_predicates): Update.
26603         (will_be_nonconstant_expr_predicate): Update.
26604         (will_be_nonconstant_predicate): Update.
26605         (phi_result_unknown_predicate): Update.
26606         (predicate_for_phi_result): Update.
26607         (array_index_predicate): Update.
26608         (estimate_function_body_sizes): Update.
26609         (estimate_node_size_and_time): Update.
26610         (estimate_ipcp_clone_size_and_time): Update.
26611         (remap_predicate): Rename to ...
26612         (predicate::remap_after_inlining): ... this one.
26613         (remap_hint_predicate): Update.
26614         (inline_merge_summary): Update.
26615         (inline_update_overall_summary): Update.
26616         (estimate_size_after_inlining): Update.
26617         (read_predicate): Rename to ...
26618         (predicate::stream_in): ... this one.
26619         (read_inline_edge_summary): Update.
26620         (write_predicate): Rename to ...
26621         (predicate::stream_out): ... this one.
26622         (write_inline_edge_summary): Update.
26623         * ipa-inline.h (MAX_CLAUSES): Turn to predicate::max_clauses.
26624         (clause_t): Turn to uint32_t
26625         (predicate): Turn to class; implement constructor and operators
26626         ==, !=, &
26627         (size_time_entry): Update.
26628         (inline_summary): Update.
26629         (inline_edge_summary): Update.
26631 2017-05-18  Marc Glisse  <marc.glisse@inria.fr>
26633         * fold-const.c (fold_binary_loc): Move transformation...
26634         * match.pd (C - X CMP X): ... here.
26636 2017-05-18  Sheldon Lobo  <sheldon.lobo@oracle.com>
26638         * config/sparc/sparc.c (sparc_option_override): Set function
26639         alignment for -mcpu=niagara7 to 64 to match the I$ line.
26640         * config/sparc/sparc.h (BRANCH_COST): Set the SPARC M7 branch
26641         latency to 1.
26642         * config/sparc/sparc.h (BRANCH_COST): Set the SPARC T4 branch
26643         latency to 2.
26644         * config/sparc/sol2.h: Fix a ASM_CPU32_DEFAULT_SPEC typo.
26646 2017-05-18  Marek Polacek  <polacek@redhat.com>
26648         PR sanitizer/80797
26649         * ubsan.c (instrument_null): Unwrap ADDR_EXPRs.
26650         (pass_ubsan::execute): Call gimple_assign_single_p instead of
26651         gimple_assign_load_p.
26653 2017-05-17  Segher Boessenkool  <segher@kernel.crashing.org>
26655         PR middle-end/80692
26656         * real.c (do_compare): Give decimal_do_compare preference over
26657         comparing just the signs.
26659 2017-05-17  Uros Bizjak  <ubizjak@gmail.com>
26661         * doc/md.texi (Canonicalization of Instructions): Describe the
26662         canonical form of instructions that inherently set a condition
26663         code register.
26665 2017-05-17  Peter Bergner  <bergner@vnet.ibm.com>
26667         PR middle-end/80775
26668         * tree-cfg.c: Move deletion of unreachable case statements to after
26669         the merging of consecutive case labels.
26671 2017-05-17  Thomas Preud'homme  <thomas.preudhomme@arm.com>
26673         * config/arm/arm.c (cmse_nonsecure_call_clear_caller_saved): Refer
26674         readers to __gnu_cmse_nonsecure_call libcall for saving, clearing and
26675         restoring of callee-saved registers.
26677 2017-05-17  Eric Botcazou  <ebotcazou@adacore.com>
26679         * compare-elim.c (equivalent_reg_at_start): Adjust outdated comment.
26680         * config/visium/visium.c (single_set_and_flags): Likewise.
26681         * config/visium/visium.md (Substitutions): Likewise.
26683 2017-05-17  Martin Liska  <mliska@suse.cz>
26685         * cfg.c: Introduce dump_flags_t type and
26686         use it instead of int type.
26687         * cfg.h: Likewise.
26688         * cfghooks.c: Likewise.
26689         * cfghooks.h (struct cfg_hooks): Likewise.
26690         * cfgrtl.c: Likewise.
26691         * cfgrtl.h: Likewise.
26692         * cgraph.c (cgraph_node::get_body): Likewise.
26693         * coretypes.h: Likewise.
26694         * domwalk.c: Likewise.
26695         * domwalk.h: Likewise.
26696         * dumpfile.c (struct dump_option_value_info): Likewise.
26697         (dump_enable_all): Likewise.
26698         (dump_switch_p_1): Likewise.
26699         (opt_info_switch_p): Likewise.
26700         * dumpfile.h (enum tree_dump_index): Likewise.
26701         (struct dump_file_info): Likewise.
26702         * genemit.c: Likewise.
26703         * generic-match-head.c: Likewise.
26704         * gengtype.c (open_base_files): Likewise.
26705         * gimple-pretty-print.c: Likewise.
26706         * gimple-pretty-print.h: Likewise.
26707         * graph.c (print_graph_cfg): Likewise.
26708         * graphite-scop-detection.c (dot_all_sese): Likewise.
26709         * ipa-devirt.c (build_type_inheritance_graph): Likewise.
26710         * loop-unroll.c (report_unroll): Likewise.
26711         * passes.c (pass_manager::register_one_dump_file): Likewise.
26712         * print-tree.c: Likewise.
26713         * statistics.c: Likewise.
26714         * tree-cfg.c: Likewise.
26715         * tree-cfg.h: Likewise.
26716         * tree-dfa.c: Likewise.
26717         * tree-dfa.h: Likewise.
26718         * tree-dump.c (dump_function): Likewise.
26719         * tree-dump.h (struct dump_info): Likewise.
26720         * tree-pretty-print.c: Likewise.
26721         * tree-pretty-print.h: Likewise.
26722         * tree-ssa-live.c: Likewise.
26723         * tree-ssa-live.h: Likewise.
26724         * tree-ssa-loop-ivcanon.c (try_unroll_loop_completely): Likewise.
26725         * tree-vect-loop.c: Likewise.
26726         * tree-vect-slp.c: Likewise.
26728 2017-05-16  James Greenhalgh  <james.greenhalgh@arm.com>
26729             Bill Schmidt  <wschmidt@linux.vnet.ibm.com>
26731         PR tree-optimization/80457
26732         * tree-vect-stmts.c (vect_model_simple_cost): Model the cost
26733         of all arguments to a statement as scalar_to_vec operations.
26734         (vectorizable_call): Adjust call to vect_model_simple_cost for
26735         new parameter.
26736         (vectorizable_conversion): Likewise.
26737         (vectorizable_assignment): Likewise.
26738         (vectorizable_shift): Likewise.
26739         (vectorizable_operation): Likewise.
26740         (vectorizable_comparison): Likewise.
26741         (vect_is_simple_cond): Record the def types for operands.
26742         (vectorizable_condition): Likewise, call vect_model_simple_cost.
26743         * tree-vectorizer.h (vect_model_simple_cost): Add new parameter
26744         for statement argument count.
26746 2017-05-16  Carl Love  <cel@us.ibm.com>
26748         * config/rs6000/rs6000-c: Add support for built-in functions
26749         vector unsigned long long vec_bperm (vector unsigned long long,
26750                                              vector unsigned char)
26751         vector signed long long vec_mule (vector signed int,
26752                                           vector signed int)
26753         vector unsigned long long vec_mule (vector unsigned int,
26754                                             vector unsigned int)
26755         vector signed long long vec_mulo (vector signed int,
26756                                           vector signed int)
26757         vector unsigned long long vec_mulo (vector unsigned int,
26758                                             vector unsigned int)
26759         vector signed char vec_sldw (vector signed char,
26760                                      vector signed char,
26761                                      const int)
26762         vector unsigned char vec_sldw (vector unsigned char,
26763                                        vector unsigned char,
26764                                        const int)
26765         vector signed short vec_sldw (vector signed short,
26766                                       vector signed short,
26767                                       const int)
26768         vector unsigned short vec_sldw (vector unsigned short,
26769                                         vector unsigned short,
26770                                         const int)
26771         vector signed int vec_sldw (vector signed int,
26772                                     vector signed int,
26773                                     const int)
26774         vector unsigned int vec_sldw (vector unsigned int,
26775                                       vector unsigned int,
26776                                       const int)
26777         vector signed long long vec_sldw (vector signed long long,
26778                                           vector signed long long,
26779                                           const int)
26780         vector unsigned long long vec_sldw (vector unsigned long long,
26781                                             vector unsigned long long,
26782                                             const int)
26783         * config/rs6000/rs6000-c: Add support for built-in functions
26784         * config/rs6000/rs6000-builtin.def: Add definition for SLDW.
26785         * config/rs6000/altivec.h: Add defintion for vec_sldw.
26786         * doc/extend.texi: Update the built-in documentation for the
26787         new built-in functions.
26789 2017-05-16  Marek Polacek  <polacek@redhat.com>
26791         PR sanitizer/80536
26792         PR sanitizer/80386
26793         * tree.c (save_expr): Don't fold the expression.
26795 2017-05-16  Uros Bizjak  <ubizjak@gmail.com>
26797         * config/i386/i386.md (*movsi_internal): Split (?rm,*y) alternative
26798         to (?r,*Yn) and (?m,*y) alternatives, and (?*y,rm) to (?*Ym,r)
26799         and (?*y,m).  Update insn attributes.
26801 2017-05-16  Martin Liska  <mliska@suse.cz>
26803         * cgraph.c (cgraph_edge::resolve_speculation): Add default value for
26804         flags argument of print_gimple_stmt, print_gimple_expr,
26805         print_generic_stmt and print_generic_expr.
26806         * cgraphclones.c (symbol_table::materialize_all_clones): Likewise.
26807         * coretypes.h: Likewise.
26808         * except.c (dump_eh_tree): Likewise.
26809         * gimple-fold.c (gimple_fold_stmt_to_constant_1): Likewise.
26810         * gimple-pretty-print.h: Likewise.
26811         * gimple-ssa-backprop.c (dump_usage_prefix): Likewise.
26812         (backprop::push_to_worklist): Likewise.
26813         (backprop::pop_from_worklist): Likewise.
26814         (backprop::process_use): Likewise.
26815         (backprop::intersect_uses): Likewise.
26816         (note_replacement): Likewise.
26817         * gimple-ssa-store-merging.c
26818         (pass_store_merging::terminate_all_aliasing_chains): Likewise.
26819         (imm_store_chain_info::coalesce_immediate_stores): Likewise.
26820         (pass_store_merging::execute): Likewise.
26821         * gimple-ssa-strength-reduction.c (dump_candidate): Likewise.
26822         (ssa_base_cand_dump_callback): Likewise.
26823         (dump_incr_vec): Likewise.
26824         (replace_refs): Likewise.
26825         (replace_mult_candidate): Likewise.
26826         (create_add_on_incoming_edge): Likewise.
26827         (create_phi_basis): Likewise.
26828         (insert_initializers): Likewise.
26829         (all_phi_incrs_profitable): Likewise.
26830         (introduce_cast_before_cand): Likewise.
26831         (replace_one_candidate): Likewise.
26832         * gimplify.c (gimplify_expr): Likewise.
26833         * graphite-isl-ast-to-gimple.c (is_valid_rename): Likewise.
26834         (set_rename): Likewise.
26835         (rename_uses): Likewise.
26836         (copy_loop_phi_nodes): Likewise.
26837         (add_close_phis_to_merge_points): Likewise.
26838         (copy_loop_close_phi_args): Likewise.
26839         (copy_cond_phi_args): Likewise.
26840         (graphite_copy_stmts_from_block): Likewise.
26841         (translate_pending_phi_nodes): Likewise.
26842         * graphite-poly.c (print_pdr): Likewise.
26843         (dump_gbb_cases): Likewise.
26844         (dump_gbb_conditions): Likewise.
26845         (print_scop_params): Likewise.
26846         * graphite-scop-detection.c (build_cross_bb_scalars_def): Likewise.
26847         (build_cross_bb_scalars_use): Likewise.
26848         (gather_bbs::before_dom_children): Likewise.
26849         * hsa-dump.c (dump_hsa_immed): Likewise.
26850         * ipa-cp.c (print_ipcp_constant_value): Likewise.
26851         (get_replacement_map): Likewise.
26852         * ipa-inline-analysis.c (dump_condition): Likewise.
26853         (estimate_function_body_sizes): Likewise.
26854         * ipa-polymorphic-call.c (check_stmt_for_type_change): Likewise.
26855         (ipa_polymorphic_call_context::get_dynamic_type): Likewise.
26856         * ipa-prop.c (ipa_dump_param): Likewise.
26857         (ipa_print_node_jump_functions_for_edge): Likewise.
26858         (ipa_modify_call_arguments): Likewise.
26859         (ipa_modify_expr): Likewise.
26860         (ipa_dump_param_adjustments): Likewise.
26861         (ipa_dump_agg_replacement_values): Likewise.
26862         (ipcp_modif_dom_walker::before_dom_children): Likewise.
26863         * ipa-pure-const.c (check_stmt): Likewise.
26864         (pass_nothrow::execute): Likewise.
26865         * ipa-split.c (execute_split_functions): Likewise.
26866         * omp-offload.c (dump_oacc_loop_part): Likewise.
26867         (dump_oacc_loop): Likewise.
26868         * trans-mem.c (tm_log_emit): Likewise.
26869         (tm_memopt_accumulate_memops): Likewise.
26870         (dump_tm_memopt_set): Likewise.
26871         (dump_tm_memopt_transform): Likewise.
26872         * tree-cfg.c (gimple_verify_flow_info): Likewise.
26873         (print_loop): Likewise.
26874         * tree-chkp-opt.c (chkp_print_addr): Likewise.
26875         (chkp_gather_checks_info): Likewise.
26876         (chkp_get_check_result): Likewise.
26877         (chkp_remove_check_if_pass): Likewise.
26878         (chkp_use_outer_bounds_if_possible): Likewise.
26879         (chkp_reduce_bounds_lifetime): Likewise.
26880         * tree-chkp.c (chkp_register_addr_bounds): Likewise.
26881         (chkp_mark_completed_bounds): Likewise.
26882         (chkp_register_incomplete_bounds): Likewise.
26883         (chkp_mark_invalid_bounds): Likewise.
26884         (chkp_maybe_copy_and_register_bounds): Likewise.
26885         (chkp_build_returned_bound): Likewise.
26886         (chkp_get_bound_for_parm): Likewise.
26887         (chkp_build_bndldx): Likewise.
26888         (chkp_get_bounds_by_definition): Likewise.
26889         (chkp_generate_extern_var_bounds): Likewise.
26890         (chkp_get_bounds_for_decl_addr): Likewise.
26891         * tree-chrec.c (chrec_apply): Likewise.
26892         * tree-data-ref.c (dump_data_reference): Likewise.
26893         (dump_subscript): Likewise.
26894         (dump_data_dependence_relation): Likewise.
26895         (analyze_overlapping_iterations): Likewise.
26896         * tree-inline.c (expand_call_inline): Likewise.
26897         (tree_function_versioning): Likewise.
26898         * tree-into-ssa.c (dump_defs_stack): Likewise.
26899         (dump_currdefs): Likewise.
26900         (dump_names_replaced_by): Likewise.
26901         (dump_update_ssa): Likewise.
26902         (update_ssa): Likewise.
26903         * tree-object-size.c (pass_object_sizes::execute): Likewise.
26904         * tree-parloops.c (build_new_reduction): Likewise.
26905         (try_create_reduction_list): Likewise.
26906         (ref_conflicts_with_region): Likewise.
26907         (oacc_entry_exit_ok_1): Likewise.
26908         (oacc_entry_exit_single_gang): Likewise.
26909         * tree-pretty-print.h: Likewise.
26910         * tree-scalar-evolution.c (set_scalar_evolution): Likewise.
26911         (get_scalar_evolution): Likewise.
26912         (add_to_evolution): Likewise.
26913         (get_loop_exit_condition): Likewise.
26914         (analyze_evolution_in_loop): Likewise.
26915         (analyze_initial_condition): Likewise.
26916         (analyze_scalar_evolution): Likewise.
26917         (instantiate_scev): Likewise.
26918         (number_of_latch_executions): Likewise.
26919         (gather_chrec_stats): Likewise.
26920         (final_value_replacement_loop): Likewise.
26921         (scev_const_prop): Likewise.
26922         * tree-sra.c (dump_access): Likewise.
26923         (disqualify_candidate): Likewise.
26924         (create_access): Likewise.
26925         (reject): Likewise.
26926         (maybe_add_sra_candidate): Likewise.
26927         (create_access_replacement): Likewise.
26928         (analyze_access_subtree): Likewise.
26929         (analyze_all_variable_accesses): Likewise.
26930         (sra_modify_assign): Likewise.
26931         (initialize_constant_pool_replacements): Likewise.
26932         (find_param_candidates): Likewise.
26933         (decide_one_param_reduction): Likewise.
26934         (replace_removed_params_ssa_names): Likewise.
26935         * tree-ssa-ccp.c (ccp_fold_stmt): Likewise.
26936         * tree-ssa-copy.c (dump_copy_of): Likewise.
26937         (copy_prop_visit_cond_stmt): Likewise.
26938         * tree-ssa-dce.c (mark_operand_necessary): Likewise.
26939         * tree-ssa-dom.c (pass_dominator::execute): Likewise.
26940         (record_equivalences_from_stmt): Likewise.
26941         * tree-ssa-dse.c (compute_trims): Likewise.
26942         (delete_dead_call): Likewise.
26943         (delete_dead_assignment): Likewise.
26944         * tree-ssa-forwprop.c (forward_propagate_into_gimple_cond): Likewise.
26945         (forward_propagate_into_cond): Likewise.
26946         (pass_forwprop::execute): Likewise.
26947         * tree-ssa-ifcombine.c (ifcombine_ifandif): Likewise.
26948         * tree-ssa-loop-im.c (invariantness_dom_walker::before_dom_children):
26949         Likewise.
26950         (move_computations_worker): Likewise.
26951         (execute_sm): Likewise.
26952         * tree-ssa-loop-ivcanon.c (tree_estimate_loop_size): Likewise.
26953         (remove_exits_and_undefined_stmts): Likewise.
26954         (remove_redundant_iv_tests): Likewise.
26955         * tree-ssa-loop-ivopts.c (dump_use): Likewise.
26956         (adjust_iv_update_pos): Likewise.
26957         * tree-ssa-math-opts.c (bswap_replace): Likewise.
26958         * tree-ssa-phiopt.c (factor_out_conditional_conversion): Likewise.
26959         (value_replacement): Likewise.
26960         * tree-ssa-phiprop.c (phiprop_insert_phi): Likewise.
26961         * tree-ssa-pre.c (print_pre_expr): Likewise.
26962         (get_representative_for): Likewise.
26963         (create_expression_by_pieces): Likewise.
26964         (insert_into_preds_of_block): Likewise.
26965         (eliminate_insert): Likewise.
26966         (eliminate_dom_walker::before_dom_children): Likewise.
26967         (eliminate): Likewise.
26968         (remove_dead_inserted_code): Likewise.
26969         * tree-ssa-propagate.c (substitute_and_fold): Likewise.
26970         * tree-ssa-reassoc.c (get_rank): Likewise.
26971         (eliminate_duplicate_pair): Likewise.
26972         (eliminate_plus_minus_pair): Likewise.
26973         (eliminate_not_pairs): Likewise.
26974         (undistribute_ops_list): Likewise.
26975         (eliminate_redundant_comparison): Likewise.
26976         (update_range_test): Likewise.
26977         (optimize_range_tests_var_bound): Likewise.
26978         (optimize_vec_cond_expr): Likewise.
26979         (rewrite_expr_tree): Likewise.
26980         (rewrite_expr_tree_parallel): Likewise.
26981         (linearize_expr): Likewise.
26982         (break_up_subtract): Likewise.
26983         (linearize_expr_tree): Likewise.
26984         (attempt_builtin_powi): Likewise.
26985         (attempt_builtin_copysign): Likewise.
26986         (transform_stmt_to_copy): Likewise.
26987         (transform_stmt_to_multiply): Likewise.
26988         (dump_ops_vector): Likewise.
26989         * tree-ssa-sccvn.c (vn_nary_build_or_lookup_1): Likewise.
26990         (print_scc): Likewise.
26991         (set_ssa_val_to): Likewise.
26992         (visit_reference_op_store): Likewise.
26993         (visit_use): Likewise.
26994         (sccvn_dom_walker::before_dom_children): Likewise.
26995         (run_scc_vn): Likewise.
26996         * tree-ssa-scopedtables.c (avail_exprs_stack::lookup_avail_expr):
26997         Likewise.
26998         (expr_hash_elt::print): Likewise.
26999         (const_and_copies::pop_to_marker): Likewise.
27000         (const_and_copies::record_const_or_copy_raw): Likewise.
27001         * tree-ssa-structalias.c (compute_dependence_clique): Likewise.
27002         * tree-ssa-uninit.c (collect_phi_def_edges): Likewise.
27003         (dump_predicates): Likewise.
27004         (find_uninit_use): Likewise.
27005         (warn_uninitialized_phi): Likewise.
27006         (pass_late_warn_uninitialized::execute): Likewise.
27007         * tree-ssa.c (verify_vssa): Likewise.
27008         (verify_ssa): Likewise.
27009         (maybe_optimize_var): Likewise.
27010         * tree-vrp.c (dump_value_range): Likewise.
27011         (dump_all_value_ranges): Likewise.
27012         (dump_asserts_for): Likewise.
27013         (register_edge_assert_for_2): Likewise.
27014         (vrp_visit_cond_stmt): Likewise.
27015         (vrp_visit_switch_stmt): Likewise.
27016         (vrp_visit_stmt): Likewise.
27017         (vrp_visit_phi_node): Likewise.
27018         (simplify_cond_using_ranges_1): Likewise.
27019         (fold_predicate_in): Likewise.
27020         (evrp_dom_walker::before_dom_children): Likewise.
27021         (evrp_dom_walker::push_value_range): Likewise.
27022         (evrp_dom_walker::pop_value_range): Likewise.
27023         (execute_early_vrp): Likewise.
27025 2017-05-16  Richard Biener  <rguenther@suse.de>
27027         * dwarf2out.c (loc_list_from_tree_1): Do not create
27028         DW_OP_GNU_variable_value for DECL_IGNORED_P decls.
27030 2017-05-16  Richard Biener  <rguenther@suse.de>
27032         * dwarf2out.c (resolve_variable_value_in_expr): Lookup DIE
27033         just generated.
27034         (note_variable_value_in_expr): If we resolved the decl ref
27035         do not push to the stack.
27037 2017-05-16  Matthew Wahab  <matthew.wahab@arm.com>
27039         * config/arm/arm_neon.h (vadd_f16): Use standard arithmetic
27040         operations in fast-math mode.
27041         (vaddq_f16): Likewise.
27042         (vmul_f16): Likewise.
27043         (vmulq_f16): Likewise.
27044         (vsub_f16): Likewise.
27045         (vsubq_f16): Likewise.
27046         * config/arm/neon.md (add<mode>3): New.
27047         (sub<mode>3): New.
27048         (fma:<VH:mode>3): New.  Also remove outdated comment.
27049         (mul<mode>3): New.
27051 2017-05-16  Martin Liska  <mliska@suse.cz>
27053         PR ipa/79849.
27054         PR ipa/79850.
27055         * ipa-devirt.c (warn_types_mismatch): Fix typo.
27056         (odr_types_equivalent_p): Likewise.
27058 2017-05-15  Sylvestre Ledru  <sylvestre@debian.org>
27060         * plugin.c (try_init_one_plugin): Fix ressource leaks (CID 726637).
27062 2017-05-15  Uros Bizjak  <ubizjak@gmail.com>
27064         PR target/80425
27065         * config/i386.i386.md (*zero_extendsidi2): Do not penalize
27066         non-interunit SSE move alternatives with '?'.
27067         (zero-extendsidi peephole2): New peephole to skip intermediate
27068         general register in SSE zero-extend sequence.
27070 2017-05-15  Jeff Law  <law@redhat.com>
27072         * reorg.c (relax_delay_slots): Create a new variable to hold
27073         the temporary target rather than clobbering TARGET_LABEL.
27075         * config/tilegx/tilegx.c (tilegx_expand_unaligned_load): Add
27076         missing argument to extract_bit_field call.
27077         * config/tilepro/tilepro.c (tilepro_expand_unaligned_load): Likewise.
27079 2017-05-15  Martin Liska  <mliska@suse.cz>
27081         PR driver/31468
27082         * gcc.c (process_command): Do not allow empty argument of -o option.
27084 2017-05-15  Renlin Li  <renlin.li@arm.com>
27086         * config/aarch64/aarch64-protos.h (aarch64_expand_call): Declare.
27087         * config/aarch64/aarch64.c (aarch64_expand_call): Define.
27088         * config/aarch64/constraints.md (Usf): Add long call check.
27089         * config/aarch64/aarch64.md (call): Use aarch64_expand_call.
27090         (call_value): Likewise.
27091         (sibcall): Likewise.
27092         (sibcall_value): Likewise.
27093         (call_insn): New.
27094         (call_value_insn): New.
27095         (sibcall_insn): Update rtx pattern.
27096         (sibcall_value_insn): Likewise.
27097         (call_internal): Remove.
27098         (call_value_internal): Likewise.
27099         (sibcall_internal): Likewise.
27100         (sibcall_value_internal): Likewise.
27101         (call_reg): Likewise.
27102         (call_symbol): Likewise.
27103         (call_value_reg): Likewise.
27104         (call_value_symbol): Likewise.
27106 2017-05-14  Krister Walfridsson  <krister.walfridsson@gmail.com>
27108         PR target/80600
27109         * config/netbsd.h (NETBSD_LIBGCC_SPEC): Always add -lgcc.
27111 2017-05-14  Uros Bizjak  <ubizjak@gmail.com>
27113         * config/i386.i386.c (ix86_cc_modes_compatible): CCNOmode is
27114         compatible with CCGOCmode and with CCZmode.
27116 2017-05-14  Martin Sebor  <msebor@redhat.com>
27118         PR middle-end/77671
27119         * gimple-fold.c (gimple_fold_builtin_sprintf): Make extern.
27120         (gimple_fold_builtin_snprintf): Same.
27121         * gimple-fold.h (gimple_fold_builtin_sprintf): Declare.
27122         (gimple_fold_builtin_snprintf): Same.
27123         * gimple-ssa-sprintf.c (get_format_string): Correct the detection
27124         of character types.
27125         (is_call_safe): New function.
27126         (try_substitute_return_value): Call it.
27127         (try_simplify_call): New function.
27128         (pass_sprintf_length::handle_gimple_call): Call it.
27130 2017-05-14  Martin Sebor  <msebor@redhat.com>
27132         PR middle-end/80669
27133         * builtins.c (expand_builtin_stpncpy): Simplify.
27135 2017-05-14  Daniel Santos  <daniel.santos@pobox.com>
27137         * config/i386/i386.opt: Add option -mcall-ms2sysv-xlogues.
27138         * config/i386/i386.h
27139         (x86_64_ms_sysv_extra_clobbered_registers): Change type to unsigned.
27140         (NUM_X86_64_MS_CLOBBERED_REGS): New macro.
27141         (struct machine_function): Add new members call_ms2sysv,
27142         call_ms2sysv_pad_in, call_ms2sysv_pad_out and call_ms2sysv_extra_regs.
27143         (struct machine_frame_state): New fields sp_realigned and
27144         sp_realigned_offset.
27145         * config/i386/i386.c
27146         (enum xlogue_stub): New enum.
27147         (enum xlogue_stub_sets): New enum.
27148         (class xlogue_layout): New class.
27149         (struct ix86_frame): New fields stack_realign_allocate_offset,
27150         stack_realign_offset and outlined_save_offset.  Modify comments to
27151         detail stack layout when using out-of-line stubs.
27152         (ix86_target_string): Add -mcall-ms2sysv-xlogues option.
27153         (ix86_option_override_internal): Add sorry() for TARGET_SEH and
27154         -mcall-ms2sysv-xlogues.
27155         (stub_managed_regs): New static variable.
27156         (ix86_save_reg): Add new parameter ignore_outlined to optionally omit
27157         registers managed by out-of-line stub.
27158         (disable_call_ms2sysv_xlogues): New function.
27159         (ix86_compute_frame_layout): Modify re-alignment calculations, disable
27160         m->call_ms2sysv when appropriate and compute frame layout for
27161         out-of-line stubs.
27162         (sp_valid_at, fp_valid_at): New inline functions.
27163         (choose_basereg): New function.
27164         (choose_baseaddr): Add align parameter, use choose_basereg and modify
27165         all callers.
27166         (ix86_emit_save_reg_using_mov, ix86_emit_restore_sse_regs_using_mov):
27167         Use align parameter of choose_baseaddr to generated aligned SSE movs
27168         when possible.
27169         (pro_epilogue_adjust_stack): Modify to track
27170         machine_frame_state::sp_realigned.
27171         (ix86_nsaved_regs): Modify to accommodate changes to ix86_save_reg.
27172         (ix86_nsaved_sseregs): Likewise.
27173         (ix86_emit_save_regs): Likewise.
27174         (ix86_emit_save_regs_using_mov): Likewise.
27175         (ix86_emit_save_sse_regs_using_mov): Likewise.
27176         (get_scratch_register_on_entry): Likewise.
27177         (gen_frame_set): New function.
27178         (gen_frame_load): Likewise.
27179         (gen_frame_store): Likewise.
27180         (emit_outlined_ms2sysv_save): Likewise.
27181         (emit_outlined_ms2sysv_restore): Likewise.
27182         (ix86_expand_prologue): Modify stack re-alignment code and call
27183         emit_outlined_ms2sysv_save when appropriate.
27184         (ix86_emit_leave): Clear machine_frame_state::sp_realigned.  Add
27185         parameter rtx_insn *insn, which allows the function to be used to only
27186         generate the notes.
27187         (ix86_expand_epilogue): Modify validity checks of frame and stack
27188         pointers, and call emit_outlined_ms2sysv_restore when appropriate.
27189         (ix86_expand_call): Modify to enable m->call_ms2sysv when appropriate.
27190         * config/i386/predicates.md
27191         (save_multiple): New predicate.
27192         (restore_multiple): Likewise.
27193         * config/i386/sse.md
27194         (save_multiple<mode>): New pattern.
27195         (save_multiple_realign<mode>): Likewise.
27196         (restore_multiple<mode>): Likewise.
27197         (restore_multiple_and_return<mode>): Likewise.
27198         (restore_multiple_leave_return<mode>): Likewise.
27199         * Makefile.in: Export HOSTCXX and HOSTCXXFLAGS to site.exp
27201 2017-05-14  Julia Koval  <julia.koval@intel.com>
27203         * config/i386/i386-builtin-types.def (VOID_FTYPE_INT_INT64): New type.
27204         * config/i386/i386-builtin.def (__builtin_ia32_xgetbv)
27205         (__builtin_ia32_xsetbv): New builtins.
27206         * config/i386/i386.c (ix86_expand_special_args_builtin):
27207         Process new types.
27208         (ix86_expand_builtin): Special expand for new intrinsics.
27209         * config/i386/i386.md (UNSPECV_XGETBV, UNSPECV_XSETBV): New.
27210         (xsetbv, xsetbv_rex64, xgetbv, xgetbv_rex64): New insn patterns.
27211         * config/i386/xsaveintrin.h (_xsetbv, _getbv): New intrinsics.
27213 2017-05-13  Trevor Saunders  <tbsaunde+gcc@tbsaunde.org>
27215         * cfganal.c (inverted_post_order_compute): Change argument type
27216         to vec *.
27217         * cfganal.h (inverted_post_order_compute): Adjust prototype.
27218         * df-core.c (rest_of_handle_df_initialize): Adjust.
27219         (rest_of_handle_df_finish): Likewise.
27220         (df_analyze_1): Likewise.
27221         (df_analyze): Likewise.
27222         (loop_inverted_post_order_compute): Change argument to be a vec *.
27223         (df_analyze_loop): Adjust.
27224         (df_get_n_blocks): Likewise.
27225         (df_get_postorder): Likewise.
27226         * df.h (struct df_d): Change field to be a vec.
27227         * lcm.c (compute_laterin): Adjust.
27228         (compute_available): Likewise.
27229         * lra-lives.c (lra_create_live_ranges_1): Likewise.
27230         * tree-ssa-dce.c (remove_dead_stmt): Likewise.
27231         * tree-ssa-pre.c (compute_antic): Likewise.
27233 2017-05-13  Trevor Saunders  <tbsaunde+gcc@tbsaunde.org>
27235         * cfganal.c (connect_infinite_loops_to_exit): Adjust.
27236         (depth_first_search::depth_first_search): Change structure init
27237         function to this constructor.
27238         (depth_first_search::add_bb): Rename function to this member.
27239         (depth_first_search::execute): Likewise.
27240         (flow_dfs_compute_reverse_finish): Adjust.
27242 2017-05-13  Trevor Saunders  <tbsaunde+gcc@tbsaunde.org>
27244         * ddg.c (find_nodes_on_paths): Use auto_sbitmap.
27245         (longest_simple_path): Likewise.
27246         * shrink-wrap.c (spread_components): Likewise.
27247         (disqualify_problematic_components): Likewise.
27248         (emit_common_heads_for_components): Likewise.
27249         (emit_common_tails_for_components): Likewise.
27250         (insert_prologue_epilogue_for_components): Likewise.
27252 2017-05-13  Trevor Saunders  <tbsaunde+gcc@tbsaunde.org>
27254         * tree-ssa-dse.c (dse_dom_walker): Make m_live_byes a
27255         auto_sbitmap.
27257 2017-05-13  Trevor Saunders  <tbsaunde+gcc@tbsaunde.org>
27259         * df-core.c (df_set_blocks): Start using auto_bitmap.
27260         (df_compact_blocks): Likewise.
27261         * df-problems.c (df_rd_confluence_n): Likewise.
27262         * df-scan.c (df_insn_rescan_all): Likewise.
27263         (df_process_deferred_rescans): Likewise.
27264         (df_update_entry_block_defs): Likewise.
27265         (df_update_exit_block_uses): Likewise.
27266         (df_entry_block_bitmap_verify): Likewise.
27267         (df_exit_block_bitmap_verify): Likewise.
27268         (df_scan_verify): Likewise.
27269         * lra-constraints.c (lra_constraints): Likewise.
27270         (undo_optional_reloads): Likewise.
27271         (lra_undo_inheritance): Likewise.
27272         * lra-remat.c (calculate_gen_cands): Likewise.
27273         (do_remat): Likewise.
27274         * lra-spills.c (assign_spill_hard_regs): Likewise.
27275         (spill_pseudos): Likewise.
27276         * tree-ssa-pre.c (bitmap_set_and): Likewise.
27277         (bitmap_set_subtract_values): Likewise.
27279 2017-05-13  Trevor Saunders  <tbsaunde+gcc@tbsaunde.org>
27281         * haifa-sched.c (estimate_shadow_tick): Replace manual bitmap
27282         management with auto_bitmap.
27283         (fix_inter_tick): Likewise.
27284         (fix_recovery_deps): Likewise.
27285         * ira.c (add_store_equivs): Likewise.
27286         (find_moveable_pseudos): Likewise.
27287         (split_live_ranges_for_shrink_wrap): Likewise.
27288         * print-rtl.c (rtx_reuse_manager::rtx_reuse_manager): Likewise.
27289         (rtx_reuse_manager::seen_def_p): Likewise.
27290         (rtx_reuse_manager::set_seen_def): Likewise.
27291         * print-rtl.h (class rtx_reuse_manager): Likewise.
27293 2017-05-13  Trevor Saunders  <tbsaunde+gcc@tbsaunde.org>
27295         * bt-load.c (combine_btr_defs): Use auto_bitmap to manage bitmap
27296         lifetime.
27297         (migrate_btr_def): Likewise.
27298         * cfgloop.c (get_loop_body_in_bfs_order): Likewise.
27299         * df-core.c (loop_post_order_compute): Likewise.
27300         (loop_inverted_post_order_compute): Likewise.
27301         * hsa-common.h: Likewise.
27302         * hsa-gen.c (hsa_bb::~hsa_bb): Likewise.
27303         * init-regs.c (initialize_uninitialized_regs): Likewise.
27304         * ipa-inline.c (resolve_noninline_speculation): Likewise.
27305         (inline_small_functions): Likewise.
27306         * ipa-reference.c (ipa_reference_write_optimization_summary): Likewise.
27307         * ira.c (combine_and_move_insns): Likewise.
27308         (build_insn_chain): Likewise.
27309         * loop-invariant.c (find_invariants): Likewise.
27310         * lower-subreg.c (propagate_pseudo_copies): Likewise.
27311         * predict.c (tree_predict_by_opcode): Likewise.
27312         (predict_paths_leading_to): Likewise.
27313         (predict_paths_leading_to_edge): Likewise.
27314         (estimate_loops_at_level): Likewise.
27315         (estimate_loops): Likewise.
27316         * shrink-wrap.c (try_shrink_wrapping): Likewise.
27317         (spread_components): Likewise.
27318         * tree-cfg.c (remove_edge_and_dominated_blocks): Likewise.
27319         * tree-loop-distribution.c (rdg_build_partitions): Likewise.
27320         * tree-predcom.c (tree_predictive_commoning_loop): Likewise.
27321         * tree-ssa-coalesce.c (coalesce_ssa_name): Likewise.
27322         * tree-ssa-phionlycprop.c (pass_phi_only_cprop::execute): Likewise.
27323         * tree-ssa-pre.c (remove_dead_inserted_code): Likewise.
27324         * tree-ssa-sink.c (nearest_common_dominator_of_uses): Likewise.
27325         * tree-ssa-threadupdate.c (compute_path_counts): Likewise.
27326         (mark_threaded_blocks): Likewise.
27327         (thread_through_all_blocks): Likewise.
27328         * tree-ssa.c (verify_ssa): Likewise.
27329         (execute_update_addresses_taken): Likewise.
27330         * tree-ssanames.c (verify_ssaname_freelists): Likewise.
27332 2017-05-13  Trevor Saunders  <tbsaunde+gcc@tbsaunde.org>
27334         * cfganal.c (mark_dfs_back_edges): Replace manual stack with
27335         auto_vec.
27336         (post_order_compute): Likewise.
27337         (inverted_post_order_compute): Likewise.
27338         (pre_and_rev_post_order_compute_fn): Likewise.
27340 2017-05-13  Trevor Saunders  <tbsaunde+gcc@tbsaunde.org>
27342         * genrecog.c (int_set::int_set): Explicitly construct our
27343         auto_vec base class.
27344         * vec.h (auto_vec::auto_vec): New constructor.
27346 2017-05-13  Trevor Saunders  <tbsaunde+gcc@tbsaunde.org>
27348         * bitmap.h (class auto_bitmap): New constructor taking
27349         bitmap_obstack * argument.
27351 2017-05-13  Trevor Saunders  <tbsaunde+gcc@tbsaunde.org>
27353         * bitmap.h (class auto_bitmap): Change type of m_bits to
27354         bitmap_head, and adjust ctor / dtor and member operators.
27356 2017-05-13  Uros Bizjak  <ubizjak@gmail.com>
27358         * compare-elim.c (equivalent_reg_at_start): Return NULL_RTX
27359         when returned register mode doesn't match original mode.
27361 2017-05-12  Jeff Law  <law@redhat.com>
27362             Jakub Jelinek  <jakub@redhat.com>
27364         * config/mn10300/mn10300.c (mn10300_match_ccmode): Fix where
27365         we look for cc setter after the compare-elim changes.
27366         * config/mn10300/mn10300.md (addsi3_flags): Fix order of patterns
27367         within the vector to match what compare-elim now expects.
27368         (subsi3_flags, andsi3_flags, iorsi3_flags): Likewise.
27369         (xorsi3_flags, one_cmplsi2_flags): Likewise.
27371         * config/rx/rx.c (rx_match_ccmode): Fix where we look cc setter
27372         after the compare-elim changes.
27373         * config/rx/rx.md (abssi2_flags): Fix order of patterns within
27374         the vector to match what compare-elim now expects.
27375         (addsi3_flags, adc_flags, addsi3_flags peepholes): Likewise.
27376         (andsi3_flags, negsi2_flags, one_cmplsi2_flags): Likewise.
27377         (iorsi3_flags, rotlsi3_flags, rotrsi3_flags): Likewise.
27378         (ashrsi3_flags, lshrsi3_flags, ashlsi3_flags): Likewise.
27379         (ssaddsi3, subsi3_flags, sbb_flags, xorsi3_flags): Likewise.
27381         * config/visium/visium.c (single_set_and_flags): Fix where
27382         we look for cc setter after the compare-elim changes.
27383         * config/visium/visium.md (flags_subst_logic): Fix order of patterns
27384         with the vector to match what compare-elim now expects.
27385         (flags_subst_arith, add<mode>3_insn_set_carry): Likewise.
27386         (add<mode>3_insn_set_overflow, addsi3_insn_set_carry): Likewise.
27387         (addsi3_insn_set_overflow, sub<mode>3_insn_set_carry): Likewise.
27388         (sub<mode>3_insn_set_overflow, subsi3_insn_set_carry): Likewise.
27389         (subsi3_insn_set_overflow, negsi2_insn_set_carry): Likewise.
27390         (neg<mode>2_insn_set_overflow): Likewise.
27392 2017-05-12  Jim Wilson  <jim.wilson@linaro.org>
27394         PR middle-end/79794
27395         * expmed.c (extract_bit_field_1): Add alt_rtl argument.  Before
27396         maybe_expand_insn call, set ops[0].target.  If still set after call,
27397         set alt_rtl.  Add extra arg to recursive calls.
27398         (extract_bit_field): Add alt_rtl argument.  Pass to
27399         extract_bit_field.
27400         * expmed.h (extract_bit_field): Fix prototype.
27401         * expr.c (emit_group_load_1, copy_blkmode_from_reg)
27402         (copy_blkmode_to_reg, read_complex_part, store_field): Pass extra NULL
27403         to extract_bit_field_calls.
27404         (expand_expr_real_1): Pass alt_rtl to expand_expr_real instead of 0.
27405         Pass alt_rtl to extract_bit_field calls.
27406         * calls.c (store_unaligned_arguments_into_psuedos)
27407         load_register_parameters): Pass extra NULL to extract_bit_field calls.
27408         * optabs.c (maybe_legitimize_operand): Clear op->target when call
27409         gen_reg_rtx.
27410         * optabs.h (struct expand_operand): Add target bitfield.
27412 2017-05-12  Uros Bizjak  <ubizjak@gmail.com>
27414         * compare-elim.c (try_eliminate_compare): Canonicalize
27415         operation with embedded compare to
27416         [(set (reg:CCM) (compare:CCM (operation) (immediate)))
27417          (set (reg) (operation)].
27419         * config/i386/i386.c (TARGET_FLAGS_REGNUM): New define.
27421 2017-05-12  Uros Bizjak  <ubizjak@gmail.com>
27423         PR target/80723
27424         * config/i386/i386.c (ix86_rtx_cost) [case PLUS]: Ignore the
27425         cost of adding a carry flag for ADC instruction.
27426         [case MINUS]: Ignore the cost of subtracting a carry flag
27427         for SBB instruction.
27429 2017-05-12  Steven Munroe  <munroesj@gcc.gnu.org>
27431         * config.gcc (powerpc*-*-*): Add bmi2intrin.h, bmiintrin.h,
27432         and x86intrin.h
27433         * config/rs6000/bmiintrin.h: New file.
27434         * config/rs6000/bmi2intrin.h: New file.
27435         * config/rs6000/x86intrin.h: New file.
27437 2017-05-12  Jeff Law  <law@redhat.com>
27439         * tree-vrp.c (vrp_dom_walker::before_dom_children): Push unwinding
27440         markers.
27442 2017-05-12  Peter Bergner  <bergner@vnet.ibm.com>
27444         PR middle-end/80707
27445         * tree-cfg.c: Remove cfg edges of unreachable case statements.
27447 2017-05-12  Will Schmidt  <will_schmidt@vnet.ibm.com>
27449         * config/rs6000/rs6000.c (rs6000_gimple_fold_builtin): Add handling for
27450         early expansion of vector divide builtins.
27451         (builtin_function_type): Add VSX_BUILTIN_UDIV_V2DI to the list of
27452         builtins identified as having unsigned arguments.
27454 2017-05-12  Will Schmidt  <will_schmidt@vnet.ibm.com>
27456         * config/rs6000/rs6000.c (gimple-fold.h): New #include.
27457         (rs6000_gimple_fold_builtin): Add handling for early GIMPLE
27458         expansion of vector logical operations (and, andc, or, xor,
27459         nor, orc, nand).
27461 2017-05-12  Will Schmidt  <will_schmidt@vnet.ibm.com>
27463         * gimple-fold.c (create_tmp_reg_or_ssa_name): Remove static declaration.
27464         * gimple-fold.h (create_tmp_reg_or_ssa_name): New prototype.
27466 2017-05-12  Will Schmidt  <will_schmidt@vnet.ibm.com>
27468         * config/rs6000/rs6000.c (rs6000_gimple_fold_builtin): Add handling for
27469         early GIMPLE expansion of vector multiplies.
27471 2017-05-12  Prakhar Bahuguna  <prakhar.bahuguna@arm.com>
27473         * config/arm/arm.md (movsi): Add TARGET_32BIT in addition to the
27474         TARGET_HAVE_MOVT conditional.
27475         (movt splitter): Likewise.
27477 2017-05-12  Richard Biener  <rguenther@suse.de>
27479         * tree-ssa-sccvn.h (has_VN_INFO): Declare.
27480         * tree-ssa-pre.c (eliminate_dom_walker::before_dom_children):
27481         Fold all stmts not inplace.
27483 2017-05-12  Richard Biener  <rguenther@suse.de>
27485         PR tree-optimization/80713
27486         * tree-ssa-pre.c (remove_dead_inserted_code): Clear
27487         inserted_exprs bit for not removed stmts.
27489 2017-05-12  Thomas Schwinge  <thomas@codesourcery.com>
27491         PR middle-end/69921
27492         * tree-parloops.c (create_parallel_loop): Set "oacc kernels
27493         parallelized" attribute for parallelized OpenACC kernels.
27494         * omp-offload.c (execute_oacc_device_lower): Use it.
27496         * omp-expand.c (expand_omp_target) <GF_OMP_TARGET_KIND_OACC_KERNELS>:
27497         Set "oacc kernels" attribute.
27498         * omp-general.c (oacc_set_fn_attrib): Remove is_kernel formal
27499         parameter.  Adjust all users.
27500         (oacc_fn_attrib_kernels_p): Remove function.
27501         * omp-offload.c (execute_oacc_device_lower): Look for "oacc
27502         kernels" attribute instead of calling oacc_fn_attrib_kernels_p.
27503         * tree-ssa-loop.c (gate_oacc_kernels): Likewise.
27504         * tree-parloops.c (create_parallel_loop): If oacc_kernels_p,
27505         assert "oacc kernels" attribute is set.
27507 2017-05-11  Carl Love  <cel@us.ibm.com>
27509         * config/rs6000/rs6000-c: Add support for built-in functions
27510         vector unsigned char vec_popcnt (vector signed char)
27511         vector unsigned char vec_popcnt (vector unsigned char)
27512         vector unsigned short vec_popcnt (vector signed short)
27513         vector unsigned short vec_popcnt (vector unsigned short)
27514         vector unsigned int vec_popcnt (vector signed int)
27515         vector unsigned int vec_popcnt (vector unsigned int)
27516         vector unsigned long long vec_popcnt (vector signed long long)
27517         vector unsigned long long vec_popcnt (vector unsigned long long)
27518         vector signed long long vec_slo (vector signed long long,
27519                                          vector signed char)
27520         vector signed long long vec_slo (vector signed long long,
27521                                          vector unsigned char)
27522         vector unsigned long long vec_slo (vector unsigned long long,
27523                                            vector signed char)
27524         vector unsigned long long vec_slo (vector unsigned long long,
27525                                            vector unsigned char)
27526         * config/rs6000/rs6000-builtin.def: Add definitions for VPOPCNTUB,
27527         VPOPCNTUH, VPOPCNTUW, and VPOPCNTUD overloads.
27528         * config/rs6000/altivec.h: Add define for vec_popcnt, vec_popcntb,
27529         vec_popcnth, vec_popcntw and vec_popcntd built-in functions.
27530         * doc/extend.texi: Update the built-in documentation file for the
27531         new built-in functions.
27533 2017-05-11  Michael Meissner  <meissner@linux.vnet.ibm.com>
27535         * attribs.h (sorted_attr_string): Move machine independent
27536         functions for target clone support from the i386 port to common
27537         code.  Rename ix86_function_versions to common_function_versions.
27538         Rename make_name to make_unique_name.
27539         (common_function_versions): Likewise.
27540         (make_unique_name): Likewise.
27541         (make_dispatcher_decl): Likewise.
27542         (is_function_default_version): Likewise.
27543         * attribs.c (attr_strcmp): Likewise.
27544         (sorted_attr_string): Likewise.
27545         (common_function_versions): Likewise.
27546         (make_unique_name): Likewise.
27547         (make_dispatcher_decl): Likewise.
27548         (is_function_default_version): Likewise.
27549         * config/i386/i386.c (attr_strcmp): Likewise.
27550         (sorted_attr_string): Likewise.
27551         (ix86_function_versions): Likewise.
27552         (make_name): Likewise.
27553         (make_dispatcher_decl): Likewise.
27554         (is_function_default_version): Likewise.
27555         (TARGET_OPTION_FUNCTION_VERSIONS): Update target function hook.
27557 2017-05-11  Bill Schmidt  <wschmidt@linux.vnet.ibm.com>
27559         PR target/80695
27560         * config/rs6000/rs6000.c (rs6000_builtin_vectorization_cost):
27561         Account for direct move costs for vec_construct of integer
27562         vectors.
27564 2017-05-11  Uros Bizjak  <ubizjak@gmail.com>
27566         PR target/80706
27567         * config/i386/sync.md (UNSPEC_LDX_ATOMIC): New unspec.
27568         (UNSPEC_STX_ATOMIC): Ditto.
27569         (loaddi_via_sse): New insn.
27570         (storedi_via_sse): Ditto.
27571         (atomic_loaddi_fpu): Emit loaddi_via_sse and storedi_via_sse.
27572         Update corresponding peephole2 patterns.
27573         (atomic_storedi_fpu): Ditto.
27575 2017-05-11  Julia Koval  <julia.koval@intel.com>
27577         * config/i386/avx512fintrin.h (_mm_mask_rsqrt14_sd)
27578         (_mm_maskz_rsqrt14_sd, _mm_mask_rsqrt14_ss, _mm_maskz_rsqrt14_ss):
27579         New intrinsics.
27580         * config/i386/i386-builtin.def (__builtin_ia32_rsqrt14sd_mask)
27581         (__builtin_ia32_rsqrt14ss_mask): New builtins.
27582         * config/i386/sse.md (rsqrt14_<mode>_mask): New pattern.
27584 2017-05-11  Nathan Sidwell  <nathan@acm.org>
27586         * graphite-poly.c: Include dumpfile.h.
27588         * dumpfle.h (dump_function): Declare here ...
27589         * tree-dump.h (dump_function): ... not here.
27590         * dumpfile.c: #include tree-cfg.h.
27591         (dump_function): Move here from ...
27592         * tree-dump.c (dump_function): ... here.
27593         * gimplify.c: #include splay-tree.h, not tree-dump.h.
27594         * graphite-poly.c: Don't include tree-dump.h.
27595         * cgraphclones.c: Include dumpfile.h not tree-dump.h.
27596         * print-tree.c: Likewise.
27597         * stor-layout.c: Likewise.
27598         * tree-nested.c: Likewise.
27600         * dumpfile.c (dump_start): Use TDF_FLAGS.
27601         (dump_enable_all): Fix TDF_KIND check thinko.
27603 2017-05-11  Kelvin Nilsen  <kelvin@gcc.gnu.org>
27605         * config/rs6000/rs6000-c.c (altivec_overloaded_builtins): Add
27606         array entries to represent two legal parameterizations of the
27607         overloaded __builtin_cmpb function, as represented by the
27608         P6_OV_BUILTIN_CMPB constant.
27609         (altivec_resolve_overloaded_builtin): Add special case handling
27610         for the __builtin_cmpb function, as represented by the
27611         P6_OV_BUILTIN_CMPB constant.
27612         * config/rs6000/rs6000-builtin.def (BU_P6_2): New macro.
27613         (BU_P6_64BIT_2): New macro.
27614         (BU_P6_OVERLOAD_2): New macro
27615         (CMPB_32): Add 32-bit compare-bytes support for 32-bit only targets.
27616         (CMPB): Add 64-bit compare-bytes support for 32-bit and 64-bit targets.
27617         (CMPB): Add overload support to represent both 32-bit and 64-bit
27618         compare-bytes function.
27619         * config/rs6000/rs6000.c (rs6000_builtin_mask_calculate): Add
27620         support for TARGET_CMPB.
27621         * config/rs6000/rs6000.h: Add support for RS6000_BTM_CMPB.
27622         * doc/extend.texi (PowerPC AltiVec Built-in Functions): Add
27623         documentation of the __builtin_cmpb overloaded built-in function.
27625 2017-05-11  Richard Biener  <rguenther@suse.de>
27627         PR tree-optimization/80705
27628         * tree-vect-data-refs.c (vect_analyze_data_refs): DECL_NONALIASED
27629         bases are not vectorizable.
27631 2017-05-11  Bin Cheng  <bin.cheng@arm.com>
27633         * tree-ssa-loop-ivopts.c (determine_set_costs): Skip non-interger
27634         when counting register pressure.
27636 2017-05-11  Bin Cheng  <bin.cheng@arm.com>
27638         * tree-ssa-loop-ivopts.c (compare_cost_pair): New.
27639         (iv_ca_more_deps): Renamed to ...
27640         (iv_ca_compare_deps): ... this.
27641         (iv_ca_extend): Extend iv_ca if NEW_CP is cheaper than OLD_CP.
27643 2017-05-11  Bin Cheng  <bin.cheng@arm.com>
27645         * tree-ssa-loop-ivopts.c (find_interesting_uses): Move inv vars dump
27646         to ...
27647         (determine_group_iv_costs): ... here.
27648         (find_inv_vars_cb): Record inv var if it's not recorded before.
27650 2017-05-11  Bin Cheng  <bin.cheng@arm.com>
27652         * tree-ssa-loop-ivopts.c (allow_ip_end_pos_p): Refine comments.
27653         (get_shiftadd_cost): Ditto.
27655 2017-05-11  Bin Cheng  <bin.cheng@arm.com>
27657         * tree-ssa-address.c: Include header file.
27658         (move_hint_to_base): Return TRUE if BASE_HINT is moved to memory
27659         address.
27660         (add_to_parts): Refactor.
27661         (addr_to_parts): New parameter.  Update use of move_hint_to_base.
27662         (create_mem_ref): Update use of addr_to_parts.  Re-associate addr
27663         in new order.
27665 2017-05-11  Bin Cheng  <bin.cheng@arm.com>
27667         PR tree-optimization/53090
27668         * tree-ssa-loop-ivopts.c (enum comp_iv_rewrite): New enum value
27669         COMP_IV_EXPR_2.
27670         (extract_cond_operands): Detect condition with IV on both sides
27671         and return COMP_IV_EXPR_2.
27672         (find_interesting_uses_cond): Add iv_use for both IVs in condition.
27673         (rewrite_use_compare): Simplify by removing call to function
27674         extract_cond_operands.
27676 2017-05-11  Bin Cheng  <bin.cheng@arm.com>
27678         * tree-ssa-loop-ivopts.c (enum comp_iv_rewrite): New.
27679         (extract_cond_operands): Detect condition comparing against non-
27680         invariant bound and return appropriate enum value.
27681         (find_interesting_uses_cond): Update use of extract_cond_operands.
27682         Handle its return value accordingly.
27683         (determine_group_iv_cost_cond, rewrite_use_compare): Ditto.
27685 2017-05-11  Bin Cheng  <bin.cheng@arm.com>
27687         * tree-ssa-loop-ivopts.c (rewrite_use_nonlinear_expr): Re-associate
27688         nonlinear iv_use computation in loop invariant sensitive way.
27690 2017-05-11  Bin Cheng  <bin.cheng@arm.com>
27692         * tree-ssa-loop-ivopts.c (relate_compare_use_with_all_cands): New.
27693         (find_iv_candidates): Call relate_compare_use_with_all_cands.
27695 2017-05-11  Bin Cheng  <bin.cheng@arm.com>
27697         * tree-ssa-loop-ivopts.c (struct iv_cand): New field inv_exprs.
27698         (dump_cand): Support iv_cand.inv_exprs.
27699         (add_candidate_1): Record invariant exprs in iv_cand.inv_exprs
27700         for candidates.
27701         (iv_ca_set_no_cp, iv_ca_set_cp, free_loop_data): Support
27702         iv_cand.inv_exprs.
27704 2017-05-11  Bin Cheng  <bin.cheng@arm.com>
27706         * tree-ssa-loop-ivopts.c (multiplier_allowed_in_address_p): Move
27707         from ...
27708         * tree-ssa-address.c (multiplier_allowed_in_address_p): ... to here
27709         as local function.  Include necessary header files.
27710         * tree-ssa-loop-ivopts.h (multiplier_allowed_in_address_p): Delete.
27712 2017-05-11  Bin Cheng  <bin.cheng@arm.com>
27714         * tree-ssa-loop-ivopts.c (autoinc_possible_for_pair): Simplify.
27716 2017-05-11  Bin Cheng  <bin.cheng@arm.com>
27718         * tree-ssa-loop-ivopts.c (force_expr_to_var_cost): Handle more
27719         operators: TRUNC_DIV_EXPR, BIT_AND_EXPR, BIT_IOR_EXPR, LSHIFT_EXPR,
27720         RSHIFT_EXPR and BIT_NOT_EXPR.
27722 2017-05-11  Bin Cheng  <bin.cheng@arm.com>
27724         * tree-ssa-loop-ivopts.c (get_loop_invariant_expr): Simplify.
27725         (adjust_setup_cost): New parameter supporting round up adjustment.
27726         (struct address_cost_data): Delete.
27727         (force_expr_to_var_cost): Don't bound cost with spill_cost.
27728         (split_address_cost, ptr_difference_cost): Delete.
27729         (difference_cost, compare_aff_trees, record_inv_expr): Delete.
27730         (struct ainc_cost_data): New struct.
27731         (get_address_cost_ainc): New function.
27732         (get_address_cost, get_computation_cost): Reimplement.
27733         (determine_group_iv_cost_address): Record inv_expr for all uses of
27734         a group.
27735         (determine_group_iv_cost_cond): Call get_loop_invariant_expr.
27736         (iv_ca_has_deps): Reimplemented to ...
27737         (iv_ca_more_deps): ... this.  Check if NEW_CP introduces more deps
27738         than OLD_CP.
27739         (iv_ca_extend): Call iv_ca_more_deps.
27741 2017-05-11  Bin Cheng  <bin.cheng@arm.com>
27743         * tree-ssa-address.c (struct mem_address): Move to header file.
27744         (valid_mem_ref_p, move_fixed_address_to_symbol): Make it global.
27745         * tree-ssa-address.h (struct mem_address): Move from C file.
27746         (valid_mem_ref_p, move_fixed_address_to_symbol): Declare.
27748 2017-05-11  Bin Cheng  <bin.cheng@arm.com>
27750         * tree-affine.h (aff_combination_type): New interface.
27751         (aff_combination_zero_p): Remove static.
27752         (aff_combination_const_p): New interface.
27753         (aff_combination_singleton_var_p): New interfaces.
27755 2017-05-11  Richard Biener  <rguenther@suse.de>
27757         * tree-ssa-pre.c (eliminate_dom_walker::before_dom_children):
27758         Skip unreachable blocks and destinations.
27759         (eliminate): Move stmt removal and fixup ...
27760         (fini_eliminate): ... here.  Skip inserted exprs.
27761         (pass_pre::execute): Move fini_pre after fini_eliminate.
27762         * tree-ssa-tailmerge.c: Include tree-cfgcleanup.h.
27763         (tail_merge_optimize): Run cleanup_tree_cfg if requested by
27764         PRE to get rid of dead code that has invalid SSA form and
27765         split critical edges again.
27767 2017-05-11  Bin Cheng  <bin.cheng@arm.com>
27769         * rtlanal.c (rtx_cost): Handle TRUNCATE between tieable modes.
27771 2017-05-11  Richard Biener  <rguenther@suse.de>
27773         * passes.c (execute_function_todo): Verify loops if they are
27774         said to be up-to-date.
27775         * cfgexpand.c (pass_expand::execute): Discard loops for -dx.
27776         * trans-mem.c (pass_tm_edges::execute): Mark loops for fixup.
27778 2017-05-10  John David Anglin  <danglin@gcc.gnu.org>
27780         PR target/80090
27781         * config/pa/pa.c (pa_assemble_integer): When outputting a SYMBOL_REF,
27782         handle calling assemble_external ourself.
27784         PR target/79027
27785         * config/pa/pa.c (pa_cannot_change_mode_class): Reject changes to/from
27786         modes with zero size.  Enhance comment.
27788 2017-05-10  Bill Schmidt  <wschmidt@linux.vnet.ibm.com>
27790         * config/rs6000/rs6000.c (altivec_init_builtins): Define POWER8
27791         built-ins for vec_xl and vec_xst with short and char pointer
27792         arguments.
27794 2017-05-10  Sebastian Peryt  <sebastian.peryt@intel.com>
27796         * config/i386/avx512fintrin.h (_mm_mask_max_round_sd)
27797         (_mm_maskz_max_round_sd, _mm_mask_max_round_ss)
27798         (_mm_maskz_max_round_ss, _mm_mask_min_round_sd)
27799         (_mm_maskz_min_round_sd, _mm_mask_min_round_ss)
27800         (_mm_maskz_min_round_ss): New intrinsics.
27801         * config/i386/i386-builtin-types.def (V2DF, V2DF, V2DF, V2DF, UQI, INT)
27802         (V4SF, V4SF, V4SF, V4SF, UQI, INT): New function type aliases.
27803         * config/i386/i386-builtin.def (__builtin_ia32_maxsd_mask_round)
27804         (__builtin_ia32_maxss_mask_round, __builtin_ia32_minsd_mask_round)
27805         (__builtin_ia32_minss_mask_round): New builtins.
27806         * config/i386/i386.c (V2DF_FTYPE_V2DF_V2DF_V2DF_UQI_INT)
27807         (V4SF_FTYPE_V4SF_V4SF_V4SF_UQI_INT): Handle new types.
27808         * config/i386/sse.md (<sse>_vm<code><mode>3<round_saeonly_name>):
27809         Rename to ...
27810         (<sse>_vm<code><mode>3<mask_name><round_saeonly_name>): ... this.
27811         (v<maxmin_float><ssescalarmodesuffix>\t{<round_saeonly_op3>%2, %1, %0|%0, %1, %<iptr>2<round_saeonly_op3>}):
27812         Change to ...
27813         (v<maxmin_float><ssescalarmodesuffix>\t{<round_saeonly_mask_op3>%2, %1, %0<mask_operand3>|%0<mask_operand3>, %1, %<iptr>2<round_saeonly_mask_op3>}):
27814         ... this.
27816 2017-05-10  Sebastian Peryt  <sebastian.peryt@intel.com>
27818         * config/i386/avx512fintrin.h (_mm_mask_mul_round_sd)
27819         (_mm_maskz_mul_round_sd, _mm_mask_mul_round_ss)
27820         (_mm_maskz_mul_round_ss, _mm_mask_div_round_sd)
27821         (_mm_maskz_div_round_sd, _mm_mask_div_round_ss)
27822         (_mm_maskz_div_round_ss, _mm_mask_mul_sd, _mm_maskz_mul_sd)
27823         (_mm_mask_mul_ss, _mm_maskz_mul_ss, _mm_mask_div_sd)
27824         (_mm_maskz_div_sd, _mm_mask_div_ss, _mm_maskz_div_ss): New intrinsics.
27825         * config/i386/i386-builtin-types.def (V2DF_FTYPE_V2DF_V2DF_V2DF_UQI_INT)
27826         (V4SF_FTYPE_V4SF_V4SF_V4SF_UQI_INT): New function type aliases.
27827         * config/i386/i386-builtin.def (__builtin_ia32_divsd_mask_round)
27828         (__builtin_ia32_divss_mask_round, __builtin_ia32_mulsd_mask_round)
27829         (__builtin_ia32_mulss_mask_round): New builtins.
27830         * config/i386/i386.c (V2DF_FTYPE_V2DF_V2DF_V2DF_UQI_INT)
27831         (V4SF_FTYPE_V4SF_V4SF_V4SF_UQI_INT): Handle new types.
27832         * config/i386/sse.md (<sse>_vm<multdiv_mnemonic><mode>3<round_name>):
27833         Rename to ...
27834         (<sse>_vm<multdiv_mnemonic><mode>3<mask_name><round_name>): ... this.
27835         (v<multdiv_mnemonic><ssescalarmodesuffix>\t{<round_op3>%2, %1, %0|%0, %1, %<iptr>2<round_op3>}):
27836         Change to ...
27837         (v<multdiv_mnemonic><ssescalarmodesuffix>\t{<round_mask_op3>%2, %1, %0<mask_operand3>|%0<mask_operand3>, %1, %<iptr>2<round_mask_op3>}):
27838         ... this.
27840 2017-05-10  Julia Koval  <julia.koval@intel.com>
27842         * config/i386/avxintrin.h (_mm256_set_m128, _mm256_set_m128d)
27843         (_mm256_set_m128i, _mm256_setr_m128, _mm256_setr_m128d)
27844         (_mm256_setr_m128i): New intrinsics.
27846 2017-05-10  Julia Koval  <julia.koval@intel.com>
27848         * config/i386/avx512fintrin.h (_mm_mask_rcp14_sd)
27849         (_mm_maskz_rcp14_sd, _mm_mask_rcp14_ss)
27850         (_mm_maskz_rcp14_ss): New intrinsics.
27851         * config/i386/i386-builtin.def (__builtin_ia32_rcp14sd_mask)
27852         (__builtin_ia32_rcp14ss_mask): New builtins.
27853         * config/i386/sse.md (srcp14<mode>_mask): New pattern.
27855 2017-05-10  Peter Bergner  <bergner@vnet.ibm.com>
27857         PR tree-optimization/51513
27858         * tree-cfg.c (gimple_seq_unreachable_p): New function.
27859         (assert_unreachable_fallthru_edge_p): Use it.
27860         (group_case_labels_stmt): Likewise.
27861         * tree-cfg.h: Prototype it.
27862         * stmt.c: Include cfghooks.h and tree-cfg.h.
27863         (emit_case_dispatch_table) <gap_label>: New local variable.
27864         Use it to fill dispatch table gaps.
27865         Test for default_label before updating probabilities.
27866         (expand_case) <default_label>: Remove unneeded initialization.
27867         Test for unreachable default case statement and remove its edge.
27868         Set default_label accordingly.
27869         * tree-ssa-ccp.c (optimize_unreachable): Update comment.
27871 2017-05-10  Carl Love  <cel@us.ibm.com>
27873         * config/rs6000/rs6000-c: Add support for built-in functions
27874         vector signed char      vec_neg (vector signed char)
27875         vector signed short int vec_neg (vector short int)
27876         vector signed int       vec_neg (vector signed int)
27877         vector signed long long vec_neg (vector signed long long)
27878         vector float            vec_neg (vector float)
27879         vector double           vec_neg (vector double)
27880         * config/rs6000/rs6000-builtin.def: Add definitions for NEG function
27881         overload.
27882         * config/rs6000/altivec.h: Add define for vec_neg
27883         * doc/extend.texi: Update the built-in documentation for the
27884         new built-in functions.
27886 2017-05-10  Prathamesh Kulkarni  <prathamesh.kulkarni@linaro.org>
27888         PR tree-optimization/77644
27889         * match.pd (sqrt(x) cmp sqrt(y) -> x cmp y): New pattern.
27891 2017-05-10  Nathan Sidwell  <nathan@acm.org>
27893         * dumpfile.h (TDI_lang_all): New.
27894         (TDF_KIND): New. Renumber others
27895         (TDF_LANG, TDF_TREE, TDF_RTL, TDF_IPA): Enumerate value, rather
27896         than bits.
27897         * dumpfile.c (dump_files): Mark language dumps as TDF_LANG.  add
27898         lang-all.
27899         (get_dump_file_name): Adjust suffix generation.
27900         (dump_enable_all): Use TDF_KIND.
27901         * doc/invoke.texi (-fdump-lang-all): Document.
27903         * dumpfile.h: Tabify.
27905 2017-05-10  Wilco Dijkstra  <wdijkstr@arm.com>
27907         PR target/80671
27908         * config/aarch64/cortex-a57-fma-steering.c (merge_forest):
27909         Move member access before delete.
27911 2017-05-10  Alexandre Oliva <aoliva@redhat.com>
27913         * tree-inline.c (expand_call_inline): Split block at stmt
27914         before the call.
27916 2017-05-09  Michael Meissner  <meissner@linux.vnet.ibm.com>
27918         PR target/68163
27919         * config/rs6000/rs6000.md (f32_lr): Delete mode attributes that
27920         are now unused after splitting mov{sf,sd}_hardfloat.
27921         (f32_lr2): Likewise.
27922         (f32_lm): Likewise.
27923         (f32_lm2): Likewise.
27924         (f32_li): Likewise.
27925         (f32_li2): Likewise.
27926         (f32_lv): Likewise.
27927         (f32_sr): Likewise.
27928         (f32_sr2): Likewise.
27929         (f32_sm): Likewise.
27930         (f32_sm2): Likewise.
27931         (f32_si): Likewise.
27932         (f32_si2): Likewise.
27933         (f32_sv): Likewise.
27934         (f32_dm): Likewise.
27935         (f32_vsx): Likewise.
27936         (f32_av): Likewise.
27937         (mov<mode>_hardfloat): Split into separate movsf and movsd pieces.
27938         For movsf, order stores so the VSX stores occur before the GPR
27939         store which encourages the register allocator to use a traditional
27940         FPR instead of a GPR.  For movsd, order the stores so that the GPR
27941         store comes before the VSX stores to allow the power6 to work.
27942         This is due to the power6 not having a 32-bit integer store
27943         instruction from a FPR.
27944         (movsf_hardfloat): Likewise.
27945         (movsd_hardfloat): Likewise.
27947 2017-05-09  Martin Sebor  <msebor@redhat.com>
27949         PR translation/80280
27950         * config/sol2-c.c (cmn_err_flag_specs): Initialize new data member
27951         added in r247778.
27953         PR translation/80280
27954         * config/i386/msformat-c.c (ms_printf_flag_specs): Initialize new
27955         data member added in r247778.
27956         (ms_scanf_flag_specs, ms_strftime_flag_specs): Same.
27958 2017-05-09  Nathan Sidwell  <nathan@acm.org>
27960         * tree.h (tree_fits_shwi_p, tree_fits_uhwi_p): Unconditionally pure.
27962         * ipa-devirt.c (default_hash_traits<type_pair>): Skip struct-scope
27963         typedefs.
27965 2017-05-09  Marek Polacek  <polacek@redhat.com>
27967         * doc/invoke.texi: Fix typo.
27969 2017-05-09  Richard Biener  <rguenther@suse.de>
27971         * tree-vrp.c (vrp_val_is_max): Adjust comment.
27972         (vrp_val_is_min): Likewise.
27973         (set_value_range_to_value): Likewise.
27974         (set_value_range_to_nonnegative): Likewise.
27975         (gimple_assign_nonzero_p): Likewise.
27976         (gimple_stmt_nonzero_p): Likewise.
27977         (vrp_int_const_binop): Likewise.  Remove unreachable case.
27978         (adjust_range_with_scev): Adjust comments.
27979         (compare_range_with_value): Likewise.
27980         (extract_range_from_phi_node): Likewise.
27981         (test_for_singularity): Likewise.
27983 2017-05-09  Richard Biener  <rguenther@suse.de>
27985         * tree-vrp.c (get_single_symbol): Add assert that we don't
27986         get overflowed constants as invariant part.
27987         (compare_values_warnv): Add comment before the TREE_NO_WARNING
27988         checks.  Use wi::cmp instead of recursing for integer constants.
27989         (compare_values): Just ignore whether we assumed undefined
27990         overflow instead of failing the compare.
27991         (extract_range_for_var_from_comparison_expr): Add comment before the
27992         TREE_NO_WARNING sets.
27993         (test_for_singularity): Likewise.
27994         (extract_range_from_comparison): Do not disable optimization
27995         when we assumed undefined overflow.
27996         (extract_range_basic): Remove init of unused var.
27998 2017-05-09  Richard Biener  <rguenther@suse.de>
28000         * tree-vrp.c (vrp_int_const_binop): Use wide-ints and simplify.
28001         (extract_range_from_multiplicative_op_1): Adjust.
28002         (extract_range_from_binary_expr_1): Use int_const_binop.
28004 2017-05-08  Kelvin Nilsen  <kelvin@gcc.gnu.org>
28006         PR target/80101
28007         * config/rs6000/power6.md: Replace store_data_bypass_p calls with
28008         rs6000_store_data_bypass_p in seven define_bypass directives and
28009         in several comments.
28010         * config/rs6000/rs6000-protos.h: Add prototype for
28011         rs6000_store_data_bypass_p function.
28012         * config/rs6000/rs6000.c (rs6000_store_data_bypass_p): New
28013         function implements slightly different (rs6000-specific) semantics
28014         than store_data_bypass_p, returning false rather than aborting
28015         with assertion error when arguments do not satisfy the
28016         requirements of store data bypass.
28017         (rs6000_adjust_cost): Replace six calls of store_data_bypass_p with
28018         rs6000_store_data_bypass_p.
28020 2017-05-08  Max Filippov  <jcmvbkbc@gmail.com>
28022         * config/xtensa/xtensa-protos.h
28023         (xtensa_initial_elimination_offset): New declaration.
28024         * config/xtensa/xtensa.c (xtensa_initial_elimination_offset):
28025         New function. Move its body from the INITIAL_ELIMINATION_OFFSET
28026         macro definition, add case for FRAME_POINTER_REGNUM when
28027         FRAME_GROWS_DOWNWARD.
28028         * config/xtensa/xtensa.h (FRAME_GROWS_DOWNWARD): New macro definition.
28029         (INITIAL_ELIMINATION_OFFSET): Replace body with call to
28030         xtensa_initial_elimination_offset.
28032 2017-05-08  Nathan Sidwell  <nathan@acm.org>
28034         * doc/invoke.texi: Alphabetize -fdump options.
28036 2017-05-08  Martin Sebor  <msebor@redhat.com>
28038         PR translation/80280
28039         * config/sol2-c.c (solaris_pragma_align): Correct quoting.
28041 2017-05-08  Bernd Edlinger  <bernd.edlinger@hotmail.de>
28043         * target.def (compute_frame_layout): New optional target hook.
28044         * doc/tm.texi.in (TARGET_COMPUTE_FRAME_LAYOUT): Add hook.
28045         * doc/tm.texi (TARGET_COMPUTE_FRAME_LAYOUT): Add documentation.
28046         * lra-eliminations.c (update_reg_eliminate): Call compute_frame_layout
28047         target hook.
28048         * reload1.c (verify_initial_elim_offsets): Likewise.
28049         * config/arm/arm.c (TARGET_COMPUTE_FRAME_LAYOUT): Define.
28050         (use_simple_return_p): Call arm_compute_frame_layout if needed.
28051         (arm_get_frame_offsets): Split up into this ...
28052         (arm_compute_frame_layout): ... and this function.
28054 2017-05-08  Richard Sandiford  <richard.sandiford@arm.com>
28056         * config/aarch64/constraints.md (Usa): New constraint.
28057         * config/aarch64/aarch64.md (*movsi_aarch64, *movdi_aarch64): Use it.
28059 2017-05-08  Thomas Preud'homme  <thomas.preudhomme@arm.com>
28061         * config.gcc (arm*-*-*): Set TM_MULTILIB_CONFIG from
28062         with_multilib_list after it has been checked.
28064 2017-05-08  Richard Biener  <rguenther@suse.de>
28066         * tree-ssa-pre.c (bitmap_set_and): Avoid bitmap copy.
28067         (bitmap_set_subtract_values): Likewise.
28069 2017-05-08  Richard Biener  <rguenther@suse.de>
28071         * tree-vrp.c (gimple_assign_nonzero_warnv_p): Rename to ...
28072         (gimple_assign_nonzero): ... this and remove strict_overflow_p
28073         argument.
28074         (gimple_stmt_nonzero_warnv_p): Rename to ...
28075         (gimple_stmt_nonzero_p): ... this and remove strict_overflow_p
28076         argument.
28077         (vrp_stmt_computes_nonzero): Remove strict_overflow_p argument.
28078         (extract_range_basic): Adjust, do not disable propagation on
28079         strict overflow sensitive simplification.
28080         (vrp_visit_cond_stmt): Likewise.
28082 2017-05-05  Jan Hubicka  <hubicka@ucw.cz>
28084         * ipa-inline-analysis.c (estimate_function_body_sizes): Recompute
28085         body size unconditionally.
28087 2017-05-07  Jeff Law  <law@redhat.com>
28089         Revert:
28090         2017-05-06  Jeff Law  <law@redhat.com>
28091         PR tree-optimization/78496
28092         * tree-vrp.c (simplify_assert_expr_using_ranges): Remove debugging
28093         code.
28095         PR tree-optimization/78496
28096         * tree-vrp.c (simplify_assert_expr_using_ranges): New function.
28097         (simplify_stmt_using_ranges): Call it.
28098         (vrp_dom_walker::before_dom_children): Extract equivalences
28099         from an ASSERT_EXPR with an equality comparison against a
28100         constant.
28102 2017-05-06  Jeff Law  <law@redhat.com>
28104         PR tree-optimization/78496
28105         * tree-vrp.c (simplify_assert_expr_using_ranges): Remove debugging
28106         code.
28108         PR tree-optimization/78496
28109         * tree-vrp.c (simplify_assert_expr_using_ranges): New function.
28110         (simplify_stmt_using_ranges): Call it.
28111         (vrp_dom_walker::before_dom_children): Extract equivalences
28112         from an ASSERT_EXPR with an equality comparison against a
28113         constant.
28115 2017-05-06  Richard Sandiford  <richard.sandiford@linaro.org>
28117         * lra-constraints.c (lra_copy_reg_equiv): New function.
28118         (split_reg): Use it to copy equivalence information from the
28119         original register to the spill register.
28121 2017-05-06  Richard Sandiford  <richard.sandiford@linaro.org>
28123         PR rtl-optimization/75964
28124         * simplify-rtx.c (simplify_const_relational_operation): Remove
28125         invalid handling of comparisons of integer ABS.
28127 2017-05-06  Uros Bizjak  <ubizjak@gmail.com>
28129         * config/i386/i386.c (ext_80387_constant_init): Do not explicitly
28130         initialize to zero.
28131         (init_regs): Remove declaration.
28132         (function_arg_advance_32): Initialize error_p as boolean variable.
28134 2017-05-05  Nathan Sidwell  <nathan@acm.org>
28136         * store-motion.c (remove_reachable_equiv_notes): Reformat long
28137         lines.  Use for (;;).
28139 2017-05-05  Bill Schmidt  <wschmidt@linux.vnet.ibm.com>
28141         * config/rs6000/rs6000.c (rs6000_vect_nonmem): New static var.
28142         (rs6000_init_cost): Initialize rs6000_vect_nonmem.
28143         (rs6000_add_stmt_cost): Update rs6000_vect_nonmem.
28144         (rs6000_finish_cost): Avoid vectorizing simple copy loops with
28145         VF=2 that require versioning.
28147 2017-05-05  David Malcolm  <dmalcolm@redhat.com>
28149         * diagnostic.h (CARET_LINE_MARGIN): Convert from macro to const
28150         int.
28152 2017-05-05  David Malcolm  <dmalcolm@redhat.com>
28154         * diagnostic.h (diagnostic_override_option_index): Convert from
28155         macro to inline function.
28157 2017-05-05  David Malcolm  <dmalcolm@redhat.com>
28159         * diagnostic.c (last_module_changed_p): New function.
28160         (set_last_module): New function.
28161         (diagnostic_report_current_module): Convert macro usage to
28162         the above functions.
28163         * diagnostic.h (diagnostic_context::last_module): Strengthen
28164         from const line_map * to const line_map_ordinary *.
28165         (diagnostic_last_module_changed): Delete macro.
28166         (diagnostic_set_last_module): Delete macro.
28168 2017-05-05  David Malcolm  <dmalcolm@redhat.com>
28170         * diagnostic.c (diagnostic_impl): Replace report_diagnostic
28171         with diagnostic_report_diagnostic.
28172         (diagnostic_n_impl_richloc): Likewise.
28173         * diagnostic.h (report_diagnostic): Delete macro.
28174         * rtl-error.c (diagnostic_for_asm): Replace report_diagnostic
28175         with diagnostic_report_diagnostic.
28176         * substring-locations.c (format_warning_va): Likewise.
28178 2017-05-05  David Malcolm  <dmalcolm@redhat.com>
28180         * diagnostic.c (diagnostic_report_diagnostic): Eliminate
28181         save/restor of format_spec.  Move option-printing code to...
28182         (print_option_information): ...this new function, and
28183         reimplement by simply printing to the pretty_printer,
28184         rather than appending to the format string.
28186 2017-05-05  David Malcolm  <dmalcolm@redhat.com>
28188         * diagnostic.c (diagnostic_report_diagnostic): Split out pragma
28189         handling logic into...
28190         (update_effective_level_from_pragmas): ...this new function.
28192 2017-05-04  Andrew Waterman  <andrew@sifive.com>
28194         * config/riscv/riscv.opt (mstrict-align): New option.
28195         * config/riscv/riscv.h (STRICT_ALIGNMENT): Use it.  Update comment.
28196         (SLOW_UNALIGNED_ACCESS): Define.
28197         (riscv_slow_unaligned_access): Declare.
28198         * config/riscv/riscv.c (riscv_tune_info): Add slow_unaligned_access
28199         field.
28200         (riscv_slow_unaligned_access): New variable.
28201         (rocket_tune_info): Set slow_unaligned_access to true.
28202         (optimize_size_tune_info): Set slow_unaligned_access to false.
28203         (riscv_cpu_info_table): Add entry for optimize_size_tune_info.
28204         (riscv_valid_lo_sum_p): Use TARGET_STRICT_ALIGN.
28205         (riscv_option_override): Set riscv_slow_unaligned_access.
28206         * doc/invoke.texi: Add -mstrict-align to RISC-V.
28208 2017-05-04  Kito Cheng  <kito.cheng@gmail.com>
28210         * config/riscv/riscv.md: Unify indentation.
28212 2017-05-05  Michael Meissner  <meissner@linux.vnet.ibm.com>
28214         PR target/79038
28215         PR target/79202
28216         PR target/79203
28217         * config/rs6000/rs6000.md (u code attribute): Add FIX and
28218         UNSIGNED_FIX.
28219         (extendsi<mode>2): Add support for doing sign extension via
28220         VUPKHSW and XXPERMDI if the value is in Altivec registers and we
28221         don't have ISA 3.0 instructions.
28222         (extendsi<mode>2 splitter): Likewise.
28223         (fix_trunc<mode>si2): If we are at ISA 2.07 (VSX small integer),
28224         generate the normal insns since SImode can now go in vector
28225         registers.  Disallow the special UNSPECs needed for previous
28226         machines to hide SImode being used.  Add new insns
28227         fctiw{,w}_<mode>_smallint if SImode can go in vector registers.
28228         (fix_trunc<mode>si2_stfiwx): Likewise.
28229         (fix_trunc<mode>si2_internal): Likewise.
28230         (fixuns_trunc<mode>si2): Likewise.
28231         (fixuns_trunc<mode>si2_stfiwx): Likewise.
28232         (fctiw<u>z_<mode>_smallint): Likewise.
28233         (fctiw<u>z_<mode>_mem): New combiner pattern to prevent conversion
28234         of floating point to 32-bit integer from doing a direct move to
28235         the GPR registers to do a store.
28236         (fctiwz_<mode>): Break long line.
28238 2017-05-05  Bin Cheng  <bin.cheng@arm.com>
28240         * Makefile.in (GTFILES): Add tree-ssa-loop-ivopts.c.
28241         * tree-ssa-loop-ivopts.c (compute_max_addr_offset): Delete.
28242         (addr_list, addr_offset_valid_p): New.
28243         (split_address_groups): Check offset validity with above function.
28244         (gt-tree-ssa-loop-ivopts.h): Include header file.
28246 2017-05-05  Nathan Sidwell  <nathan@acm.org>
28248         * config.gcc (arm*-*-*): Add missing 'fi'.
28250 2017-05-05  Steve Ellcey  <sellcey@cavium.com>
28252         * doc/invoke.texi (-fopt-info): Explicitly say order of options
28253         included in -fopt-info does not matter.
28254         * doc/optinfo.texi (-fopt-info): Fix description of default
28255         behavour. Explicitly say order of options included in -fopt-info
28256         does not matter.
28258 2017-05-05  Thomas Preud'homme  <thomas.preudhomme@arm.com>
28260         * config.gcc: Allow combinations of aprofile and rmprofile values for
28261         --with-multilib-list.
28262         * config/arm/t-multilib: New file.
28263         * config/arm/t-aprofile: Remove initialization of MULTILIB_*
28264         variables.  Remove setting of ISA and floating-point ABI in
28265         MULTILIB_OPTIONS and MULTILIB_DIRNAMES.  Set architecture and FPU in
28266         MULTI_ARCH_OPTS_A and MULTI_ARCH_DIRS_A rather than MULTILIB_OPTIONS
28267         and MULTILIB_DIRNAMES respectively.  Add comment to introduce all
28268         matches.  Add architecture matches for marvel-pj4 and generic-armv7-a
28269         CPU options.
28270         * config/arm/t-rmprofile: Likewise except for the matches changes.
28271         * doc/install.texi (--with-multilib-list): Document the combination of
28272         aprofile and rmprofile values and warn about pitfalls in doing that.
28274 2017-05-05  Wilco Dijkstra  <wdijkstr@arm.com>
28276         * config/aarch64/aarch64.md (movsi_aarch64): Remove '*' from r=w.
28277         (movdi_aarch64): Likewise.
28279 2017-05-05  Jakub Jelinek  <jakub@redhat.com>
28281         PR tree-optimization/80632
28282         * tree-switch-conversion.c (struct switch_conv_info): Add target_vop
28283         field.
28284         (build_arrays): Initialize it for virtual phis.
28285         (fix_phi_nodes): Use it for virtual phis.
28287         PR tree-optimization/80558
28288         * tree-vrp.c (extract_range_from_binary_expr_1): Optimize
28289         [x, y] op z into [x op, y op z] for op & or | if conditions
28290         are met.
28292 2017-05-05  Andre Vieira  <andre.simoesdiasvieira@arm.com>
28293             Prakhar Bahuguna  <prakhar.bahuguna@arm.com>
28295         PR target/71607
28296         * config/arm/arm.md (use_literal_pool): Remove.
28297         (64-bit immediate split): No longer takes cost into consideration
28298         if arm_disable_literal_pool is enabled.
28299         * config/arm/arm.c (arm_tls_referenced_p): Add diagnostic if TLS is
28300         used when arm_disable_literal_pool is enabled.
28301         (arm_max_const_double_inline_cost): Remove use of
28302         arm_disable_literal_pool.
28303         (push_minipool_fix): Add assert.
28304         (arm_reorg): Add return if arm_disable_literal_pool is enabled.
28305         * config/arm/vfp.md (no_literal_pool_df_immediate): New.
28306         (no_literal_pool_sf_immediate): New.
28308 2017-05-05  Prathamesh Kulkarni  <prathamesh.kulkarni@linaro.org>
28310         PR tree-optimization/80613
28311         * tree-ssa-dce.c (propagate_necessity): Remove cases for
28312         BUILT_IN_STRDUP and BUILT_IN_STRNDUP.
28314 2017-05-05  Richard Biener  <rguenther@suse.de>
28316         * tree-ssa-pre.c (get_or_alloc_expr_for): Simplify.
28318 2017-05-05  Georg-Johann Lay  <avr@gjlay.de>
28320         * config/avr/avr.md [flag_strict_overflow]: Remove any occurence
28321         of this flag from insn conditions due to removal from r247495.
28323 2017-05-05  Wilco Dijkstra  <wdijkstr@arm.com>
28325         * config/arm/aarch-common.c (arm_early_load_addr_dep_ptr):
28326         New function.
28327         (arm_early_store_addr_dep_ptr): Likewise.
28328         * config/arm/aarch-common-protos.h
28329         (arm_early_load_addr_dep_ptr): Add prototype.
28330         (arm_early_store_addr_dep_ptr): Likewise.
28331         * config/arm/cortex-a53.md: Add new bypasses.
28333 2017-05-05  Jakub Jelinek  <jakub@redhat.com>
28335         * tree.c (next_type_uid): Change type to unsigned.
28336         (type_hash_canon): Decrement back next_type_uid if
28337         freeing a type node with the highest TYPE_UID.  For INTEGER_TYPEs
28338         also ggc_free TYPE_MIN_VALUE, TYPE_MAX_VALUE and TYPE_CACHED_VALUES
28339         if possible.
28341 2017-05-04  Martin Sebor  <msebor@redhat.com>
28343         * builtins.c: Fix a trivial typo in a comment.
28345         PR middle-end/79234
28346         * builtins.c (check_sizes): Adjust to handle reading past the end.
28347         Avoid printing excessive upper bound of ranges.  Use %E to print
28348         tree nodes instead of converting them to %wu.
28349         (expand_builtin_memchr): New function.
28350         (compute_dest_size): Rename...
28351         (compute_objsize): ...to this.
28352         (expand_builtin_memcpy): Adjust.
28353         (expand_builtin_mempcpy): Adjust.
28354         (expand_builtin_strcat): Adjust.
28355         (expand_builtin_strcpy): Adjust.
28356         (check_strncat_sizes): Adjust.
28357         (expand_builtin_strncat): Adjust.
28358         (expand_builtin_strncpy): Adjust and simplify.
28359         (expand_builtin_memset): Adjust.
28360         (expand_builtin_bzero): Adjust.
28361         (expand_builtin_memcmp): Adjust.
28362         (expand_builtin): Handle memcmp.
28363         (maybe_emit_chk_warning): Check strncat just once.
28365 2017-05-04  Martin Sebor  <msebor@redhat.com>
28367         PR preprocessor/79214
28368         PR middle-end/79222
28369         PR middle-end/79223
28370         * builtins.c (check_sizes): Add inlining context and issue
28371         warnings even when -Wno-system-headers is set.
28372         (check_strncat_sizes): Same.
28373         (expand_builtin_strncat): Same.
28374         (expand_builtin_memmove): New function.
28375         (expand_builtin_stpncpy): Same.
28376         (expand_builtin): Handle memmove and stpncpy.
28378 2017-05-04  Bin Cheng  <bin.cheng@arm.com>
28380         * tree-ssa-loop-ivopts.c (struct cost_pair): Remove field inv_expr
28381         which is not used any more.
28383 2017-05-04  Wilco Dijkstra  <wdijkstr@arm.com>
28385         * config/aarch64/aarch64.c (generic_tunings): Update prefetch model.
28387 2017-05-04  Wilco Dijkstra  <wdijkstr@arm.com>
28389         * config/aarch64/aarch64.c (cortexa35_tunings): Set jump alignment to 4.
28390         (cortexa53_tunings): Likewise.
28391         (cortexa57_tunings): Likewise.
28392         (cortexa72_tunings): Likewise.
28393         (cortexa73_tunings): Likewise.
28395 2017-05-04  Wilco Dijkstra  <wdijkstr@arm.com>
28397         * config/aarch64/aarch64.c (generic_tunings): Set jump alignment to 4.
28398         Set loop alignment to 8.
28400 2017-05-04  Martin Sebor  <msebor@redhat.com>
28402         PR translation/80280
28403         * builtins.c (expand_builtin_object_size): Add missing quoting to
28404         %D and like directives.
28405         * hsa-gen.c (hsa_type_for_scalar_tree_type): Same.
28406         (hsa_type_for_tree_type): Same.
28407         (verify_function_arguments): Same.
28408         * symtab.c (symbol_table::change_decl_assembler_name): Same.
28409         * varasm.c (get_section): Same.
28410         (mark_weak): Same.
28412 2017-05-04  Martin Sebor  <msebor@redhat.com>
28414         PR translation/80280
28415         * config/i386/i386.c (ix86_function_versions): Quote a %D directive.
28417 2017-05-04  Wilco Dijkstra  <wdijkstr@arm.com>
28419         * config/aarch64/aarch64.c (generic_addrcost_table):
28420         Change HI/TI mode setting.
28422 2017-05-04  Martin Jambor  <mjambor@suse.cz>
28424         PR tree-optimization/80622
28425         * tree-sra.c (comes_initialized_p): New function.
28426         (build_accesses_from_assign): Only set write lazily when
28427         comes_initialized_p is false.
28428         (analyze_access_subtree): Use comes_initialized_p.
28429         (propagate_subaccesses_across_link): Assert !comes_initialized_p
28430         instead of testing for PARM_DECL.
28432 2017-05-04  Kyrylo Tkachov  <kyrylo.tkachov@arm.com>
28434         * config/aarch64/aarch64.md (prefetch); Adjust predicate and
28435         constraint on operand 0 to allow more general addressing modes.
28436         Adjust output template.
28437         * config/aarch64/aarch64.c (aarch64_address_valid_for_prefetch_p):
28438         New function.
28439         * config/aarch64/aarch64-protos.h
28440         (aarch64_address_valid_for_prefetch_p): Declare prototype.
28441         * config/aarch64/constraints.md (Dp): New address constraint.
28442         * config/aarch64/predicates.md (aarch64_prefetch_operand): New
28443         predicate.
28445 2017-05-04  Jan Hubicka  <hubicka@ucw.cz>
28447         * ipa-cp.c (perform_estimation_of_a_value): Drop base_time parameter;
28448         update use of estimate_ipcp_clone_size_and_time.
28449         (estimate_local_effects): Update use of
28450         estimate_ipcp_clone_size_and_time and perform_estimation_of_a_value.
28451         * ipa-inline.h (estimate_ipcp_clone_size_and_time): Update prototype.
28452         * ipa-inline-analysis.c (estimate_ipcp_clone_size_and_time):
28453         Return nonspecialized time.
28455 2017-05-04  Richard Biener  <rguenther@suse.de>
28457         * tree-ssa-alias.c (get_continuation_for_phi): Improve looking
28458         for the last VUSE which def dominates the PHI.  Directly call
28459         maybe_skip_until.
28460         (get_continuation_for_phi_1): Remove.
28462 2017-05-04  Richard Sandiford  <richard.sandiford@linaro.org>
28464         * tree-ssa-loop-manip.c (niter_for_unrolled_loop): Add commentary
28465         to explain the use of truncating division.  Cap the number of
28466         iterations to the maximum given by nb_iterations_upper_bound,
28467         if defined.
28469 2017-05-04  Thomas Preud'homme  <thomas.preudhomme@arm.com>
28471         * configure.ac (--enable-mingw-wildcard): Add new configurable feature.
28472         * configure: Regenerate.
28473         * config.in: Regenerate.
28474         * config/i386/driver-mingw32.c: new file.
28475         * config/i386/x-mingw32: Add rule to build driver-mingw32.o.
28476         * config.host: Link driver-mingw32.o on MinGW host.
28477         * doc/install.texi: Document new --enable-mingw-wildcard configure
28478         option.
28480 2017-05-04  Marek Polacek  <polacek@redhat.com>
28482         PR tree-optimization/80612
28483         * calls.c (get_size_range): Check for INTEGRAL_TYPE_P.
28485 2017-05-04  Prakhar Bahuguna  <prakhar.bahuguna@arm.com>
28486             Andre Simoes Dias Vieira  <andre.simoesdiasvieira@arm.com>
28488         * config/arm/arm.md (movsi): Change TARGET_32BIT to TARGET_HAVE_MOVT.
28489         (movt splitter): Likewise.
28490         * config/arm/arm.c (arm_option_check_internal): Change arm_arch_thumb2
28491         to TARGET_HAVE_MOVT, and merge with -mslow-flash-data check.
28492         (const_ok_for_arm): Change else to else if (TARGET_THUMB2) and add else
28493         block for Thumb-1 with MOVT.
28494         (thumb2_legitimate_address_p): Move code block ...
28495         (can_avoid_literal_pool_for_label_p): ... into this new function.
28496         (thumb1_legitimate_address_p): Add check for TARGET_HAVE_MOVT and
28497         literal pool.
28498         (thumb_legitimate_constant_p): Add conditional on TARGET_HAVE_MOVT
28499         * doc/invoke.texi (-mpure-code): Change "ARMv7-M targets" for
28500         "M-profile targets with the MOVT instruction".
28502 2017-05-04  Prakhar Bahuguna  <prakhar.bahuguna@arm.com>
28504         * config/arm/arm-builtins.c (arm_init_builtins): Rename
28505         __builtin_arm_ldfscr to __builtin_arm_get_fpscr, and rename
28506         __builtin_arm_stfscr to __builtin_arm_set_fpscr.
28508 2017-05-04  Martin Liska  <mliska@suse.cz>
28510         * tree-vrp.c (simplify_cond_using_ranges_2): Remove unused
28511         variable cond_code.
28513 2017-05-04  Richard Biener  <rguenther@suse.de>
28515         * tree.c (array_at_struct_end_p): Handle arrays at struct
28516         end with flexarrays more conservatively.  Refactor and treat
28517         arrays of arrays or aggregates more strict.  Fix
28518         VIEW_CONVERT_EXPR handling.  Remove allow_compref argument.
28519         * tree.c (array_at_struct_end_p): Adjust prototype.
28520         * emit-rtl.c (set_mem_attributes_minus_bitpos): Adjust.
28521         * gimple-fold.c (get_range_strlen): Likewise.
28522         * tree-chkp.c (chkp_may_narrow_to_field): Likewise.
28524 2017-05-04  Richard Biener  <rguenther@suse.de>
28526         PR tree-optimization/31130
28527         * tree-vrp.c (needs_overflow_infinity): Remove as always returning
28528         false.
28529         (supports_overflow_infinity): Likewise.
28530         (is_negative_overflow_infinity): Likewise.
28531         (is_positive_overflow_infinity): Likewise.
28532         (is_overflow_infinity): Likewise.
28533         (stmt_overflow_infinity): Likewise.
28534         (overflow_infinity_range_p): Likewise.
28535         (usable_range_p): Remove as always returning true.
28536         (make_overflow_infinity): Remove.
28537         (negative_overflow_infinity): Likewise.
28538         (positive_overflow_infinity): Likewise.
28539         (avoid_overflow_infinity): Likewise.
28540         (set_value_range): Adjust accordingly.
28541         (set_value_range_to_nonnegative): Likewise, remove now unused
28542         overflow_infinity arg.
28543         (vrp_operand_equal_p): Adjust.
28544         (update_value_range): Likewise.
28545         (range_int_cst_singleton_p): Likewise.
28546         (operand_less_p): Likewise.
28547         (compare_values_warnv): Likewise.
28548         (extract_range_for_var_from_comparison_expr): Likewise.
28549         (vrp_int_const_binop): Likewise.
28550         (zero_nonzero_bits_from_vr): Likewise.
28551         (extract_range_from_multiplicative_op_1): Likewise.
28552         (extract_range_from_binary_expr_1): Likewise.
28553         (extract_range_from_unary_expr): Likewise.
28554         (extract_range_from_comparison): Likewise.
28555         (extract_range_basic): Likewise.
28556         (adjust_range_with_scev): Likewise.
28557         (compare_ranges): Likewise.
28558         (compare_range_with_value): Likewise.
28559         (dump_value_range): Likewise.
28560         (test_for_singularity): Likewise, remove strict_overflow_p parameter
28561         never used.
28562         (simplify_cond_using_ranges): Adjust.
28564 2017-05-04  Pekka Jääskeläinen  <pekka.jaaskelainen@parmance.com>
28566         * brig-builtins.def: Added a builtin for class_f64.
28567         * builtin-types.def: Added a builtin type needed by class_f64.
28569 2017-05-03  Jason Merrill  <jason@redhat.com>
28571         * timevar.def: Add TV_CONSTEXPR.
28573 2017-05-03  David Malcolm  <dmalcolm@redhat.com>
28575         * common.opt (fdiagnostics-parseable-fixits): Fix typo.
28577 2017-05-03  Martin Jambor  <mjambor@suse.cz>
28579         * ipa-prop.c (ipa_update_after_lto_read): Removed.
28580         * ipa-prop.h (ipa_update_after_lto_read): Remove declaration.
28581         * ipa-cp.c (ipcp_propagate_stage): Do not call
28582         ipa_update_after_lto_read.
28583         * ipa-inline.c (ipa_inline): Likewise.
28585 2017-05-03  Martin Jambor  <mjambor@suse.cz>
28587         * ipa-prop.h (ipa_edge_args): Make a class.  Mark with for_user GTY
28588         tag.  Added a default constructor and a destructor.
28589         (ipa_edge_args_sum_t): New class;
28590         (ipa_edge_args_sum): Declare.
28591         (ipa_edge_args_vector): Remove declaration.
28592         (IPA_EDGE_REF): Use ipa_edge_args_sum.
28593         (ipa_free_edge_args_substructures): Remove declaration.
28594         (ipa_check_create_edge_args): Use ipa_edge_args_sum.
28595         (ipa_edge_args_info_available_for_edge_p): Likewise.
28596         * ipa-prop.c (ipa_edge_args_vector): Removed.
28597         (edge_removal_hook_holder): Likewise.
28598         (edge_duplication_hook_holder): Likewise.
28599         (ipa_edge_args_sum): New variable.
28600         (ipa_propagate_indirect_call_infos): Test ipa_edge_args_sum instead of
28601         ipa_edge_args_vector.
28602         (ipa_free_edge_args_substructures): Likewise.
28603         (ipa_free_all_edge_args): Free ipa_edge_args_sum instead of
28604         ipa_edge_args_vector.
28605         (ipa_edge_removal_hook): Turned into method
28606         ipa_edge_args_sum_t::remove.
28607         (ipa_edge_duplication_hook): Turned into method
28608         ipa_edge_args_sum_t::duplicate.
28609         (ipa_register_cgraph_hooks): Create ipa_edge_args_sum instead of
28610         registering edge hooks.
28611         (ipa_unregister_cgraph_hooks): Do not unregister edge hooks.
28612         * ipa-inline-analysis.c (estimate_function_body_sizes): Test
28613         ipa_edge_args_sum instead of ipa_edge_args_vector.
28614         * ipa-profile.c (ipa_profile): Likewise.
28616 2017-05-03  Martin Jambor  <mjambor@suse.cz>
28618         * symbol-summary.h (function_summary): New method exists.
28619         (function_summary::symtab_removal): Deallocate through release.
28620         (call_summary): New class.
28621         (gt_ggc_mx): New overload.
28622         (gt_pch_nx): Likewise.
28623         (gt_pch_nx): Likewise.
28625 2017-05-03  Jeff Law  <law@redhat.com>
28627         PR tree-optimization/78496
28628         * tree-vrp.c (simplify_cond_using_ranges_1): Renamed
28629         from simplify_cond_using_ranges.  Split off code to walk
28630         backwards through casts into ...
28631         (simplify_cond_using_ranges_2): New function.
28632         (simplify_stmt_using_ranges): Call simplify_cond_using_ranges_1.
28633         (execute_vrp): After identifying jump threads, call
28634         simplify_cond_using_ranges_2.
28636 2017-05-03  Jan Hubicka  <hubicka@ucw.cz>
28638         PR bootstrap/80609
28639         * ipa-inline.h (inline_summary): Add ctor.
28640         (create_ggc): Do not use ggc_cleared_alloc.
28642 2017-05-03  Jeff Downs  <heydowns@somuchpressure.net>
28643             Rainer Orth  <ro@CeBiTec.Uni-Bielefeld.DE>
28645         * gcc.c (handle_braces): Support escaping in switch matching
28646         text.
28647         * doc/invoke.texi (Spec Files): Document it.
28648         Remove superfluous @code markup in items.
28650 2017-05-03  David Malcolm  <dmalcolm@redhat.com>
28652         * diagnostic-show-locus.c (struct column_range): New struct.
28653         (get_affected_columns): New function.
28654         (get_printed_columns): New function.
28655         (struct correction): New struct.
28656         (correction::ensure_capacity): New function.
28657         (correction::ensure_terminated): New function.
28658         (struct line_corrections): New struct.
28659         (line_corrections::~line_corrections): New dtor.
28660         (line_corrections::add_hint): New function.
28661         (layout::print_trailing_fixits): Reimplement in terms of the new
28662         classes.
28663         (selftest::test_overlapped_fixit_printing): New function.
28664         (selftest::diagnostic_show_locus_c_tests): Call it.
28666 2017-05-03  Nathan Sidwell  <nathan@acm.org>
28668         Canonicalize canonical type hashing
28669         * tree.h (type_hash_canon_hash): Declare.
28670         * tree.c (type_hash_list, attribute_hash_list): Move into
28671         type_hash_canon_hash.
28672         (build_type_attribute_qual_variant): Break out hash code calc into
28673         type_hash_canon_hash.
28674         (type_hash_canon_hash): New.  Generic type hash computation.
28675         (build_range_type_1, build_array_type_1, build_function_type,
28676         build_method_type_directly, build_offset_type, build_complex_type,
28677         make_vector_type): Call it.
28679 2017-05-03  Richard Biener  <rguenther@suse.de>
28681         * tree-vect-data-refs.c (vect_enhance_data_refs_alignment):
28682         When all DRs have unknown misaligned do not always peel
28683         when there is a store but apply the same costing model as if
28684         there were only loads.
28686 2017-05-03  Richard Biener  <rguenther@suse.de>
28688         Revert
28689         PR tree-optimization/80492
28690         * tree-ssa-alias.c (decl_refs_may_alias_p): Handle
28691         compare_base_decls returning dont-know properly.
28693 2017-05-03  Thomas Preud'homme  <thomas.preudhomme@arm.com>
28695         * config/arm/iterators.md (CCSI): New mode iterator.
28696         (arch): New mode attribute.
28697         * config/arm/sync.md (atomic_compare_and_swap<mode>_1): Rename into ...
28698         (atomic_compare_and_swap<CCSI:arch><NARROW:mode>_1): This and ...
28699         (atomic_compare_and_swap<CCSI:arch><SIDI:mode>_1): This.  Use CCSI
28700         code iterator for success result mode.
28701         * config/arm/arm.c (arm_expand_compare_and_swap): Adapt code to use
28702         the corresponding new insn generators.
28704 2017-05-03  Bin Cheng  <bin.cheng@arm.com>
28706         Revert r247509
28707         2017-05-02  Bin Cheng  <bin.cheng@arm.com>
28708         * rtlanal.c (rtx_cost): Handle TRUNCATE between tieable modes.
28710 2017-05-03  Richard Sandiford  <richard.sandiford@linaro.org>
28712         * tree-data-ref.h (SUB_CONFLICTS_IN_A): Wrap SUB argument in brackets.
28713         (SUB_CONFLICTS_IN_B, SUB_LAST_CONFLICT, SUB_DISTANCE): Likewise.
28714         (DDR_A): Wrap DDR argument in brackets.
28715         (DDR_B, DDR_AFFINE_P, DDR_ARE_DEPENDENT, DDR_SUBSCRIPTS): Likewise.
28716         (DDR_LOOP_NEST, DDR_INNER_LOOP, DDR_SELF_REFERENCE): Likewise.
28717         (DDR_REVERSED_P): Likewise.
28719 2017-05-03  Jakub Jelinek  <jakub@redhat.com>
28721         PR tree-optimization/79472
28722         * tree-switch-conversion.c (struct switch_conv_info): Add
28723         contiguous_range and default_case_nonstandard fields.
28724         (collect_switch_conv_info): Compute contiguous_range and
28725         default_case_nonstandard fields, don't clear final_bb if
28726         contiguous_range and only the default case doesn't have the required
28727         structure.
28728         (check_all_empty_except_final): Set default_case_nonstandard instead
28729         of failing if contiguous_range and the default case doesn't have empty
28730         block.
28731         (check_final_bb): Add SWTCH argument, don't fail if contiguous_range
28732         and only the default case doesn't have the required constants.  Skip
28733         virtual phis.
28734         (gather_default_values): Skip virtual phis.  Allow non-NULL CASE_LOW
28735         if default_case_nonstandard.
28736         (build_constructors): Build constant 1 just once.  Assert that default
28737         values aren't inserted in between cases if contiguous_range.  Skip
28738         virtual phis.
28739         (build_arrays): Skip virtual phis.
28740         (prune_bbs): Add DEFAULT_BB argument, don't remove that bb.
28741         (fix_phi_nodes): Don't add e2f phi arg if default_case_nonstandard.
28742         Handle virtual phis.
28743         (gen_inbound_check): Handle default_case_nonstandard case.
28744         (process_switch): Adjust check_final_bb caller.  Call
28745         gather_default_values with the first non-default case instead of
28746         default case if default_case_nonstandard.
28748 2017-05-02  Nathan Sidwell  <nathan@acm.org>
28750         * ggc-page.c (move_ptes_to_front): Replace unsigned >0 with i--
28751         check.  Fix formatting.
28753 2017-05-02  Jan Hubicka  <hubicka@ucw.cz>
28755         * ipa-inline-analysis.c (estimate_node_size_and_time): Allow roundoff
28756         errors when comparing specialized and unspecialized times.
28758 2017-05-02  David Malcolm  <dmalcolm@redhat.com>
28760         * diagnostic-show-locus.c
28761         (layout::should_print_annotation_line_p): Make private.
28762         (layout::print_annotation_line): Make private.
28763         (layout::annotation_line_showed_range_p): Make private.
28764         (layout::show_ruler): Make private.
28765         (layout::print_source_line): Make private.  Pass in line and
28766         line_width, rather than calling location_get_source_line.  Drop
28767         returned value.
28768         (layout::print_leading_fixits): New method.
28769         (layout::print_any_fixits): Rename to...
28770         (layout::print_trailing_fixits): ...this, and make private.
28771         Don't print newline fixits.
28772         (diagnostic_show_locus): Move logic for printing one row into...
28773         (layout::print_line): ...this new function.  Move the
28774         location_get_source_line call and error-handling from
28775         print_source_line to here.  Call print_leading_fixits, and rename
28776         print_any_fixits to print_trailing_fixits.
28777         (selftest::test_fixit_insert_containing_newline): Update now that
28778         newlines are partially supported.
28779         (selftest::test_fixit_insert_containing_newline_2): New test.
28780         (selftest::test_fixit_replace_containing_newline): Update comments.
28781         (selftest::diagnostic_show_locus_c_tests): Call the new test.
28782         * edit-context.c (class added_line): New class.
28783         (class edited_line): Describe newline handling in comment.
28784         (edited_line::actually_edited_p): New method.
28785         (edited_line::print_content): Delete redundant decl.
28786         (edited_line::m_predecessors): New field.
28787         (edited_file::print_content): Call edited_line::print_content.
28788         (edited_file::print_diff): Update to support newlines.
28789         (edited_file::print_diff_hunk): Likewise.
28790         (edited_file::print_run_of_changed_lines): New function.
28791         (edited_file::print_diff_line): Convert to...
28792         (print_diff_line): ...this.
28793         (edited_file::get_effective_line_count): New function.
28794         (edited_line::edited_line): Initialize new field m_predecessors.
28795         (edited_line::~edited_line): Clean up m_predecessors.
28796         (edited_line::apply_fixit): Handle newlines.
28797         (edited_line::get_effective_line_count): New function.
28798         (edited_line::print_content): New function.
28799         (edited_line::print_diff_lines): New function.
28800         (selftest::test_applying_fixits_insert_containing_newline): New
28801         test.
28802         (selftest::test_applying_fixits_replace_containing_newline): New
28803         test.
28804         (selftest::insert_line): New function.
28805         (selftest::test_applying_fixits_multiple_lines): Add example of
28806         inserting a line.
28807         (selftest::edit_context_c_tests): Call the new tests.
28809 2017-05-02  Bin Cheng  <bin.cheng@arm.com>
28811         * tree-ssa-loop-ivopts.c (get_scaled_computation_cost_at): Delete
28812         parameter cand.  Update dump information.
28813         (get_computation_cost): Update uses.
28815 2017-05-02  Bin Cheng  <bin.cheng@arm.com>
28817         * tree-ssa-loop-ivopts.c (get_computation_aff_1): New.
28818         (get_computation_aff): Reorder parameters.  Use get_computation_aff_1.
28819         (get_computation_at, rewrite_use_address): Update use of
28820         get_computation_aff.
28822 2017-05-02  Bin Cheng  <bin.cheng@arm.com>
28824         * tree-ssa-loop-ivopts.c (get_computation_at): Reorder parameters.
28825         (get_computation): Delete.
28826         (get_computation_cost): Implement like get_computation_cost_at.
28827         Use get_computation_at.
28828         (get_computation_cost_at): Delete.
28829         (rewrite_use_nonlinear_expr): Use get_computation_at.
28830         (rewrite_use_compare, remove_unused_ivs): Ditto.
28832 2017-05-02  Bin Cheng  <bin.cheng@arm.com>
28834         * tree-ssa-loop-ivopts.c (rewrite_use_address): Simple refactor.
28836 2017-05-02  Bin Cheng  <bin.cheng@arm.com>
28838         * tree-ssa-loop-ivopts.c (struct iv_ca): Rename n_regs to n_invs.
28839         (ivopts_global_cost_for_size): Rename parameter and update uses.
28840         (iv_ca_recount_cost): Update uses.
28841         (iv_ca_set_remove_invs, iv_ca_set_no_cp): Record invariants and
28842         candidates seperately in n_invs and n_cands.
28843         (iv_ca_set_add_invs, iv_ca_set_cp, iv_ca_new): Ditto.
28845 2017-05-02  Bin Cheng  <bin.cheng@arm.com>
28847         * tree-ssa-loop-ivopts.c (struct walk_tree_data): New.
28848         (find_inv_vars_cb): New.
28849         (find_depends): Renamed to ...
28850         (find_inv_vars): ... this.
28851         (add_candidate_1, force_var_cost): Call find_inv_vars.
28852         (split_address_cost, determine_group_iv_cost_cond): Ditto.
28854 2017-05-02  Bin Cheng  <bin.cheng@arm.com>
28856         * tree-ssa-loop-ivopts.c (struct cost_pair): Rename depends_on to
28857         inv_vars.  Add inv_exprs.
28858         (struct iv_cand): Rename depends_on to inv_vars.
28859         (struct ivopts_data): Rename max_inv_id/n_invariant_uses to
28860         max_inv_var_id/n_inv_var_uses.  Move max_inv_expr_id around.
28861         Refactor field used_inv_exprs from has_map to array n_inv_expr_uses.
28862         (dump_cand): Dump inv_vars.
28863         (tree_ssa_iv_optimize_init): Support inv_vars and inv_exprs.
28864         (record_invariant, find_depends, add_candidate_1): Ditto.
28865         (set_group_iv_cost, force_var_cost): Ditto.
28866         (split_address_cost, ptr_difference_cost, difference_cost): Ditto.
28867         (get_computation_cost_at, get_computation_cost): Ditto.
28868         (determine_group_iv_cost_generic): Ditto.
28869         (determine_group_iv_cost_address): Ditto.
28870         (determine_group_iv_cost_cond, autoinc_possible_for_pair): Ditto.
28871         (determine_group_iv_costs): Ditto.
28872         (iv_ca_recount_cost): Update call to ivopts_global_cost_for_size.
28873         (iv_ca_set_remove_invariants): Renamed to ...
28874         (iv_ca_set_remove_invs): ... this.  Support inv_vars and inv_exprs.
28875         (iv_ca_set_no_cp): Use iv_ca_set_remove_invs.
28876         (iv_ca_set_add_invariants):  Renamed to ...
28877         (iv_ca_set_add_invs): ... this.  Support inv_vars and inv_exprs.
28878         (iv_ca_set_cp): Use iv_ca_set_add_invs.
28879         (iv_ca_has_deps): Support inv_vars and inv_exprs.
28880         (iv_ca_new, iv_ca_free, iv_ca_dump, free_loop_data): Ditto.
28881         (create_new_ivs): Remove useless dump.
28883 2017-05-02  Bin Cheng  <bin.cheng@arm.com>
28885         * tree-ssa-loop-ivopts.c (get_computation_cost_at): Remove pseudo
28886         iv_cand code.
28887         (determine_group_iv_cost_cond, determine_iv_cost): Ditto.
28888         (iv_ca_set_no_cp, create_new_iv): Ditto.
28890 2017-05-02  Bin Cheng  <bin.cheng@arm.com>
28892         * rtlanal.c (rtx_cost): Handle TRUNCATE between tieable modes.
28894 2017-05-02  Xi Ruoyao  <ryxi@stu.xidian.edu.cn>
28896         * tree.h (EXPR_CILK_SPAWN): Use macro TREE_CHECK2 instead of
28897         function tree_check2.
28899 2017-05-02  Martin Liska  <mliska@suse.cz>
28901         * doc/gcov.texi: Add missing preposition.
28902         * gcov.c (function_info::function_info): Properly fill up
28903         all member variables.
28905 2017-05-02  Tamar Christina  <tamar.christina@arm.com>
28907         * expr.c (expand_expr_real_2): Re-cost if previous costs are the same.
28909 2017-05-02  Tamar Christina  <tamar.christina@arm.com>
28911         * simplify-rtx.c (simplify_binary_operation_1): Add LSHIFTRT case.
28913 2017-05-02  Martin Liska  <mliska@suse.cz>
28915         PR lto/77954.
28916         * lto-streamer-in.c (lto_read_tree_1): Remove
28917         LTO_STREAMER_DEBUG.
28918         * lto-streamer.c (struct tree_hash_entry): Likewise.
28919         (struct tree_entry_hasher): Likewise.
28920         (tree_entry_hasher::hash): Likewise.
28921         (tree_entry_hasher::equal): Likewise.
28922         (lto_streamer_init): Likewise.
28923         (lto_orig_address_map): Likewise.
28924         (lto_orig_address_get): Likewise.
28925         (lto_orig_address_remove): Likewise.
28926         * lto-streamer.h: Likewise.
28927         * tree-streamer-in.c (streamer_alloc_tree): Likewise.
28928         * tree-streamer-out.c (streamer_write_tree_header): Likewise.
28930 2017-05-02  Sebastian Peryt  <sebastian.peryt@intel.com>
28932         * config/i386/avx512fintrin.h (_mm_mask_add_round_sd)
28933         (_mm_maskz_add_round_sd, _mm_mask_add_round_ss)
28934         (mm_maskz_add_round_ss, _mm_mask_sub_round_sd)
28935         (mm_maskz_sub_round_sd, _mm_mask_sub_round_ss)
28936         (mm_maskz_sub_round_ss, _mm_mask_add_sd)
28937         (mm_maskz_add_sd, _mm_mask_add_ss, _mm_maskz_add_ss)
28938         (mm_mask_sub_sd, _mm_maskz_sub_sd, _mm_mask_sub_ss)
28939         (mm_maskz_sub_ss): New intrinsics.
28940         * config/i386/i386-builtin-types.def (V2DF_FTYPE_V2DF_V2DF_V2DF_UQI_INT)
28941         (V4SF_FTYPE_V4SF_V4SF_V4SF_UQI_INT): New function type aliases.
28942         * config/i386/i386-builtin.def (__builtin_ia32_addsd_mask_round)
28943         (__builtin_ia32_addss_mask_round, __builtin_ia32_subsd_mask_round)
28944         (__builtin_ia32_subss_mask_round): New builtins.
28945         * config/i386/i386.c (V2DF_FTYPE_V2DF_V2DF_V2DF_UQI_INT)
28946         (V4SF_FTYPE_V4SF_V4SF_V4SF_UQI_INT): Handle new types.
28947         * config/i386/sse.md (<sse>_vm<plusminus_insn><mode>3<round_name>):
28948         Renamed to ...
28949         (<sse>_vm<plusminus_insn><mode>3<mask_name><round_name>): ... this.
28950         (v<plusminus_mnemonic><ssescalarmodesuffix>\t{<round_op3>%2, %1, %0|%0, %1, %<iptr>2<round_op3>}):
28951         Changed to ...
28952         (v<plusminus_mnemonic><ssescalarmodesuffix>\t{<round_mask_op3>%2, %1, %0<mask_operand3>|%0<mask_operand3>, %1, %<iptr>2<round_mask_op3>}):
28953         ... this.
28955 2017-05-02  Martin Jambor  <mjambor@suse.cz>
28957         PR tree-optimization/78687
28958         * tree-sra.c (access): New field parent.
28959         (process_subtree_disqualification): New function.
28960         (disqualify_candidate): Call it.
28961         (build_accesses_from_assign): Reset write flag if creating an
28962         assighnment link.
28963         (build_access_subtree): Fill in parent field and also prpagate
28964         down grp_write flag.
28965         (create_artificial_child_access): New parameter set_grp_write, set
28966         grp_write to its value.
28967         (propagate_subaccesses_across_link): Also propagate grp_write flag
28968         values.
28969         (propagate_all_subaccesses): Push the closest parent back to work
28970         queue if add_access_to_work_queue returned true.
28972 2017-05-02  Richard Biener  <rguenther@suse.de>
28974         * common.opt (fstrict-overflow): Alias negative to fwrapv.
28975         * doc/invoke.texi (fstrict-overflow): Remove all traces of
28976         -fstrict-overflow documentation.
28977         * tree.h (TYPE_OVERFLOW_UNDEFINED): Do not test flag_strict_overflow.
28978         (POINTER_TYPE_OVERFLOW_UNDEFINED): Test !flag_wrapv instead of
28979         flag_strict_overflow.
28980         * ipa-inline.c (can_inline_edge_p): Do not test flag_strict_overflow.
28981         * lto-opts.c (lto_write_options): Do not stream it.
28982         * lto-wrapper.c (merge_and_complain): Do not handle it.
28983         * opts.c (default_options_table): Do not set -fstrict-overflow.
28984         (finish_options): Likewise do not clear it when sanitizing.
28985         * simplify-rtx.c (simplify_const_relational_operation): Do not
28986         test flag_strict_overflow.
28988 2017-05-02  Uros Bizjak  <ubizjak@gmail.com>
28990         * config/alpha/alpha.md (*add<mode>3_ieee): Merge to add<mode>3
28991         using enabled attribute.
28992         (*sub<mode>3_ieee): Merge to sub<mode>3 using enabled attribute.
28993         (*mul<mode>3_ieee): Merge to mul<mode>3 using enabled attribute.
28994         (*div<mode>3_ieee): Merge to div<mode>3 using enabled attribute.
28995         (*sqrt<mode>2_ieee): Merge to sqrt<mode>2 using enabled attribute.
28996         (*fix_truncdfdi_ieee): Merge to *fix_truncdfdi2 using enabled attribute.
28997         (*fix_truncsfdi_ieee): Merge to *fix_truncsfdi2 using enabled attribute.
28998         (*floatdisf_ieee): Merge to floatdisf2 using enabled attribute.
28999         (*floatdidf_ieee): Merge to floatdidf2 using enabled attribute.
29000         (*truncdfsf2_ieee): Merge to truncdfsf2 using enabled attribute.
29001         (*cmpdf_ieee): Merge to *cmpdf_internal using enabled attribute.
29003 2017-05-02  Uros Bizjak  <ubizjak@gmail.com>
29005         * config/i386/i386.c (ix86_code_end): Use {FIRST,LAST}_INT_REG.
29007 2017-05-02  Richard Biener  <rguenther@suse.de>
29009         PR tree-optimization/80591
29010         Revert
29011         2017-04-10  Richard Biener  <rguenther@suse.de>
29013         * tree-ssa-structalias.c (find_func_aliases): Properly handle
29014         asm inputs.
29016 2017-05-02  Richard Biener  <rguenther@suse.de>
29018         PR tree-optimization/80549
29019         * tree-cfgcleanup.c (mfb_keep_latches): New helper.
29020         (cleanup_tree_cfg_noloop): Create forwarders to known loop
29021         headers if they do not have a preheader.
29023 2017-05-02  Martin Liska  <mliska@suse.cz>
29025         PR other/80589
29026         * common.opt: Fix typo.
29027         * doc/invoke.texi: Likewise.
29029 2017-05-01  Jan Beulich  <jbeulich@suse.com>
29031         * config/i386/sse.md (xop_vpermil2<mode>3): Do not allow operand
29032         swapping, add (x,x,m,x,n) alternative.
29034 2017-05-01  Nathan Sidwell  <nathan@acm.org>
29036         * calls.c (combine_pending_stack_adjustment_and_call): Remove
29037         unnecessary unadjusted_alignment check.
29039 2017-05-01  Xi Ruoyao  <ryxi@stu.xidian.edu.cn>
29041         PR c++/80038
29042         * cilk_common.c (expand_builtin_cilk_detach): Move pedigree
29043         operations here.
29044         * gimplify.c (gimplify_cilk_detach): New function.
29045         (gimplify_call_expr, gimplify_modify_expr): Call it as needed.
29046         * tree-core.h: Document EXPR_CILK_SPAWN.
29047         * tree.h (EXPR_CILK_SPAWN): Define.
29049 2017-05-01  David Malcolm  <dmalcolm@redhat.com>
29051         * diagnostic-show-locus.c (layout::get_expanded_location): Rewrite
29052         to use new fixit_hint representation, using the "replace" logic.
29053         (get_line_span_for_fixit_hint): Likewise.
29054         (layout::print_any_fixits): Likewise.
29055         (selftest::test_one_liner_many_fixits): Rename to...
29056         (selftest::test_one_liner_many_fixits_1): ...this, and update
29057         comment and expected output to reflect that the multiple fix-it
29058         hints are now consolidated into one insertion.
29059         (selftest::test_one_liner_many_fixits_2): New test.
29060         (selftest::test_diagnostic_show_locus_one_liner): Update for
29061         above.
29062         (selftest::test_fixit_consolidation): Update for fix-it API
29063         change.
29064         * diagnostic.c (print_parseable_fixits): Likewise.
29065         * edit-context.c (edited_line::m_line_events): Convert from
29066         auto_vec <line_event *> to auto_vec <line_event>.
29067         (class line_event): Convert from abstract base class to a concrete
29068         class, taking over the role of replace_event.
29069         (class insert_event): Delete.
29070         (class replace_event): Rename to class line_event.  Convert to
29071         half-open range.
29072         (edit_context::add_fixits): Reimplement.
29073         (edit_context::apply_insert): Delete.
29074         (edit_context::apply_replace): Rename to...
29075         (edit_context::apply_fixit): ...this.  Convert to half-open range.
29076         (edited_file::apply_insert): Delete.
29077         (edited_file::apply_replace): Rename to...
29078         (edited_file::apply_fixit): ...this.
29079         (edited_line::~edited_line): Drop deletion of events.
29080         (edited_line::apply_insert): Delete.
29081         (edited_line::apply_replace): Rename to...
29082         (edited_line::apply_fixit): ...this.  Convert to half-open range.
29083         Update for change to type of m_line_events.
29084         * edit-context.h (edit_context::apply_insert): Delete.
29085         (edit_context::apply_replace): Rename to...
29086         (edit_context::apply_fixit): ...this.
29088 2017-05-01  Martin Sebor  <msebor@redhat.com>
29090         * gimple-ssa-sprintf.c (format_integer): Set knownrange when it's
29091         known.
29093 2017-05-01  Uros Bizjak  <ubizjak@gmail.com>
29095         PR target/68491
29096         * config/i386/cpuid.h (__get_cpuid): Always return 0 when
29097         __get_cpuid_max returns 0.
29098         (__get_cpuid_count): Ditto.
29100 2017-05-01  Eric Botcazou  <ebotcazou@adacore.com>
29102         * tree.c (substitute_in_expr) <tcc_vl_exp>: Also inline a call if the
29103         replacement expression is another instance of one of its arguments.
29105 2017-05-01  Jakub Jelinek  <jakub@redhat.com>
29107         PR target/79430
29108         * rtlanal.c (reg_set_p): If reg is a stack_pointer_rtx, also
29109         check for stack push/pop autoinc.
29110         * config/i386/i386.c (ix86_agi_dependent): Return false
29111         if the only reason why modified_in_p returned true is that
29112         addr is SP based and set_insn is a push or pop.
29114 2017-04-29  Jan Hubicka  <hubicka@ucw.cz>
29116         * ipa-inline.c (compute_inlined_call_time): Remove now unnecesary
29117         overflow check.
29119 2017-04-29  Jan Hubicka  <hubicka@ucw.cz>
29121         PR ipa/79224
29122         * ipa-inline-analysis.c (dump_predicate): Add optional parameter NL.
29123         (account_size_time): Use two predicates - exec_pred and
29124         nonconst_pred_ptr.
29125         (evaluate_conditions_for_known_args): Compute both clause and
29126         nonspec_clause.
29127         (evaluate_properties_for_edge): Evaulate both clause and nonspec_clause.
29128         (inline_summary_t::duplicate): Update.
29129         (estimate_function_body_sizes): Caluculate exec and nonconst predicates
29130         separately.
29131         (compute_inline_parameters): Likewise.
29132         (estimate_edge_size_and_time): Update caluclation of time.
29133         (estimate_node_size_and_time): Compute both time and nonspecialized
29134         time.
29135         (estimate_ipcp_clone_size_and_time): Update.
29136         (inline_merge_summary): Update.
29137         (do_estimate_edge_time): Update.
29138         (do_estimate_edge_size): Update.
29139         (do_estimate_edge_hints): Update.
29140         (inline_read_section, inline_write_summary): Stream both new predicates.
29141         * ipa-inline.c (compute_uninlined_call_time): Take uninlined_call_time
29142         as argument.
29143         (compute_inlined_call_time): Cleanup.
29144         (big_speedup_p): Update.
29145         (edge_badness): Update.
29146         * ipa-inline.h (INLINE_TIME_SCALE): Remove.
29147         (size_time_entry): Replace predicate by exec_predicate and
29148         nonconst_predicate.
29149         (edge_growth_cache_entry): Cache both time nad nonspecialized time.
29150         (estimate_edge_time): Return also nonspec_time.
29151         (reset_edge_growth_cache): Update.
29153 2017-04-29  Jakub Jelinek  <jakub@redhat.com>
29155         PR rtl-optimization/80491
29156         * ifcvt.c (noce_process_if_block): When looking for x setter
29157         with missing else_bb, don't check only the insn right before
29158         cond_earliest, but look for the last insn that x is modified in
29159         within the same bb.
29161         PR rtl-optimization/80491
29162         * alias.c (memory_modified_in_insn_p): Return true for CALL_INSNs.
29164 2017-04-29  Marc Glisse  <marc.glisse@inria.fr>
29166         PR tree-optimization/80487
29167         * tree-ssa-alias.c (stmt_kills_ref_p): Handle stpncpy and strncpy.
29169 2017-04-29  Prathamesh Kulkarni  <prathamesh.kulkarni@linaro.org>
29171         PR tree-optimization/79697
29172         * tree-ssa-dce.c (mark_stmt_if_obviously_necessary): Check if callee
29173         is BUILT_IN_STRDUP, BUILT_IN_STRNDUP, BUILT_IN_REALLOC.
29174         (propagate_necessity): Check if def_callee is BUILT_IN_STRDUP or
29175         BUILT_IN_STRNDUP.
29176         * gimple-fold.c (gimple_fold_builtin_realloc): New function.
29177         (gimple_fold_builtin): Call gimple_fold_builtin_realloc.
29179 2017-04-28  Martin Sebor  <msebor@redhat.com>
29181         PR tree-optimization/80523
29182         * gimple-ssa-sprintf.c (target_to_host_charmap): New global variable.
29183         (init_target_to_host_charmap, target_to_host, target_strtol10): New
29184         functions.
29185         (maybe_warn, format_directive, parse_directive): Use new functions.
29186         (pass_sprintf_length::execute): Call init_target_to_host_charmap.
29188 2017-04-28  Marc Glisse  <marc.glisse@inria.fr>
29190         * match.pd (X+Z OP Y+Z, X-Z OP Y-Z, Z-X OP Z-Y): New transformations.
29192 2017-04-28  Bernd Edlinger  <bernd.edlinger@hotmail.de>
29194         * configure.ac (SYSTEM_HEADER_DIR, BUILD_SYSTEM_HEADER_DIR,
29195         target_header_dir): Set correctly.
29196         * configure: Regenerated.
29197         * Makefile.in (BUILD_SYSTEM_HEADER_DIR): New make variabe.
29198         (LIMITS_H_TEST, if_multiarch, stmp-fixinc): Use BUILD_SYSTEM_HEADER_DIR
29199         instead of SYSTEM_HEADER_DIR.
29201 2017-04-28  Jan Hubicka  <hubicka@ucw.cz>
29203         * ipa-cp.c (perform_estimation_of_a_value): Turn time to sreal.
29204         (estimate_local_effects): Likewise.
29205         * ipa-inline.c (compute_inlined_call_time, want_inline_small_function_p,
29206         edge_badness, inline_small_functions, dump_overall_stats): LIkewise.
29207         * ipa-inline.h (edge_growth_cache_entry, estimate_time_after_inlining,
29208         estimate_ipcp_clone_size_and_time, do_estimate_edge_time,
29209         do_estimate_edge_time, estimate_edge_time): Likewise.
29210         * ipa-inline-analysis.c (estimate_node_size_and_time,
29211         estimate_ipcp_clone_size_and_time, do_estimate_edge_time): Likewise.
29212         (estimate_time_after_inlining): Remove.
29214 2017-04-28  Martin Liska  <mliska@suse.cz>
29216         * doc/gcov.texi: Enhance documentation of gcov.
29218 2017-04-28  Martin Liska  <mliska@suse.cz>
29220         * doc/gcov.texi: Sort options in alphabetic order.
29221         * doc/gcov-dump.texi: Likewise.
29222         * doc/gcov-tool.texi: Likewise.
29223         * gcov.c (print_usage): Likewise.
29224         * gcov-dump.c (print_usage): Likewise.
29225         * gcov-tool.c (print_merge_usage_message): Likewise.
29226         (print_rewrite_usage_message): Likewise.
29227         (print_overlap_usage_message): Likewise.
29229 2017-04-28  Martin Liska  <mliska@suse.cz>
29231         PR gcov-profile/53915
29232         * gcov.c (format_gcov): Print 'NAN %' when top > bottom.
29234 2017-04-28  Martin Liska  <mliska@suse.cz>
29236         PR gcov-profile/79891
29237         * gcov.c (add_line_counts): Assign BBs to lines just if the BB
29238         is marked by compiler as living on a line.
29239         (get_cycles_count): Remove usage of the union.
29240         (output_intermediate_file): Likewise.
29241         (find_source): Fix GNU coding style.
29242         (accumulate_line_counts): Remove old non-all block mode.
29243         (output_lines): Remove usage of the union.
29244         * profile.c (output_location): Include all BBs, even if
29245         belonging to a same line (and file) as a previous BB.
29247 2017-04-28  Martin Liska  <mliska@suse.cz>
29249         * gcov.c (process_args): Handle new argument 'w'.
29250         (read_graph_file): Assign ID to BBs.
29251         (output_branch_count): Display BB # if verbose flag is set.
29252         (output_lines): Likewise for arcs.
29253         (print_usage): Add '--verbose' option help.
29254         * doc/gcov.texi: Document --verbose (-w) option.
29256 2017-04-28  Martin Liska  <mliska@suse.cz>
29258         * gcov.c (struct block_location_info): New struct.
29259         (process_file): Fill up the new structure.
29260         (read_graph_file): Replace usage of encoding by the newly added
29261         struct.
29262         (add_line_counts): Likewise.
29263         (accumulate_line_counts): Remove usage of the union.
29264         (function_info::function_info): New function.
29265         (function_info::~function_info): Likewise.
29266         (process_file): Call delete instead of release_function.
29267         (release_function): Release the function.
29268         (release_structures): Call delete instead of release_function.
29269         (solve_flow_graph): Replace usage of num_blocks.
29270         (find_exception_blocks): Likewise.
29271         (output_lines): Fix GNU coding style.
29273 2017-04-28  Martin Liska  <mliska@suse.cz>
29275         PR driver/56469
29276         * coverage.c (coverage_remove_note_file): New function.
29277         * coverage.h: Declare the function.
29278         * toplev.c (finalize): Clean if an error has been seen.
29280 2017-04-28  Martin Liska  <mliska@suse.cz>
29282         PR gcov-profile/80031
29283         * gcov-dump.c (tag_blocks): Just print number of basic blocks.
29284         * gcov-io.h (GCOV_TAG_BLOCKS_NUM): Remove unused macro.
29285         * gcov.c (read_graph_file): Read just number of blocks.
29286         * profile.c (branch_prob): Do not stream 0 flags per a basic
29287         block.
29289 2017-04-28  Martin Liska  <mliska@suse.cz>
29291         * gcov-dump.c (tag_*): Add new argument to declarations.
29292         (dump_gcov_file): Likewise.
29293         (tag_blocks): Add and use new argument depth.
29294         (tag_arcs): Likewise.
29295         (tag_lines): Likewise.
29296         (tag_counters): Likewise.
29297         (tag_summary): Likewise.
29298         (dump_working_sets): Use depth to do a proper indentation.
29300 2017-04-28  Jakub Jelinek  <jakub@redhat.com>
29302         PR bootstrap/80531
29303         * cgraph.h (symtab_node::debug_symtab): No longer inline.
29304         * symtab.c (symtab_node::debug_symtab): Move definition here.
29306 2017-04-28  Richard Biener  <rguenther@suse.de>
29308         * lto-streamer.h (LTO_major_version): Bump to 7.
29310 2017-04-28  Richard Biener  <rguenther@suse.de>
29312         * tree-vrp.c (assert_info): New struct.
29313         (add_assert_info): New helper.
29314         (register_edge_assert_for_2): Refactor to add asserts to a vector
29315         of assert_info.
29316         (register_edge_assert_for_1): Likewise.
29317         (register_edge_assert_for): Likewise.
29318         (finish_register_edge_assert_for): New helper actually registering
29319         asserts where live on edge.
29320         (find_conditional_asserts): Adjust.
29321         (find_switch_asserts): Likewise.
29322         (evrp_dom_walker::try_find_new_range): Generalize.
29323         (evrp_dom_walker::before_dom_children): Use register_edge_assert_for.
29325 2017-04-27  Marek Polacek  <polacek@redhat.com>
29327         PR sanitizer/80349
29328         * fold-const.c (fold_binary_loc) <case EQ_EXPR, NE_EXPR>: Convert
29329         arg10 and arg11 to itype.
29331 2017-04-27  Jonathan Wakely  <jwakely@redhat.com>
29333         * doc/extend.texi (Object Size Checking): Improve grammar.
29335 2017-04-27  Richard Earnshaw  <rearnsha@arm.com>
29337         PR target/80530
29338         * config/aarch64/aarch64.c (aarch64_emit_approx_sqrt): Ensure
29339         that the logic for permitting reciprocal estimates matches that
29340         in use_rsqrt_p.
29342 2017-04-27  Jakub Jelinek  <jakub@redhat.com>
29344         PR c++/80534
29345         * tree.c (type_cache_hasher::equal): Only compare
29346         TYPE_TYPELESS_STORAGE flag on non-aggregate element types.
29347         (build_array_type_1): Only hash TYPE_TYPELESS_STORAGE flag on
29348         non-aggregate element types.
29349         * tree.h (TYPE_TYPELESS_STORAGE): Fix comment typo, add more details
29350         about the flag on ARRAY_TYPEs in the comment, formatting fix.
29352 2017-04-27  Richard Biener  <rguenther@suse.de>
29354         PR middle-end/80533
29355         * emit-rtl.c (set_mem_attributes_minus_bitpos): When
29356         stripping ARRAY_REFs from MEM_EXPR make sure we're not
29357         keeping a reference to a trailing array.
29359 2017-04-27  Richard Biener  <rguenther@suse.de>
29361         PR middle-end/80539
29362         * tree-chrec.c (chrec_fold_plus_poly_poly): Deal with not
29363         being in loop-closed SSA form conservatively.
29364         (chrec_fold_multiply_poly_poly): Likewise.
29366 2017-04-27  Tamar Christina  <tamar.christina@arm.com>
29368         PR middle-end/79665
29369         * expr.c (expand_expr_real_2): Move TRUNC_MOD_EXPR, FLOOR_MOD_EXPR,
29370         CEIL_MOD_EXPR, ROUND_MOD_EXPR cases.
29372 2017-04-27  Jakub Jelinek  <jakub@redhat.com>
29374         PR target/77728
29375         * config/aarch64/aarch64.c (struct aarch64_fn_arg_alignment): Remove.
29376         (aarch64_function_arg_alignment): Return unsigned int again, but still
29377         ignore TYPE_FIELDS chain decls other than FIELD_DECLs.
29378         (aarch64_layout_arg): Adjust aarch64_function_arg_alignment caller.
29379         Don't emit -Wpsabi note.
29380         (aarch64_function_arg_boundary): Likewise.
29381         (aarch64_gimplify_va_arg_expr): Adjust aarch64_function_arg_alignment
29382         caller.
29384 2017-04-26  Nathan Sidwell  <nathan@acm.org>
29386         * tree.h (crc32_unsigned_n): Declare.
29387         (crc32_unsigned, crc32_unsigned): Make inline.
29388         * tree.c (crc32_unsigned_bits): Replace with ...
29389         (crc32_unsigned_n): ... this.
29390         (crc32_unsigned, crc32_byte): Remove.
29391         (crc32_string): Remove unnecessary braces.
29393 2017-04-25  Jan Hubicka  <hubicka@ucw.cz>
29395         * ipa-cp.c (estimate_local_effects): Convert sreal to int.
29396         * ipa-inline-analysis.c (MAX_TIME): Remove.
29397         (account_size_time): Use sreal for time.
29398         (dump_inline_summary): Update.
29399         (estimate_function_body_sizes): Update.
29400         (estimate_edge_size_and_time): Update.
29401         (estimate_calls_size_and_time): Update.
29402         (estimate_node_size_and_time): Update.
29403         (inline_merge_summary): Update.
29404         (inline_update_overall_summary): Update.
29405         (estimate_time_after_inlining): Update.
29406         (inline_read_section): Update.
29407         (inline_write_summary): Update.
29408         * ipa-inline.c (compute_uninlined_call_time): Update.
29409         (compute_inlined_call_time): Update.
29410         (recursive_inlining): Update.
29411         (inline_small_functions): Update.
29412         (dump_overall_stats): Update.
29413         * ipa-inline.h: Include sreal.h.
29414         (size_time_entry): Turn time to sreal.
29415         (inline_summary): Turn self_time nad time to sreal.
29417 2017-04-25  Jan Hubicka  <hubicka@ucw.cz>
29419         * sreal.c: Include backend.h, tree.h, gimple.h, cgraph.h and
29420         data-streamer.h
29421         (sreal::stream_out, sreal::stream_in): New.
29422         * sreal.h (sreal::stream_out, sreal::stream_in): Declare.
29424 2017-04-25  Jakub Jelinek  <jakub@redhat.com>
29426         * Makefile.in (s-options): Invoke opt-gather.awk with LC_ALL=C in the
29427         environment.
29429 2017-04-25  Uros Bizjak  <ubizjak@gmail.com>
29431         PR target/70799
29432         * config/i386/i386.c (dimode_scalar_to_vector_candidate_p):
29433         Handle ASHIFTRT.
29434         (dimode_scalar_chain::compute_convert_gain): Ditto.
29435         (dimode_scalar_chain::make_vector_copies): Ditto.
29436         (dimode_scalar_chain::convert_reg): Ditto.
29437         (dimode_scalar_chain::convert_insn): Ditto.
29438         * config/i386/sse.md (VI24_AVX512BW_1): Remove mode iterator.
29439         (VI248_AVX512BW_1): New mode iterator.
29440         (<mask_codefor>ashr<mode>3<mask_name>): Merge insn pattern with
29441         <mask_codefor>ashrv2di3<mask_name> insn using VI248_AVX512BW_1
29442         mode iterator.
29444 2017-04-25  Martin Sebor  <msebor@redhat.com>
29446         PR tree-optimization/80497
29447         * gimple-ssa-sprintf.c (get_int_range): Avoid assuming all integer
29448         constants are representable in HOST_WIDE_INT.
29449         (parse_directive): Ditto.
29451 2017-04-25  Martin Sebor  <msebor@redhat.com>
29453         PR bootstrap/80486
29454         * dominance.c (dom_info::m_n_basic_blocks): Change type to unsigned.
29455         (new_zero_array): Adjust signature.
29456         (dom_info::dom_init): Used unsigned rather that size_t.
29457         (dom_info::dom_info): Same.
29459 2017-04-25  Ramana Radhakrishnan  <ramana.radhakrishnan@arm.com>
29460             Jakub Jelinek  <jakub@redhat.com>
29462         PR target/77728
29463         * config/arm/arm.c: Include gimple.h.
29464         (aapcs_layout_arg): Emit -Wpsabi note if arm_needs_doubleword_align
29465         returns negative, increment ncrn only if it returned positive.
29466         (arm_needs_doubleword_align): Return int instead of bool,
29467         ignore DECL_ALIGN of non-FIELD_DECL TYPE_FIELDS chain
29468         members, but if there is any such non-FIELD_DECL
29469         > PARM_BOUNDARY aligned decl, return -1 instead of false.
29470         (arm_function_arg): Emit -Wpsabi note if arm_needs_doubleword_align
29471         returns negative, increment nregs only if it returned positive.
29472         (arm_setup_incoming_varargs): Likewise.
29473         (arm_function_arg_boundary): Emit -Wpsabi note if
29474         arm_needs_doubleword_align returns negative, return
29475         DOUBLEWORD_ALIGNMENT only if it returned positive.
29477 2017-04-25  Marek Polacek  <polacek@redhat.com>
29479         PR sanitizer/80349
29480         * fold-const.c (fold_binary_loc) <case BIT_IOR_EXPR>: Convert arg0's
29481         first argument to type.
29483 2017-04-25  Bill Seurer  <seurer@linux.vnet.ibm.com>
29485         PR target/80482
29486         * config/rs6000/rs6000-c.c (altivec_resolve_overloaded_builtin): Change
29487         type checks to test for compatibility instead of equality.
29489 2017-04-25  Ramana Radhakrishnan  <ramana.radhakrishnan@arm.com>
29490             Jakub Jelinek  <jakub@redhat.com>
29492         PR target/77728
29493         * config/aarch64/aarch64.c (struct aarch64_fn_arg_alignment): New
29494         type.
29495         (aarch64_function_arg_alignment): Return aarch64_fn_arg_alignment
29496         struct.  Ignore DECL_ALIGN of decls other than FIELD_DECL for
29497         the alignment computation, but return their maximum in warn_alignment.
29498         (aarch64_layout_arg): Adjust aarch64_function_arg_alignment caller.
29499         Emit a -Wpsabi note if warn_alignment is 16 bytes, but alignment
29500         is smaller.
29501         (aarch64_function_arg_boundary): Likewise.  Simplify using MIN/MAX.
29502         (aarch64_gimplify_va_arg_expr): Adjust aarch64_function_arg_alignment
29503         caller.
29505 2017-04-25  Claudiu Zissulescu  <claziss@synopsys.com>
29507         * config/arc/simdext.md (dmpyh): Fix typo.
29509 2017-04-25  Richard Biener  <rguenther@suse.de>
29511         PR tree-optimization/80492
29512         * alias.c (compare_base_decls): Handle registers with asm
29513         specification conservatively.
29514         * tree-ssa-alias.c (decl_refs_may_alias_p): Handle
29515         compare_base_decls returning dont-know properly.
29517 2017-04-25  Claudiu Zissulescu  <claziss@synopsys.com>
29519         * config/arc/arc.c (LEGITIMATE_OFFSET_ADDRESS_P): Delete macro.
29520         (legitimate_offset_address_p): New function.
29521         (arc_legitimate_address_p): Use above function.
29523 2017-04-25  Claudiu Zissulescu  <claziss@synopsys.com>
29525         * config/arc/arc.c (arc_output_mi_thunk): Emit PIC calls.
29527 2017-04-25  Claudiu Zissulescu  <claziss@synopsys.com>
29529         * config/arc/arc.c (arc_conditional_register_usage): Use ACCL,
29530         ACCH registers whenever they are available.
29532 2017-04-25  Claudiu Zissulescu  <claziss@synopsys.com>
29534         * config/arc/arc.c (arc_conditional_register_usage): Make D0, D1
29535         double regs fix when not used.
29537 2017-04-25  Claudiu Zissulescu  <claziss@synopsys.com>
29539         * config/arc/arc.h (REGNO_OK_FOR_BASE_P): Consider also extension
29540         core registers.
29541         (REG_OK_FOR_INDEX_P_NONSTRICT): Likewise.
29542         (REG_OK_FOR_BASE_P_NONSTRICT): Likewise.
29544 2017-04-25  Claudiu Zissulescu  <claziss@synopsys.com>
29546         * config/arc/arc.c (arc_output_addsi): Check for h-register class
29547         when emitting short ADD instructions.
29549 2017-04-25  Claudiu Zissulescu  <claziss@synopsys.com>
29551         * config/arc/arc.md (cmpsi_cc_insn_mixed): Use 'h' register
29552         constraint.
29553         (cmpsi_cc_c_insn): Likewise.
29554         (cbranchsi4_scratch): Compute proper instruction length using
29555         compact_hreg_operand.
29556         * config/arc/predicates.md (compact_hreg_operand): New predicate.
29558 2017-04-25  Richard Biener  <rguenther@suse.de>
29560         PR middle-end/80509
29561         * passes.c (pass_manager::pass_manager): Initialize
29562         m_name_to_pass_map.
29564 2017-04-25  Richard Biener  <rguenther@suse.de>
29566         PR tree-optimization/79201
29567         * tree-ssa-sink.c (statement_sink_location): Handle calls.
29569 2017-04-25  Andreas Krebbel  <krebbel@linux.vnet.ibm.com>
29571         PR target/80464
29572         * config/s390/vector.md: Split MEM->GPR vector moves for
29573         non-s_operand addresses.
29575 2017-04-25  Andreas Krebbel  <krebbel@linux.vnet.ibm.com>
29577         PR target/79895
29578         * config/s390/predicates.md (reload_const_wide_int_operand): New
29579         predicate.
29580         * config/s390/s390.md ("movti"): Remove d/P alternative.
29581         ("movti_bigconst"): New pattern definition.
29583 2017-04-25  Dominik Vogt  <vogt@linux.vnet.ibm.com>
29585         PR target/80080
29586         * s390-protos.h (s390_expand_cs_hqi): Removed.
29587         (s390_expand_cs, s390_expand_atomic_exchange_tdsi): New prototypes.
29588         * config/s390/s390.c (s390_emit_compare_and_swap): Handle all integer
29589         modes as well as CCZ1mode and CCZmode.
29590         (s390_expand_atomic_exchange_tdsi, s390_expand_atomic): Adapt to new
29591         signature of s390_emit_compare_and_swap.
29592         (s390_expand_cs_hqi): Likewise, make static.
29593         (s390_expand_cs_tdsi): Generate an explicit compare before trying
29594         compare-and-swap, in some cases.
29595         (s390_expand_cs): Wrapper function.
29596         (s390_expand_atomic_exchange_tdsi): New backend specific expander for
29597         atomic_exchange.
29598         (s390_match_ccmode_set): Allow CCZmode <-> CCZ1 mode.
29599         * config/s390/s390.md ("atomic_compare_and_swap<mode>"): Merge the
29600         patterns for small and large integers.  Forbid symref memory operands.
29601         Move expander to s390.c.  Require cc register.
29602         ("atomic_compare_and_swap<DGPR:mode><CCZZ1:mode>_internal")
29603         ("*atomic_compare_and_swap<TDI:mode><CCZZ1:mode>_1")
29604         ("*atomic_compare_and_swapdi<CCZZ1:mode>_2")
29605         ("*atomic_compare_and_swapsi<CCZZ1:mode>_3"): Use s_operand to forbid
29606         symref memory operands.  Remove CC mode and call s390_match_ccmode
29607         instead.
29608         ("atomic_exchange<mode>"): Allow and implement all integer modes.
29610 2017-04-25  Dominik Vogt  <vogt@linux.vnet.ibm.com>
29612         * config/s390/s390.md (define_peephole2): New peephole to help
29613         combining the load-and-test pattern with volatile memory.
29615 2017-04-25  Dominik Vogt  <vogt@linux.vnet.ibm.com>
29617         * config/s390/s390.md ("cstorecc4"): Use load-on-condition and deal
29618         with CCZmode for TARGET_Z196.
29620 2017-04-25  Jakub Jelinek  <jakub@redhat.com>
29622         PR rtl-optimization/80501
29623         * combine.c (make_compound_operation_int): Set subreg_code to SET
29624         even for AND with mask of the sign bit of mode.
29626         PR rtl-optimization/80500
29627         * loop-unroll.c (combine_var_copies_in_loop_exit): Call copy_rtx on
29628         sum's initial value.
29630 2017-04-25  Julian Brown  <julian@codesourcery.com>
29631             Naveen H.S  <Naveen.Hurugalawadi@cavium.com>
29633         * config/aarch64/thunderx2t99.md (thunderx2t99_crc): New Reservation.
29635 2017-04-25  Marc Glisse  <marc.glisse@inria.fr>
29637         * fold-const.c (tree_single_nonzero_warnv_p): Handle SSA_NAME.
29639 2017-04-25  Julian Brown  <julian@codesourcery.com>
29640             Naveen H.S  <Naveen.Hurugalawadi@cavium.com>
29642         * config/aarch64/thunderx2t99.md (thunderx2t99_aes): New Reservation.
29643         (thunderx2t99_sha): New Reservation.
29645 2017-04-25  Julian Brown  <julian@codesourcery.com>
29646             Naveen H.S  <Naveen.Hurugalawadi@cavium.com>
29648         * config/aarch64/aarch64-simd.md (aarch64_simd_vec_set<mode>): Fix
29649         type for 1-element load.
29651 2017-04-24  Marc Glisse  <marc.glisse@inria.fr>
29653         * match.pd (X/[ex]C CMP Y/[ex]C): New transformation.
29655 2017-04-24  Martin Jambor  <mjambor@suse.cz>
29657         PR tree-optimization/80293
29658         * tree-sra.c (scalarizable_type_p): New parameter const_decl, make
29659         char arrays not totally scalarizable if it is false.
29660         (analyze_all_variable_accesses): Pass correct value in the new
29661         parameter.  Add a statistics counter.
29663 2017-04-24  Jan Hubicka  <hubicka@ucw.cz>
29665         PR middle-end/79931
29666         * ipa-devirt.c (dump_possible_polymorphic_call_targets): Fix ICE.
29668 2017-04-24  Richard Biener  <rguenther@suse.de>
29670         PR tree-optimization/80494
29671         * tree-scalar-evolution.c (analyze_scalar_evolution_1): Bail
29672         out for complex types.
29674 2017-04-24  Richard Biener  <rguenther@suse.de>
29676         * tree-ssa-sccvn.h (run_scc_vn): Adjust prototype.
29677         * tree-ssa-sccvn.c (print_scc): Print SCC size.
29678         (extract_and_process_scc_for_name): Never fail but drop SCC to varying.
29679         (DFS): Adjust and never fail.
29680         (sccvn_dom_walker::fail): Remove.
29681         (sccvn_dom_walker::before_dom_children): Adjust.
29682         (run_scc_vn): Likewise and never fail.
29683         * tree-ssa-pre.c (pass_pre::execute): Adjust.
29684         (pass_fre::execute): Likewise.
29686 2017-04-24  Richard Biener  <rguenther@suse.de>
29688         PR tree-optimization/79725
29689         * tree-ssa-sink.c (statement_sink_location): Return whether
29690         failure reason was zero uses.  Move that check later.
29691         (sink_code_in_bb): Deal with zero uses by removing the stmt
29692         if possible.
29694 2017-04-24  Richard Biener  <rguenther@suse.de>
29696         PR c++/2972
29697         * tree-ssa-uninit.c (warn_uninitialized_vars): Handle some
29698         pointer-based references.
29700 2017-04-24  Richard Biener  <rguenther@suse.de>
29702         PR bootstrap/79814
29703         * pass_manager.h (pass_manager::operator new): Remove.
29704         (pass_manager::operator delete): Likewise.
29705         * passes.c (pass_manager::operator new): Remove.
29706         (pass_manager::operator delete): Likewise.
29707         (pass_manager::pass_manager): Zero individual pass members.
29709 2017-04-23  Uros Bizjak  <ubizjak@gmail.com>
29711         PR target/70799
29712         * config/i386/i386.c (dimode_scalar_to_vector_candidate_p)
29713         <case ASHIFT, case LSHIFTRT>: Also consider variable shifts.
29714         Check "XEXP (src, 1)" operand here.
29715         <case PLUS, case MINUS, case IOR, case XOR, case AND>:
29716         Check "XEXP (src, 1)" operand here.
29717         (dimode_scalar_chain::make_vector_copies): Detect count register
29718         of a shift instruction.  Zero extend count register from QImode
29719         to DImode to satisfy vector shift pattern count operand predicate.
29720         Substitute vector shift count operand with a DImode copy.
29721         (dimode_scalar_chain::convert_reg): Ditto, zero-extend from
29722         vector register.
29724 2017-04-21  Uros Bizjak  <ubizjak@gmail.com>
29726         * config/i386/i386.md (*extzvqi_mem_rex64): Move above *extzv<mode>.
29727         Remove UNSPEC_NOREX_MEM tag.  Update corresponding peephole2 pattern.
29728         (*insvqi_1_mem_rex64): Move above insv<mode>_1.  Remove
29729         UNSPEC_NOREX_MEM tag.  Update corresponding peephole2 pattern.
29730         (UNSPEC_NOREX_MEM): Remove definition.
29732 2017-04-21  Richard Biener  <rguenther@suse.de>
29734         PR tree-optimization/79547
29735         * tree-ssa-structalias.c (find_func_aliases_for_builtin_call):
29736         Handle strlen, strcmp, strncmp, strcasecmp, strncasecmp, memcmp,
29737         bcmp, strspn, strcspn, __builtin_object_size and __builtin_constant_p
29738         without any constraints.
29740 2017-04-21  Richard Biener  <rguenther@suse.de>
29742         PR tree-optimization/78847
29743         * fold-const.c (split_tree): Handle POINTER_PLUS_EXPR.
29745 2017-04-21  Richard Biener  <rguenther@suse.de>
29747         * tree.h (build_qualified_type): Annotate with CXX_MEM_STAT_INFO.
29748         (build_distinct_type_copy): Likewise.
29749         (build_variant_type_copy): Likewise.
29750         * tree.c (build_qualified_type): Pass down mem-stat info.
29751         (build_distinct_type_copy): Likewise.
29752         (build_variant_type_copy): Likewise.
29754 2017-04-21  Richard Biener  <rguenther@suse.de>
29756         PR tree-optimization/80237
29757         * tree-ssa-pre.c (find_leader_in_sets): Add third set argument,
29758         defaulted to NULL.
29759         (phi_translate_1): Also allow a leader in AVAIL_OUT of pred
29760         for a simplified result.
29762 2016-04-21  Richard Biener  <rguenther@suse.de>
29764         * tree-ssa-loop-ivcanon.c (constant_after_peeling): Do not require
29765         sth as strict as a simple_iv but a chrec without symbols and an
29766         operand defined in the loop we are peeling (and not some subloop).
29767         (propagate_constants_for_unrolling): Propagate all constants.
29769 2017-04-20  Uros Bizjak  <ubizjak@gmail.com>
29771         PR target/79804
29772         * config/i386/i386.c (print_reg): Remove assert for disalowed
29773         regno values, call output_operand_lossage instead.
29775 2017-04-20  Uros Bizjak  <ubizjak@gmail.com>
29777         PR target/78090
29778         * config/i386/constraints.md (Yc): New register constraint.
29779         * config/i386/i386.md (*float<SWI48:mode><MODEF:mode>2_mixed):
29780         Use Yc constraint for alternative 2 of operand 0.  Remove
29781         preferred_for_speed attribute.
29783 2017-04-20  Alexander Monakov  <amonakov@ispras.ru>
29785         * omp-low.c (lower_lastprivate_clauses): Correct handling of linear and
29786         lastprivate clauses in SIMT case.
29788 2017-04-20  Volker Reichelt  <v.reichelt@netcologne.de>
29790         * doc/invoke.texi (-Wextra-semi): Document new warning option.
29792 2017-04-20  Richard Biener  <rguenther@suse.de>
29794         PR tree-optimization/57796
29795         * tree-vect-stmts.c (vect_model_store_cost): Cost scatters
29796         as N scalar stores.
29797         (vect_model_load_cost): Cost gathers as N scalar loads.
29799 2017-04-20  Richard Biener  <rguenther@suse.de>
29801         * ggc-page.c (ggc_allocated_p): Rename to ...
29802         (safe_lookup_page_table_entry): ... this and return the lookup
29803         result.
29804         (gt_ggc_m_S): Use safe_lookup_page_table_entry.
29806 2017-04-20  Richard Biener  <rguenther@suse.de>
29808         PR tree-optimization/80453
29809         * tree-ssa-sccvn.h (struct vn_phi_s): Add cclhs and ccrhs members.
29810         * tree-ssa-sccvn.c (cond_stmts_equal_p): Use recorded lhs and rhs
29811         from the conditions.
29812         (vn_phi_eq): Pass them down.
29813         (vn_phi_lookup): Record them.
29814         (vn_phi_insert): Likewise.
29816 2017-04-20  Matthew Fortune  <matthew.fortune@imgtec.com>
29818         * config/mips/mips.c (mips_expand_vec_perm_const): Re-fix
29819         uninitialized variable warning to avoid buffer overrun.
29821 2017-04-20  Alexander Monakov  <amonakov@ispras.ru>
29823         PR other/71250
29824         * doc/invoke.texi (-Wmissing-field-initializers): Mention that warning
29825         is suppressed for '{ 0 }' in C.
29827 2017-04-20  Jakub Jelinek  <jakub@redhat.com>
29829         * BASE-VER: Set to 8.0.0.
29831 2017-04-20  Thomas Preud'homme  <thomas.preudhomme@arm.com>
29833         * config/arm/arm.c (arm_elf_asm_cdtor): Create non-default
29834         priority .init_array and .fini_array section with SECTION_NOTYPE
29835         flag.
29837 2017-04-20  Jakub Jelinek  <jakub@redhat.com>
29839         PR middle-end/80423
29840         * tree.h (build_array_type): Add typeless_storage default argument.
29841         * tree.c (type_cache_hasher::equal): Also compare
29842         TYPE_TYPELESS_STORAGE flag for ARRAY_TYPEs.
29843         (build_array_type): Add typeless_storage argument, set
29844         TYPE_TYPELESS_STORAGE to it, if shared also hash it, and pass to
29845         recursive call.
29846         (build_nonshared_array_type): Adjust build_array_type_1 caller.
29847         (build_array_type): Likewise.  Add typeless_storage argument.
29849 2017-04-19  Eric Botcazou  <ebotcazou@adacore.com>
29850             Jakub Jelinek  <jakub@redhat.com>
29852         PR tree-optimization/80426
29853         * tree-vrp.c (extract_range_from_binary_expr_1): For an additive
29854         operation on symbolic operands, also compute the overflow for the
29855         invariant part when the operation degenerates into a negation.
29857 2017-04-19  Jakub Jelinek  <jakub@redhat.com>
29859         PR debug/80461
29860         * dwarf2out.c (modified_type_die, gen_type_die_with_usage):
29861         Check for t with zero TYPE_QUALS_NO_ADDR_SPACE.
29863         PR debug/80436
29864         * tree-ssa-loop-manip.c (find_uses_to_rename_def): Ignore debug uses.
29866 2017-04-19  Georg-Johann Lay  <avr@gjlay.de>
29868         PR target/80462
29869         * config/avr/avr.c (tree.h): Include it.
29870         (cgraph.h): Include it.
29871         (avr_encode_section_info): Don't warn for uninitialized progmem
29872         variable if it's just an alias.
29874 2017-04-19  Richard Biener  <rguenther@suse.de>
29876         PR ipa/65972
29877         * auto-profile.c (afdo_vpt_for_early_inline): Update SSA
29878         when needed by AutoPGO.
29880 2017-04-19  Paulo J. Matos  <paulo@matos-sorge.com>
29882         PR lto/50345
29883         * doc/lto.texi: Remove an extra 'that'.
29885 2017-04-19  Segher Boessenkool  <segher@kernel.crashing.org>
29887         PR rtl-optimization/80429
29888         * ira.c (split_live_ranges_for_shrink_wrap): Don't split regs that
29889         are only used in debug insns.
29891 2017-04-19  Eric Botcazou  <ebotcazou@adacore.com>
29892             Vladimir Makarov  <vmakarov@redhat.com>
29894         * config/sparc/predicates.md (input_operand): Add comment.  Return
29895         true for any memory operand when LRA is in progress.
29896         * config/sparc/sparc.c (sparc_expand_move): Minor formatting fix.
29898 2017-04-18  Jeff Law  <law@redhat.com>
29900         PR target/74563
29901         * mips.md ({return,simple_return}_internal): Do not overwrite
29902         operands[0].
29904 2017-04-18  Jakub Jelinek  <jakub@redhat.com>
29906         PR tree-optimization/80443
29907         * tree-vrp.c (intersect_ranges): For signed 1-bit precision type,
29908         instead of adding 1, subtract -1 and similarly instead of subtracting
29909         1 add -1.
29911 2017-04-18  Richard Sandiford  <richard.sandiford@arm.com>
29913         PR rtl-optimization/80357
29914         * haifa-sched.c (tmp_bitmap): New variable.
29915         (model_recompute): Handle duplicate use records.
29916         (alloc_global_sched_pressure_data): Initialize tmp_bitmap.
29917         (free_global_sched_pressure_data): Free it.
29919 2017-04-18  Bernd Edlinger  <bernd.edlinger@hotmail.de>
29921         Revert:
29922         2017-02-20  Bernd Edlinger  <bernd.edlinger@hotmail.de>
29923         * Makefile.in (BUILD_SYSTEM_HEADER_DIR): New make variabe.
29924         (LIMITS_H_TEST, if_multiarch, stmp-fixinc): Use BUILD_SYSTEM_HEADER_DIR
29925         instead of SYSTEM_HEADER_DIR.
29927 2017-04-18  Jeff Law  <law@redhat.com>
29929         PR middle-end/80422
29930         * cfgcleanup.c (try_crossjump_to_edge): Verify SRC1 and SRC2 have
29931         predecessors after walking up the insn chain.
29933 2017-04-18  Jakub Jelinek  <jakub@redhat.com>
29935         PR debug/80263
29936         * dwarf2out.c (modified_type_die): Try harder not to emit internal
29937         sizetype type into debug info.
29939 2017-04-18  Michael Meissner  <meissner@linux.vnet.ibm.com>
29941         PR target/80099
29942         * config/rs6000/rs6000.c (rs6000_expand_vector_extract): Eliminate
29943         unneeded test for TARGET_UPPER_REGS_SF.
29944         * config/rs6000/vsx.md (vsx_extract_v4sf_var): Likewise.
29946 2017-04-18  Jakub Jelinek  <jakub@redhat.com>
29948         PR sanitizer/80444
29949         * sancov.c (sancov_pass): Use gsi_start_nondebug_after_labels_bb
29950         instead of gsi_after_labels.
29952 2017-04-18  Jeff Law  <law@redhat.com>
29954         * regcprop.c (maybe_mode_change): Avoid creating copies of the
29955         stack pointer.
29957         Revert:
29958         2017-04-13  Jeff Law  <law@redhat.com>
29959         * config/mips.mips.md (zero_extendsidi2): Do not allow SP to appear
29960         in operands[1] if it is a MEM and TARGET_MIPS16 is active.
29962 2017-04-18  Georg-Johann Lay  <avr@gjlay.de>
29964         PR target/79453
29965         * config/avr/avr.c (intl.h): Include it.
29966         (avr_pgm_check_var_decl) [reason]: Wrap diagnostic snippets into _().
29968 2017-04-18  Martin Liska  <mliska@suse.cz>
29970         PR gcov-profile/78783
29971         * gcov-tool.c (gcov_output_files): Validate that destination
29972         file is either removed by the tool or by a user.
29974 2017-04-14  Andrew Burgess  <andrew.burgess@embecosm.com>
29975             Guy Benyei  <guybe@mellanox.com>
29977         * config/arc/arc.c (arc_reorg): Move loop_end_id into a more local
29978         block, and do not negate it, the stored id is already negative.
29980 2017-04-14  Andrew Burgess  <andrew.burgess@embecosm.com>
29982         * config/arc/arc.md (doloop_begin_i): Use @pcl assembler syntax.
29984 2017-04-14  Michael Meissner  <meissner@linux.vnet.ibm.com>
29986         PR target/80098
29987         * config/rs6000/rs6000-cpus.def (OTHER_P9_VECTOR_MASKS): Define
29988         masks of options that should be turned off if the VSX vector
29989         options are turned off.
29990         (OTHER_P8_VECTOR_MASKS): Likewise.
29991         (OTHER_VSX_VECTOR_MASKS): Likewise.
29992         * config/rs6000/rs6000.c (rs6000_option_override_internal): Call
29993         rs6000_disable_incompatible_switches to validate no type switches
29994         like -mvsx.
29995         (rs6000_incompatible_switch): New function to disallow turning on
29996         other vector options if -mno-vsx, -mno-power8-vector, or
29997         -mno-power9-vector are specified.
29999 2017-04-14  Claudiu Zissulescu  <claziss@synopsys.com>
30001         * config/arc/arc.h (CRT_CALL_STATIC_FUNCTION): Use long calls.
30003 2017-04-14  Claudiu Zissulescu  <claziss@synopsys.com>
30005         * config/arc/arc-protos.h (arc_decl_pretend_args): Remove.
30006         * config/arc/arc.c (arc_decl_pretend_args): Likewise.
30007         * config/arc/arc.h (CFA_FRAME_BASE_OFFSET): Likewise.
30008         (ARG_POINTER_CFA_OFFSET): Likewise.
30010 2017-04-14  Claudiu Zissulescu  <claziss@synopsys.com>
30012         * config/arc/arc.c (arc_mode_dependent_address_p): Relax
30013         conditions to take advantage of various optimizations.
30015 2017-04-13  Jeff Law  <law@redhat.com>
30017         * config/mips.mips.md (zero_extendsidi2): Do not allow SP to appear
30018         in operands[1] if it is a MEM and TARGET_MIPS16 is active.
30019         (zero_extendsidi2_dext): Likewise.
30021 2017-04-13  Jakub Jelinek  <jakub@redhat.com>
30023         PR sanitizer/80403
30024         * fold-const.c (fold_ternary_loc): Revert
30025         use op0 instead of fold_convert_loc (loc, type, arg0) part of
30026         2017-04-12 change.
30028 2017-04-13  Vladimir Makarov  <vmakarov@redhat.com>
30030         PR rtl-optimization/80343
30031         * lra-remat.c (update_scratch_ops): Assign original hard reg to
30032         new scratch pseudo.
30034 2017-04-13  Denis Khalikov <d.khalikov@partner.samsung.com>
30036         PR sanitizer/80414
30037         * ubsan.c (ubsan_expand_bounds_ifn): Pass original index
30038         to ubsan_encode_value.
30040 2017-04-13  Jeff Law  <law@redhat.com>
30042         * reload1.c (eliminate_regs_1): Call gen_rtx_raw_SUBREG for SUBREGs
30043         appearing in DEBUG_INSNs.
30045 2017-04-13  Martin Liska  <mliska@suse.cz>
30047         PR gcov-profile/80413
30048         * gcov-io.c (gcov_write_string): Copy to buffer just when
30049         allocated size is greater than zero.
30051 2017-04-13  Jakub Jelinek  <jakub@redhat.com>
30053         PR debug/80321
30054         * dwarf2out.c (decls_for_scope): Ignore declarations of
30055         current_function_decl in BLOCK_NONLOCALIZED_VARS.
30057 2017-04-12  Jan Hubicka  <hubicka@ucw.cz>
30059         PR lto/69953
30060         * ipa-visibility.c (non_local_p): Fix typos.
30061         (localize_node): When localizing symbol in same comdat group,
30062         dissolve the group only when we know external symbols are going
30063         to be privatized.
30064         (function_and_variable_visibility): Do not localize DECL_EXTERNAL.
30066 2017-04-12  Jakub Jelinek  <jakub@redhat.com>
30068         PR tree-optimization/79390
30069         * optabs.c (emit_conditional_move): If the preferred op2/op3 operand
30070         order does not result in usable sequence, retry with reversed operand
30071         order.
30073         PR sanitizer/80403
30074         PR sanitizer/80404
30075         PR sanitizer/80405
30076         * fold-const.c (fold_ternary_loc): Use op1 instead of arg1 as argument
30077         to fold_build2_loc.  Convert TREE_OPERAND (tem, 0) to type.  Use
30078         op0 instead of fold_convert_loc (loc, type, arg0).
30080 2017-04-12  Jeff Law  <law@redhat.com>
30082         * genattrtab.c (write_eligible_delay): Verify DELAY_INSN still
30083         has a delay slot in the generated code.
30085         * config/cris/cris.md (cris_preferred_reload_class): Return
30086         GENNONACR_REGS rather than GENERAL_REGS.
30088 2017-04-12  Jakub Jelinek  <jakub@redhat.com>
30090         PR c/80163
30091         * expr.c <CASE_CONVERT>: For EXPAND_INITIALIZER determine SIGN_EXTEND
30092         vs. ZERO_EXTEND based on signedness of treeop0's type rather than
30093         signedness of the result type.
30095 2017-04-12  Richard Biener  <rguenther@suse.de>
30096             Jeff Law  <law@redhat.com>
30098         PR tree-optimization/80359
30099         * tree-ssa-dse.c (maybe_trim_partially_dead_store): Do not
30100         trim stores to TARGET_MEM_REFs.
30102 2017-04-12  Richard Biener  <rguenther@suse.de>
30104         PR tree-optimization/79390
30105         * gimple-ssa-split-paths.c (is_feasible_trace): Restrict
30106         threading case even more.
30108 2017-04-12  Segher Boessenkool  <segher@kernel.crashing.org>
30110         PR target/80382
30111         * config/rs6000/sync.md (atomic_load<mode>, atomic_store<mode): Test
30112         for quad_address_p for TImode, instead of just not indexed_address.
30114 2017-04-12  Richard Biener  <rguenther@suse.de>
30115             Bernd Edlinger  <bernd.edlinger@hotmail.de>
30117         PR middle-end/79671
30118         * alias.c (component_uses_parent_alias_set_from): Handle
30119         TYPE_TYPELESS_STORAGE.
30120         (get_alias_set): Likewise.
30121         * tree-core.h (tree_type_common): Add typeless_storage flag.
30122         * tree.h (TYPE_TYPELESS_STORAGE): New macro.
30123         * stor-layout.c (place_union_field): Set TYPE_TYPELESS_STORAGE
30124         for types containing members with TYPE_TYPELESS_STORAGE.
30125         (place_field): Likewise.
30126         (layout_type): Likewise for ARRAY_TYPE.
30127         * lto-streamer-out.c (hash_tree): Hash TYPE_TYPELESS_STORAGE.
30128         * tree-streamer-in.c (unpack_ts_type_common_value_fields): Stream
30129         TYPE_TYPELESS_STORAGE.
30130         * tree-streamer-out.c (pack_ts_type_common_value_fields): Likewise.
30132 2017-04-12  Jakub Jelinek  <jakub@redhat.com>
30134         PR sanitizer/80349
30135         * fold-const.c (fold_binary_loc) <case BIT_IOR_EXPR>: Convert arg0's
30136         first argument to type.
30138 2017-04-11  Bill Schmidt  <wschmidt@linux.vnet.ibm.com>
30140         PR target/80376
30141         PR target/80315
30142         * config/rs6000/rs6000.c (rs6000_expand_unop_builtin): Return
30143         CONST0_RTX (mode) rather than const0_rtx where appropriate.
30144         (rs6000_expand_binop_builtin): Likewise.
30145         (rs6000_expand_ternop_builtin): Likewise; also add missing
30146         vsx_xxpermdi_* variants; also fix typo (arg1 => arg2) for
30147         vshasigma built-ins.
30148         * doc/extend.texi: Document that vec_xxpermdi's third argument
30149         must be a constant.
30151 2017-04-11  Uros Bizjak  <ubizjak@gmail.com>
30153         * config/i386/i386.c (dimode_scalar_chain::compute_convert_gain):
30154         Use shift_const cost parameter when calculating gain of STV shifts.
30156 2017-04-11  Vladimir Makarov  <vmakarov@redhat.com>
30158         PR rtl-optimization/70478
30159         * lra-constraints.c (process_alt_operands): Check memory for
30160         disfavoring memory insn operand.
30162 2017-04-11  Jakub Jelinek  <jakub@redhat.com>
30164         PR middle-end/80100
30165         * simplify-rtx.c (simplify_binary_operation_1) <case IOR>: Perform
30166         left shift in unsigned HOST_WIDE_INT type.
30168         PR rtl-optimization/80385
30169         * simplify-rtx.c (simplify_unary_operation_1): Don't transform
30170         (not (neg X)) into (plus X -1) for complex or non-integral modes.
30172         PR libgomp/80394
30173         * omp-low.c (scan_omp_task): Don't optimize away empty tasks
30174         if they have any depend clauses.
30176 2017-04-11  Martin Liska  <mliska@suse.cz>
30178         PR ipa/80212
30179         * cgraph.c (cgraph_node::dump): Dump calls_comdat_local.
30180         * ipa-split.c (split_function): Create a local comdat symbol
30181         if caller is in a comdat group.
30183 2017-04-11  Martin Liska  <mliska@suse.cz>
30185         PR ipa/80212
30186         * ipa-cp.c (determine_versionability): Handle calls_comdat_local
30187         flags.
30189 2017-04-11  Martin Sebor  <msebor@redhat.com>
30191         PR middle-end/80364
30192         * gimple-ssa-sprintf.c (get_int_range): Remove second argument and
30193         always use the int type.  Use INTEGRAL_TYPE_P() rather than testing
30194         for INTEGER_TYPE.
30195         (directive::set_width, directive::set_precision, format_character):
30196         Adjust.
30197         (parse_directive): Use INTEGRAL_TYPE_P() rather than testing for
30198         INTEGER_TYPE.
30200 2017-04-11  Richard Earnshaw  <rearnsha@arm.com>
30202         PR target/80389
30203         * config/arm/arm.c (arm_configure_build_target): When -mcpu and -arch
30204         conflict, set target->arch_name instead of target->cpu_name.
30206 2017-04-11  Richard Biener  <rguenther@suse.de>
30208         PR tree-optimization/80374
30209         * tree-ssa-dom.c (derive_equivalences_from_bit_ior): Use
30210         build_zero_cst, remove fold_convertible_p check again.
30212 2017-04-11  Martin Liska  <mliska@suse.cz>
30214         PR sanitizer/70878
30215         * ubsan.c (instrument_object_size): Do not instrument register
30216         variables.
30218 2017-04-11  Jakub Jelinek  <jakub@redhat.com>
30220         PR target/80381
30221         * config/i386/i386-builtin-types.def
30222         (V16HI_FTYPE_V16HI_INT_V16HI_UHI_COUNT,
30223         V16HI_FTYPE_V16HI_V8HI_V16HI_UHI_COUNT,
30224         V16SI_FTYPE_V16SI_INT_V16SI_UHI_COUNT,
30225         V16SI_FTYPE_V16SI_V4SI_V16SI_UHI_COUNT,
30226         V2DI_FTYPE_V2DI_INT_V2DI_UQI_COUNT,
30227         V2DI_FTYPE_V2DI_V2DI_V2DI_UQI_COUNT,
30228         V32HI_FTYPE_V32HI_INT_V32HI_USI_COUNT,
30229         V32HI_FTYPE_V32HI_V8HI_V32HI_USI_COUNT,
30230         V4DI_FTYPE_V4DI_INT_V4DI_UQI_COUNT,
30231         V4DI_FTYPE_V4DI_V2DI_V4DI_UQI_COUNT,
30232         V4SI_FTYPE_V4SI_INT_V4SI_UQI_COUNT,
30233         V4SI_FTYPE_V4SI_V4SI_V4SI_UQI_COUNT,
30234         V8DI_FTYPE_V8DI_INT_V8DI_UQI_COUNT,
30235         V8DI_FTYPE_V8DI_V2DI_V8DI_UQI_COUNT,
30236         V8HI_FTYPE_V8HI_INT_V8HI_UQI_COUNT,
30237         V8HI_FTYPE_V8HI_V8HI_V8HI_UQI_COUNT,
30238         V8SI_FTYPE_V8SI_INT_V8SI_UQI_COUNT,
30239         V8SI_FTYPE_V8SI_V4SI_V8SI_UQI_COUNT): New function type aliases.
30240         * config/i386/i386-builtin.def (__builtin_ia32_pslld512_mask,
30241         __builtin_ia32_pslldi512_mask, __builtin_ia32_psllq512_mask,
30242         __builtin_ia32_psllqi512_mask, __builtin_ia32_psrad512_mask,
30243         __builtin_ia32_psradi512_mask, __builtin_ia32_psraq512_mask,
30244         __builtin_ia32_psraqi512_mask, __builtin_ia32_psrld512_mask,
30245         __builtin_ia32_psrldi512_mask, __builtin_ia32_psrlq512_mask,
30246         __builtin_ia32_psrlqi512_mask, __builtin_ia32_psllwi128_mask,
30247         __builtin_ia32_pslldi128_mask, __builtin_ia32_psllqi128_mask,
30248         __builtin_ia32_psllw128_mask, __builtin_ia32_pslld128_mask,
30249         __builtin_ia32_psllq128_mask, __builtin_ia32_psllwi256_mask,
30250         __builtin_ia32_psllw256_mask, __builtin_ia32_pslldi256_mask,
30251         __builtin_ia32_pslld256_mask, __builtin_ia32_psllqi256_mask,
30252         __builtin_ia32_psllq256_mask, __builtin_ia32_psradi128_mask,
30253         __builtin_ia32_psrad128_mask, __builtin_ia32_psradi256_mask,
30254         __builtin_ia32_psrad256_mask, __builtin_ia32_psraqi128_mask,
30255         __builtin_ia32_psraq128_mask, __builtin_ia32_psraqi256_mask,
30256         __builtin_ia32_psraq256_mask, __builtin_ia32_psrldi128_mask,
30257         __builtin_ia32_psrld128_mask, __builtin_ia32_psrldi256_mask,
30258         __builtin_ia32_psrld256_mask, __builtin_ia32_psrlqi128_mask,
30259         __builtin_ia32_psrlq128_mask, __builtin_ia32_psrlqi256_mask,
30260         __builtin_ia32_psrlq256_mask, __builtin_ia32_psrawi256_mask,
30261         __builtin_ia32_psraw256_mask, __builtin_ia32_psrawi128_mask,
30262         __builtin_ia32_psraw128_mask, __builtin_ia32_psrlwi256_mask,
30263         __builtin_ia32_psrlw256_mask, __builtin_ia32_psrlwi128_mask,
30264         __builtin_ia32_psrlw128_mask, __builtin_ia32_psllwi512_mask,
30265         __builtin_ia32_psllw512_mask, __builtin_ia32_psrawi512_mask,
30266         __builtin_ia32_psraw512_mask, __builtin_ia32_psrlwi512_mask,
30267         __builtin_ia32_psrlw512_mask): Use _COUNT suffixed function type
30268         aliases.
30269         * config/i386/i386.c (ix86_expand_args_builtin): Rename last_arg_count
30270         flag to second_arg_count, handle 4 argument function type _COUNT
30271         aliases, handle second_arg_count on second argument rather than last.
30273 2017-04-10  Jeff Law  <law@redhat.com>
30275         PR tree-optimization/80374
30276         * tree-ssa-dom.c (derive_equivalences_from_bit_ior): Do not try to
30277         record anything if we can not convert integer_zero_node to the
30278         desired type.
30280 2017-04-10  Kelvin Nilsen  <kelvin@gcc.gnu.org>
30282         PR target/80108
30283         * config/rs6000/rs6000.c (rs6000_option_override_internal):
30284         Enhance special handling given to the TARGET_P9_MINMAX option in
30285         relation to certain other options.
30287 2017-04-10  Bin Cheng  <bin.cheng@arm.com>
30289         PR tree-optimization/80153
30290         * tree-ssa-loop-ivopts.c (add_iv_candidate_for_use): Check and
30291         remove POINTER_PLUS_EXPR's base part directly, rather than through
30292         aff_tree.
30294 2017-04-10  Richard Biener  <rguenther@suse.de>
30295             Bin Cheng  <bin.cheng@arm.com>
30297         PR tree-optimization/80153
30298         * tree-affine.c (aff_combination_to_tree): Get base pointer from
30299         the first element of pointer type aff_tree.  Build result expr in
30300         aff_tree's type.
30301         (add_elt_to_tree): Convert to type unconditionally.  Remove other
30302         fold_convert calls.
30303         * tree-ssa-loop-ivopts.c (alloc_iv): Pass in consistent types.
30304         (rewrite_use_nonlinear_expr): Check invariant using iv information.
30306 2017-04-10  Richard Biener  <rguenther@suse.de>
30308         * tree-ssa-structalias.c (find_func_aliases): Properly handle
30309         asm inputs.
30311 2017-04-10  Vladimir Makarov  <vmakarov@redhat.com>
30313         PR rtl-optimization/70478
30314         * lra-constraints.c (curr_small_class_check): New.
30315         (update_and_check_small_class_inputs): New.
30316         (process_alt_operands): Update curr_small_class_check.  Disfavor
30317         alternative insn memory operands.  Check available regs for small
30318         class operands.
30320 2017-03-31  Matthew Fortune  <matthew.fortune@imgtec.com>
30322         PR target/80057
30323         * config/mips/mips.opt (-mvirt): Update description.
30324         * doc/invoke.texi (-mvirt): Likewise.
30326 2017-04-10  Richard Biener  <rguenther@suse.de>
30328         PR middle-end/80362
30329         * fold-const.c (fold_binary_loc): Look at unstripped ops when
30330         looking for NEGATE_EXPR in -A / -B to A / B folding.
30332 2017-04-10  Martin Liska  <mliska@suse.cz>
30334         PR gcov-profile/80224
30335         * gcov.c (print_usage): Fix usage string.
30336         (get_gcov_intermediate_filename): Remove.
30337         (output_gcov_file): Use both for normal and intermediate format.
30338         (generate_results): Do not initialize special file for
30339         intermediate format.
30341 2017-04-10  Richard Biener  <rguenther@suse.de>
30343         PR tree-optimization/80304
30344         * tree-ssa-loop-im.c (ref_indep_loop_p_1): Also recurse
30345         for safelen.
30347 2017-04-10  Nathan Sidwell  <nathan@acm.org>
30349         PR target/79905
30350         * config/rs6000/rs6000.c (rs6000_vector_type): New.
30351         (rs6000_init_builtins): Use it.
30353 2016-04-10  Kyrylo Tkachov  <kyrylo.tkachov@arm.com>
30355         * config/arm/arm.md (<mrc>): Add mode to SET source.
30356         (<mrrc>): Likewise.
30358 2017-04-10  Richard Biener  <rguenther@suse.de>
30360         PR middle-end/80344
30361         * gimplify.c (is_gimple_mem_rhs_or_call): Allow CLOBBERs.
30363 2017-04-10  Jakub Jelinek  <jakub@redhat.com>
30365         PR target/80324
30366         * config/i386/avx512fintrin.h (_mm512_reduce_add_epi32,
30367         _mm512_reduce_mul_epi32, _mm512_reduce_and_epi32,
30368         _mm512_reduce_or_epi32, _mm512_mask_reduce_add_epi32,
30369         _mm512_mask_reduce_mul_epi32, _mm512_mask_reduce_and_epi32,
30370         _mm512_mask_reduce_or_epi32, _mm512_reduce_min_epi32,
30371         _mm512_reduce_max_epi32, _mm512_reduce_min_epu32,
30372         _mm512_reduce_max_epu32, _mm512_mask_reduce_min_epi32,
30373         _mm512_mask_reduce_max_epi32, _mm512_mask_reduce_min_epu32,
30374         _mm512_mask_reduce_max_epu32, _mm512_reduce_add_ps,
30375         _mm512_reduce_mul_ps, _mm512_mask_reduce_add_ps,
30376         _mm512_mask_reduce_mul_ps, _mm512_reduce_min_ps, _mm512_reduce_max_ps,
30377         _mm512_mask_reduce_min_ps, _mm512_mask_reduce_max_ps,
30378         _mm512_reduce_add_epi64, _mm512_reduce_mul_epi64,
30379         _mm512_reduce_and_epi64, _mm512_reduce_or_epi64,
30380         _mm512_mask_reduce_add_epi64, _mm512_mask_reduce_mul_epi64,
30381         _mm512_mask_reduce_and_epi64, _mm512_mask_reduce_or_epi64,
30382         _mm512_reduce_min_epi64, _mm512_reduce_max_epi64,
30383         _mm512_mask_reduce_min_epi64, _mm512_mask_reduce_max_epi64,
30384         _mm512_reduce_min_epu64, _mm512_reduce_max_epu64,
30385         _mm512_mask_reduce_min_epu64, _mm512_mask_reduce_max_epu64,
30386         _mm512_reduce_add_pd, _mm512_reduce_mul_pd, _mm512_mask_reduce_add_pd,
30387         _mm512_mask_reduce_mul_pd, _mm512_reduce_min_pd, _mm512_reduce_max_pd,
30388         _mm512_mask_reduce_min_pd, _mm512_mask_reduce_max_pd): New intrinsics.
30390 2017-04-08  Vladimir Makarov  <vmakarov@redhat.com>
30392         PR rtl-optimization/70478
30393         * lra-constraints.c: Reverse the last patch.
30395 2017-04-08  Andreas Tobler  <andreast@gcc.gnu.org>
30397         * config/aarch64/aarch64-freebsd.h: Define MCOUNT_NAME.
30398         Add comment for WCHAR_T.
30400 2017-04-08  Martin Liska  <mliska@suse.cz>
30402         Revert:
30403         2017-04-07  Martin Liska  <mliska@suse.cz>
30405         PR ipa/80212
30406         * ipa-split.c (split_function): Add function part to a same comdat
30407         group.
30409 2017-04-08  Aaron Sawdey  <acsawdey@linux.vnet.ibm.com>
30411         PR target/80358
30412         * config/rs6000/rs6000.c (expand_block_compare): Fix boundary check.
30414 2017-04-07  Pat Haugen  <pthaugen@us.ibm.com>
30416         * rs6000/rs6000.c (vec_load_pendulum): Rename...
30417         (vec_pairing): ...to this.
30418         (power9_sched_reorder2): Rewrite code for pairing vector/vecload insns.
30419         (rs6000_sched_init): Adjust for name change.
30420         (struct rs6000_sched_context): Likewise.
30421         (rs6000_init_sched_context): Likewise.
30422         (rs6000_set_sched_context): Likewise.
30424 2017-04-07  Jakub Jelinek  <jakub@redhat.com>
30426         PR target/80322
30427         PR target/80323
30428         PR target/80325
30429         PR target/80326
30430         * config/i386/avxintrin.h (_mm256_cvtsd_f64, _mm256_cvtss_f32): New
30431         intrinsics.
30432         * config/i386/avx512fintrin.h (_mm512_int2mask, _mm512_mask2int,
30433         _mm512_abs_ps, _mm512_mask_abs_ps, _mm512_abs_pd, _mm512_mask_abs_pd,
30434         _mm512_cvtsd_f64, _mm512_cvtss_f32): Likewise.
30436 2017-04-07  Andreas Tobler  <andreast@gcc.gnu.org>
30438         * config/aarch64/aarch64-freebsd.h: Define WCHAR_TYPE.
30440 2017-04-07  Vladimir Makarov  <vmakarov@redhat.com>
30442         PR rtl-optimization/70703
30443         * ira-color.c (update_conflict_hard_regno_costs): Use
30444         int64_t instead of HOST_WIDE_INT.
30446 2017-04-07  Vladimir Makarov  <vmakarov@redhat.com>
30448         PR rtl-optimization/70478
30449         * lra-constraints.c (process_alt_operands): Disfavor alternative
30450         insn memory operands.
30452 2017-04-07  Jeff Law  <law@redhat.com>
30454         * config/iq2000/iq2000.c (final_prescan_insn): Do not separate a
30455         CALL and NOTE_INSN_CALL_ARG_LOCATION.
30457 2017-04-07  Martin Liska  <mliska@suse.cz>
30459         PR target/79889
30460         * config/aarch64/aarch64.c (aarch64_process_target_attr):
30461         Show error message instead of an ICE.
30463 2017-04-07  Martin Liska  <mliska@suse.cz>
30465         PR ipa/80212
30466         * ipa-split.c (split_function): Add function part to a same comdat
30467         group.
30469 2017-04-07  Richard Biener  <rguenther@suse.de>
30471         PR middle-end/80341
30472         * tree.c (get_unwidened): Also handle ! for_type case for
30473         INTEGER_CSTs.
30474         * convert.c (do_narrow): Split out from ...
30475         (convert_to_integer_1): ... here.  Do not pass final truncation
30476         type to get_unwidened for TRUNC_DIV_EXPR.
30478 2017-04-07  Richard Biener  <rguenther@suse.de>
30480         * tree-affine.c (wide_int_ext_for_comb): Take type rather
30481         than aff_tree.
30482         (aff_combination_const): Adjust.
30483         (aff_combination_scale): Likewise.
30484         (aff_combination_add_elt): Likewise.
30485         (aff_combination_add_cst): Likewise.
30486         (aff_combination_convert): Likewise.
30487         (add_elt_to_tree): Likewise.  Remove unused argument.
30488         (aff_combination_to_tree): Adjust calls to add_elt_to_tree.
30490 2017-04-07  Sebastian Huber  <sebastian.huber@embedded-brains.de>
30492         * config/arm/arm.h (ARM_DEFAULT_SHORT_ENUMS): Provide default
30493         definition.
30494         * config/arm/arm.c (arm_default_short_enums): Use
30495         ARM_DEFAULT_SHORT_ENUMS.
30496         * config/arm/rtems.h (ARM_DEFAULT_SHORT_ENUMS): Define.
30498 2017-04-06  Jakub Jelinek  <jakub@redhat.com>
30500         PR debug/80234
30501         * dwarf2out.c (gen_member_die): Handle C++17 inline static data
30502         members with redundant out-of-class redeclaration.
30504 2017-04-06  Uros Bizjak  <ubizjak@gmail.com>
30506         PR target/80286
30507         * config/i386/sse.md (*vec_extractv4si_0_zext_sse4): New pattern.
30508         * config/i386/i386.md (*zero_extendsidi2):
30509         Add (?*x,*x) and (?*v,*v) alternatives.
30511 2017-04-06  Uros Bizjak  <ubizjak@gmail.com>
30513         PR target/79733
30514         * config/i386/i386.c (ix86_expand_builtin)
30515         <case IX86_BUILTIN_K{,OR}TEST{C,Z}{8,16,32,64}>: Determine insn operand
30516         mode from insn data. Convert operands to insn operand mode.
30517         Copy operands that don't satisfy insn predicate to a register.
30519 2017-04-06  Sam Thursfield  <sam.thursfield@codethink.co.uk>
30521         * config/rs6000/x-aix: Increase memory limit for genautomata on AIX.
30522         Update comments.
30524 2017-04-06  Richard Biener  <rguenther@suse.de>
30526         PR tree-optimization/80334
30527         * tree-ssa-loop-ivopts.c (rewrite_use_address): Properly
30528         preserve alignment of accesses.
30530 2017-04-06  Richard Biener  <rguenther@suse.de>
30532         PR tree-optimization/80262
30533         * tree-sra.c (build_ref_for_offset): Preserve address-space
30534         information.
30535         * tree-ssa-sccvn.c (vn_reference_maybe_forwprop_address):
30536         Drop useless address-space information on MEM_REF offsets.
30538 2017-04-05  Andreas Schwab  <schwab@linux-m68k.org>
30540         * builtins.def (BUILT_IN_UPDATE_SETJMP_BUF): Fix type.
30542 2017-04-05  Vladimir Makarov  <vmakarov@redhat.com>
30544         PR rtl-optimization/70703
30545         * ira-color.c (update_conflict_hard_regno_costs): Use
30546         HOST_WIDE_INT instead of long.
30548 2017-04-05  Uros Bizjak  <ubizjak@gmail.com>
30550         PR target/80298
30551         * config/i386/mmintrin.h: Add -msse target option when __SSE__ is
30552         not defined for x86_64 target.  Add -mmmx target option when __SSE2__
30553         is not defined.
30554         * config/i386/mm3dnow.h: Add -msse target when __SSE__ is not defined
30555         for x86_64 target.  Handle -m3dnowa option.
30557 2017-04-05  Vladimir Makarov  <vmakarov@redhat.com>
30559         PR rtl-optimization/70703
30560         * ira-color.c (update_costs_from_allocno): Use the smallest mode.
30561         (update_conflict_hard_regno_costs): Use long instead of unsigned
30562         arithmetic for cost calculation.
30564 2017-04-05  Jakub Jelinek  <jakub@redhat.com>
30565             Bernd Edlinger  <bernd.edlinger@hotmail.de>
30567         PR sanitizer/80308
30568         * asan.c (asan_store_shadow_bytes): Fix location of last_chunk_value
30569         for big endian.
30571 2017-04-05  Eric Botcazou  <ebotcazou@adacore.com>
30573         PR target/78002
30574         * config/aarch64/aarch64.c (aarch64_emit_probe_stack_range): Replace
30575         ptr_mode with Pmode throughout.
30576         * config/aarch64/aarch64.md (probe_stack_range_<PTR:mode): Rename
30577         into probe_stack_range and use DImode.
30579 2017-04-05  Dominik Vogt  <vogt@linux.vnet.ibm.com>
30581         PR target/79890
30582         * config/s390/s390.c (s390_register_info_gprtofpr): Return if
30583         call_eh_return is true.
30585 2017-04-05  Andreas Krebbel  <krebbel@linux.vnet.ibm.com>
30587         * config/s390/s390-c.c (s390_resolve_overloaded_builtin):
30588         Initialize last_match_fntype_index.
30590 2017-04-05  Jakub Jelinek  <jakub@redhat.com>
30592         PR target/80310
30593         * tree-nvr.c: Include internal-fn.h.
30594         (pass_return_slot::execute): Ignore internal calls without
30595         direct optab.
30597 2017-04-04  Jakub Jelinek  <jakub@redhat.com>
30598             Richard Biener  <rguenther@suse.de>
30600         PR c++/80297
30601         * genmatch.c (capture::gen_transform): For GENERIC unshare_expr
30602         captures used multiple times, except for the last use.
30603         * generic-match-head.c: Include gimplify.h.
30605 2017-04-04  Jakub Jelinek  <jakub@redhat.com>
30607         PR tree-optimization/79390
30608         * target.h (struct noce_if_info): Declare.
30609         * targhooks.h (default_noce_conversion_profitable_p): Declare.
30610         * target.def (noce_conversion_profitable_p): New target hook.
30611         * ifcvt.h (struct noce_if_info): New type, moved from ...
30612         * ifcvt.c (struct noce_if_info): ... here.
30613         (noce_conversion_profitable_p): Renamed to ...
30614         (default_noce_conversion_profitable_p): ... this.  No longer
30615         static nor inline.
30616         (noce_try_store_flag_constants, noce_try_addcc,
30617         noce_try_store_flag_mask, noce_try_cmove, noce_try_cmove_arith,
30618         noce_convert_multiple_sets): Use targetm.noce_conversion_profitable_p
30619         instead of noce_conversion_profitable_p.
30620         * config/i386/i386.c: Include ifcvt.h.
30621         (ix86_option_override_internal): Don't override
30622         PARAM_MAX_RTL_IF_CONVERSION_INSNS default.
30623         (ix86_noce_conversion_profitable_p): New function.
30624         (TARGET_NOCE_CONVERSION_PROFITABLE_P): Redefine.
30625         * config/i386/x86-tune.def (X86_TUNE_ONE_IF_CONV_INSN): Adjust comment.
30626         * doc/tm.texi.in (TARGET_NOCE_CONVERSION_PROFITABLE_P): Add.
30627         * doc/tm.texi: Regenerated.
30629 2017-04-04  Bill Schmidt  <wschmidt@linux.vnet.ibm.com>
30631         * doc/extend.texi (PowerPC AltiVec Built-in Functions): Grammar
30632         correction.
30634 2017-04-04  Thomas Preud'homme  <thomas.preudhomme@arm.com>
30636         PR target/80307
30637         * config/arm/arm.c (thumb1_rtx_costs): Give a cost of 32
30638         instructions for small multiply cores.
30640 2017-04-04  Jeff Law  <law@redhat.com>
30642         * config/mips/mips.c (mips_multi_add): Zero initialize the newly
30643         added member.
30644         (mips_expand_vec_perm_const): Initialize elements in orig_perm
30645         that are not set by the loop over the elements.
30647 2017-04-04  Jakub Jelinek  <jakub@redhat.com>
30649         PR target/80286
30650         * config/i386/i386.c (ix86_expand_args_builtin): If op has scalar
30651         int mode, convert_modes it to mode as unsigned, otherwise use
30652         lowpart_subreg to mode rather than SImode.
30653         * config/i386/sse.md (<mask_codefor>ashr<mode>3<mask_name>,
30654         ashr<mode>3, ashr<mode>3<mask_name>, <shift_insn><mode>3<mask_name>):
30655         Use DImode instead of SImode for the shift count operand.
30656         * config/i386/mmx.md (mmx_ashr<mode>3, mmx_<shift_insn><mode>3):
30657         Likewise.
30659 2017-04-04  Richard Biener  <rguenther@suse.de>
30661         PR middle-end/80281
30662         * match.pd (A + (-B) -> A - B): Make sure to preserve unsigned
30663         arithmetic done for the negate or the plus.  Simplify.
30664         (A - (-B) -> A + B): Likewise.
30665         * fold-const.c (split_tree): Make sure to not negate pointers.
30667 2017-04-04  Segher Boessenkool  <segher@kernel.crashing.org>
30669         PR rtl-optimization/60818
30670         * simplify-rtx.c (simplify_binary_operation_1): Do not replace
30671         a compare of comparisons with the thing compared if this results
30672         in a different machine mode.
30674 2017-04-03  Jonathan Wakely  <jwakely@redhat.com>
30676         * alias.c (base_alias_check): Fix typo in comment.
30677         * cgraph.h (class ipa_polymorphic_call_context): Likewise.
30678         * cgraphunit.c (symbol_table::compile): Likewise.
30679         * collect2.c (maybe_run_lto_and_relink): Likewise.
30680         * config/arm/arm.c (arm_thumb1_mi_thunk): Likewise.
30681         * config/avr/avr-arch.h (avr_arch_info_t): Likewise.
30682         * config/avr/avr.c (avr_map_op_t): Likewise.
30683         * config/cr16/cr16.h (DATA_ALIGNMENT): Likewise.
30684         * config/epiphany/epiphany.c (TARGET_ARG_PARTIAL_BYTES): Likewise.
30685         * config/epiphany/epiphany.md (movcc): Likewise.
30686         * config/i386/i386.c (legitimize_pe_coff_extern_decl): Likewise.
30687         * config/m68k/m68k.c (struct _sched_ib, m68k_sched_variable_issue):
30688         Likewise.
30689         * config/mips/mips.c (mips_save_restore_reg): Likewise.
30690         * config/rx/rx.c (rx_is_restricted_memory_address): Likewise.
30691         * config/s390/s390.c (Z10_EARLYLOAD_DISTANCE): Likewise.
30692         * config/sh/sh.c (sh_rtx_costs): Likewise.
30693         * fold-const.c (fold_truth_andor): Likewise.
30694         * genautomata.c (collapse_flag): Likewise.
30695         * gengtype.h (struct type::u::s): Likewise.
30696         * gensupport.c (has_subst_attribute, add_mnemonic_string): Likewise.
30697         * input.c (FORMAT_AMOUNT): Likewise.
30698         * ipa-cp.c (class ipcp_lattice, agg_replacements_to_vector)
30699         (known_aggs_to_agg_replacement_list): Likewise.
30700         * ipa-inline-analysis.c: Likewise.
30701         * ipa-inline.h (estimate_edge_time, estimate_edge_hints): Likewise.
30702         * ipa-polymorphic-call.c
30703         (ipa_polymorphic_call_context::restrict_to_inner_class): Likewise.
30704         * loop-unroll.c (analyze_insn_to_expand_var): Likewise.
30705         * lra.c (lra_optional_reload_pseudos, lra_subreg_reload_pseudos):
30706         Likewise.
30707         * modulo-sched.c (apply_reg_moves): Likewise.
30708         * omp-expand.c (build_omp_regions_1): Likewise.
30709         * trans-mem.c (struct tm_wrapper_hasher): Likewise.
30710         * tree-ssa-loop-ivopts.c (may_eliminate_iv): Likewise.
30711         * tree-ssa-loop-niter.c (maybe_lower_iteration_bound): Likewise.
30712         * tree-vect-data-refs.c (vect_enhance_data_refs_alignment): Likewise.
30713         * value-prof.c: Likewise.
30714         * var-tracking.c (val_reset): Likewise.
30716 2017-04-03  Richard Biener  <rguenther@suse.de>
30718         PR tree-optimization/80275
30719         * fold-const.c (split_address_to_core_and_offset): Handle
30720         POINTER_PLUS_EXPR.
30722 2017-04-03  Eric Botcazou  <ebotcazou@adacore.com>
30724         * tree-nested.c (get_descriptor_type): Make sure that the alignment of
30725         descriptors is at least equal to that of functions.
30727 2017-04-02  Uros Bizjak  <ubizjak@gmail.com>
30729         * config/i386/sse.md (movdi_to_sse): Add missing DONE.
30731 2017-04-02  Uros Bizjak  <ubizjak@gmail.com>
30733         PR target/80250
30734         * config/i386/sse.md (mov<IMOD4:mode>): Remove insn pattern.
30735         (mov<IMOD4:mode>): New expander.
30736         (*mov<IMOD4:mode>_internal): New insn and split pattern.
30738 2017-03-31  Segher Boessenkool  <segher@kernel.crashing.org>
30740         PR rtl-optimization/79405
30741         * fwprop.c (propagations_left): New variable.
30742         (forward_propagate_into): Decrement it.
30743         (fwprop_init): Initialize it.
30744         (fw_prop): If the variable has reached zero, stop propagating.
30745         (fwprop_addr): Ditto.
30747 2017-03-31  Jakub Jelinek  <jakub@redhat.com>
30749         PR debug/79255
30750         * dwarf2out.c (decls_for_scope): If BLOCK_NONLOCALIZED_VAR is
30751         a FUNCTION_DECL, pass it as decl instead of origin to
30752         process_scope_var.
30754 2017-03-31  Alexander Monakov  <amonakov@ispras.ru>
30756         * config/nvptx/nvptx.c (nvptx_output_softstack_switch): Correct format
30757         string.
30759 2017-03-31  Pat Haugen  <pthaugen@us.ibm.com>
30761         PR target/80107
30762         * config/rs6000/rs6000.md (extendhi<mode>2): Add test for
30763         TARGET_VSX_SMALL_INTEGER.
30765 2017-03-31  Bill Schmidt  <wschmidt@linux.vnet.ibm.com>
30767         * doc/extend.texi (PowerPC AltiVec Built-in Functions): Add
30768         reference to the OpenPOWER 64-Bit ELF V2 ABI Specification.
30770 2017-03-31  Matthew Fortune  <matthew.fortune@imgtec.com>
30772         * config/mips/mips-msa.md (msa_vec_extract_<msafmt_f>): Update
30773         extraction from odd-numbered MSA register.
30775 2017-03-31  Jakub Jelinek  <jakub@redhat.com>
30777         PR middle-end/80173
30778         * expmed.c (store_bit_field_1): Don't attempt to create
30779         a word subreg out of hard registers wider than word if they
30780         have HARD_REGNO_NREGS of 1 for their mode.
30782         PR middle-end/80163
30783         * varasm.c (initializer_constant_valid_p_1): Disallow sign-extending
30784         conversions to integer types wider than word and pointer.
30786         PR debug/80025
30787         * cselib.h (rtx_equal_for_cselib_1): Add depth argument.
30788         (rtx_equal_for_cselib_p): Pass 0 to it.
30789         * cselib.c (cselib_hasher::equal): Likewise.
30790         (rtx_equal_for_cselib_1): Add depth argument.  If depth
30791         is 128, don't look up VALUE locs and punt.  Increment
30792         depth in recursive calls when walking VALUE locs.
30794 2017-03-31  Bernd Edlinger  <bernd.edlinger@hotmail.de>
30796         * gcov.c (md5sum_to_hex): Fix output of MD5 hex bytes.
30797         (make_gcov_file_name): Use the canonical path name for generating
30798         the MD5 value.
30799         (read_line): Fix handling of files with ascii null bytes.
30801 2017-03-30  Matthew Fortune  <matthew.fortune@imgtec.com>
30803         * config/mips/mips.c (mips_expand_vector_init): Create a const_vector
30804         to initialise a vector register instead
30805         of using a const_int.
30807 2017-03-30  Jakub Jelinek  <jakub@redhat.com>
30809         PR translation/80189
30810         * gimplify.c (omp_default_clause): Use %qs instead of %s in
30811         diagnostic messages.
30813 2017-03-30  Peter Bergner  <bergner@vnet.ibm.com>
30815         PR target/80246
30816         * config/rs6000/dfp.md (dfp_dxex_<mode>): Update mode of operand 0.
30817         (dfp_diex_<mode>): Update mode of operand 1.
30818         * doc/extend.texi (dxex, dxexq): Document change to return type.
30819         (diex, diexq): Document change to argument type.
30821 2017-03-30  Martin Jambor  <mjambor@suse.cz>
30823         PR ipa/77333
30824         * cgraph.h (cgraph_build_function_type_skip_args): Declare.
30825         * cgraph.c (redirect_call_stmt_to_callee): Set gimple fntype so that
30826         it reflects the signature changes performed at the callee side.
30827         * cgraphclones.c (build_function_type_skip_args): Make public, renamed
30828         to cgraph_build_function_type_skip_args.
30829         (build_function_decl_skip_args): Adjust call to the above function.
30831 2017-03-30  Jakub Jelinek  <jakub@redhat.com>
30833         PR target/80206
30834         * config/i386/sse.md
30835         (<extract_type>_vextract<shuffletype><extract_suf>_mask): Use
30836         register as dest whenever it is a MEM not rtx_equal_p to the
30837         corresponding dup operand, and when forcing into reg move the
30838         reg into the memory afterwards.
30839         (<extract_type_2>_vextract<shuffletype><extract_suf_2>_mask):
30840         Likewise.  Use <ssehalfvecmode> instead of <ssequartermode>
30841         for the force_reg mode.
30842         (avx512vl_vextractf128<mode>): Use register as dest either
30843         always when a MEM, or when it is a MEM not rtx_equal_p to the
30844         corresponding dup operand, or even not when it is a CONST_VECTOR
30845         depending on the mode and lo vs. hi.
30846         (avx512dq_vextract<shuffletype>64x2_1_maskm): Remove extraneous
30847         parens.
30848         (avx512f_vextract<shuffletype>32x4_1_maskm): Likewise.
30849         (<mask_codefor>avx512dq_vextract<shuffletype>64x2_1<mask_name>):
30850         Likewise.  Require that operands[2] is even.
30851         (<mask_codefor>avx512f_vextract<shuffletype>32x4_1<mask_name>):
30852         Remove extraneous parens.  Require that operands[2] is a multiple
30853         of 4.
30854         (vec_extract_lo_<mode><mask_name>): Don't bother testing if
30855         operands[0] is a MEM if <mask_applied>, the predicates/constraints
30856         disallow memory then.
30858 2017-03-30  Richard Biener  <rguenther@suse.de>
30860         PR tree-optimization/77498
30861         * tree-ssa-pre.c (phi_translate_1): Do not allow simplifications
30862         to non-constants over backedges.
30864 2017-03-29  Segher Boessenkool  <segher@kernel.crashing.org>
30866         PR rtl-optimization/80233
30867         * combine.c (combine_instructions): Only take NONDEBUG_INSN_P insns
30868         as last_combined_insn.  Do not test for BARRIER_P separately.
30870 2017-03-29  Andreas Schwab  <schwab@suse.de>
30872         PR ada/80146
30873         * calls.c (prepare_call_address): Convert funexp to Pmode before
30874         copying to temp reg.
30876 2017-03-29  Bill Schmidt  <wschmidt@linux.vnet.ibm.com>
30878         PR tree-optimization/80158
30879         * gimple-ssa-strength-reduction.c (replace_mult_candidate):
30880         Handle possible future case of more than one alternate
30881         interpretation.
30882         (replace_rhs_if_not_dup): Likewise.
30883         (replace_one_candidate): Likewise.
30885 2017-03-28  Vladimir Makarov  <vmakarov@redhat.com>
30887         PR rtl-optimization/80193
30888         * ira.c (ira): Do not check allocation for LRA.
30890 2017-03-28  Alexander Monakov  <amonakov@ispras.ru>
30892         * config/nvptx/nvptx-protos.h (nvptx_output_simt_enter): Declare.
30893         (nvptx_output_simt_exit): Declare.
30894         * config/nvptx/nvptx.c (nvptx_init_unisimt_predicate): Use
30895         cfun->machine->unisimt_location.  Handle NULL unisimt_predicate.
30896         (init_softstack_frame): Move initialization of crtl->is_leaf to...
30897         (nvptx_declare_function_name): ...here.  Emit declaration of local
30898         memory space buffer for omp_simt_enter insn.
30899         (nvptx_output_unisimt_switch): New.
30900         (nvptx_output_softstack_switch): New.
30901         (nvptx_output_simt_enter): New.
30902         (nvptx_output_simt_exit): New.
30903         * config/nvptx/nvptx.h (struct machine_function): New fields
30904         has_simtreg, unisimt_location, simt_stack_size, simt_stack_align.
30905         * config/nvptx/nvptx.md (UNSPECV_SIMT_ENTER): New unspec.
30906         (UNSPECV_SIMT_EXIT): Ditto.
30907         (omp_simt_enter_insn): New insn.
30908         (omp_simt_enter): New expansion.
30909         (omp_simt_exit): New insn.
30910         * config/nvptx/nvptx.opt (msoft-stack-reserve-local): New option.
30912         * internal-fn.c (expand_GOMP_SIMT_ENTER): New.
30913         (expand_GOMP_SIMT_ENTER_ALLOC): New.
30914         (expand_GOMP_SIMT_EXIT): New.
30915         * internal-fn.def (GOMP_SIMT_ENTER): New internal function.
30916         (GOMP_SIMT_ENTER_ALLOC): Ditto.
30917         (GOMP_SIMT_EXIT): Ditto.
30918         * target-insns.def (omp_simt_enter): New insn.
30919         (omp_simt_exit): Ditto.
30920         * omp-low.c (struct omplow_simd_context): New fields simt_eargs,
30921         simt_dlist.
30922         (lower_rec_simd_input_clauses): Implement SIMT privatization.
30923         (lower_rec_input_clauses): Likewise.
30924         (lower_lastprivate_clauses): Handle SIMT privatization.
30926         * omp-offload.c: Include langhooks.h, tree-nested.h, stor-layout.h.
30927         (ompdevlow_adjust_simt_enter): New.
30928         (find_simtpriv_var_op): New.
30929         (execute_omp_device_lower): Handle IFN_GOMP_SIMT_ENTER,
30930         IFN_GOMP_SIMT_ENTER_ALLOC, IFN_GOMP_SIMT_EXIT.
30932         * tree-inline.h (struct copy_body_data): New field dst_simt_vars.
30933         * tree-inline.c (expand_call_inline): Handle SIMT privatization.
30934         (copy_decl_for_dup_finish): Ditto.
30936         * tree-ssa.c (execute_update_addresses_taken): Handle GOMP_SIMT_ENTER.
30938 2017-03-28  Uros Bizjak  <ubizjak@gmail.com>
30940         PR target/53383
30941         * config/i386/i386.c (ix86_option_override_internal): Always
30942         allow -mpreferred-stack-boundary=3 for 64-bit targets.
30944 2017-03-28  Bin Cheng  <bin.cheng@arm.com>
30946         * tree-vect-loop.c (optimize_mask_stores): Add bb to the right loop.
30948 2017-03-28  Bin Cheng  <bin.cheng@arm.com>
30950         * tree-vect-loop-manip.c (slpeel_add_loop_guard): New param and
30951         mark new edge's irreducible flag accordign to it.
30952         (vect_do_peeling): Check loop preheader edge's irreducible flag
30953         and pass it to function slpeel_add_loop_guard.
30955 2017-03-28  Richard Sandiford  <richard.sandiford@arm.com>
30957         PR tree-optimization/80218
30958         * tree-call-cdce.c (shrink_wrap_one_built_in_call_with_conds):
30959         Update block frequencies and counts.
30961 2017-03-28  Richard Biener  <rguenther@suse.de>
30963         PR tree-optimization/78644
30964         * tree-ssa-ccp.c (evaluate_stmt): When we may not use the value
30965         of a simplification result we may not use it at all.
30967 2017-03-28  Richard Biener  <rguenther@suse.de>
30969         PR ipa/80205
30970         * tree-inline.c (copy_phis_for_bb): Do not create PHI node
30971         without arguments, generate default definition of a SSA name.
30973 2017-03-28  Richard Biener  <rguenther@suse.de>
30975         PR middle-end/80222
30976         * gimple-fold.c (gimple_fold_indirect_ref): Do not touch
30977         TYPE_REF_CAN_ALIAS_ALL references.
30978         * fold-const.c (fold_indirect_ref_1): Likewise.
30980 2017-03-28  Martin Liska  <mliska@suse.cz>
30982         PR ipa/80104
30983         * cgraphunit.c (cgraph_node::expand_thunk): Mark argument of a
30984         thunk call as DECL_GIMPLE_REG_P when vector or complex type.
30986 2017-03-28  Claudiu Zissulescu  <claziss@synopsys.com>
30987             Thomas Petazzoni  <thomas.petazzoni@free-electrons.com>
30989         * config/arc/arc.h (CPP_SPEC): Add subtarget_cpp_spec.
30990         (EXTRA_SPECS): Define.
30991         (SUBTARGET_EXTRA_SPECS): Likewise.
30992         (SUBTARGET_CPP_SPEC): Likewise.
30993         * config/arc/elf.h (EXTRA_SPECS): Renamed to
30994         SUBTARGET_EXTRA_SPECS.
30995         * config/arc/linux.h (SUBTARGET_CPP_SPEC): Define.
30997 2017-03-28  Claudiu Zissulescu  <claziss@synopsys.com>
30999         * config/arc/simdext.md (vst64_insn): Update pattern.
31000         (vld32wh_insn): Likewise.
31001         (vld32wl_insn): Likewise.
31002         (vld64_insn): Likewise.
31003         (vld32_insn): Likewise.
31005 2017-03-28  Marek Polacek  <polacek@redhat.com>
31007         PR sanitizer/80067
31008         * fold-const.c (fold_comparison): Use protected_set_expr_location
31009         instead of SET_EXPR_LOCATION.
31011 2017-03-28  Markus Trippelsdorf  <markus@trippelsdorf.de>
31013         * tree.c (add_expr): Avoid name lookup warning.
31015 2017-03-27  Jeff Law  <law@redhat.com>
31017         PR tree-optimization/80216
31018         * tree-ssa-dom.c (derive_equivalences_from_bit_ior): Fix typo in
31019         function name.  Limit recursion depth.
31020         (record_temporary_equivalences): Corresponding changes.
31022 2017-03-27  Jonathan Wakely  <jwakely@redhat.com>
31024         * doc/invoke.texi (-Wno-narrowing): Reorder so default behavior is
31025         covered first.
31027 2017-03-27  Jakub Jelinek  <jakub@redhat.com>
31029         PR target/80102
31030         * reg-notes.def (REG_CFA_NOTE): Define.  Use it for CFA related
31031         notes.
31032         * cfgcleanup.c (reg_note_cfa_p): New array.
31033         (insns_have_identical_cfa_notes): New function.
31034         (old_insns_match_p): Don't cross-jump in between /f
31035         and non-/f instructions.  If both i1 and i2 are frame related,
31036         verify all CFA notes, their order and content.
31038 2017-03-27  Michael Meissner  <meissner@linux.vnet.ibm.com>
31040         PR target/78543
31041         * config/rs6000/rs6000.md (bswaphi2_extenddi): Combine bswap
31042         HImode and SImode with zero extend to DImode to one insn.
31043         (bswap<mode>2_extenddi): Likewise.
31044         (bswapsi2_extenddi): Likewise.
31045         (bswaphi2_extendsi): Likewise.
31046         (bswaphi2): Combine bswap HImode and SImode into one insn.
31047         Separate memory insns from swapping register.
31048         (bswapsi2): Likewise.
31049         (bswap<mode>2): Likewise.
31050         (bswaphi2_internal): Delete, no longer used.
31051         (bswapsi2_internal): Likewise.
31052         (bswap<mode>2_load): Split bswap HImode/SImode into separate load,
31053         store, and gpr<-gpr swap insns.
31054         (bswap<mode>2_store): Likewise.
31055         (bswaphi2_reg): Register only splitter, combine with the splitter.
31056         (bswaphi2 splitter): Likewise.
31057         (bswapsi2_reg): Likewise.
31058         (bswapsi2 splitter): Likewise.
31059         (bswapdi2): If we have the LDBRX and STDBRX instructions, split
31060         the insns into load, store, and register/register insns.
31061         (bswapdi2_ldbrx): Likewise.
31062         (bswapdi2_load): Likewise.
31063         (bswapdi2_store): Likewise.
31064         (bswapdi2_reg): Likewise.
31066 2017-03-27  Gunther Nikl  <gnikl@users.sourceforge.net>
31068         * system.h (HAVE_DESIGNATED_INITIALIZERS): Fix non C++ case.
31069         (HAVE_DESIGNATED_UNION_INITIALIZERS): Likewise.
31071 2017-03-27  Kelvin Nilsen  <kelvin@gcc.gnu.org>
31073         PR target/80103
31074         * config/rs6000/rs6000-c.c (rs6000_target_modify_macros): Edit and
31075         add comments.
31076         * config/rs6000/rs6000.c (rs6000_option_override_internal): Add
31077         special handling for target option conflicts between dform
31078         options (-mpower9-dform, -mpower9-dform-vector,
31079         -mpower9-dform-scalar) and -mno-direct-move.
31081 2017-03-27  Richard Biener  <rguenther@suse.de>
31083         PR tree-optimization/80181
31084         * tree-ssa-ccp.c (likely_value): UNDEFINED ^ X is UNDEFINED.
31086 2017-03-27  Claudiu Zissulescu  <claziss@synopsys.com>
31088         * config/arc/predicates.md (move_double_src_operand): Replace the
31089         call to move_double_src_operand with a call to address_operand.
31091 2017-03-27  Claudiu Zissulescu  <claziss@synopsys.com>
31093         * config/arc/elf.h (ARGET_ARC_TP_REGNO_DEFAULT): Define.
31094         * config/arc/linux.h (ARGET_ARC_TP_REGNO_DEFAULT): Likewise.
31095         * config/arc/arc.opt (mtp-regno): Use ARGET_ARC_TP_REGNO_DEFAULT.
31097 2017-03-27  Claudiu Zissulescu  <claziss@synopsys.com>
31099         * config/arc/predicates.md (long_immediate_loadstore_operand):
31100         Consider scaled addresses cases.
31102 2017-03-27  Claudiu Zissulescu  <claziss@synopsys.com>
31104         * config/arc/arc.c (arc_epilogue_uses): BLINK should be also
31105         restored when in interrupt.
31106         * config/arc/arc.md (simple_return): ARCv2 rtie instruction
31107         doesn't have delay slot.
31109 2017-03-27  Richard Biener  <rguenther@suse.de>
31111         PR ipa/79776
31112         * tree-ssa-structalias.c (associate_varinfo_to_alias): Skip
31113         inlined thunk clones.
31115 2017-03-27  Jakub Jelinek  <jakub@redhat.com>
31117         PR sanitizer/80168
31118         * asan.c (instrument_derefs): Copy over last operand from
31119         original COMPONENT_REF to the new COMPONENT_REF with
31120         DECL_BIT_FIELD_REPRESENTATIVE.
31121         * ubsan.c (instrument_object_size): Likewise.
31123 2017-03-27  Richard Biener  <rguenther@suse.de>
31125         PR tree-optimization/80170
31126         * tree-vect-data-refs.c (vect_compute_data_ref_alignment): Make
31127         sure DR/SCEV didnt fold in constants we do not see when looking
31128         at the reference base alignment.
31130 2017-03-27  Richard Biener  <rguenther@suse.de>
31132         PR middle-end/80171
31133         * gimple-fold.c (fold_ctor_reference): Properly guard against
31134         NULL return value from canonicalize_constructor_val.
31136 2017-03-25  Uros Bizjak  <ubizjak@gmail.com>
31138         PR target/80180
31139         * config/i386/i386.c (ix86_expand_builtin)
31140         <IX86_BUILTIN_RDSEED{16,32,64}_STEP>: Do not expand arg0 between
31141         flags reg setting and flags reg using instructions.
31142         <IX86_BUILTIN_RDRAND{16,32,64}_STEP>: Ditto.  Use non-flags reg
31143         clobbering instructions to zero extend op2.
31145 2017-03-25  Gerald Pfeifer  <gerald@pfeifer.com>
31147         * doc/install.texi (Configuration) <--with-aix-soname>:
31148         Update link to AIX ld.
31150 2017-03-25  Bernd Schmidt  <bschmidt@redhat.com>
31152         PR rtl-optimization/80160
31153         PR rtl-optimization/80159
31154         * lra-assigns.c (must_not_spill_p): Tighten new test to also take
31155         reg_alternate_class into account.
31157 2017-03-24  Vladimir Makarov  <vmakarov@redhat.com>
31159         PR target/80148
31160         * lra-assigns.c (assign_by_spills): Add spilled non-reload pseudos
31161         to consider in curr_insn_transform.
31163 2017-03-24  Jakub Jelinek  <jakub@redhat.com>
31165         * genrecog.c (validate_pattern): Add VEC_SELECT validation.
31166         * genmodes.c (emit_min_insn_modes_c): Call emit_mode_nunits
31167         and emit_mode_inner.
31169 2017-03-24  Andreas Krebbel  <krebbel@linux.vnet.ibm.com>
31171         * config/s390/s390-builtins.def: Add VXE builtins.  Add a flags
31172         argument to the overloaded builtin variants.  Use the new flag to
31173         deprecate certain builtin variants.
31174         * config/s390/s390-builtin-types.def: Add new builtin types.
31175         * config/s390/s390-builtins.h: Support new flags field for
31176         overloaded builtins.
31177         * config/s390/s390-c.c (OB_DEF_VAR): New flags field.
31178         (s390_macro_to_expand): Enable vector float data type.
31179         (s390_cpu_cpp_builtins_internal): Indicate support of the new
31180         builtins by incrementing the __VEC__ version number.
31181         (s390_expand_overloaded_builtin): Support expansion of vec_xl and
31182         vec_xst.
31183         (s390_resolve_overloaded_builtin): Emit error messages depending
31184         on the builtin flags.
31185         * config/s390/s390.c (s390_expand_builtin): Support additional
31186         flags argument.  Change error message to match the messages
31187         emitted in s390-c.c.
31188         * config/s390/s390.md: New UNSPEC_* constants.
31189         (op_type): Add new instruction types.
31190         * config/s390/vecintrin.h: Add new builtins and test data class
31191         constants.
31192         * config/s390/vx-builtins.md (V_HW_32_64): Add V4SF.
31193         (V_HW_4, VEC_HW, VECF_HW): New mode iterators.
31194         (VEC_INEXACT, VEC_NOINEXACT): New constants.
31195         ("vec_splats<mode>", "vec_insert<mode>", "vec_promote<mode>")
31196         ("vec_insert_and_zero<mode>", "vec_mergeh<mode>")
31197         ("vec_mergel<mode>"): V_HW -> VEC_HW.
31199         ("vlrlrv16qi", "vstrlrv16qi", "vbpermv16qi", "vec_msumv2di")
31200         ("vmslg", "*vftci<mode>_cconly", "vftci<mode>_intcconly")
31201         ("*vftci<mode>", "vftci<mode>_intcc", "vec_double_s64")
31202         ("vec_double_u64", "vfmin<mode>", "vfmax<mode>"): New definition.
31204         ("and_av2df3", "and_cv2df3", "vec_andc_av2df3")
31205         ("vec_andc_cv2df3", "xor_av2df3", "xor_cv2df3", "vec_nor_av2df3")
31206         ("vec_nor_cv2df3", "ior_av2df3", "ior_cv2df3", "vec_nabs")
31207         ("*vftcidb", "*vftcidb_cconly", "vftcidb"): Remove definition.
31209         ("vec_all_<fpcmpcc:code>v2df", "vec_any_<fpcmpcc:code>v2df")
31210         ("vec_scatter_elementv4si_DI", "vec_cmp<fpcmp:code>v2df")
31211         ("vec_di_to_df_s64", "vec_di_to_df_u64", "vec_df_to_di_u64")
31212         ("vfidb", "*vldeb", "*vledb", "*vec_cmp<insn_cmp>v2df_cconly")
31213         ("vec_cmpeqv2df_cc", "vec_cmpeqv2df_cc", "vec_cmphv2df_cc")
31214         ("vec_cmphev2df_cc", "*vec_cmpeqv2df_cc")
31215         ("*vec_cmphv2df_cc", "*vec_cmphev2df_cc"): Enable new modes as ...
31217         ("vec_all_<fpcmpcc:code><mode>", "vec_any_<fpcmpcc:code><mode>")
31218         ("vec_scatter_element<V_HW_4:mode>_DI")
31219         ("vec_cmp<fpcmp:code><mode>", "vcdgb", "vcdlgb", "vclgdb")
31220         ("vec_fpint<mode>", "vflls")
31221         ("vflrd", "*vec_cmp<insn_cmp><mode>_cconly", "vec_cmpeq<mode>_cc")
31222         ("vec_cmpeq<mode>_cc", "vec_cmph<mode>_cc", "vec_cmphe<mode>_cc")
31223         ("*vec_cmpeq<mode>_cc", "*vec_cmph<mode>_cc")
31224         ("*vec_cmphe<mode>_cc"): ... these.
31226         ("vec_ctd_s64", "vec_ctsl", "vec_ctul", "vec_st2f"): Use rounding
31227         mode constant instead of magic value.
31229 2017-03-24  Andreas Krebbel  <krebbel@linux.vnet.ibm.com>
31231         * config/s390/s390.c (s390_expand_vec_compare): Support other
31232         vector floating point modes than just V2DF.
31233         (s390_expand_vcond): Likewise.
31234         (s390_hard_regno_mode_ok): Allow SFmode values in VRs.
31235         (s390_cannot_change_mode_class): Prevent mode changes between TF
31236         and V1TF in vector registers.
31237         * config/s390/s390.md (DF, SF): New mode attributes.
31238         ("*cmp<mode>_ccs", "add<mode>3", "sub<mode>3", "mul<mode>3")
31239         ("fma<mode>4", "fms<mode>4", "div<mode>3", "*neg<mode>2"): Add
31240         SFmode support for VRs.
31241         * config/s390/vector.md (V_HW, V_HW2, VT_HW, ti*, nonvec): Add new
31242         vector fp modes.
31243         (VFT, VF_HW): New mode iterators.
31244         (vw, sdx): New mode attributes.
31245         ("addv2df3", "subv2df3", "mulv2df3", "divv2df3", "sqrtv2df2")
31246         ("fmav2df4","fmsv2df4", "negv2df2", "absv2df2", "*negabsv2df2")
31247         ("smaxv2df3", "sminv2df3", "*vec_cmp<VFCMP_HW_OP:code>v2df_nocc")
31248         ("vec_cmpuneqv2df", "vec_cmpltgtv2df", "vec_orderedv2df")
31249         ("vec_unorderedv2df"): Adjust the v2df only patterns to support
31250         also the new vector floating point modes.  Renaming to ...
31252         ("add<mode>3", "sub<mode>3", "mul<mode>3", "div<mode>3")
31253         ("sqrt<mode>2", "fma<mode>4", "fms<mode>4", "neg<mode>2")
31254         ("abs<mode>2", "negabs<mode>2", "smax<mode>3")
31255         ("smin<mode>3", "*vec_cmp<VFCMP_HW_OP:code><mode>_nocc")
31256         ("vec_cmpuneq<mode>", "vec_cmpltgt<mode>", "vec_ordered<mode>")
31257         ("vec_unordered<mode>"): ... these.
31259         ("neg_fma<mode>4", "neg_fms<mode>4", "*smax<mode>3_vxe")
31260         ("*smin<mode>3_vxe", "*sminv2df3_vx", "*vec_extendv4sf")
31261         ("*vec_extendv2df"): New insn definitions.
31263 2017-03-24  Andreas Krebbel  <krebbel@linux.vnet.ibm.com>
31265         * config/s390/s390.md ("*adddi3_sign", "*subdi3_sign", "mulditi3")
31266         ("mulditi3_2", "*muldi3_sign"): New patterns.
31267         ("muldi3", "*muldi3", "mulsi3", "*mulsi3"): Add an expander and
31268         rename the pattern definition.
31270 2017-03-24  Andreas Krebbel  <krebbel@linux.vnet.ibm.com>
31272         * config/s390/s390.md ("indirect_jump"): Turn insn definition into
31273         expander.
31274         ("*indirect_jump", "*indirect2_jump"): New pattern definitions.
31276 2017-03-24  Andreas Krebbel  <krebbel@linux.vnet.ibm.com>
31278         * config/s390/s390.c (s390_expand_vec_init): Use vllezl
31279         instruction if possible.
31280         * config/s390/vector.md (vec_halfnumelts): New mode
31281         attribute.
31282         ("*vec_vllezlf<mode>"): New pattern.
31284 2017-03-24  Andreas Krebbel  <krebbel@linux.vnet.ibm.com>
31286         * config/s390/vector.md ("popcountv16qi2", "popcountv8hi2")
31287         ("popcountv4si2", "popcountv2di2"): Rename to ...
31288         ("popcount<mode>2", "popcountv8hi2_vx", "popcountv4si2_vx")
31289         ("popcountv2di2_vx"): ... these and add !TARGET_VXE to the
31290         condition.
31291         ("popcount<mode>2_vxe"): New pattern.
31293 2017-03-24  Andreas Krebbel  <krebbel@linux.vnet.ibm.com>
31295         * common/config/s390/s390-common.c (processor_flags_table): Add
31296         arch12.
31297         * config.gcc: Add arch12.
31298         * config/s390/driver-native.c (s390_host_detect_local_cpu):
31299         Default to arch12 for unknown CPU model numbers.
31300         * config/s390/s390-builtins.def: Add B_VXE builtin flag.
31301         * config/s390/s390-c.c (s390_cpu_cpp_builtins_internal): Adjust
31302         PROCESSOR_max sanity check.
31303         * config/s390/s390-opts.h (enum processor_type): Add
31304         PROCESSOR_ARCH12.
31305         * config/s390/s390.c (processor_table): Add arch12.
31306         (s390_expand_builtin): Add check for B_VXE flag.
31307         (s390_issue_rate): Add PROCESSOR_ARCH12.
31308         (s390_get_sched_attrmask): Likewise.
31309         (s390_get_unit_mask): Likewise.
31310         (s390_sched_score): Enable z13 scheduling for arch12.
31311         (s390_sched_reorder): Likewise.
31312         (s390_sched_variable_issue): Likewise.
31313         * config/s390/s390.h (enum processor_flags): Add PF_ARCH12 and
31314         PF_VXE.
31315         (s390_tune_attr): Use z13 scheduling also for arch12.
31316         (TARGET_CPU_ARCH12, TARGET_CPU_ARCH12_P, TARGET_CPU_VXE)
31317         (TARGET_CPU_VXE_P, TARGET_ARCH12, TARGET_ARCH12_P, TARGET_VXE)
31318         (TARGET_VXE_P): New macros.
31319         * config/s390/s390.md: Add arch12 to cpu attribute.  Add arch12
31320         and vxe to cpu_facility.  Add arch12 and vxe to enabled attribute.
31321         * config/s390/s390.opt: Add arch12 as processor_type.
31323 2017-03-24  Andreas Krebbel  <krebbel@linux.vnet.ibm.com>
31325         * config/s390/s390.md
31326         ("fixuns_truncdddi2", "fixuns_trunctddi2")
31327         ("fixuns_trunc<BFP:mode><GPR:mode>2"): Merge into ...
31328         ("fixuns_trunc<FP:mode><GPR:mode>2"): New expander.
31330         ("fixuns_trunc<BFP:mode><GPR:mode>2", "fixuns_trunc<mode>si2"):
31331         Rename expanders to ...
31333         ("fixuns_trunc<BFP:mode><GPR:mode>2_emu")
31334         ("fixuns_truncdddi2_emu"): ... these.
31336         ("fixuns_trunc<mode>si2_emu"): New expander.
31338         ("*fixuns_truncdfdi2_z13"): Rename to ...
31339         ("*fixuns_truncdfdi2_vx"): ... this.
31341 2017-03-24  Andreas Krebbel  <krebbel@linux.vnet.ibm.com>
31343         * config/s390/2964.md: Remove the single element vector compare
31344         instructions which are no longer used.
31345         * config/s390/s390.c (s390_select_ccmode): Remove handling of
31346         vector CCmodes.
31347         (s390_canonicalize_comparison): Remove handling of DFmode
31348         compares.
31349         (s390_expand_vec_compare_scalar): Remove function.
31350         (s390_emit_compare): Don't call s390_expand_vec_compare_scalar.
31351         * config/s390/s390.md ("*vec_cmp<insn_cmp>df_cconly"): Remove
31352         pattern.
31353         ("*cmp<mode>_ccs"): Add wfcdb instruction.
31355 2017-03-24  Andreas Krebbel  <krebbel@linux.vnet.ibm.com>
31357         * config/s390/s390.md ("mov<mode>_64dfp" DD_DF): Use vleig for loading a
31358         FP zero.
31359         ("*mov<mode>_64" DD_DF): Remove the vector instructions. These
31360         will anyway by matched by mov<mode>_64dfp.
31362 2017-03-24  Andreas Krebbel  <krebbel@linux.vnet.ibm.com>
31364         * config/s390/s390.md ("mov<mode>" SD_SF): Change vleg/vsteg to
31365         vlef/vstef.  Add missing operand to vleif.
31367 2017-03-24  Andreas Krebbel  <krebbel@linux.vnet.ibm.com>
31369         * config/s390/s390.c (s390_expand_vec_init): Enable vector load
31370         pair for all vector types with 64 bit elements.
31371         * config/s390/vx-builtins.md (V_HW_64): Move mode iterator to ...
31372         * config/s390/vector.md (V_HW_64): ... here.
31373         (V_128_NOSINGLE): New mode iterator.
31374         ("vec_init<V_HW:mode>"): Use V_128 as mode iterator.
31375         ("*vec_splat<mode>"): Use V_128_NOSINGLE mode iterator.
31376         ("*vec_tf_to_v1tf", "*vec_ti_to_v1ti"): New pattern definitions.
31377         ("*vec_load_pairv2di"): Change to ...
31378         ("*vec_load_pair<mode>"): ... this one.
31380 2017-03-24  Andreas Krebbel  <krebbel@linux.vnet.ibm.com>
31382         * config/s390/constraints.md: Add comments.
31383         (jKK): Reject element sizes > 8 bytes.
31384         * config/s390/s390.c (s390_split_ok_p): Enable splitting also for
31385         s_operands.
31386         * config/s390/s390.md: Add the s_operand checks formerly in
31387         s390_split_ok_p to various splitters where they are still
31388         required.
31389         * config/s390/vector.md ("mov<mode>" V_128): Add GPR alternatives
31390         for 128 bit vectors.  Plus two splitters.
31392 2017-03-24  Andreas Krebbel  <krebbel@linux.vnet.ibm.com>
31394         * config/s390/s390.md: Rename the cpu facilty vec to vx throughout
31395         the file.
31397 2017-03-24  Andreas Krebbel  <krebbel@linux.vnet.ibm.com>
31399         PR target/79893
31400         * config/s390/s390-c.c (s390_adjust_builtin_arglist): Issue an
31401         error if the boundary argument is not constant.
31403 2017-03-24  Jakub Jelinek  <jakub@redhat.com>
31405         PR rtl-optimization/80112
31406         * loop-doloop.c (doloop_condition_get): Don't check condition
31407         if cmp isn't SET with IF_THEN_ELSE src.
31409 2017-03-24  Bill Schmidt  <wschmidt@linux.vnet.ibm.com>
31411         PR tree-optimization/80158
31412         * gimple-ssa-strength-reduction.c (replace_mult_candidate): When
31413         replacing a candidate statement, also replace it for the
31414         candidate's alternate interpretation.
31415         (replace_rhs_if_not_dup): Likewise.
31416         (replace_one_candidate): Likewise.
31418 2017-03-24  Richard Biener  <rguenther@suse.de>
31420         PR tree-optimization/80167
31421         * graphite-isl-ast-to-gimple.c
31422         (translate_isl_ast_to_gimple::is_valid_rename): Handle default-defs
31423         properly.
31424         (translate_isl_ast_to_gimple::get_rename): Likewise.
31426 2017-03-23  Kelvin Nilsen  <kelvin@gcc.gnu.org>
31428         * config/rs6000/rs6000.c (rs6000_option_override_internal): Change
31429         handling of certain combinations of target options, including the
31430         combinations -mpower8-vector vs. -mno-vsx, -mpower9-vector vs.
31431         -mno-power8-vector, and -mpower9_dform vs. -mno-power9-vector.
31433 2017-03-23  Kyrylo Tkachov  <kyrylo.tkachov@arm.com>
31435         PR target/71436
31436         * config/arm/arm.md (*load_multiple): Add reload_completed to
31437         matching condition.
31439 2017-03-23  Bill Schmidt  <wschmidt@linux.vnet.ibm.com>
31440             Richard Biener  <rguenth@suse.de>
31442         PR tree-optimization/79908
31443         PR tree-optimization/80136
31444         * tree-stdarg.c (expand_ifn_va_arg_1): For a VA_ARG whose LHS has
31445         been cast away, gimplify_and_add suffices.
31447 2017-03-23  Markus Trippelsdorf  <markus@trippelsdorf.de>
31449         * tree-vrp.c (identify_jump_threads): Delete avail_exprs.
31451 2017-03-23  Richard Biener  <rguenther@suse.de>
31453         PR tree-optimization/80032
31454         * gimplify.c (gimple_push_cleanup): Forced unconditional
31455         cleanups still have to go to the conditional_cleanups
31456         sequence.
31458 2017-03-22  Jakub Jelinek  <jakub@redhat.com>
31460         PR tree-optimization/80072
31461         * tree-ssa-reassoc.c (struct operand_entry): Change id field type
31462         to unsigned int.
31463         (next_operand_entry_id): Change type to unsigned int.
31464         (sort_by_operand_rank): Make sure to return the right return value
31465         even if unsigned fields are bigger than INT_MAX.
31466         (struct oecount): Change cnt and id type to unsigned int.
31467         (oecount_hasher::equal): Formatting fix.
31468         (oecount_cmp): Make sure to return the right return value
31469         even if unsigned fields are bigger than INT_MAX.
31470         (undistribute_ops_list): Change next_oecount_id type to unsigned int.
31472         PR c++/80129
31473         * gimplify.c (gimplify_modify_expr_rhs) <case COND_EXPR>: Clear
31474         TREE_READONLY on result if writing it more than once.
31476         PR sanitizer/80110
31477         * doc/invoke.texi (-fsanitize=thread): Document that with
31478         -fnon-call-exceptions atomics are not able to throw
31479         exceptions.
31481         PR sanitizer/80110
31482         * tsan.c: Include tree-eh.h.
31483         (instrument_builtin_call): Call maybe_clean_eh_stmt or
31484         maybe_clean_or_replace_eh_stmt where needed.
31485         (instrument_memory_accesses): Add cfg_changed argument.
31486         Call gimple_purge_dead_eh_edges on each block and set *cfg_changed
31487         if it returned true.
31488         (tsan_pass): Adjust caller.  Return TODO_cleanup_cfg if cfg_changed.
31490         PR rtl-optimization/63191
31491         * config/i386/i386.c (ix86_delegitimize_address): Turn into small
31492         wrapper function, moved the whole old content into ...
31493         (ix86_delegitimize_address_1): ... this.  New inline function.
31494         (ix86_find_base_term): Use ix86_delegitimize_address_1 with
31495         true as last argument instead of ix86_delegitimize_address.
31497 2017-03-22  Wilco Dijkstra  <wdijkstr@arm.com>
31499         * config/aarch64/aarch64.c (generic_branch_cost): Copy
31500         cortexa57_branch_cost.
31502 2017-03-22  Wilco Dijkstra  <wdijkstr@arm.com>
31504         * config/aarch64/aarch64.c (generic_tunings): Add AES fusion.
31506 2017-03-21  Aaron Sawdey  <acsawdey@linux.vnet.ibm.com>
31508         PR target/80123
31509         * doc/md.texi (Constraints): Document wA constraint.
31510         * config/rs6000/constraints.md (wA): New.
31511         * config/rs6000/rs6000.c (rs6000_debug_reg_global): Add wA reg_class.
31512         (rs6000_init_hard_regno_mode_ok): Init wA constraint.
31513         * config/rs6000/rs6000.h (RS6000_CONSTRAINT_wA): New.
31514         * config/rs6000/vsx.md (vsx_splat_<mode>): Use wA constraint.
31516 2017-03-22  Cesar Philippidis  <cesar@codesourcery.com>
31518         PR c++/80029
31519         * gimplify.c (is_oacc_declared): New function.
31520         (oacc_default_clause): Use it to set default flags for acc declared
31521         variables inside parallel regions.
31522         (gimplify_scan_omp_clauses): Strip firstprivate pointers for acc
31523         declared variables.
31524         (gimplify_oacc_declare): Gimplify the declare clauses.  Add the
31525         declare attribute to any decl as necessary.
31527 2017-03-22  Thomas Preud'homme  <thomas.preudhomme@arm.com>
31529         PR target/80082
31530         * config/arm/arm-isa.h (isa_bit_lpae): New feature bit.
31531         (ISA_ARMv7ve): Add isa_bit_lpae to the definition.
31532         * config/arm/arm-protos.h (arm_arch7ve): Rename into ...
31533         (arm_arch_lpae): This.
31534         * config/arm/arm.c (arm_arch7ve): Rename into ...
31535         (arm_arch_lpae): This.  Define it in term of isa_bit_lpae.
31536         * config/arm/arm.h (TARGET_HAVE_LPAE): Redefine in term of
31537         arm_arch_lpae.
31539 2017-03-22  Martin Liska  <mliska@suse.cz>
31541         PR target/79906
31542         * config/rs6000/rs6000.c (rs6000_inner_target_options): Show
31543         error message instead of an ICE.
31545 2017-03-21  Bill Schmidt  <wschmidt@linux.vnet.ibm.com>
31547         * doc/extend.texi (6.11 Additional Floating Types): Revise.
31549 2017-03-21  Kelvin Nilsen  <kelvin@gcc.gnu.org>
31551         * config/rs6000/rs6000-c.c (rs6000_target_modify_macros): Add
31552         comments.
31553         * config/rs6000/rs6000.c (rs6000_option_override_internal): Add
31554         comments.
31556 2017-03-21  Martin Sebor  <msebor@redhat.com>
31558         * doc/extend.texi: Use "cannot" instead of "can't."
31559         * doc/hostconfig.texi: Same.
31560         * doc/install.texi: Same.
31561         * doc/invoke.texi: Same.
31562         * doc/loop.texi: Same.
31563         * doc/md.texi: Same.
31564         * doc/objc.texi: Same.
31565         * doc/rtl.texi: Same.
31566         * doc/tm.texi: Same.
31567         * doc/tm.texi.in: Same.
31568         * doc/trouble.texi: Same.
31570 2017-03-21  Alexandre Oliva <aoliva@redhat.com>
31572         PR debug/63238
31573         * dwarf2out.c (struct checksum_attributes): Add at_alignment.
31574         (collect_checksum_attributes): Set it.
31575         (die_checksum_ordered): Use it.
31577 2017-03-21  Bill Schmidt  <wschmidt@linux.vnet.ibm.com>
31579         PR tree-optimization/79908
31580         * tree-stdarg.c (expand_ifn_va_arg_1): Revert the following
31581         change: For a VA_ARG whose LHS has been cast away, use
31582         force_gimple_operand to construct the side effects.
31584 2017-03-21  David Malcolm  <dmalcolm@redhat.com>
31586         PR translation/80001
31587         * omp-offload.c (oacc_loop_fixed_partitions): Make diagnostics
31588         more amenable to translation.
31589         (oacc_loop_auto_partitions): Likewise.
31591 2017-03-21  Marek Polacek  <polacek@redhat.com>
31592             Martin Sebor  <msebor@redhat.com>
31594         PR tree-optimization/80109
31595         * gimple-ssa-warn-alloca.c (alloca_call_type): Only call get_range_info
31596         on INTEGRAL_TYPE_P.
31598 2017-03-21  Jakub Jelinek  <jakub@redhat.com>
31599             Segher Boessenkool  <segher@kernel.crashing.org>
31601         PR target/80125
31602         * combine.c (can_combine_p): Revert the 2017-03-20 change, only
31603         check reg_used_between_p between insn and one of succ or succ2
31604         depending on if succ is artificial insn not inserted into insn
31605         stream.
31607 2017-03-21  Martin Liska  <mliska@suse.cz>
31609         PR gcov-profile/80081
31610         * Makefile.in: Add gcov-dump and fix installation of gcov-tool.
31611         * doc/gcc.texi: Include gcov-dump stuff.
31612         * doc/gcov-dump.texi: New file.
31614 2017-03-21  Toma Tabacu  <toma.tabacu@imgtec.com>
31616         PR rtl-optimization/79150
31617         * config/mips/mips.c (mips_block_move_loop): Emit a NOP after the
31618         conditional jump, if the jump is the last insn of the loop.
31620 2017-03-21  Bill Schmidt  <wschmidt@linux.vnet.ibm.com>
31621             Richard Biener  <rguenth@suse.de>
31623         PR tree-optimization/79908
31624         * tree-stdarg.c (expand_ifn_va_arg_1): For a VA_ARG whose LHS has
31625         been cast away, use force_gimple_operand to construct the side
31626         effects.
31628 2017-03-21  Martin Liska  <mliska@suse.cz>
31630         PR libfortran/79956
31631         * simplify-rtx.c (simplify_immed_subreg): Initialize a variable
31632         to NULL.
31634 2017-03-21  Brad Spengler <spender@grsecurity.net>
31636         PR plugins/80094
31637         * plugin.c (htab_hash_plugin): New function.
31638         (add_new_plugin): Use it and adjust.
31639         (parse_plugin_arg_opt): Adjust.
31640         (init_one_plugin): Likewise.
31642 2017-03-21  Richard Biener  <rguenther@suse.de>
31644         PR tree-optimization/80032
31645         * gimplify.c (gimple_push_cleanup): Add force_uncond parameter,
31646         if set force the cleanup to happen unconditionally.
31647         (gimplify_target_expr): Push inserted clobbers with force_uncond
31648         to avoid them being removed by control-dependent DCE.
31650 2017-03-21  Richard Biener  <rguenther@suse.de>
31652         PR tree-optimization/80122
31653         * tree-inline.c (copy_bb): Do not expans va-arg packs or
31654         va_arg_pack_len when the inlined call stmt requires pack
31655         expansion itself.
31656         * tree-inline.h (struct copy_body_data): Make call_stmt a gcall *.
31658 2017-03-21  Jakub Jelinek  <jakub@redhat.com>
31660         PR sanitizer/78158
31661         * tsan.c (instrument_builtin_call): If the memory model argument
31662         is not a constant, assume it is valid.
31664         PR c/67338
31665         * fold-const.c (round_up_loc): Negate divisor in unsigned type to
31666         avoid UB.
31668 2017-03-20  Segher Boessenkool  <segher@kernel.crashing.org>
31670         PR rtl-optimization/79910
31671         * combine.c (can_combine_p): Do not allow combining an I0 or I1
31672         if its dest is used by an insn before I2 (other than the combined
31673         insns themselves, which are properly handled already).
31675 2017-03-20  Segher Boessenkool  <segher@kernel.crashing.org>
31677         Revert:
31678         2017-03-17  Bernd Schmidt  <bschmidt@redhat.com>
31680         * combine.c (record_used_regs): New static function.
31681         (try_combine): Handle situations where there is an additional
31682         instruction between I2 and I3 which needs to have a LOG_LINK
31683         updated.
31685         Revert:
31686         2017-03-17  Jim Wilson  <jim.wilson@linaro.org>
31688         * combine.c (try_combine): Delete redundant i1 test.  Call
31689         prev_nonnote_nondebug_insn instead of prev_nonnote_insn.
31691 2017-03-20  Aaron Sawdey  <acsawdey@linux.vnet.ibm.com>
31693         PR target/80083
31694         * config/rs6000/rs6000.md (*movsi_internal1): Fix constraints for
31695         alternatives 13/14.
31697 2017-03-20  Bill Schmidt  <wschmidt@linux.vnet.ibm.com>
31699         PR tree-optimization/80054
31700         * gimple-ssa-strength-reduction.c (all_phi_incrs_profitable): Fail
31701         the optimization if a PHI or any of its arguments is not dominated
31702         by the candidate's basis.  Use gphi* rather than gimple* as
31703         appropriate.
31704         (replace_profitable_candidates): Clean up a gimple* variable that
31705         should be a gphi* variable.
31707 2017-03-20  Martin Sebor  <msebor@redhat.com>
31709         PR c++/52477
31710         * doc/extend.texi (attribute constructor): Document present limitation.
31712 2017-03-20  Kelvin Nilsen  <kelvin@gcc.gnu.org>
31714         PR target/79963
31715         * config/rs6000/altivec.h (vec_all_ne): Under __cplusplus__ and
31716         __POWER9_VECTOR__ #ifdef control, change template definition to
31717         use Power9-specific built-in function.
31718         (vec_any_eq): Likewise.
31719         * config/rs6000/vector.md (vector_ae_v2di_p): Change the flag used
31720         to control outcomes from this test.
31721         (vector_ae_<mode>p): For VEC_F modes, likewise.
31723 2017-03-20  Ian Lance Taylor  <iant@google.com>
31725         * config/i386/i386.c (ix86_function_regparm): Save an extra
31726         register for -fsplit-stack with DECL_STATIC_CHAIN.
31728 2017-03-17  Palmer Dabbelt  <palmer@dabbelt.com>
31730         PR target/79912
31731         * config/riscv/riscv.c (riscv_preferred_reload_class): Remove.
31732         (TARGET_PREFERRED_RELOAD_CLASS): Likewise.
31734 2017-03-17  Palmer Dabbelt  <palmer@dabbelt.com>
31736         * config/riscv/riscv.c (riscv_print_operand): Use "fence
31737         iorw,ow".
31738         * config/riscv/sync.mc (mem_thread_fence_1): Use "fence
31739         iorw,iorw".
31741 2017-03-20  Marek Polacek  <polacek@redhat.com>
31743         PR sanitizer/80063
31744         * asan.c (DEF_SANITIZER_BUILTIN): Use do { } while (0).
31746 2017-03-20  Richard Biener  <rguenther@suse.de>
31748         PR tree-optimization/80113
31749         * graphite-isl-ast-to-gimple.c (copy_loop_phi_nodes): Do not
31750         allocate extra SSA name for PHI def.
31751         (add_close_phis_to_outer_loops): Likewise.
31752         (add_close_phis_to_merge_points): Likewise.
31753         (copy_loop_close_phi_args): Likewise.
31754         (copy_cond_phi_nodes): Likewise.
31756 2017-03-20  Martin Liska  <mliska@suse.cz>
31758         PR middle-end/79753
31759         * tree-chkp.c (chkp_build_returned_bound): Do not build
31760         returned bounds for a LHS that's not a BOUNDED_P type.
31762 2017-03-20  Martin Liska  <mliska@suse.cz>
31764         PR target/79769
31765         PR target/79770
31766         * tree-chkp.c (chkp_find_bounds_1): Handle REAL_CST,
31767         COMPLEX_CST and VECTOR_CST.
31769 2017-03-20  Andreas Krebbel  <krebbel@linux.vnet.ibm.com>
31771         PR target/78857
31772         * config/s390/s390.md ("cmp<mode>_ccs_0"): Add a clobber of the
31773         target operand.  A new splitter adds the clobber statement in case
31774         the target operand is dead anyway.
31776 2017-03-19  Gerald Pfeifer  <gerald@pfeifer.com>
31778         * doc/install.texi (Specific) <sparc-*-linux*>: No longer refer
31779         to age-old versions of binutils and glibc.
31781 2017-03-18  Segher Boessenkool  <segher@kernel.crashing.org>
31783         * doc/contrib.texi (Contributors): Remove duplicate entry for myself.
31785 2017-03-18  Gerald Pfeifer  <gerald@pfeifer.com>
31787         * doc/contrib.texi (Contributors): Add Segher Boessenkool.
31789 2017-03-18  Gerald Pfeifer  <gerald@pfeifer.com>
31791         * doc/install.texi (Specific) <arm-*-eabi>: Remove old
31792         requirement for binutils 2.13.
31794 2017-03-17  Jim Wilson  <jim.wilson@linaro.org>
31796         * combine.c (try_combine): Delete redundant i1 test.  Call
31797         prev_nonnote_nondebug_insn instead of prev_nonnote_insn.
31799 2017-03-17  Palmer Dabbelt  <palmer@dabbelt.com
31801         * doc/install.texi (Specific) <riscv32-*-elf>: Add riscv32-*-elf,
31802         riscv32-*-linux, riscv64-*-elf, riscv64-*-linux to the table of
31803         contents.
31804         <riscv64-*-elf>: Re-arrange section
31805         <riscv32-*-elf>: Add a note about requiring binutils 2.28.
31806         <riscv32-*-linux>: Likewise.
31807         <riscv64-*-elf>: Likewise
31808         <riscv64-*-linux>: Likewise.
31810 2017-03-17  Richard Earnshaw  <rearnsha@arm.com>
31812         PR target/80052
31813         * aarch64.opt(verbose-cost-dump): Fix typo.
31815 2017-03-17  Pat Haugen  <pthaugen@us.ibm.com>
31817         PR target/79951
31818         * config/rs6000/rs6000.md (copysign<mode>3_fcpsgn): Test
31819         for VECTOR_UNIT_VSX_P (<MODE>mode) too.
31821 2017-03-17  Bernd Schmidt  <bschmidt@redhat.com>
31823         * reload.c (find_reloads): When reloading a nonoffsettable address,
31824         use RELOAD_OTHER for it and its address reloads.
31826         PR rtl-optimization/79910
31827         * combine.c (record_used_regs): New static function.
31828         (try_combine): Handle situations where there is an additional
31829         instruction between I2 and I3 which needs to have a LOG_LINK
31830         updated.
31832 2017-03-17  Jeff Law  <law@redhat.com>
31834         PR tree-optimization/71437
31835         * tree-vrp.c (simplify_stmt_for_jump_threading): Lookup the
31836         conditional in the hash table first.
31837         (vrp_dom_walker::before_dom_children): Extract condition from
31838         ASSERT_EXPR.  Record condition, its inverion and any implied
31839         conditions as well.
31841 2017-03-17  Marek Polacek  <polacek@redhat.com>
31842             Markus Trippelsdorf  <markus@trippelsdorf.de>
31844         PR tree-optimization/80079
31845         * gimple-ssa-store-merging.c (class pass_store_merging): Initialize
31846         m_stores_head.
31848 2017-03-17  Richard Biener  <rguenther@suse.de>
31850         PR middle-end/80075
31851         * tree-eh.c (stmt_could_throw_1_p): Only handle gimple assigns.
31852         Properly verify the LHS before the RHS possibly claims to be
31853         handled.
31854         (stmt_could_throw_p): Hande gimple conds fully here.  Clobbers
31855         do not throw.
31857 2017-03-17  Martin Jambor  <mjambor@suse.cz>
31859         * doc/invoke.texi (Option Options): Include -fipa-vrp in the list.
31860         (List of -O2 options): Likewise.
31861         (-fipa-bit-cp): Replace "ipa" with "interprocedural."
31862         (-fipa-vrp) New.
31864 2017-03-17  Tom de Vries  <tom@codesourcery.com>
31866         * gcov-dump.c (print_usage): Print bug_report_url.
31868 2017-03-17  Richard Biener  <rguenther@suse.de>
31870         PR middle-end/80050
31871         * genmatch.c (parser::next): Remove pointless check for CPP_EOF.
31872         (parser::peek): Likewise.
31874 2017-03-17  Richard Biener  <rguenther@suse.de>
31876         PR tree-optimization/80048
31877         * sese.c (free_sese_info): Properly release rename_map and
31878         copied_bb_map elements.
31880 2017-03-16  Alexandre Oliva <aoliva@redhat.com>
31882         * gimple-ssa-store-merging.c (struct imm_store_chain_info):
31883         Add linked-list forward and backlinks.  Insert on
31884         construction, remove on destruction.
31885         (class pass_store_merging): Add m_stores_head field.
31886         (pass_store_merging::terminate_and_process_all_chains):
31887         Iterate over m_stores_head list.
31888         (pass_store_merging::terminate_all_aliasing_chains):
31889         Likewise.
31890         (pass_store_merging::execute): Check for debug stmts first.
31891         Push new chains onto the m_stores_head stack.
31893 2017-03-16  Michael Meissner  <meissner@linux.vnet.ibm.com>
31895         PR target/71294
31896         * config/rs6000/vsx.md (vsx_splat_<mode>, VSX_D iterator): Allow a
31897         SPLAT operation on ISA 2.07 64-bit systems that have direct move,
31898         but no MTVSRDD support, by doing MTVSRD and XXPERMDI.
31900 2017-03-16  Jeff Law  <law@redhat.com>
31902         PR tree-optimization/71437
31903         * tree-ssa-dom.c (dom_opt_dom_walker): Remove thread_across_edge
31904         member function.  Implementation moved into after_dom_children
31905         member function and into the threader's thread_outgoing_edges
31906         function.
31907         (dom_opt_dom_walker::after_dom_children): Simplify by moving
31908         some code into new thread_outgoing_edges.
31909         * tree-ssa-threadedge.c (thread_across_edge): Make static and simplify
31910         definition.  Simplify marker handling (do it here).   Assume we always
31911         have the available expression and the const/copies tables.
31912         (thread_outgoing_edges): New function extracted from tree-ssa-dom.c
31913         and tree-vrp.c
31914         * tree-ssa-threadedge.h (thread_outgoing_edges): Declare.
31915         * tree-vrp.c (equiv_stack): No longer file scoped.
31916         (vrp_dom_walker): New class.
31917         (vrp_dom_walker::before_dom_children): New member function.
31918         (vrp_dom_walker::after_dom_children): Likewise.
31919         (identify_jump_threads):  Setup domwalker.  Use it rather than
31920         walking edges in a random order by hand.  Simplify setup/finalization.
31921         (finalize_jump_threads): Remove.
31922         (vrp_finalize): Do not call identify_jump_threads here.
31923         (execute_vrp): Do it here instead and call thread_through_all_blocks
31924         here too.
31926         PR tree-optimization/71437
31927         * tree-ssa-dom.c (pfn_simplify): Add basic_block argument.  All
31928         callers changed.
31929         (simplify_stmt_for_jump_threading): Add basic_block argument.  All
31930         callers changed.
31931         (lhs_of_dominating_assert): Moved from here into tree-vrp.c.
31932         (dom_opt_dom_walker::thread_across_edge): Remove
31933         handle_dominating_asserts argument.  All callers changed.
31934         (record_temporary_equivalences_from_stmts_at_dest): Corresponding
31935         changes.  Remove calls to lhs_of_dominating_assert.  Other
31936         uses of handle_dominating_asserts turn into unconditional code
31937         (simplify_control_stmt_condition_1): Likewise.
31938         (simplify_control_stmt_condition): Likewise.
31939         (thread_through_normal_block, thread_across_edge): Likewise.
31940         * tree-ssa-threadedge.h (thread_across_edge): Corresponding changes.
31941         * tree-vrp.c (lhs_of_dominating_assert): Move here.  Return original
31942         object if it is not an SSA_NAME.
31943         (simplify_stmt_for_jump_threading): Call lhs_of_dominating_assert
31944         before calling into the VRP specific simplifiers.
31945         (identify_jump_threads): Remove handle_dominating_asserts
31946         argument.
31948 2017-03-16  Jakub Jelinek  <jakub@redhat.com>
31950         PR fortran/79886
31951         * tree-diagnostic.c (default_tree_printer): No longer static.
31952         * tree-diagnostic.h (default_tree_printer): New prototype.
31954 2017-03-16  Tamar Christina  <tamar.christina@arm.com>
31956         * config/aarch64/aarch64-simd.md (*aarch64_simd_mov<mode>)
31957         Change ins into fmov.
31959 2017-03-16  Kyrylo Tkachov  <kyrylo.tkachov@arm.com>
31961         * config/aarch64/iterators.md (h_con): Return "x" for V4HF and V8HF.
31962         * config/aarch64/aarch64-simd.md (*aarch64_fma4_elt_from_dup<mode>):
31963         Use h_con constraint for operand 1.
31964         (*aarch64_fnma4_elt_from_dup<mode>): Likewise.
31965         (*aarch64_mulx_elt_from_dup<mode>): Likewise for operand 2.
31967 2017-03-15  Jeff Law  <law@redhat.com>
31969         PR tree-optimization/71437
31970         * tree-ssa-dom.c (derive_equivalences_from_bit_ior): New function.
31971         (record_temporary_equivalences): Use it.
31973         PR tree-optimization/71437
31974         * tree-ssa-dom.c (struct cond_equivalence): Moved from here into
31975         tree-ssa-scopedtables.
31976         (lookup_avail_expr, build_and_record_new_cond): Likewise.
31977         (record_conditions, record_cond, vuse_eq): Likewise.
31978         (record_edge_info): Adjust to API tweak of record_conditions.
31979         (simplify_stmt_for_jump_threading): Similarly for lookup_avail_expr.
31980         (record_temporary_equivalences, optimize_stmt): Likewise.
31981         (eliminate_redundant_computations): Likewise.
31982         (record_equivalences_from_stmt): Likewise.
31983         * tree-ssa-scopedtables.c: Include options.h and params.h.
31984         (vuse_eq): New function, moved from tree-ssa-dom.c
31985         (build_and_record_new_cond): Likewise.
31986         (record_conditions): Likewise.  Accept vector of conditions rather
31987         than edge_equivalence structure for first argument.
31988         for the first argument.
31989         (avail_exprs_stack::lookup_avail_expr): New member function, moved
31990         from tree-ssa-dom.c.
31991         (avail_exprs_stack::record_cond): Likewise.
31992         * tree-ssa-scopedtables.h (struct cond_equivalence): Moved here
31993         from tree-ssa-dom.c.
31994         (avail_exprs_stack): Add new member functions lookup_avail_expr
31995         and record_cond.
31996         (record_conditions): Declare.
31998 2017-03-15  Vladimir Makarov  <vmakarov@redhat.com>
32000         PR target/80017
32001         * lra-constraints.c (process_alt_operands): Increase reject for
32002         reloading an input/output operand.
32004 2017-03-15  Michael Meissner  <meissner@linux.vnet.ibm.com>
32006         PR target/79038
32007         * config/rs6000/rs6000.md (float<QHI:mode><IEEE128:mode>2): Define
32008         insns to convert from signed/unsigned char/short to IEEE 128-bit
32009         floating point.
32010         (floatuns<QHI:mode><IEEE128:mode>2): Likewise.
32012 2017-03-15  Uros Bizjak  <ubizjak@gmail.com>
32014         PR target/80019
32015         * config/i386/i386.c (ix86_vector_duplicate_value): Create
32016         subreg of inner mode for values already in registers.
32018 2017-03-15  Bernd Schmidt  <bschmidt@redhat.com>
32020         * config/c6x/c6x.c (hwloop_optimize): Handle case where the old
32021         iteration reg is used after the loop.
32023 2017-03-14  Martin Sebor  <msebor@redhat.com>
32025         PR tree-optimization/79800
32026         * gimple-ssa-sprintf.c (format_floating: Add argument.  Handle
32027         precision in negative-positive range.
32028         (format_floating): Call non-const overload with adjusted precision.
32030 2017-03-14  Michael Meissner  <meissner@linux.vnet.ibm.com>
32032         PR target/79947
32033         * config/rs6000/rs6000.h (TARGET_FRSQRTES): Add check for
32034         -mpowerpc-gfxopt.
32036 2017-03-14  Martin Sebor  <msebor@redhat.com>
32038         PR middle-end/80020
32039         * builtin-attrs.def (ATTR_ALLOC_SIZE_2_NOTHROW_LIST): New macro.
32040         * builtins.def (aligned_alloc): Use it.
32042         PR c/79936
32043         * Makefile.in (GTFILES): Add calls.c.
32044         * calls.c: Include "gt-calls.h".
32046 2017-03-14  Bernd Schmidt  <bschmidt@redhat.com>
32048         PR rtl-optimization/79728
32049         * regs.h (struct target_regs): New field
32050         x_contains_allocatable_regs_of_mode.
32051         (contains_allocatable_regs_of_mode): New macro.
32052         * reginfo.c (init_reg_sets_1): Initialize it, and change
32053         contains_reg_of_mode so it includes global regs as well.
32054         * reload.c (push_reload): Use contains_allocatable_regs_of_mode
32055         rather than contains_regs_of_mode.
32057 2017-03-14  Martin Liska  <mliska@suse.cz>
32059         * doc/invoke.texi: Document options that can't be combined with
32060         -fcheck-pointer-bounds.
32062 2017-03-14  Martin Liska  <mliska@suse.cz>
32064         PR middle-end/79831
32065         * doc/invoke.texi (-Wchkp): Document the option.
32067 2017-03-14  Martin Liska  <mliska@suse.cz>
32069         * Makefile.in: Install gcov-dump.
32071 2017-03-14  Martin Liska  <mliska@suse.cz>
32073         * multiple_target.c (expand_target_clones): Bail out for
32074         an invalid attribute.
32076 2017-03-14  Richard Biener  <rguenther@suse.de>
32078         * alias.c (struct alias_set_entry): Pack properly.
32079         * cfgloop.h (struct loop): Likewise.
32080         * cse.c (struct set): Likewise.
32081         * ipa-utils.c (struct searchc_env): Likewise.
32082         * loop-invariant.c (struct invariant): Likewise.
32083         * lra-remat.c (struct cand): Likewise.
32084         * recog.c (struct change_t): Likewise.
32085         * rtl.h (struct address_info): Likewise.
32086         * symbol-summary.h (function_summary): Likewise.
32087         * tree-loop-distribution.c (struct partition): Likewise.
32088         * tree-object-size.c (struct object_size_info): Likewise.
32089         * tree-ssa-loop-ivopts.c (struct cost_pair): Likewise.
32090         * tree-ssa-threadupdate.c (struct ssa_local_info_t): Likewise.
32091         * tree-vect-data-refs.c (struct _vect_peel_info): Likewise.
32092         * tree-vect-slp.c (struct _slp_oprnd_info): Likewise.
32093         * tree-vect-stmts.c (struct simd_call_arg_info): Likewise.
32094         * tree-vectorizer.h (struct _loop_vec_info): Likewise.
32095         (struct _stmt_vec_info): Likewise.
32097 2017-03-14  Martin Liska  <mliska@suse.cz>
32099         PR target/79892
32100         * multiple_target.c (create_dispatcher_calls): Check that
32101         a target can create a function dispatcher.
32103 2017-03-14  Martin Liska  <mliska@suse.cz>
32105         PR lto/66295
32106         * multiple_target.c (expand_target_clones): Drop local.local
32107         flag for default implementation.
32109 2017-03-14  Richard Biener  <rguenther@suse.de>
32111         PR tree-optimization/80030
32112         * tree-vect-stmts.c (vectorizable_store): Plug memleak.
32114 2017-03-13  Kito Cheng  <kito.cheng@gmail.com>
32116         * config/riscv/riscv.c (riscv_emit_float_compare>: Use
32117         gcc_fallthrough() instead of __attribute__((fallthrough));
32119 2017-03-13  Gerald Pfeifer  <gerald@pfeifer.com>
32121         * doc/gcc.texi: Remove "up" link to (DIR).
32122         * doc/gccint.texi: Ditto.
32124 2017-03-13  Gerald Pfeifer  <gerald@pfeifer.com>
32126         * doc/install.texi (Specific) <avr>: Remove reference to
32127         binutils 2.13.
32129 2017-03-13  Jeff Law  <law@redhat.com>
32131         * config/riscv/riscv.c (riscv_emit_float_compare): Use fallthru
32132         attribute rather than comments.
32134         * config/pdp11/pdp11.md (movmemhi): Adjust operand numbers to
32135         match_scratch operand is highest.
32137 2017-03-13  Martin Liska  <mliska@suse.cz>
32139         PR middle-end/78339
32140         * ipa-pure-const.c (warn_function_noreturn): If the declarations
32141         is a CHKP clone, use original declaration.
32143 2017-03-13  Claudiu Zissulescu  <claziss@synopsys.com>
32145         * config/arc/arc.c (arc_init): Use multiplier whenever we have it.
32146         (arc_conditional_register_usage): Use a different allocation order
32147         when optimizing for size.
32148         * common/config/arc/arc-common.c (arc_option_optimization_table):
32149         Section anchors default on when optimizing for size.
32151 2017-03-13  Claudiu Zissulescu  <claziss@synopsys.com>
32153         * config/arc/arc.md (*tst_bitfield_tst): Fix pattern.
32155 2017-03-13  Claudiu Zissulescu  <claziss@synopsys.com>
32157         * config/arc/arc.c (arc_output_addsi): Emit code density adds.
32158         * config/arc/arc.md (cpu_facility): Add cd variant.
32159         (*movqi_insn): Add code density variant.
32160         (*movhi_insn): Likewise.
32161         (*movqi_insn): Likewise.
32162         (*addsi3_mixed): Likewise.
32163         (subsi3_insn): Likewise.
32165 2017-03-13  Claudiu Zissulescu  <claziss@synopsys.com>
32167         * config/arc/arc.md (movsi_cond_exec): Update constraint.
32169 2017-03-13  Claudiu Zissulescu  <claziss@synopsys.com>
32171         * config/arc/arc.c (arc_legitimize_pic_address): Handle PIC
32172         expressions with MINUS and UNARY ops.
32174 2017-03-13  Kyrylo Tkachov  <kyrylo.tkachov@arm.com>
32176         PR target/79911
32177         * config/arm/neon.md (vec_sel_widen_ssum_lo<VQI:mode><VW:mode>3):
32178         Rename to...
32179         (vec_sel_widen_ssum_lo<mode><V_half>3): ... This. Avoid mismatch
32180         between vec_select and vector argument.
32181         (vec_sel_widen_ssum_hi<VQI:mode><VW:mode>3): Rename to...
32182         (vec_sel_widen_ssum_hi<mode><V_half>3): ... This. Likewise.
32183         (vec_sel_widen_usum_lo<VQI:mode><VW:mode>3): Rename to...
32184         (vec_sel_widen_usum_lo<mode><V_half>3): ... This.
32185         (vec_sel_widen_usum_hi<VQI:mode><VW:mode>3): Rename to...
32186         (vec_sel_widen_usum_hi<mode><V_half>3): ... This.
32188 2017-03-13  Richard Biener  <rguenther@suse.de>
32190         PR other/79991
32191         * params.def (vect-max-peeling-for-alignment): Fix typo.
32193 2017-03-12  Gerald Pfeifer  <gerald@pfeifer.com>
32195         * doc/install.texi (Specific) <mips-*-*>: Remove description of
32196         issue that only occurred with binutils below 2.18.
32198 2017-03-12  Gerald Pfeifer  <gerald@pfeifer.com>
32200         * doc/install.texi (Specific) <cris-axis-elf>: No longer
32201         refer to binutils 2.11/2.12 minimum.
32203 2017-03-12  Gerald Pfeifer  <gerald@pfeifer.com>
32205         * doc/install.texi (Specific) <powerpc-*-*>: Remove link to
32206         ftp.kernel.org and simplify binutils requirement.
32208 2017-03-11  Gerald Pfeifer  <gerald@pfeifer.com>
32210         * doc/invoke.texi (Warning Options): Fix spelling of link-time
32211         optimization.
32212         (Optimize Options): Ditto.  Also remove redundancy.
32214 2017-03-10  David Malcolm  <dmalcolm@redhat.com>
32216         PR translation/79848
32217         * ipa-devirt.c (warn_types_mismatch): Simplify uses of "%<%s%>" to
32218         "%qs".
32219         * ipa-pure-const.c (suggest_attribute): Likewise.  Convert _
32220         to G_ to avoid double translation.
32222 2017-03-10  David Malcolm  <dmalcolm@redhat.com>
32224         PR translation/79923
32225         * auto-profile.c (get_combined_location): Convert leading
32226         character of diagnostics to lower case and remove trailing period.
32227         (read_profile): Likewise for various diagnostics.
32228         * config/arm/arm.c (arm_option_override): Remove trailing period
32229         from various diagnostics.
32230         * config/msp430/msp430.c (msp430_expand_delay_cycles): Likewise.
32231         (msp430_expand_delay_cycles): Likewise.
32233 2017-03-10  David Malcolm  <dmalcolm@redhat.com>
32235         PR target/79925
32236         * config/aarch64/aarch64.c (aarch64_validate_mcpu): Quote the
32237         full command-line argument, rather than just "str".
32238         (aarch64_validate_march): Likewise.
32239         (aarch64_validate_mtune): Likewise.
32241 2017-03-10  Bernd Schmidt  <bschmidt@redhat.com>
32243         PR rtl-optimization/78911
32244         * lra-assigns.c (must_not_spill_p): New function.
32245         (spill_for): Use it.
32247 2017-03-10  Jakub Jelinek  <jakub@redhat.com>
32249         PR tree-optimization/79981
32250         * tree-vrp.c (extract_range_basic): Handle IMAGPART_EXPR of
32251         ATOMIC_COMPARE_EXCHANGE ifn result.
32252         (stmt_interesting_for_vrp, vrp_visit_stmt): Handle
32253         IFN_ATOMIC_COMPARE_EXCHANGE.
32255 2017-03-10  David Malcolm  <dmalcolm@redhat.com>
32257         PR driver/79875
32258         * opts.c (parse_sanitizer_options): Add missing question mark to
32259         "did you mean" message.
32261 2017-03-10  Bill Schmidt  <wschmidt@linux.vnet.ibm.com>
32263         * config/rs6000/rs6000-builtin.def (VMULEUB_UNS): Remove orphaned
32264         built-in.
32265         (VMULEUH_UNS): Likewise.
32266         (VMULOUB_UNS): Likewise.
32267         (VMULOUH_UNS): Likewise.
32268         * config/rs6000/rs6000.c (builtin_function_type): Remove
32269         references to ALTIVEC_BUILTIN_VMUL[EO]U[BH]_UNS.
32271 2017-03-10  David Malcolm  <dmalcolm@redhat.com>
32273         PR bootstrap/79952
32274         * read-rtl-function.c (function_reader::read_rtx_operand): Update
32275         x with result of extra_parsing_for_operand_code_0.
32276         (function_reader::extra_parsing_for_operand_code_0): Convert
32277         return type from void to rtx, returning x.  When reading
32278         SYMBOL_REF with SYMBOL_FLAG_HAS_BLOCK_INFO, reallocate x to the
32279         larger size containing struct block_symbol.
32281 2017-03-10  Segher Boessenkool  <segher@kernel.crashing.org>
32283         * config/rs6000/rs6000.c (rs6000_option_override_internal): Disallow
32284         -mfloat128-hardware without -m64.
32286 2017-03-10  Will Schmidt <will_schmidt@vnet.ibm.com>
32288         PR target/79941
32289         * config/rs6000/rs6000.c (builtin_function_type): Add VMUL*U[HB]
32290         entries to the case statement that marks unsigned arguments to
32291         overloaded functions.
32293 2017-03-10  Kelvin Nilsen  <kelvin@gcc.gnu.org>
32295         * config/rs6000/rs6000.c (rs6000_option_override_internal): Fix
32296         two typographic errors in the handling of TARGET_UPPER_REGS_DI.
32298 2017-03-10  Pat Haugen  <pthaugen@us.ibm.com>
32300         PR target/79907
32301         * config/rs6000/rs6000.c (rs6000_init_hard_regno_mode_ok): Test
32302         TARGET_UPPER_REGS_DI when setting 'wi' constraint regclass.
32304 2017-03-10  Martin Liska  <mliska@suse.cz>
32306         PR target/65705
32307         PR target/69804
32308         * toplev.c (process_options): Enable MPX with LSAN and UBSAN.
32309         * tree-chkp.c (chkp_walk_pointer_assignments): Verify that
32310         FIELD != NULL.
32312 2017-03-10  Olivier Hainque  <hainque@adacore.com>
32314         * tree-switch-conversion (array_value_type): Start by resetting
32315         candidate type to it's main variant.
32317 2017-03-10  Jakub Jelinek  <jakub@redhat.com>
32319         PR rtl-optimization/79909
32320         * combine.c (try_combine): Use simplify_replace_rtx on individual
32321         CALL_INSN_FUNCTION_USAGE elements instead of replace_rtx on copy_rtx
32322         of the whole CALL_INSN_FUNCTION_USAGE.
32324         PR tree-optimization/79972
32325         * gimple-ssa-warn-alloca.c (alloca_call_type): Only call
32326         get_range_info on SSA_NAMEs.  Formatting fixes.
32328 2017-03-10  Richard Biener  <rguenther@suse.de>
32329             Jakub Jelinek  <jakub@redhat.com>
32331         PR tree-optimization/77975
32332         * tree-ssa-loop-niter.c (get_base_for): Allow phi argument from latch
32333         edge to be constant.
32334         (get_val_for): For constant x return it.  Formatting fix.
32335         (loop_niter_by_eval): Avoid pointless looping if the next iteration
32336         would use the same bases as the current one.
32338 2017-03-09  Bill Schmidt  <wschmidt@linux.vnet.ibm.com>
32340         * config/rs6000/rs6000.c (rs6000_gen_le_vsx_permute): Use rotate
32341         instead of vec_select for V1TImode.
32342         * conifg/rs6000/vsx.md (VSX_LE): Remove mode iterator that is no
32343         longer needed.
32344         (VSX_LE_128): Add V1TI to this mode iterator.
32345         (*vsx_le_perm_load_<mode>): Change to use VSX_D mode iterator.
32346         (*vsx_le_perm_store_<mode>): Likewise.
32347         (pre-reload splitter for VSX stores): Likewise.
32348         (post-reload splitter for VSX stores): Likewise.
32349         (*vsx_xxpermdi2_le_<mode>): Likewise.
32350         (*vsx_lxvd2x2_le_<mode>): Likewise.
32351         (*vsx_stxvd2x2_le_<mode>): Likewise.
32353 2017-03-09  Michael Eager  <eager@eagercon.com>
32355         Correct failures with --enable-checking=yes,rtl.
32357         * config/microblaze/microblaze.c (microblaze_expand_shift):
32358         Replace GET_CODE test with CONST_INT_P and INTVAL test with
32359         test for const0_rtx.
32360         * config/microblaze/microblaze.md (ashlsi3_byone, ashrsi3_byone,
32361         lshrsi3_byone): Replace INTVAL with test for const1_rtx.
32363 2017-03-09  Richard Biener  <rguenther@suse.de>
32365         PR tree-optimization/79977
32366         * graphite-scop-detection.c (scop_detection::merge_sese):
32367         Handle the case of extra exits to blocks dominating the entry.
32369 2017-03-09  Toma Tabacu  <toma.tabacu@imgtec.com>
32371         * doc/sourcebuild.texi (Effective-Target Keywords, Other attributes):
32372         Document rdynamic.
32374 2017-03-09  Vladimir Makarov  <vmakarov@redhat.com>
32376         PR rtl-optimization/79949
32377         * lra-constraints.c (process_alt_operands): Check memory when
32378         trying to predict a cycle.  Print about the overall increase.
32380 2017-03-09  Richard Biener  <rguenther@suse.de>
32382         PR middle-end/79971
32383         * gimple-expr.c (useless_type_conversion_p): Preserve
32384         TYPE_SATURATING for fixed-point types.
32386 2017-03-09  Richard Biener  <rguenther@suse.de>
32388         PR ipa/79970
32389         * ipa-prop.c (ipa_modify_formal_parameters): Avoid changing
32390         alignment of BLKmode params.
32392 2017-03-09  Kyrylo Tkachov  <kyrylo.tkachov@arm.com>
32394         PR target/79913
32395         * config/aarch64/iterators.md (VALL_F16_NO_V2Q): New mode iterator.
32396         (VALL_NO_V2Q): Likewise.
32397         (VDQF_DF): Delete.
32398         * config/aarch64/aarch64-simd.md
32399         (aarch64_dup_lane_<vswap_width_name><mode>): Use VALL_F16_NO_V2Q
32400         iterator.
32401         (*aarch64_simd_vec_copy_lane_<vswap_width_name><mode>): Use
32402         VALL_NO_V2Q mode iterator.
32403         (*aarch64_vgetfmulx<mode>): Use VDQF iterator.
32405 2017-03-09  Martin Liska  <mliska@suse.cz>
32407         PR tree-optimization/79631
32408         * tree-chkp-opt.c (chkp_is_constant_addr): Call
32409         tree_int_cst_sign_bit just for INTEGER constants.
32411 2017-03-09  Martin Liska  <mliska@suse.cz>
32413         PR target/65705
32414         PR target/69804
32415         * toplev.c (process_options): Disable -fcheck-pointer-bounds with
32416         sanitizers.
32418 2017-03-09  Marek Polacek  <polacek@redhat.com>
32420         PR c++/79672
32421         * tree.c (inchash::add_expr): Handle TREE_VEC.
32423 2017-03-09  Martin Liska  <mliska@suse.cz>
32425         PR ipa/79764
32426         (chkp_narrow_size_and_offset): New function.
32427         (chkp_parse_array_and_component_ref): Support BIT_FIELD_REF.
32428         (void chkp_parse_bit_field_ref): New function.
32429         (chkp_make_addressed_object_bounds): Add case for BIT_FIELD_REF.
32430         (chkp_process_stmt): Use chkp_parse_bit_field_ref.
32432 2017-03-09  Martin Liska  <mliska@suse.cz>
32434         PR ipa/79761
32435         * tree-chkp.c (chkp_get_bound_for_parm): Get bounds for a param.
32436         (chkp_find_bounds_1): Remove gcc_unreachable.
32438 2017-03-09  Jakub Jelinek  <jakub@redhat.com>
32440         PR sanitizer/79944
32441         * asan.c (get_mem_refs_of_builtin_call): For BUILT_IN_ATOMIC* and
32442         BUILT_IN_SYNC*, determine the access type from the size suffix and
32443         always build a MEM_REF with that type.  Handle forgotten
32444         BUILT_IN_SYNC_FETCH_AND_NAND_16 and BUILT_IN_SYNC_NAND_AND_FETCH_16.
32446         PR target/79932
32447         * config/i386/avx512vlintrin.h (_mm256_cmpge_epi32_mask,
32448         _mm256_cmpge_epi64_mask, _mm256_cmpge_epu32_mask,
32449         _mm256_cmpge_epu64_mask, _mm256_cmple_epi32_mask,
32450         _mm256_cmple_epi64_mask, _mm256_cmple_epu32_mask,
32451         _mm256_cmple_epu64_mask, _mm256_cmplt_epi32_mask,
32452         _mm256_cmplt_epi64_mask, _mm256_cmplt_epu32_mask,
32453         _mm256_cmplt_epu64_mask, _mm256_cmpneq_epi32_mask,
32454         _mm256_cmpneq_epi64_mask, _mm256_cmpneq_epu32_mask,
32455         _mm256_cmpneq_epu64_mask, _mm256_mask_cmpge_epi32_mask,
32456         _mm256_mask_cmpge_epi64_mask, _mm256_mask_cmpge_epu32_mask,
32457         _mm256_mask_cmpge_epu64_mask, _mm256_mask_cmple_epi32_mask,
32458         _mm256_mask_cmple_epi64_mask, _mm256_mask_cmple_epu32_mask,
32459         _mm256_mask_cmple_epu64_mask, _mm256_mask_cmplt_epi32_mask,
32460         _mm256_mask_cmplt_epi64_mask, _mm256_mask_cmplt_epu32_mask,
32461         _mm256_mask_cmplt_epu64_mask, _mm256_mask_cmpneq_epi32_mask,
32462         _mm256_mask_cmpneq_epi64_mask, _mm256_mask_cmpneq_epu32_mask,
32463         _mm256_mask_cmpneq_epu64_mask, _mm_cmpge_epi32_mask,
32464         _mm_cmpge_epi64_mask, _mm_cmpge_epu32_mask, _mm_cmpge_epu64_mask,
32465         _mm_cmple_epi32_mask, _mm_cmple_epi64_mask, _mm_cmple_epu32_mask,
32466         _mm_cmple_epu64_mask, _mm_cmplt_epi32_mask, _mm_cmplt_epi64_mask,
32467         _mm_cmplt_epu32_mask, _mm_cmplt_epu64_mask, _mm_cmpneq_epi32_mask,
32468         _mm_cmpneq_epi64_mask, _mm_cmpneq_epu32_mask, _mm_cmpneq_epu64_mask,
32469         _mm_mask_cmpge_epi32_mask, _mm_mask_cmpge_epi64_mask,
32470         _mm_mask_cmpge_epu32_mask, _mm_mask_cmpge_epu64_mask,
32471         _mm_mask_cmple_epi32_mask, _mm_mask_cmple_epi64_mask,
32472         _mm_mask_cmple_epu32_mask, _mm_mask_cmple_epu64_mask,
32473         _mm_mask_cmplt_epi32_mask, _mm_mask_cmplt_epi64_mask,
32474         _mm_mask_cmplt_epu32_mask, _mm_mask_cmplt_epu64_mask,
32475         _mm_mask_cmpneq_epi32_mask, _mm_mask_cmpneq_epi64_mask,
32476         _mm_mask_cmpneq_epu32_mask, _mm_mask_cmpneq_epu64_mask): Move
32477         definitions outside of __OPTIMIZE__ guarded section.
32479         PR target/79932
32480         * config/i386/avx512bwintrin.h (_mm512_packs_epi32,
32481         _mm512_maskz_packs_epi32, _mm512_mask_packs_epi32,
32482         _mm512_packus_epi32, _mm512_maskz_packus_epi32,
32483         _mm512_mask_packus_epi32): Move definitions outside of __OPTIMIZE__
32484         guarded section.
32486 2017-03-09  Andreas Krebbel  <krebbel@linux.vnet.ibm.com>
32488         * config/s390/vx-builtins.md ("vfee<mode>", "vfeez<mode>")
32489         ("vfenez<mode>"): Add missing constraints.
32491 2017-03-08  Martin Sebor  <msebor@redhat.com>
32493         PR target/79928
32494         * config/nds32/nds32.c (nds32_option_override):
32495         Fix misspelled diagnostic.
32497 2017-03-08  Jakub Jelinek  <jakub@redhat.com>
32499         PR c/79940
32500         * gimplify.c (gimplify_omp_for): Replace index var in outer
32501         taskloop statement with an artificial variable and add
32502         OMP_CLAUSE_PRIVATE clause for it.
32504 2017-03-08  Richard Biener  <rguenther@suse.de>
32506         PR tree-optimization/79955
32507         * tree-ssa-uninit.c (warn_uninitialized_vars): Do not warn
32508         for accesses that are completely outside of the variable.
32510 2017-03-08  Andrew Haley  <aph@redhat.com>
32512         PR tree-optimization/79943
32513         * tree-ssa-loop-split.c (compute_new_first_bound): When
32514         calculating the new upper bound, (END-BEG) should be added, not
32515         subtracted.
32517 2017-03-08  Jakub Jelinek  <jakub@redhat.com>
32519         * config/avr/avr.md (setmemhi): Make sure match_dup
32520         operand number comes before match_scratch.
32522 2017-03-08  Richard Biener  <rguenther@suse.de>
32524         PR tree-optimization/79920
32525         * tree-vect-slp.c (vect_create_mask_and_perm): Remove and inline
32526         with ncopies == 1 to ...
32527         (vect_transform_slp_perm_load): ... here.  Properly compute
32528         all element loads by iterating VF times over the group.  Do
32529         not handle ncopies (computed in a broken way) in
32530         vect_create_mask_and_perm.
32532 2017-03-08  Jakub Jelinek  <jakub@redhat.com>
32534         PR sanitizer/79904
32535         * internal-fn.c (expand_vector_ubsan_overflow): If arg0 or arg1
32536         is a uniform vector, use uniform_vector_p return value instead of
32537         building ARRAY_REF on folded VIEW_CONVERT_EXPR to array type.
32539 2017-03-07  Marek Polacek  <polacek@redhat.com>
32541         PR middle-end/79809
32542         * gimple-ssa-warn-alloca.c (pass_walloca::gate): Use HOST_WIDE_INT.
32543         (alloca_call_type): Likewise.
32545 2017-03-07  Martin Liska  <mliska@suse.cz>
32547         * gcov.c (process_args): Put comment to correct location.
32549 2017-03-07  Martin Liska  <mliska@suse.cz>
32551         PR middle-end/68270
32552         * tree-chkp.c (chkp_may_narrow_to_field): Add new argument ref.
32553         Use array_at_struct_end_p instead of DECL_CHAIN (field).
32554         (chkp_narrow_bounds_for_field): Likewise.
32555         (chkp_parse_array_and_component_ref): Pass one more argument to
32556         call.
32558 2017-03-07  Richard Biener  <rguenther@suse.de>
32560         * tree-vect-loop-manip.c (slpeel_add_loop_guard): Preserve
32561         preheaders.
32563 2017-03-07  Segher Boessenkool  <segher@kernel.crashing.org>
32565         * config/i386/i386.c (ix86_local_alignment): Align most aggregates
32566         of 16 bytes and more to 16 bytes, not those of 16 bits and more.
32568 2017-03-07  Kyrylo Tkachov  <kyrylo.tkachov@arm.com>
32570         PR c/79855
32571         * params.def (PARAM_STORE_MERGING_ALLOW_UNALIGNED): Add full stop
32572         to end of description.
32573         (PARAM_MAX_STORES_TO_MERGE): Likewise.
32575 2017-03-07  Jakub Jelinek  <jakub@redhat.com>
32577         PR rtl-optimization/79901
32578         * config/i386/sse.md (*avx512bw_<code><mode>3<mask_name>): Renamed to
32579         ...
32580         (*avx512f_<code><mode>3<mask_name>): ... this.
32581         (<code><mode>3 with maxmin code iterator): Use VI8_AVX2_AVX512F
32582         iterator instead of VI8_AVX2_AVX512BW.
32584         PR rtl-optimization/79901
32585         * expr.c (expand_expr_real_2): For vector MIN/MAX, if there is no
32586         min/max expander, expand it using expand_vec_cond_expr.
32588         PR sanitizer/79897
32589         * ubsan.c (ubsan_encode_value): Call mark_addressable on the
32590         temporary.
32592 2017-03-06  Jakub Jelinek  <jakub@redhat.com>
32594         PR c++/79821
32595         * dwarf2out.h (dw_vec_const): Change array type from unsigned char *
32596         to void * for PCH reasons.
32597         * dwarf2out.c (output_loc_operands, output_die): Cast
32598         v.val_vec.array to unsigned char *.
32600 2017-03-06  John David Anglin  <danglin@gcc.gnu.org>
32602         PR target/77850
32603         * config/pa/pa-64.h (PAD_VARARGS_DOWN): Don't pad down complex and
32604         vector types.
32606 2017-03-06  Vladimir Makarov  <vmakarov@redhat.com>
32608         PR rtl-optimization/79571
32609         * lra-constraints.c (process_alt_operands): Calculate static
32610         reject and subtract it from overall when only addresses will be
32611         reloaded.
32613 2017-03-06  Julia Koval  <julia.koval@intel.com>
32615         PR target/79793
32616         * config/i386/i386.c (ix86_minimum_incoming_stack_boundary): Set
32617         incoming stack boundary to 128 for 64-bit targets.
32619 2017-03-06  Richard Biener  <rguenther@suse.de>
32621         PR tree-optimization/79894
32622         * tree-vectorizer.c (vectorize_loops): Set loop_vectorized_call
32623         to NULL after folding it.
32625 2017-03-06  Richard Biener  <rguenther@suse.de>
32627         PR tree-optimization/79824
32628         * tree-vect-stmts.c (get_group_load_store_type): Fix alignment
32629         check disabling peeling for gaps.
32631 2017-03-06  Toma Tabacu  <toma.tabacu@imgtec.com>
32633         * doc/sourcebuild.texi (Effective-Target Keywords, Environment
32634         attributes): Document gettimeofday.
32636 2017-03-06  Robin Dapp  <rdapp@linux.vnet.ibm.com>
32638         * config/s390/s390.c (s390_option_override_internal): Set
32639         PARAM_MIN_VECT_LOOP_BOUND
32641 2017-03-06  Robin Dapp  <rdapp@linux.vnet.ibm.com>
32643         * config/s390/s390.c (s390_asm_output_function_label): Use nopr %r0.
32644         * config/s390/s390.md: Likewise.
32646 2017-03-06  Jakub Jelinek  <jakub@redhat.com>
32648         PR target/79812
32649         * config/i386/sse.md (VI8F_256_512): Remove mode iterator.
32650         (<avx2_avx512>_perm<mode>): Rename to ...
32651         (avx2_perm<mode>): ... this.  Use VI8F_256 iterator instead
32652         of VI8F_256_512.
32653         (<avx512>_perm<mode>_mask): Rename to ...
32654         (avx512vl_perm<mode>_mask): ... this.  Use VI8F_256 iterator instead
32655         of VI8F_256_512.
32656         (<avx2_avx512>_perm<mode>_1<mask_name>): Rename to ...
32657         (avx2_perm<mode>_1<mask_name): ... this.  Use VI8F_256 iterator
32658         instead of VI8F_256_512.
32659         (avx512f_perm<mode>): New define_expand.
32660         (avx512f_perm<mode>_mask): Likewise.
32661         (avx512f_perm<mode>_1<mask_name>): New define_insn.
32662         (<avx512>_vec_dup<mode>_1): Fix up vec_select mode.
32664 2017-03-06  Prachi Godbole  <prachi.godbole@imgtec.com>
32666         * config/mips/mips-msa.md (msa_fmax_a_<msafmt>, msa_fmin_a_<msafmt>,
32667         msa_max_a_<msafmt>, msa_min_a_<msafmt>): Introduce mode interator for
32668         if_then_else.
32669         (smin<mode>3, smax<mode>3): Change operand print code from 'B' to 'E'.
32671 2017-03-06  Martin Liska  <mliska@suse.cz>
32673         PR sanitize/79783
32674         * asan.c (asan_expand_poison_ifn): Do not expand ASAN_POISON
32675         when having a SSA NAME w/o VAR_DECL assigned to it.
32677 2017-03-06  Prachi Godbole  <prachi.godbole@imgtec.com>
32679         * config/mips/mips-msa.md (msa_dotp_<su>_d, msa_dpadd_<su>_d,
32680         msa_dpsub_<su>_d): Fix MODE for vec_select.
32682 2017-03-06  Prachi Godbole  <prachi.godbole@imgtec.com>
32684         * config/mips/mips.c (mips_gen_const_int_vector): Change type of last
32685         argument.
32686         * config/mips/mips-protos.h (mips_gen_const_int_vector): Likewise.
32688 2017-03-06  Richard Biener  <rguenther@suse.de>
32690         * lto-streamer.c (lto_check_version): Use %qs in diagnostics.
32691         * plugin.c (register_plugin_info): Likewise.
32692         * tree-chkp.c (chkp_make_static_const_bounds): Likewise.
32694 2017-03-05  Jakub Jelinek  <jakub@redhat.com>
32696         * config/i386/sse.md (sse_storehps, sse_storelps,
32697         avx_<castmode><avxsizesuffix>_<castmode>,
32698         avx512f_<castmode><avxsizesuffix>_<castmode>,
32699         avx512f_<castmode><avxsizesuffix>_256<castmode>): Require
32700         in condition that at least one operand is not a MEM.
32702 2017-03-03  Jakub Jelinek  <jakub@redhat.com>
32704         PR middle-end/79805
32705         * internal-fn.def (ATOMIC_BIT_TEST_AND_SET, ATOMIC_BIT_TEST_AND_RESET,
32706         ATOMIC_BIT_TEST_AND_COMPLEMENT, ATOMIC_COMPARE_EXCHANGE): Remove
32707         ECF_NOTHROW.
32708         * gimple-fold.c (fold_builtin_atomic_compare_exchange): Set
32709         gimple_call_nothrow_p flag based on whether original builtin can throw.
32710         If it can, emit following stmts on the fallthrough edge.
32711         * tree-ssa-ccp.c (optimize_atomic_bit_test_and): Similarly, except
32712         don't create new bb if inserting just debug stmts on the edge, try to
32713         insert them on the fallthru bb or just reset debug stmts.
32715 2017-03-03  Segher Boesssenkool  <segher@kernel.crashing.org>
32717         PR target/43763
32718         * config/rs6000/rs6000.c (rs6000_final_prescan_insn): Save and
32719         restore recog_data (including the operand rtxes inside it) around
32720         the call to get_insn_template.
32722 2017-03-03  Martin Sebor  <msebor@redhat.com>
32724         PR tree-optimization/79699
32725         * context.c (context::~context): Free MPFR caches to avoid
32726         a memory leak on program exit.
32728 2017-03-03  Kyrylo Tkachov  <kyrylo.tkachov@arm.com>
32730         * config/aarch64/aarch64.c (aarch64_float_const_representable_p):
32731         Use wide_int::ulow () instead of .elt (0).
32733 2017-03-03  Uros Bizjak  <ubizjak@gmail.com>
32735         * config/i386/i386.md (*pushtf): Change *roF constraint to *roC.
32736         (*pushxf): Limit oF constraint to 32bit targets and add oC
32737         constraint for 64bit targets.
32738         (pushxf splitter): Use PUSH_ROUNDING to calculate stack adjustment.
32739         (*pushdf): Change rmF constraint to rmC.
32741 2017-03-03  Martin Liska  <mliska@suse.cz>
32743         * tree-ssa-loop-prefetch.c (pass_loop_prefetch::execute):
32744         Remove unused variable.
32746 2017-03-03  Jakub Jelinek  <jakub@redhat.com>
32748         PR target/79807
32749         * config/i386/i386.c (ix86_expand_multi_arg_builtin): If target
32750         is a memory operand, increase num_memory.
32751         (ix86_expand_args_builtin): Likewise.
32753 2017-03-03  Jan Hubicka  <jh@suse.cz>
32755         PR lto/79760
32756         * ipa-devirt.c (maybe_record_node): Properly handle
32757         __cxa_pure_virtual visibility.
32759 2017-03-03  Martin Liska  <mliska@suse.cz>
32761         PR tree-optimization/79803
32762         * tree-ssa-loop-prefetch.c (tree_ssa_prefetch_arrays): Remove
32763         assert.
32764         (pass_loop_prefetch::execute): Disabled optimization if an
32765         assumption about L1 cache size is not met.
32767 2017-03-03  Martin Liska  <mliska@suse.cz>
32769         PR rtl-optimization/79574
32770         * gcse.c (struct gcse_expr): Use HOST_WIDE_INT instead of int.
32771         (hash_scan_set): Likewise.
32772         (dump_hash_table): Likewise.
32773         (hoist_code): Likewise.
32775 2017-03-03  Richard Biener  <rguenther@suse.de>
32777         * fixed-value.c (fixed_from_string): Restore use of elt (1)
32778         in place of uhigh ().
32779         (fixed_convert_from_real): Likewise.
32781 2017-03-03  Uros Bizjak  <ubizjak@gmail.com>
32783         PR target/79514
32784         * config/i386/i386.md (*pushxf_rounded): Use Pmode instead of DImode.
32786 2017-03-03  Richard Biener  <rguenther@suse.de>
32788         PR middle-end/79818
32789         * match.pd ( X +- C1 CMP C2 -> X CMP C2 -+ C1): Add missing
32790         TYPE_OVERFLOW_UNDEFINED check.
32792 2017-03-02  Bill Schmidt  <wschmidt@linux.vnet.ibm.com>
32794         * config/rs6000/vector.md (vector_ne_<mode>_p): Correct operand
32795         numbers.
32796         (vector_ae_<mode>_p): Likewise.
32797         (vector_nez_<mode>_p): Likewise.
32798         (vector_ne_v2di_p): Likewise.
32799         (vector_ae_v2di_p): Likewise.
32800         (vector_ne_<mode>_p): Likewise.
32801         * config/rs6000/vsx.md (vsx_tsqrt<mode>2_fg): Correct operand
32802         numbers.
32803         (vsx_tsqrt<mode>2_fe): Likewise.
32805 2017-03-02  Uros Bizjak  <ubizjak@gmail.com>
32807         PR target/79514
32808         * config/i386/i386.md (*pushxf_rounded): New insn_and_split pattern.
32810 2017-03-02  Jakub Jelinek  <jakub@redhat.com>
32812         PR rtl-optimization/79780
32813         * cprop.c (one_cprop_pass): When second and further conditional trap
32814         in a single basic block is turned into an unconditional trap, turn it
32815         into a deleted note to avoid RTL verification failures.
32817 2017-03-02  Richard Biener  <rguenther@suse.de>
32819         * fold-const.c (const_binop): Use ulow () instead of elt (0).
32821 2017-03-02  Richard Biener  <rguenther@suse.de>
32823         PR tree-optimization/79345
32824         PR c++/42000
32825         * tree-ssa-alias.c (walk_aliased_vdefs_1): Take a limit
32826         param and abort the walk, returning -1 if it is hit.
32827         (walk_aliased_vdefs): Take a limit param and pass it on.
32828         * tree-ssa-alias.h (walk_aliased_vdefs): Add a limit param,
32829         defaulting to 0 and return a signed int.
32830         * tree-ssa-uninit.c (struct check_defs_data): New struct.
32831         (check_defs): New helper.
32832         (warn_uninitialized_vars): Use walk_aliased_vdefs to warn
32833         about uninitialized memory.
32834         * fixed-value.c (fixed_from_string): Use ulow/uhigh to avoid
32835         bogus uninitialized warning.
32836         (fixed_convert_from_real): Likewise.
32838 2017-03-02  Bin Cheng  <bin.cheng@arm.com>
32840         PR tree-optimization/66768
32841         * tree-ssa-loop-ivopts.c (find_interesting_uses_address): Skip addr
32842         iv_use if base object can't be determined.
32844 2017-03-02  Jakub Jelinek  <jakub@redhat.com>
32846         PR tree-optimization/79345
32847         * gensupport.h (struct pattern_stats): Add min_scratch_opno field.
32848         * gensupport.c (get_pattern_stats_1) <case MATCH_SCRATCH>: Update it.
32849         (get_pattern_stats): Initialize it.
32850         * genemit.c (gen_expand): Verify match_scratch numbers come after
32851         match_operand/match_dup numbers.
32852         * config/i386/i386.md (<s>mul<mode>3_highpart): Swap match_dup and
32853         match_scratch numbers.
32854         * config/i386/sse.md (avx2_gathersi<mode>, avx2_gatherdi<mode>):
32855         Likewise.
32856         * config/s390/s390.md (trunctdsd2): Likewise.
32858 2017-03-02  Richard Biener  <rguenther@suse.de>
32860         * wide-int.h (wide_int_storage::operator=): Implement in terms
32861         of wi::copy.
32863 2017-03-02  Richard Biener  <rguenther@suse.de>
32865         PR tree-optimization/79777
32866         * tree-ssa-pre.c (eliminate_insert): Give up if we simplify
32867         the to insert expression to sth existing.
32869 2017-03-01  Martin Sebor  <msebor@redhat.com>
32871         PR middle-end/79692
32872         * gimple-ssa-sprintf.c
32873         (directive::known_width_and_precision): New function.
32874         (format_integer): Use it.
32875         (get_mpfr_format_length): Consider the full range of precision
32876         when computing %g output with the # flag.  Set the likely byte
32877         count to 3 rather than 1 when precision is indeterminate.
32878         (format_floating): Correct the lower bound of precision.
32880 2017-03-01  Bill Schmidt  <wschmidt@linux.vnet.ibm.com>
32882         * doc/invoke.texi: Document default code model for 64-bit Linux.
32884 2017-03-01  Aaron Sawdey  <acsawdey@linux.vnet.ibm.com>
32886         PR target/79752
32887         * config/rs6000/rs6000.md (peephole2 for udiv/umod): Should emit
32888         udiv rather than div since input pattern is unsigned.
32890 2017-03-01  Uros Bizjak  <ubizjak@gmail.com>
32892         * config/i386/i386.c (print_reg): Warn for values of
32893         unsupported size in integer register.
32895 2017-03-01  Michael Meissner  <meissner@linux.vnet.ibm.com>
32897         PR target/79439
32898         * config/rs6000/predicates.md (current_file_function_operand): Do
32899         not allow self calls to be local if the function is replaceable.
32901 2017-03-01  Kelvin Nilsen  <kelvin@gcc.gnu.org>
32903         PR target/79395
32904         * config/rs6000/altivec.h (vec_ctz and others): Change the
32905         preprocessor macro that controls conditional compilation from
32906         _ARCH_PWR9 to __POWER9_VECTOR__.
32907         (vec_all_ne): Change parameterization of __altivec_scalar_pred
32908         macro expansion under preprocessor #ifdef __POWER9_VECTOR__
32909         control (instead of _ARCH_PWR9 control) so that template
32910         definition uses power9-specific function.
32911         (vec_any_eq): Likewise.
32912         (vec_all_ne): Change macro definition to use a power9-specific
32913         expansion under #ifdef __POWER9_VECTOR__ control (instead of
32914         _ARCH_PWR9 control).
32915         (vec_any_eq) Likewise.
32916         * config/rs6000/rs6000-builtin.def (CMPNEF): Remove BU_P9V_AV_2
32917         expansion for CMPNEF to remove support for xvcmpnesp instruction.
32918         (CMPNED): Remove BU_P9V_AV2 expansion for CMPNED to remove
32919         support for xvcmpnedp instruction.
32920         (VCMPNEB_P): Replace BU_P9V_AV_P macro expansion with BU_P9V_AV_2
32921         macro expansion so that Power9 implementation of vec_all_ne does
32922         not use the AltiVec predicate framework.
32923         (VCMPNEH_P): Likewise.
32924         (VCMPNEW_P): Likewise.
32925         (VCMPNED_P): Likewise.
32926         (VCMPNEFP_P): Likewise.
32927         (VCMPNEDP_P): Likewise.
32928         (VCMPAEB_P): Add BU_P9V_AV_2 macro expansion to change
32929         implementation of vec_any_eq to not use AltiVec predicate
32930         framework.
32931         (VCMPAEH_P): Likewise.
32932         (VCMPAEW_P): Likewise.
32933         (VCMPAED_P): Likewise.
32934         (VCMPAEFP_P): Likewise.
32935         (VCMPAEDP_P): Likewise.
32936         (VCMPNE_P): Replace BU_P9V_OVERLOAD_P macro expansion with
32937         BU_P9V_OVERLOAD_2 so that Power9 implementation of vec_all_ne does
32938         not use the AltiVec predicate framework.
32939         (VCMPAE_P): Add BU_P9V_OVERLOAD_2 macro to change implementation
32940         of vec_any_eq to not use AltiVec predicate framework.
32941         * config/rs6000/rs6000-c.c (rs6000_target_modify_macros): Add
32942         support for predefined __POWER9_VECTOR__ macro to indicate that
32943         Power9 instruction selection is enabled.
32944         (altivec_overloaded_builtins): Remove extraneous
32945         ALTIVEC_BUILTIN_VEC_CMPNE entry for overloaded
32946         function argument types RS6000_BTI_bool_V16QI and
32947         RS6000_BTI_bool_V16QI.  Remove erroneous ALTIVEC_BUILTIN_VEC_CMPNE
32948         entry for overloaded function argument types RS6000_BTI_bool_V4SI
32949         andRS6000_BTI_bool_V4SI, mapping to P9V_BUILTIN_CMPNEB.  Remove
32950         two entries mapping to P9V_BUITIN_CMPNED and one entry mapping to
32951         P9V_BUILTIN_CMPNEF to force use of instructions not specific to
32952         Power9 for implementations of vec_cmpne.  Change the signature for
32953         all definitions of the overloaded P9V_BUILTIN_VEC_CMPNE_P function
32954         (representing vec_all_ne) to remove the previously described first
32955         argument of type RS6000_BTI_INTSI, as this was an artifact of
32956         reliance on the AltiVec predicate framework, which is no longer
32957         used in the implementation of these functions.  Add
32958         P9V_BUILTIN_VEC_VCMPAE_P entries (representing the vec_anyeq
32959         function) to match all of the P9V_BUILTIN_VEC_VCMNE_P entries
32960         since, unlike the AltiVec predicate framework implementation, we
32961         do not share function descriptors between vec_alle and vec_anyeq.
32962         (altivec_resolve_overloaded_builtin): Add SFmode and DFmode to the
32963         set of modes that receive special treatment even when
32964         TARGET_P9_VECTOR is true.  The special treatment emits code that
32965         does not depend on Power9 instructions.
32966         * config/rs6000/vector.md (vector_ne_<mode>_p): Change this
32967         define_expand to not rely on AltiVec predicate framework.
32968         (vector_ae_<mode>p): New define_expand to represent vec_any_eq
32969         function.
32970         (vector_ne_v2di_p): Change this define_expand to not rely on
32971         AltiVec predicate framework.
32972         (vector_ae_v2di_p): New define_expand to represent vec_any_eq
32973         function.
32974         (vector_ne_<mode>_p): Change this define_expand to not rely on
32975         AltiVec predicate framework.
32976         (vector_ae_<mode>p): New define_expand to represent vec_any_eq
32977         function.
32978         * config/rs6000/vsx.md (*vsx_ne_<mode>_p): For modes VSX_EXTRACT_I
32979         (V16QI, V8HI, V4SI), correct a typo in the code emitted for this
32980         define_insn pattern.
32981         (*vsx_ne_<mode>_p): For modes VSX_F (V4SF and V2DF), remove this
32982         define_insn pattern because the xvcmpne<VSs>. instruction is not
32983         supported.
32984         (vcmpne<VSs>): Remove this define_insn because xvcmpne<VSs>
32985         instruction is not supported.
32987 2017-03-01  Jakub Jelinek  <jakub@redhat.com>
32989         * config/nvptx/nvptx.c: Include intl.h.
32991 2017-03-01  Martin Jambor  <mjambor@suse.cz>
32993         PR lto/78140
32994         * ipa-prop.h (ipa_bits): Removed field known.
32995         (ipa_jump_func): Removed field vr_known.  Changed fields bits and m_vr
32996         to pointers.  Adjusted their comments to warn about their sharing.
32997         (ipcp_transformation_summary): Change bits to a vector of pointers.
32998         (ipa_check_create_edge_args): Moved to ipa-prop.c, declare.
32999         (ipa_get_ipa_bits_for_value): Declare.
33000         * tree-vrp.h (value_range): Mark as GTY((for_user)).
33001         * ipa-prop.c (ipa_bit_ggc_hash_traits): New.
33002         (ipa_bits_hash_table): Likewise.
33003         (ipa_vr_ggc_hash_traits): Likewise.
33004         (ipa_vr_hash_table): Likewise.
33005         (ipa_print_node_jump_functions_for_edge): Adjust for bits and m_vr
33006         being pointers and vr_known being removed.
33007         (ipa_set_jf_unknown): Likewise.
33008         (ipa_get_ipa_bits_for_value): New function.
33009         (ipa_set_jfunc_bits): Likewise.
33010         (ipa_get_value_range): New overloaded functions.
33011         (ipa_set_jfunc_vr): Likewise.
33012         (ipa_compute_jump_functions_for_edge): Use the above functions to
33013         construct bits and vr parts of jump functions.
33014         (ipa_check_create_edge_args): Move here from ipa-prop.h, also allocate
33015         ipa_bits_hash_table and ipa_vr_hash_table if they do not already
33016         exist.
33017         (ipcp_grow_transformations_if_necessary): Also allocate
33018         ipa_bits_hash_table and ipa_vr_hash_table if they do not already
33019         exist.
33020         (ipa_node_params_t::duplicate): Do not copy bits, just pointers to
33021         them.  Fix too long lines.
33022         (ipa_write_jump_function): Adjust for bits and m_vr being pointers and
33023         vr_known being removed.
33024         (ipa_read_jump_function): Use new setter functions to construct bits
33025         and vr parts of jump functions or set them to NULL.
33026         (write_ipcp_transformation_info): Adjust for bits being pointers.
33027         (read_ipcp_transformation_info): Likewise.
33028         (ipcp_update_bits): Likewise.  Fix excessively long lines a trailing
33029         space.
33030         Include gt-ipa-prop.h.
33031         * ipa-cp.c (propagate_bits_across_jump_function): Adjust for bits
33032         being pointers.
33033         (ipcp_store_bits_results): Likewise.
33034         (propagate_vr_across_jump_function): Adjust for m_vr being a pointer.
33035         Do not write to existing jump functions but use a temporary instead.
33037 2017-03-01  Jakub Jelinek  <jakub@redhat.com>
33039         PR c++/79681
33040         * fold-const.c (make_bit_field_ref): If orig_inner is COMPONENT_REF,
33041         attempt to use its first operand as BIT_FIELD_REF base.
33043 2017-03-01  Richard Biener  <rguenther@suse.de>
33045         PR middle-end/79721
33046         * tree-chrec.c (chrec_evaluate): Perform computation of Newtons
33047         interpolating formula in wrapping arithmetic.
33048         (chrec_apply): Convert chrec_evaluate return value to wanted type.
33050 2017-03-01  Jakub Jelinek  <jakub@redhat.com>
33052         PR tree-optimization/79734
33053         * tree-vect-generic.c (expand_vector_condition): Optimize
33054         AVX512 vector boolean VEC_COND_EXPRs into bitwise operations.
33055         Handle VEC_COND_EXPR where comparison has different inner width from
33056         type's inner width.
33058 2017-02-28  Sandra Loosemore  <sandra@codesourcery.com>
33060         * doc/invoke.texi (ARC Options): Copy-edit to fix punctuation,
33061         markup, and similar issues.  Remove @opindex entries for things
33062         that aren't options.  Add missing -mmpy-option entries.
33064 2017-02-28  Jakub Jelinek  <jakub@redhat.com>
33066         PR tree-optimization/79737
33067         * gimple-ssa-store-merging.c (encode_tree_to_bitpos): If bitlen is
33068         a multiple of BITS_PER_UNIT and !BYTES_BIG_ENDIAN, clear
33069         tmpbuf[byte_size - 1].  Call natice_encode_expr with byte_size - 1
33070         instead of byte_size.  Formatting fix.
33071         (shift_bytes_in_array_right): Formatting fix.
33073 2017-02-28  Eric Botcazou  <ebotcazou@adacore.com>
33075         PR target/79749
33076         * config/sparc/sparc.c (sparc_frame_pointer_required): Add missing
33077         condition on optimize for the leaf function test.
33079 2017-02-28  Martin Liska  <mliska@suse.cz>
33081         PR lto/79625
33082         * read-rtl-function.c (function_reader::handle_unknown_directive):
33083         Bail out when one uses -flto.
33085 2017-02-28  Martin Liska  <mliska@suse.cz>
33087         * common.opt: Replace space with tabular for options of <number>
33088         type.
33089         * config/i386/i386.opt: Show <number> value for
33090         -mlarge-data-threshold.
33091         * opts.c (print_filtered_help): Do not display number in hexadecimal
33092         format.
33094 2017-02-28  Martin Liska  <mliska@suse.cz>
33096         * common.opt: Fix --help=option -Q for options which are of
33097         an enum type.
33099 2017-02-28  Uros Bizjak  <ubizjak@gmail.com>
33101         * config/i386/i386.c (print_reg): Error out for values
33102         of 8-bit size in invalid integer register.
33104 2017-02-28  Martin Sebor  <msebor@redhat.com>
33106         PR tree-optimization/79691
33107         * passes.def (pass_all_optimizations_g): Enable pass_sprintf_length.
33109 2017-02-28  Jakub Jelinek  <jakub@redhat.com>
33111         PR target/79729
33112         * config/i386/i386.c (ix86_print_operand) <case 'R'>: Replace
33113         gcc_unreachable with output_operand_lossage.
33115 2017-02-28  Richard Biener  <rguenther@suse.de>
33117         PR tree-optimization/79740
33118         * tree-ssa-sccvn.c (vn_nary_op_insert_into): Allow redundant
33119         inserts.
33120         (visit_nary_op): Insert the nary into the hashtable if we
33121         pattern-matched sth.
33122         * tree-ssa-pre.c (eliminate_insert): Robustify.
33124 2017-02-28  Richard Biener  <rguenther@suse.de>
33126         PR middle-end/79731
33127         * fold-const.c (decode_field_reference): Reject out-of-bound
33128         accesses.
33130 2017-02-28  Jakub Jelinek  <jakub@redhat.com>
33132         * config/i386/i386.c: Include intl.h.
33133         (ix86_option_override_internal): Use cond ? G_("...") : G_("...")
33134         instead of just cond ? "..." : "...".
33135         * config/nvptx/nvptx.c (nvptx_goacc_validate_dims): Likewise.
33136         * coverage.c (read_counts_file): Likewise.
33137         * omp-offload.c: Include intl.h.
33138         (oacc_loop_fixed_partitions): Use cond ? G_("...") : G_("...") instead
33139         of just cond ? "..." : "...".
33140         * gcov.c (read_count_file): Use cond ? N_("...") : N_("...") instead
33141         of just cond ? "..." : "...".
33143 2017-02-28  Richard Earnshaw  <rearnsha@arm.com>
33145         PR target/79742
33146         * config/arm/parsecpu.awk (gen_data): Set tuning target to 'tune for'
33147         entry, if present.
33148         * config/arm/arm-cpus.in (cortex-m0plus.small-multiply): Correct
33149         'tune for' CPU name.
33150         * config/arm/arm-cpu-data.h: Regenerated.
33152 2017-02-28  Richard Biener  <rguenther@suse.de>
33154         PR tree-optimization/79732
33155         * tree-inline.c (expand_call_inline): Do not shadow var.
33157 2017-02-28  Richard Biener  <rguenther@suse.de>
33159         PR tree-optimization/79723
33160         * tree-vect-stmts.c (get_vectype_for_scalar_type_and_size): Preserve
33161         address-space properly.
33163 2017-02-28  Thomas Schwinge  <thomas@codesourcery.com>
33165         * doc/optinfo.texi (Optimization groups): Fix option used for
33166         OPTGROUP_ALL.
33167         * doc/invoke.texi (-fopt-info): Document "omp".
33168         * dumpfile.h: Sort OPTGROUP_OMP before OPTGROUP_VEC.
33169         (OPTGROUP_ALL): Add OPTGROUP_OMP.
33170         * hsa-gen.c (pass_data_gen_hsail): Use OPTGROUP_OMP.
33171         * ipa-hsa.c (pass_data_ipa_hsa): Likewise.
33172         * omp-simd-clone.c (pass_data_omp_simd_clone): Likewise.
33174         * dumpfile.h (OPTGROUP_OPENMP): Rename to OPTGROUP_OMP.  Adjust
33175         all users.
33176         * dumpfile.c (optgroup_options): Instead of "openmp", associate
33177         OPTGROUP_OMP with "omp".
33179 2017-02-27  Pat Haugen  <pthaugen@us.ibm.com>
33181         PR target/79544
33182         * config/rs6000/rs6000-c.c (struct altivec_builtin_types): Use VSRAD
33183         for arithmetic shift of unsigned V2DI.
33185 2017-02-27  Claudiu Zissulescu  <claziss@synopsys.com>
33187         * config.gcc (arc*-): Clean up, use arc/big.h, arc/elf.h, and
33188         arc/linux.h headers.
33189         * config/arc/arc.h (TARGET_OS_CPP_BUILTINS): Remove.
33190         (LINK_SPEC): Likewise.
33191         (ARC_TLS_EXTRA_START_SPEC): Likewise.
33192         (EXTRA_SPECS): Likewise.
33193         (STARTFILE_SPEC): Likewise.
33194         (ENDFILE_SPEC): Likewise.
33195         (LIB_SPEC): Likewise.
33196         (TARGET_SDATA_DEFAULT): Likewise.
33197         (TARGET_MMEDIUM_CALLS_DEFAULT): Likewise.
33198         (MULTILIB_DEFAULTS): Likewise.
33199         (DWARF2_UNWIND_INFO): Likewise.
33200         * config/arc/big.h: New file.
33201         * config/arc/elf.h: Likewise.
33202         * config/arc/linux.h: Likewise.
33203         * config/arc/t-uClibc: Remove.
33205 2017-02-27  Bin Cheng  <bin.cheng@arm.com>
33207         PR tree-optimization/77536
33208         * tree-ssa-loop-manip.c (niter_for_unrolled_loop): New function.
33209         (tree_transform_and_unroll_loop): Use above function to compute the
33210         estimated niter of unrolled loop and use it when scaling profile.
33211         Also use count info rather than frequency if it's non-zero.
33212         * tree-ssa-loop-manip.h niter_for_unrolled_loop(): New declaration.
33213         * tree-vect-loop.c (scale_profile_for_vect_loop): New function.
33214         (vect_transform_loop): Call above function.
33216 2017-02-27  Richard Biener  <rguenther@suse.de>
33218         PR tree-optimization/45397
33219         * tree-ssa-pre.c (eliminate_insert): Handle BIT_AND_EXPR.
33220         * tree-ssa-sccvn.c (valueized_wider_op): New helper.
33221         (visit_nary_op): Add pattern matching for CSEing sign-changed
33222         or truncated operations with wider ones.
33224 2017-02-27  Richard Biener  <rguenther@suse.de>
33226         PR tree-optimization/79690
33227         * tree-vect-stmts.c (vectorizable_store): Use vector type
33228         built from the DR with address-space.
33230 2017-02-26  Gerald Pfeifer  <gerald@pfeifer.com>
33232         * doc/invoke.texi (Optimize Options): Refine the description
33233         of asan-use-after-return.
33235 2017-02-25  Alan Modra  <amodra@gmail.com>
33237         PR rtl-optimization/79584
33238         * lra-constraints.c (base_to_reg): Reload ad->base, the entire
33239         base, not ad->base_term, the reg within base.  Remove assertion
33240         that ad->base == ad->base_term.  Replace gen_int_mode using
33241         bogus mode with const0_rtx.
33243 2017-02-25  Jakub Jelinek  <jakub@redhat.com>
33245         PR middle-end/79396
33246         * tree-eh.c (operation_could_trap_p, stmt_could_throw_1_p): Handle
33247         FMA_EXPR like tcc_binary or tcc_unary.
33249         * tree-ssa-loop-niter.c (number_of_iterations_exit): Simplify warning.
33251         PR debug/77589
33252         * dwarf2out.c (struct dw_loc_list_struct): Add noted_variable_value
33253         bitfield.
33254         (size_of_loc_descr): Handle DW_OP_GNU_variable_value.
33255         (output_loc_operands): Handle DW_OP_call_ref and
33256         DW_OP_GNU_variable_value.
33257         (struct variable_value_struct): New type.
33258         (struct variable_value_hasher): Likewise.
33259         (variable_value_hash): New variable.
33260         (string_types): Remove.
33261         (copy_loc_descr): New function.
33262         (add_loc_descr_to_each): Clarify comment.  Use copy_loc_descr.
33263         (prepend_loc_descr_to_each): New function.
33264         (add_loc_list): Fix comment typo.  Use prepend_loc_descr_to_each
33265         instead of add_loc_descr_to_each if the first argument is single
33266         location list and the second has multiple.
33267         (resolve_args_picking_1): Handle DW_OP_GNU_variable_value.
33268         (loc_list_from_tree_1): For early_dwarf, emit DW_OP_GNU_variable_value
33269         when looking for variable value which doesn't have other location info.
33270         (loc_list_from_tree): Formatting fix.
33271         (gen_array_type_die): Simplify DW_AT_string_length handling.
33272         (adjust_string_types): Remove.
33273         (gen_subprogram_die): Don't call adjust_string_types nor test/set
33274         string_types.  Call resolve_variable_values.
33275         (prune_unused_types_walk_loc_descr): Handle DW_OP_GNU_variable_value.
33276         (resolve_addr_in_expr): Likewise.  Add A argument.
33277         (copy_deref_exprloc): Remove deref argument.  Adjust for the
33278         original expression being DW_OP_GNU_variable_value with optionally
33279         DW_OP_stack_value after it instead of DW_OP_call4 with DW_OP_deref
33280         optionally after it.
33281         (optimize_string_length): Rework for DW_OP_GNU_variable_value.
33282         (resolve_addr): Adjust optimize_string_length and resolve_addr_in_expr
33283         callers.  Set remove_AT_byte_size if removing DW_AT_string_length.
33284         (variable_value_hasher::hash, variable_value_hasher::equal): New
33285         methods.
33286         (resolve_variable_value_in_expr, resolve_variable_value,
33287         resolve_variable_values, note_variable_value_in_expr,
33288         note_variable_value): New functions.
33289         (dwarf2out_early_finish): Call note_variable_value on all toplevel
33290         DIEs.
33292 2017-02-24  Jakub Jelinek  <jakub@redhat.com>
33294         PR c/79677
33295         * opts.h (handle_generated_option): Add GENERATED_P argument.
33296         * opts-common.c (handle_option): Adjust function comment.
33297         (handle_generated_option): Add GENERATED_P argument, pass it to
33298         handle_option.
33299         (control_warning_option): Pass false to handle_generated_option
33300         GENERATED_P.
33301         * opts.c (maybe_default_option): Pass true to handle_generated_option
33302         GENERATED_P.
33303         * optc-gen.awk: Likewise.
33305 2017-02-24  Segher Boessenkool  <segher@kernel.crashing.org>
33307         * config/sh/sh.md (tstsi_t): If operands[0] is a SUBREG instead of
33308         a REG, look at the REG it is a SUBREG of.
33309         (splitter for cmpeqsi_t): Ditto.
33311 2017-02-24  Segher Boessenkool  <segher@kernel.crashing.org>
33313         * config/pa/pa.c (pa_combine_instructions): Do not share RTL.  Make
33314         the special USEs with the pattern of the insn, not the insn itself.
33316 2017-02-24  Matthew Fortune  <matthew.fortune@imgtec.com>
33318         PR target/79473
33319         * doc/invoke.texi: Document -mload-store-pairs.
33321 2017-02-24  Segher Boessenkool  <segher@kernel.crashing.org>
33322             Sandra Loosemore  <sandra@codesourcery.com>
33324         * config/nios2/nios2.c (nios2_simple_const_p): Returns false if the
33325         argument isn't a CONST_INT.
33326         (nios2_alternate_compare_const): Assert op is a CONST_INT.
33327         (nios2_valid_compare_const_p): Assert op is a CONST_INT.
33328         (nios2_validate_compare): Bypass alternate compare logic if *op2
33329         is not a CONST_INT.
33330         (ldstwm_operation_p): Return false if first_base is not a REG or
33331         if first_offset is not a CONST_INT.
33333 2017-02-24  Segher Boessenkool  <segher@kernel.crashing.org>
33335         * config/cris/cris.md: Use correct operand in a define_peephole2.
33337 2017-02-24  Segher Boessenkool  <segher@kernel.crashing.org>
33339         * config/c6x/c6x.c (predicate_insn): Do not incorrectly share RTL.
33341 2017-02-24  Segher Boessenkool  <segher@kernel.crashing.org>
33343         * config/arc/arc.c (arc_ccfsm_advance): Only take the PATTERN of
33344         this_insn if it is an INSN or JUMP_INSN.
33345         (force_offsettable): Look at base, not at addr.
33346         * config/arc/predicates.md (brcc_nolimm_operator): Don't call INTVAL
33347         on things that aren't necessarily CONST_INTs.
33349 2017-02-24  Uros Bizjak  <ubizjak@gmail.com>
33351         * doc/invoke.texi (x86 Options, -mfpmath=sse): Mention that
33352         -mfpmath=sse is the default also for x86-32 targets with SSE2
33353         instruction set when @option{-ffast-math} is enabled
33355 2017-02-24  Jeff Law  <law@redhat.com>
33357         PR rtl-optimizatoin/79286
33358         * ira.c (update_equiv_regs): Drop may_trap_p exception to
33359         dominance test.
33361 2017-02-24  Richard Biener  <rguenther@suse.de>
33363         PR tree-optimization/79389
33364         * gimple-ssa-split-paths.c (is_feasible_trace): Properly skip
33365         debug insns.
33367 2017-02-24  Aldy Hernandez  <aldyh@redhat.com>
33369         * tree-ssa-loop-niter.c (number_of_iterations_exit): Update
33370         function comment to reflect reality.
33371         (loop_exits_before_overflow): Fix typo in function description.
33373 2017-02-24  Richard Biener  <rguenther@suse.de>
33375         PR tree-optimization/79389
33376         * gimple-ssa-split-paths.c (is_feasible_trace): Verify more
33377         properly that a threading opportunity exists.  Detect conditional
33378         copy/constant propagation opportunities.
33380 2017-02-23  Eric Botcazou  <ebotcazou@adacore.com>
33382         * config/visium/visium.md (type): Add trap.
33383         (b): New mode attribute.
33384         (*btst): Rename into...
33385         (*btst<mode>): ...this and adjust.
33386         (*cbranchsi4_btst_insn): Rename into...
33387         (*cbranch<mode>4_btst_insn): ...this and adjust.
33388         (trap): New define_insn.
33390 2017-02-23  Jakub Jelinek  <jakub@redhat.com>
33392         PR tree-optimization/79389
33393         * ifcvt.c (struct noce_if_info): Add rev_cond field.
33394         (noce_reversed_cond_code): New function.
33395         (noce_emit_store_flag): Use rev_cond if non-NULL instead of
33396         reversed_comparison_code.  Formatting fix.
33397         (noce_try_store_flag): Test rev_cond != NULL in addition to
33398         reversed_comparison_code.
33399         (noce_try_store_flag_constants): Likewise.
33400         (noce_try_store_flag_mask): Likewise.
33401         (noce_try_addcc): Use rev_cond if non-NULL instead of
33402         reversed_comparison_code.
33403         (noce_try_cmove_arith): Likewise.  Formatting fixes.
33404         (noce_try_minmax, noce_try_abs): Clear rev_cond.
33405         (noce_find_if_block): Initialize rev_cond.
33406         (find_cond_trap): Call noce_get_condition with then_bb == trap_bb
33407         instead of false as last argument never attempt to reverse it
33408         afterwards.
33410 2017-02-23  Bin Cheng  <bin.cheng@arm.com>
33412         PR tree-optimization/79663
33413         * tree-predcom.c (combine_chains): Process refs in reverse order
33414         only for ZERO length chains, and add explaining comment.
33416 2017-02-23  Jeff Law  <law@redhat.com>
33418         PR tree-optimization/79578
33419         * tree-ssa-dse.c (clear_bytes_written_by): Use OEP_ADDRESS_OF
33420         in call to operand_equal_p.
33422 2017-01-23  Dominique d'Humieres  <dominiq@lps.ens.fr>
33424         PR target/71017
33425         * config/i386/cpuid.h: Fix another undefined behavior.
33427 2017-02-23  Richard Biener  <rguenther@suse.de>
33429         PR tree-optimization/79683
33430         * tree-vect-stmts.c (vect_analyze_stmt): Do not overwrite
33431         vector types for data-refs.
33433 2017-02-23  Martin Liska  <mliska@suse.cz>
33435         * params.def (PARAM_MIN_NONDEBUG_INSN_UID): Change default to 0.
33437 2017-02-23  Jakub Jelinek  <jakub@redhat.com>
33439         PR middle-end/79665
33440         * internal-fn.c (get_range_pos_neg): Moved to ...
33441         * tree.c (get_range_pos_neg): ... here.  No longer static.
33442         * tree.h (get_range_pos_neg): New prototype.
33443         * expr.c (expand_expr_real_2) <case TRUNC_DIV_EXPR>: If both arguments
33444         are known to be in between 0 and signed maximum inclusive, try to
33445         expand both unsigned and signed divmod and use the cheaper one from
33446         those.
33448 2017-02-22  Jeff Law  <law@redhat.com>
33450         PR tree-optimization/79578
33451         * tree-ssa-dse.c (clear_bytes_written_by): Use operand_equal_p
33452         to compare base operands.
33454 2017-02-22  Segher Boessenkool  <segher@kernel.crashing.org>
33456         PR target/79211
33457         * config/rs6000/rs6000.md (*fsel<SFDF:mode><SFDF2:mode>4): Use
33458         gpc_reg_operand instead of fpr_reg_operand.
33460 2017-02-22  Sameera Deshpande  <sameera.deshpande@imgtec.com>
33462         * config/mips/mips.c (mips_return_in_memory): Force FP
33463         vector types to be returned in memory for o32 ABI.
33465 2017-02-22  Jakub Jelinek  <jakub@redhat.com>
33467         * dwarf2out.c (gen_variable_die): For -gdwarf-5, use DW_TAG_variable
33468         instead of DW_TAG_member for static data member declarations and don't
33469         set no_linkage_name for static inline data members.
33470         (gen_member_die): For -gdwarf-5 don't change DW_TAG_variable
33471         to DW_TAG_member.
33473 2017-02-22  Martin Liska  <mliska@suse.cz>
33475         * doc/invoke.texi: Replace inequality signs with square brackets
33476         for -Wnormalized.
33478 2017-02-22  Matthew Fortune  <matthew.fortune@imgtec.com>
33480         PR target/78660
33481         * lra-constraints.c (simplify_operand_subreg): Handle
33482         WORD_REGISTER_OPERATIONS targets.
33484 2017-02-22  Jakub Jelinek  <jakub@redhat.com>
33486         PR target/70465
33487         * reg-stack.c (emit_swap_insn): Treat (float_extend:?F (mem:?F))
33488         and (const_double:?F) like (mem:?F) for the purpose of fxch %st(1)
33489         elimination by swapping fld*.
33491 2017-02-22  Richard Biener  <rguenther@suse.de>
33493         PR tree-optimization/79673
33494         * tree-ssa-pre.c (compute_avail): Use wide_int_to_tree to
33495         convert the [TARGET_]MEM_REF offset INTEGER_CST, scrapping off
33496         irrelevant address-space qualifiers and avoiding a
33497         ADDR_SPACE_CONVERT_EXPR from fold_convert.
33499 2017-02-22  Richard Biener  <rguenther@suse.de>
33501         PR tree-optimization/79666
33502         * tree-vrp.c (extract_range_from_binary_expr_1): Make sure
33503         to not symbolically negate if that may introduce undefined
33504         overflow.
33506 2017-02-22  Martin Liska  <mliska@suse.cz>
33508         PR lto/79587
33509         * data-streamer-in.c (streamer_read_gcov_count): Remove assert.
33510         * data-streamer-out.c (streamer_write_gcov_count_stream):
33511         Likewise.
33512         * value-prof.c (stream_out_histogram_value): Make assert more
33513         precise based on type of counter.
33515 2017-02-21  Uros Bizjak  <ubizjak@gmail.com>
33517         PR target/79593
33518         * config/i386/i386.md (standard_x87sse_constant_load splitter):
33519         Use nonimmediate_operand instead of memory_operand for operand 1.
33520         (float-extend standard_x87sse_constant_load splitter): Ditto.
33522 2017-02-21  Jeff Law  <law@redhat.com>
33524         PR tree-optimization/79621
33525         * gimple-ssa-isolate-paths.c (find_implicit_erroneous_behavior): Ignore
33526         blocks with edges to themselves.
33528 2017-02-21  Jakub Jelinek  <jakub@redhat.com>
33530         PR target/79633
33531         * tree-chkp-opt.c (chkp_optimize_string_function_calls): Use
33532         is_gimple_call instead of comparing gimple_code with GIMPLE_CALL.
33533         Use gimple_call_builtin_p.
33535         PR target/79570
33536         * sel-sched.c (moveup_expr_cached): Don't call sel_bb_head
33537         on temporarily removed DEBUG_INSNs.
33539         PR tree-optimization/79649
33540         * tree-loop-distribution.c (classify_partition): Give up on
33541         non-generic address space loads/stores.
33543 2017-02-21  Aldy Hernandez  <aldyh@redhat.com>
33545         * doc/loop.texi (Loop manipulation): Remove nonexistent
33546         tree_ssa_loop_version from the documentation.
33547         * cfgloopmanip.c (loop_version): Document CONDITION_BB argument.
33549 2017-02-21  Jakub Jelinek  <jakub@redhat.com>
33551         PR target/79494
33552         * config/i386/i386.c (ix86_expand_split_stack_prologue): Call
33553         make_reg_eh_region_note_nothrow_nononlocal on call_insn.
33554         * config/rs6000/rs6000.c: Include except.h.
33555         (rs6000_expand_split_stack_prologue): Call
33556         make_reg_eh_region_note_nothrow_nononlocal on the call insn.
33558 2017-02-21  Martin Jambor  <mjambor@suse.cz>
33560         PR lto/79579
33561         * ipa-prop.c (ipa_prop_write_jump_functions): Bail out if no edges
33562         have been analyzed.
33564 2017-02-21  Martin Jambor  <mjambor@suse.cz>
33566         * common.opt (-fipa-cp-alignment): Mark as ignored and preserved
33567         for backward compatibility only.
33568         * doc/invoke.texi (Option Summary): Remove all references to
33569         -fipa-cp-alignment.
33571 2017-02-21  Matthew Fortune  <matthew.fortune@imgtec.com>
33573         PR target/78660
33574         Revert:
33575         2017-02-20  Matthew Fortune  <matthew.fortune@imgtec.com>
33577         * lra-constraints.c (curr_insn_transform): Handle
33578         WORD_REGISTER_OPERATIONS requirements when reloading SUBREGs.
33580 2017-02-21  Martin Liska  <mliska@suse.cz>
33582         * config/i386/i386.opt: Replace -masm-dialect with -masm.
33584 2017-02-21  Thomas Schwinge  <thomas@codesourcery.com>
33586         PR translation/79638
33587         * config/nvptx/nvptx.c (ENTRY_TEMPLATE): Single out "%ntid.y".
33589 2017-02-21  Eric Botcazou  <ebotcazou@adacore.com>
33591         PR ada/67205
33592         * config/arm/arm.c (TARGET_CUSTOM_FUNCTION_DESCRIPTORS): Define.
33593         (arm_function_ok_for_sibcall): Return false for an indirect call by
33594         descriptor if all the argument registers are used.
33595         (arm_relayout_function): Use FUNCTION_ALIGNMENT macro to adjust the
33596         alignment of the function.
33598 2017-02-21  Jakub Jelinek  <jakub@redhat.com>
33600         PR tree-optimization/61441
33601         * simplify-rtx.c (simplify_const_unary_operation): For
33602         -fsignaling-nans and sNaN operand, return NULL_RTX rather than
33603         the sNaN unmodified.
33605 2017-02-20  Bernd Edlinger  <bernd.edlinger@hotmail.de>
33607         * Makefile.in (BUILD_SYSTEM_HEADER_DIR): New make variabe.
33608         (LIMITS_H_TEST, if_multiarch, stmp-fixinc): Use BUILD_SYSTEM_HEADER_DIR
33609         instead of SYSTEM_HEADER_DIR.
33611 2017-02-20  Gerald Pfeifer  <gerald@pfeifer.com>
33612             Martin LiÅ¡ka  <mliska@suse.cz>
33614         * doc/invoke.texi (use-after-scope-direct-emission-threshold):
33615         Fix typos and grammar, use active voice, and clarify.
33617 2017-02-20  Marek Polacek  <polacek@redhat.com>
33619         PR middle-end/79537
33620         * gimplify.c (gimplify_expr): Handle unused *&&L;.
33622         PR sanitizer/79558
33623         * ubsan.c (ubsan_type_descriptor): Check if TYPE_MAX_VALUE is null.
33625 2017-02-20  Jakub Jelinek  <jakub@redhat.com>
33627         PR target/79568
33628         * config/i386/i386.c (ix86_expand_builtin): Handle
33629         OPTION_MASK_ISA_AVX512VL and OPTION_MASK_ISA_64BIT in
33630         ix86_builtins_isa[fcode].isa as a requirement of those
33631         flags and any other flag in the bitmask.
33632         (ix86_init_mmx_sse_builtins): Use 0 instead of
33633         ~OPTION_MASK_ISA_64BIT as mask.
33634         * config/i386/i386-builtin.def (__builtin_ia32_rdtsc,
33635         __builtin_ia32_rdtscp, __builtin_ia32_pause, __builtin_ia32_bsrsi,
33636         __builtin_ia32_rdpmc, __builtin_ia32_rolqi, __builtin_ia32_rolhi,
33637         __builtin_ia32_rorqi, __builtin_ia32_rorhi): Likewise.
33639 2017-02-20  Matthew Fortune  <matthew.fortune@imgtec.com>
33641         PR target/78012
33642         * lra-constraints.c (split_reg): Check requested split mode
33643         is supported by the register.
33645 2017-02-20  Matthew Fortune  <matthew.fortune@imgtec.com>
33647         * lra-constraints.c (simplify_operand_subreg): Remove early
33648         return false.
33650 2017-02-20  Matthew Fortune  <matthew.fortune@imgtec.com>
33652         PR target/78660
33653         * lra-constraints.c (curr_insn_transform): Tighten condition
33654         for converting SUBREG reloads from OP_OUT to OP_INOUT.
33656 2017-02-20  Matthew Fortune  <matthew.fortune@imgtec.com>
33658         PR target/78660
33659         * lra-constraints.c (curr_insn_transform): Handle
33660         WORD_REGISTER_OPERATIONS requirements when reloading SUBREGs.
33662 2017-02-19  Uros Bizjak  <ubizjak@gmail.com>
33664         Revert:
33665         2016-05-30  Uros Bizjak  <ubizjak@gmail.com>
33667         * config/i386/sync.md (mfence_nosse): Use "lock orl $0, -4(%esp)".
33669 2017-02-19  Jonathan Wakely  <jwakely@redhat.com>
33671         PR c++/69523
33672         * doc/invoke.texi (C++ Dialect Options) [-Wliteral-suffix]: Update
33673         description.
33675 2017-02-19  Prathamesh Kulkarni  <prathamesh.kulkarni@linaro.org>
33677         * gimple-pretty-print.c (dump_ternary_rhs): Adjust gimple dump format
33678         for FMA_EXPR.
33680 2017-02-18  Jakub Jelinek  <jakub@redhat.com>
33682         * final.c (last_columnnum, override_columnnum): New variables.
33683         (final_start_function): Set last_columnnum, pass it to begin_prologue
33684         hook and pass 0 to dwarf2out_begin_prologue.
33685         (final_scan_insn): Update override_columnnum.  Pass last_columnnum
33686         to source_line debug hook.
33687         (notice_source_line): Compute last_columnnum and for debug_column_info
33688         return true on column changes.
33689         * debug.h (struct gcc_debug_hooks): Add column argument to
33690         source_line and begin_prologue hooks.
33691         (debug_nothing_int_charstar_int_bool): Remove prototype.
33692         (debug_nothing_int_int_charstar,
33693         debug_nothing_int_int_charstar_int_bool): New prototypes.
33694         (dwarf2out_begin_prologue): Add column argument.
33695         * debug.c (do_nothing_debug_hooks): Adjust source_line and
33696         begin_prologue hooks.
33697         (debug_nothing_int_charstar_int_bool): Remove.
33698         (debug_nothing_int_int_charstar,
33699         debug_nothing_int_int_charstar_int_bool): New functions.
33700         * dwarf2out.c (dwarf2out_begin_prologue): Add column argument, pass it
33701         through to dwarf2out_source_line.
33702         (dwarf2_lineno_debug_hooks): Adjust begin_prologue hook.
33703         (dwarf2out_source_line): Add column argument, emit it if requested.
33704         * sdbout.c (sdbout_source_line, sdbout_begin_prologue): Add column
33705         arguments.
33706         * xcoffout.h (xcoffout_begin_prologue, xcoffout_source_line): Likewise.
33707         * xcoffout.c (xcoffout_begin_prologue, xcoffout_source_line): Likewise.
33708         * vmsdbgout.c (vmsdbgout_begin_prologue): Add column argument, pass it
33709         through to dwarf2out_begin_prologue.
33710         (vmsdbgout_source_line): Add column argument, pass it through to
33711         dwarf2out_source_line.
33712         * dbxout.c (dbxout_begin_prologue): Add column argument, adjust
33713         dbxout_source_line caller.
33714         (dbxout_source_line): Add column argument.
33716         * common.opt (gno-column-info, gcolumn-info): New options.
33717         * dwarf2out.c (dwarf2_lineno_debug_hooks): Formatting fix.
33718         (check_die): Also test for multiple DW_AT_decl_column attributes.
33719         (add_src_coords_attributes, dwarf2out_imported_module_or_decl_1): Add
33720         DW_AT_decl_column if requested.
33721         (gen_subprogram_die): Compare and/or add also DW_AT_decl_column
33722         if requested.
33723         (gen_variable_die): Likewise.
33724         (add_call_src_coords_attributes): Add DW_AT_call_column if requested.
33725         * doc/invoke.texi (-gcolumn-info, -gno-column-info): Document.
33727         PR target/79569
33728         * config/i386/i386.opt (m3dnowa): Replace Undocumented with Report.
33729         * common/config/i386/i386-common.c (OPTION_MASK_ISA_3DNOW_A_SET): Define.
33730         (ix86_handle_option): Handle OPT_m3dnowa.
33731         * doc/invoke.texi (-m3dnowa): Document.
33732         * doc/extend.texi (__builtin_ia32_pmulhuw, __builtin_ia32_pf2iw): Use
33733         -m3dnowa instead of -m3dnow -march=athlon.
33735         PR target/79559
33736         * config/i386/i386.c (ix86_print_operand): Use output_operand_lossage
33737         instead of gcc_assert for K, r and R code checks.  Formatting fixes.
33739 2017-02-17  Bill Schmidt  <wschmidt@linux.vnet.ibm.com>
33741         PR target/79261
33742         * config/rs6000/rs6000.c (rs6000_expand_ternop_builtin): Add
33743         support for CODE_FOR_vsx_xxpermdi_v2d[fi]_be.
33744         * config/rs6000/rs6000.md (reload_gpr_from_vsx<mode>): Call
33745         generator for vsx_xxpermdi_<mode>_be.
33746         * config/rs6000/vsx.md (vsx_xxpermdi_<mode>): Remove logic to
33747         force big-endian semantics.
33748         (vsx_xxpermdi_<mode>_be): New define_expand with same
33749         implementation as previous version of vsx_xxpermdi_<mode>.
33751 2017-02-17  Jakub Jelinek  <jakub@redhat.com>
33753         PR tree-optimization/79327
33754         * gimple-ssa-sprintf.c (format_integer): Remove likely_adjust
33755         variable, its initialization and use.
33757 2017-02-17  Julia Koval  <julia.koval@intel.com>
33759         * common/config/i386/i386-common.c (OPTION_MASK_ISA_RDPID_SET): New.
33760         (OPTION_MASK_ISA_PKU_UNSET): New.
33761         (ix86_handle_option): Handle -mrdpid.
33762         * config/i386/cpuid.h (bit_RDPID): New.
33763         * config/i386/driver-i386.c (host_detect_local_cpu):
33764         Detect RDPID feature.
33765         * config/i386/i386-builtin.def (__builtin_ia32_rdpid): New.
33766         * config/i386/i386-c.c (ix86_target_macros_internal):
33767         Handle RDPID flag.
33768         * config/i386/i386.c (ix86_target_string): Add -mrdpid to isa2_opts.
33769         (ix86_valid_target_attribute_inner_p): Add "rdpid".
33770         (ix86_expand_builtin): Handle IX86_BUILTIN_RDPID.
33771         * config/i386/i386.h (TARGET_RDPID, TARGET_RDPID_P): New.
33772         * config/i386/i386.md (define_insn "rdpid"): New.
33773         * config/i386/i386.opt Add -mrdpid.
33774         * config/i386/immintrin.h (_rdpid_u32): New.
33776 2017-02-17  Vladimir Makarov  <vmakarov@redhat.com>
33778         PR rtl-optimization/79541
33779         * lra-constraints.c (curr_insn_transform): Remove wrong asm insn
33780         instead of transforming it into USE.
33782 2017-02-17  Segher Boessenkool  <segher@kernel.crashing.org>
33784         * config/rs6000/rs6000.md (extendsfdf2): Remove default arguments.
33785         If HONOR_SNANS (SFmode) force the input to a register.
33786         (*extendsfdf2_fpr): Add !HONOR_SNANS (SFmode) condition.
33787         (*extendsfdf2_snan): New pattern, used when using SNaNs; it generates
33788         an frsp or similar insn.
33790 2017-02-17  Martin Liska  <mliska@suse.cz>
33792         PR rtl-optimization/79577
33793         * params.def (selsched-max-sched-times): Increase minimum to 1.
33795 2017-02-17  Martin Liska  <mliska@suse.cz>
33797         PR rtl-optimization/79574
33798         * gcse.c (want_to_gcse_p): Prevent integer overflow.
33800 2017-02-17  Martin Liska  <mliska@suse.cz>
33802         PR tree-optimization/79529
33803         * tree-ssa-loop-unswitch.c (is_maybe_undefined): Use
33804         ssa_defined_default_def_p to handle cases which are implicitly
33805         defined.
33806         * tree-ssa.c (ssa_defined_default_def_p): New function.
33807         (ssa_undefined_value_p): Use ssa_defined_default_def_p to handle cases
33808         which are implicitly defined.
33809         * tree-ssa.h (ssa_defined_default_def_p): Declare.
33811 2017-02-17  Richard Biener  <rguenther@suse.de>
33813         PR middle-end/79576
33814         * params.def (max-ssa-name-query-depth): Limit to 10.
33816 2017-02-17  Richard Biener  <rguenther@suse.de>
33818         PR tree-optimization/79552
33819         * tree-ssa-structalias.c (visit_loadstore): Properly verify
33820         default defs.
33822 2017-02-17  Richard Biener  <rguenther@suse.de>
33824         PR bootstrap/79567
33825         * genmatch.c (output_line_directive): Handle DIR_SEPARATOR_2.
33827 2017-02-17  Marek Polacek  <polacek@redhat.com>
33829         PR middle-end/79536
33830         * fold-const.c (fold_negate_expr_1): Renamed from fold_negate_expr.
33831         (fold_negate_expr): New wrapper.
33833 2017-02-16  Sandra Loosemore  <sandra@codesourcery.com>
33835         * doc/invoke.texi (C++ Dialect Options) [-Wno-non-template-friend]: 
33836         Correct terminology and de-emphasize pre-standard behavior.
33838 2017-02-16  Alan Modra  <amodra@gmail.com>
33840         PR rtl-optimization/79286
33841         * ira.c (def_dominates_uses): New function.
33842         (update_equiv_regs): Don't create an equivalence for insns that
33843         may trap where the register def does not dominate the use.
33845 2017-02-16  Vladimir Makarov  <vmakarov@redhat.com>
33847         PR rtl-optimization/78127
33848         * lra.c (lra): Call lra_eliminate before finish the loop after
33849         lra_constraint.
33851 2017-02-16  Richard Biener  <rguenther@suse.de>
33853         * graphite.h: Do not include isl/isl_val_gmp.h, instead include
33854         isl/isl_val.h.
33855         * graphite-isl-ast-to-gimple.c (gmp_cst_to_tree): Remove.
33856         (gcc_expression_from_isl_expr_int): Use generic isl_val interface.
33857         * graphite-sese-to-poly.c: Do not include isl/isl_val_gmp.h.
33858         (isl_val_int_from_wi): New function.
33859         (extract_affine_gmp): Rename to ...
33860         (extract_affine_wi): ... this, take a widest_int.
33861         (extract_affine_int): Just wrap extract_affine_wi.
33862         (add_param_constraints): Use isl_val_int_from_wi.
33863         (add_loop_constraints): Likewise, and extract_affine_wi.
33865 2017-02-15  Jeff Law  <law@redhat.com>
33867         PR middle-end/79521
33868         * ira-costs.c (scan_one_insn): Check have_regs_of_mode before calling
33869         ira_init_register_move_cost_if_necessary.
33871 2017-02-15  Martin Sebor  <msebor@redhat.com>
33873         PR middle-end/32003
33874         * doc/invoke.texi (-fdump-final-insns): Replace option accidentally
33875         removed in a prior commit.
33877 2017-02-15  Bin Cheng  <bin.cheng@arm.com>
33879         PR tree-optimization/79347
33880         * tree-vect-loop-manip.c (vect_do_peeling): Maintain profile
33881         counters during peeling.
33883 2017-02-15  Thomas Schwinge  <thomas@codesourcery.com>
33885         * Makefile.in (site.exp): Remove "set ISLVER".
33887 2017-02-15  Jakub Jelinek  <jakub@redhat.com>
33889         PR target/79487
33890         * real.c (real_from_integer): Call real_convert even for decimal.
33892 2017-02-15  Dominik Vogt  <vogt@linux.vnet.ibm.com>
33894         PR target/79421
33895         * config/s390/s390.c: define TARGET_CUSTOM_FUNCTION_DESCRIPTORS.
33897 2017-02-14  Andrew Pinski  <apinski@cavium.com>
33899         * config/aarch64/aarch64-cores.def (thunderx2t99): Move to under 'C"
33900         cores and change the partno/implementer to be correct.
33901         (thunderx2t99p1): New core which replaces thunderx2t99 and still has
33902         the 'B" as the implementer.
33903         * config/aarch64/aarch64-tune.md: Regenerate.
33905 2017-02-14  Carl Love  <cel@us.ibm.com>
33907         * config/rs6000/rs6000.c: Add case statement entry to make the
33908         xvcvuxdsp built-in argument unsigned.
33909         * config/rs6000/vsx.md: Fix the source and return operand types so they
33910         match the instruction definitions from the ISA document.  Fix typo
33911         in the instruction generation for the (define_insn "vsx_xvcvuxdsp"
33912         statement.
33914 2017-02-14  Vladimir Makarov  <vmakarov@redhat.com>
33916         PR target/79282
33917         * lra-int.h (struct lra_operand_data, struct lra_insn_reg): Add
33918         member early_clobber_alts.
33919         * lra-lives.c (reg_early_clobber_p): New.
33920         (process_bb_lives): Use it.
33921         * lra.c (new_insn_reg): New arg early_clobber_alts.  Use it.
33922         (debug_operand_data): Initialize early_clobber_alts.
33923         (setup_operand_alternative): Set up early_clobber_alts.
33924         (collect_non_operand_hard_regs): Ditto.  Pass early clobber
33925         alternatives to new_insn_reg.
33926         (add_regs_to_insn_regno_info): Add arg early_clobber_alts.  Use
33927         it.
33928         (lra_update_insn_regno_info): Pass the new arg.
33930 2017-02-14  Jakub Jelinek  <jakub@redhat.com>
33932         PR middle-end/79505
33933         * omp-offload.c (free_oacc_loop): Release loop->ifns vector.
33934         (new_oacc_loop_raw): Don't clear already cleared fields.
33936         PR target/79481
33937         * config/i386/avx512pfintrin.h (_mm512_prefetch_i32gather_pd,
33938         _mm512_prefetch_i32gather_ps, _mm512_prefetch_i64gather_pd,
33939         _mm512_prefetch_i64gather_ps): New inline functions and macros.
33941 2017-02-14  Uros Bizjak  <ubizjak@gmail.com>
33943         PR target/79495
33944         * config/i386/i386.md (*movxf_internal): Add (o,rC) alternative.
33946 2017-02-14  H.J. Lu  <hongjiu.lu@intel.com>
33948         PR target/79498
33949         * config/i386/i386.c (timode_scalar_chain::convert_insn): Insert
33950         the extra instruction to the right place to store 128-bit constant
33951         when needed.
33953 2017-02-14  Martin Sebor  <msebor@redhat.com>
33955         PR middle-end/79448
33956         * gimple-ssa-sprintf.c (format_directive): Avoid issuing INT_MAX
33957           warning for strings of unknown length.
33959 2017-02-13  Segher Boessenkool  <segher@kernel.crashing.org>
33961         * config.gcc (supported_defaults) [powerpc*-*-*]: Update.
33963 2017-02-14  Jeff Law  <law@redhat.com>
33965         PR target/79404
33966         * ira-costs.c (scan_one_insn): Initialize register move costs
33967         for pseudos seen in USE/CLOBBER insns.
33969         PR tree-optimization/79095
33970         * tree-vrp.c (extract_range_from_binary_expr_1): For EXACT_DIV_EXPR,
33971         if the numerator has the range ~[0,0] make the resultant range ~[0,0].
33972         (extract_range_from_binary_expr): For MINUS_EXPR with no derived range,
33973         if the operands are known to be not equal, then the resulting range
33974         is ~[0,0].
33975         (intersect_ranges): If the new range is ~[0,0] and the old range is
33976         wide, then prefer ~[0,0].
33977         * tree-vrp.c (overflow_comparison_p_1): New function.
33978         (overflow_comparison_p): New function.
33979         * tree-vrp.c (register_edge_assert_for_2): Register additional asserts
33980         if NAME is used in an overflow test.
33981         (vrp_evaluate_conditional_warnv_with_ops): If the ops represent an
33982         overflow check that can be expressed as an equality test, then adjust
33983         ops to be that equality test.
33985 2017-02-14  Andreas Krebbel  <krebbel@linux.vnet.ibm.com>
33987         * config/s390/s390-builtin-types.def: Remove flags argument.
33988         * config/s390/s390.c (s390_init_builtins): Likewise.
33990 2017-02-14  Martin Liska  <mliska@suse.cz>
33992         * tree-ssa-loop-unswitch.c (hoist_guard): Release get_loop_body
33993         vector.  Fix trailing white spaces.
33995 2017-02-14  James Greenhalgh  <james.greenhalgh@arm.com>
33997         * config/aarch64/aarch64.c (aarch64_simd_container_mode): Handle
33998         HFmode.
34000 2017-02-14  Kyrylo Tkachov  <kyrylo.tkachov@arm.com>
34002         PR rtl-optimization/68664
34003         * config/arm/arm.c (arm_sched_can_speculate_insn):
34004         New function.  Declare prototype.
34005         (TARGET_SCHED_CAN_SPECULATE_INSN): Define.
34007 2017-02-14  Kyrylo Tkachov  <kyrylo.tkachov@arm.com>
34009         PR rtl-optimization/68664
34010         * config/aarch64/aarch64.c (aarch64_sched_can_speculate_insn):
34011         New function.
34012         (TARGET_SCHED_CAN_SPECULATE_INSN): Define.
34014 2017-02-14  Amit Pawar  <amit.pawar@amd.com>
34016         * config/i386/i386.c (znver1_cost): Fix the alignment for function and
34017         max skip bytes for function, loop and jump.
34019 2017-02-14  Prathamesh Kulkarni  <prathamesh.kulkarni@linaro.org>
34021         * gimple-pretty-print.c (dump_unary_rhs): Adjust dump format for
34022         ABS_EXPR for gimple dump.
34024 2017-02-14  Jakub Jelinek  <jakub@redhat.com>
34026         PR target/79462
34027         * config/sh/sh.c (expand_cbranchdi4): Don't clear operands[4].
34029         PR tree-optimization/79408
34030         * tree-vrp.c (simplify_div_or_mod_using_ranges): Handle also the
34031         case when on TRUNC_MOD_EXPR op0 is INTEGER_CST.
34032         (simplify_stmt_using_ranges): Call simplify_div_or_mod_using_ranges
34033         also if rhs1 is INTEGER_CST.
34035 2017-02-14  Richard Biener  <rguenther@suse.de>
34037         PR middle-end/79432
34038         * tree-into-ssa.c (insert_phi_nodes): When the function can
34039         have abnormal edges rewrite SSA names with broken use-def
34040         dominance out of SSA and register them for PHI insertion.
34042 2017-02-13  Martin Sebor  <msebor@redhat.com>
34044         PR middle-end/79496
34045         * gimple-ssa-sprintf.c (pass_sprintf_length::handle_gimple_call): Avoid
34046         clearing info.nowrite flag when snprintf size argument is a range.
34048 2017-02-13  Jakub Jelinek  <jakub@redhat.com>
34050         * cprop.c (cprop_jump): Add missing space in string literal.
34051         * tree-ssa-structalias.c (rewrite_constraints): Likewise.
34052         (get_constraint_for_component_ref): Likewise.
34053         * df-core.c (df_worklist_dataflow_doublequeue): Likewise.
34054         * tree-outof-ssa.c (insert_partition_copy_on_edge): Likewise.
34055         * lra-constraints.c (process_alt_operands): Likewise.
34056         * ipa-inline.c (inline_small_functions): Likewise.
34057         * tree-ssa-sccvn.c (visit_reference_op_store): Likewise.
34058         * cgraph.c (cgraph_edge::redirect_call_stmt_to_callee): Likewise.
34059         * trans-mem.c (diagnose_tm_1_op): Likewise.
34060         * omp-grid.c (grid_find_single_omp_among_assignments): Likewise.
34061         (grid_parallel_clauses_gridifiable): Likewise.
34063         * config/nvptx/mkoffload.c (process): Add space in between
34064         , and %d.
34066         * config/i386/i386.h (REG_CLASS_NAMES): Add , in between
34067         "MOD4_SSE_REGS" and "ALL_REGS".
34069         * spellcheck.c (test_data): Add , in between "foo" and "food".
34071 2017-02-13  Aaron Sawdey  <acsawdey@linux.vnet.ibm.com>
34073         PR target/79449
34074         * config/rs6000/rs6000.c (expand_block_compare): Make sure runtime
34075         boundary crossing check and subsequent code generation agree.
34077 2017-02-13  Kyrylo Tkachov  <kyrylo.tkachov@arm.com>
34079         * config/aarch64/aarch64.c (has_memory_op): Delete.
34080         (aarch64_madd_needs_nop): Use contains_mem_rtx_p instead of
34081         has_memory_op.
34083 2017-02-13  Jakub Jelinek  <jakub@redhat.com>
34085         PR rtl-optimization/79388
34086         PR rtl-optimization/79450
34087         * combine.c (distribute_notes): When removing TEM_INSN for which
34088         corresponding dest has last value recorded, invalidate that last
34089         value.
34091 2017-02-13  Kyrylo Tkachov  <kyrylo.tkachov@arm.com>
34093         * config/arm/arm.c (arm_print_tune_info): Use ASM_COMMENT_START instead
34094         of explicit '@'.  Add missing assembly comment marker on branch costs
34095         printout.
34097 2017-02-13  Nathan Sidwell  <nathan@acm.org>
34099         * gengtype-lex.l (<in_struct>): Add '/'.
34101 2017-02-13  Martin Liska  <mliska@suse.cz>
34103         PR c/79471
34104         * calls.c (expand_call): Replace XALLOCAVEC with XCNEWVEC.
34106 2017-02-13  Richard Biener  <rguenther@suse.de>
34108         * configure.ac (HAVE_ISL_OPTIONS_SET_SCHEDULE_SERIALIZE_SCCS):
34109         Remove.
34110         * configure: Re-generate.
34111         * config.in: Likewise.
34112         * graphite-dependences.c: Simplify as if
34113         HAVE_ISL_OPTIONS_SET_SCHEDULE_SERIALIZE_SCCS was defined.
34114         * graphite-isl-ast-to-gimple.c: Likewise.
34115         * graphite-optimize-isl.c: Likewise.
34116         * graphite-poly.c: Likewise.
34117         * graphite-sese-to-poly.c: Likewise.
34118         * graphite.h: Likewise.
34119         * toplev.c: Include isl/version.h and use isl_version () for
34120         printing the ISL version.
34121         * doc/install.texi: Update ISL requirement.
34123 2017-02-12  Gerald Pfeifer  <gerald@pfeifer.com>
34125         * doc/standards.texi (Standards): Update reference to
34126         Objective-C 2.0.
34128 2017-02-12  Gerald Pfeifer  <gerald@pfeifer.com>
34130         * doc/extend.texi (Named Address Spaces): sourceware.org now
34131         defaults to https.
34132         * doc/install.texi (Binaries): Ditto.
34133         (Specific): Ditto.
34135 2017-02-11  Sandra Loosemore  <sandra@codesourcery.com>
34137         * doc/cpp.texi: Replace "stringify"/"stringification" with C
34138         standard terminology "stringize"/"stringizing" throughout.
34139         * doc/cppinternals.texi: Likewise.
34141 2017-02-11  Sandra Loosemore  <sandra@codesourcery.com>
34143         * doc/extend.texi: Fix some spelling mistakes and typos.
34144         * doc/invoke.texi: Likewise.
34146 2017-02-11  Jan Hubicka  <hubicka@ucw.cz>
34148         PR ipa/79224
34149         * params.def (inline-min-speedup) Change from 10 to 8.
34151 2017-02-11  Jakub Jelinek  <jakub@redhat.com>
34153         * doc/invoke.texi (fopenmp): Bump OpenMP version from 4.0 to
34154         4.5.
34156 2017-02-11  Jan Hubicka  <hubicka@ucw.cz>
34158         PR ipa/79224
34159         * ipa-inline-analysis.c (get_minimal_bb): New function.
34160         (record_modified): Use it.
34161         (remap_edge_change_prob): Handle also ancestor functions.
34163 2017-02-11  Gerald Pfeifer  <gerald@pfeifer.com>
34165         * doc/contrib.texi (Contributors): Remove broken link into
34166         the Mauve CVS repository.
34168 2017-02-11  Jakub Jelinek  <jakub@redhat.com>
34170         PR middle-end/79454
34171         * internal-fn.c (expand_vector_ubsan_overflow): Use piece-wise
34172         result computation whenever lhs doesn't have vector mode, not
34173         just when it has BLKmode.
34175 2017-02-10  Gerald Pfeifer  <gerald@pfeifer.com>
34177         * doc/makefile.texi (profiledbootstrap): Refer to the
34178         installation instructions only in textual form.
34180 2017-02-10  Aaron Sawdey  <acsawdey@linux.vnet.ibm.com>
34182         PR target/79295
34183         * config/rs6000/altivec.md (bcd<bcd_add_sub>): Fix constraints.
34185 2017-02-10  Gerald Pfeifer  <gerald@pfeifer.com>
34187         * doc/install.texi (Specific): Use https for blackfin.uclinux.org.
34188         (Specific): Update mingw-w64 reference.
34189         (Binaries): Ditto.
34190         (Specific): Remove broken link to Renesas RX processor.
34192 2017-02-10  Richard Biener  <rguenther@suse.de>
34194         * toplev.c (process_options): Do not mention obsolete graphite
34195         options when printing sorry message about missing graphite support.
34196         Mention -floop-nest-optimize.
34198 2017-02-10  Christophe Lyon  <christophe.lyon@linaro.org>
34200         * config/aarch64/arm_neon.h (vtst_p8): Rewrite without asm.
34201         (vtst_p16): Likewise.
34202         (vtstq_p8): Likewise.
34203         (vtstq_p16): Likewise.
34204         (vtst_p64): New.
34205         (vtstq_p64): Likewise.
34206         * config/arm/arm_neon.h (vgetq_lane_p64): New.
34207         (vset_lane_p64): New.
34208         (vsetq_lane_p64): New.
34210 2017-02-10  Jakub Jelinek  <jakub@redhat.com>
34212         PR tree-optimization/79411
34213         * tree-ssa-reassoc.c (is_reassociable_op): Return false if
34214         stmt operands are SSA_NAMEs used in abnormal phis.
34215         (can_reassociate_p): Return false if op is SSA_NAME used in abnormal
34216         phis.
34218 2017-02-09  Jan Hubicka  <hubicka@ucw.cz>
34220         PR ipa/70795
34221         * cgraphunit.c (cgraph_node::add_new_function): Set externally_visible
34222         flag if needed.
34224 2017-02-09  Jan Hubicka  <hubicka@ucw.cz>
34226         * tree-ssa-loop-unswitch.c (hoist_guard): Update profile.
34228 2017-02-09  Jakub Jelinek  <jakub@redhat.com>
34230         * omp-offload.c (oacc_loop_auto_partitions): Use || instead of |
34231         to avoid warning.
34233         PR c/79413
34234         * gimplify.h (is_gimple_sizepos): Only test for INTEGER_CST constants,
34235         not arbitrary TREE_CONSTANT.
34237         PR c/79431
34238         * gimplify.c (gimplify_adjust_omp_clauses): Ignore
34239         "omp declare target link" attribute unless is_global_var.
34240         * omp-offload.c (find_link_var_op): Likewise.
34242 2017-02-09  Nathan Sidwell  <nathan@codesourcery.com>
34243             Chung-Lin Tang  <cltang@codesourcery.com>
34245         * gimplify.c (gimplify_scan_omp_clauses): No special handling for
34246         OMP_CLAUSE_TILE.
34247         (gimplify_adjust_omp_clauses): Don't delete TILE.
34248         (gimplify_omp_for): Deal with TILE.
34249         * internal-fn.c (expand_GOACC_TILE): New function.
34250         * internal-fn.def (GOACC_DIM_POS): Comment may be overly conservative.
34251         (GOACC_TILE): New.
34252         * omp-expand.c (struct oacc_collapse): Add tile and outer fields.
34253         (expand_oacc_collapse_init): Add LOC paramter.  Initialize tile
34254         element fields.
34255         (expand_oacc_collapse_vars): Add INNER parm, adjust for tiling,
34256         avoid DIV for outermost collapse var.
34257         (expand_oacc_for): Insert tile element loop as needed.  Adjust.
34258         Remove out of date comments, fix whitespace.
34259         * omp-general.c (omp_extract_for_data): Deal with tiling.
34260         * omp-general.h (enum oacc_loop_flags): Add OLF_TILE flag,
34261         adjust OLF_DIM_BASE value.
34262         (struct omp_for_data): Add tiling field.
34263         * omp-low.c (scan_sharing_clauses): Allow OMP_CLAUSE_TILE.
34264         (lower_oacc_head_mark): Add OLF_TILE as appropriate.  Ensure 2 levels
34265         for auto loops.  Remove default auto determining, moved to
34266         oacc_loop_fixed_partitions.
34267         * omp-offload.c (struct oacc_loop): Change 'ifns' to vector of call
34268         stmts, add e_mask field.
34269         (oacc_dim_call): New function, abstracted out from oacc_thread_numbers.
34270         (oacc_thread_numbers): Use oacc_dim_call.
34271         (oacc_xform_tile): New.
34272         (new_oacc_loop_raw): Initialize e_mask, adjust for ifns vector.
34273         (finish_oacc_loop): Adjust for ifns vector.
34274         (oacc_loop_discover_walk): Append loop abstraction sites to list,
34275         add case for GOACC_TILE fns.
34276         (oacc_loop_xform_loop): Delete.
34277         (oacc_loop_process): Iterate over call list directly, and add
34278         handling for GOACC_TILE fns.
34279         (oacc_loop_fixed_partitions): Determine default auto, deal with TILE,
34280         dump partitioning.
34281         (oacc_loop_auto_partitions): Add outer_assign parm. Assign all but
34282         vector partitioning to outer loops.  Assign 2 partitions to loops
34283         when available. Add TILE handling.
34284         (oacc_loop_partition): Adjust oacc_loop_auto_partitions call.
34285         (execite_oacc_device_lower): Process GOACC_TILE fns,
34286         ignore unknown specs.
34287         * tree-nested.c (convert_nonlocal_omp_clauses): Allow OMP_CLAUSE_TILE.
34288         * tree.c (omp_clause_num_ops): Adjust TILE ops.
34289         * tree.h (OMP_CLAUSE_TILE_ITERVAR, OMP_CLAUSE_TILE_COUNT): New.
34291 2017-02-09  Gerald Pfeifer  <gerald@pfeifer.com>
34293         * configure.ac (ACX_BUGURL): Update.
34294         * configure: Regenerate.
34296 2017-02-09  Richard Biener  <rguenther@suse.de>
34298         PR tree-optimization/69823
34299         * graphite-scop-detection.c (scop_detection::harmful_loop_in_region):
34300         Properly enumerate all BBs in the region.  Use auto_vec/auto_bitmap.
34302 2017-02-09  Andrew Burgess  <andrew.burgess@embecosm.com>
34304         * config/arc/arc-c.def: Add __NPS400__ definition.
34305         * config/arc/arc.h (CPP_SPEC): Don't define __NPS400__ here.
34306         (TARGET_NPS400): Define.
34308 2017-02-09  Andrew Burgess  <andrew.burgess@embecosm.com>
34310         * config/arc/arc-arch.h (arc_arch_t): Move unchanged to earlier in
34311         file.
34312         (arc_cpu_t): Change base_architecture field, arch, to a arc_arc_t
34313         pointer, arch_info.
34314         (arc_cpu_types): Fill the arch_info field with a pointer into the
34315         arc_arch_types table.
34316         (arc_selected_cpu): Declare.
34317         * config/arc/arc.c (arc_selected_cpu): Make global.
34318         (arc_selected_arch): Delete.
34319         (arc_base_cpu): Delete.
34320         (arc_override_options): Remove references to deleted variables,
34321         update access to arch information.
34322         (ARC_OPT): Update access to arch information.
34323         (ARC_OPTX): Likewise.
34324         * config/arc/arc.h (arc_base_cpu): Remove declaration.
34325         (TARGET_ARC600): Update access to arch information.
34326         (TARGET_ARC601): Likewise.
34327         (TARGET_ARC700): Likewise.
34328         (TARGET_EM): Likewise.
34329         (TARGET_HS): Likewise.
34330         * config/arc/driver-arc.c (arc_cpu_to_as): Update access to arch
34331         information.
34333 2017-02-08  Pat Haugen  <pthaugen@us.ibm.com>
34335         PR target/78604
34336         * config/rs6000/rs6000.c (rs6000_emit_vector_cond_expr): Invert
34337         condition/operands for integer GE/LE/GEU/LEU operations.
34339 2017-02-08  Segher Boessenkool  <segher@kernel.crashing.org>
34341         PR translation/79397
34342         * config/rs6000/rs6000.opt (maltivec=le, maltivec=be): Fix spelling
34343         of AltiVec.
34345 2017-02-08  Martin Jambor  <mjambor@suse.cz>
34347         PR ipa/79375
34348         * ipa-prop.c (ipa_alloc_node_params): Make static, return bool
34349         whether allocation happened.
34350         (ipa_initialize_node_params): Do not call ipa_alloc_node_params if
34351         nothing was allocated.
34353 2017-02-08  Jakub Jelinek  <jakub@redhat.com>
34355         PR tree-optimization/79408
34356         * tree-vrp.c (simplify_div_or_mod_using_ranges): If op1 is not
34357         constant, but SSA_NAME with a known integer range, use the minimum
34358         of that range instead of op1 to determine if modulo can be replaced
34359         with its first operand.
34361 2016-02-08  Kyrylo Tkachov  <kyrylo.tkachov@arm.com>
34363         * config/riscv/riscv.c (riscv_build_integer_1): Avoid use of INT16_MAX.
34365 2017-02-08  Richard Biener  <rguenther@suse.de>
34367         PR tree-optimization/71824
34368         * graphite-scop-detection.c (scop_detection::build_scop_breadth):
34369         Check all loops contained in the merged region.
34371 2017-02-07  Andrew Pinski  <apinski@cavium.com>
34373         * config/aarch64/aarch64.md (popcount<mode>2): New pattern.
34375 2017-02-07  Andrew Pinski  <apinski@cavium.com>
34377         * config/aarch64/aarch64-cores.def (thunderx): Disable LSE.
34378         (thunderxt88): Likewise.
34379         (thunderxt81): Disable LSE and change v8.1 to v8.
34380         (thunderxt83): Likewise.
34382 2017-02-07  Jakub Jelinek  <jakub@redhat.com>
34383             Richard Biener  <rguenther@suse.de>
34385         PR middle-end/79399
34386         * ira-int.h (struct target_ira_int): Change x_max_struct_costs_size
34387         type from int to size_t.
34388         * ira-costs.c (struct_costs_size): Change type from int to size_t.
34390 2017-02-07  Jakub Jelinek  <jakub@redhat.com>
34392         PR rtl-optimization/79386
34393         * cprop.c (bypass_conditional_jumps): Initialize
34394         bypass_last_basic_block already before splitting bbs after
34395         unconditional traps...
34396         (bypass_conditional_jumps): ... rather than here.
34398         PR target/79299
34399         * config/i386/sse.md (xtg_mode, gatherq_mode): New mode attrs.
34400         (*avx512f_gathersi<mode>, *avx512f_gathersi<mode>_2,
34401         *avx512f_gatherdi<mode>, *avx512f_gatherdi<mode>_2): Use them,
34402         fix -masm=intel patterns.
34404 2017-02-07  Richard Biener  <rguenther@suse.de>
34406         PR tree-optimization/79256
34407         PR middle-end/79278
34408         * builtins.c (get_object_alignment_2): Use min_align_of_type
34409         to extract alignment for MEM_REFs to honor BIGGEST_FIELD_ALIGNMENT
34410         and ADJUST_FIELD_ALIGN.
34412         * doc/tm.texi.in (ADJUST_FIELD_ALIGN): Adjust to take additional
34413         type parameter.
34414         * doc/tm.texi: Regenerate.
34415         * stor-layout.c (layout_decl): Adjust.
34416         (update_alignment_for_field): Likewise.
34417         (place_field): Likewise.
34418         (min_align_of_type): Likewise.
34419         * config/arc/arc.h (ADJUST_FIELD_ALIGN): Adjust.
34420         * config/epiphany/epiphany.h (ADJUST_FIELD_ALIGN): Likewise.
34421         * config/epiphany/epiphany.c (epiphany_adjust_field_align): Likewise.
34422         * config/frv/frv.h (ADJUST_FIELD_ALIGN): Likewise.
34423         * config/frv/frv.c (frv_adjust_field_align): Likewise.
34424         * config/i386/i386.h (ADJUST_FIELD_ALIGN): Likewise.
34425         * config/i386/i386.c (x86_field_alignment): Likewise.
34426         * config/rs6000/aix.h (ADJUST_FIELD_ALIGN): Likewise.
34427         * config/rs6000/darwin.h (ADJUST_FIELD_ALIGN): Likewise.
34428         * config/rs6000/freebsd64.h (ADJUST_FIELD_ALIGN): Likewise.
34429         * config/rs6000/linux64.h (ADJUST_FIELD_ALIGN): Likewise.
34430         * config/rs6000/sysv4.h (ADJUST_FIELD_ALIGN): Likewise.
34431         * config/rs6000/rs6000.c (rs6000_special_adjust_field_align_p):
34432          Likewise.
34434         Revert
34435         2017-01-30  Richard Biener  <rguenther@suse.de>
34437         PR tree-optimization/79256
34438         * targhooks.c (default_builtin_vector_alignment_reachable): Honor
34439         BIGGEST_FIELD_ALIGNMENT and ADJUST_FIELD_ALIGN to fix up bogus
34440         alignment on TYPE.
34442 2017-02-07  Toma Tabacu  <toma.tabacu@imgtec.com>
34444         * config/mips/mips.c (mips_expand_builtin_insn): Convert the QImode
34445         argument of the pshufh, psllh, psllw, psrah, psraw, psrlh, psrlw
34446         builtins to SImode and emit a zero-extend, if necessary.
34448 2017-02-06  Palmer Dabbelt  <palmer@dabbelt.com>
34450         * docs/invoke.texi (RISC-V Options): Alphabetize.
34452 2017-02-06  Palmer Dabbelt  <palmer@dabbelt.com>
34454         * doc/invoke.texi (RISC-V Options): Use two spaces to separate
34455         options.
34457 2017-02-06  Palmer Dabbelt  <palmer@dabbelt.com>
34459         * config/riscv/riscv.c: New file.
34460         * common/config/riscv/riscv-common.c: Likewise.
34461         * config.gcc: Likewise.
34462         * config/riscv/constraints.md: Likewise.
34463         * config/riscv/elf.h: Likewise.
34464         * config/riscv/generic.md: Likewise.
34465         * config/riscv/linux.h: Likewise.
34466         * config/riscv/multilib-generator: Likewise.
34467         * config/riscv/peephole.md: Likewise.
34468         * config/riscv/pic.md: Likewise.
34469         * config/riscv/predicates.md: Likewise.
34470         * config/riscv/riscv-builtins.c: Likewise.
34471         * config/riscv/riscv-c.c: Likewise.
34472         * config/riscv/riscv-ftypes.def: Likewise.
34473         * config/riscv/riscv-modes.def: Likewise.
34474         * config/riscv/riscv-opts.h: Likewise.
34475         * config/riscv/riscv-protos.h: Likewise.
34476         * config/riscv/riscv.h: Likewise.
34477         * config/riscv/riscv.md: Likewise.
34478         * config/riscv/riscv.opt: Likewise.
34479         * config/riscv/sync.md: Likewise.
34480         * config/riscv/t-elf-multilib: Likewise.
34481         * config/riscv/t-linux: Likewise.
34482         * config/riscv/t-linux-multilib: Likewise.
34483         * config/riscv/t-riscv: Likewise.
34484         * configure.ac: Likewise.
34485         * doc/contrib.texi: Add Kito Cheng, Palmer Dabbelt, and Andrew
34486         Waterman as RISC-V maintainers.
34487         * doc/install.texi: Add RISC-V entries.
34488         * doc/invoke.texi: Add RISC-V options section.
34489         * doc/md.texi: Add RISC-V constraints section.
34490         * configure: Regenerated.
34492 2017-02-06  Michael Meissner  <meissner@linux.vnet.ibm.com>
34494         PR target/66144
34495         * config/rs6000/vector.md (vcond<mode><mode>): Allow the true and
34496         false values to be constant vectors with all 0 or all 1 bits set.
34497         (vcondu<mode><mode>): Likewise.
34498         * config/rs6000/predicates.md (vector_int_reg_or_same_bit): New
34499         predicate.
34500         (fpmask_comparison_operator): Update comment.
34501         (vecint_comparison_operator): New predicate.
34502         * config/rs6000/rs6000.c (rs6000_emit_vector_cond_expr): Optimize
34503         vector conditionals when the true and false values are constant
34504         vectors with all 0 bits or all 1 bits set.
34506 2017-02-06  Martin Sebor  <msebor@redhat.com>
34508         PR  tree-optimization/79376
34509         * gimple-fold.c (get_range_strlen): Set the minimum length to zero.
34511 2017-02-06  Uros Bizjak  <ubizjak@gmail.com>
34513         * config/i386/sse.md (vector modes -> vec_extract* splitter): Use
34514         explicit subreg RTX with operand 1.  Use VECTOR_MODE_P predicate
34515         to simplify split condition.
34517 2017-02-06  Jakub Jelinek  <jakub@redhat.com>
34519         * omp-expand.c (oxpand_omp_atomic_fetch_op,
34520         expand_omp_atomic_pipeline): Return false if can_atomic_load_p is
34521         false.
34523 2017-02-06  Segher Boessenkool  <segher@kernel.crashing.org>
34525         PR rtl-optimization/68664
34526         * target.def (can_speculate_insn): New hook.
34527         * doc/tm.texi.in (TARGET_SCHED_CAN_SPECULATE_INSN): New hook.
34528         * doc/tm.texi: Regenerate.
34529         * sched-rgn.c (can_schedule_ready_p): Use the new hook.
34530         * config/rs6000/rs6000.c (TARGET_SCHED_CAN_SPECULATE_INSN): New macro.
34531         (rs6000_sched_can_speculate_insn): New function.
34533 2017-02-06  Jakub Jelinek  <jakub@redhat.com>
34535         PR tree-optimization/79284
34536         * tree-vectorizer.h (VECT_SCALAR_BOOLEAN_TYPE_P): Define.
34537         * tree-vect-stmts.c (vect_get_vec_def_for_operand,
34538         vectorizable_mask_load_store, vectorizable_operation,
34539         vect_is_simple_cond, get_same_sized_vectype): Use it instead
34540         of comparing TREE_CODE of a type against BOOLEAN_TYPE.
34541         * tree-vect-patterns.c (check_bool_pattern, search_type_for_mask_1,
34542         vect_recog_bool_pattern, vect_recog_mask_conversion_pattern): Likewise.
34543         * tree-vect-slp.c (vect_get_constant_vectors): Likewise.
34544         * tree-vect-loop.c (vect_determine_vectorization_factor): Likewise.
34545         Remove redundant gimple_code (stmt) == GIMPLE_ASSIGN test after
34546         is_gimple_assign (stmt).  Replace another such test with
34547         is_gimple_assign (stmt).
34549 2017-02-06  Georg-Johann Lay  <avr@gjlay.de>
34551         PR target/78883
34552         * config/avr/avr.c (rtl-iter.h): Include it.
34553         (TARGET_LEGITIMATE_COMBINED_INSN): New hook define...
34554         (avr_legitimate_combined_insn): ...and implementation.
34556 2017-02-06  Dominik Vogt  <vogt@linux.vnet.ibm.com>
34558         * config/s390/predicates.md ("larl_operand"): Use macros from hwint.h.
34559         * config/s390/s390.c (s390_const_operand_ok)
34560         (s390_canonicalize_comparison, s390_extract_part)
34561         (s390_single_part, s390_contiguous_bitmask_nowrap_p)
34562         (s390_contiguous_bitmask_p, s390_rtx_costs)
34563         (legitimize_pic_address): Likewise.
34564         * config/s390/s390.md ("clzdi2", "clztidi2"): Likewise.
34565         * config/s390/vx-builtins.md ("vec_genbytemaskv16qi")
34566         ("vec_permi<mode>", "vfae<mode>", "*vfaes<mode>", "vstrc<mode>")
34567         ("*vstrcs<mode>"): Use UINTVAL() to set unsigned HOST_WIDE_INT.
34568         * config/s390/vector.md ("vec_vfenes<mode>"): Likewise.
34570 2017-02-06  Georg-Johann Lay  <avr@gjlay.de>
34572         * config/avr/avr.md (*addhi3_zero_extend): Add alternative where
34573         REGNO($0) == REGNO($1).
34575 2017-02-06  Andreas Krebbel  <krebbel@linux.vnet.ibm.com>
34577         * config/s390/linux.h(SIZE_TYPE): Add comment.
34579 2017-02-06  Julian Brown  <julian@codesourcery.com>
34580             Naveen H.S  <Naveen.Hurugalawadi@cavium.com>
34581             Virendra Pathak  <virendra.pathak@broadcom.com>
34583         * config/aarch64/aarch64-cores.def: Change the scheduler
34584         to Thunderx2t99.
34585         * config/aarch64/aarch64.md: Include thunderx2t99.md.
34586         * config/aarch64/thunderx2t99.md: New file.
34588 2017-02-05  Gerald Pfeifer  <gerald@pfeifer.com>
34590         * doc/standards.texi (Go Language): Update link to language
34591         standard.
34593 2017-02-05  Jan Hubicka  <hubicka@ucw.cz>
34595         * tree-eh.c (lower_resx): Sanitize profile.
34596         (cleanup_empty_eh_move_lp): Likewise.
34598 2017-02-05  Jan Hubicka  <hubicka@ucw.cz>
34600         PR tree-ssa/79347
34601         * cfgloopmanip.c (lv_adjust_loop_entry_edge, loop_version): Add
34602         ELSE_PROB.
34603         * cfgloopmanip.h (loop_version): Update prototype.
34604         * modulo-sched.c (sms_schedule): Update call of loop_version.
34605         * tree-if-conv.c(version_loop_for_if_conversion): Likewise.
34606         * tree-parloops.c (gen_parallel_loop): Likewise.
34607         * tree-ssa-loop-manip.c (tree_transform_and_unroll_loop): Likewise.
34608         * tree-ssa-loop-split.c (split_loop): Likewise.
34609         * tree-ssa-loop-unswitch.c (tree_unswitch_loop): Likewise.
34610         * tree-vect-loop-manip.c (vect_loop_versioning): Likewise.
34612 2017-02-05  Martin Liska  <mliska@suse.cz>
34614         PR bootstrap/78985
34615         * config/s390/s390.c (s390_gimplify_va_arg): Initialize local
34616         variable to NULL.
34617         (print_operand_address): Initialize a struct to zero.
34619 2017-02-05  Gerald Pfeifer  <gerald@pfeifer.com>
34621         * doc/contrib.texi (Contributors): Refer to Hans Boehm's
34622         garbage collector only in textual form.
34624 2017-02-05  Gerald Pfeifer  <gerald@pfeifer.com>
34626         * doc/extend.texi (x86 specific memory model extensions for
34627         transactional memory): Simplify a phrase.
34629 2017-02-05  Eric Botcazou  <ebotcazou@adacore.com>
34631         PR target/79353
34632         * config/sparc/sync.md (atomic_loaddi_1): Replace 'U' constraint with
34633         'r', 'm' constraint with 'T' and !TARGET_ARCH64 with TARGET_ARCH32.
34634         (atomic_storedi_1): Likewise.
34636 2017-02-04  Jakub Jelinek  <jakub@redhat.com>
34638         PR tree-optimization/79338
34639         * tree-parloops.c (gather_scalar_reductions): Don't call
34640         vect_analyze_loop_form for loop->inner before destroying loop's
34641         loop_vinfo.
34643 2017-02-03  Martin Sebor  <msebor@redhat.com>
34645         PR tree-optimization/79327
34646         * gimple-ssa-sprintf.c (tree_digits): Avoid adding the base prefix
34647         when precision has resulted in leading zeros.
34648         (format_integer): Adjust the likely counter to assume an unknown
34649         argument that may be zero is non-zero.
34651 2017-02-03  Jason Merrill  <jason@redhat.com>
34653         PR c++/78689
34654         * tree-inline.c (copy_tree_body_r) [COND_EXPR]: Revert change to
34655         avoid copying non-taken branch.
34657 2017-02-03  Jakub Jelinek  <jakub@redhat.com>
34659         PR tree-optimization/79340
34660         * tree-vect-loop.c (vectorizable_reduction): Release
34661         vec_defs elements after safe_splicing them into other vectors.
34662         Formatting fixes.
34664         PR tree-optimization/79327
34665         * gimple-ssa-sprintf.c (adjust_range_for_overflow): If returning
34666         true, always set *argmin and *argmax to TYPE_{MIN,MAX}_VALUE of
34667         dirtype.
34668         (format_integer): Use wide_int_to_tree instead of build_int_cst
34669         + to_?hwi.  If argmin is NULL, just set argmin and argmax to
34670         TYPE_{MIN,MAX}_VALUE of argtype.  Simplify and fix computation
34671         of shortest and longest sequence.
34673 2017-02-03  Uros Bizjak  <ubizjak@gmail.com>
34675         * config/i386/i386.c (dimode_scalar_chain::convert_reg):
34676         Use pextrd for TARGET_SSE4_1 when creating scalar copy.
34678 2017-02-03  Walter Lee  <walt@tilera.com>
34680         PR target/78862
34681         * config/tilegx/tilegx.md (tilegx_expand_prologue): Add blockage
34682         after initial stackframe link reg save.
34683         * config/tilepro/tilepro.md (tilepro_expand_prologue): Likewise.
34685 2017-02-03  Jakub Jelinek  <jakub@redhat.com>
34687         PR target/79354
34688         * config/rs6000/rs6000.md (movsi_from_sf): Use wb constraint instead of
34689         wu for stxssp alternative.
34691 2017-02-03  Martin Sebor  <msebor@redhat.com>
34693         PR tree-optimization/79352
34694         * gimple-fold.c (get_range_strlen): Add argument.
34695         (get_range_strlen): Change return type to bool.
34696         (get_maxval_strlen): Pass in a dummy argument.
34697         * gimple-fold.h (get_range_strlen): Change return type to bool.
34698         * gimple-ssa-sprintf.c (get_string_length): Set unlikely counter.
34699         * tree.h (array_at_struct_end_p): Add argument.
34700         * tree.c (array_at_struct_end_p): Handle it.
34702 2017-02-03  Martin Liska  <mliska@suse.cz>
34704         PR lto/66295
34705         * multiple_target.c (create_dispatcher_calls): Redirect edge
34706         from a caller of a dispatcher.
34707         (expand_target_clones): Make the clones local.
34708         (ipa_target_clone): Do both target clones and resolvers.
34709         (ipa_dispatcher_calls): Remove the pass.
34710         (pass_dispatcher_calls::gate): Likewise.
34711         (make_pass_dispatcher_calls): Likewise.
34712         * passes.def (pass_target_clone): Put as very first IPA early
34713         pass.
34715 2017-02-03  Martin Liska  <mliska@suse.cz>
34717         * symtab.c (symtab_node::binds_to_current_def_p): Bail out
34718         in case of a function with ifunc attribute.
34720 2017-02-03  Martin Liska  <mliska@suse.cz>
34722         * cgraph.c (cgraph_node::dump): Dump function version info.
34723         * symtab.c (symtab_node::dump_base): Add missing new line.
34725 2017-02-02  Jan Hubicka  <hubicka@ucw.cz>
34727         * tree-ssa-ifcombine.c (update_profile_after_ifcombine): New function.
34728         (ifcombine_ifandif): Use it.
34730 2017-02-03  Martin Liska  <mliska@suse.cz>
34732         * doc/invoke.texi: Document default value for
34733         use-after-scope-direct-emission-threshold.
34735 2017-02-03  Martin Liska  <mliska@suse.cz>
34737         PR tree-optimization/79339
34738         * gimple-ssa-sprintf.c (format_floating_max): Call mpfr_clear.
34739         (format_floating): Likewise.
34741 2017-02-03  Martin Liska  <mliska@suse.cz>
34743         PR ipa/79337
34744         * ipa-prop.c (ipa_node_params_t::insert): Remove current
34745         implementation.
34746         (ipa_node_params_t::remove): Likewise.
34747         * ipa-prop.h (ipa_node_params::ipa_node_params): Make default
34748         initialization from removed ipa_node_params_t::insert.
34749         (ipa_node_params::~ipa_node_params): Move from removed
34750         ipa_node_params_t::release.
34751         * symbol-summary.h (symbol_summary::m_released): New member.
34752         Do not release a summary twice.  Do not allow to call finalizer
34753         for types of a summary that live in GGC memory.
34755 2017-02-02  Naveen H.S  <Naveen.Hurugalawadi@cavium.com>
34757         * config/aarch64/aarch64.c (thunderx2t99_tunings): Enable AES and
34758         cmp_branch fusion.
34760 2017-02-02  Martin Sebor  <msebor@redhat.com>
34762         PR middle-end/79275
34763         * gimple-ssa-sprintf.c (get_string_length): Set lower bound to zero.
34764         (format_string): Tighten up the range of output for non-constant
34765         strings and correct the expected range for wide non-constant strings.
34767 2017-02-02  Martin Sebor  <msebor@redhat.com>
34769         * doc/invoke.texi (-maccumulate-args): Fix bad grammar.
34771         PR middle-end/32003
34772         * doc/invoke.texi (-fdump-tree-): Remove pass-specific options from
34773         index.
34774         (-fdump-tree-@var): Add to index and document how to come up
34775         with pass-specific option and dump file names.
34776         (-fdump-passes): Clarify where to look for output.
34778 2017-02-02  Jan Hubicka  <hubicka@ucw.cz>
34780         PR middle-end/77445
34781         * tree-ssa-threadbackward.c (profitable_jump_thread_path): Dump
34782         statistics of the analyzed path; allow threading for speed when
34783         any of BBs along the path are optimized for speed.
34785 2017-02-02  Eric Botcazou  <ebotcazou@adacore.com>
34787         PR middle-end/78468
34788         * emit-rtl.c (init_emit): Add ??? comment for problematic alignment
34789         settings of the virtual registers.
34791         Revert again
34792         2016-08-23  Dominik Vogt  <vogt@linux.vnet.ibm.com>
34794         * explow.c (get_dynamic_stack_size): Take known alignment of stack
34795         pointer + STACK_DYNAMIC_OFFSET into account when calculating the size
34796         needed.
34798 2017-02-02  Andreas Krebbel  <krebbel@linux.vnet.ibm.com>
34800         * config/s390/vx-builtins.md ("vec_ceil", "vec_floor")
34801         ("vec_trunc", "vec_roundc", "vec_round"): Remove expanders.
34803 2017-02-02  Andreas Krebbel  <krebbel@linux.vnet.ibm.com>
34805         * config/s390/s390.md: Add missing comments with the expanded
34806         mnemonics.
34807         * config/s390/vector.md: Likewise.
34808         * config/s390/vx-builtins.md: Likewise.
34810 2017-02-02  Jakub Jelinek  <jakub@redhat.com>
34812         PR target/79197
34813         * config/rs6000/rs6000.md (*fixuns_trunc<mode>di2_fctiduz): Rename to ...
34814         (fixuns_trunc<mode>di2): ... this, remove previous expander.  Put all
34815         conditions on a single line.
34817 2017-02-02  Andreas Krebbel  <krebbel@linux.vnet.ibm.com>
34819         * config/s390/s390-c.c (s390_cpu_cpp_builtins_internal): Rename
34820         __S390_VX__ to __VX__.
34822 2017-02-01  Andrew Pinski  <apinski@cavium.com>
34824         * tree-vect-loop.c (vect_compute_single_scalar_iteration_cost): Pass
34825         stmt_info to record_stmt_cost.
34826         (vect_get_known_peeling_cost): Pass stmt_info if known to
34827         record_stmt_cost.
34828         * config/aarch64/aarch64-protos.h (cpu_vector_cost): Split
34829         cpu_vector_cost field into
34830         scalar_int_stmt_cost and scalar_fp_stmt_cost.  Split vec_stmt_cost
34831         field into vec_int_stmt_cost and vec_fp_stmt_cost.
34832         * config/aarch64/aarch64.c (generic_vector_cost): Update for the
34833         splitting of scalar_stmt_cost and vec_stmt_cost.
34834         (thunderx_vector_cost): Likewise.
34835         (cortexa57_vector_cost): LIkewise.
34836         (exynosm1_vector_cost): Likewise.
34837         (xgene1_vector_cost): Likewise.
34838         (thunderx2t99_vector_cost): Improve after the splitting of the two
34839         fields.
34840         (aarch64_builtin_vectorization_cost): Update for the splitting of
34841         scalar_stmt_cost and vec_stmt_cost.
34843 2017-02-01  Torvald Riegel  <triegel@redhat.com>
34844             Richard Henderson  <rth@redhat.com>
34846         * builtins.c (fold_builtin_atomic_always_lock_free): Make "lock-free"
34847         conditional on existance of a fast atomic load.
34848         * optabs-query.c (can_atomic_load_p): New function.
34849         * optabs-query.h (can_atomic_load_p): Declare it.
34850         * optabs.c (expand_atomic_exchange): Always delegate to libatomic if
34851         no fast atomic load is available for the particular size of access.
34852         (expand_atomic_compare_and_swap): Likewise.
34853         (expand_atomic_load): Likewise.
34854         (expand_atomic_store): Likewise.
34855         (expand_atomic_fetch_op): Likewise.
34856         * testsuite/lib/target-supports.exp
34857         (check_effective_target_sync_int_128): Remove x86 because it provides
34858         no fast atomic load.
34859         (check_effective_target_sync_int_128_runtime): Likewise.
34861 2017-02-01  Richard Biener  <rguenther@suse.de>
34863         * graphite.c: Include tree-vectorizer.h for find_loop_location.
34864         (graphite_transform_loops): Provide opt-info for optimized nests.
34865         * tree-parloop.c (parallelize_loops): Provide opt-info for
34866         parallelized loops.
34868 2017-02-01  Richard Biener  <rguenther@suse.de>
34870         PR middle-end/79315
34871         * tree-cfg.c (move_stmt_op): Never set TREE_BLOCK when it
34872         was not set before.
34874 2017-02-01  Richard Biener  <rguenther@suse.de>
34876         PR tree-optimization/71824
34877         * graphite-scop-detection.c (scop_detection::build_scop_breadth):
34878         Verify the loops are valid in the merged SESE region.
34879         (scop_detection::can_represent_loop_1): Check analyzing the
34880         evolution of the number of iterations in the region succeeds.
34882 2017-01-31  Ian Lance Taylor  <iant@golang.org>
34884         * config/i386/i386.c (ix86_expand_split_stack_prologue): Add
34885         REG_ARGS_SIZE note to 32-bit push insns and call insn.
34887 2017-01-31  David Malcolm  <dmalcolm@redhat.com>
34889         PR preprocessor/79210
34890         * input.c (get_substring_ranges_for_loc): Replace line_width
34891         assertion with error-handling.
34893 2017-01-31  Richard Biener  <rguenther@suse.de>
34895         PR tree-optimization/77318
34896         * graphite-sese-to-poly.c (extract_affine): Fix assert.
34897         (create_pw_aff_from_tree): Take loop parameter.
34898         (add_condition_to_pbb): Pass loop of the condition to
34899         create_pw_aff_from_tree.
34901 2017-01-31  Jakub Jelinek  <jakub@redhat.com>
34903         * config/s390/s390.c (s390_asan_shadow_offset): New function.
34904         (TARGET_ASAN_SHADOW_OFFSET): Redefine.
34906 2017-01-31  Michael Meissner  <meissner@linux.vnet.ibm.com>
34908         PR target/78597
34909         PR target/79038
34910         * config/rs6000/rs6000-protos.h (convert_float128_to_int): Delete,
34911         no longer used.
34912         (convert_int_to_float128): Likewise.
34913         * config/rs6000/rs6000.c (convert_float128_to_int): Likewise.
34914         (convert_int_to_float128): Likewise.
34915         * config/rs6000/rs6000.md (UNSPEC_IEEE128_MOVE): Likewise.
34916         (UNSPEC_IEEE128_CONVERT): Likewise.
34917         (floatsi<mode>2, FLOAT128 iterator): Bypass calling
34918         rs6000_expand_float128_convert if we have IEEE 128-bit hardware.
34919         Use local variables for IBM extended format.
34920         (fix_trunc<mode>si2, FLOAT128 iterator): Likewise.
34921         (fix_trunc<mode>si2_fprs): Likewise.
34922         (fixuns_trunc<IEEE128:mode><SDI:mode>2): Likewise.
34923         (floatuns<IEEE128:mode>2, IEEE128 iterator): Likewise.
34924         (fix<uns>_<mode>si2_hw): Rework the IEEE 128-bt hardware support
34925         to know that we can now have integers of all sizes in vector
34926         registers.
34927         (fix<uns>_<mode>di2_hw): Likewise.
34928         (float<uns>_<mode>si2_hw): Likewise.
34929         (fix_<mode>si2_hw): Likewise.
34930         (fixuns_<mode>si2_hw): Likewise.
34931         (float<uns>_<mode>di2_hw): Likewise.
34932         (float_<mode>di2_hw): Likewise.
34933         (float_<mode>si2_hw): Likewise.
34934         (floatuns_<mode>di2_hw): Likewise.
34935         (floatuns_<mode>si2_hw): Likewise.
34936         (xscvqp<su>wz_<mode>): Delete, no longer used.
34937         (xscvqp<su>dz_<mode>): Likewise.
34938         (xscv<su>dqp_<mode>): Likewise.
34939         (ieee128_mfvsrd_64bit): Likewise.
34940         (ieee128_mfvsrd_32bit): Likewise.
34941         (ieee128_mfvsrwz): Likewise.
34942         (ieee128_mtvsrw): Likewise.
34943         (ieee128_mtvsrd_64bit): Likewise.
34944         (ieee128_mtvsrd_32bit): Likewise.
34946 2017-01-31  Martin Liska  <mliska@suse.cz>
34948         PR ipa/79285
34949         * ipa-prop.c (ipa_free_all_node_params): Call release method
34950         instead of ~sumbol_summary to not to trigger double times
34951         dtor of hash_map.
34953 2017-01-31  Aldy Hernandez  <aldyh@redhat.com>
34955         PR tree-optimization/71691
34956         * bitmap.h (class auto_bitmap): New.
34957         * tree-ssa-loop-unswitch.c (tree_may_unswitch_on): Call
34958         is_maybe_undefined instead of ssa_undefined_value_p.
34960 2017-01-31  Andreas Krebbel  <krebbel@linux.vnet.ibm.com>
34962         * config/s390/s390-c.c (s390_cpu_cpp_builtins_internal): Rename
34963         __S390_ARCH_LEVEL__ to __ARCH__.
34965 2017-01-31  Jakub Jelinek  <jakub@redhat.com>
34967         PR tree-optimization/79267
34968         * value-prof.c (gimple_ic): Only drop lhs for noreturn calls
34969         if should_remove_lhs_p is true.
34971 2017-01-30  Alexandre Oliva <aoliva@redhat.com>
34973         PR debug/63238
34974         * dwarf2out.c (clone_as_declaration): Drop DW_AT_alignment.
34975         (add_alignment_attribute): New.
34976         (base_type_die): Add alignment attribute.
34977         (subrange_type_die): Likewise.
34978         (modified_type_die): Likewise.
34979         (gen_array_type_die): Likewise.
34980         (gen_descr_array_type_die: Likewise.
34981         (gen_enumeration_type_die): Likewise.
34982         (gen_subprogram_die): Likewise.
34983         (gen_variable_die): Likewise.
34984         (gen_field_die): Likewise.
34985         (gen_ptr_to_mbr_type_die): Likewise.
34986         (gen_struct_or_union_type_die): Likewise.
34987         (gen_subroutine_type_die): Likewise.
34988         (gen_typedef_die): Likewise.
34989         (base_type_cmp): Compare alignment attribute.
34991 2017-01-30  Aaron Sawdey  <acsawdey@linux.vnet.ibm.com>
34993         PR target/79170
34994         * config/rs6000/altivec.md (*setb_internal): Rename to setb_signed.
34995         (setb_unsigned) New pattern for setb with CCUNS.
34996         * config/rs6000/rs6000.c (expand_block_compare): Use a different
34997         subfc./subfe sequence to avoid overflow problems.  Generate a
34998         shorter sequence with cmpld/setb for power9.
34999         * config/rs6000/rs6000.md (subf<mode>3_carry_dot2): Add a new pattern
35000         for generating subfc. instruction.
35001         (cmpstrsi): Add TARGET_POPCNTD predicate as the generate sequence
35002         now uses this instruction.
35004 2017-01-30  Ian Lance Taylor  <iant@google.com>
35006         PR debug/79289
35007         * dwarf2out.c (gen_type_die_with_usage): When picking a variant
35008         for FUNCTION_TYPE/METHOD_TYPE, use the first matching one.
35010 2017-01-30  Martin Sebor  <msebor@redhat.com>
35012         * gimple-ssa-sprintf.c (fmtresult::adjust_for_width_or_precision):
35013         Move constant to the right of a relational operator.
35014         (get_mpfr_format_length, format_character, format_string): Ditto.
35015         (should_warn_p, maybe_warn): Same.
35017         * doc/invoke.texi (-Wformat-truncation=1): Fix typo.
35019 2017-01-30  Maxim Ostapenko  <m.ostapenko@samsung.com>
35021         PR lto/79061
35022         * asan.c (get_translation_unit_decl): Remove function.
35023         (asan_add_global): Force has_dynamic_init to zero in LTO mode.
35025 2017-01-30  Martin Liska  <mliska@suse.cz>
35027         PR gcov-profile/79259
35028         * opts.c (common_handle_option): Enable flag_ipa_bit_cp w/
35029         -fprofile-generate.
35031 2017-01-30  Martin Liska  <mliska@suse.cz>
35033         PR bootstrap/78985
35034         * config/aarch64/cortex-a57-fma-steering.c (func_fma_steering::analyze):
35035         Initialize variables with NULL value.
35037 2017-01-30  Richard Earnshaw  <rearnsh@arm.com>
35039         PR target/79260
35040         * config.gcc (arm*-*-*): Add arm/arm-flags.h and arm/arm-isa.h to
35041         tm_p_file.
35042         * arm/arm-protos.h: Don't directly include arm-flags.h and arm-isa.h.
35044 2017-01-30  Richard Biener  <rguenther@suse.de>
35046         PR tree-optimization/79276
35047         * tree-vrp.c (process_assert_insertions): Properly adjust common
35048         when removing a duplicate.
35050 2017-01-30  Richard Biener  <rguenther@suse.de>
35052         PR tree-optimization/79256
35053         * targhooks.c (default_builtin_vector_alignment_reachable): Honor
35054         BIGGEST_FIELD_ALIGNMENT and ADJUST_FIELD_ALIGN to fix up bogus
35055         alignment on TYPE.
35056         * tree.c (build_aligned_type): Set TYPE_USER_ALIGN.
35058 2017-01-30  Dominik Vogt  <vogt@linux.vnet.ibm.com>
35060         PR target/79240
35061         * config/s390/s390.md ("*r<noxa>sbg_<mode>_srl_bitmask")
35062         ("*r<noxa>sbg_<mode>_sll_bitmask")
35063         ("*extzv_<mode>_srl<clobbercc_or_nocc>")
35064         ("*extzv_<mode>_sll<clobbercc_or_nocc>"):
35065         Use contiguous_bitmask_nowrap_operand.
35067 2017-01-29  Bill Schmidt  <wschmidt@linux.vnet.ibm.com>
35069         PR target/79268
35070         * config/rs6000/altivec.h (vec_xl): Revise #define.
35071         (vec_xst): Likewise.
35073 2017-01-27  Uros Bizjak  <ubizjak@gmail.com>
35075         * config/i386/i386.c (print_reg): Use REGNO instead of true_regnum.
35077 2017-01-27  Bernd Schmidt  <bschmidt@redhat.com>
35079         PR rtl-optimization/79194
35080         * cprop.c (one_cprop_pass): Move deletion of code after unconditional
35081         traps before call to bypass_conditional_jumps.
35083 2017-01-27  Vladimir Makarov  <vmakarov@redhat.com>
35085         PR tree-optimization/71374
35086         * lra-constraints.c (check_conflict_input_operands): New.
35087         (match_reload): Use it.
35089 2017-01-27  Vladimir Makarov  <vmakarov@redhat.com>
35091         PR target/79131
35092         * lra-assigns.c (find_hard_regno_for_1): Take endianess for into
35093         account to calculate conflict_set.
35095 2017-01-27  Bin Cheng  <bin.cheng@arm.com>
35097         PR rtl-optimization/78559
35098         * combine.c (try_combine): Discard REG_EQUAL and REG_EQUIV for
35099         other_insn in combine.
35101 2017-01-27  Pekka Jääskeläinen  <pekka.jaaskelainen@parmance.com>
35103         * builtin-types.def: Use unsigned_char_type_node for BT_UINT8.  Use
35104         uint16_type_node for BT_UINT16.
35106 2017-01-27  David Malcolm  <dmalcolm@redhat.com>
35108         * doc/sourcebuild.texi (Testsuites): Add "GIMPLE Tests" and
35109         "RTL Tests" to menu.
35110         (GIMPLE Tests): New node.
35111         (RTL Tests): New node.
35113 2017-01-27  Richard Biener  <rguenther@suse.de>
35115         PR tree-optimization/79245
35116         * tree-loop-distribution.c (distribute_loop): Apply cost
35117         modeling also to detected patterns.
35119 2017-01-27  Richard Biener  <rguenther@suse.de>
35121         PR tree-optimization/71433
35122         * tree-vrp.c (register_new_assert_for): Revert earlier changes.
35123         (compare_assert_loc): New function.
35124         (process_assert_insertions): Sort and optimize assert locations
35125         to remove duplicates and push down identical assertions on
35126         edges to their destination block.
35128 2017-01-27  Richard Biener  <rguenther@suse.de>
35130         PR tree-optimization/79244
35131         * tree-vrp.c (remove_range_assertions): Forcefully propagate
35132         out SSA names even if abnormal.
35134 2017-01-27  Jakub Jelinek  <jakub@redhat.com>
35136         * realmpfr.h: Poison MPFR_RND{N,Z,U,D}.
35137         * gimple-ssa-sprintf.c (format_floating_max): Use GMP_RNDN
35138         instead of MPFR_RNDN.
35140 2017-01-27  Richard Earnshaw  <rearnsha@arm.com>
35142         PR target/79239
35143         * arm.c (arm_option_override): Don't call build_target_option_node
35144         until after doing all option overrides.
35145         (arm_valid_target_attribute_tree): Likewise.
35147 2017-01-27  Martin Liska  <mliska@suse.cz>
35149         * doc/invoke.texi (-fprofile-arcs): Document profiling support
35150         for {cd}tors and C++ {cd}tors.
35152 2017-01-27  Dominik Vogt  <vogt@linux.vnet.ibm.com>
35154         * config/s390/s390.md ("*setmem_long_and")
35155         ("*setmem_long_and_31z"): Use zero_extend instead of and.
35157 2017-01-26  Martin Sebor  <msebor@redhat.com>
35159         * gimple-ssa-sprintf.c (format_floating): Simplify the computation
35160         of precision.
35162 2017-01-26  Martin Sebor  <msebor@redhat.com>
35164         * gimple-ssa-sprintf.c (format_floating): Test HAVE_XFmode and
35165         HAVE_DFmode before using XFmode or DFmode.
35166         (parse_directive): Avoid using the z length modifier to avoid
35167         the ISO C++98 does not support the â€˜z’ gnu_printf length modifier.
35169         PR middle-end/78703
35170         * gimple-ssa-sprintf.c (adjust_for_width_or_precision): Change
35171         to accept adjustment as an array.
35172         (get_int_range): New function.
35173         (struct directive): Make width and prec arrays.
35174         (directive::set_width, directive::set_precision): Call get_int_range.
35175         (format_integer, format_floating): Handle width and precision ranges.
35176         (format_string, parse_directive): Same.
35178 2017-01-26  Jakub Jelinek  <jakub@redhat.com>
35180         PR debug/79129
35181         * dwarf2out.c (generate_skeleton_bottom_up): For children with
35182         comdat_type_p set, just clone them, but keep the children in the
35183         original DIE.
35185         PR debug/78835
35186         * dwarf2out.c (prune_unused_types): Mark all functions with DIEs
35187         which have direct callers with -fvar-tracking-assignments enabled
35188         in the current TU.
35189         (resolve_addr): Avoid adding skeleton DIEs for DW_AT_call_origin
35190         inside of type units.
35192 2017-01-26  Martin Sebor  <msebor@redhat.com>
35194         PR middle-end/78703
35195         * gimple-ssa-sprintf.c (struct result_range): Add likely and
35196         unlikely counters.
35197         (struct format_result): Replace number_chars, number_chars_min,
35198         and number_chars_max with a single member of struct result_range.
35199         Remove bounded.
35200         (format_result::operator+=): Adjust.
35201         (struct fmtresult): Remove bounded.  Handle likely and unlikely
35202         counters.
35203         (fmtresult::adjust_for_width_or_precision): New function.
35204         (fmtresult:type_max_digits): New function.
35205         (bytes_remaining): Handle likely and unlikely counters.
35206         (min_bytes_remaining): Remove.
35207         (format_percent): Simplify.
35208         (format_integer, format_floating): Set likely and unlikely counters.
35209         (get_string_length, format_character, format_string): Same.
35210         (format_plain, should_warn_p): New function.
35211         (maybe_warn): Call should_warn_p.  Update diagnostic messages
35212         and handle those for all directives, including plain strings.
35213         (format_directive): Handle likely and unlikely counters.
35214         Remove unnecessary quoting from diagnostics.  Add an informational
35215         note.
35216         (add_bytes): Remove.
35217         (pass_sprintf_length::compute_format_length): Simplify.
35218         (try_substitute_return_value): Handle likely and unlikely counters.
35220 2017-01-26  Carl Love  <cel@us.ibm.com>
35222         * config/rs6000/rs6000-c (altivec_overloaded_builtins): Remove
35223         bogus entries for the P8V_BUILTIN_VEC_VGBBD built-ins
35225 2017-01-26  Vladimir Makarov  <vmakarov@redhat.com>
35227         PR target/79131
35228         * lra-assigns.c (setup_live_pseudos_and_spill_after_risky): Take
35229         endianess for subregs into account.
35230         * lra-constraints.c (lra_constraints): Do risky transformations
35231         always on the first iteration.
35232         * lra-lives.c (check_pseudos_live_through_calls): Add arg
35233         last_call_used_reg_set.
35234         (process_bb_lives): Define and use last_call_used_reg_set.
35235         * lra.c (lra): Always continue after lra_constraints on the first
35236         iteration.
35238 2017-01-26  Kirill Yukhin  <kirill.yukhin@gmail.com>
35240         * gcc.target/i386/avx512bw-kshiftlq-2.c: Use unsigned long long
35241         constant.
35242         * gcc.target/i386/avx512bw-kshiftrq-2.c: Ditto.
35244 2017-01-26  Jakub Jelinek  <jakub@redhat.com>
35246         * config/i386/avx512fintrin.h (_ktest_mask16_u8,
35247         _ktestz_mask16_u8, _ktestc_mask16_u8, _kadd_mask16): Move to ...
35248         * config/i386/avx512dqintrin.h (_ktest_mask16_u8,
35249         _ktestz_mask16_u8, _ktestc_mask16_u8, _kadd_mask16): ... here.
35250         * config/i386/i386-builtin.def (__builtin_ia32_ktestchi,
35251         __builtin_ia32_ktestzhi, __builtin_ia32_kaddhi): Use
35252         OPTION_MASK_ISA_AVX512DQ instead of OPTION_MASK_ISA_AVX512F.
35253         * config/i386/sse.md (SWI1248_AVX512BWDQ2): New mode iterator.
35254         (kadd<mode>, ktest<mode>): Use it instead of SWI1248_AVX512BWDQ.
35256 2017-01-26  Marek Polacek  <polacek@redhat.com>
35258         PR c/79199
35259         * fold-const.c (operand_equal_p) [COND_EXPR]: Use OP_SAME_WITH_NULL
35260         for the third operand.
35262 2017-01-26  Jakub Jelinek  <jakub@redhat.com>
35264         PR middle-end/79236
35265         * omp-low.c (struct omp_context): Add simt_stmt field.
35266         (scan_omp_for): Return omp_context *.
35267         (scan_omp_simd): Set simt_stmt on the non-_simt_ SIMD
35268         context to the _simt_ SIMD stmt.
35269         (lower_omp_for): For combined SIMD with sibling _simt_
35270         SIMD, make sure to use the same decls in _looptemp_
35271         clauses as in the sibling.
35273 2017-01-26  David Sherwood  <david.sherwood@arm.com>
35275         PR middle-end/79212
35276         * gimplify.c (omp_notice_variable): Add GOVD_SEEN flag to variables in
35277         all contexts.
35279 2017-01-26  Jakub Jelinek  <jakub@redhat.com>
35281         PR target/70465
35282         * reg-stack.c (emit_swap_insn): Instead of fld a; fld b; fxchg %st(1);
35283         emit fld b; fld a; if possible.
35285         * brig-builtins.def: Update copyright years.
35286         * config/arm/arm_acle_builtins.def: Update copyright years.
35288 2017-01-25  Michael Meissner  <meissner@linux.vnet.ibm.com>
35290         PR target/79179
35291         * config/rs6000/vsx.md (vsx_extract_<mode>_store): Use wY
35292         constraint instead of o for the stxsd instruction.
35294 2017-01-25  Carl Love  <cel@us.ibm.com>
35296         * config/rs6000/rs6000-c (altivec_overloaded_builtins): Fix order
35297         of entries for ALTIVEC_BUILTIN_VEC_PACKS and P8V_BUILTIN_VEC_VGBBD.
35299 2017-01-25  Jonathan Wakely  <jwakely@redhat.com>
35301         * doc/invoke.texi (C++ Dialect Options): Fix typo.
35303 2017-01-25  Richard Biener  <rguenther@suse.de>
35305         PR tree-optimization/69264
35306         * target.def (vector_alignment_reachable): Improve documentation.
35307         * doc/tm.texi: Regenerate.
35308         * targhooks.c (default_builtin_vector_alignment_reachable): Simplify
35309         and add a comment.
35310         * tree-vect-data-refs.c (vect_supportable_dr_alignment): Revert
35311         earlier changes with respect to TYPE_USER_ALIGN.
35312         (vector_alignment_reachable_p): Likewise.  Improve dumping.
35314 2016-01-25  Kyrylo Tkachov  <kyrylo.tkachov@arm.com>
35316         PR target/79145
35317         * config/arm/arm.md (xordi3): Force constant operand into a register
35318         for TARGET_IWMMXT.
35320 2016-01-25  Kyrylo Tkachov  <kyrylo.tkachov@arm.com>
35322         * doc/invoke.texi (-fstore-merging): Correct default optimization
35323         levels at which it is enabled.
35324         (-O): Move -fstore-merging from list to...
35325         (-O2): ... Here.
35327 2017-01-25  Richard Biener  <rguenther@suse.de>
35329         PR debug/78363
35330         * omp-expand.c: Include debug.h.
35331         (expand_omp_taskreg): Make sure to generate early debug before
35332         outlining anything from a function.
35333         (expand_omp_target): Likewise.
35334         (grid_expand_target_grid_body): Likewise.
35336 2017-01-25  Maxim Ostapenko  <m.ostapenko@samsung.com>
35338         PR lto/79061
35339         * asan.c (get_translation_unit_decl): New function.
35340         (asan_add_global): Extract modules file name from globals
35341         TRANSLATION_UNIT_DECL name.
35343 2017-01-24  Eric Botcazou  <ebotcazou@adacore.com>
35345         PR target/77439
35346         * config/arm/arm.c (arm_function_ok_for_sibcall): Add back restriction
35347         for long calls with APCS frame and VFP.
35349 2017-01-24  David Malcolm  <dmalcolm@redhat.com>
35351         * cfg.c (original_copy_tables_initialized_p): New function.
35352         * cfg.h (original_copy_tables_initialized_p): New decl.
35353         * cfgrtl.c (relink_block_chain): Guard the call to
35354         free_original_copy_tables with a call to
35355         original_copy_tables_initialized_p.
35356         * cgraph.h (symtab_node::native_rtl_p): New decl.
35357         * cgraphunit.c (symtab_node::native_rtl_p): New function.
35358         (symtab_node::needed_p): Don't assert for early assembly output
35359         for __RTL functions.
35360         (cgraph_node::finalize_function): Set "force_output" for __RTL
35361         functions.
35362         (cgraph_node::analyze): Bail out early for __RTL functions.
35363         (analyze_functions): Update assertion to support __RTL functions.
35364         (cgraph_node::expand): Bail out early for __RTL functions.
35365         * final.c (rest_of_clean_state): Don't call delete_tree_ssa for
35366         __RTL functions.
35367         * function.h (struct function): Update comment for field
35368         "pass_startwith".
35369         * gimple-expr.c: Include "tree-pass.h".
35370         (gimple_has_body_p): Return false for __RTL functions.
35371         * Makefile.in (OBJS): Add run-rtl-passes.o.
35372         * pass_manager.h (gcc::pass_manager::get_rest_of_compilation): New
35373         accessor.
35374         (gcc::pass_manager::get_clean_slate): New accessor.
35375         * passes.c: Include "insn-addr.h".
35376         (should_skip_pass_p): Add logging.  Update logic for running
35377         "expand" to be compatible with both __GIMPLE and __RTL.  Guard
35378         property-provider override so it is only done for gimple passes.
35379         Don't skip dfinit.
35380         (skip_pass): New function.
35381         (execute_one_pass): Call skip_pass when skipping passes.
35382         * read-md.c (md_reader::read_char): Support filtering
35383         the input to a subset of line numbers.
35384         (md_reader::md_reader): Initialize fields
35385         m_first_line and m_last_line.
35386         (md_reader::read_file_fragment): New function.
35387         * read-md.h (md_reader::read_file_fragment): New decl.
35388         (md_reader::m_first_line): New field.
35389         (md_reader::m_last_line): New field.
35390         * read-rtl-function.c (function_reader::create_function): Only
35391         create cfun if it doesn't already exist.  Set PROP_rtl on cfun's
35392         curr_properties.  Set DECL_INITIAL to a dummy block.
35393         (read_rtl_function_body_from_file_range): New function.
35394         * read-rtl-function.h (read_rtl_function_body_from_file_range):
35395         New decl.
35396         * run-rtl-passes.c: New file.
35397         * run-rtl-passes.h: New file.
35399 2017-01-24  Jeff Law  <law@redhat.com>
35401         * config/microblaze/microblaze.h (ASM_FORMAT_PRIVATE_NAME): Increase
35402         buffer size.
35404 2017-01-24  Bin Cheng  <bin.cheng@arm.com>
35406         PR tree-optimization/79159
35407         * tree-ssa-loop-niter.c (get_cst_init_from_scev): New function.
35408         (record_nonwrapping_iv): Improve boundary using above function if no
35409         value range information.
35411 2017-01-24  Pekka Jääskeläinen  <pekka@parmance.com>
35412             Martin Jambor  <mjambor@suse.cz>
35414         * brig-builtins.def: New file.
35415         * builtins.def (DEF_HSAIL_BUILTIN): New macro.
35416         (DEF_HSAIL_ATOMIC_BUILTIN): Likewise.
35417         (DEF_HSAIL_SAT_BUILTIN): Likewise.
35418         (DEF_HSAIL_INTR_BUILTIN): Likewise.
35419         (DEF_HSAIL_CVT_ZEROI_SAT_BUILTIN): Likewise.
35420         * builtin-types.def (BT_INT8): New.
35421         (BT_INT16): Likewise.
35422         (BT_UINT8): Likewise.
35423         (BT_UINT16): Likewise.
35424         (BT_FN_ULONG): Likewise.
35425         (BT_FN_UINT_INT): Likewise.
35426         (BT_FN_UINT_ULONG): Likewise.
35427         (BT_FN_UINT_LONG): Likewise.
35428         (BT_FN_UINT_PTR): Likewise.
35429         (BT_FN_ULONG_PTR): Likewise.
35430         (BT_FN_INT8_FLOAT): Likewise.
35431         (BT_FN_INT16_FLOAT): Likewise.
35432         (BT_FN_UINT32_FLOAT): Likewise.
35433         (BT_FN_UINT16_FLOAT): Likewise.
35434         (BT_FN_UINT8_FLOAT): Likewise.
35435         (BT_FN_UINT64_FLOAT): Likewise.
35436         (BT_FN_UINT16_UINT32): Likewise.
35437         (BT_FN_UINT32_UINT16): Likewise.
35438         (BT_FN_UINT16_UINT16_UINT16): Likewise.
35439         (BT_FN_INT_PTR_INT): Likewise.
35440         (BT_FN_UINT_PTR_UINT): Likewise.
35441         (BT_FN_LONG_PTR_LONG): Likewise.
35442         (BT_FN_ULONG_PTR_ULONG): Likewise.
35443         (BT_FN_VOID_UINT64_UINT64): Likewise.
35444         (BT_FN_UINT8_UINT8_UINT8): Likewise.
35445         (BT_FN_INT8_INT8_INT8): Likewise.
35446         (BT_FN_INT16_INT16_INT16): Likewise.
35447         (BT_FN_INT_INT_INT): Likewise.
35448         (BT_FN_UINT_FLOAT_UINT): Likewise.
35449         (BT_FN_FLOAT_UINT_UINT): Likewise.
35450         (BT_FN_ULONG_UINT_UINT): Likewise.
35451         (BT_FN_ULONG_UINT_PTR): Likewise.
35452         (BT_FN_ULONG_ULONG_ULONG): Likewise.
35453         (BT_FN_UINT_UINT_UINT): Likewise.
35454         (BT_FN_VOID_UINT_PTR): Likewise.
35455         (BT_FN_UINT_UINT_PTR: Likewise.
35456         (BT_FN_UINT32_UINT64_PTR): Likewise.
35457         (BT_FN_INT_INT_UINT_UINT): Likewise.
35458         (BT_FN_UINT_UINT_UINT_UINT): Likewise.
35459         (BT_FN_UINT_UINT_UINT_PTR): Likewise.
35460         (BT_FN_UINT_ULONG_ULONG_UINT): Likewise.
35461         (BT_FN_ULONG_ULONG_ULONG_ULONG): Likewise.
35462         (BT_FN_LONG_LONG_UINT_UINT): Likewise.
35463         (BT_FN_ULONG_ULONG_UINT_UINT): Likewise.
35464         (BT_FN_VOID_UINT32_UINT64_PTR): Likewise.
35465         (BT_FN_VOID_UINT32_UINT32_PTR): Likewise.
35466         (BT_FN_UINT_UINT_UINT_UINT_UINT): Likewise.
35467         (BT_FN_UINT_FLOAT_FLOAT_FLOAT_FLOAT): Likewise.
35468         (BT_FN_ULONG_ULONG_ULONG_UINT_UINT): Likewise.
35469         * doc/frontends.texi: List BRIG FE.
35470         * doc/install.texi (Testing): Add BRIG tesring requirements.
35471         * doc/invoke.texi (Overall Options): Mention BRIG.
35472         * doc/standards.texi (Standards): Doucment BRIG HSA version.
35474 2017-01-24  Richard Biener  <rguenther@suse.de>
35476         PR translation/79208
35477         * ipa-devirt.c (odr_types_equivalent_p): Fix typo in diagnostic.
35479 2017-01-24  Martin Jambor  <mjambor@suse.cz>
35481         PR bootstrap/79198
35482         * ipa-prop.c (ipa_free_all_node_params): Call summary destructor.
35483         * ipa-prop.c (ipa_node_params_t::insert): Initialize fields known_csts
35484         and known_contexts.
35486 2017-01-24  Aldy Hernandez  <aldyh@redhat.com>
35488         PR middle-end/79123
35489         * gimple-ssa-warn-alloca.c (alloca_call_type): Make sure
35490         casts from signed to unsigned really don't have a range.
35492 2017-01-24  Markus Trippelsdorf  <markus@trippelsdorf.de>
35494         * gimple-ssa-sprintf.c (format_floating): Change MPFR_RNDx to
35495         GMP_RNDx for compatiblity.
35497 2017-01-24  Martin Liska  <mliska@suse.cz>
35499         PR bootstrap/79132
35500         * tree-ssa-reassoc.c (rewrite_expr_tree_parallel): Insert assert
35501         that would prevent us to call alloca with -1 as argument.
35503 2017-01-24  Jakub Jelinek  <jakub@redhat.com>
35505         * dwarf2out.c (output_compilation_unit_header, output_file_names):
35506         Avoid -Wformat-security warning.
35508 2017-01-23  Andrew Pinski  <apinski@cavium.com>
35510         * config/aarch64/aarch64.c (thunderx2t99_addrcost_table): Improve
35511         cost table.
35513 2017-01-23  Martin Sebor  <msebor@redhat.com>
35515         PR middle-end/78703
35516         * gimple-ssa-sprintf.c (warn_level): New global.
35517         (format_integer): Use it here and throughout the rest of the file.
35518         Use the same switch to compute sign as base.
35519         (maybe_warn): New function.
35520         (format_directive): Factor out warnings into maybe_warn.
35521         Add debugging output.  Use warn_level.
35522         (add_bytes): Use warn_level.
35523         (pass_sprintf_length::compute_format_length): Add debugging output.
35524         (try_substitute_return_value): Same.
35525         (pass_sprintf_length::handle_gimple_call): Set and use warn_level.
35527         PR middle-end/78703
35528         * gimple-ssa-sprintf.c (struct format_result): Remove constant member.
35529         (struct fmtresult, format_integer, format_floating): Adjust.
35530         (fmtresult::fmtresult): Set max correctly in two argument ctor.
35531         (get_string_length, format_string,format_directive): Same.
35532         (pass_sprintf_length::compute_format_length): Same.
35533         (try_substitute_return_value): Simplify slightly.
35535         PR middle-end/78703
35536         * gimple-ssa-sprintf.c (pass_sprintf_length::gate): Adjust formatting.
35537         (fmtresult::operator+=): Outlined.
35538         (struct fmtresult): Add ctors.
35539         (struct conversion_spec): Rename...
35540         (struct directive): ...to this.  Add and remove data members.
35541         (directive::set_width, directive::set_precision): New functions.
35542         (format_percent): Use fmtresult ctor.
35543         (get_width_and_precision): Remove.
35544         (format_integer): Make naming changes.  Avoid computing width and
35545         precision.
35546         (format_floating): Same.  Adjust indentation.
35547         (format_character, format_none): New functions.
35548         (format_string): Moved character handling to format_character.
35549         (format_directive): Remove arguments, change return type.
35550         (parse_directive): New function.
35551         (pass_sprintf_length::compute_format_length): Move directive
35552         parsing to parse_directive.
35554 2017-01-23  Jakub Jelinek  <jakub@redhat.com>
35556         * tree.h (assign_assembler_name_if_neeeded): Rename to ...
35557         (assign_assembler_name_if_needed): ... this.
35558         * tree.c (assign_assembler_name_if_neeeded): Rename to ...
35559         (assign_assembler_name_if_needed): ... this.
35560         (free_lang_data_in_cgraph): Adjust callers.
35561         * cgraphunit.c (cgraph_node::analyze): Likewise.
35562         * omp-expand.c (expand_omp_taskreg, expand_omp_target):
35563         Likewise.
35565 2017-01-23  Richard Biener  <rguenther@suse.de>
35567         PR tree-optimization/79088
35568         PR tree-optimization/79188
35569         * tree-ssa-threadupdate.c (mark_threaded_blocks): Move code
35570         resetting loop bounds after last path deletion.  Reset loop
35571         bounds of the target loop, make code match the comments.
35572         * tree-ssa-threadbackwards.c (pass_early_thread_jumps::execute):
35573         Make sure loops need no fixups.
35575 2017-01-23  Kelvin Nilsen  <kelvin@gcc.gnu.org>
35577         * config/rs6000/rs6000-builtin.def (VSIEDPF): Add scalar insert
35578         exponent support with double type for first argument.
35579         * config/rs6000/rs6000-c.c (altivec_overloaded_builtins): Changed
35580         type returned by __builtin_vec_extract_sig,
35581         __builtin_vec_extract_sig_sp, and __builtin_vec_extract_sig_dp
35582         functions from "vector int" to "vector unsigned int" or from
35583         "vector long long int" to "vector unsigned long long int".
35584         Changed type returned by __builtin_vec_extract_exp,
35585         __builtin_vec_extract_exp_sp, and __builtin_vec_extract_exp_dp
35586         functions from "vector int" to "vector unsigned int" or from
35587         "vector long long int" to "vector unsigned long long int".
35588         Changed return type of __builtin_vec_test_data_class,
35589         __builtin_vec_test_data_class_sp, and
35590         __builtin_vec_test_data_class_dp from "vector int" to
35591         "vector bool int" or from "vector long long int" to "vector bool
35592         long long int" and changed second argument type from "unsigned
35593         int" to "int".  Added new overloaded function forms "vector float
35594         __builtin_vec_insert_exp (vector float, vector unsigned int)" and
35595         "vector float __builtin_vec_insert_exp_sp (vector float, vector
35596         unsigned int)" and "vector double __builtin_vec_insert_exp (vector
35597         double, vector unsigned long long int)" and "vector double
35598         __builtin_vec_insert_exp_dp (vector double, vector unsigned long
35599         long int)".  Changed return type of
35600         __builtin_scalar_test_data_class and
35601         __builtin_scalar_test_data_class_sp and
35602         __builtin_scalar_test_data_class_dp from "unsigned int" to "bool
35603         int" and changed second argument from "unsigned int" to "int".
35604         Changed type returned by __builtin_scalar_test_neg,
35605         __builtin_scalar_test_neg_sp, and __builtin_scalar_test_neg_dp
35606         from "int" to "bool int".  Added new overloaded function form
35607         "double __builtin_scalar_insert_exp (double, unsigned long long int)".
35608         * config/rs6000/vsx.md (xsiexpdpf): New insn for scalar insert
35609         exponent double-precision with floating point first argument.
35610         * doc/extend.texi (PowerPC AltiVec Built-in Functions): Adjust
35611         documentation of scalar_test_data_class, scalar_test_neg,
35612         scalar_extract_sig, scalar_extract_exp, scalar_insert_exp,
35613         vector_extract_exp, vec_extract_sig, vec_insert_exp, and
35614         vec_test_data_class built-in functions to reflect refinements in
35615         their type signatures.
35617 2017-01-23  Andreas Tobler  <andreast@gcc.gnu.org>
35619         * config/aarch64/aarch64.c (aarch64_elf_asm_constructor): Increase
35620         size of buf.
35621         (aarch64_elf_asm_destructor): Likewise.
35623 2017-01-23  Bernd Schmidt  <bschmidt@redhat.com>
35625         PR rtl-optimization/78634
35626         * config/i386/i386.c (ix86_max_noce_ifcvt_seq_cost): New function.
35627         (TARGET_MAX_NOCE_IFCVT_SEQ_COST): Define.
35628         * ifcvt.c (noce_try_cmove): Add missing cost check.
35630         PR rtl-optimization/71724
35631         * combine.c (if_then_else_cond): Look for situations where it is
35632         beneficial to undo the work of one of the recursive calls.
35634 2017-01-23  Bin Cheng  <bin.cheng@arm.com>
35636         PR tree-optimization/70754
35637         * tree-predcom.c (stmt_combining_refs): New parameter INSERT_BEFORE.
35638         (reassociate_to_the_same_stmt): New parameter INSERT_BEFORE.  Insert
35639         combined stmt before it if not NULL.
35640         (combine_chains): Process refs reversely and compute dominance point
35641         for root ref.
35643 2017-01-23  Martin Liska  <mliska@suse.cz>
35645         PR tree-optimization/79196
35646         * tree-ssa-strlen.c (fold_strstr_to_memcmp): Rename to ...
35647         (fold_strstr_to_strncmp): ... this.  Fold the pattern to strncmp
35648         instead of memcmp.
35649         (strlen_optimize_stmt): Call the renamed function.
35651 2017-01-23  Michael Matz  <matz@suse.de>
35653         PR tree-optimization/78384
35654         * tree-ssa-loop-split.c (patch_loop_exit): Use correct edge.
35656 2017-01-23  Richard Biener  <rguenther@suse.de>
35658         PR tree-optimization/79186
35659         * tree-vrp.c (register_new_assert_for): Make sure we've seen
35660         both incoming edges before moving an assert.
35662 2017-01-23  Martin Jambor  <mjambor@suse.cz>
35664         * ipa-prop.c (load_from_param_1): Removed.
35665         (load_from_unmodified_param): Bits from load_from_param_1 put back
35666         here.
35667         (load_from_param): Removed.
35668         (compute_complex_assign_jump_func): Removed stmt2 and just replaced it
35669         with stmt.  Reverted back to use of load_from_unmodified_param.
35671 2017-01-23  Martin Jambor  <mjambor@suse.cz>
35673         PR ipa/79108
35674         * ipa-prop.h (ipa_param_descriptor): Anotate with with GTY(()).
35675         (ipa_node_params): Annotate with GTY((for_user)).  Make descriptors
35676         field a pointer to garbage collected vector, mark lattices and
35677         ipcp_orig_node with GTY((skip)).
35678         (ipa_get_param_count): Adjust to descriptors being a pointer.
35679         (ipa_get_param): Likewise.
35680         (ipa_get_type): Likewise.
35681         (ipa_get_param_move_cost): Likewise.
35682         (ipa_set_param_used): Likewise.
35683         (ipa_get_controlled_uses): Likewise.
35684         (ipa_set_controlled_uses): Likewise.
35685         (ipa_is_param_used): Likewise.
35686         (ipa_node_params_t): Move into garbage collector.  New methods insert
35687         and remove.
35688         (ipa_node_params_sum): Annotate wth GTY(()).
35689         (ipa_check_create_node_params): Adjust to ipa_node_params_sum being
35690         garbage collected.
35691         (ipa_load_from_parm_agg): Adjust declaration.
35692         * ipa-icf.c (param_used_p): Adjust to descriptors being a pointer.
35693         * ipa-profile.c (ipa_profile): Likewise.
35694         * ipa-prop.c (ipa_get_param_decl_index_1): Likewise.
35695         (ipa_populate_param_decls): Make descriptors parameter garbage
35696         collected.
35697         (ipa_dump_param): Adjust to descriptors being a pointer.
35698         (ipa_alloc_node_params): Likewise.
35699         (ipa_initialize_node_params): Likewise.
35700         (load_from_param_1): Make descriptors parameter garbage collected.
35701         (load_from_unmodified_param): Likewise.
35702         (load_from_param): Likewise.
35703         (ipa_load_from_parm_agg): Likewise.
35704         (ipa_node_params::~ipa_node_params): Removed.
35705         (ipa_free_all_node_params): Remove call to delete operator.
35706         (ipa_node_params_t::insert): New.
35707         (ipa_node_params_t::remove): Likewise.
35708         (ipa_node_params_t::duplicate): Adjust to descriptors being a pointer,
35709         copy known_csts and known_contexts vectors.
35710         (ipa_read_node_info): Adjust to descriptors being a pointer.
35711         (ipcp_modif_dom_walker): Make m_descriptors field garbage
35712         collected.
35713         (ipcp_transform_function): Make descriptors variable garbage
35714         collected.
35716 2017-01-23  Andrew Senkevich  <andrew.senkevich@intel.com>
35718         * config/i386/avx512bwintrin.h: Add k-mask test, kortest intrinsics.
35719         * config/i386/avx512dqintrin.h: Ditto.
35720         * config/i386/avx512fintrin.h: Ditto.
35721         * config/i386/i386.c: Handle new builtins.
35722         * config/i386/i386-builtin.def: Add new builtins.
35723         * config/i386/sse.md (ktest<mode>, kortest<mode>): New.
35724         (UNSPEC_KORTEST, UNSPEC_KTEST): New.
35726 2017-01-23  Jakub Jelinek  <jakub@redhat.com>
35727             Martin Liska  <mliska@suse.cz>
35729         * asan.h: Define ASAN_USE_AFTER_SCOPE_ATTRIBUTE.
35730         * asan.c (asan_expand_poison_ifn): Support stores and use
35731         appropriate ASAN report function.
35732         * internal-fn.c (expand_ASAN_POISON_USE): New function.
35733         * internal-fn.def (ASAN_POISON_USE): Declare.
35734         * tree-into-ssa.c (maybe_add_asan_poison_write): New function.
35735         (maybe_register_def): Create ASAN_POISON_USE when sanitizing.
35736         * tree-ssa-dce.c (eliminate_unnecessary_stmts): Remove
35737         ASAN_POISON calls w/o LHS.
35738         * tree-ssa.c (execute_update_addresses_taken): Create clobber
35739         for ASAN_MARK (UNPOISON, &x, ...) in order to prevent usage of a LHS
35740         from ASAN_MARK (POISON, &x, ...) coming to a PHI node.
35741         * gimplify.c (asan_poison_variables): Add attribute
35742         use_after_scope_memory to variables that really needs to live
35743         in memory.
35744         * tree-ssa.c (is_asan_mark_p): Do not rewrite into SSA when
35745         having the attribute.
35747 2017-01-23  Martin Liska  <mliska@suse.cz>
35749         * asan.c (create_asan_shadow_var): New function.
35750         (asan_expand_poison_ifn): Likewise.
35751         * asan.h (asan_expand_poison_ifn): New declaration.
35752         * internal-fn.c (expand_ASAN_POISON): Likewise.
35753         * internal-fn.def (ASAN_POISON): New builtin.
35754         * sanopt.c (pass_sanopt::execute): Expand
35755         asan_expand_poison_ifn.
35756         * tree-inline.c (copy_decl_for_dup_finish): Make function
35757         external.
35758         * tree-inline.h (copy_decl_for_dup_finish): Likewise.
35759         * tree-ssa.c (is_asan_mark_p): New function.
35760         (execute_update_addresses_taken): Rewrite local variables
35761         (identified just by use-after-scope as addressable) into SSA.
35763 2017-01-22  Gerald Pfeifer  <gerald@pfeifer.com>
35765         * doc/install.texi (Specific): opensource.apple.com uses https
35766         now. Remove trailing slash.
35768 2017-01-22  Gerald Pfeifer  <gerald@pfeifer.com>
35770         * README.Portability: Remove note on an Irix compatibility issue.
35772 2017-01-22  Dimitry Andric <dim@FreeBSD.org>
35774         * gcov.c (INCLUDE_ALGORITHM): Define.
35775         (INCLUDE_VECTOR): Define.
35776         No longer include <vector> and <algorithm> directly.
35778 2017-01-21  Gerald Pfeifer  <gerald@pfeifer.com>
35780         * doc/extend.texi (Thread-Local): Change www.akkadia.org reference
35781         to https.
35782         * doc/invoke.texi (Code Gen Options): Ditto.
35784 2017-01-21  Jan Hubicka  <hubicka@ucw.cz>
35786         PR lto/78407
35787         * cfg.c (update_bb_profile_for_threading): Fix updating of probablity.
35789 2017-01-21  Bernd Schmidt  <bschmidt@redhat.com>
35791         rtl-optimization/79125
35792         * cprop.c (local_cprop_pass): Handle cases where we make an
35793         unconditional trap.
35795 2017-01-20  Segher Boessenkool  <segher@kernel.crashing.org>
35797         PR target/61729
35798         PR target/77850
35799         * config/rs6000/rs6000.c (rs6000_gimplify_va_arg): Adjust address to
35800         read from, for big endian.
35802 2017-01-20  Jiong Wang  <jiong.wang@arm.com>
35804         * config/aarch64/aarch64-builtins.c (aarch64_init_builtins): Register
35805         register pauth builtins for LP64 only.
35807 2017-01-20  Marek Polacek  <polacek@redhat.com>
35809         PR c/79152
35810         * gimplify.c (should_warn_for_implicit_fallthrough): Handle consecutive
35811         non-case labels.
35813 2017-01-20  Alexander Monakov  <amonakov@ispras.ru>
35815         * omp-expand.c (expand_omp_simd): Clear PROP_gimple_lomp_dev regardless
35816         of safelen status.
35817         * omp-offload.c (pass_omp_device_lower::gate): Use PROP_gimple_lomp_dev.
35818         * passes.c (dump_properties): Handle PROP_gimple_lomp_dev.
35819         * tree-inline.c (expand_call_inline): Propagate PROP_gimple_lomp_dev.
35821 2017-01-20  Kyrylo Tkachov  <kyrylo.tkachov@arm.com>
35823         PR target/71270
35824         * config/arm/arm.c (neon_valid_immediate): Reject vector constants
35825         in big-endian mode when they are not a single duplicated value.
35827 2017-01-20  Richard Biener  <rguenther@suse.de>
35829         * BASE-VER: Bump to 7.0.1.
35831 2017-01-20  Alexander Monakov  <amonakov@ispras.ru>
35833         * omp-low.c (omplow_simd_context): New struct.  Use it...
35834         (lower_rec_simd_input_clauses): ...here and...
35835         (lower_rec_input_clauses): ...here to hold common data.  Adjust all
35836         references to idx, lane, max_vf, is_simt.
35838 2017-01-20  Graham Markall  <graham.markall@embecosm.com>
35840         * config/arc/arc.h (LINK_SPEC): Use arclinux_nps emulation when
35841         mcpu=nps400.
35843 2017-01-20  Martin Jambor  <mjambor@suse.cz>
35845         * hsa.h: Renaed to hsa-common.h.  Adjusted a comment.
35846         * hsa.c: Renaed to hsa-common.c.  Change include of gt-hsa.h to
35847         gt-hsa-common.h.
35848         * Makefile.in (OBJS): Rename hsa.o to hsa-common.o.
35849         (GTFILES): Rename hsa.c to hsa-common.c.
35850         * hsa-brig.c: Change include of hsa.h to hsa-common.h.
35851         * hsa-dump.c: Likewise.
35852         * hsa-gen.c: Likewise.
35853         * hsa-regalloc.c: Likewise.
35854         * ipa-hsa.c: Likewise.
35855         * omp-expand.c: Likewise.
35856         * omp-low.c: Likewise.
35857         * toplev.c: Likewise.
35859 2017-01-20  Marek Polacek  <polacek@redhat.com>
35861         PR c/64279
35862         * doc/invoke.texi: Document -Wduplicated-branches.
35863         * fold-const.c (operand_equal_p): Handle MODIFY_EXPR, INIT_EXPR,
35864         COMPOUND_EXPR, PREDECREMENT_EXPR, PREINCREMENT_EXPR,
35865         POSTDECREMENT_EXPR, POSTINCREMENT_EXPR, CLEANUP_POINT_EXPR, EXPR_STMT,
35866         STATEMENT_LIST, and RETURN_EXPR.  For non-pure non-const functions
35867         return 0 only when not OEP_LEXICOGRAPHIC.
35868         (fold_build_cleanup_point_expr): Use the expression
35869         location when building CLEANUP_POINT_EXPR.
35870         * tree-core.h (enum operand_equal_flag): Add OEP_LEXICOGRAPHIC.
35871         * tree.c (add_expr): Handle error_mark_node.
35873 2017-01-20  Martin Liska  <mliska@suse.cz>
35875         PR lto/69188
35876         * tree-profile.c (init_ic_make_global_vars): Do not call
35877         finalize_decl.
35878         (gimple_init_gcov_profiler): Likewise.
35880 2017-01-20  Martin Liska  <mliska@suse.cz>
35882         PR ipa/71190
35883         * cgraph.h (maybe_create_reference): Remove argument and
35884         update comment.
35885         * cgraphclones.c (cgraph_node::create_virtual_clone): Remove one
35886         argument.
35887         * ipa-cp.c (create_specialized_node): Likewise.
35888         * symtab.c (symtab_node::maybe_create_reference): Handle
35889         VAR_DECLs and ADDR_EXPRs and select ipa_ref_use type.
35891 2017-01-20  Martin Liska  <mliska@suse.cz>
35893         * read-rtl-function.c (function_reader::create_function): Use
35894         build_decl instread of build_decl_stat.
35896 2017-01-20  Andrew Senkevich  <andrew.senkevich@intel.com>
35898         * config/i386/avx512bwintrin.h: Add k-mask registers shift intrinsics.
35899         * config/i386/avx512dqintrin.h: Ditto.
35900         * config/i386/avx512fintrin.h: Ditto.
35901         * config/i386/i386-builtin-types.def: Add new types.
35902         * config/i386/i386.c: Handle new types.
35903         * config/i386/i386-builtin.def (__builtin_ia32_kshiftliqi)
35904         (__builtin_ia32_kshiftlihi, __builtin_ia32_kshiftlisi)
35905         (__builtin_ia32_kshiftlidi, __builtin_ia32_kshiftriqi)
35906         (__builtin_ia32_kshiftrihi, __builtin_ia32_kshiftrisi)
35907         (__builtin_ia32_kshiftridi): New.
35908         * config/i386/sse.md (k<code><mode>): Rename *k<code><mode>.
35910 2017-01-19  Segher Boessenkool  <segher@kernel.crashing.org>
35912         PR target/78875
35913         PR target/79140
35914         * config/rs6000/rs6000.c (TARGET_STACK_PROTECT_GUARD): Unconditionally
35915         define to rs6000_init_stack_protect_guard.
35916         (rs6000_init_stack_protect_guard): New function.
35918 2017-01-19  Matthew Fortune  <matthew.fortune@imgtec.com>
35919             Yunqiang Su  <yunqiang.su@imgtec.com>
35921         * config.gcc (supported_defaults): Add madd4.
35922         (with_madd4): Add validation.
35923         (all_defaults): Add madd4.
35924         * config/mips/mips.opt (mmadd4): New option.
35925         * config/mips/mips.h (OPTION_DEFAULT_SPECS): Add a default for
35926         mmadd4.
35927         (TARGET_CPU_CPP_BUILTINS): Add builtin_define for
35928         __mips_no_madd4.
35929         (ISA_HAS_UNFUSED_MADD4): Gate with mips_madd4.
35930         (ISA_HAS_FUSED_MADD4): Likewise.
35931         * doc/invoke.texi (-mmadd4): Document the new option.
35932         * doc/install.texi (--with-madd4): Document the new option.
35934 2017-01-19  Jiong Wang  <jiong.wang@arm.com>
35936         * config/aarch64/aarch64-builtins.c (enum aarch64_builtins): New
35937         entries for AARCH64_PAUTH_BUILTIN_XPACLRI,
35938         AARCH64_PAUTH_BUILTIN_PACIA1716, AARCH64_PAUTH_BUILTIN_AUTIA1716.
35939         (aarch64_init_pauth_hint_builtins): New.
35940         (aarch64_init_builtins): Call aarch64_init_pauth_hint_builtins.
35941         (aarch64_expand_builtin): Expand new builtins.
35943 2017-01-19  Jiong Wang  <jiong.wang@arm.com>
35945         * reg-notes.def (CFA_TOGGLE_RA_MANGLE): New reg-note.
35946         * combine-stack-adj.c (no_unhandled_cfa): Handle
35947         REG_CFA_TOGGLE_RA_MANGLE.
35948         * dwarf2cfi.c (dwarf2out_frame_debug): Handle REG_CFA_TOGGLE_RA_MANGLE.
35949         * config/aarch64/aarch64.c (aarch64_expand_prologue): Generates DWARF
35950         info for return address signing.
35951         (aarch64_expand_epilogue): Likewise.
35953 2017-01-19  Jiong Wang  <jiong.wang@arm.com>
35955         * config/aarch64/aarch64-opts.h (aarch64_function_type): New enum.
35956         * config/aarch64/aarch64-protos.h
35957         (aarch64_return_address_signing_enabled): New declaration.
35958         * config/aarch64/aarch64.c (aarch64_return_address_signing_enabled):
35959         New function.
35960         (aarch64_expand_prologue): Sign return address before it's pushed onto
35961         stack.
35962         (aarch64_expand_epilogue): Authenticate return address fetched from
35963         stack.
35964         (aarch64_override_options): Sanity check for ILP32 and ISA level.
35965         (aarch64_attributes): New function attributes for "sign-return-address".
35966         * config/aarch64/aarch64.md (UNSPEC_AUTI1716, UNSPEC_AUTISP,
35967         UNSPEC_PACI1716, UNSPEC_PACISP, UNSPEC_XPACLRI): New unspecs.
35968         ("*do_return"): Generate combined instructions according to key index.
35969         ("<pauth_mnem_prefix>sp", "<pauth_mnem_prefix1716", "xpaclri"): New.
35970         * config/aarch64/iterators.md (PAUTH_LR_SP, PAUTH_17_16): New integer
35971         iterators.
35972         (pauth_mnem_prefix, pauth_hint_num_a): New integer attributes.
35973         * config/aarch64/aarch64.opt (msign-return-address=): New.
35974         * doc/extend.texi (AArch64 Function Attributes): Documents
35975         "sign-return-address=".
35976         * doc/invoke.texi (AArch64 Options): Documents "-msign-return-address=".
35978 2017-01-19  Matthew Fortune  <matthew.fortune@imgtec.com>
35980         * doc/invoke.texi: Add missing -mlxc1-sxc1 options to
35981         overall option summary.
35983 2017-01-19  Jiong Wang  <jiong.wang@arm.com>
35985         * config/aarch64/aarch64-arches.def: New entry for "armv8.3-a".
35986         * config/aarch64/aarch64.h (AARCH64_FL_V8_3, AARCH64_FL_FOR_ARCH8_3,
35987         AARCH64_ISA_V8_3, TARGET_ARMV8_3): New.
35988         * doc/invoke.texi (AArch64 Options): Document "armv8.3-a".
35990 2017-01-19  Michael Meissner  <meissner@linux.vnet.ibm.com>
35992         * config/rs6000/rs6000-cpus.def (ISA_3_0_MASKS_SERVER): Enable
35993         -mpower9-minmax by default for -mcpu=power9.
35994         (ISA_3_MASKS_IEEE): Require -mvsx-small-integer to enable IEEE
35995         128-bit floating point.
35997 2017-01-20  Alan Modra  <amodra@gmail.com>
35999         * config/rs6000/rs6000.md (cmpstrnsi, cmpstrsi): Fail if
36000         optimizing for size.
36002 2017-01-20  Alan Modra  <amodra@gmail.com>
36004         PR target/79144
36005         * config/rs6000/rs6000.c (expand_strn_compare): Get the asm name
36006         for strcmp and strncmp from corresponding builtin decl.
36008 2017-01-19  Uros Bizjak  <ubizjak@gmail.com>
36010         * config.gcc (x86_64-*-rtems*): Use i386/rtemself.h
36011         instead of i386/rtems-64.h.
36012         * config/i386/rtems-64.h: Remove.
36014 2017-01-19  Uros Bizjak  <ubizjak@gmail.com>
36016         PR target/78478
36017         Revert:
36018         2013-11-05  Uros Bizjak  <ubizjak@gmail.com>
36020         * config/i386/rtemself.h (LONG_DOUBLE_TYPE_SIZE): New define.
36022 2017-01-19  Tamar Christina  <tamar.christina@arm.com>
36024         * config/aarch64/aarch64.c (aarch64_simd_gen_const_vector_dup):
36025         Change int to HOST_WIDE_INT.
36026         * config/aarch64/aarch64-protos.h
36027         (aarch64_simd_gen_const_vector_dup): Likewise.
36028         * config/aarch64/aarch64-simd.md: Add copysign<mode>3.
36030 2017-01-19  David Malcolm  <dmalcolm@redhat.com>
36032         * langhooks-def.h (lhd_type_for_size): New decl.
36033         (LANG_HOOKS_TYPE_FOR_SIZE): Define as lhd_type_for_size.
36034         * langhooks.c (lhd_type_for_size): New function, taken from
36035         lto_type_for_size.
36037 2017-01-19  Pat Haugen  <pthaugen@us.ibm.com>
36039         * config/rs6000/power9.md (power9-alu): Remove 'cmp' type and add
36040         define_bypass for CR latency.
36041         (power9-cracked-alu): Update bypass latency and remove power9-branch.
36042         (power9-alu2): Add define_bypass for CR latency.
36043         (power9-cmp): New.
36044         (power9-mul): Update insn latency.
36045         (power9-mul-compare): Update insn latency, bypass latency and remove
36046         power9-branch.
36048 2016-01-19  Kyrylo Tkachov  <kyrylo.tkachov@arm.com>
36050         * config/aarch64/aarch64-protos.h (aarch64_nopcrelative_literal_loads):
36051         Delete.
36052         * config/aarch64/aarch64.md
36053         (aarch64_reload_movcp<GPF_TF:mode><P:mode>): Delete reference to
36054         aarch64_nopcrelative_literal_loads.
36055         (aarch64_reload_movcp<VALL:mode><P:mode>): Likewise.
36057 2017-01-19  Chenghua Xu  <paul.hua.gm@gmail.com>
36059         * config/mips/mips.h (ISA_HAS_FUSED_MADD4): Enable for
36060         TARGET_LOONGSON_3A.
36061         (ISA_HAS_UNFUSED_MADD4): Exclude TARGET_LOONGSON_3A.
36063 2017-01-19  Doug Gilmore  <doug.gilmore@imgtec.com>
36065         PR target/78176
36066         * config.gcc (supported_defaults): Add lxc1-sxc1.
36067         (with_lxc1_sxc1): Add validation.
36068         (all_defaults): Add lxc1-sxc1.
36069         * config/mips/mips.opt (mlxc1-sxc1): New option.
36070         * config/mips/mips.h (OPTION_DEFAULT_SPECS): Add a default for
36071         mlxc1-sxc1.
36072         (TARGET_CPU_CPP_BUILTINS): Add builtin_define for
36073         __mips_no_lxc1_sxc1.
36074         (ISA_HAS_LXC1_SXC1): Gate with mips_lxc1_sxc1.
36075         * doc/invoke.texi (-mlxc1-sxc1): Document the new option.
36076         * doc/install.texi (--with-lxc1-sxc1): Document the new option.
36078 2017-01-19  Richard Biener  <rguenther@suse.de>
36080         PR tree-optimization/72488
36081         * tree-ssa-sccvn.c (run_scc_vn): When we abort the VN make
36082         sure to restore SSA info.
36083         * tree-ssa.c (verify_ssa): Verify SSA info is not shared.
36085 2017-01-19  Richard Earnshaw  <rearnsha@arm.com>
36087         PR rtl-optimization/79121
36088         * expr.c (expand_expr_real_2, case LSHIFT_EXPR): Look at the signedness
36089         of the inner type when shifting an extended value.
36091 2017-01-17  Jan Hubicka  <hubicka@ucw.cz>
36093         PR lto/78407
36094         * symtab.c (symtab_node::equal_address_to): Fix comparing of
36095         interposable aliases.
36097 2017-01-18  Peter Bergner  <bergner@vnet.ibm.com>
36099         PR target/78516
36100         * config/rs6000/spe.md (mov_si<mode>_e500_subreg0): Fix constraints.
36101         Use the evmergelohi instruction.
36102         (mov_si<mode>_e500_subreg4_2_le): Likewise.
36103         (mov_sitf_e500_subreg8_2_be): Likewise.
36104         (mov_sitf_e500_subreg12_2_le): Likewise.
36105         (mov_si<mode>_e500_subreg0_2_le): Fix constraints.
36106         (mov_si<mode>_e500_subreg4_2_be): Likewise.
36107         (mov_sitf_e500_subreg8_2_le): Likewise.
36108         (mov_sitf_e500_subreg12_2_be): Likewise.
36110 2017-01-18  Bill Schmidt  <wschmidt@linux.vnet.ibm.com>
36112         * config/rs6000/altivec.md (altivec_vbpermq): Change "type"
36113         attribute from vecsimple to vecperm.
36114         (altivec_vbpermq2): Likewise.
36116 2017-01-18  Bill Schmidt  <wschmidt@linux.vnet.ibm.com>
36118         PR target/79040
36119         * config/rs6000/altivec.h: Fix typo of vec_cntlz to vec_cnttz.
36121 2017-01-18  Aaron Sawdey  <acsawdey@linux.vnet.ibm.com>
36122         * config/rs6000/rs6000-protos.h (expand_strn_compare): Add arg.
36123         * config/rs6000/rs6000.c (expand_strn_compare): Add ability to expand
36124         strcmp. Fix bug where comparison didn't stop with zero byte. Fix
36125         case where N arg is SIZE_MAX.
36126         * config/rs6000/rs6000.md (cmpstrnsi): Args to expand_strn_compare.
36127         (cmpstrsi): Add pattern.
36129 2017-01-18  Michael Meissner  <meissner@linux.vnet.ibm.com>
36131         * config/rs6000/rs6000-c.c (altivec_overloaded_builtins): Add
36132         __builtin_vec_revb builtins.
36133         * config/rs6000/rs6000-builtins.def (P9V_BUILTIN_XXBRQ_V16QI): Add
36134         built-in functions to support generation of the ISA 3.0 XXBR<x>
36135         vector byte reverse instructions.
36136         (P9V_BUILTIN_XXBRQ_V1TI): Likewise.
36137         (P9V_BUILTIN_XXBRD_V2DI): Likewise.
36138         (P9V_BUILTIN_XXBRD_V2DF): Likewise.
36139         (P9V_BUILTIN_XXBGW_V4SI): Likewise.
36140         (P9V_BUILTIN_XXBGW_V4SF): Likewise.
36141         (P9V_BUILTIN_XXBGH_V8HI): Likewise.
36142         (P9V_BUILTIN_VEC_REVB): Likewise.
36143         * config/rs6000/vsx.md (p9_xxbrq_v1ti): New insns/expanders to
36144         generate the ISA 3.0 XXBR<x> vector byte reverse instructions.
36145         (p9_xxbrq_v16qi): Likewise.
36146         (p9_xxbrd_<mode>, VSX_D iterator): Likewise.
36147         (p9_xxbrw_<mode>, VSX_W iterator): Likewise.
36148         (p9_xxbrh_v8hi): Likewise.
36149         * config/rs6000/altivec.h (vec_revb): Define if ISA 3.0.
36150         * doc/extend.texi (RS/6000 Altivec Built-ins): Document the
36151         vec_revb built-in functions.
36153 2017-01-18  Uros Bizjak  <ubizjak@gmail.com>
36155         PR rtl-optimization/78952
36156         * config/i386/i386.md (any_extract): New code iterator.
36157         (*insvqi_2): Use any_extract for source operand.
36158         (*insvqi_3): Use any_shiftrt for source operand.
36160 2017-01-18  Wilco Dijkstra  <wdijkstr@arm.com>
36162         * config/aarch64/aarch64.c (aarch64_sched_adjust_priority)
36163         New function.
36164         (TARGET_SCHED_ADJUST_PRIORITY): Define target hook.
36166 2017-01-18  Matthias Klose  <doko@ubuntu.com>
36168         * doc/install.texi: Allow default for --with-target-bdw-gc-include.
36170 2016-01-18  Bill Schmidt  <wschmidt@linux.vnet.ibm.com>
36172         * config/rs6000/altivec.h (vec_bperm): Change #define.
36173         * config/rs6000/altivec.md (UNSPEC_VBPERMD): New enum constant.
36174         (altivec_vbpermq2): New define_insn.
36175         (altivec_vbpermd): Likewise.
36176         * config/rs6000/rs6000-builtin.def (VBPERMQ2): New monomorphic
36177         function interface.
36178         (VBPERMD): Likewise.
36179         (VBPERM): New polymorphic function interface.
36180         * config/rs6000/r6000-c.c (altivec_overloaded_builtins_table):
36181         Add entries for P9V_BUILTIN_VEC_VBPERM.
36182         * doc/extend.texi: Add interfaces for vec_bperm.
36184 2017-01-18  Andreas Krebbel  <krebbel@linux.vnet.ibm.com>
36186         * config/s390/s390-c.c (s390_expand_overloaded_builtin): Downcase
36187         first letter of error messages.
36188         (s390_resolve_overloaded_builtin): Likewise.
36189         * config/s390/s390.c (s390_expand_builtin): Likewise.
36190         (s390_invalid_arg_for_unprototyped_fn): Likewise.
36191         (s390_valid_target_attribute_inner_p): Likewise.
36192         * config/s390/s390.md ("tabort"): Likewise.
36194 2017-01-18  Toma Tabacu  <toma.tabacu@imgtec.com>
36196         * config/mips/mips.h (ISA_HAS_DIV3): Remove unused macro.
36197         (ISA_AVOID_DIV_HILO): New macro.
36198         (ISA_HAS_DIV): Use new ISA_AVOID_DIV_HILO macro.
36199         (ISA_HAS_DDIV): Likewise.
36201 2017-01-18  Markus Trippelsdorf  <markus@trippelsdorf.de>
36203         * doc/invoke.texi (fabi-version): Correct number of occurrences.
36205 2017-01-18  Markus Trippelsdorf  <markus@trippelsdorf.de>
36207         * doc/invoke.texi (fabi-version): Spelling fix.
36209 2017-01-18  Markus Trippelsdorf  <markus@trippelsdorf.de>
36211         PR c++/70182
36212         * doc/invoke.texi (fabi-version): Mention mangling fix for
36213         operator names.
36215 2017-01-18  Markus Trippelsdorf  <markus@trippelsdorf.de>
36217         PR c++/77489
36218         * doc/invoke.texi (fabi-version): Document discriminator mangling.
36220 2017-01-17  Segher Boessenkool  <segher@kernel.crashing.org>
36222         PR target/78875
36223         * config/rs6000/rs6000-opts.h (stack_protector_guard): New enum.
36224         * config/rs6000/rs6000.c (rs6000_option_override_internal): Handle
36225         the new options.
36226         * config/rs6000/rs6000.md (stack_protect_set): Handle the new more
36227         flexible settings.
36228         (stack_protect_test): Ditto.
36229         * config/rs6000/rs6000.opt (mstack-protector-guard=,
36230         mstack-protector-guard-reg=, mstack-protector-guard-offset=): New
36231         options.
36232         * doc/invoke.texi (Option Summary) [RS/6000 and PowerPC Options]:
36233         Add -mstack-protector-guard=, -mstack-protector-guard-reg=, and
36234         -mstack-protector-guard-offset=.
36235         (RS/6000 and PowerPC Options): Ditto.
36237 2017-01-17  Uros Bizjak  <ubizjak@gmail.com>
36239         * config/i386/i386.h (MASK_CLASS_P): New define.
36240         * config/i386/i386.c (inline_secondary_memory_needed): Ensure that
36241         there are no registers from different register sets also when
36242         mask registers are used.  Update function comment.
36243         * config/i386/i386.md (*movsi_internal): Split (*k/*krm) alternative
36244         to (*k/*r) and (*k/*km) alternatives.
36246 2017-01-17  Wilco Dijkstra  <wdijkstr@arm.com>
36248         * config/aarch64/aarch64.md (eh_return): Remove pattern and splitter.
36249         * config/aarch64/aarch64.h (AARCH64_EH_STACKADJ_REGNUM): Remove.
36250         (EH_RETURN_HANDLER_RTX): New define.
36251         * config/aarch64/aarch64.c (aarch64_frame_pointer_required):
36252         Force frame pointer in EH return functions.
36253         (aarch64_expand_epilogue): Add barrier for eh_return.
36254         (aarch64_final_eh_return_addr): Remove.
36255         (aarch64_eh_return_handler_rtx): New function.
36256         * config/aarch64/aarch64-protos.h (aarch64_final_eh_return_addr):
36257         Remove.
36258         (aarch64_eh_return_handler_rtx): New prototype.
36260 2017-01-17  Bill Schmidt  <wschmidt@linux.vnet.ibm.com>
36262         * config/rs6000/altivec.h (vec_rlmi): New #define.
36263         (vec_vrlnm): Likewise.
36264         (vec_rlnm): Likewise.
36265         * config/rs6000/altivec.md (UNSPEC_VRLMI): New UNSPEC enum value.
36266         (UNSPEC_VRLNM): Likewise.
36267         (VIlong): New mode iterator.
36268         (altivec_vrl<VI_char>mi): New define_insn.
36269         (altivec_vrl<VI_char>nm): Likewise.
36270         * config/rs6000/rs6000-builtin.def (VRLWNM): New monomorphic
36271         function entry.
36272         (VRLDNM): Likewise.
36273         (RLNM): New polymorphic function entry.
36274         (VRLWMI): New monomorphic function entry.
36275         (VRLDMI): Likewise.
36276         (RLMI): New polymorphic function entry.
36277         * config/rs6000/r6000-c.c (altivec_overloaded_builtin_table): Add
36278         new entries for P9V_BUILTIN_VEC_RLMI and P9V_BUILTIN_VEC_RLNM.
36279         * doc/extend.texi: Add description of vec_rlmi, vec_rlnm, and
36280         vec_vrlnm.
36282 2017-01-17  Jakub Jelinek  <jakub@redhat.com>
36284         PR debug/78839
36285         * dwarf2out.c (field_byte_offset): Restore the
36286         PCC_BITFIELD_TYPE_MATTERS behavior for INTEGER_CST DECL_FIELD_OFFSET
36287         and DECL_FIELD_BIT_OFFSET.  Use fold_build2 instead of build2 + fold.
36288         (analyze_variants_discr, gen_variant_part): Use fold_build2 instead
36289         of build2 + fold.
36291 2017-01-17  Eric Botcazou  <ebotcazou@adacore.com>
36293         PR ada/67205
36294         * config/aarch64/aarch64.c (TARGET_CUSTOM_FUNCTION_DESCRIPTORS): Define
36296 2017-01-17  Jakub Jelinek  <jakub@redhat.com>
36298         PR debug/71669
36299         * dwarf2out.c (add_data_member_location_attribute): For constant
36300         offset bitfield emit for -gdwarf-5 DW_AT_data_bit_offset attribute
36301         instead of DW_AT_data_member_location, DW_AT_bit_offset and
36302         DW_AT_byte_size attributes.
36304 2017-01-17  Eric Botcazou  <ebotcazou@adacore.com>
36306         * config/rs6000/rs6000.c (rs6000_emit_move): Also use a TOC reference
36307         after forcing to constant memory when the code model is medium.
36309 2017-01-17  Julia Koval  <julia.koval@intel.com>
36311         PR target/76731
36312         * config/i386/avx512fintrin.h
36313         (_mm512_i32gather_ps): Change __addr type to void const*.
36314         (_mm512_mask_i32gather_ps): Ditto.
36315         (_mm512_i32gather_pd): Ditto.
36316         (_mm512_mask_i32gather_pd): Ditto.
36317         (_mm512_i64gather_ps): Ditto.
36318         (_mm512_mask_i64gather_ps): Ditto.
36319         (_mm512_i64gather_pd): Ditto.
36320         (_mm512_mask_i64gather_pd): Ditto.
36321         (_mm512_i32gather_epi32): Ditto.
36322         (_mm512_mask_i32gather_epi32): Ditto.
36323         (_mm512_i32gather_epi64): Ditto.
36324         (_mm512_mask_i32gather_epi64): Ditto.
36325         (_mm512_i64gather_epi32): Ditto.
36326         (_mm512_mask_i64gather_epi32): Ditto.
36327         (_mm512_i64gather_epi64): Ditto.
36328         (_mm512_mask_i64gather_epi64): Ditto.
36329         (_mm512_i32scatter_ps): Change __addr type to void*.
36330         (_mm512_mask_i32scatter_ps): Ditto.
36331         (_mm512_i32scatter_pd): Ditto.
36332         (_mm512_mask_i32scatter_pd): Ditto.
36333         (_mm512_i64scatter_ps): Ditto.
36334         (_mm512_mask_i64scatter_ps): Ditto.
36335         (_mm512_i64scatter_pd): Ditto.
36336         (_mm512_mask_i64scatter_pd): Ditto.
36337         (_mm512_i32scatter_epi32): Ditto.
36338         (_mm512_mask_i32scatter_epi32): Ditto.
36339         (_mm512_i32scatter_epi64): Ditto.
36340         (_mm512_mask_i32scatter_epi64): Ditto.
36341         (_mm512_i64scatter_epi32): Ditto.
36342         (_mm512_mask_i64scatter_epi32): Ditto.
36343         (_mm512_i64scatter_epi64): Ditto.
36344         (_mm512_mask_i64scatter_epi64): Ditto.
36345         * config/i386/avx512pfintrin.h
36346         (_mm512_mask_prefetch_i32gather_pd): Change __addr type to void const*.
36347         (_mm512_mask_prefetch_i32gather_ps): Ditto.
36348         (_mm512_mask_prefetch_i64gather_pd): Ditto.
36349         (_mm512_mask_prefetch_i64gather_ps): Ditto.
36350         (_mm512_prefetch_i32scatter_pd): Change __addr type to void*.
36351         (_mm512_prefetch_i32scatter_ps): Ditto.
36352         (_mm512_mask_prefetch_i32scatter_pd): Ditto.
36353         (_mm512_mask_prefetch_i32scatter_ps): Ditto.
36354         (_mm512_prefetch_i64scatter_pd): Ditto.
36355         (_mm512_prefetch_i64scatter_ps): Ditto.
36356         (_mm512_mask_prefetch_i64scatter_pd): Ditto.
36357         (_mm512_mask_prefetch_i64scatter_ps): Ditto.
36358         * config/i386/avx512vlintrin.h
36359         (_mm256_mmask_i32gather_ps): Change __addr type to void const*.
36360         (_mm_mmask_i32gather_ps): Ditto.
36361         (_mm256_mmask_i32gather_pd): Ditto.
36362         (_mm_mmask_i32gather_pd): Ditto.
36363         (_mm256_mmask_i64gather_ps): Ditto.
36364         (_mm_mmask_i64gather_ps): Ditto.
36365         (_mm256_mmask_i64gather_pd): Ditto.
36366         (_mm_mmask_i64gather_pd): Ditto.
36367         (_mm256_mmask_i32gather_epi32): Ditto.
36368         (_mm_mmask_i32gather_epi32): Ditto.
36369         (_mm256_mmask_i32gather_epi64): Ditto.
36370         (_mm_mmask_i32gather_epi64): Ditto.
36371         (_mm256_mmask_i64gather_epi32): Ditto.
36372         (_mm_mmask_i64gather_epi32): Ditto.
36373         (_mm256_mmask_i64gather_epi64): Ditto.
36374         (_mm_mmask_i64gather_epi64): Ditto.
36375         (_mm256_i32scatter_ps): Change __addr type to void*.
36376         (_mm256_mask_i32scatter_ps): Ditto.
36377         (_mm_i32scatter_ps): Ditto.
36378         (_mm_mask_i32scatter_ps): Ditto.
36379         (_mm256_i32scatter_pd): Ditto.
36380         (_mm256_mask_i32scatter_pd): Ditto.
36381         (_mm_i32scatter_pd): Ditto.
36382         (_mm_mask_i32scatter_pd): Ditto.
36383         (_mm256_i64scatter_ps): Ditto.
36384         (_mm256_mask_i64scatter_ps): Ditto.
36385         (_mm_i64scatter_ps): Ditto.
36386         (_mm_mask_i64scatter_ps): Ditto.
36387         (_mm256_i64scatter_pd): Ditto.
36388         (_mm256_mask_i64scatter_pd): Ditto.
36389         (_mm_i64scatter_pd): Ditto.
36390         (_mm_mask_i64scatter_pd): Ditto.
36391         (_mm256_i32scatter_epi32): Ditto.
36392         (_mm256_mask_i32scatter_epi32): Ditto.
36393         (_mm_i32scatter_epi32): Ditto.
36394         (_mm_mask_i32scatter_epi32): Ditto.
36395         (_mm256_i32scatter_epi64): Ditto.
36396         (_mm256_mask_i32scatter_epi64): Ditto.
36397         (_mm_i32scatter_epi64): Ditto.
36398         (_mm_mask_i32scatter_epi64): Ditto.
36399         (_mm256_i64scatter_epi32): Ditto.
36400         (_mm256_mask_i64scatter_epi32): Ditto.
36401         (_mm_i64scatter_epi32): Ditto.
36402         (_mm_mask_i64scatter_epi32): Ditto.
36403         (_mm256_i64scatter_epi64): Ditto.
36404         (_mm256_mask_i64scatter_epi64): Ditto.
36405         (_mm_i64scatter_epi64): Ditto.
36406         (_mm_mask_i64scatter_epi64): Ditto.
36407         * config/i386/i386-builtin-types.def (V16SF_V16SF_PCFLOAT_V16SI_HI_INT)
36408         (V8DF_V8DF_PCDOUBLE_V8SI_QI_INT, V8SF_V8SF_PCFLOAT_V8DI_QI_INT)
36409         (V8DF_V8DF_PCDOUBLE_V8DI_QI_INT, V16SI_V16SI_PCINT_V16SI_HI_INT)
36410         (V8DI_V8DI_PCINT64_V8SI_QI_INT, V8SI_V8SI_PCINT_V8DI_QI_INT)
36411         (V8DI_V8DI_PCINT64_V8DI_QI_INT, V2DF_V2DF_PCDOUBLE_V4SI_QI_INT)
36412         (V4DF_V4DF_PCDOUBLE_V4SI_QI_INT, V2DF_V2DF_PCDOUBLE_V2DI_QI_INT)
36413         (V4DF_V4DF_PCDOUBLE_V4DI_QI_INT, V4SF_V4SF_PCFLOAT_V4SI_QI_INT)
36414         (V8SF_V8SF_PCFLOAT_V8SI_QI_INT, V4SF_V4SF_PCFLOAT_V2DI_QI_INT)
36415         (V4SF_V4SF_PCFLOAT_V4DI_QI_INT, V2DI_V2DI_PCINT64_V4SI_QI_INT)
36416         (V4DI_V4DI_PCINT64_V4SI_QI_INT, V2DI_V2DI_PCINT64_V2DI_QI_INT)
36417         (V4DI_V4DI_PCINT64_V4DI_QI_INT, V4SI_V4SI_PCINT_V4SI_QI_INT)
36418         (V8SI_V8SI_PCINT_V8SI_QI_INT, V4SI_V4SI_PCINT_V2DI_QI_INT)
36419         (V4SI_V4SI_PCINT_V4DI_QI_INT, VOID_PFLOAT_HI_V16SI_V16SF_INT)
36420         (VOID_PFLOAT_QI_V8SI_V8SF_INT, VOID_PFLOAT_QI_V4SI_V4SF_INT)
36421         (VOID_PDOUBLE_QI_V8SI_V8DF_INT, VOID_PDOUBLE_QI_V4SI_V4DF_INT)
36422         (VOID_PDOUBLE_QI_V4SI_V2DF_INT, VOID_PFLOAT_QI_V8DI_V8SF_INT)
36423         (VOID_PFLOAT_QI_V4DI_V4SF_INT, VOID_PFLOAT_QI_V2DI_V4SF_INT)
36424         (VOID_PDOUBLE_QI_V8DI_V8DF_INT, VOID_PDOUBLE_QI_V4DI_V4DF_INT)
36425         (VOID_PDOUBLE_QI_V2DI_V2DF_INT, VOID_PINT_HI_V16SI_V16SI_INT)
36426         (VOID_PINT_QI_V8SI_V8SI_INT, VOID_PINT_QI_V4SI_V4SI_INT)
36427         (VOID_PLONGLONG_QI_V8SI_V8DI_INT, VOID_PLONGLONG_QI_V4SI_V4DI_INT)
36428         (VOID_PLONGLONG_QI_V4SI_V2DI_INT, VOID_PINT_QI_V8DI_V8SI_INT)
36429         (VOID_PINT_QI_V4DI_V4SI_INT, VOID_PINT_QI_V2DI_V4SI_INT)
36430         (VOID_PLONGLONG_QI_V8DI_V8DI_INT, VOID_QI_V8SI_PCINT64_INT_INT)
36431         (VOID_PLONGLONG_QI_V4DI_V4DI_INT, VOID_PLONGLONG_QI_V2DI_V2DI_INT)
36432         (VOID_HI_V16SI_PCINT_INT_INT, VOID_QI_V8DI_PCINT64_INT_INT)
36433         (VOID_QI_V8DI_PCINT_INT_INT): Remove.
36434         (V16SF_V16SF_PCVOID_V16SI_HI_INT,  V8DF_V8DF_PCVOID_V8SI_QI_INT)
36435         (V8SF_V8SF_PCVOID_V8DI_QI_INT, V8DF_V8DF_PCVOID_V8DI_QI_INT)
36436         (V16SI_V16SI_PCVOID_V16SI_HI_INT, V8DI_V8DI_PCVOID_V8SI_QI_INT)
36437         (V8SI_V8SI_PCVOID_V8DI_QI_INT, V8DI_V8DI_PCVOID_V8DI_QI_INT)
36438         (VOID_PVOID_HI_V16SI_V16SF_INT, VOID_PVOID_QI_V8SI_V8DF_INT)
36439         (VOID_PVOID_QI_V8DI_V8SF_INT, VOID_PVOID_QI_V8DI_V8DF_INT)
36440         (VOID_PVOID_HI_V16SI_V16SI_INT, VOID_PVOID_QI_V8SI_V8DI_INT)
36441         (VOID_PVOID_QI_V8DI_V8SI_INT, VOID_PVOID_QI_V8DI_V8DI_INT)
36442         (V2DF_V2DF_PCVOID_V4SI_QI_INT, V4DF_V4DF_PCVOID_V4SI_QI_INT)
36443         (V2DF_V2DF_PCVOID_V2DI_QI_INT, V4DF_V4DF_PCVOID_V4DI_QI_INT
36444         (V4SF_V4SF_PCVOID_V4SI_QI_INT, V8SF_V8SF_PCVOID_V8SI_QI_INT)
36445         (V4SF_V4SF_PCVOID_V2DI_QI_INT, V4SF_V4SF_PCVOID_V4DI_QI_INT)
36446         (V2DI_V2DI_PCVOID_V4SI_QI_INT, V4DI_V4DI_PCVOID_V4SI_QI_INT)
36447         (V2DI_V2DI_PCVOID_V2DI_QI_INT, V4DI_V4DI_PCVOID_V4DI_QI_INT)
36448         (V4SI_V4SI_PCVOID_V4SI_QI_INT, V8SI_V8SI_PCVOID_V8SI_QI_INT)
36449         (V4SI_V4SI_PCVOID_V2DI_QI_INT, V4SI_V4SI_PCVOID_V4DI_QI_INT)
36450         (VOID_PVOID_QI_V8SI_V8SF_INT, VOID_PVOID_QI_V4SI_V4SF_INT)
36451         (VOID_PVOID_QI_V4SI_V4DF_INT, VOID_PVOID_QI_V4SI_V2DF_INT)
36452         (VOID_PVOID_QI_V4DI_V4SF_INT, VOID_PVOID_QI_V2DI_V4SF_INT)
36453         (VOID_PVOID_QI_V4DI_V4DF_INT, VOID_PVOID_QI_V2DI_V2DF_INT)
36454         (VOID_PVOID_QI_V8SI_V8SI_INT, VOID_PVOID_QI_V4SI_V4SI_INT)
36455         (VOID_PVOID_QI_V4SI_V4DI_INT, VOID_PVOID_QI_V4SI_V2DI_INT)
36456         (VOID_PVOID_QI_V4DI_V4SI_INT, VOID_PVOID_QI_V2DI_V4SI_INT)
36457         (VOID_PVOID_QI_V4DI_V4DI_INT, VOID_PVOID_QI_V2DI_V2DI_INT)
36458         (VOID_QI_V8SI_PCVOID_INT_INT, VOID_HI_V16SI_PCVOID_INT_INT)
36459         (VOID_QI_V8DI_PCVOID_INT_INT): Add.
36460         * config/i386/i386.c (ix86_init_mmx_sse_builtins): Adjust builtin
36461         definitions accordingly.
36463 2017-01-17  Kito Cheng  <kito.cheng@gmail.com>
36464             Kuan-Lin Chen  <kuanlinchentw@gmail.com>
36466         PR target/79079
36467         * internal-fn.c (expand_mul_overflow): Use convert_modes instead of
36468         gen_lowpart.
36470 2017-01-17  Vladimir Makarov  <vmakarov@redhat.com>
36472         PR target/79058
36473         * ira-conflicts.c (ira_build_conflicts): Update total conflict
36474         hard regs for inner regno.
36476 2017-01-17  Martin Liska  <mliska@suse.cz>
36478         PR ipa/71207
36479         * ipa-polymorphic-call.c (contains_type_p): Fix wrong
36480         assumption and add comment.
36482 2017-01-17  Nathan Sidwell  <nathan@acm.org>
36484         * ipa-visibility.c (localize_node): New function, broken out of ...
36485         (function_and_variable_visibility): ... here. Call it.
36487 2017-01-17  Jan Hubicka  <hubicka@ucw.cz>
36489         PR middle-end/77445
36490         * tree-ssa-threadupdate.c (remove_ctrl_stmt_and_useless_edges):
36491         correctly set frequency of oudgoing edge.
36492         (duplicate_thread_path): Fix profile updating.
36494 2017-01-17  Jakub Jelinek  <jakub@redhat.com>
36496         PR other/79046
36497         * configure.ac: Add GCC_BASE_VER.
36498         * Makefile.in (version): Use @get_gcc_base_ver@ instead of cat to get
36499         version from BASE-VER file.
36500         (CFLAGS-gcc.o): Add -DBASEVER=$(BASEVER_s).
36501         (gcc.o): Depend on $(BASEVER).
36502         * common.opt (dumpfullversion): New option.
36503         * gcc.c (driver_handle_option): Handle OPT_dumpfullversion.
36504         * doc/invoke.texi: Document -dumpfullversion.
36505         * doc/install.texi: Document --with-gcc-major-version-only.
36506         * configure: Regenerated.
36508 2017-01-17  Richard Biener  <rguenther@suse.de>
36510         PR tree-optimization/71433
36511         * tree-vrp.c (register_new_assert_for): Merge same asserts
36512         on all incoming edges.
36513         (process_assert_insertions_for): Handle insertions at the
36514         beginning of BBs.
36516 2017-01-17  Gerald Pfeifer  <gerald@pfeifer.com>
36518         * config/i386/cygwin.h (LIBGCJ_SONAME): Remove.
36519         * config/i386/mingw32.h (LIBGCJ_SONAME): Remove.
36521 2017-01-17  Kaz Kojima  <kkojima@gcc.gnu.org>
36523         PR target/78633
36524         * config/sh/sh.md (cmpeqsi_t+1): Call copy_rtx to avoid invalid
36525         RTL sharing.
36527 2017-01-17  Alan Modra  <amodra@gmail.com>
36529         PR target/79066
36530         * config/rs6000/rs6000.md (elf_high, elf_low): Disable when pic.
36531         * config/rs6000/rs6000.c (rs6000_emit_allocate_stack): Don't allow
36532         symbolic stack limit when pic.
36534 2017-01-16  Martin Sebor  <msebor@redhat.com>
36536         PR tree-optimization/78608
36537         * gimple-ssa-sprintf.c (tree_digits): Avoid negating TYPE_MIN.
36539 2017-01-16  Jeff Law  <law@redhat.com>
36541         Revert:
36542         2016-12-02  Tadek Kijkowski  <tkijkowski@gmail.com>
36543         * Makefile.in (PREPROCESSOR_DEFINES): Add a level of indirection
36544         for several include directories that may be relative to sysroot.
36545         * config/i386/x-mingw32 (gplus_includedir): Define.
36546         (gplus_tool_includedir, gplus_backward_include_dir): Likewise.
36547         (native_system_includedir): Likewise.
36548         * config/i386/mingw32.h (STANDARD_STARTFILE_PREFIX_1): Do not
36549         override if TARGET_SYSTEM_ROOT is defined.
36550         (NATIVE_SYSTEM_HEADER_DIR): Likewise.
36552         PR tree-optimization/79090
36553         PR tree-optimization/33562
36554         PR tree-optimization/61912
36555         PR tree-optimization/77485
36556         * tree-ssa-dse.c (compute_trims): Accept STMT argument.  Dump STMT
36557         and computed trims into the dump file.
36559 2017-01-17  Uros Bizjak  <ubizjak@gmail.com>
36561         * config/i386/i386.h (LIMIT_RELOAD_CLASS): Remove.
36563 2017-01-16  Jakub Jelinek  <jakub@redhat.com>
36565         PR c/79089
36566         * gimplify.c (gimplify_init_constructor): If want_value and
36567         object == lhs, unshare lhs to avoid invalid tree sharing.  Formatting
36568         fix.
36570         PR target/79080
36571         * loop-doloop.c (doloop_modify): Call unshare_all_rtl_in_chain on
36572         sequence.  Formatting fixes.
36573         (doloop_optimize): Formatting fixes.
36575         PR driver/49726
36576         * gcc.c (debug_level_greater_than_spec_func): New function.
36577         (static_spec_functions): Add debug-level-gt spec function.
36578         (ASM_DEBUG_SPEC, cpp_options): Use %:debug-level-gt(0) instead of
36579         !g0.
36580         * config/darwin.h (DSYMUTIL_SPEC, ASM_DEBUG_SPEC): Likewise.
36581         * config/darwin9.h (DSYMUTIL_SPEC, ASM_DEBUG_SPEC): Likewise.
36582         * common.opt (g, gcoff, gdwarf, gdwarf-, ggdb, gno-pubnames,
36583         gpubnames, ggnu-pubnames, gno-record-gcc-switches,
36584         grecord-gcc-switches, gno-strict-dwarf, gstrict-dwarf, gstabs,
36585         gstabs+, gtoggle, gvms, gxcoff, gxcoff+): Add Driver flag.
36587 2017-01-16  Uros Bizjak  <ubizjak@gmail.com>
36589         * config/i386/i386.h (HARD_REGNO_CALLER_SAVE_MODE): Apply HImode and
36590         QImode fixups to general and mask registers only.
36592 2017-01-16  Carl Love  <cel@us.ibm.com>
36594         * config/rs6000/rs6000-c (altivec_overloaded_builtins): Add support
36595         for built-in functions
36596         vector signed char vec_nabs (vector signed char)
36597         vector signed short vec_nabs (vector signed short)
36598         vector signed int vec_nabs (vector signed int)
36599         vector signed long long vec_nabs (vector signed long long)
36600         vector float vec_nabs (vector float)
36601         vector double vec_nabs (vector double)
36602         * config/rs6000/rs6000-builtin.def: Add definitions for NABS functions
36603         and NABS overload.
36604         * config/rs6000/altivec.md: New define_expand nabs<mode>2 types
36605         * config/rs6000/altivec.h: New define for vec_nabs built-in function.
36606         * doc/extend.texi: Update the documentation file for the new built-in
36607         functions.
36609 2017-01-16  Martin Sebor  <msebor@redhat.com>
36611         * gimple-ssa-sprintf.c (format_directive): Correct a typo in a warning
36612         message.
36614 2017-01-16  Bill Schmidt  <wschmidt@linux.vnet.ibm.com>
36616         * config/rs6000/rs6000.c (rtx_is_swappable_p): Change
36617         UNSPEC_VSX__XXSPLTD to require special splat handling.
36619 2017-01-16  David Malcolm  <dmalcolm@redhat.com>
36621         PR bootstrap/78616
36622         * system.h: Poison strndup.
36624 2017-01-16  Alan Modra  <amodra@gmail.com>
36626         PR target/79098
36627         * config/rs6000/rs6000.c (rs6000_legitimate_combined_insn): Don't
36628         use a switch.
36630 2017-01-16  Georg-Johann Lay  <avr@gjlay.de>
36632         * config/avr/avr.h (BRANCH_COST) [reload_completed]: Increase by 4.
36634 2017-01-15  Uros Bizjak  <ubizjak@gmail.com>
36636         * config/i386/i386.c (ix86_legitimate_combined_insn): Do not
36637         call recog here.  Assert that INSN_CODE (insn) is non-negative.
36639 2017-01-15  Segher Boessenkool  <segher@kernel.crashing.org>
36641         PR target/72749
36642         * cfgrtl.c (rtl_split_edge): Also patch jump insns that jump to the
36643         fallthrough.
36644         * haifa-sched.c (dump_insn_stream): Don't crash if there is a label
36645         in the currently scheduled RTL fragment.
36647 2017-01-15  Segher Boessenkool  <segher@kernel.crashing.org>
36649         PR rtl-optimization/78751
36650         * ifcvt.c (find_cond_trap): If we generated a non-existing insn,
36651         give up.
36653 2017-01-14  Jeff Law  <law@redhat.com>
36655         PR tree-optimization/79090
36656         * tree-ssa-dse.c (valid_ao_ref_for_dse): Reject zero length and
36657         variable length stores.
36658         (compute_trims): Delete dead assignment to *trim_tail.
36659         (dse_dom_walker::dse_optimize_stmt): Optimize mem* calls with
36660         zero length.
36662 2017-01-14  Bernd Schmidt  <bschmidt@redhat.com>
36664         PR rtl-optimization/78626
36665         PR rtl-optimization/78727
36666         * cprop.c (one_cprop_pass): Collect unconditional traps in the middle
36667         of a block, and split such blocks after everything else is finished.
36669 2017-01-14  Alan Modra  <amodra@gmail.com>
36671         PR target/72749
36672         * combine.c (recog_for_combine_1): Set INSN_CODE before calling
36673         target legitimate_combined_insn.
36674         * config/rs6000/rs6000.c (TARGET_LEGITIMATE_COMBINED_INSN): Define.
36675         (rs6000_legitimate_combined_insn): New function.
36676         * config/rs6000/rs6000.md (UNSPEC_DOLOOP): Delete, and remove
36677         all uses.
36678         (ctr<mode>_internal3): Rename from *ctr<mode>_internal5.
36679         (ctr<mode>_internal4): Rename from *ctr<mode>_internal6.
36680         (ctr<mode>_internal1, ctr<mode>_internal2): Remove '*' from name.
36682 2017-01-14  Gerald Pfeifer  <gerald@pfeifer.com>
36684         * doc/frontends.texi (G++ and GCC): Remove references to Java.
36686 2017-01-13  Jeff Law  <law@redhat.com>
36688         PR tree-optimization/33562
36689         PR tree-optimization/61912
36690         PR tree-optimization/77485
36691         * tree-ssa-dse.c (delete_dead_call): Accept gsi rather than
36692         a statement.
36693         (delete_dead_assignment): Likewise.
36694         (dse_dom_walker::dse_optimize_stmt): Pass in the gsi rather than
36695         statement to delete_dead_call and delete_dead_assignment.
36697 2017-01-13  David Malcolm  <dmalcolm@redhat.com>
36699         PR c/78304
36700         * substring-locations.c (format_warning_va): Strengthen case 1 so
36701         that both endpoints of the substring must be within the format
36702         range for just the substring to be printed.
36704 2017-01-13  Uros Bizjak  <ubizjak@gmail.com>
36706         * config/i386/i386.opt (msgx): Use ix86_isa_flags2 variable.
36707         * config/i386/i386.c (ix86_target_string): Add missing options
36708         to isa_opts and reorder options by implied ISAs.  Rename isa_opts2 to
36709         isa2_opts, ix86_flag_opts to flag2_opts, ix86_target_other to
36710         flags_other and ix86_target_other to flags2_other.  Display unknown
36711         isa2 options.
36712         (ix86_valid_target_attribute_inner_p): Add missing options and
36713         reorder options by implied ISAs, as in ix86_target_string.
36715 2017-01-13  Richard Sandiford  <richard.sandiford@arm.com>
36717         * hash-table.h (hash_table::too_empty_p): New function.
36718         (hash_table::expand): Use it.
36719         (hash_table::traverse): Likewise.
36720         (hash_table::empty_slot): Use sizeof (value_type) instead of
36721         sizeof (PTR) to convert bytes to elements.  Shrink the table
36722         if the current size is excessive for the current number of
36723         elements.
36725 2017-01-13  Richard Sandiford  <richard.sandiford@arm.com>
36727         * ira-costs.c (record_reg_classes): Break from the inner loop
36728         early once alt_fail is known to be true.  Update outer loop
36729         handling accordingly.
36731 2017-01-13  Jeff Law  <law@redhat.com>
36733         * tree-ssa-dse.c (decrement_count): New function.
36734         (increment_start_addr, maybe_trim_memstar_call): Likewise.
36735         (dse_dom_walker::optimize_stmt): Call maybe_trim_memstar_call directly
36736         when we know the partially dead statement is a mem* function.
36738         PR tree-optimization/61912
36739         PR tree-optimization/77485
36740         * tree-ssa-dse.c: Include expr.h.
36741         (maybe_trim_constructor_store): New function.
36742         (maybe_trim_partially_dead_store): Call maybe_trim_constructor_store.
36744         PR tree-optimization/33562
36745         PR tree-optimization/61912
36746         PR tree-optimization/77485
36747         * doc/invoke.texi: Document new dse-max-object-size param.
36748         * params.def (PARM_DSE_MAX_OBJECT_SIZE): New PARAM.
36749         * tree-ssa-dse.c: Include params.h.
36750         (dse_store_status): New enum.
36751         (initialize_ao_ref_for_dse): New, partially extracted from
36752         dse_optimize_stmt.
36753         (valid_ao_ref_for_dse, normalize_ref): New.
36754         (setup_live_bytes_from_ref, compute_trims): Likewise.
36755         (clear_bytes_written_by, maybe_trim_complex_store): Likewise.
36756         (maybe_trim_partially_dead_store): Likewise.
36757         (maybe_trim_complex_store): Likewise.
36758         (dse_classify_store): Renamed from dse_possibly_dead_store_p.
36759         Track what bytes live from the original store.  Return tri-state
36760         for dead, partially dead or live.
36761         (dse_dom_walker): Add constructor, destructor and new private members.
36762         (delete_dead_call, delete_dead_assignment): New extracted from
36763         dse_optimize_stmt.
36764         (dse_optimize_stmt): Make a member of dse_dom_walker.
36765         Use initialize_ao_ref_for_dse.
36767         PR tree-optimization/33562
36768         PR tree-optimization/61912
36769         PR tree-optimization/77485
36770         * sbitmap.h (bitmap_count_bits): Prototype.
36771         (bitmap_clear_range, bitmap_set_range): Likewise.
36772         * sbitmap.c (bitmap_clear_range): New function.
36773         (bitmap_set_range, sbitmap_popcount, bitmap_count_bits): Likewise.
36775 2017-01-13  Martin Liska  <mliska@suse.cz>
36777         PR ipa/79043
36778         * function.c (set_cfun): Add new argument force.
36779         * function.h (set_cfun): Likewise.
36780         * ipa-inline-transform.c (inline_call): Use the function when
36781         strict alising from is dropped for function we inline to.
36783 2017-01-13  Richard Biener  <rguenther@suse.de>
36785         * tree-pretty-print.c (dump_generic_node): Fix inverted condition
36786         for dumping GIMPLE INTEGER_CSTs.
36788 2017-01-13  Rainer Orth  <ro@CeBiTec.Uni-Bielefeld.DE>
36790         * config/sol2.h (TARGET_OS_CPP_BUILTINS): Define __STDC_VERSION__
36791         to 201112L since C++17.
36793 2017-01-13  Maxim Ostapenko  <m.ostapenko@samsung.com>
36795         PR sanitizer/78887
36796         * asan.c (asan_needs_odr_indicator_p): Don't emit ODR indicators
36797         if -fsanitize=kernel-address is present.
36799 2017-01-13  Richard Biener  <rguenther@suse.de>
36801         * tree-pretty-print.c (dump_generic_node): Dump INTEGER_CSTs
36802         as _Literal ( type ) number in case usual suffixes do not
36803         preserve all information.
36805 2017-01-13  Richard Biener  <rguenther@suse.de>
36807         PR tree-optimization/77283
36808         * gimple-ssa-split-paths.c: Include gimple-ssa.h, tree-phinodes.h
36809         and ssa-iterators.h.
36810         (is_feasible_trace): Implement a cost model based on joiner
36811         PHI node uses.
36813 2017-01-12  Michael Meissner  <meissner@linux.vnet.ibm.com>
36815         PR target/79004
36816         * config/rs6000/rs6000.md (FP_ISA3): Do not optimize converting
36817         char or short to __float128/_Float128 directly.
36819 2017-01-12  Martin Sebor  <msebor@redhat.com>
36821         to -Wformat-overflow.
36822         * gimple-ssa-sprintf.c (pass_sprintf_length::gate): Adjust.
36823         (min_bytes_remaining): Same.
36824         (get_string_length): Same.
36825         (format_string): Same.
36826         (format_directive): Same.
36827         (add_bytes): Same.
36828         (pass_sprintf_length::handle_gimple_call): Same.
36830 2017-01-12  Jakub Jelinek  <jakub@redhat.com>
36832         * gimple-ssa-sprintf.c (try_substitute_return_value): Remove
36833         info.nowrite calls with no lhs that can't throw.  Return bool
36834         whether gsi_remove has been called or not.
36835         (pass_sprintf_length::handle_gimple_call): Return bool whether
36836         try_substitute_return_value called gsi_remove.  Formatting fix.
36837         (pass_sprintf_length::execute): Don't use gsi_remove if
36838         handle_gimple_call returned true.
36840         PR bootstrap/79069
36841         * cfgrtl.c (rtl_tidy_fallthru_edge): For any_uncondjump_p that can't
36842         be removed due to side-effects, don't remove following barrier nor
36843         turn the successor edge into fallthru edge.
36845 2017-01-12  Bill Schmidt  <wschmidt@linux.vnet.ibm.com>
36847         PR target/79044
36848         * config/rs6000/rs6000.c (insn_is_swappable_p): Mark
36849         element-reversing loads and stores as not swappable.
36851 2017-01-12  Nathan Sidwell  <nathan@acm.org>
36852             Nicolai Stange  <nicstange@gmail.com>
36854         * combine.c (try_combine): Don't ignore result of overlap checking
36855         loop.  Combine overlap & asm check into single loop.
36857 2017-01-12  Richard Biener  <rguenther@suse.de>
36859         * tree-pretty-print.c (dump_generic_node): Provide -gimple
36860         variant for MEM_REF.  Sanitize INTEGER_CST for -gimple.
36862 2017-01-12  Richard Biener  <rguenther@suse.de>
36864         * tree.c (initialize_tree_contains_struct): Make TS_OPTIMIZATION
36865         and TS_TARGET_OPTION directly derive from TS_BASE.
36866         * tree-core.h (tree_optimization_option): Derive from tree_base.
36867         (tree_target_option): Likewise.
36869 2017-01-11  Uros Bizjak  <ubizjak@gmail.com>
36871         * config/i386/i386.c (memory_address_length): Increase len
36872         only when rip_relative_addr_p returns false.
36874 2017-01-11  Julia Koval  <julia.koval@intel.com>
36876         * common/config/i386/i386-common.c (OPTION_MASK_ISA_SGX_UNSET): New.
36877         (OPTION_MASK_ISA_SGX_SET): New.
36878         (ix86_handle_option): Handle OPT_msgx.
36879         * config.gcc: Added sgxintrin.h.
36880         * config/i386/driver-i386.c (host_detect_local_cpu): Detect sgx.
36881         * config/i386/i386-c.c (ix86_target_macros_internal): Define __SGX__.
36882         * config/i386/i386.c (ix86_target_string): Add -msgx.
36883         (PTA_SGX): New.
36884         (ix86_option_override_internal): Handle new options.
36885         (ix86_valid_target_attribute_inner_p): Add sgx.
36886         * config/i386/i386.h (TARGET_SGX, TARGET_SGX_P): New.
36887         * config/i386/i386.opt: Add msgx.
36888         * config/i386/sgxintrin.h: New file.
36889         * config/i386/x86intrin.h: Add sgxintrin.h.
36891 2017-01-11  Jakub Jelinek  <jakub@redhat.com>
36893         PR c++/71537
36894         * fold-const.c (maybe_nonzero_address): Return 1 for function
36895         local objects.
36896         (tree_single_nonzero_warnv_p): Don't handle function local objects
36897         here.
36899         PR c++/72813
36900         * gcc.c (default_compilers): Don't add -o %g.s for -S -save-temps
36901         of c-header.
36903 2017-01-11  David Malcolm  <dmalcolm@redhat.com>
36905         PR driver/78877
36906         * opts.c: Include "spellcheck.h"
36907         (struct string_fragment): New struct.
36908         (struct edit_distance_traits<const string_fragment &>): New
36909         struct.
36910         (get_closest_sanitizer_option): New function.
36911         (parse_sanitizer_options): Offer suggestions for unrecognized arguments.
36913 2017-01-11  Jakub Jelinek  <jakub@redhat.com>
36915         * dwarf2out.c (DWARF_COMPILE_UNIT_HEADER_SIZE): For DWARF5 decrease
36916         by 12.
36917         (DWARF_COMDAT_TYPE_UNIT_HEADER_SIZE): Always
36918         DWARF_COMPILE_UNIT_HEADER_SIZE plus 12.
36919         (DWARF_COMPILE_UNIT_SKELETON_HEADER_SIZE): Define.
36920         (calc_base_type_die_sizes): Use DWARF_COMPILE_UNIT_SKELETON_HEADER_SIZE
36921         for initial die_offset if dwarf_split_debug_info.
36922         (output_comp_unit): Use DWARF_COMPILE_UNIT_SKELETON_HEADER_SIZE for
36923         initial next_die_offset if dwo_id is non-NULL.  Don't emit padding
36924         fields.
36925         (output_skeleton_debug_sections): Formatting fix.  Use
36926         DWARF_COMPILE_UNIT_SKELETON_HEADER_SIZE instead of
36927         DWARF_COMPILE_UNIT_HEADER_SIZE.  Don't emit padding.
36929 2017-01-11  Wilco Dijkstra  <wdijkstr@arm.com>
36931         * config/arm/cortex-a53.md: Add bypasses for
36932         cortex_a53_r2f_cvt.
36933         (cortex_a53_r2f): Only use for transfers.
36934         (cortex_a53_f2r): Likewise.
36935         (cortex_a53_r2f_cvt): Add reservation for conversions.
36936         (cortex_a53_f2r_cvt): Likewise.
36938 2017-01-11  Tamar Christina  <tamar.christina@arm.com>
36940         * config/arm/arm_neon.h: Add __artificial__ and gnu_inline
36941         to all inlined functions, change static to extern.
36943 2017-01-11  Christophe Lyon  <christophe.lyon@linaro.org>
36945         PR target/78253
36946         * config/arm/arm.c (legitimize_pic_address): Handle reference to
36947         weak symbol.
36948         (arm_assemble_integer): Likewise.
36950 2017-01-11  Richard Earnshaw  <rearnsha@arm.com>
36952         * config.gcc: Use new awk script to check CPU, FPU and architecture
36953         parameters for --with-... options.
36954         * config/arm/parsecpu.awk: New file
36955         * config/arm/arm-cpus.in: New file.
36956         * config/arm/arm-opts.h: Include arm-cpu.h instead of processing .def
36957         files.
36958         * config/arm/arm.c: Include arm-cpu-data.h instead of processing .def
36959         files.
36960         * config/arm/t-arm: Update dependency rules.
36961         * common/config/arm/arm-common.c: Include arm-cpu-cdata.h instead
36962         of processing .def files.
36963         * config/arm/genopt.sh: Deleted.
36964         * config/arm/gentune.sh: Deleted.
36965         * config/arm/arm-cores.def: Deleted.
36966         * config/arm/arm-arches.def: Deleted.
36967         * config/arm/arm-fpus.def: Deleted.
36968         * config/arm/arm-tune.md: Regenerated.
36969         * config/arm/arm-tables.opt: Regenerated.
36970         * config/arm/arm-cpu.h: New generated file.
36971         * config/arm/arm-cpu-data.h: New generated file.
36972         * config/arm/arm-cpu-cdata.h: New generated file.
36974 2017-01-11  Maxim Ostapenko  <m.ostapenko@samsung.com>
36976         PR lto/79042
36977         * lto-cgraph.c (lto_output_varpool_node): Pack dynamically_initialized
36978         bit.
36979         (input_varpool_node): Unpack dynamically_initialized bit.
36981 2017-01-11  Eric Botcazou  <ebotcazou@adacore.com>
36983         PR rtl-optimization/79032
36984         * lra-constraints.c (simplify_operand_subreg): In the MEM case, test
36985         the alignment of the adjusted memory reference against that of MODE,
36986         instead of the alignment of the original memory reference.
36988 2017-01-11  Martin Jambor  <mjambor@suse.cz>
36990         * hsa.c (hsa_callable_function_p): Revert addition of DECL_ARTIFICIAL
36991         test.
36992         * ipa-hsa.c (process_hsa_functions): Only duplicate non-artificial
36993         decorated functions.
36995 2017-01-11  Richard Biener  <rguenther@suse.de>
36997         * tree-vrp.c (evrp_dom_walker::before_dom_children): Also
36998         set range/nonnull info for PHI results.  Do not set it on
36999         stmts marked for removal.
37001 2017-01-10  Eric Botcazou  <ebotcazou@adacore.com>
37003         * expr.c (store_field): In the bitfield case, fetch the return value
37004         from the registers before applying a single big-endian adjustment.
37005         Always do a final load for a BLKmode value not larger than a word.
37007 2017-01-10  David Malcolm  <dmalcolm@redhat.com>
37009         PR c++/77949
37010         * input.c (selftest::test_accessing_ordinary_linemaps): Verify
37011         that we correctly handle column numbers greater than
37012         LINE_MAP_MAX_COLUMN_NUMBER.
37014 2017-01-10  Martin Sebor  <msebor@redhat.com>
37016         PR middle-end/78245
37017         * gimple-ssa-sprintf.c (get_destination_size): Call
37018         {init,fini}object_sizes.
37019         * tree-object-size.c (addr_object_size): Adjust.
37020         (pass_through_call): Adjust.
37021         (pass_object_sizes::execute): Adjust.
37022         * tree-object-size.h (fini_object_sizes): Declare.
37024 2017-01-10  Martin Sebor  <msebor@redhat.com>
37026         PR tree-optimization/78775
37027         * builtins.c (get_size_range): Move...
37028         * calls.c: ...to here.
37029         (alloc_max_size): Accept zero argument.
37030         (operand_signed_p): Remove.
37031         (maybe_warn_alloc_args_overflow): Call get_size_range.
37032         * calls.h (get_size_range): Declare.
37034 2017-01-10  Joe Seymour  <joe.s@somniumtech.com>
37036         * config/msp430/driver-msp430.c (msp430_mcu_data): Sync with data
37037         from TI's devices.csv file as of September 2016.
37038         * config/msp430/msp430.c (msp430_mcu_data): Likewise.
37040 2017-01-10  Sandra Loosemore  <sandra@codesourcery.com>
37042         * doc/extend.texi: Tweak formatting to fix overfull hbox warnings.
37043         * doc/invoke.texi: Likewise.
37044         * doc/md.texi: Likewise.
37045         * doc/objc.texi: Likewise.
37047 2017-01-10  Joshua Conner  <joshconner@google.com>
37049         * config/arm/fuchsia-elf.h: New file.
37050         * config/fuchsia.h: New file.
37051         * config.gcc (*-*-fuchsia*): Set native_system_header_dir.
37052         (aarch64*-*-fuchsia*, arm*-*-fuchsia*, x86_64-*-fuchsia*): Add to
37053         targets.
37054         * config.host: (aarch64*-*-fuchsia*, arm*-*-fuchsia*): Add to hosts.
37056 2016-01-10  Richard Biener  <rguenther@suse.de>
37058         PR tree-optimization/79034
37059         * tree-call-cdce.c (shrink_wrap_one_built_in_call_with_conds):
37060         Propagate out degenerate PHIs in the joiner.
37062 2017-01-10  Martin Liska  <mliska@suse.cz>
37064         * ipa-icf.c (sort_sem_items_by_decl_uid): New function.
37065         (sort_congruence_classes_by_decl_uid): Likewise.
37066         (sort_congruence_class_groups_by_decl_uid): Likewise.
37067         (sem_item_optimizer::merge_classes): Sort class, groups in these
37068         classes and members in the groups by DECL_UID of declarations.
37069         This would make merge operations stable.
37071 2017-01-10  Martin Liska  <mliska@suse.cz>
37073         * ipa-icf.c (sem_item_optimizer::sem_item_optimizer): Remove
37074         usage of m_classes_vec.
37075         (sem_item_optimizer::~sem_item_optimizer):  Likewise.
37076         (sem_item_optimizer::get_group_by_hash): Likewise.
37077         (sem_item_optimizer::subdivide_classes_by_equality): Likewise.
37078         (sem_item_optimizer::subdivide_classes_by_sensitive_refs): Likewise.
37079         (sem_item_optimizer::verify_classes): Likewise.
37080         (sem_item_optimizer::process_cong_reduction): Likewise.
37081         (sem_item_optimizer::dump_cong_classes): Likewise.
37082         (sem_item_optimizer::merge_classes): Likewise.
37083         * ipa-icf.h (congruence_class_hash): Rename from
37084         congruence_class_group_hash.  Remove declaration of m_classes_vec.
37086 2017-01-10  Andrew Senkevich  <andrew.senkevich@intel.com>
37088         * common/config/i386/i386-common.c (OPTION_MASK_ISA_AVX512VPOPCNTDQ_SET,
37089         OPTION_MASK_ISA_AVX512VPOPCNTDQ_UNSET): New.
37090         * config.gcc: Add avx512vpopcntdqintrin.h.
37091         * config/i386/avx512vpopcntdqintrin.h: New.
37092         * config/i386/cpuid.h (bit_AVX512VPOPCNTDQ): New.
37093         * config/i386/i386-builtin-types.def: Add new types.
37094         * config/i386/i386-builtin.def (__builtin_ia32_vpopcountd_v16si,
37095         __builtin_ia32_vpopcountd_v16si_mask, __builtin_ia32_vpopcountq_v8di,
37096         __builtin_ia32_vpopcountq_v8di_mask): New.
37097         * config/i386/i386-c.c (ix86_target_macros_internal): Define
37098         __AVX512VPOPCNTDQ__.
37099         * config/i386/i386.c (ix86_target_string): Add -mavx512vpopcntdq.
37100         (PTA_AVX512VPOPCNTDQ): Define.
37101         * config/i386/i386.h (TARGET_AVX512VPOPCNTDQ,
37102         TARGET_AVX512VPOPCNTDQ_P): Define.
37103         * config/i386/i386.opt: Add mavx512vpopcntdq.
37104         * config/i386/immintrin.h: Include avx512vpopcntdqintrin.h.
37105         * config/i386/sse.md (define_insn "vpopcount<mode><mask_name>"): New.
37107 2017-01-01  Jan Hubicka  <hubicka@ucw.cz>
37109         PR middle-end/77484
37110         * predict.def (PRED_CALL): Set to 67.
37112 2017-01-09  Eric Botcazou  <ebotcazou@adacore.com>
37114         * expr.c (store_field): In the bitfield case, if the value comes from
37115         a function call and is of an aggregate type returned in registers, do
37116         not modify the field mode; extract the value in all cases if the mode
37117         is BLKmode and the size is not larger than a word.
37119 2017-01-09  Dominique d'Humieres  <dominiq@lps.ens.fr>
37121         PR target/71017
37122         * config/i386/cpuid.h: Fix undefined behavior.
37124 2017-01-04  Jeff Law  <law@redhat.com>
37126         PR tree-optimization/79007
37127         PR tree-optimization/67955
37128         * tree-ssa-alias.c (same_addr_size_stores_p): Only need to be
37129         conservative for pt.null when flag_non_call_exceptions is on.
37131 2017-01-09  Jakub Jelinek  <jakub@redhat.com>
37133         PR translation/79019
37134         PR translation/79020
37135         * params.def (PARAM_INLINE_MIN_SPEEDUP,
37136         PARAM_IPA_CP_SINGLE_CALL_PENALTY,
37137         PARAM_USE_AFTER_SCOPE_DIRECT_EMISSION_THRESHOLD): Fix typos
37138         in descriptions.
37139         * config/avr/avr.opt (maccumulate-args): Likewise.
37140         * config/msp430/msp430.opt (mwarn-mcu): Likewise.
37141         * common.opt (freport-bug): Likewise.
37142         * cif-code.def (CIF_FINAL_ERROR): Likewise.
37143         * doc/invoke.texi (ipa-cp-single-call-penalty): Likewise.
37144         * config/s390/s390.c (s390_invalid_binary_op): Fix spelling in
37145         translatable string.
37146         * config/i386/i386.c (function_value_32): Likewise.
37147         * config/nios2/nios2.c (nios2_valid_target_attribute_rec): Likewise.
37148         * config/msp430/msp430.c (msp430_option_override, msp430_attr):
37149         Likewise.
37150         * config/msp430/driver-msp430.c (msp430_select_hwmult_lib): Likewise.
37151         * common/config/msp430/msp430-common.c (msp430_handle_option):
37152         Likewise.
37153         * symtab.c (symtab_node::verify_base): Likewise.
37154         * opts.c (set_debug_level): Likewise.
37155         * tree.c (verify_type_variant): Likewise.  Fix typo in comment.
37156         * config/rs6000/rs6000-c.c (altivec_resolve_overloaded_builtin): Add
37157         missing whitespace to translatable strings.
37158         * config/avr/avr.md (bswapsi2): Fix typo in comment.
37159         * config/sh/superh.h: Likewise.
37160         * config/i386/xopintrin.h: Likewise.
37161         * config/i386/znver1.md: Likewise.
37162         * config/rs6000/rs6000.c (struct rs6000_opt_mask): Likewise.
37163         * ipa-inline-analysis.c (compute_inline_parameters): Likewise.
37164         * double-int.h (struct double_int): Likewise.
37165         * double-int.c (div_and_round_double): Likewise.
37166         * wide-int.cc: Likewise.
37167         * tree-ssa.c (non_rewritable_mem_ref_base): Likewise.
37168         * tree-ssa-sccvn.c (vn_reference_lookup_3): Likewise.
37169         * cfgcleanup.c (crossjumps_occured): Renamed to ...
37170         (crossjumps_occurred): ... this.
37171         (try_crossjump_bb, try_head_merge_bb, try_optimize_cfg, cleanup_cfg):
37172         Adjust all uses.
37174         PR tree-optimization/78899
37175         * tree-if-conv.c (version_loop_for_if_conversion): Instead of
37176         returning bool return struct loop *, NULL for failure and the new
37177         loop on success.
37178         (versionable_outer_loop_p): Don't version outer loop if it has
37179         dont_vectorized bit set.
37180         (tree_if_conversion): When versioning outer loop, ensure
37181         tree_if_conversion is performed also on the inner loop of the
37182         non-vectorizable outer loop copy.
37183         * tree-vectorizer.c (set_uid_loop_bbs): Formatting fix.  Fold
37184         LOOP_VECTORIZED in inner loop of the scalar outer loop and
37185         prevent vectorization of it.
37186         (vectorize_loops): For outer + inner LOOP_VECTORIZED, ensure
37187         the outer loop vectorization of the non-scalar version is attempted
37188         before vectorization of the inner loop in scalar version.  If
37189         outer LOOP_VECTORIZED guarded loop is not vectorized, prevent
37190         vectorization of its inner loop.
37191         * tree-vect-loop-manip.c (rename_variables_in_bb): If outer_loop
37192         has 2 inner loops, rename also on edges from bb whose single pred
37193         is outer_loop->header.  Fix typo in function comment.
37195 2017-01-09  Martin Sebor  <msebor@redhat.com>
37197         PR bootstrap/79033
37198         * asan.c (asan_emit_stack_protection): Increase local buffer size
37199         to avoid snprintf truncation warning.
37201 2017-01-09  Andrew Pinski  <apinski@cavium.com>
37203         * config/aarch64/aarch64-cores.def: Add thunderx2t99.  Change vulcan
37204         to reference thunderx2t99 for the tuning structure
37205         * config/aarch64/aarch64-cost-tables.h (vulcan_extra_costs):
37206         Rename to ...
37207         (thunderx2t99_extra_costs): This.
37208         * config/aarch64/aarch64-tune.md: Regenerate.
37209         * config/aarch64/aarch64.c (vulcan_addrcost_table): Rename to ...
37210         (vulcan_addrcost_table): This.
37211         (vulcan_regmove_cost): Rename to ...
37212         (thunderx2t99_regmove_cost): This.
37213         (vulcan_vector_cost): Rename to ...
37214         (thunderx2t99_vector_cost): this.
37215         (vulcan_branch_cost): Rename to ...
37216         (thunderx2t99_branch_cost): This.
37217         (vulcan_tunings): Rename to ...
37218         (thunderx2t99_tunings): This and s/vulcan/thunderx2t99 .
37219         * doc/invoke.texi (AARCH64/mtune): Add thunderx2t99.
37221 2017-01-09  Martin Jambor  <mjambor@suse.cz>
37223         PR ipa/78365
37224         PR ipa/78599
37225         * ipa-prop.h (ipa_jump_func): Swap positions of vr_known and m_vr.
37226         * ipa-cp.c (ipa_vr_operation_and_type_effects): New function.
37227         (propagate_vr_accross_jump_function): Use the above function for all
37228         value range computations for pass-through jump functions and type
37229         converasion from explicit value range values.
37230         (ipcp_propagate_stage): Do not attempt to deduce types of formal
37231         parameters from TYPE_ARG_TYPES.
37232         * ipa-prop.c (ipa_write_jump_function): Remove trailing whitespace.
37233         (ipa_write_node_info): Stream type of the actual argument.
37234         (ipa_read_node_info): Likewise. Also remove trailing whitespace.
37236 2017-01-09  Martin Liska  <mliska@suse.cz>
37238         PR pch/78970
37239         * gcc.c (driver_handle_option): Handle OPT_E and set have_E.
37240         (lookup_compiler): Do not show error message with have_E.
37242 2017-01-09  Jakub Jelinek  <jakub@redhat.com>
37244         PR tree-optimization/78938
37245         * tree-vect-stmts.c (vectorizable_condition): For non-masked COND_EXPR
37246         where comp_vectype is VECTOR_BOOLEAN_TYPE_P, use
37247         BIT_{NOT,XOR,AND,IOR}_EXPR on the comparison operands instead of
37248         {EQ,NE,GE,GT,LE,LT}_EXPR directly inside of VEC_COND_EXPR.  Formatting
37249         fixes.
37251 2017-01-09  Kyrylo Tkachov  <kyrylo.tkachov@arm.com>
37253         * tree-ssa-address.c (gen_addr_rtx): Don't handle index if it
37254         is const0_rtx.
37256 2017-01-09  Richard Biener  <rguenther@suse.de>
37258         PR tree-optimization/78997
37259         * tree-vect-slp.c (vect_mask_constant_operand_p): Handle SSA
37260         name condition properly.
37262 2017-01-09  Richard Biener  <rguenther@suse.de>
37264         PR debug/79000
37265         * dwarf2out.c (is_cxx): New overload with context.
37266         (is_naming_typedef_decl): Use it.
37268 2017-01-08  Sandra Loosemore  <sandra@codesourcery.com>
37270         * invoke.texi (Option Summary): Correct spacing in option lists
37271         and add line breaks to fix over-long lines.
37273 2017-01-08  Sandra Loosemore  <sandra@codesourcery.com>
37275         PR middle-end/17660
37277         * extend.texi (Common Variable Attributes): Add xref to GCC
37278         Internals manual to explain mode attribute keywords.
37280 2017-01-08  Sandra Loosemore  <sandra@codesourcery.com>
37282         PR other/16519
37283         * doc/invoke.texi (Option Summary): Move -pthread to Linker Options
37284         and Preprocessor Options.
37285         (Options for Linking): Document -pthread here....
37286         (RS/6000 and PowerPC Options): ...not here.
37287         (Solaris 2 Options): ...or here.
37288         * doc/cppopts.texi: Document -pthread.
37290 2017-01-08  Martin Sebor  <msebor@redhat.com>
37292         PR middle-end/77708
37293         * doc/invoke.texi (Warning Options): Document -Wformat-truncation.
37294         * gimple-ssa-sprintf.c (call_info::reval_used, call_info::warnopt):
37295         New member functions.
37296         (format_directive): Used them.
37297         (add_bytes): Same.
37298         (pass_sprintf_length::handle_gimple_call): Same.
37299         * graphite-sese-to-poly.c (tree_int_to_gmp): Increase buffer size
37300         to avoid truncation for any argument.
37301         (extract_affine_mul): Same.
37302         * tree.c (get_file_function_name): Same.
37304 2017-01-01  Jan Hubicka  <hubicka@ucw.cz>
37306         PR middle-end/77484
37307         * predict.def (PRED_INDIR_CALL): Set to 86.
37309 2017-01-07  Sandra Loosemore  <sandra@codesourcery.com>
37311         PR preprocessor/54124
37312         * doc/cppopts.texi: Reformat -d subtable to list the full name
37313         of the options.  Add cross-reference to the docs for the general
37314         compiler -d options.
37315         * doc/invoke.texi (Developer Options): Add cross-reference to the
37316         preprocessor-specific -d option documentation.
37318 2017-01-07  Sandra Loosemore  <sandra@codesourcery.com>
37320         PR preprocessor/13498
37321         * doc/cpp.texi (Search Path): Rewrite to remove obsolete and
37322         redudant material, and reflect new command-line options.
37323         (System Headers): Likewise.
37325 2017-01-07  Sandra Loosemore  <sandra@codesourcery.com>
37327         * doc/cppdiropts.texi: Merge documentation of -I, -iquote,
37328         -isystem, and -idirafter.  Copy-edit.
37329         * doc/cppopts.texi: Copy-edit.  Remove contradiction about
37330         default for -ftrack-macro-expansion.  Delete obsolete and
37331         badly-formatted implementation details about -fdebug-cpp output.
37332         * doc/cppwarnopts.texi: Copy-edit.
37334 2017-01-07  David Malcolm  <dmalcolm@redhat.com>
37336         PR c++/72803
37337         * input.c (selftest::test_accessing_ordinary_linemaps): Verify
37338         that the transition from a max line width >= 1<<10 to narrower
37339         lines works correctly.
37341 2017-01-07  Alexandre Oliva <aoliva@redhat.com>
37343         * doc/options.texi (PerFunction): New.
37344         * opt-functions.awk (switch_flags): Map both Optimization and
37345         PerFunction to CL_OPTIMIZATION.
37346         * opth-gen.awk: Test for PerFunction flag along with
37347         Optimization.
37348         * optc-save-gen.awk: Likewise.  Introduce var_opt_hash and set
37349         it only when the latter is present.  Skip those that don't in
37350         the hash function generator.
37351         * common.opt (fvar-tracking): Mark as PerFunction instead of
37352         Optimization.
37353         (fvar-tracking-assignments): Likewise.
37354         (fvar-tracking-assignments-toggle): Likewise.
37355         (fvar-tracking-uninit): Likewise.
37357 2017-01-07  Jakub Jelinek  <jakub@redhat.com>
37359         PR translation/79018
37360         * params.def (PARAM_MAX_STORES_TO_MERGE): Add missing space between
37361         the and store.
37363 2017-01-06  Mikael Pettersson  <mikpelinux@gmail.com>
37365         PR target/57583
37366         * config/m68k/m68k.opt (LONG_JUMP_TABLE_OFFSETS): New option.
37367         * config/m68k/linux.h (ASM_RETURN_CASE_JUMP): Handle
37368         TARGET_LONG_JUMP_TABLE_OFFSETS.
37369         * config/m68k/m68kelf.h (ASM_RETURN_CASE_JUMP): Likewise.
37370         * config/m68k/netbsd-elf.h (ASM_RETURN_CASE_JUMP): Likewise.
37371         * config/m68k/m68k.h (CASE_VECTOR_MODE): Likewise.
37372         (ASM_OUTPUT_ADDR_DIFF_ELF): Likewise.
37373         * config/m68k/m68k.md (tablejump expander): Likewise.
37374         (*tablejump_pcrel_hi): Renamed from unnamed insn, reject
37375         TARGET_LONG_JUMP_TABLE_OFFSETS.
37376         (*tablejump_pcrel_si): New insn, handle TARGET_LONG_JUMP_TABLE_OFFSETS.
37377         * doc/invoke.texi (M68K options): Add -mlong-jump-table-offsets.
37379 2017-01-06  Edgar E. Iglesias <edgar.iglesias@xilinx.com>
37380             David Holsgrove <david.holsgrove@xilinx.com>
37382         * common/config/microblaze/microblaze-common.c
37383         (TARGET_EXCEPT_UNWIND_INFO): Remove.
37384         * config/microblaze/microblaze-protos.h (microblaze_eh_return):
37385         New prototype.
37386         * config/microblaze/microblaze.c (microblaze_must_save_register)
37387         (microblaze_expand_epilogue, microblaze_return_addr): Handle
37388         calls_eh_return.
37389         (microblaze_eh_return): New function.
37390         * config/microblaze/microblaze.h (RETURN_ADDR_OFFSET)
37391         (EH_RETURN_DATA_REGNO, MB_EH_STACKADJ_REGNUM)
37392         (EH_RETURN_STACKADJ_RTX, ASM_PREFERRED_EH_DATA_FORMAT): New macros.
37393         * config/microblaze/microblaze.md (eh_return): New pattern.
37395 2017-01-06  Jakub Jelinek  <jakub@redhat.com>
37397         * system.h (GCC_DIAGNOSTIC_PUSH_IGNORED, GCC_DIAGNOSTIC_POP,
37398         GCC_DIAGNOSTIC_STRINGIFY): Define.
37400         * read-rtl.c (rtx_reader::read_rtx_code): Avoid -Wsign-compare warning.
37402 2017-01-06  Andre Vieira  <andre.simoesdiasvieira@arm.com>
37404         * config/arm/arm.md (<mcrr>): New.
37405         (<mrrc>): New.
37406         * config/arm/arm.c (arm_arch5te): New.
37407         (arm_option_override): Set arm_arch5te.
37408         (arm_coproc_builtin_available): Add support for mcrr, mcrr2, mrrc
37409         and mrrc2.
37410         * config/arm/arm-builtins.c (MCRR_QUALIFIERS): Define to...
37411         (arm_mcrr_qualifiers): ... this. New.
37412         (MRRC_QUALIFIERS): Define to...
37413         (arm_mrrc_qualifiers): ... this. New.
37414         * config/arm/arm_acle.h (__arm_mcrr, __arm_mcrr2, __arm_mrrc,
37415         __arm_mrrc2): New.
37416         * config/arm/arm_acle_builtins.def (mcrr, mcrr2, mrrc, mrrc2): New.
37417         * config/arm/iterators.md (MCRRI, mcrr, MCRR): New.
37418         (MRRCI, mrrc, MRRC): New.
37419         * config/arm/unspecs.md (VUNSPEC_MCRR, VUNSPEC_MCRR2, VUNSPEC_MRRC,
37420         VUNSPEC_MRRC2): New.
37422 2017-01-06  Andre Vieira  <andre.simoesdiasvieira@arm.com>
37424         * config/arm/arm.md (<mcr>): New.
37425         (<mrc>): New.
37426         * config/arm/arm.c (arm_coproc_builtin_available): Add
37427         support for mcr, mrc, mcr2 and mrc2.
37428         * config/arm/arm-builtins.c (MCR_QUALIFIERS): Define to...
37429         (arm_mcr_qualifiers): ... this. New.
37430         (MRC_QUALIFIERS): Define to ...
37431         (arm_mrc_qualifiers): ... this. New.
37432         (MCR_QUALIFIERS): Define to ...
37433         (arm_mcr_qualifiers): ... this. New.
37434         * config/arm/arm_acle.h (__arm_mcr, __arm_mrc, __arm_mcr2,
37435         __arm_mrc2): New.
37436         * config/arm/arm_acle_builtins.def (mcr, mcr2, mrc, mrc2): New.
37437         * config/arm/iterators.md (MCRI, mcr, MCR, MRCI, mrc, MRC): New.
37438         * config/arm/unspecs.md (VUNSPEC_MCR, VUNSPEC_MCR2, VUNSPEC_MRC,
37439         VUNSPEC_MRC2): New.
37441 2017-01-06  Andre Vieira  <andre.simoesdiasvieira@arm.com>
37443         * config/arm/arm.md (*ldc): New.
37444         (*stc): New.
37445         (<ldc>): New.
37446         (<stc>): New.
37447         * config/arm/arm.c (arm_coproc_builtin_available): Add
37448         support for ldc,ldcl,stc,stcl,ldc2,ldc2l,stc2 and stc2l.
37449         (arm_coproc_ldc_stc_legitimate_address): New.
37450         * config/arm/arm-builtins.c (arm_type_qualifiers): Add
37451         'qualifier_const_pointer'.
37452         (LDC_QUALIFIERS): Define to...
37453         (arm_ldc_qualifiers): ... this. New.
37454         (STC_QUALIFIERS): Define to...
37455         (arm_stc_qualifiers): ... this. New.
37456         * config/arm/arm-protos.h
37457         (arm_coproc_ldc_stc_legitimate_address): New.
37458         * config/arm/arm_acle.h (__arm_ldc, __arm_ldcl, __arm_stc,
37459         __arm_stcl, __arm_ldc2, __arm_ldc2l, __arm_stc2, __arm_stc2l): New.
37460         * config/arm/arm_acle_builtins.def (ldc, ldc2, ldcl, ldc2l, stc,
37461         stc2, stcl, stc2l): New.
37462         * config/arm/constraints.md (Uz): New.
37463         * config/arm/iterators.md (LDCI, STCI, ldc, stc, LDC STC): New.
37464         * config/arm/unspecs.md (VUNSPEC_LDC, VUNSPEC_LDC2, VUNSPEC_LDCL,
37465         VUNSPEC_LDC2L, VUNSPEC_STC, VUNSPEC_STC2, VUNSPEC_STCL,
37466         VUNSPEC_STC2L): New.
37468 2017-01-06  Andre Vieira  <andre.simoesdiasvieira@arm.com>
37470         * config/arm/arm.md (<cdp>): New.
37471         * config/arm/arm.c (neon_const_bounds): Rename this ...
37472         (arm_const_bounds): ... this.
37473         (arm_coproc_builtin_available): New.
37474         * config/arm/arm-builtins.c (SIMD_MAX_BUILTIN_ARGS): Increase.
37475         (arm_type_qualifiers): Add 'qualifier_unsigned_immediate'.
37476         (CDP_QUALIFIERS): Define to...
37477         (arm_cdp_qualifiers): ... this. New.
37478         (void_UP): Define.
37479         (arm_expand_builtin_args): Add case for 6 arguments.
37480         * config/arm/arm-protos.h (neon_const_bounds): Rename this ...
37481         (arm_const_bounds): ... this.
37482         (arm_coproc_builtin_available): New.
37483         * config/arm/arm_acle.h (__arm_cdp): New.
37484         (__arm_cdp2): New.
37485         * config/arm/arm_acle_builtins.def (cdp): New.
37486         (cdp2): New.
37487         * config/arm/iterators.md (CDPI,CDP,cdp): New.
37488         * config/arm/neon.md: Rename all 'neon_const_bounds' to
37489         'arm_const_bounds'.
37490         * config/arm/types.md (coproc): New.
37491         * config/arm/unspecs.md (VUNSPEC_CDP, VUNSPEC_CDP2): New.
37492         * doc/extend.texi (ACLE): Add a mention of Coprocessor intrinsics.
37493         * doc/sourcebuild.texi (arm_coproc1_ok, arm_coproc2_ok,
37494         arm_coproc3_ok, arm_coproc4_ok): Document new effective targets.
37496 2017-01-06  Andre Vieira  <andre.simoesdiasvieira@arm.com>
37498         * config/arm/arm-builtins.c (arm_unsigned_binop_qualifiers): New.
37499         (UBINOP_QUALIFIERS): New.
37500         (si_UP): Define.
37501         (acle_builtin_data): New. Change comment.
37502         (arm_builtins): Remove ARM_BUILTIN_CRC32B, ARM_BUILTIN_CRC32H,
37503         ARM_BUILTIN_CRC32W, ARM_BUILTIN_CRC32CB, ARM_BUILTIN_CRC32CH,
37504         ARM_BUILTIN_CRC32CW. Add ARM_BUILTIN_ACLE_BASE and include
37505         arm_acle_builtins.def.
37506         (ARM_BUILTIN_ACLE_PATTERN_START): Define.
37507         (arm_init_acle_builtins): New.
37508         (CRC32_BUILTIN): Remove.
37509         (bdesc_2arg): Remove entries for crc32b, crc32h, crc32w,
37510         crc32cb, crc32ch and crc32cw.
37511         (arm_init_crc32_builtins): Remove.
37512         (arm_init_builtins): Use arm_init_acle_builtins rather
37513         than arm_init_crc32_builtins.
37514         (arm_expand_acle_builtin): New.
37515         (arm_expand_builtin): Use 'arm_expand_acle_builtin'.
37516         * config/arm/arm_acle_builtins.def: New.
37518 2017-01-06  Andre Vieira  <andre.simoesdiasvieira@arm.com>
37520         * config/arm/arm-builtins.c (neon_builtin_datum): Rename to ..
37521         (arm_builtin_datum): ... this.
37522         (arm_init_neon_builtin): Rename to ...
37523         (arm_init_builtin): ... this. Add a new parameters PREFIX
37524         and USE_SIG_IN_NAME.
37525         (arm_init_neon_builtins): Replace 'arm_init_neon_builtin' with
37526         'arm_init_builtin'. Replace type 'neon_builtin_datum' with
37527         'arm_builtin_datum'.
37528         (arm_init_vfp_builtins): Likewise.
37529         (builtin_arg): Rename enum's replacing 'NEON_ARG' with
37530         'ARG_BUILTIN' and add a 'ARG_BUILTIN_NEON_MEMORY.
37531         (arm_expand_neon_args): Rename to ...
37532         (arm_expand_builtin_args): ... this. Rename builtin_arg
37533         enum values and differentiate between ARG_BUILTIN_MEMORY
37534         and ARG_BUILTIN_NEON_MEMORY.
37535         (arm_expand_neon_builtin_1): Rename to ...
37536         (arm_expand_builtin_1): ... this. Rename builtin_arg enum
37537         values, arm_expand_builtin_args and add bool parameter NEON.
37538         (arm_expand_neon_builtin): Use arm_expand_builtin_1.
37539         (arm_expand_vfp_builtin): Likewise.
37540         (NEON_MAX_BUILTIN_ARGS): Remove, it was unused.
37542 2017-01-01  Jan Hubicka  <hubicka@ucw.cz>
37544         PR middle-end/77484
37545         * predict.def (PRED_POLYMORPHIC_CALL): Set to 59.
37546         * predict.c (tree_estimate_probability_bb): Reverse direction of
37547         polymorphic call predictor.
37549 2017-01-06  David Malcolm  <dmalcolm@redhat.com>
37551         * passes.c (execute_one_pass): Split out pass-skipping logic into...
37552         (determine_pass_name_match): ...this new function and...
37553         (should_skip_pass_p): ...this new function.
37555 2017-01-06  Nathan Sidwell  <nathan@acm.org>
37557         * ipa-visibility.c (function_and_variable_visibility): Reformat
37558         comments and long lines.  Remove extrneous if.
37559         * symtab.c (symtab_node::make_decl_local): Fix code format.
37560         (symtab_node::set_section_for_node): Fix comment typo.
37562 2017-01-06  Martin Liska  <mliska@suse.cz>
37564         PR bootstrap/79003
37565         * lra-constraints.c: Rename invariant to lra_invariant.
37566         * predict.c (set_even_probabilities): Initialize e to NULL.
37568 2017-01-05  Martin Sebor  <msebor@redhat.com>
37570         PR tree-optimization/78910
37571         * gimple-ssa-sprintf.c (tree_digits): Add an argument.
37572         (format_integer): Correct off-by-one error in the handling
37573         of precision with negative numbers in signed conversions..
37575 2017-01-05  Eric Botcazou  <ebotcazou@adacore.com>
37577         * doc/invoke.texi (C Dialect Options): Adjust -fsso-struct entry.
37579 2017-01-05  Jakub Jelinek  <jakub@redhat.com>
37581         PR tree-optimization/71016
37582         * tree-ssa-phiopt.c (tree_ssa_phiopt_worker): Pass cond_stmt to
37583         factor_out_conditional_conversion.  Formatting fix.
37584         (factor_out_conditional_conversion): Add cond_stmt argument.
37585         If arg1 is INTEGER_CST, punt if new_arg0 is not any operand of
37586         cond_stmt and if arg0_def_stmt is not the only stmt in its bb.
37587         Formatting fix.
37589 2017-01-05  David Malcolm  <dmalcolm@redhat.com>
37591         * Makefile.in (OBJS): Add read-md.o, read-rtl.o,
37592         read-rtl-function.o, and selftest-rtl.o.
37593         * config/aarch64/aarch64.c: Include selftest.h and selftest-rtl.h.
37594         (selftest::aarch64_test_loading_full_dump): New function.
37595         (selftest::aarch64_run_selftests): New function.
37596         (TARGET_RUN_TARGET_SELFTESTS): Wire it up to
37597         selftest::aarch64_run_selftests.
37598         * config/i386/i386.c
37599         (selftest::ix86_test_loading_dump_fragment_1): New function.
37600         (selftest::ix86_test_loading_call_insn): New function.
37601         (selftest::ix86_test_loading_full_dump): New function.
37602         (selftest::ix86_test_loading_unspec): New function.
37603         (selftest::ix86_run_selftests): Call the new functions.
37604         * emit-rtl.c (maybe_set_max_label_num): New function.
37605         * emit-rtl.h (maybe_set_max_label_num): New decl.
37606         * function.c (instantiate_decls): Guard call to
37607         instantiate_decls_1 with if (DECL_INITIAL (fndecl)).
37608         * function-tests.c (selftest::verify_three_block_rtl_cfg): Remove
37609         "static".
37610         * gensupport.c (gen_reader::gen_reader): Pass "false"
37611         for new "compact" param of rtx_reader.
37612         * print-rtl.c (rtx_writer::print_rtx_operand): Print "(nil)"
37613         rather than an empty string for NULL strings.
37614         * read-md.c: Potentially include config.h rather than bconfig.h.
37615         Wrap include of errors.h with #ifdef GENERATOR_FILE.
37616         (have_error): New global, copied from errors.c.
37617         (md_reader::read_name): Rename to...
37618         (md_reader::read_name_1): ...this, adding "out_loc" param,
37619         and converting "missing name or number" to returning false, rather
37620         than failing.
37621         (md_reader::read_name): Reimplement in terms of read_name_1.
37622         (md_reader::read_name_or_nil): New function.
37623         (md_reader::read_string): Handle "(nil)" by returning NULL.
37624         (md_reader::md_reader): Add new param "compact".
37625         (md_reader::read_md_files): Wrap with #ifdef GENERATOR_FILE.
37626         (md_reader::read_file): New method.
37627         * read-md.h (md_reader::md_reader): Add new param "compact".
37628         (md_reader::read_file): New method.
37629         (md_reader::is_compact): New accessor.
37630         (md_reader::read_name): Convert return type from void to file_location.
37631         (md_reader::read_name_or_nil): New decl.
37632         (md_reader::read_name_1): New decl.
37633         (md_reader::m_compact): New field.
37634         (noop_reader::noop_reader): Pass "false" for new "compact" param
37635         of rtx_reader.
37636         (rtx_reader::rtx_reader): Add new "compact" param.
37637         (rtx_reader::read_rtx_operand): Make virtual and convert return
37638         type from void to rtx.
37639         (rtx_reader::read_until): New decl.
37640         (rtx_reader::handle_any_trailing_information): New virtual function.
37641         (rtx_reader::postprocess): New virtual function.
37642         (rtx_reader::finalize_string): New virtual function.
37643         (rtx_reader::m_in_call_function_usage): New field.
37644         (rtx_reader::m_reuse_rtx_by_id): New field.
37645         * read-rtl-function.c: New file.
37646         * selftest-rtl.c (selftest::assert_rtx_ptr_eq_at): New function.
37647         * selftest-rtl.h (ASSERT_RTX_PTR_EQ): New macro.
37648         (selftest::verify_three_block_rtl_cfg): New decl.
37649         * read-rtl-function.h: New file.
37650         * read-rtl.c: Potentially include config.h rather than bconfig.h.
37651         For host, include function.h, memmodel.h, and emit-rtl.h.
37652         (one_time_initialization): New function.
37653         (struct compact_insn_name): New struct.
37654         (compact_insn_names): New array.
37655         (find_code): Handle insn codes in compact dumps.
37656         (apply_subst_iterator): Wrap with #ifdef GENERATOR_FILE.
37657         (bind_subst_iter_and_attr): Likewise.
37658         (add_condition_to_string): Likewise.
37659         (add_condition_to_rtx): Likewise.
37660         (apply_attribute_uses): Likewise.
37661         (add_current_iterators): Likewise.
37662         (apply_iterators): Likewise.
37663         (initialize_iterators): Guard usage of apply_subst_iterator with
37664         #ifdef GENERATOR_FILE.
37665         (read_conditions): Wrap with #ifdef GENERATOR_FILE.
37666         (md_reader::read_mapping): Likewise.
37667         (add_define_attr_for_define_subst): Likewise.
37668         (add_define_subst_attr): Likewise.
37669         (read_subst_mapping): Likewise.
37670         (check_code_iterator): Likewise.
37671         (rtx_reader::read_rtx): Likewise.  Move one-time initialization
37672         logic to...
37673         (one_time_initialization): New function.
37674         (rtx_reader::read_until): New method.
37675         (read_flags): New function.
37676         (parse_reg_note_name): New function.
37677         (rtx_reader::read_rtx_code): Initialize "iterator" to NULL.
37678         Handle reuse_rtx ids.
37679         Wrap iterator lookup within #ifdef GENERATOR_FILE.
37680         Add parsing support for RTL dumps, mirroring the special-cases in
37681         print_rtx, by calling read_flags, reading REG_NOTE names, INSN_UID
37682         values, and calling handle_any_trailing_information.
37683         (rtx_reader::read_rtx_operand): Convert return type from void
37684         to rtx, returning return_rtx.  Handle case 'e'.  Call
37685         finalize_string on XSTR and XTMPL fields.
37686         (rtx_reader::read_nested_rtx):  Handle dumps in which trailing
37687          "(nil)" values were omitted.  Call the postprocess vfunc on the
37688         return_rtx.
37689         (rtx_reader::rtx_reader): Add new "compact" param and pass to base
37690         class ctor.  Initialize m_in_call_function_usage.  Call
37691         one_time_initialization.
37692         * rtl-tests.c (selftest::test_uncond_jump): Call
37693         set_new_first_and_last_insn.
37694         * rtl.h (read_rtx): Wrap decl with #ifdef GENERATOR_FILE.
37695         * selftest-rtl.c: New file.
37696         * selftest-rtl.h (class selftest::rtl_dump_test): New class.
37697         (selftest::get_insn_by_uid): New decl.
37698         * selftest-run-tests.c (selftest::run_tests): Call
37699         read_rtl_function_c_tests.
37700         * selftest.h  (selftest::read_rtl_function_c_tests): New decl.
37701         * tree-dfa.c (ssa_default_def): Return NULL_TREE for rtl function
37702         dumps.
37704 2017-01-05  Uros Bizjak  <ubizjak@gmail.com>
37706         * config/i386/i386.md (*testqi_ext_3): No need to handle memory
37707         operands in a special way.  Assert that pos+len <= mode precision.
37709 2017-01-05  Jakub Jelinek  <jakub@redhat.com>
37711         * common.opt (fvect-cost-model): Remove RejectNegative flag, use
37712         3 argument Alias with unlimited for the negative form.
37713         (fno-vect-cost-model): Removed.
37715 2017-01-05  Martin Liska  <mliska@suse.cz>
37717         * hsa-gen.c (gen_hsa_divmod): New function.
37718         (gen_hsa_insn_for_internal_fn_call): Use the function for IFN_DIVMOD.
37720 2017-01-05  Martin Liska  <mliska@suse.cz>
37722         PR pch/78970
37723         * gcc.c (lookup_compiler): Reject '-' filename for a precompiled
37724         header.
37726 2017-01-05  Andreas Krebbel  <krebbel@linux.vnet.ibm.com>
37728         * config/s390/s390.c (s390_expand_setmem): Unroll the loop for
37729         small constant length operands.
37731 2017-01-05  Andreas Krebbel  <krebbel@linux.vnet.ibm.com>
37733         * config/s390/s390.c (s390_expand_setmem): Avoid overlapping bytes
37734         between loop iterations.
37736 2017-01-05  Martin Liska  <mliska@suse.cz>
37738         PR sanitizer/78815
37739         * gimplify.c (gimplify_decl_expr): Compare to
37740         asan_poisoned_variables instread of checking flags.
37741         (gimplify_target_expr): Likewise.
37742         (gimplify_expr): Likewise.
37743         (gimplify_function_tree): Conditionally initialize
37744         asan_poisoned_variables.
37746 2017-01-04  Jeff Law  <law@redhat.com>
37748         PR tree-optimizatin/78812
37749         * rtl.h (contains_mem_rtx_p): Prototype.
37750         * ifcvt.c (containts_mem_rtx_p): Move from here to...
37751         * rtlanal.c (contains_mem_rtx_p): Here and remove static linkage.
37752         * gcse.c (prune_expressions): Use contains_mem_rtx_p to discover
37753         and prune MEMs that are not at the toplevel of a SET_SRC rtx.  Look
37754         through ZERO_EXTEND and SIGN_EXTEND when trying to avoid pruning MEMs.
37756 2017-01-04  Alexandre Oliva <aoliva@redhat.com>
37758         * input.c (assert_char_at_range): Default-initialize actual_range.
37760 2017-01-04  Alexandre Oliva <aoliva@redhat.com>
37762         * df-scan.c (df_ref_create_structure): Make regno unsigned,
37763         to match the caller.
37765 2017-01-04  Alexandre Oliva <aoliva@redhat.com>
37767         * cfgexpand.c (expand_gimple_basic_block): Disregard debug
37768         insns after final jump in test to emit dummy move.
37770 2017-01-04  Alexandre Oliva <aoliva@redhat.com>
37772         * gimple-iterator.h (gsi_one_nondebug_before_end_p): New.
37773         * tree-eh.c (cleanup_empty_eh): Skip more debug stmts.
37775 2017-01-04  Alexandre Oliva <aoliva@redhat.com>
37777         * multiple_target.c (create_dispatcher_calls): Init e_next.
37778         * tree-ssa-loop-split.c (split_loop): Init border.
37779         * tree-vect-loop.c (vect_determine_vectorization_factor): Init
37780         scalar_type.
37782 2017-01-04  Michael Meissner  <meissner@linux.vnet.ibm.com>
37784         PR target/71977
37785         PR target/70568
37786         PR target/78823
37787         * config/rs6000/predicates.md (sf_subreg_operand): New predicate.
37788         (altivec_register_operand): Do not return true if the operand
37789         contains a SUBREG mixing SImode and SFmode.
37790         (vsx_register_operand): Likewise.
37791         (vsx_reg_sfsubreg_ok): New predicate.
37792         (vfloat_operand): Do not return true if the operand contains a
37793         SUBREG mixing SImode and SFmode.
37794         (vint_operand): Likewise.
37795         (vlogical_operand): Likewise.
37796         (gpc_reg_operand): Likewise.
37797         (int_reg_operand): Likewise.
37798         * config/rs6000/rs6000-protos.h (valid_sf_si_move): Add declaration.
37799         * config/rs6000/rs6000.c (valid_sf_si_move): New function to
37800         determine if a MOVSI or MOVSF operation contains SUBREGs that mix
37801         SImode and SFmode.
37802         (rs6000_emit_move_si_sf_subreg): New helper function.
37803         (rs6000_emit_move): Call rs6000_emit_move_si_sf_subreg to possbily
37804         fixup SUBREGs involving SImode and SFmode.
37805         * config/rs6000/vsx.md (SFBOOL_*): New constants that are operand
37806         numbers for the new peephole2 optimization.
37807         (peephole2 for SFmode unions): New peephole2 to optimize cases in
37808         the GLIBC math library that do AND/IOR/XOR operations on single
37809         precision floating point.
37810         * config/rs6000/rs6000.h (TARGET_NO_SF_SUBREG): New internal
37811         target macros to say whether we need to avoid SUBREGs mixing
37812         SImode and SFmode.
37813         (TARGET_ALLOW_SF_SUBREG): Likewise.
37814         * config/rs6000/rs6000.md (UNSPEC_SF_FROM_SI): New unspecs.
37815         (UNSPEC_SI_FROM_SF): Likewise.
37816         (iorxor): Change spacing.
37817         (and_ior_xor): New iterator for AND, IOR, and XOR.
37818         (movsi_from_sf): New insns for SImode/SFmode SUBREG support.
37819         (movdi_from_sf_zero_ext): Likewise.
37820         (mov<mode>_hardfloat, FMOVE32 iterator): Use register_operand
37821         instead of gpc_reg_operand.  Add SImode/SFmode SUBREG support.
37822         (movsf_from_si): New insn for SImode/SFmode SUBREG support.
37823         (fma<mode>4): Use gpc_reg_operand instead of register_operand.
37824         (fms<mode>4): Likewise.
37825         (fnma<mode>4): Likewise.
37826         (fnms<mode>4): Likewise.
37827         (nfma<mode>4): Likewise.
37828         (nfms<mode>4): Likewise.
37830 2017-01-04  Marek Polacek  <polacek@redhat.com>
37832         PR c++/64767
37833         * doc/invoke.texi: Document -Wpointer-compare.
37835 2017-01-04  Jakub Jelinek  <jakub@redhat.com>
37837         * optc-gen.awk: Emit #error for -W*/-f*/-m* Enum without
37838         RejectNegative.
37840         * dwarf2out.c (output_loc_list): Don't throw away 64K+ location
37841         descriptions for -gdwarf-5 and emit them as uleb128 instead of
37842         2-byte data.
37844 2017-01-04  Kelvin Nilsen  <kelvin@gcc.gnu.org>
37846         PR target/78056
37847         * doc/sourcebuild.texi (PowerPC-specific attributes): Add
37848         documentation of the powerpc_popcntb_ok attribute.
37849         * config/rs6000/rs6000.c (rs6000_option_override_internal): Add
37850         code to issue warning messages if a requested CPU configuration is
37851         not supported by the binary (assembler and loader) toolchain.
37852         (spe_init_builtins): Add two assertions to prevent ICE if attempt is
37853         made to define a built-in function that has been disabled.
37854         (paired_init_builtins): Add assertion to prevent ICE if attempt is
37855         made to define a built-in function that has been disabled.
37856         (altivec_init_builtins): Add comment explaining why definition
37857         of the DST built-in functions is not preceded by an assertion
37858         check.  Add assertions to prevent ICE if attempts are made to
37859         define an altivec predicate or an abs* built-in function that has
37860         been disabled.
37861         (htm_init_builtins): Add comment explaining why definition of the
37862         htm built-in functions is not preceded by an assertion check.
37864 2017-01-04  Jeff Law  <law@redhat.com>
37866         PR tree-optimizatin/67955
37867         * tree-ssa-alias.c (same_addr_size_stores_p): Check offsets first.
37868         Allow any SSA_VAR_P as the base objects.  Use integer_zerop.  Verify
37869         the points-to solution does not include pt_null.  Use DECL_PT_UID
37870         unconditionally.
37872 2017-01-04  Uros Bizjak  <ubizjak@gmail.com>
37874         * config/i386/i386.md (HI/SImode test with imm to QImode splitters):
37875         Use gen_int_mode instead of gen_lopwart for const_int operands.
37877 2017-01-04  Jakub Jelinek  <jakub@redhat.com>
37879         PR tree-optimization/71563
37880         * match.pd: Simplify X << Y into X if Y is known to be 0 or
37881         out of range value - has low bits known to be zero.
37883 2017-01-04  Alan Modra  <amodra@gmail.com>
37885         * Makefile.in (aclocal_deps): Update and order as per aclocal.m4.
37886         * configure: Regenerate.
37887         * config.in: Regenerate.
37889 2017-01-04  Jakub Jelinek  <jakub@redhat.com>
37891         PR bootstrap/77569
37892         * input.c (ebcdic_execution_charset::on_error): Don't use strstr for
37893         a substring of the message, but strcmp with the whole message.  Ifdef
37894         ENABLE_NLS, translate the message first using dgettext.
37896 2017-01-03  Jeff Law  <law@redhat.com>
37898         PR tree-optimizatin/78856
37899         * tree-ssa-threadupdate.c: Include tree-vectorizer.h.
37900         (mark_threaded_blocks): Remove code to truncate thread paths that
37901         cross multiple loop headers.  Instead invalidate the cached loop
37902         iteration information and handle case of a thread path walking
37903         into an irreducible region.
37905 2017-01-03  Michael Meissner  <meissner@linux.vnet.ibm.com>
37907         PR target/78900
37908         * config/rs6000/rs6000.c (rs6000_split_signbit): Change some
37909         assertions.  Add support for doing the signbit if the IEEE 128-bit
37910         floating point value is in a GPR.
37911         * config/rs6000/rs6000.md (Fsignbit): Delete.
37912         (signbit<mode>2_dm): Delete using <Fsignbit> and just use "wa".
37913         Update the length attribute if the value is in a GPR.
37914         (signbit<mode>2_dm_<su>ext): Add combiner pattern to eliminate
37915         the sign or zero extension instruction, since the value is always 0/1.
37916         (signbit<mode>2_dm2): Delete using <Fsignbit>.
37918         PR target/78953
37919         * config/rs6000/vsx.md (vsx_extract_<mode>_store_p9): If we are
37920         extracting SImode to a GPR register so that we can generate a
37921         store, limit the vector to be in a traditional Altivec register
37922         for the vextuwrx instruction.
37924 2017-01-03  Ian Lance Taylor  <iant@google.com>
37926         * godump.c (go_format_type): Treat ENUMERAL_TYPE like INTEGER_TYPE.
37928 2017-01-03  Martin Sebor  <msebor@redhat.com>
37930         PR tree-optimization/78696
37931         * gimple-ssa-sprintf.c (format_floating): Correct handling of
37932         precision.  Use MPFR for %f for greater fidelity.  Correct handling
37933         of %g.
37934         (pass_sprintf_length::compute_format_length): Set width and precision
37935         specified by asrerisk to void_node for vararg functions.
37936         (try_substitute_return_value): Adjust dump output.
37938 2017-01-03  David Edelsohn  <dje.gcc@gmail.com>
37940         * doc/invoke.texi (RS6000 options): LRA is enabled by default.
37942 2017-01-03  Eric Botcazou  <ebotcazou@adacore.com>
37944         * doc/invoke.texi (SPARC options): Document -mlra as the default.
37945         * config/sparc/sparc.c (sparc_option_override): Force LRA unless
37946         -mlra/-mno-lra was passed to the compiler.
37948 2017-01-03  James Cowgill  <James.Cowgill@imgtec.com>
37950         PR rtl-optimization/65618
37951         * emit-rtl.c (try_split): Move initialization of "before" and
37952         "after" to just before the call to emit_insn_after_setloc.
37954 2017-01-03  Gerald Pfeifer  <gerald@pfeifer.com>
37956         * doc/md.texi (Standard Names): Remove reference to Java frontend.
37958 2017-01-03  Pierre-Marie de Rodat  <derodat@adacore.com>
37960         * dwarf2out.c (gen_enumeration_type_die): When
37961         -gno-strict-dwarf, add a DW_AT_encoding attribute.
37963 2017-01-03  Jakub Jelinek  <jakub@redhat.com>
37965         PR tree-optimization/78965
37966         * gimple-ssa-sprintf.c (pass_sprintf_length::compute_format_length):
37967         Change first argument from const call_info & to call_info &.  For %n
37968         set info.nowrite to false.
37970         PR middle-end/78901
37971         * gimple-ssa-sprintf.c (try_substitute_return_value): Don't change
37972         possibly throwing calls.
37974         * genmatch.c (dt_node::gen_kids_1): If generic_exprs include SSA_NAME
37975         and exprs_len || fns_len, emit the code for SSA_NAME next to the exprs
37976         and fns handling, rather than in a separate case SSA_NAME.
37978 2017-01-02  Jeff Law  <law@redhat.com>
37980         * config/darwin-driver.c (darwin_driver_init): Const-correctness
37981         fixes for first_period and second_period variables.
37983 2017-01-02  Uros Bizjak  <ubizjak@gmail.com>
37985         PR target/78967
37986         * config/i386/i386.md (UNSPEC_NOREX_MEM): New unspec.
37987         (*insvqi_1): New insn pattern.
37988         (*insvqi_1_mem_rex64): Ditto.
37989         (*insvqi_2): Ditto.
37990         (*insvqi_3): Rename from *insvqi.
37992         (*extzvqi_mem_rex64): Add UNSPEC_NOREX_MEM tag.
37994 2017-01-02  Gerald Pfeifer  <gerald@pfeifer.com>
37996         * doc/cfg.texi (Edges): Remove reference to Java.
37997         (Maintaining the CFG): Ditto.
37999 2017-01-01  Jan Hubicka  <hubicka@ucw.cz>
38001         PR middle-end/77674
38002         * symtab.c (symtab_node::binds_to_current_def_p): Fix handling of
38003         transparent aliases.
38005 2017-01-01  Jan Hubicka  <hubicka@ucw.cz>
38007         PR middle-end/77484
38008         * predict.def (PRED_CALL): Update hitrate.
38009         (PRED_INDIR_CALL, PRED_POLYMORPHIC_CALL): New predictors.
38010         * predict.c (tree_estimate_probability_bb): Split CALL predictor
38011         into direct/indirect/polymorphic variants.
38013 2017-01-01  Jakub Jelinek  <jakub@redhat.com>
38015         Update copyright years.
38017         * gcc.c (process_command): Update copyright notice dates.
38018         * gcov-dump.c (print_version): Ditto.
38019         * gcov.c (print_version): Ditto.
38020         * gcov-tool.c (print_version): Ditto.
38021         * gengtype.c (create_file): Ditto.
38022         * doc/cpp.texi: Bump @copying's copyright year.
38023         * doc/cppinternals.texi: Ditto.
38024         * doc/gcc.texi: Ditto.
38025         * doc/gccint.texi: Ditto.
38026         * doc/gcov.texi: Ditto.
38027         * doc/install.texi: Ditto.
38028         * doc/invoke.texi: Ditto.
38030 Copyright (C) 2017 Free Software Foundation, Inc.
38032 Copying and distribution of this file, with or without modification,
38033 are permitted in any medium without royalty provided the copyright
38034 notice and this notice are preserved.