Comparison with an enum should mention enum value.
[gcc.git] / gcc / ChangeLog
1 2018-12-27 Martin Liska <mliska@suse.cz>
2
3 * builtins.c (expand_movstr): Compare with RETURN_BEGIN.
4 * expr.c (move_by_pieces): Likewise.
5 (store_by_pieces): Likewise.
6 (store_expr): Fix GNU coding style.
7
8 2018-12-26 Andrew Pinski <apinski@marvell.com>
9
10 * config/aarch64/aarch64-cores.def (octeontx): New.
11 (octeontx81): Likewise.
12 (octeontx83): Likewise.
13 * config/aarch64/aarch64-tune.md: Regenerate.
14 * doc/invoke.texi (AArch64 Options) [mtune]: Add octeontx, octeontx81
15 and octeontx83.
16
17 2018-12-24 Martin Sebor <msebor@redhat.com>
18
19 * gimple-fold.c (get_range_strlen_tree): Factored out of
20 get_range_strlen. Minor comment updates/additions. Assert
21 argument is not a simple SSA_NAME.
22 (get_range_strlen): Call get_range_strlen_tree as appropriate.
23 Minor comment updates/additions.
24
25 2018-12-24 Jan Hubicka <hubicka@ucw.cz>
26
27 * ipa-devirt.c (dump_targets): Cap number of targets printed.
28 (dump_possible_polymorphic_call_targets): Add verbose parameter.
29 (ipa_devirt): Use it.
30 * ipa-utils.h (dump_possible_polymorphic_call_targets): Add verbose
31 parametrs.
32
33 2018-12-24 Jan Hubicka <hubicka@ucw.cz>
34
35 PR lto/88140
36 * tree.c (fld_simplified_type): Temporarily disable array
37 simplification.
38
39 2018-12-24 Jan Hubicka <hubicka@ucw.cz>
40
41 * lto-symtab.c (lto_symtab_merge_decls_2): Do not report ODR violations
42 for method whose basetype was already reported.
43 * ipa-devirt.c (odr_type_violation_reported_p): New.
44 * ipa-utils.h (odr_type_violation_reported_p): Declare.
45
46 2018-12-24 Iain Sandoe <iain@sandoe.co.uk>
47
48 * configure.ac (dwarf2_debug_line): Check for the debug_line
49 section using otool when there’s no objdump available.
50 * configure: Regenerate.
51
52 2018-12-24 Jan Hubicka <hubicka@ucw.cz>
53
54 * ipa-utils.c (ipa_merge_profiles): Fix updating of fnsummary;
55 also handle rescaling of mismatched profiles.
56 * ipa-fnsummary.c (analyze_function): Handle speculative edges.
57
58 2018-12-23 Martin Sebor <msebor@redhat.com>
59 Jeff Law <law@redhat.com>
60
61 * builtins.h (c_strlen_data): Add new fields and comments.
62 * builtins.c (unterminated_array): Change field reference from
63 "len" to "minlen" in c_strlen_data instance.
64 * gimple-fold.c (get_range_strlen): Likewise.
65 * gimple-ssa-sprintf.c (get_string_length): Likewise.
66
67 * builtins.c (unterminated_array): Rename "data" to "lendata". Fix
68 a few comments.
69 (expand_builtin_strnlen, expand_builtin_stpcpy_1): Likewise.
70 (fold_builtin_strlen): Likewise.
71 * gimple-fold.c (get_range_strlen): Likewise. Also rename a couple
72 instances of "type" to "optype" and "arg" to "fld".
73
74 * builtins.c (unterminated_array): Use empty brace initialization
75 for c_strlen_data.
76 (c_strlen, expand_builtin_strnlen): Likewise.
77 (expand_builtin_stpcpy_1, fold_builtin_strlen): Likewise.
78 * gimple-fold.c (get_range_strlen): Likewise.
79 (gimple_fold_builtin_stpcpy): Likewise.
80 * gimple-ssa-sprintf.c (get_string_length): Likewise.
81
82 2018-12-23 Alan Modra <amodra@gmail.com>
83
84 PR 88346
85 * config/rs6000/rs6000.h (ASM_CPU_SPEC): Correct %e message. Handle
86 -mcpu=rs64, not -mcpu=rs64a. Handle -mcpu=powerpc64 and -mcpu=titan.
87 * config/rs6000/driver-rs6000.c (asm_names): Similarly.
88 * config/rs6000/aix71.h (ASM_CPU_SPEC): Delete %e message. Handle
89 -mcpu=rs64, not -mcpu=rs64a.
90 * config/rs6000/aix72.h (ASM_CPU_SPEC): Likewise.
91
92 2018-12-23 Iain Sandoe <iain@sandoe.co.uk>
93
94 * lto-wrapper.c (tool_cleanup): Don’t report ficticious temp files.
95 (debug_objcopy): Improve temp filenames. Append the early
96 debug objects to the outfiles. Remove the phase prelinking the
97 early debug. Emit the early debug filenames for ld.
98
99 2018-12-23 Iain Sandoe <iain@sandoe.co.uk>
100
101 * config/i386/darwin.h (TARGET_ASM_OUTPUT_IDENT): New.
102
103 2018-12-23 Iain Sandoe <iain@sandoe.co.uk>
104
105 * collect2.c (maybe_run_lto_and_relink): Don’t say we have a temp file
106 unless we actually did some LTO.
107 (has_lto_section, is_lto_object_file): New.
108 (maybe_lto_object_file): Remove.
109 (scan_prog_file): Use is_lto_object_file() instead of scanning the
110 output of nm.
111
112 2018-12-23 Iain Sandoe <iain@sandoe.co.uk>
113
114 * collect2.c (main): Parse the output file early so we can make nicer
115 temp names. Respond to “-save-temps” in the GCC OPTIONS.
116 (maybe_unlink): Don’t print “[Leaving…”] for files we never created
117 and don’t exist.
118
119 2018-12-23 Iain Sandoe <iain@sandoe.co.uk>
120
121 * collect2.c (main): Combine flags from both the command line and
122 COLLECT_GCC_OPTIONS to determine the set in force
123
124 2018-12-21 Jan Hubicka <hubicka@ucw.cz>
125
126 * ipa-utils.c (ipa_merge_profiles): Recompute summaries.
127
128 2018-12-21 Jakub Jelinek <jakub@redhat.com>
129
130 PR middle-end/85594
131 PR middle-end/88553
132 * omp-expand.c (extract_omp_for_update_vars): Regimplify the condition
133 if needed.
134 (expand_omp_for_generic): Don't clobber t temporary for ordered loops.
135
136 2018-12-15 Jan Hubicka <hubicka@ucw.cz>
137
138 PR ipa/88561
139 * ipa-polymorphic-call.c
140 (ipa_polymorphic_call_context::ipa_polymorphic_call_context): Handle
141 arguments of thunks correctly.
142 (ipa_polymorphic_call_context::get_dynamic_context): Be ready for
143 NULL instance pinter.
144 * lto-cgraph.c (lto_output_node): Always stream thunk info.
145
146 2018-12-21 Andreas Krebbel <krebbel@linux.ibm.com>
147
148 * config/s390/vector.md ("floatv2div2df2", "floatunsv2div2df2")
149 ("fix_truncv2dfv2di2", "fixuns_truncv2dfv2di2"): New pattern
150 definitions.
151
152 2018-12-21 Eric Botcazou <ebotcazou@adacore.com>
153
154 PR rtl-optimization/87727
155 * combine.c (cant_combine_insn_p): On a LEAF_REGISTERS target, combine
156 again moves from leaf hard registers.
157
158 * final.c (final_scan_insn_1) <NOTE_INSN_INLINE_ENTRY>: Minor tweak.
159
160 2018-12-21 Jakub Jelinek <jakub@redhat.com>
161
162 PR target/88522
163 * config/i386/sse.md (*avx512pf_gatherpf<mode>sf_mask,
164 *avx512pf_gatherpf<mode>df_mask, *avx512pf_scatterpf<mode>sf_mask,
165 *avx512pf_scatterpf<mode>df_mask): Use %X5 instead of %5 for
166 -masm=intel.
167 (gatherq_mode): Remove mode iterator.
168 (*avx512f_gathersi<mode>, *avx512f_gathersi<mode>_2): Use X instead
169 of <xtg_mode>.
170 (*avx512f_gatherdi<mode>): Use X instead of <gatherq_mode>.
171 (*avx512f_gatherdi<mode>_2, *avx512f_scattersi<mode>,
172 *avx512f_scatterdi<mode>): Use %X5 for -masm=intel.
173
174 PR rtl-optimization/88563
175 * expr.c (expand_expr_real_2) <case WIDEN_MULT_EXPR>: Swap innermode
176 and mode arguments to convert_modes. Likewise swap mode and word_mode
177 arguments. Handle both arguments with VOIDmode before convert_modes
178 of one of them. Formatting fixes.
179
180 2018-12-21 Uros Bizjak <ubizjak@gmail.com>
181
182 PR target/88556
183 * internal-fn.def (COSH): New.
184 (SINH): Ditto.
185 (TANH): Ditto.
186 * optabs.def (cosh_optab): New.
187 (sinh_optab): Ditto.
188 (tanh_optab): Ditto.
189 * config/i386/i386-protos.h (ix86_emit_i387_sinh): New prototype.
190 (ix86_emit_i387_cosh): Ditto.
191 (ix86_emit_i387_tanh): Ditto.
192 * config/i386/i386.c (ix86_emit_i387_sinh): New function.
193 (ix86_emit_i387_cosh): Ditto.
194 (ix86_emit_i387_tanh): Ditto.
195 * config/i386/i386.md (sinhxf2): New expander.
196 (sinh<mode>2): Ditto.
197 (coshxf2): Ditto.
198 (cosh<mode>2): Ditto.
199 (tanhxf2): Ditto.
200 (tanh<mode>2): Ditto.
201
202 2018-12-21 Jakub Jelinek <jakub@redhat.com>
203
204 PR target/88547
205 * config/i386/i386.c (ix86_expand_int_sse_cmp): Optimize
206 x > y ? 0 : -1 into min (x, y) == x ? -1 : 0.
207
208 2018-12-21 Jan Beulich <jbeulich@suse.com>
209
210 * config/i386/sse.md (vaesdec_<mode>, vaesdeclast_<mode>): Allow
211 memory input.
212
213 2018-12-21 Alexandre Oliva <oliva@adacore.com>
214
215 * config.gcc (tmake_file): Add name to tmake_file for
216 each @name in --with-multilib-list on arm-*-* targets.
217 * doc/install.texi (with-multilib-list): Document it.
218
219 2018-12-21 Jakub Jelinek <jakub@redhat.com>
220
221 * tree-vect-data-refs.c (vect_enhance_data_refs_alignment): Use
222 DR_TARGET_ALIGNMENT on dr_info rather than dr. Spelling fixes.
223
224 2018-12-20 Joern Rennecke <joern.rennecke@riscy-ip.com>
225
226 * tree-vect-data-refs.c (vect_enhance_data_refs_alignment): Don't do
227 versioning for data accesses with misaligned step.
228
229 2018-12-20 H.J. Lu <hongjiu.lu@intel.com>
230
231 PR c/51628
232 * doc/invoke.texi: Document -Wno-address-of-packed-member.
233
234 2018-12-20 Vladimir Makarov <vmakarov@redhat.com>
235
236 PR target/88457
237 * ira-color.c (fast_allocation): Choose the best cost hard reg.
238
239 2018-12-20 Richard Sandiford <richard.sandiford@arm.com>
240
241 * config/aarch64/iterators.md (SVE_INT_UNARY, fp_int_op): Add abs.
242 (SVE_FP_UNARY): Sort.
243
244 2018-12-20 Richard Sandiford <richard.sandiford@arm.com>
245
246 * config/aarch64/aarch64-sve.md (*cond_<optab><mode>_4): Use
247 sve_fmla_op rather than sve_fmad_op for the movprfx alternative.
248
249 2018-12-20 Martin Jambor <mjambor@suse.cz>
250
251 PR ipa/88214
252 * tree-ssa-alias.c (ao_ref_init_from_ptr_and_size): Assert that
253 ptr is a pointer.
254
255 2018-12-20 Richard Biener <rguenther@suse.de>
256
257 PR tree-optimization/84362
258 * tree-ssa-loop-im.c: Include alias.h, builtins.h and tree-dfa.h.
259 (struct im_mem_ref): add ref_canonical flag.
260 (struct mem_ref_hasher): Use ao_ref as compare_type.
261 (mem_ref_hasher::equal): Adjust and add variant comparing ao_ref
262 parts.
263 (mem_ref_alloc): Take ao_ref parameter, initialize ref_canonical
264 member.
265 (gather_mem_refs_stmt): Set up ao_ref early and do the lookup
266 using it. If we have non-equal refs canonicalize the one
267 in the hashtable used for insertion.
268 (tree_ssa_lim_initialize): Adjust.
269
270 2018-12-20 Jakub Jelinek <jakub@redhat.com>
271
272 PR target/88547
273 * config/i386/i386.c (ix86_expand_sse_movcc): For maskcmp, try to
274 emit vpmovm2? instruction perhaps after knot?. Reorganize code
275 so that it doesn't have to test !maskcmp in almost every conditional.
276
277 2018-12-20 Alan Modra <amodra@gmail.com>
278
279 * config/rs6000/sysv4.h (GNU_USER_DYNAMIC_LINKER): Define.
280
281 2018-12-19 Andreas Tobler <andreast@gcc.gnu.org>
282
283 * config.gcc: Enable TARGET_DEFAULT_ASYNC_UNWIND_TABLES on
284 aarch64*-*-freebsd*
285
286 2018-12-19 Uros Bizjak <ubizjak@gmail.com>
287
288 * config/i386/i386.md (SWI1248_AVX512BWDQ_64): Rename from
289 SWI1248_AVX512BWDQ2_64. Unconditionally enable HImode.
290 (*cmp<mode>_ccz_1): Emit kortest instead of ktest insn.
291 Use SWI1248_AVX512BWDQ_64 mode iterator and enable only for
292 TARGET_AVX512F.
293
294 2018-12-19 Thomas Preud'homme <thomas.preudhomme@linaro.org>
295
296 * config/arm/elf.h: Update comment about condition that need to
297 match with libgcc/config/arm/lib1funcs.S to also include
298 libgcc/config/arm/t-arm.
299 * doc/sourcebuild.texi (output-exists, output-exists-not): Rename
300 subsubsection these directives are in to "Check for output files".
301 Move scan-symbol to that section and add to it new scan-symbol-not
302 directive.
303
304 2018-12-19 Tom de Vries <tdevries@suse.de>
305
306 * config/nvptx/nvptx.c (PTX_CTA_SIZE): Define.
307
308 2018-12-19 Tom de Vries <tdevries@suse.de>
309
310 * omp-offload.c (oacc_fn_attrib_level): Remove static.
311 * omp-offload.h (oacc_fn_attrib_level): Declare.
312
313 2018-12-19 Tom de Vries <tdevries@suse.de>
314
315 * omp-offload.c (oacc_get_default_dim): New function.
316 * omp-offload.h (oacc_get_default_dim): Declare.
317
318 2018-12-19 David Malcolm <dmalcolm@redhat.com>
319
320 PR c++/87504
321 * gcc-rich-location.c
322 (maybe_range_label_for_tree_type_mismatch::get_text): Move here from
323 c/c-typeck.c.
324 (binary_op_rich_location::binary_op_rich_location): New ctor.
325 (binary_op_rich_location::use_operator_loc_p): New function.
326 * gcc-rich-location.h
327 (class maybe_range_label_for_tree_type_mismatch)): Move here from
328 c/c-typeck.c.
329 (struct op_location_t): New forward decl.
330 (class binary_op_rich_location): New class.
331 * tree.h (struct op_location_t): New struct.
332
333 2018-12-19 David Malcolm <dmalcolm@redhat.com>
334
335 PR c++/43064
336 PR c++/43486
337 * convert.c: Include "selftest.h".
338 (preserve_any_location_wrapper): New function.
339 (convert_to_pointer_maybe_fold): Update to handle location
340 wrappers.
341 (convert_to_real_maybe_fold): Likewise.
342 (convert_to_integer_1): Strip expr when using TREE_OVERFLOW.
343 Handle location wrappers when checking for INTEGER_CST.
344 (convert_to_integer_maybe_fold): Update to handle location
345 wrappers.
346 (convert_to_complex_maybe_fold): Likewise.
347 (selftest::test_convert_to_integer_maybe_fold): New functions.
348 (selftest::convert_c_tests): New function.
349 * convert.h (preserve_any_location_wrapper): New decl.
350 * fold-const.c (size_binop_loc): Strip location wrappers when
351 using TREE_OVERFLOW.
352 (operand_equal_p): Strip any location wrappers.
353 (integer_valued_real_p): Strip any location wrapper.
354 * selftest-run-tests.c (selftest::run_tests): Call
355 selftest::convert_c_tests.
356 * selftest.h (selftest::convert_c_tests): New decl.
357 * tree.c (build_complex): Assert that REAL and IMAG are constants.
358 (integer_zerop): Look through location wrappers.
359 (integer_onep): Likewise.
360 (integer_each_onep): Likewise.
361 (integer_all_onesp): Likewise.
362 (integer_minus_onep): Likewise.
363 (integer_pow2p): Likewise.
364 (integer_nonzerop): Likewise.
365 (integer_truep): Likewise.
366 (fixed_zerop): Likewise.
367 (real_zerop): Likewise.
368 (real_onep): Likewise.
369 (real_minus_onep): Likewise.
370 (tree_int_cst_equal): Likewise.
371 (simple_cst_equal): Treat location wrappers with non-equal source
372 locations as being unequal.
373 (uniform_integer_cst_p): Look through location wrappers.
374 (maybe_wrap_with_location): Don't create wrappers if any
375 auto_suppress_location_wrappers are active.
376 (suppress_location_wrappers): New variable.
377 (selftest::test_predicates): New test.
378 (selftest::tree_c_tests): Call it.
379 * tree.h (CONSTANT_CLASS_OR_WRAPPER_P): New macro.
380 (suppress_location_wrappers): New decl.
381 (class auto_suppress_location_wrappers): New class.
382
383 2018-12-19 Paul A. Clarke <pc@us.ibm.com>
384
385 * config/rs6000/tmmintrin.h (_mm_hadds_epi16): Vector lanes swapped.
386 (_mm_hsub_epi32): Likewise.
387 (_mm_shuffle_epi8): Fix reversed interpretation of parameters.
388 (_mm_shuffle_pi8): Likewise.
389 (_mm_addubs_pi16): Likewise.
390
391 2018-12-19 Thomas Preud'homme <thomas.preudhomme@linaro.org>
392
393 * config/arm/arm.h (TARGET_HARD_FLOAT): Restrict to TARGET_32BIT
394 targets.
395 * config/arm/arm.c (output_return_instruction): Only check
396 TARGET_HARD_FLOAT to decide whether FP instructions are available.
397
398 2018-12-19 Tom de Vries <tom@codesourcery.com>
399
400 * doc/sourcebuild.texi (Commands for use in dg-final, Scan optimization
401 dump files): Add offload-rtl.
402
403 2018-12-19 Segher Boessenkool <segher@kernel.crashing.org>
404
405 PR target/88213
406 * config/rs6000/vsx.md (*vsx_extract_<P:mode>_<VSX_D:mode>_load):
407 Require TARGET_POWERPC64.
408
409 2018-12-19 Richard Biener <rguenther@suse.de>
410
411 PR tree-optimization/88533
412 Revert
413 2018-04-30 Richard Biener <rguenther@suse.de>
414
415 PR tree-optimization/28364
416 PR tree-optimization/85275
417 * tree-ssa-loop-ch.c (ch_base::copy_headers): Stop after
418 copying first exit test.
419
420 * tree-ssa-loop-ch.c: Include tree-phinodes.h and
421 ssa-iterators.h.
422 (should_duplicate_loop_header_p): Track whether stmt compute
423 loop invariants or values based on IVs. Apart from the
424 original loop header only duplicate blocks with exit tests
425 that are based on IVs or invariants.
426
427 2018-12-19 Tom de Vries <tdevries@suse.de>
428
429 * config/nvptx/nvptx.c (nvptx_gen_shared_bcast, shared_prop_gen)
430 (nvptx_goacc_expand_accel_var): Use MAX and ROUND_UP.
431 (nvptx_assemble_value, nvptx_output_skip): Use MIN.
432 (nvptx_shared_propagate, nvptx_single, nvptx_expand_shared_addr): Use
433 MAX.
434
435 2018-12-19 Tom de Vries <tdevries@suse.de>
436
437 * config/nvptx/nvptx.c (nvptx_gen_wcast): Rename as
438 nvptx_gen_warp_bcast.
439 (nvptx_gen_wcast): Rename to nvptx_gen_shared_bcast, add bool
440 vector argument, and update call to nvptx_gen_shared_bcast.
441 (propagator_fn): Add bool argument.
442 (nvptx_propagate): New bool argument, pass bool argument to fn.
443 (vprop_gen): Rename to warp_prop_gen, update call to
444 nvptx_gen_warp_bcast.
445 (nvptx_vpropagate): Rename to nvptx_warp_propagate, update call to
446 nvptx_propagate.
447 (wprop_gen): Rename to shared_prop_gen, update call to
448 nvptx_gen_shared_bcast.
449 (nvptx_wpropagate): Rename to nvptx_shared_propagate, update call
450 to nvptx_propagate.
451 (nvptx_wsync): Rename to nvptx_cta_sync.
452 (nvptx_single): Update calls to nvptx_gen_warp_bcast,
453 nvptx_gen_shared_bcast and nvptx_cta_sync.
454 (nvptx_process_pars): Likewise.
455 (write_worker_buffer): Rename as write_shared_buffer.
456 (nvptx_file_end): Update calls to write_shared_buffer.
457 (nvptx_expand_worker_addr): Rename as nvptx_expand_shared_addr.
458 (nvptx_expand_builtin): Update call to nvptx_expand_shared_addr.
459 (nvptx_get_worker_red_addr): Rename as nvptx_get_shared_red_addr.
460 (nvptx_goacc_reduction_setup): Update call to
461 nvptx_get_shared_red_addr.
462 (nvptx_goacc_reduction_fini): Likewise.
463 (nvptx_goacc_reduction_teardown): Likewise.
464
465 2018-12-19 Tom de Vries <tdevries@suse.de>
466
467 * config/nvptx/nvptx.c (worker_bcast_size): Rename as
468 oacc_bcast_size.
469 (worker_bcast_align): Rename as oacc_bcast_align.
470 (worker_bcast_sym): Rename as oacc_bcast_sym.
471 (nvptx_option_override): Update usage of oacc_bcast_*.
472 (struct wcast_data_t): Rename as broadcast_data_t.
473 (nvptx_gen_wcast): Update type of data argument and usage of
474 oacc_bcast_align.
475 (wprop_gen): Update type of data_ and usage of oacc_bcast_align.
476 (nvptx_wpropagate): Update type of data and usage of
477 oacc_bcast_{sym,size}.
478 (nvptx_single): Update type of data and usage of oacc_bcast_size.
479 (nvptx_file_end): Update usage of oacc_bcast_{sym,align,size}.
480
481 2018-12-19 Tom de Vries <tdevries@suse.de>
482
483 * config/nvptx/nvptx.md (nvptx_barsync): Add and handle operand.
484 * config/nvptx/nvptx.c (nvptx_wsync): Update call to gen_nvptx_barsync.
485
486 2018-12-19 Tom de Vries <tdevries@suse.de>
487
488 * config/nvptx/nvptx.c (nvptx_single): Always pass false to
489 nvptx_wsync.
490 (nvptx_process_pars): Likewise.
491
492 2018-12-19 Tom de Vries <tdevries@suse.de>
493
494 * config/nvptx/nvptx.c (nvptx_previous_fndecl): Declare.
495 (nvptx_set_current_function): New function.
496 (TARGET_SET_CURRENT_FUNCTION): Define.
497
498 2018-12-19 Shaokun Zhang <zhangshaokun@hisilicon.com>
499
500 * config/aarch64/aarch64-cores.def (tsv110): Fix architecture. This
501 part is really Armv8.2 with some permitted Armv8.4 extensions.
502
503 2018-12-19 Jakub Jelinek <jakub@redhat.com>
504
505 PR target/88541
506 * config/i386/vpclmulqdqintrin.h (_mm256_clmulepi64_epi128): Enable
507 for -mavx -mvpclmulqdq rather than just for -mavx512vl -mvpclmulqdq.
508
509 2018-12-19 Alexandre Oliva <aoliva@redhat.com>
510
511 PR testsuite/86153
512 PR middle-end/83239
513 * vr-values.c
514 (vr_values::vrp_evaluate_conditional_warnv_with_ops): Extend
515 simplification of overflow tests to cover cases in which we
516 can determine the result of the comparison.
517
518 2018-12-19 Bin Cheng <bin.cheng@linux.alibaba.com>
519
520 * auto-profile.c (afdo_indirect_call): Skip generating histogram
521 value if we can't find cgraph_node for then indirected callee. Save
522 profile_id of the cgraph_node in histogram value's first counter.
523 * value-prof.c (gimple_value_profile_transformations): Don't skip
524 for flag_auto_profile.
525
526 2018-12-18 Vladimir Makarov <vmakarov@redhat.com>
527
528 PR rtl-optimization/87759
529 * lra-assigns.c (lra_split_hard_reg_for): Recalculate
530 non_reload_pseudos.
531
532 2018-12-18 Jakub Jelinek <jakub@redhat.com>
533
534 PR target/88464
535 * config/i386/i386-builtin-types.def
536 (VOID_FTYPE_PDOUBLE_QI_V8SI_V4DF_INT,
537 VOID_FTYPE_PFLOAT_QI_V4DI_V8SF_INT,
538 VOID_FTYPE_PLONGLONG_QI_V8SI_V4DI_INT,
539 VOID_FTYPE_PINT_QI_V4DI_V8SI_INT,
540 VOID_FTYPE_PDOUBLE_QI_V4SI_V2DF_INT,
541 VOID_FTYPE_PFLOAT_QI_V2DI_V4SF_INT,
542 VOID_FTYPE_PLONGLONG_QI_V4SI_V2DI_INT,
543 VOID_FTYPE_PINT_QI_V2DI_V4SI_INT): New builtin types.
544 * config/i386/i386.c (enum ix86_builtins): Add
545 IX86_BUILTIN_SCATTERALTSIV4DF, IX86_BUILTIN_SCATTERALTDIV8SF,
546 IX86_BUILTIN_SCATTERALTSIV4DI, IX86_BUILTIN_SCATTERALTDIV8SI,
547 IX86_BUILTIN_SCATTERALTSIV2DF, IX86_BUILTIN_SCATTERALTDIV4SF,
548 IX86_BUILTIN_SCATTERALTSIV2DI and IX86_BUILTIN_SCATTERALTDIV4SI.
549 (ix86_init_mmx_sse_builtins): Fix up names of IX86_BUILTIN_GATHERALT*,
550 IX86_BUILTIN_GATHER3ALT* and IX86_BUILTIN_SCATTERALT* builtins to
551 match the IX86_BUILTIN codes. Build IX86_BUILTIN_SCATTERALTSIV4DF,
552 IX86_BUILTIN_SCATTERALTDIV8SF, IX86_BUILTIN_SCATTERALTSIV4DI,
553 IX86_BUILTIN_SCATTERALTDIV8SI, IX86_BUILTIN_SCATTERALTSIV2DF,
554 IX86_BUILTIN_SCATTERALTDIV4SF, IX86_BUILTIN_SCATTERALTSIV2DI and
555 IX86_BUILTIN_SCATTERALTDIV4SI decls.
556 (ix86_vectorize_builtin_scatter): Expand those new builtins.
557
558 2018-12-18 Bill Schmidt <wschmidt@linux.ibm.com>
559
560 * doc/extend.texi (PowerPC Altivec/VSX Built-in Functions):
561 Describe when a typedef name can be used as the type specifier for
562 a vector type, and when it cannot.
563
564 2018-12-18 Jozef Lawrynowicz <jozef.l@mittosystems.com>
565
566 * config/msp430/msp430.h: Define TARGET_VTABLE_ENTRY_ALIGN.
567
568 2018-12-18 Jakub Jelinek <jakub@redhat.com>
569
570 PR target/88513
571 PR target/88514
572 * optabs.def (vec_pack_sbool_trunc_optab, vec_unpacks_sbool_hi_optab,
573 vec_unpacks_sbool_lo_optab): New optabs.
574 * optabs.c (expand_widen_pattern_expr): Use vec_unpacks_sbool_*_optab
575 and pass additional argument if both input and target have the same
576 scalar mode of VECTOR_BOOLEAN_TYPE_P vectors.
577 * expr.c (expand_expr_real_2) <case VEC_PACK_TRUNC_EXPR>: Handle
578 VECTOR_BOOLEAN_TYPE_P pack where result has the same scalar mode
579 as the operands using vec_pack_sbool_trunc_optab.
580 * tree-vect-stmts.c (supportable_widening_operation): Use
581 vec_unpacks_sbool_{lo,hi}_optab for VECTOR_BOOLEAN_TYPE_P conversions
582 where both wider_vectype and vectype have the same scalar mode.
583 (supportable_narrowing_operation): Similarly use
584 vec_pack_sbool_trunc_optab if narrow_vectype and vectype have the same
585 scalar mode.
586 * config/i386/i386.c (ix86_get_builtin)
587 <case IX86_BUILTIN_GATHER3ALTDIV8SF>: Check for VECTOR_MODE_P
588 rather than non-VOIDmode.
589 * config/i386/sse.md (vec_pack_trunc_qi, vec_pack_trunc_<mode>):
590 Remove useless ()s around "register_operand", formatting fixes.
591 (vec_pack_sbool_trunc_qi, vec_unpacks_sbool_lo_qi,
592 vec_unpacks_sbool_hi_qi): New expanders.
593 * doc/md.texi (vec_pack_sbool_trunc_M, vec_unpacks_sbool_hi_M,
594 vec_unpacks_sbool_lo_M): Document.
595
596 2018-12-18 Jozef Lawrynowicz <jozef.l@mittosystems.com>
597
598 * combine.c (update_rsp_from_reg_equal): Only look for the nonzero bits
599 of src in nonzero_bits_mode if the mode of src is MODE_INT and
600 HWI_COMPUTABLE.
601 (reg_nonzero_bits_for_combine): Add clarification to comment.
602
603 2018-12-18 Wei Xiao <wei3.xiao@intel.com>
604
605 * config/i386/driver-i386.c (host_detect_local_cpu): Detect cascadelake.
606 * config/i386/i386.c (fold_builtin_cpu): Handle cascadelake.
607 * doc/extend.texi: Add cascadelake.
608 2018-12-17 Peter Bergner <bergner@linux.ibm.com>
609
610 PR target/87870
611 * config/rs6000/vsx.md (nW): New mode iterator.
612 (vsx_mov<mode>_64bit): Use it. Remove redundant GPR 0/-1 alternative.
613 Update length attribute for (<??r>, <nW>) alternative.
614 (vsx_mov<mode>_32bit): Likewise.
615
616 2018-12-17 Tom de Vries <tdevries@suse.de>
617
618 * config/nvptx/nvptx.c (PTX_VECTOR_LENGTH, PTX_WORKER_LENGTH,
619 PTX_DEFAULT_RUNTIME_DIM): Move to the top of the file.
620
621 2018-12-17 Tom de Vries <tdevries@suse.de>
622
623 * config/nvptx/nvptx.c (PTX_WARP_SIZE): Define.
624 (nvptx_simt_vf): Return PTX_WARP_SIZE instead of PTX_VECTOR_LENGTH.
625
626 2018-12-17 Tom de Vries <tdevries@suse.de>
627
628 * config/nvptx/nvptx.c (nvptx_single): Fix whitespace.
629 (nvptx_neuter_pars): Likewise.
630
631 2018-12-17 Tom de Vries <tdevries@suse.de>
632
633 * config/nvptx/nvptx.c (nvptx_goacc_validate_dims): Work around Fortran
634 bug PR72741 by overriding dims parameter for routines.
635
636 2018-12-17 Tom de Vries <tdevries@suse.de>
637
638 * config/nvptx/nvptx.c (nvptx_goacc_validate_dims): Rewrite using
639 predicate vars.
640
641 2018-12-17 Steve Ellcey <sellcey@cavium.com>
642
643 * config/aarch64/aarch64-protos.h (aarch64_use_simple_return_insn_p):
644 New prototype.
645 (aarch64_epilogue_uses): Ditto.
646 * config/aarch64/aarch64.c (aarch64_attribute_table): New array.
647 (aarch64_simd_decl_p): New function.
648 (aarch64_reg_save_mode): New function.
649 (aarch64_function_ok_for_sibcall): Check for simd calls.
650 (aarch64_layout_frame): Check for simd function.
651 (aarch64_gen_storewb_pair): Handle E_TFmode.
652 (aarch64_push_regs): Use aarch64_reg_save_mode to get mode.
653 (aarch64_gen_loadwb_pair): Handle E_TFmode.
654 (aarch64_pop_regs): Use aarch64_reg_save_mode to get mode.
655 (aarch64_gen_store_pair): Handle E_TFmode.
656 (aarch64_gen_load_pair): Ditto.
657 (aarch64_save_callee_saves): Handle different mode sizes.
658 (aarch64_restore_callee_saves): Ditto.
659 (aarch64_components_for_bb): Check for simd function.
660 (aarch64_epilogue_uses): New function.
661 (aarch64_process_components): Check for simd function.
662 (aarch64_expand_prologue): Ditto.
663 (aarch64_expand_epilogue): Ditto.
664 (aarch64_expand_call): Ditto.
665 (aarch64_use_simple_return_insn_p): New function.
666 (TARGET_ATTRIBUTE_TABLE): New define.
667 * config/aarch64/aarch64.h (EPILOGUE_USES): Redefine.
668 (FP_SIMD_SAVED_REGNUM_P): New macro.
669 * config/aarch64/aarch64.md (simple_return): New define_expand.
670 (load_pair_dw_tftf): New instruction.
671 (store_pair_dw_tftf): Ditto.
672 (loadwb_pair<TX:mode>_<P:mode>): Ditto.
673 (storewb_pair<TX:mode>_<P:mode>): Ditto.
674
675 2018-12-17 Uros Bizjak <ubizjak@gmail.com>
676
677 PR target/88502
678 * internal-fn.def (ACOSH): New.
679 (ASINH): Ditto.
680 (ATANH): Ditto.
681 * optabs.def (acosh_optab): New.
682 (asinh_optab): Ditto.
683 (atanh_optab): Ditto.
684 * config/i386/i386-protos.h (ix86_emit_i387_asinh): New prototype.
685 (ix86_emit_i387_acosh): Ditto.
686 (ix86_emit_i387_atanh): Ditto.
687 * config/i386/i386.c (ix86_emit_i387_asinh): New function.
688 (ix86_emit_i387_acosh): Ditto.
689 (ix86_emit_i387_atanh): Ditto.
690 * config/i386/i386.md (asinhxf2): New expander.
691 (asinh<mode>2): Ditto.
692 (acoshxf2): Ditto.
693 (acosh<mode>2): Ditto.
694 (atanhxf2): Ditto.
695 (atanh<mode>2): Ditto.
696
697 2018-12-17 David Edelsohn <dje.gcc@gmail.com>
698
699 * config.gcc (powerpc-ibm-aix6.*): Delete extra_headers.
700 (powerpc-ibm-aix7.1.*): Same.
701 (powerpc-ibm-aix[789].*): Same.
702
703 2018-12-17 H.J. Lu <hongjiu.lu@intel.com>
704
705 PR debug/79342
706 * dwarf2out.c (find_AT_string_in_table): Add insert argument
707 defaulting to INSERT and replace INSERT.
708 (find_AT_string): Likewise.
709 (output_macinfo_op): Pass NO_INSERT to find_AT_string.
710
711 2018-12-15 Jan Hubicka <hubicka@ucw.cz>
712
713 * coverage.c (struct conts_entry): Add n_counts.
714 (remap_counts_file): Record number of ocunts.
715 (get_coverage_counts): Verify that counts match.
716 * coverage.h (get_coverage_counts): Update prototype.
717 * profile.c (get_exec_counts. compute_value_histograms): Add
718 n_counts parametrs.
719
720 2018-12-17 Senthil Kumar Selvaraj <senthilkumar.selvaraj@microchip.com>
721
722 PR rtl-optimization/88253
723 * combine.c (combine_simplify_rtx): Test for side-effects before
724 substituting by zero.
725
726 2018-12-17 Richard Sandiford <richard.sandiford@arm.com>
727
728 * doc/invoke.texi (-fversion-loops-for-strides): Document
729 (loop-versioning-group-size, loop-versioning-max-inner-insns)
730 (loop-versioning-max-outer-insns): Document new --params.
731 * Makefile.in (OBJS): Add gimple-loop-versioning.o.
732 * common.opt (fversion-loops-for-strides): New option.
733 * opts.c (default_options_table): Enable fversion-loops-for-strides
734 at -O3.
735 * params.def (PARAM_LOOP_VERSIONING_GROUP_SIZE)
736 (PARAM_LOOP_VERSIONING_MAX_INNER_INSNS)
737 (PARAM_LOOP_VERSIONING_MAX_OUTER_INSNS): New parameters.
738 * passes.def: Add pass_loop_versioning.
739 * timevar.def (TV_LOOP_VERSIONING): New time variable.
740 * tree-ssa-propagate.h
741 (substitute_and_fold_engine::substitute_and_fold): Add an optional
742 block parameter.
743 * tree-ssa-propagate.c
744 (substitute_and_fold_engine::substitute_and_fold): Likewise.
745 When passed, only walk blocks dominated by that block.
746 * tree-vrp.h (range_includes_p): Declare.
747 (range_includes_zero_p): Turn into an inline wrapper around
748 range_includes_p.
749 * tree-vrp.c (range_includes_p): New function, generalizing...
750 (range_includes_zero_p): ...this.
751 * tree-pass.h (make_pass_loop_versioning): Declare.
752 * gimple-loop-versioning.cc: New file.
753
754 2018-12-15 Jan Hubicka <hubicka@ucw.cz>
755
756 * ipa-fnsummary.c (remap_edge_change_prob): Do not ICE when changes
757 are not streamed in.
758
759 2018-12-15 H.J. Lu <hongjiu.lu@intel.com>
760
761 PR target/88483
762 * config/i386/i386.c (ix86_finalize_stack_frame_flags): Revert
763 reversion 267133.
764
765 2018-12-15 Jan Hubicka <hubicka@ucw.cz>
766
767 * ipa-fnsummary.c (analyze_function_body): Do not loeak conds and
768 size_time_table.
769 (ipa_fn_summary_generate): Add prevails parameter; do not allocate
770 data when symbol is not prevailing.
771 (inline_read_section): Likewise.
772
773 2018-12-15 Jan Hubicka <hubicka@ucw.cz>
774
775 * cgraph.h (cgraph_node): Add predicate prevailing_p.
776 (cgraph_edge): Add predicate possible_call_in_translation_unit_p.
777 * ipa-prop.c (ipa_write_jump_function): Optimize streaming of ADDR_EXPR.
778 (ipa_read_jump_function): Add prevails parameter; optimize streaming.
779 (ipa_read_edge_info): Break out from ...
780 (ipa_read_node_info): ... here; optimize streaming.
781 * cgraph.c (cgraph_edge::possibly_call_in_translation_unit_p): New
782 predicate.
783
784 2018-12-15 Jan Hubicka <hubicka@ucw.cz>
785
786 * ipa-utils.c (ipa_merge_profiles): Do no merging when source function
787 has zero count.
788
789 2018-12-15 Jakub Jelinek <jakub@redhat.com>
790
791 PR tree-optimization/88464
792 PR target/88498
793 * tree-vect-stmts.c (vect_build_gather_load_calls): For NARROWING
794 and mask with integral masktype, don't try to permute mask vectors,
795 instead emit VEC_UNPACK_{LO,HI}_EXPR. Fix up NOP_EXPR operand.
796 (vectorizable_store): Handle masked scatters with decl and integral
797 mask type.
798 (permute_vec_elements): Allow scalar_dest to be NULL.
799 * config/i386/i386.c (ix86_get_builtin)
800 <case IX86_BUILTIN_GATHER3ALTDIV16SF>: Use lowpart_subreg for masks.
801 <case IX86_BUILTIN_GATHER3ALTDIV8SF>: Don't assume mask and src have
802 to be the same.
803
804 2018-12-15 Jan Hubicka <hubicka@ucw.cz>
805
806 * ipa.c (cgraph_build_static_cdtor_1): Add OPTIMIZATION and TARGET
807 parameters.
808 (cgraph_build_static_cdtor): Update.
809 (build_cdtor): Use OPTIMIZATION and TARGET of the first real cdtor
810 callsed.
811
812 2018-12-15 Alan Modra <amodra@gmail.com>
813
814 * config/rs6000/rs6000.c (generate_set_vrsave, rs6000_emit_savres_rtx),
815 (rs6000_emit_prologue, rs6000_call_aix, rs6000_call_sysv),
816 (rs6000_call_darwin_1): Use gen_hard_reg_clobber.
817
818 2018-12-15 Jakub Jelinek <jakub@redhat.com>
819
820 PR target/88489
821 * config/i386/sse.md (UNSPEC_SFIXUPIMM): New unspec enumerator.
822 (avx512f_sfixupimm<mode><mask_name><round_saeonly_name>): Use it
823 instead of UNSPEC_FIXUPIMM.
824
825 PR rtl-optimization/88478
826 * cselib.c (cselib_record_sets): Move sets[i].src_elt tests
827 after REG_P (dest) test.
828
829 2018-12-14 Martin Sebor <msebor@redhat.com>
830
831 PR tree-optimization/88372
832 * calls.c (maybe_warn_alloc_args_overflow): Handle function pointers.
833 * tree-object-size.c (alloc_object_size): Same. Simplify.
834 * doc/extend.texi (Object Size Checking): Update.
835 (Other Builtins): Add __builtin_object_size.
836 (Common Type Attributes): Add alloc_size.
837 (Common Variable Attributes): Ditto.
838
839 2018-12-14 Martin Sebor <msebor@redhat.com>
840
841 PR rtl-optimization/87096
842 * gimple-ssa-sprintf.c (sprintf_dom_walker::handle_gimple_call): Avoid
843 folding calls whose bound may exceed INT_MAX. Diagnose bound ranges
844 that exceed the limit.
845
846 2018-12-14 Martin Sebor <msebor@redhat.com>
847
848 PR web/79738
849 * doc/extend.texi (attribute const, pure): Clarify.
850
851 2018-12-14 H.J. Lu <hongjiu.lu@intel.com>
852
853 * config/i386/i386.c (rest_of_insert_endbranch): Insert ENDBR
854 at the function entry only when -mmanual-endbr isn't used or
855 there is cf_check function attribute.
856 (ix86_attribute_table): Add cf_check.
857 * config/i386/i386.opt: Add -mmanual-endbr.
858 * doc/extend.texi: Document cf_check attribute.
859 * doc/invoke.texi: Document -mmanual-endbr.
860
861 2018-12-14 Thomas Schwinge <thomas@codesourcery.com>
862 Cesar Philippidis <cesar@codesourcery.com>
863
864 * omp-offload.c (inform_oacc_loop): New function.
865 (execute_oacc_device_lower): Use it to display loop parallelism.
866
867 2018-12-14 Jakub Jelinek <jakub@redhat.com>
868
869 PR c++/82294
870 PR c++/87436
871 * expr.h (categorize_ctor_elements): Add p_unique_nz_elts argument.
872 * expr.c (categorize_ctor_elements_1): Likewise. Compute it like
873 p_nz_elts, except don't multiply it by mult. Adjust recursive call.
874 Fix up COMPLEX_CST handling.
875 (categorize_ctor_elements): Add p_unique_nz_elts argument, initialize
876 it and pass it through to categorize_ctor_elements_1.
877 (mostly_zeros_p, all_zeros_p): Adjust categorize_ctor_elements callers.
878 * gimplify.c (gimplify_init_constructor): Likewise. Don't force
879 ctor into readonly data section if num_unique_nonzero_elements is
880 smaller or equal to 1/8 of num_nonzero_elements and size is >= 64
881 bytes.
882
883 2018-12-14 Thomas Preud'homme <thomas.preudhomme@arm.com>
884
885 * config/arm/arm.md (arm_movdi): Split if -mslow-flash-data and
886 source is a constant that would be loaded by literal pool.
887 (movsf expander): Generate a no_literal_pool_sf_immediate insn if
888 -mslow-flash-data is present, targeting hardfloat ABI and source is a
889 float constant that cannot be loaded via vmov.
890 (movdf expander): Likewise but generate a no_literal_pool_df_immediate
891 insn.
892 (arm_movsf_soft_insn): Split if -mslow-flash-data and source is a
893 float constant that would be loaded by literal pool.
894 (softfloat constant movsf splitter): Splitter for the above case.
895 (movdf_soft_insn): Split if -mslow-flash-data and source is a float
896 constant that would be loaded by literal pool.
897 (softfloat constant movdf splitter): Splitter for the above case.
898 * config/arm/constraints.md (Pz): Document existing constraint.
899 (Ha): Define constraint.
900 (Tu): Likewise.
901 * config/arm/predicates.md (hard_sf_operand): New predicate.
902 (hard_df_operand): Likewise.
903 * config/arm/thumb2.md (thumb2_movsi_insn): Split if
904 -mslow-flash-data and constant would be loaded by literal pool.
905 * constant/arm/vfp.md (thumb2_movsi_vfp): Likewise and disable constant
906 load in VFP register.
907 (movdi_vfp): Likewise.
908 (thumb2_movsf_vfp): Use hard_sf_operand as predicate for source to
909 prevent match for a constant load if -mslow-flash-data and constant
910 cannot be loaded via vmov. Adapt constraint accordingly by
911 using Ha instead of E for generic floating-point constant load.
912 (thumb2_movdf_vfp): Likewise using hard_df_operand predicate instead.
913 (no_literal_pool_df_immediate): Add a clobber to use as the
914 intermediate general purpose register and also enable it after reload
915 but disable it constant is a valid FP constant. Add constraints and
916 generate a DI intermediate load rather than 2 SI loads.
917 (no_literal_pool_sf_immediate): Add a clobber to use as the
918 intermediate general purpose register and also enable it after
919 reload.
920
921 2018-12-14 Uros Bizjak <ubizjak@gmail.com>
922
923 PR target/88474
924 * internal-fn.def (HYPOT): New.
925 * optabs.def (hypot_optab): New.
926 * config/i386/i386.md (hypot<mode>3): New expander.
927
928 2018-12-14 Jeff Law <law@redhat.com>
929
930 * target.def (post_cfi_startproc): Fix text.
931
932 2018-12-14 Sam Tebbs <sam.tebbs@arm.com>
933
934 * doc/tm.texi (TARGET_ASM_POST_CFI_STARTPROC): Define.
935 * doc/tm.texi.in (TARGET_ASM_POST_CFI_STARTPROC): Define.
936 * dwarf2out.c (dwarf2out_do_cfi_startproc): Trigger the hook.
937 * hooks.c (hook_void_FILEptr_tree): Define.
938 * hooks.h (hook_void_FILEptr_tree): Define.
939 * target.def (post_cfi_startproc): Define.
940
941 2018-12-14 Tom de Vries <tdevries@suse.de>
942
943 * lto-cgraph.c (verify_node_partition): New function.
944 (input_overwrite_node, input_varpool_node): Use verify_node_partition.
945
946 2018-12-14 H.J. Lu <hongjiu.lu@intel.com>
947
948 PR target/88483
949 * config/i386/i386.c (ix86_finalize_stack_frame_flags): Don't
950 use get_frame_size ().
951
952 2018-12-14 Andrew Stubbs <ams@codesourcery.com>
953
954 * gcc/lra-int.h (lra_register_new_scratch_op): Add third parameter.
955 * gcc/lra-remat.c (update_scratch_ops): Pass icode to
956 lra_register_new_scratch_op.
957 * gcc/lra.c (struct sloc): Add icode field.
958 (lra_register_new_scratch_op): Add icode parameter.
959 Use icode to skip insns that have changed beyond recognition.
960
961 2018-12-14 Eric Botcazou <ebotcazou@adacore.com>
962
963 * dwarf2out.c (analyze_discr_in_predicate): Simplify.
964 (analyze_variants_discr): Deal with naked boolean discriminants.
965
966 2018-12-14 Claudiu Zissulescu <claziss@synopsys.com>
967
968 * config/arc/arc.c (arc_restore_callee_milli) Don't clobber off
969 variable.
970
971 2018-12-14 Claudiu Zissulescu <claziss@synopsys.com>
972
973 * config/arc/arc.h (reg_class): Add SIBCALL_REGS.
974
975 2018-12-14 Richard Biener <rguenther@suse.de>
976
977 * gimple-ssa-split-paths.c (is_feasible_trace): Remove
978 duplicated code block.
979
980 2018-12-14 Alan Modra <amodra@gmail.com>
981
982 PR rtl-optimization/88311
983 * config/rs6000/rs6000.c (rs6000_call_sysv): Do not mask cookie.
984 (rs6000_sibcall_sysv): Likewise.
985
986 2018-12-14 Segher Boessenkool <segher@kernel.crashing.org>
987
988 PR rtl-optimization/88001
989 * function.c (match_asm_constraints_1): Don't invalidly share RTL.
990
991 2018-12-14 Bin Cheng <bin.cheng@linux.alibaba.com>
992
993 * auto-profile.c (afdo_annotate_cfg): Call update_max_bb_count even
994 if autofdo counts are all zeros.
995
996 2018-12-14 Bin Cheng <bin.cheng@linux.alibaba.com>
997
998 * auto-profile.c (afdo_indirect_call): Skip generating histogram
999 value for internal call.
1000
1001 2018-12-14 Bin Cheng <bin.cheng@linux.alibaba.com>
1002
1003 * auto-profile.c (AFDO_EINFO): New macro.
1004 (class edge_info): New class.
1005 (is_edge_annotated, set_edge_annotated): Delete.
1006 (afdo_propagate_edge, afdo_propagate_circuit, afdo_propagate): Remove
1007 parameter. Adjust edge count computation and annotation using class
1008 edge_info.
1009 (afdo_calculate_branch_prob, afdo_annotate_cfg): Likewise.
1010
1011 2018-12-13 Michael Ploujnikov <michael.ploujnikov@oracle.com>
1012
1013 * ipa-cp.c (print_all_lattices): Skip cp clones.
1014
1015 * ipa-cp.c: Fix various comment typos.
1016
1017 2018-12-13 Jakub Jelinek <jakub@redhat.com>
1018
1019 PR tree-optimization/88444
1020 * tree-inline.c (fold_marked_statements): Iterate up to
1021 last_basic_block_for_fn rather than n_basic_blocks_for_fn.
1022
1023 PR rtl-optimization/88470
1024 * cfgcleanup.c (outgoing_edges_match): If the function is
1025 shrink-wrapped and bb1 ends with a JUMP_INSN with a single fake
1026 edge to EXIT, return false.
1027
1028 2018-12-13 Martin Sebor <msebor@redhat.com>
1029
1030 * doc/extend.texi: Consistently use @code for const and volatile
1031 qualifiers, the true and false constants, and asm statements.
1032
1033 2018-12-13 Vladimir Makarov <vmakarov@redhat.com>
1034
1035 PR rtl-optimization/88414
1036 * lra-int.h (lra_asm_error_p): New.
1037 * lra-assigns.c (lra_assign): Check lra_asm_error_p for checking
1038 call crossed pseudo assignment correctness.
1039 (lra_split_hard_reg_for): Set up lra_asm_error_p.
1040 * lra-constraints.c (curr_insn_transform): Ditto.
1041 * lra.c (lra_asm_error_p): New.
1042 (lra): Reset lra_asm_error_p.
1043
1044 2018-12-13 Jakub Jelinek <jakub@redhat.com>
1045
1046 PR rtl-optimization/88416
1047 * valtrack.c (cleanup_auto_inc_dec): Handle pre/post-inc/dec/modify
1048 even if !AUTO_INC_DEC.
1049
1050 2018-12-13 David Edelsohn <dje.gcc@gmail.com>
1051
1052 * config/rs6000/rs6000.c (rs6000_function_arg): Ensure type is
1053 non-NULL.
1054 (rs6000_arg_partial_bytes): Same.
1055
1056 2018-12-13 Jason Merrill <jason@redhat.com>
1057
1058 * gdbinit.in (pp): New macro.
1059 (pbb): Remove.
1060
1061 2018-12-13 Jakub Jelinek <jakub@redhat.com>
1062
1063 PR tree-optimization/88464
1064 * tree-vect-stmts.c (vect_build_gather_load_calls): Handle INTEGER_TYPE
1065 masktype if mask is non-NULL.
1066 (vectorizable_load): Don't reject masked gather loads if masktype
1067 in the decl is INTEGER_TYPE.
1068
1069 2018-12-13 Andreas Krebbel <krebbel@linux.ibm.com>
1070
1071 * config/s390/s390-builtins.def (s390_vec_double_s64): Map to
1072 s390_vec_double_s64 instead of s390_vcdgb.
1073 (s390_vec_double_u64): Map to s390_vec_double_u64 instead of
1074 s390_vcdlgb.
1075
1076 2018-12-13 Andreas Krebbel <krebbel@linux.ibm.com>
1077
1078 * config/s390/vx-builtins.md ("vec_ctd_s64", "vec_ctd_u64")
1079 ("vec_ctsl", "vec_ctul"): Replace 0 with VEC_NOINEXACT.
1080 ("vec_double_s64", "vec_double_u64"): Replace 4 with VEC_INEXACT.
1081
1082 2018-12-13 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
1083
1084 * doc/invoke.texi (-msve-vector-bits): Clarify -msve-vector-bits=128
1085 behavior.
1086
1087 2018-12-13 Wei Xiao <wei3.xiao@intel.com>
1088
1089 * common/config/i386/i386-common.c (processor_names): Add cascadelake.
1090 (processor_alias_table): Add cascadelake.
1091 * config.gcc: Add -march=cascadelake.
1092 * config/i386/i386-c.c (ix86_target_macros_internal): Handle
1093 cascadelake.
1094 * config/i386/i386.c (Add m_CASCADELAKE): New.
1095 (processor_cost_table): Add cascadelake.
1096 (get_builtin_code_for_version): Handle cascadelake.
1097 * config/i386/i386.h (TARGET_CASCADELAKE, PROCESSOR_CASCADELAKE): New.
1098 (PTA_CASCADELAKE): Ditto.
1099 * doc/invoke.texi: Add -march=cascadelake.
1100
1101 2018-12-13 Jakub Jelinek <jakub@redhat.com>
1102
1103 PR target/88465
1104 * config/i386/i386.md (*movdi_internal, *movsi_internal,
1105 *movhi_internal, *movqi_internal): Add alternative(s) to load
1106 0 or -1 into k registers using kxor or kxnoq instructions.
1107
1108 PR target/88461
1109 * config/i386/sse.md (VI1248_AVX512VLBW, AVX512ZEXTMASK): New
1110 mode iterators.
1111 (<avx512>_testm<mode>3<mask_scalar_merge_name>,
1112 <avx512>_testnm<mode>3<mask_scalar_merge_name>): Merge patterns
1113 with VI12_AVX512VL and VI48_AVX512VL iterators into ones with
1114 VI1248_AVX512VLBW iterator.
1115 (*<avx512>_testm<VI1248_AVX512VLBW:mode>3_zext,
1116 *<avx512>_testm<VI1248_AVX512VLBW:mode>3_zext_mask,
1117 *<avx512>_testnm<VI1248_AVX512VLBW:mode>3_zext,
1118 *<avx512>_testnm<VI1248_AVX512VLBW:mode>3_zext_mask): New
1119 define_insns.
1120
1121 PR target/88461
1122 * config/i386/i386.md (*zero_extendsidi2, zero_extend<mode>di2,
1123 *zero_extend<mode>si2, *zero_extendqihi2): Add =*k, *km alternatives.
1124
1125 2018-12-12 Tom de Vries <tdevries@suse.de>
1126 Jakub Jelinek <jakub@redhat.com>
1127
1128 * omp-builtins.def (BUILT_IN_GOMP_LOOP_NONMONOTONIC_RUNTIME_START,
1129 BUILT_IN_GOMP_LOOP_MAYBE_NONMONOTONIC_RUNTIME_START,
1130 BUILT_IN_GOMP_LOOP_ULL_NONMONOTONIC_RUNTIME_START,
1131 BUILT_IN_GOMP_LOOP_ULL_MAYBE_NONMONOTONIC_RUNTIME_START,
1132 BUILT_IN_GOMP_PARALLEL_LOOP_NONMONOTONIC_RUNTIME,
1133 BUILT_IN_GOMP_PARALLEL_LOOP_MAYBE_NONMONOTONIC_RUNTIME): Fix up
1134 function types - remove one argument.
1135
1136 2018-12-12 Martin Sebor <msebor@redhat.com>
1137
1138 * doc/extend.texi (attribute copy): Fix typos.
1139
1140 2018-12-12 Martin Sebor <msebor@redhat.com>
1141
1142 * doc/extend.texi (Function Attributes): Clarify C++ aspects.
1143 (Variable Attributes): Same.
1144 (Type Attributes): Same.
1145
1146 2018-12-12 Olivier Hainque <hainque@adacore.com>
1147
1148 * config/aarch64/aarch64.c (aarch64_override_options): Once arch,
1149 cpu and tune were validated, insert SUBTARGET_OVERRIDE_OPTIONS if
1150 defined.
1151
1152 2018-12-12 Olivier Hainque <hainque@adacore.com>
1153
1154 * config/aarch64/aarch64.c (PROBE_STACK_FIRST_REG) : Redefine as
1155 R9_REGNUM instead of 9.
1156 (PROBE_STACK_SECOND_REG): Redefine as R10_REGNUM instead of 10.
1157
1158 2018-12-12 Eric Botcazou <ebotcazou@adacore.com>
1159
1160 PR target/86806
1161 * config/sparc/sparc.md (unspecv): Add UNSPECV_SPECULATION_BARRIER.
1162 (speculation_barrier): New instruction for V9.
1163
1164 2018-12-12 Segher Boessenkool <segher@kernel.crashing.org>
1165 Iain Sandoe <iain@sandoe.co.uk>
1166
1167 PR target/88343
1168 * config/rs6000/rs6000.c (save_reg_p): Do not save the picbase reg
1169 unless it has been used.
1170 (first_reg_to_save): Remove dead code.
1171
1172 2018-12-12 Iain Sandoe <iain@sandoe.co.uk>
1173
1174 * config/rs6000/rs6000-protos.h (rs6000_call_darwin): New.
1175 (rs6000_sibcall_darwin): New. (macho_call_template): Remove.
1176 * config/rs6000/rs6000.c (get_prev_label): Forward declaration.
1177 (rs6000_call_template_1): Handle Darwin.
1178 (macho_call_template): Remove.
1179 (rs6000_call_sysv): Remove handling for Darwin.
1180 (rs6000_call_darwin_1, rs6000_call_darwin): New
1181 (rs6000_sibcall_darwin): New.
1182 * config/rs6000/rs6000.md (define_expand “call”): Handle Darwin
1183 with its own expander. (define_expand “call_value”): Likewise.
1184 (define_expand “sibcall”): Likewise.
1185 (define_expand “sibcall_value”): Likewise.
1186 (call_nonlocal_sysv): Remove Darwin special-casing.
1187 (call_value_nonlocal_sysv): Likewise.
1188
1189 2018-12-12 Iain Sandoe <iain@sandoe.co.uk>
1190
1191 * config/rs6000/darwin.md (call_indirect_nonlocal_darwin64): Remove.
1192 (call_nonlocal_darwin64): Remove.
1193 (call_value_indirect_nonlocal_darwin64): Remove.
1194 (call_value_nonlocal_darwin64): Remove.
1195 * config/rs6000/rs6000.c (rs6000_call_template_1): Handle Darwin with
1196 the same asm output as AIX/ELFv2. (rs6000_call_sysv): Preserve the
1197 CALL_LONG flag when needed for Darwin.
1198 * config/rs6000/rs6000.md (define expand “call”): Expand Darwin as
1199 per sysv.
1200 (define_expand “call_value”): Likewise.
1201 (define_expand “sibcall”): Likewise.
1202 (define_expand “sibcall_value”): Likewise.
1203 (call_indirect_nonlocal_sysv): Mark the clobber mode P.
1204 (call_nonlocal_sysv): Likewise.
1205 (call_nonlocal_sysv_secure): Likewise.
1206 (call_value_indirect_nonlocal_sysv): Likewise.
1207 (call_value_nonlocal_sysv): Likewise.
1208 (call_value_nonlocal_sysv_secure): Likewise.
1209 (call_local64): Mark the clobber DI.
1210 (call_value_local64): Likewise.
1211
1212 2018-12-11 Jakub Jelinek <jakub@redhat.com>
1213
1214 PR tree-optimization/88444
1215 * tree-vrp.c (register_edge_assert_for_2): Only register assertions
1216 for conversions if rhs1 is a SSA_NAME.
1217
1218 2018-12-11 Dimitar Dimitrov <dimitar@dinux.eu>
1219
1220 * cfgexpand.c (asm_clobber_reg_is_valid): Also produce
1221 error when stack pointer is clobbered.
1222 (expand_asm_stmt): Refactor clobber check in separate function.
1223
1224 2018-12-11 Eric Botcazou <ebotcazou@adacore.com>
1225
1226 * config/rs6000/vxworks.h (RS6000_STARTING_FRAME_OFFSET): Define,
1227 accounting for STACK_BOUNDARY 128.
1228 (STACK_DYNAMIC_OFFSET): Likewise.
1229
1230 2018-12-11 Jakub Jelinek <jakub@redhat.com>
1231
1232 PR target/88425
1233 * config/i386/i386.md (*x86_mov<SWI48:mode>cc_0_m1_neg_leu<SWI:mode>):
1234 New define_insn_and_split.
1235
1236 2018-12-11 Richard Biener <rguenther@suse.de>
1237
1238 PR middle-end/88448
1239 PR middle-end/88415
1240 * gimple.c (gimple_assign_set_rhs_with_ops): Revert previous
1241 change.
1242 * tree-complex.c (update_complex_assignment): Properly transfer
1243 or clean EH info around gimple_assign_set_rhs_with_ops.
1244
1245 2018-12-11 Richard Earnshaw <rearnsha@arm.com>
1246
1247 PR target/87369
1248 * config/aarch64/iterators.md (sizem1): Add sizes for SFmode and DFmode.
1249 (Vbtype): Add SFmode mapping.
1250 * config/aarch64/aarch64.md (copysigndf3, copysignsf3): Delete.
1251 (copysign<GPF:mode>3): New expand pattern.
1252 (copysign<GPF:mode>3_insn): New insn pattern.
1253
1254 2018-12-11 Richard Biener <rguenther@suse.de>
1255
1256 * ccmp.c (ccmp_candidate_p): Use GIMPLE API properly.
1257
1258 2018-12-11 Jakub Jelinek <jakub@redhat.com>
1259
1260 PR lto/86004
1261 * doc/sourcebuild.texi (lto_incremental): Document new effective
1262 target.
1263
1264 2018-12-11 Segher Boessenkool <segher@kernel.crashing.org>
1265
1266 PR target/88145
1267 * config/rs6000/rs6000.c (rs6000_expand_zeroop_builtin): Use
1268 rs6000_isa_flags instead of rs6000_isa_flags_explicit to decide
1269 whether soft float is enabled.
1270 (rs6000_expand_mtfsb_builtin): Ditto.
1271 (rs6000_expand_set_fpscr_rn_builtin): Ditto.
1272 (rs6000_expand_set_fpscr_drn_builtin): Ditto.
1273
1274 2018-12-10 Jeff Law <law@redhat.com>
1275
1276 PR tree-optimization/80520
1277 * gimple-ssa-split-paths.c (is_feasible_trace): Recognize half
1278 diamonds that are likely if convertable.
1279
1280 2018-12-10 Martin Sebor <msebor@redhat.com>
1281
1282 PR tree-optimization/86196
1283 * gimple-ssa-warn-restrict.c (builtin_memref::builtin_memref): Use
1284 base size only of arrays.
1285
1286 2018-12-10 Segher Boessenkool <segher@kernel.crashing.org>
1287
1288 * config.gcc (Obsolete configurations): Delete powerpc*-*-*spe*.
1289 (Unsupported targets): Add powerpc*-*-*spe*.
1290 (powerpc*-*-*spe*): Delete.
1291 (powerpc-*-eabispe*): Delete.
1292 (powerpc-*-rtems*spe*): Delete.
1293 (powerpc*-*-linux*spe*): Delete.
1294 (powerpc*-*-linux*): Do not handle the linux*spe* targets.
1295 (powerpc-wrs-vxworks*spe): Delete.
1296 (with_cpu setting code): Delete powerpc*-*-*spe* handling.
1297 * config.host (target powerpc*-*-*spe*): Delete.
1298 * doc/invoke.texi (PowerPC SPE Options): Delete.
1299 (PowerPC SPE Options): Delete.
1300 * config/powerpcspe: Delete.
1301
1302 2018-12-10 Uros Bizjak <ubizjak@gmail.com>
1303
1304 PR target/88418
1305 * config/i386/i386.c (ix86_expand_sse_cmp): For vector modes,
1306 check operand 1 with vector_operand predicate.
1307 (ix86_expand_sse_movcc): For vector modes, check op_true with
1308 vector_operand, not nonimmediate_operand.
1309
1310 2018-12-10 Richard Biener <rguenther@suse.de>
1311
1312 * tree-affine.c (tree_to_aff_combination): Remove unreachable
1313 MEM_REF case.
1314 (aff_combination_expand): Cache on SSA names, not possibly
1315 on conversion trees. Avoid expanding cases we do not handle.
1316
1317 2018-12-10 Richard Biener <rguenther@suse.de>
1318
1319 PR tree-optimization/88427
1320 * vr-values.c (vr_values::extract_range_from_phi_node):
1321 Handle symbolic ranges conservatively when trying to drop
1322 to Inf +- 1.
1323
1324 2018-12-10 Martin Jambor <mjambor@suse.cz>
1325
1326 PR ipa/88214
1327 * ipa-prop.c (determine_locally_known_aggregate_parts): Make sure
1328 we check pointers against pointers.
1329
1330 2018-12-10 Richard Biener <rguenther@suse.de>
1331
1332 PR middle-end/88415
1333 * gimple.c (gimple_assign_set_rhs_with_ops): Transfer EH
1334 info to a newly allocated stmt.
1335
1336 2018-12-10 Jerome Lambourg <lambourg@adacore.com>
1337
1338 * config/vxworksae.h (TARGET_VXWORKS_HAVE_CTORS_DTORS): Define.
1339
1340 2018-12-10 Fredrik Nyström <fredrik@lysator.liu.se>
1341
1342 PR bootstrap/65725
1343 * config/sol2.h: Only use libgcc-unwind.map if
1344 ENABLE_SHARED_LIBGCC.
1345
1346 2018-12-10 Bin Cheng <bin.cheng@linux.alibaba.com>
1347
1348 * auto-profile.c (afdo_calculate_branch_prob): Convert profile_count
1349 to afdo precision quality.
1350 (afdo_callsite_hot_enough_for_early_inline): Likewise.
1351 (afdo_annotate_cfg): Set profile_count for exit basic block.
1352
1353 2018-12-10 Bin Cheng <bin.cheng@linux.alibaba.com>
1354
1355 * auto-profile.c (string_table::get_index_by_decl)
1356 (function_instance::get_function_instance_by_decl): Avoid infinite
1357 recursion by using DECL_FROM_INLINE.
1358
1359 2018-12-09 John David Anglin <danglin@gcc.gnu.org>
1360
1361 * config.gcc (hppa*-*-linux*): Add pa/t-pa to tmake_file. Define
1362 d_target_objs.
1363 * config/pa/pa-protos.h (pa_d_target_versions): New prototype.
1364 * config/pa/pa.h (TARGET_D_CPU_VERSIONS): Define.
1365 * config/pa/pa-d.c: New file.
1366 * config/pa/t-pa: New file.
1367
1368 2018-12-08 Bin Cheng <bin.cheng@linux.alibaba.com>
1369
1370 * ipa-cp.c (update_profiling_info): Call adjust_for_ipa_scaling for
1371 zero profile count.
1372
1373 2018-12-08 Jakub Jelinek <jakub@redhat.com>
1374
1375 PR fortran/88304
1376 * tree-nested.c (convert_local_reference_stmt): Handle clobbers where
1377 lhs is not a decl normally, don't call use_pointer_in_frame on that
1378 lhs.
1379
1380 2018-12-08 Eric Botcazou <ebotcazou@adacore.com>
1381
1382 PR rtl-optimization/88390
1383 * dwarf2cfi.c (struct dw_cfi_row): Add window_save field.
1384 (cfi_row_equal_p): Compare it.
1385 (dwarf2out_frame_debug_cfa_window_save): Add FAKE parameter.
1386 If FAKE is false, set window_save of the current row.
1387 (dwarf2out_frame_debug) <REG_CFA_TOGGLE_RA_MANGLE>: Call above
1388 function with FAKE parameter set to true.
1389 <REG_CFA_WINDOW_SAVE>: Likewise but with FAKE parameter set to false.
1390 (change_cfi_row): Emit a DW_CFA_GNU_window_save if necessary.
1391
1392 2018-12-07 Peter Bergner <bergner@linux.ibm.com>
1393
1394 PR target/87496
1395 * config/rs6000/rs6000.c (rs6000_option_override_internal): Disallow
1396 -mabi=ieeelongdouble and -mabi=ibmlongdouble without -mlong-double-128.
1397 Do not error for -mabi=ibmlongdouble and no ISA 2.06 support.
1398 * doc/invoke.texi: Document -mabi=ibmlongdouble and -mabi=ieeelongdouble
1399 require -mlong-double-128.
1400
1401 2018-12-07 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
1402
1403 * config/aarch64/aarch64.c (aarch64_tuning_override_functions): Add
1404 sve_width entry.
1405 (aarch64_parse_sve_width_string): Define.
1406
1407 2018-12-07 Jeff Law <law@redhat.com>
1408
1409 PR middle-end/87813
1410 * gimple-ssa-evrp-analyze.h (class evrp_range_analyzer): Add
1411 m_update_global_ranges member. Add corresponding argument to ctor.
1412 * gimple-ssa-evrp-analyze.c
1413 (evrp_range_analyzer::evrp_range_analyzer): Add new argument and
1414 initialize m_update_global_ranges.
1415 (evrp_range_analyzer::set_ssa_range_info): Assert that we are
1416 updating global ranges.
1417 (evrp_range_analyzer::record_ranges_from_incoming_edge): Only
1418 update global ranges if explicitly requested.
1419 (evrp_range_analyzer::record_ranges_from_phis): Similarly.
1420 (evrp_range_analyzer::record_ranges_from_stmt): Similarly.
1421 * gimple-ssa-evrp.c (evrp_dom_walker): Pass new argument to
1422 evrp_range_analyzer ctor.
1423 * gimple-ssa-sprintf.c (sprintf_dom_walker): Similarly.
1424 * tree-ssa-dom.c (dom_opt_dom_walker): Similarly.
1425
1426 2018-12-07 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
1427
1428 * config/aarch64/aarch64-opts.h (aarch64_sve_vector_bits_enum):
1429 Add SVE_NOT_IMPLEMENTED value.
1430 * config/aarch64/aarch64-protos.h (struct tune_params): Add sve_width
1431 field.
1432 * config/aarch64/aarch64.c (generic_tunings,cortexa35_tunings,
1433 cortexa53_tunings, cortexa57_tunings, cortexa72_tunings,
1434 cortexa73_tunings, exynosm1_tunings, thunderx_tunings,
1435 thunderx_tunings, tsv110_tunings, xgene1_tunings, qdf24xx_tunings,
1436 saphira_tunings, thunderx2t99_tunings, emag_tunings):
1437 Specify sve_width.
1438 (aarch64_estimated_poly_value): Define.
1439 (TARGET_ESTIMATED_POLY_VALUE): Define.
1440
1441 2018-12-07 Paul A. Clarke <pc@us.ibm.com>
1442
1443 PR target/88408
1444 * config/rs6000/mmintrin.h (_mm_packs_pu16): Correctly use "__vector".
1445
1446 2018-12-07 Vladimir Makarov <vmakarov@redhat.com>
1447
1448 PR rtl-optimization/88349
1449 * ira-costs.c (record_operand_costs): Check bigger reg class on
1450 NO_REGS.
1451
1452 2018-12-07 Richard Sandiford <richard.sandiford@arm.com>
1453
1454 * config/aarch64/aarch64-sve.md (*mul<mode>3, *v<optab><mode>3):
1455 Split the patterns after reload if we don't need the predicate
1456 operand.
1457 (*post_ra_mul<mode>3, *post_ra_v<optab><mode>3): New patterns.
1458
1459 2018-12-07 Richard Sandiford <richard.sandiford@arm.com>
1460
1461 * config/aarch64/iterators.md (SVE_UNPRED_FP_BINARY): New code
1462 iterator.
1463 (sve_fp_op): Handle minus and mult.
1464 * config/aarch64/aarch64-sve.md (*add<mode>3, *sub<mode>3)
1465 (*mul<mode>3): Split the patterns after reload if we don't
1466 need the predicate operand.
1467 (*post_ra_<sve_fp_op><mode>3): New pattern.
1468
1469 2018-12-07 Bin Cheng <bin.cheng@linux.alibaba.com>
1470
1471 * profile-count.h (profile_count::oeprator>=): Fix typo by inverting
1472 return condition when *this is precise zero.
1473
1474 2018-12-07 Jakub Jelinek <jakub@redhat.com>
1475
1476 PR target/85593
1477 * final.c (rest_of_handle_final): Don't call collect_fn_hard_reg_usage
1478 for functions with naked attribute.
1479
1480 PR c/88367
1481 * tree-vrp.c (extract_range_from_binary_expr): For POINTER_PLUS_EXPR
1482 with -fno-delete-null-pointer-checks, set_nonnull only if the pointer
1483 is non-NULL and offset is known to have most significant bit clear.
1484 * vr-values.c (vr_values::vrp_stmt_computes_nonzero): For ADDR_EXPR
1485 of MEM_EXPR, return true if the MEM_EXPR has non-zero offset with
1486 most significant bit clear. If offset does have most significant bit
1487 set and -fno-delete-null-pointer-checks, don't return true even if
1488 the base pointer is non-NULL.
1489
1490 2018-12-06 Alexandre Oliva <aoliva@redhat.com>
1491
1492 * cselib.c (cselib_record_sets): Skip strict low part sets
1493 with NULL src_elt.
1494
1495 2018-12-06 Paul A. Clarke <pc@us.ibm.com>
1496
1497 PR target/88316
1498 * config/rs6000/smmintrin.h: New file.
1499 * config.gcc: Add smmintrin.h to extra_headers for powerpc*-*-*.
1500
1501 2018-12-06 Paul A. Clarke <pc@us.ibm.com>
1502
1503 PR target/88316
1504 * config/rs6000/mmintrin.h (_mm_unpackhi_pi8): Fix for big-endian.
1505 (_mm_unpacklo_pi8): Likewise.
1506 (_mm_mulhi_pi16): Likewise.
1507 (_mm_packs_pi16): Fix for big-endian. Use preferred API.
1508 (_mm_packs_pi32): Likewise.
1509 (_mm_packs_pu16): Likewise.
1510 * config/rs6000/xmmintrin.h (_mm_cvtss_si32): Fix for big-endian.
1511 (_mm_cvtss_si64): Likewise.
1512 (_mm_cvtpi32x2_ps): Likewise.
1513 (_mm_shuffle_ps): Likewise.
1514 (_mm_movemask_pi8): Likewise.
1515 (_mm_mulhi_pu16): Likewise.
1516 (_mm_sad_pu8): Likewise.
1517 (_mm_sad_pu8): Likewise.
1518 (_mm_cvtpu16_ps): Fix for big-endian. Use preferred API.
1519 (_mm_cvtpu8_ps): Likewise.
1520 (_mm_movemask_ps): Better #else case for big-endian (no functional
1521 change).
1522 (_mm_shuffle_pi16): Likewise.
1523 * config/rs6000/emmintrin.h (_mm_movemask_pd): Fix for big-endian.
1524 Better #else case for big-endian (no functional change).
1525 (_mm_movemask_epi8): Likewise.
1526 (_mm_shufflehi_epi16): Likewise.
1527 (_mm_shufflelo_epi16): Likewise.
1528 (_mm_shuffle_epi32): Likewise.
1529 (_mm_mul_epu32): Fix for big-endian.
1530 (_mm_bsrli_si128): Likewise.
1531 (_mm_cvtps_pd): Better #else case for big endian.
1532 (_mm_mulhi_epi16): Likewise.
1533 (_mm_mul_epu32): Likewise.
1534 (_mm_slli_si128): Likewise.
1535 (_mm_sll_epi16): Likewise.
1536 (_mm_sll_epi32): Likewise.
1537 (_mm_sra_epi16): Likewise.
1538 (_mm_sra_epi32): Likewise.
1539 (_mm_srl_epi16): Likewise.
1540 (_mm_srl_epi32): Likewise.
1541 (_mm_mulhi_epu16): Likewise.
1542 (_mm_sad_epu8): Likewise.
1543 * config/rs6000/pmmintrin.h (_mm_hadd_ps): Fix for big-endian.
1544 (_mm_sub_ps): Likewise.
1545 * config/rs6000/mmintrin.h (_mm_cmpeq_pi8): Fix for 32-bit mode.
1546 * gcc/config/rs6000/tmmintrin.h (_mm_alignr_epi8): Use ENDIAN
1547 macros consistently (no functional changes).
1548 (_mm_alignr_pi8): Likewise.
1549
1550 2018-12-06 Iain Sandoe <iain@sandoe.co.uk>
1551
1552 PR c++/87380
1553 * config/darwin.h (TARGET_WEAK_NOT_IN_ARCHIVE_TOC) Remove, use the
1554 default.
1555 * config/rs6000/darwin7.h (TARGET_WEAK_NOT_IN_ARCHIVE_TOC): New.
1556
1557 2018-12-06 Vladimir Makarov <vmakarov@redhat.com>
1558
1559 PR target/88282
1560 * ira.c (ira_init_register_move_cost): Use info from
1561 hard_regno_mode_ok instead of contains_reg_of_mode.
1562 * ira-costs.c (contains_reg_of_mode): Don't use cost from bigger
1563 hard register class for some fixed hard registers.
1564
1565 2018-12-06 Segher Boessenkool <segher@kernel.crashing.org>
1566
1567 * doc/extend.texi (Using Assembly Language with C): Document asm inline.
1568 (Size of an asm): Fix typo. Document asm inline.
1569 * gimple-pretty-print.c (dump_gimple_asm): Handle asm inline.
1570 * gimple.h (enum gf_mask): Add GF_ASM_INLINE.
1571 (gimple_asm_set_volatile): Fix typo.
1572 (gimple_asm_inline_p): New.
1573 (gimple_asm_set_inline): New.
1574 * gimplify.c (gimplify_asm_expr): Propagate the asm inline flag from
1575 tree to gimple.
1576 * ipa-icf-gimple.c (func_checker::compare_gimple_asm): Compare the
1577 gimple_asm_inline_p flag, too.
1578 * tree-core.h (tree_base): Document that protected_flag is ASM_INLINE_P
1579 in an ASM_EXPR.
1580 * tree-inline.c (estimate_num_insns): If gimple_asm_inline_p return
1581 a minimum size for an asm.
1582 * tree.h (ASM_INLINE_P): New.
1583
1584 2018-12-06 Segher Boessenkool <segher@kernel.crashing.org>
1585
1586 PR inline-asm/55681
1587 * doc/extend.texi (Basic Asm): Update grammar.
1588 (Extended Asm): Update grammar.
1589
1590 2018-12-06 Iain Sandoe <iain@sandoe.co.uk>
1591
1592 PR target/78444
1593 * config/i386/darwin.h (STACK_BOUNDARY): Remove macro.
1594 * config/i386/i386.c (ix86_compute_frame_layout): Ensure at least 128b
1595 stack alignment in non-leaf functions.
1596
1597 2018-12-06 Jakub Jelinek <jakub@redhat.com>
1598
1599 PR target/87598
1600 * config/aarch64/aarch64.c (aarch64_print_address_internal): Don't
1601 call output_operand_lossage on VOIDmode CONST_INTs. After
1602 output_operand_lossage do return false.
1603
1604 2018-12-06 Richard Biener <rguenther@suse.de>
1605
1606 * df-problems.c (df_rd_local_compute): Use bitmap_release.
1607 (df_live_free): Likewise.
1608 (df_md_local_compute): Likewise.
1609 (df_md_free): Release df_md_scratch bitmap.
1610 * loop-invariant.c (calculate_loop_reg_pressure): Use
1611 bitmap_release.
1612 * sched-deps.c (true_dependency_cache, output_dependency_cache,
1613 anti_dependency_cache, control_dependency_cache,
1614 spec_dependency_cache): Use bitmap instead of bitmap_head *.
1615 * sched-ebb.c (schedule_ebbs_init): Initialize non-GTY
1616 dont_calc_deps as bitmap allocated from obstack not GC.
1617 (schedule_ebbs_finish): Use bitmap_release.
1618 * sched-rgn.c (schedule_insns): Initialize non-GTY
1619 not_in_df as bitmap allocated from obstack not GC.
1620 Use bitmap_release.
1621 * sel-sched.c (_forced_ebb_heads): Remove premature optimization.
1622 (sel_region_init): Allocate forced_ebb_heads.
1623 (sel_region_finish): Free forced_ebb_heads.
1624
1625 2018-12-06 Richard Biener <rguenther@suse.de>
1626
1627 * bitmap.c (bitmap_head::crashme): Define.
1628 * bitmap.h (bitmap_head): Add constexpr default constructor
1629 poisoning the obstack member.
1630 (bitmap_head::crashme): Declare.
1631 (bitmap_release): New function clearing a bitmap and poisoning
1632 the obstack member.
1633 * gengtype.c (main): Make it recognize CONSTEXPR.
1634 * lra-constraints.c (lra_inheritance): Use bitmap_release
1635 instead of bitmap_clear.
1636 * ira.c (ira): Work around class-memaccess warning.
1637 * regrename.c (create_new_chain): Likewise.
1638
1639 2018-12-06 Jakub Jelinek <jakub@redhat.com>
1640
1641 PR tree-optimization/85726
1642 * generic-match-head.c (optimize_successive_divisions_p): New function.
1643 * gimple-match-head.c (optimize_successive_divisions_p): Likewise.
1644 * match.pd: Don't combine successive divisions if they aren't exact
1645 and optimize_successive_divisions_p is false.
1646
1647 PR fortran/88304
1648 * tree-nested.c (convert_nonlocal_reference_stmt): Remove clobbers
1649 for non-local automatic decls.
1650
1651 2018-12-05 David Edelsohn <dje.gcc@gmail.com>
1652
1653 * config/rs6000/aix72.h (ASM_DEFAULT_SPEC): Match Power7 processor
1654 default.
1655
1656 2018-12-05 Uros Bizjak <ubizjak@gmail.com>
1657
1658 * dwarf2out.c (field_byte_offset): Remove
1659 #ifdef PCC_BITFIELD_TYPE_MATTERS check.
1660
1661 2018-12-05 Richard Biener <rguenther@suse.de>
1662 Martin Sebor <msebor@redhat.com>
1663
1664 PR c/87028
1665 * calls.c (get_attr_nonstring_decl): Avoid setting *REF to
1666 SSA_NAME_VAR.
1667 * gcc/gimple-low.c (lower_stmt): Fold builtin calls here.
1668 * gimplify (maybe_fold_stmt): Avoid folding builtin calls.
1669
1670 2018-12-05 Iain Sandoe <iain@sandoe.co.uk>
1671
1672 * configure.ac (gcc_cv_otool): Set.
1673 * configure: Regenerate.
1674
1675 2018-12-05 Uros Bizjak <ubizjak@gmail.com>
1676
1677 * config/i386/cygming.h (PCC_BITFIELD_TYPE_MATTERS): Remove.
1678 (GROUP_BITFIELDS_BY_ALIGN): Ditto.
1679
1680 2018-12-05 Richard Sandiford <richard.sandiford@arm.com>
1681
1682 PR tree-optimization/88064
1683 * tree-vect-patterns.c (vect_convert_input): Convert the result of
1684 an existing cast if it has the right width but the wrong sign.
1685 Do not test the signedness of the required result when
1686 considering whether to split an existing cast; instead split to
1687 a type with the same signedness as the source of the cast, then
1688 convert it to the opposite signedness where necessary.
1689 (vect_recog_over_widening_pattern): Handle sign changes between
1690 the final PLUS_EXPR and the RSHIFT_EXPR.
1691 (vect_recog_average_pattern): Use an unsigned operation when
1692 truncating an addition, subtraction or multiplication. Cast the
1693 result back to the "real" signedness before promoting.
1694
1695 2018-12-05 Richard Biener <rguenther@suse.de>
1696
1697 PR tree-optimization/86637
1698 * tree-vectorizer.c (pass_slp_vectorize::execute): Reset
1699 vect_location at the end.
1700
1701 2018-12-05 Jakub Jelinek <jakub@redhat.com>
1702
1703 PR tree-optimization/87360
1704 * gimple-loop-jam.c (tree_loop_unroll_and_jam): On failure to analyze
1705 data dependencies, don't return false, just continue. Formatting
1706 fixes.
1707 (merge_loop_tree, bb_prevents_fusion_p, unroll_jam_possible_p,
1708 fuse_loops): Formatting fixes.
1709
1710 PR sanitizer/88333
1711 * cfgexpand.c (expand_stack_vars): If asan_vec is empty, start with
1712 aligning frame offset to ASAN_RED_ZONE_SIZE bytes.
1713
1714 2018-12-05 Xianmiao Qu <xianmiao_qu@c-sky.com>
1715
1716 * config.gcc (csky-*-linux-gnu*): Force .init_array support.
1717
1718 2018-12-05 Segher Boessenkool <segher@kernel.crashing.org>
1719
1720 * config/rs6000/rs6000.c (rs6000_function_arg): Only do the special
1721 aggregate handling on actual AIX, not on somewhat similar systems.
1722 (rs6000_arg_partial_bytes): Ditto.
1723
1724 2018-12-04 Vladimir Makarov <vmakarov@redhat.com>
1725
1726 PR rtl-optimization/88317
1727 * lra-constraints.c (split_reg): Don't set up check_only_regs if
1728 we are outside the inheritance pass.
1729
1730 2018-12-04 Jan Hubicka <hubicka@ucw.cz>
1731
1732 * ipa-prop.c (jump_function_useful_p): New.
1733 (ipa_read_node_info): Do not allocated useless jump functions.
1734
1735 2018-12-04 David Malcolm <dmalcolm@redhat.com>
1736
1737 PR c/82967
1738 * spellcheck.c (selftest::test_suggestions): Add another assertion.
1739
1740 2018-12-04 Martin Sebor <msebor@redhat.com>
1741
1742 * doc/extend.texi (__builtin_has_attribute): Fix typo.
1743
1744 2018-12-04 Jakub Jelinek <jakub@redhat.com>
1745
1746 PR target/88188
1747 * config/rs6000/rs6000.c (ccr_bit): Return -1 instead of assertion
1748 failures.
1749 (print_operand): Use REG_P instead of GET_CODE == REG.
1750 <case 'D'>: Also check CR_REGNO_P (REGNO (x)).
1751 <case 't'>: Likewise. Remove GET_MODE check.
1752 * config/rs6000/rs6000.md (scc patterns): Assert ccr_bit didn't
1753 return -1.
1754
1755 2018-12-04 Martin Sebor <msebor@redhat.com>
1756
1757 * doc/extend.texi (attribute aligned): Expand.
1758
1759 2018-12-04 David Edelsohn <dje.gcc@gmail.com>
1760
1761 PR target/61976
1762 * config/rs6000/rs6000.c (rs6000_function_arg): Don't pass aggregates
1763 in FPRs on AIX.
1764 (rs6000_arg_partial_bytes): Same.
1765
1766 2018-12-04 Vladimir Makarov <vmakarov@redhat.com>
1767
1768 PR target/88282
1769 * ira-costs.c (exec): Try bigger class to use smaller register
1770 move cost.
1771
1772 2018-12-04 Michael Ploujnikov <michael.ploujnikov@oracle.com>
1773
1774 PR ipa/88297
1775 * ipa-cp.c (create_specialized_node): Track clone counters by
1776 node assembler names.
1777 (ipcp_driver): Change type of clone_num_suffixes key to const char*.
1778
1779 2018-12-04 Richard Biener <rguenther@suse.de>
1780
1781 * tree-vect-loop.c (vect_transform_loop): Fix epilogue iterations
1782 for epilogue vectorization.
1783
1784 2018-12-04 Richard Biener <rguenther@suse.de>
1785
1786 PR tree-optimization/88301
1787 * tree-vrp.c (register_edge_assert_for_2): Fix sign-conversion
1788 issues in last commit.
1789
1790 2018-12-04 Richard Biener <rguenther@suse.de>
1791
1792 PR tree-optimization/88315
1793 * tree-vect-loop.c (get_initial_defs_for_reduction): Simplify
1794 and fix initialization vector for SAD and DOT_PROD SLP reductions.
1795
1796 2018-12-03 Sandra Loosemore <sandra@codesourcery.com>
1797
1798 PR c/59039
1799 * doc/extend.texi (Nonlocal gotos): New section.
1800
1801 2018-12-03 Uros Bizjak <ubizjak@gmail.com>
1802
1803 * config/i386/sse.md (vec_concatv2df): Change (v,xm,C)
1804 alternative to (v,vm,c).
1805
1806 2018-12-03 Segher Boessenkool <segher@kernel.crashing.org>
1807
1808 * gcc/config.gcc (Unsupported targets): Add powerpc*-*-linux*paired*.
1809 (powerpc*-*-linux*): Don't handle it here.
1810
1811 2018-12-03 Jeff Law <law@redhat.com>
1812
1813 * config/h8300/h8300.md (<code>qi3_1): Add gcc_unreachable to keep
1814 warnings quiet.
1815
1816 * config/h8300/h8300.md (low byte masking peepholes): Only accept
1817 nonimmediate_operand for the to-be-masked operand.
1818
1819 2018-12-03 Richard Biener <rguenther@suse.de>
1820
1821 * tree-ssa-sccvn.c (eliminate_dom_walker::eliminate_stmt): Only
1822 allow expected function-pointer cast re-instantiation.
1823
1824 2018-12-03 Ilya Leoshkevich <iii@linux.ibm.com>
1825
1826 * common/config/s390/s390-common.c (s390_option_init_struct):
1827 Use section anchors by default.
1828 * config/s390/s390.c (s390_check_symref_alignment): Handle
1829 anchors.
1830 (TARGET_MAX_ANCHOR_OFFSET): Use short displacement.
1831 * output.h (assemble_align): Pass `align' as unsigned int, so
1832 that the value 0x80000000, which corresponds to `aligned(1 <<
1833 28)', would pass the `align > BITS_PER_UNIT' check.
1834 * varasm.c (assemble_align): Likewise.
1835
1836 2018-12-03 Julian Brown <julian@codesourcery.com>
1837
1838 * tree-pretty-print.c (dump_omp_clause): Make default case
1839 gcc_unreachable.
1840
1841 2018-12-03 Richard Biener <rguenther@suse.de>
1842
1843 PR tree-optimization/88301
1844 * tree-vrp.c (register_edge_assert_for_2): Handle conversions
1845 that do not change the value by registering the same assert
1846 for the operand.
1847
1848 2018-12-03 Richard Biener <rguenther@suse.de>
1849
1850 * tree-vect-loop.c (vect_transform_loop): Properly compute
1851 upper bound for the epilogue when doing epilogue vectorization.
1852
1853 2018-12-03 Ilya Leoshkevich <iii@linux.ibm.com>
1854
1855 PR target/80080
1856 * cfgcleanup.c (class pass_postreload_jump): New pass.
1857 (pass_postreload_jump::execute): Likewise.
1858 (make_pass_postreload_jump): Likewise.
1859 * passes.def: Add pass_postreload_jump before
1860 pass_postreload_cse.
1861 * tree-pass.h (make_pass_postreload_jump): New pass.
1862
1863 2018-12-02 Uros Bizjak <ubizjak@gmail.com>
1864
1865 * config/i386/i386.c (inline_memory_move_cost): Correctly
1866 compute number of TFmode GPR moves.
1867
1868 2018-12-02 Jakub Jelinek <jakub@redhat.com>
1869
1870 PR target/88278
1871 * config/i386/sse.md (*vec_concatv4sf_0, *vec_concatv4si_0): New insns.
1872
1873 2018-12-02 Jeff Law <law@redhat.com>
1874
1875 * config/h8300/h8300.md (call, call_value): Drop mode from
1876 operand containing number of bytes pushed.
1877 (call_insn, call_value_insn): Use mode iterator for number
1878 of bytes pushed operand. Make pattern name vary appropriately.
1879
1880 2018-12-02 Jan Hubicka <jh@suse.cz>
1881
1882 * bb-reorer.c (find_rarely_executed_basic_blocks_and_crossin_edges):
1883 trust precise profiles.
1884
1885 2018-12-02 Jakub Jelinek <jakub@redhat.com>
1886
1887 * tree-nested.c (convert_nonlocal_omp_clauses,
1888 convert_local_omp_clauses): Handle OMP_CLAUSE_IN_REDUCTION,
1889 OMP_CLAUSE_TASK_REDUCTION and OMP_CLAUSE__SIMT_ clauses.
1890 (convert_nonlocal_reference_stmt, convert_local_reference_stmt):
1891 Convert clauses for GIMPLE_OMP_TASKGROUP.
1892
1893 * omp-low.c (check_omp_nesting_restrictions): Allow cancel or
1894 cancellation point with taskgroup clause inside of taskloop. Consider
1895 a taskloop construct without nogroup clause as implicit taskgroup for
1896 diagnostics if cancel/cancellation point with taskgroup clause is
1897 closely nested inside of taskgroup region.
1898
1899 PR sanitizer/88291
1900 * asan.c (asan_clear_shadow): Move assert that len is multiple of 4
1901 to the start of the function.
1902 (asan_emit_stack_protection): When emitting clearing sequence for
1903 epilogue, align offset down to ASAN_RED_ZONE_SIZE granularity,
1904 add last_size_aligned which is last_size padded to multiples of
1905 ASAN_RED_ZONE_SIZE and emit asan_clear_shadow always on 4 byte
1906 boundaries.
1907
1908 2018-12-01 Jakub Jelinek <jakub@redhat.com>
1909
1910 PR sanitizer/88289
1911 * asan.c (asan_redzone_buffer::flush_redzone_payload): Fix up
1912 an off-by-one for BYTES_BIG_ENDIAN.
1913
1914 PR target/54589
1915 * combine.c (find_split_point): For invalid memory address
1916 nonobj + obj + const, if reg + obj + const is valid addressing
1917 mode, split at nonobj. Use if rather than else if for the
1918 fallback. Comment fixes.
1919
1920 2018-11-30 Indu Bhagat <indu.bhagat@oracle.com>
1921
1922 * coverage.c (get_coverage_counts): Use from_function_decl for precise
1923 function location.
1924 * profile-count.c (profile_count::dump): Add handling for precise
1925 profile quality.
1926 * profile.c (compute_branch_probabilities): Rely on exec_counts instead
1927 of profile_info to set profile_status of function.
1928 (branch_prob): Do not set profile_status of function based on
1929 profile_info. Done above based on exec_counts.
1930
1931 2018-11-30 Jakub Jelinek <jakub@redhat.com>
1932
1933 PR tree-optimization/88274
1934 * tree-ssa-reassoc.c (optimize_range_tests_xor,
1935 optimize_range_tests_diff): If type has smaller precision than
1936 corresponding mode or if it has non-standard min/max, compute
1937 everything in a standard type for the precision.
1938
1939 PR testsuite/85368
1940 * params.def (PARAM_LOGICAL_OP_NON_SHORT_CIRCUIT): New param.
1941 * tree-ssa-ifcombine.c (ifcombine_ifandif): If
1942 --param logical-op-non-short-circuit is present, override
1943 LOGICAL_OP_NON_SHORT_CIRCUIT value from the param.
1944 * fold-const.c (fold_range_test, fold_truth_andor): Likewise.
1945
1946 2018-11-30 Jeff Law <law@redhat.com>
1947
1948 * optabs.c (expand_binop): Use "machine_mode" rather than
1949 "enum machine mode" in most recent change.
1950
1951 2018-11-30 Wilco Dijkstra <wdijkstr@arm.com>
1952
1953 PR middle-end/64242
1954 * builtins.c (expand_builtin_longjmp): Use a temporary when restoring
1955 the frame pointer.
1956 (expand_builtin_nonlocal_goto): Likewise.
1957
1958 2018-11-30 David Malcolm <dmalcolm@redhat.com>
1959
1960 * diagnostic-core.h (emit_diagnostic): New decl.
1961 * diagnostic.c (emit_diagnostic): New overload, taking a
1962 rich_location *.
1963
1964 2018-11-30 David Malcolm <dmalcolm@redhat.com>
1965
1966 * pretty-print.c (class selftest::test_pretty_printer): New
1967 subclass of pretty_printer.
1968 (selftest::test_prefixes_and_wrapping): New test.
1969 (selftest::pretty_print_c_tests): Call it.
1970
1971 2018-11-30 Michael Ploujnikov <michael.ploujnikov@oracle.com>
1972
1973 Minimize clone counter memory usage in create_virtual_clone.
1974 * cgraph.h (clone_function_name): Add a variant that takes a
1975 tree decl.
1976 * cgraph.h (cgraph_node::create_virtual_clone): Add a new
1977 argument: num_suffix.
1978 * cgraphclones.c (cgraph_node::create_virtual_clone): Pass
1979 num_suffix to clone_function_name.
1980 (clone_function_name): Add a variant that takes a tree decl.
1981 * ipa-cp.c (create_specialized_node): Keep track of clone
1982 counters in clone_num_suffixes hash map.
1983 (ipcp_driver): Free the counter hash map.
1984 * ipa-hsa.c (process_hsa_functions): Creates at most one hsa
1985 clone per function.
1986
1987 2018-11-30 Michael Ploujnikov <michael.ploujnikov@oracle.com>
1988 Make function assembly more independent.
1989
1990 This is achieved by having clone_function_name assign unique clone
1991 numbers for each function independently.
1992
1993 * cgraphclones.c: Replaced clone_fn_id_num with clone_fn_ids;
1994 hash map.
1995 (clone_function_name_numbered): Use clone_fn_ids.
1996
1997 2018-11-30 Vladimir Makarov <vmakarov@redhat.com>
1998
1999 PR rtl-optimization/88179
2000 * lra-constraints.c (address_eliminator::address_eliminator):
2001 Don't eleminate regs in illegitimate address.
2002
2003 2018-11-30 David Malcolm <dmalcolm@redhat.com>
2004
2005 PR preprocessor/88257
2006 * input.c (get_substring_ranges_for_loc): Fix indentation.
2007 Bulletproof against getting a different files back from
2008 linemap_resolve_location and expand_location_to_spelling_point.
2009
2010 2018-11-30 Alexander Monakov <amonakov@ispras.ru>
2011
2012 PR gcov-profile/88279
2013 * tree-profile.c (init_ic_make_global_vars): Call
2014 decl_default_tls_model for variable and not it's type.
2015
2016 2018-11-30 Sam Tebbs <sam.tebbs@arm.com>
2017
2018 * config/arm/arm.h (TARGET_DOTPROD): Add TARGET_VFP5 constraint.
2019
2020 2018-11-30 Martin Liska <mliska@suse.cz>
2021
2022 PR sanitizer/81715
2023 * asan.c (asan_shadow_cst): Remove, partially transform
2024 into flush_redzone_payload.
2025 (RZ_BUFFER_SIZE): New.
2026 (struct asan_redzone_buffer): New.
2027 (asan_redzone_buffer::emit_redzone_byte): Likewise.
2028 (asan_redzone_buffer::flush_redzone_payload): Likewise.
2029 (asan_redzone_buffer::flush_if_full): Likewise.
2030 (asan_emit_stack_protection): Use asan_redzone_buffer class
2031 that is responsible for proper aligned stores and flushing
2032 of shadow memory payload.
2033 * asan.h (ASAN_MIN_RED_ZONE_SIZE): New.
2034 (asan_var_and_redzone_size): Likewise.
2035 * cfgexpand.c (expand_stack_vars): Use smaller alignment
2036 (ASAN_MIN_RED_ZONE_SIZE) in order to make shadow memory
2037 for automatic variables more compact.
2038
2039 2018-11-30 Alan Modra <amodra@gmail.com>
2040
2041 * config/rs6000/predicates.md (easy_fp_constant): Avoid long
2042 dependent insn sequences.
2043 * config/rs6000/rs6000.c (num_insns_constant): Support long
2044 double constants.
2045 * config/rs6000/rs6000.md (mov<mode>_softfloat <FMOVE128>): Adjust
2046 length attribute.
2047
2048 2018-11-30 Alan Modra <amodra@gmail.com>
2049
2050 * config/rs6000/rs6000.c (num_insns_constant_gpr): Renamed from
2051 num_insns_constant_wide. Make static. Revise comment.
2052 (num_insns_constant_multi): New function.
2053 (num_insns_constant): Formatting. Correct CONST_WIDE_INT
2054 calculation. Simplify and extract code common to both
2055 CONST_INT and CONST_DOUBLE. Add gcc_unreachable for unhandled
2056 const_double modes.
2057 * config/rs6000/rs6000-protos.h (num_insns_const_wide): Delete.
2058
2059 2018-11-30 Richard Biener <rguenther@suse.de>
2060
2061 PR tree-optimization/88274
2062 * tree-vrp.c (ranges_from_anti_range): Fix handling of
2063 TYPE_MIN/MAX_VALUE.
2064
2065 2018-11-29 Andi Kleen <ak@linux.intel.com>
2066
2067 * config/i386/i386.c (current_fentry_section): Add.
2068 (x86_function_profiler): Handle fentry section.
2069 (ix86_attribute_table): Add fentry section.
2070 * config/i386/i386.opt: Add -mfentry-section.
2071 * doc/extend.texi: Document fentry_section attribute.
2072 * doc/invoke.texi: Document -mfentry-section.
2073
2074 2018-11-29 Andi Kleen <ak@linux.intel.com>
2075
2076 * config/i386/i386.c (x86_print_call_or_nop): Handle nop name.
2077 (current_fentry_name): Add.
2078 (x86_function_profiler): Handle fentry_name attribute.
2079 (ix86_handle_fentry_name): Add.
2080 (ix86_attribute_table): Add fentry_name.
2081 * config/i386/i386.opt: Add -mfentry-name
2082 * doc/extend.texi: Document fentry_name.
2083 * doc/invoke.texi: Document minstrument-return.
2084
2085 2018-11-29 Andi Kleen <ak@linux.intel.com>
2086
2087 * config/i386/i386-opts.h (enum instrument_return): Add.
2088 * config/i386/i386.c (output_return_instrumentation): Add.
2089 (ix86_output_function_return): Call output_return_instrumentation.
2090 (ix86_output_call_insn): Call output_return_instrumentation.
2091 * config/i386/i386.opt: Add -minstrument-return=.
2092 * doc/invoke.texi (-minstrument-return): Document.
2093
2094 2018-11-29 Eric Botcazou <ebotcazou@adacore.com>
2095
2096 PR target/87807
2097 * config/sparc/sparc-modes.def: Minor tweak.
2098 * config/sparc/sparc.c: Minor reordering.
2099 (sparc_pass_by_reference): Move around.
2100 (traverse_record_type): Change offset from HOST_WIDE_INT to int.
2101 (classify_registers): Likewise for bitpos.
2102 (function_arg_slotno): Remove dead test and tweak comments.
2103 <MODE_RANDOM>: Remove useless assertion and test whether the
2104 parameter is named in order to pass it in FP registers. Return
2105 the regno for floating-point vector types.
2106 (compute_int_layout): Change bitpos from HOST_WIDE_INT to int.
2107 (compute_fp_layout): Likewise.
2108 (count_registers): Likewise.
2109 (assign_int_registers): Likewise.
2110 (assign_fp_registers): Likewise.
2111 (assign_registers): Likewise.
2112 (function_arg_record_value): Change size from HOST_WIDE_INT to int
2113 and use CEIL_NWORDS to compute the number of registers.
2114 (function_arg_union_value): Minor tweaks.
2115 (function_arg_vector_value): Add slotno and named parameters, use
2116 CEIL_NWORDS to compute the number of registers.
2117 (sparc_function_arg_1): Rework handling of vector types. Change
2118 size from HOST_WIDE_INT to int.
2119 (sparc_arg_partial_bytes): Rework handling of 32-bit ABI and deal
2120 with vector types for the 64-bt ABI.
2121 (sparc_function_arg_advance): Likewise.
2122 (sparc_return_in_memory): Add reference to -fpcc-struct-return.
2123 (sparc_struct_value_rtx): Return NULL_RTX instead of 0.
2124 (sparc_function_value_1): Rework handling of vector types. Change
2125 size from HOST_WIDE_INT to int.
2126
2127 2018-11-29 Jakub Jelinek <jakub@redhat.com>
2128
2129 PR target/88152
2130 * config/i386/sse.md (*<sse>_movmsk<ssemodesuffix><avxsizesuffix>_lt,
2131 *<sse>_movmsk<ssemodesuffix><avxsizesuffix>_zext_lt,
2132 *<sse>_movmsk<ssemodesuffix><avxsizesuffix>_shift,
2133 *<sse>_movmsk<ssemodesuffix><avxsizesuffix>_zext_shift,
2134 *<sse2_avx2>_pmovmskb_lt, *<sse2_avx2>_pmovmskb_zext_lt): New
2135 define_insn_and_split patterns.
2136
2137 PR target/54700
2138 * config/i386/sse.md
2139 (*<sse4_1>_blendv<ssemodesuffix><avxsizesuffix>_lt,
2140 *<sse4_1>_blendv<ssefltmodesuffix><avxsizesuffix>_ltint,
2141 *<sse4_1_avx2>_pblendvb_lt): Change define_insn into
2142 define_insn_and_split.
2143
2144 2018-11-29 Peter Bergner <bergner@linux.ibm.com>
2145
2146 PR target/87496
2147 * config/rs6000/rs6000.c (rs6000_option_override_internal): Disallow
2148 -mabi=ieeelongdouble without both -mpopcntd and -mvsx.
2149
2150 2018-11-29 Uros Bizjak <ubizjak@gmail.com>
2151
2152 * config/i386/i386.c (inline_memory_move_cost):
2153 Check "in" for 2 in MMX_CLASS_P case.
2154 * config/i386/mmx.md (*mov<mode>_internal): Correct
2155 TARGET_INTER_UNIT_MOVES_FROM_VEC and TARGET_INTER_UNIT_MOVES_TO_VEC
2156 alternatives in preferred_for_speed attribute calculation.
2157
2158 2018-11-29 Martin Sebor <msebor@redhat.com>
2159
2160 PR c/88172
2161 PR testsuite/88208
2162 * doc/extend.texi (attribute constructor): Clarify.
2163
2164 2018-11-29 Martin Liska <mliska@suse.cz>
2165
2166 PR middle-end/88246
2167 * builtins.c (expand_movstr): Fix thinko introduced
2168 when switching to the new enum.
2169
2170 2018-11-29 qing zhao <qing.zhao@oracle.com>
2171
2172 * cif-code.def (EXTERN_LIVE_ONLY_STATIC): New CIF code.
2173 * common.opt: Add -flive-patching flag.
2174 * doc/invoke.texi: Document -flive-patching.
2175 * flag-types.h (enum live_patching_level): New enum.
2176 * ipa-inline.c (can_inline_edge_p): Disable external functions from
2177 inlining when flag_live_patching is LIVE_PATCHING_INLINE_ONLY_STATIC.
2178 * opts.c (control_options_for_live_patching): New function.
2179 (finish_options): Make flag_live_patching incompatible with flag_lto.
2180 Control IPA optimizations based on different levels of
2181 flag_live_patching.
2182
2183 2018-11-29 Giuliano Belinassi <giuliano.belinassi@usp.br>
2184
2185 * match.pd (sinh (atanh (x))): New simplification rules.
2186 (cosh (atanh (x))): Likewise.
2187
2188 2018-11-29 Jakub Jelinek <jakub@redhat.com>
2189
2190 PR target/54700
2191 * config/i386/sse.md (ssebytemode): Add V16SI, V8SI and V4SI entries.
2192 (ssefltmodesuffix, ssefltvecmode): New define_mode_attrs.
2193 (*<sse4_1>_blendv<ssemodesuffix><avxsizesuffix>_lt,
2194 *<sse4_1>_blendv<ssefltmodesuffix><avxsizesuffix>_ltint,
2195 *<sse4_1_avx2>_pblendvb_lt): New define_insns.
2196
2197 PR target/88152
2198 * tree.h (build_uniform_cst, uniform_integer_cst_p): Declare.
2199 * tree.c (build_uniform_cst, uniform_integer_cst_p): New functions.
2200 * match.pd (define_predicates): Add uniform_integer_cst_p.
2201 (cmp @0 INTEGER_CST@1, cmp (convert?@2 @0) INTEGER_CST@1): Adjust
2202 so that it works also for vector comparisons with uniform constants
2203 with INTEGER_CST element.
2204
2205 PR target/88234
2206 * config/rs6000/rs6000.c (rs6000_gimple_fold_builtin): For
2207 vec_add and vec_sub builtins, perform PLUS_EXPR or MINUS_EXPR
2208 in unsigned_type_for instead of vector integral type where overflow
2209 doesn't wrap.
2210
2211 2018-11-29 Michael Ploujnikov <michael.ploujnikov@oracle.com>
2212
2213 There can be at most one .resolver clone per function
2214 * config/rs6000/rs6000.c (make_resolver_func): Generate
2215 resolver symbol with clone_function_name instead of
2216 clone_function_name_numbered.
2217
2218 2018-11-29 Richard Biener <rguenther@suse.de>
2219
2220 PR tree-optimization/88243
2221 * tree-vect-patterns.c (vect_mark_pattern_stmts): Set the def
2222 type of all pattern-sequence stmts to vect_internal_def.
2223
2224 2018-11-29 Andre Vieira <andre.simoesdiasvieira@arm.com>
2225
2226 PR target/88224
2227 * config/arm/arm-cpus.in (armv7-r): Add FP16conv configurations.
2228 (cortex-r7, cortex-r8): Update default and add new configuration.
2229 * doc/invoke.texi (armv7-r): Add two new vfp options.
2230 (nofp.dp): Add cortex-r7 and cortex-r8 to the list of targets that
2231 support this option.
2232
2233 2018-11-29 Alan Modra <amodra@gmail.com>
2234
2235 * config/rs6000/rs6000.c (rs6000_emit_move): Disable long
2236 double split for targets other than Darwin.
2237
2238 2018-11-29 Alan Modra <amodra@gmail.com>
2239
2240 * config/rs6000/rs6000.md (movdi_internal64): Correct lengths.
2241
2242 2018-11-29 Alan Modra <amodra@gmail.com>
2243
2244 * config/rs6000/predicates.md (easy_fp_constant): Remove code
2245 dealing with integers in const_double. Assert on unexpected
2246 modes. Delete superfluous ABI_V4 test.
2247 * config/rs6000/rs6000.c (rs6000_emit_move): Comment fixes.
2248 Don't call easy_fp_constant for Pmode.
2249 (rs6000_hash_constant): Remove code dealing with integers in
2250 const_double.
2251 (rs6000_legitimate_constant_p): Likewise.
2252 (output_toc): Formatting, use CONST_DOUBLE_P.
2253
2254 2018-11-29 Alan Modra <amodra@gmail.com>
2255
2256 * config/rs6000/constraints.md (G, H): Comment on purpose of
2257 constraint. Correct mode comments and "G" mode test.
2258 * config/rs6000/rs6000.md (movdi_internal32): Remove "GH" from
2259 alternative handling "F". Add length attr. Formatting.
2260 (mov<mode>_softfloat <FMOVE128>): Delete "GH" from
2261 alternative, and move "F" to separate alternative. Correct
2262 insn lengths.
2263
2264 2018-11-29 Alan Modra <amodra@gmail.com>
2265
2266 * config/rs6000/predicates.md (easy_vector_constant): Don't call
2267 easy_fp_constant.
2268
2269 2018-11-29 Alan Modra <amodra@gmail.com>
2270
2271 * config.in (HAVE_AS_PLTSEQ): Add.
2272 * config/rs6000/predicates.md (indirect_call_operand): New.
2273 * config/rs6000/rs6000-protos.h (rs6000_pltseq_template),
2274 (rs6000_sibcall_sysv): Declare.
2275 * config/rs6000/rs6000.c (init_cumulative_args): Set cookie
2276 CALL_LONG for -fno-plt.
2277 (print_operand <T, z, 0>): Handle UNSPEC_PLTSEQ.
2278 (rs6000_indirect_call_template_1): Emit .reloc directives for
2279 UNSPEC_PLTSEQ calls.
2280 (rs6000_pltseq_template): New function.
2281 (rs6000_longcall_ref): Add arg parameter. Use PLT16 insns if
2282 relocs supported by assembler. Move SYMBOL_REF test to callers.
2283 (rs6000_call_aix): Adjust rs6000_longcall_ref call. Package
2284 insns in UNSPEC_PLTSEQ, preserving original func_desc.
2285 (rs6000_call_sysv): Likewise.
2286 (rs6000_sibcall_sysv): New function.
2287 * config/rs6000/rs6000.h (HAVE_AS_PLTSEQ): Provide default.
2288 * config/rs6000/rs6000.md (UNSPEC_PLTSEQ, UNSPEC_PLT16_HA,
2289 UNSPEC_PLT16_LO): New.
2290 (pltseq_tocsave, pltseq_plt16_ha, pltseq_plt16_lo, pltseq_mtctr): New.
2291 (call_indirect_nonlocal_sysv): Don't differentiate zero from non-zero
2292 cookie in constraints. Test explicitly for flags in length attr.
2293 Handle unspec operand 1.
2294 (call_value_indirect_nonlocal_sysv): Likewise.
2295 (call_indirect_aix, call_value_indirect_aix): Handle unspec operand 1.
2296 (call_indirect_elfv2, call_value_indirect_elfv2): Likewise.
2297 (sibcall, sibcall_value): Use rs6000_sibcall_sysv.
2298 (sibcall_indirect_nonlocal_sysv): New pattern.
2299 (sibcall_value_indirect_nonlocal_sysv): Likewise.
2300 (sibcall_nonlocal_sysv, sibcall_value_nonlocal_sysv): Remove indirect
2301 call alternatives.
2302 * configure.ac: Check for gas plt sequence marker support.
2303 * configure: Regenerate.
2304
2305 2018-11-29 Alan Modra <amodra@gmail.com>
2306
2307 * config/rs6000/predicates.md (unspec_tls): New.
2308 * config/rs6000/rs6000-protos.h (rs6000_call_template),
2309 (rs6000_sibcall_template): Update prototype.
2310 (rs6000_longcall_ref): Delete.
2311 (rs6000_call_sysv): Declare.
2312 * config/rs6000/rs6000.c (edit_tls_call_insn): New function.
2313 (global_tlsarg): New variable.
2314 (rs6000_legitimize_tls_address): Rewrite __tls_get_addr call
2315 handling.
2316 (print_operand): Extract UNSPEC_TLSGD address operand.
2317 (rs6000_call_template, rs6000_sibcall_template): Remove arg
2318 parameter, extract from second call operand instead.
2319 (rs6000_longcall_ref): Make static, localize vars.
2320 (rs6000_call_aix): Rename parameter to reflect new usage. Take
2321 tlsarg from global_tlsarg. Don't create unused rtl or nop insns.
2322 (rs6000_sibcall_aix): Rename parameter to reflect new usage. Take
2323 tlsarg from global_tlsarg.
2324 (rs6000_call_sysv): New function.
2325 * config/rs6000/rs6000.md: Adjust rs6000_call_template and
2326 rs6000_sibcall_template throughout.
2327 (tls_gd_aix, tls_gd_sysv, tls_gd_call_aix, tls_gd_call_sysv): Delete.
2328 (tls_ld_aix, tls_ld_sysv, tls_ld_call_aix, tls_ld_call_sysv): Delete.
2329 (tls_gdld_nomark): New insn.
2330 (tls_gd): Swap operand order. Simplify mode selection.
2331 (tls_gd_high, tls_gd_low): Swap operand order.
2332 (tls_ld): Remove const_int 0 vector element from UNSPEC_TLSLD.
2333 Simplify mode selection.
2334 (tls_ld_high, tls_ld_low): Similarly adjust UNSPEC_TLSLD.
2335 (call, call_value): Don't assert for second call operand.
2336 Use rs6000_call_sysv.
2337
2338 2018-11-29 Alan Modra <amodra@gmail.com>
2339
2340 * config/rs6000/darwin.md (call_indirect_nonlocal_darwin64),
2341 (call_nonlocal_darwin64, call_value_indirect_nonlocal_darwin64),
2342 (call_value_nonlocal_darwin64): Remove constraints from second call
2343 arg, the rounded_stack_size_rtx arg.
2344 * config/rs6000/rs6000.md (tls_gd_aix, tls_gd_sysv, tls_gd_call_aix),
2345 (tls_gd_call_sysv, tls_ld_aix, tls_ld_sysv, tls_ld_call_aix),
2346 (tls_ld_call_sysv, call_local32, call_local64, call_value_local32),
2347 (call_value_local64, call_indirect_nonlocal_sysv),
2348 (call_nonlocal_sysv, call_nonlocal_sysv_secure),
2349 (call_value_indirect_nonlocal_sysv, call_value_nonlocal_sysv),
2350 (call_value_nonlocal_sysv_secure, call_local_aix),
2351 (call_value_local_aix, call_nonlocal_aix, call_value_nonlocal_aix),
2352 (call_indirect_aix, call_value_indirect_aix, call_indirect_elfv2),
2353 (call_value_indirect_elfv2, sibcall_local32, sibcall_local64),
2354 (sibcall_value_local32, sibcall_value_local64, sibcall_aix),
2355 (sibcall_value_aix): Likewise.
2356
2357 2018-11-29 Alan Modra <amodra@gmail.com>
2358
2359 * config/rs6000/rs6000.md (TLSmode): Delete mode iterator. Replace
2360 with P throughout except for call mems which should use SI.
2361 (tls_abi_suffix, tls_sysv_suffix, tls_insn_suffix): Delete mode
2362 attributes. Replace with bits, mode and ptrload respectively.
2363
2364 2018-11-29 Alan Modra <amodra@gmail.com>
2365
2366 * config/rs6000/rs6000-protos.h (rs6000_indirect_call_template),
2367 (rs6000_indirect_sibcall_template): Declare.
2368 * config/rs6000/rs6000.c (rs6000_indirect_call_template_1),
2369 (rs6000_indirect_call_template, rs6000_indirect_sibcall_template):
2370 New functions.
2371 * config/rs6000/rs6000.md (call_indirect_nonlocal_sysv),
2372 (call_value_indirect_nonlocal_sysv, sibcall_nonlocal_sysv),
2373 (call_indirect_aix, call_value_indirect_aix): Use
2374 rs6000_indirect_call_template and rs6000_indirect_sibcall_template.
2375 call_indirect_elfv2, call_value_indirect_elfv2): Likewise, and
2376 handle both speculation and non-speculation cases.
2377 (call_indirect_aix_nospec, call_value_indirect_aix_nospec): Delete.
2378 (call_indirect_elfv2_nospec, call_value_indirect_elfv2_nospec): Delete.
2379
2380 2018-11-29 Alan Modra <amodra@gmail.com>
2381
2382 * config/rs6000/rs6000-protos.h (rs6000_call_template): Declare.
2383 (rs6000_sibcall_template): Declare.
2384 (macho_call_template): Rename from output_call.
2385 * config/rs6000/rs6000.c (rs6000_call_template_1): New function.
2386 (rs6000_call_template, rs6000_sibcall_template): Likewise.
2387 (macho_call_template): Rename from output_call.
2388 * config/rs6000/rs6000.md (tls_gd_aix, tls_gd_sysv),
2389 (tls_gd_call_aix, tls_gd_call_sysv, tls_ld_aix, tls_ld_sysv),
2390 (tls_ld_call_aix, tls_ld_call_sysv, call_nonlocal_sysv),
2391 (call_nonlocal_sysv_secure, call_value_nonlocal_sysv),
2392 (call_value_nonlocal_sysv_secure, call_nonlocal_aix),
2393 (call_value_nonlocal_aix): Use rs6000_call_template and update
2394 occurrences of output_call to macho_call_template.
2395 (sibcall_nonlocal_sysv, sibcall_value_nonlocal_sysv, sibcall_aix),
2396 (sibcall_value_aix): Use rs6000_sibcall_template.
2397
2398 2018-11-28 Aaron Sawdey <acsawdey@linux.ibm.com>
2399
2400 * config/rs6000/rs6000-string.c (expand_block_clear): Change how
2401 we determine if unaligned vsx is ok.
2402
2403 2018-11-28 Jan Hubicka <jh@suse.cz>
2404
2405 * predict.c (determine_unlikely_bbs): Forward declare; also determine
2406 edges that are always known to be taken because it is only likely
2407 edge out of given BB.
2408 (tree_estimate_probability): Call before profile guessing to get bit
2409 of extra precision.
2410
2411 2018-11-28 Jan Hubicka <jh@suse.cz>
2412
2413 * tree-ssa-ifcombine.c (update_profile_after_ifcombine): Handle
2414 profile_probability::always better.
2415
2416 2018-11-28 Jan Hubicka <jh@suse.cz>
2417
2418 * profile-count.h (profile_count::split): Give better result when
2419 splitting profile_probability::always.
2420
2421 2018-11-28 Vladimir Makarov <vmakarov@redhat.com>
2422
2423 PR target/88207
2424 * ira-costs.c (scan_one_insn): Process subregs when updating costs
2425 for pseudos and allocnos from insn.
2426
2427 2018-11-28 David Edelsohn <dje.gcc@gmail.com>
2428
2429 * config/rs6000/aix72.h: Update to match aix71.h changes.
2430
2431 2018-11-28 Jeff Law <law@redhat.com>
2432
2433 * config/h8300/constraints.md: Add "C" constraint for call insns.
2434 * config/h8300/h8300.md (call, call_value): Turn into a define_expand
2435 and define_insn pair. Move invalid call targets into a register in
2436 the expander and fix constraints in the matching pattern.
2437 * config/h8300/predicates.md (call_expander_operand): Renamed from
2438 call_insn_operand. Reject things we shouldn't be trying to handle.
2439 (call_insn_operand): New predicate for use by the call/call_value
2440 insns.
2441 (small_call_insn_operand): Update appropriately.
2442
2443 2018-11-28 Sam Tebbs <sam.tebbs@arm.com>
2444
2445 * config/aarch64/aarch64.c (aarch64_process_target_attr): Replace
2446 calls to strtok with strtok_r.
2447
2448 2018-11-28 Richard Biener <rguenther@suse.de>
2449
2450 PR tree-optimization/88223
2451 * tree-ssa-sccvn.c (vn_reference_lookup_3): When skipping
2452 over a stored-same value may-alias store make sure to consider
2453 partial overlaps which are valid when TBAA reasonings do not
2454 apply and byte-granular overlaps are possible at all.
2455
2456 2018-11-28 Richard Biener <rguenther@suse.de>
2457
2458 PR tree-optimization/88217
2459 * vr-values.c (vr_values::extract_range_from_phi_node): Make
2460 sure to handle results > +INF and < -INF correctly when
2461 trying to drop down to +INF - 1 or -INF + 1.
2462
2463 2018-11-28 Alan Modra <amodra@gmail.com>
2464
2465 * xcoffout.c (do_block): Signed/unsigned warning fix.
2466
2467 2018-11-28 Richard Biener <rguenther@suse.de>
2468
2469 PR tree-optimization/79351
2470 * tree-ssa-sccvn.c (vn_reference_lookup_3): For assignments from
2471 empty CONSTRUCTORs ensure the store is at a constant position.
2472
2473 2018-11-28 Richard Biener <rguenther@suse.de>
2474
2475 PR tree-optimization/88229
2476 * tree-ssa.c (non_rewritable_mem_ref_base): Check DECL_SIZE_UNIT
2477 is an INTEGER_CST before accessing it so.
2478
2479 2018-11-28 Sam Tebbs <sam.tebbs@arm.com>
2480
2481 * doc/invoke.texi (-mtune=): Remove obsolete CPU names.
2482
2483 2018-11-28 Jakub Jelinek <jakub@redhat.com>
2484
2485 PR target/88189
2486 * config/i386/i386.c (ix86_expand_sse_movcc): Handle DFmode and
2487 SFmode using sse4_1_blendvs[sd] with TARGET_SSE4_1. Formatting fixes.
2488 * config/i386/sse.md (sse4_1_blendv<ssemodesuffix>): New pattern.
2489
2490 2018-11-27 Martin Liska <mliska@suse.cz>
2491
2492 * gcov.c (generate_results): Append current_working_directory
2493 only when exists.
2494
2495 2018-11-27 Mike Gulick <mgulick@mathworks.com>
2496
2497 PR preprocessor/83173
2498 * input.c (dump_location_info): Dump reason and included_from
2499 fields from line_map_ordinary struct. Fix indentation when
2500 location > 5 digits.
2501 * diagnostic-show-locus.c (num_digits, num_digits): Move to
2502 diagnostic.c to allow it to be utilized by input.c.
2503 * diagnostic.c (num_digits, selftest::test_num_digits): Moved
2504 here.
2505 (selftest::diagnostic_c_tests): Run selftest::test_num_digits.
2506 * diagnostic.h (num_digits): Add extern definition.
2507
2508 2018-11-27 Fredrik Noring <noring@nocrew.org>
2509
2510 * config/mips/mips.c (mips_reorg_process_insns)
2511 (mips_option_override): Handle `-mfix-r5900'.
2512 * config/mips/mips.h (ASM_SPEC): Add `mfix-r5900' and
2513 `mno-fix-r5900'.
2514 * config/mips/mips.opt (mfix-r5900): New option.
2515 * doc/invoke.texi: Document the `r5900' processor name, and
2516 `-mfix-r5900' and `-mno-fix-r5900' options.
2517
2518 2018-11-27 Jakub Jelinek <jakub@redhat.com>
2519
2520 PR target/88188
2521 * config/rs6000/rs6000.c (print_operand) <case 'D'>: Use
2522 output_operand_lossage instead of gcc_assert.
2523 <case 't'>: Likewise.
2524 <case 'z'>: Likewise.
2525 <case 'V'>: Use output_operand_lossage instead of gcc_unreachable.
2526
2527 2018-11-27 Jeff Law <law@redhat.com>
2528
2529 * config/riscv/riscv (riscv_block_mvoe_straight): Use RETURN_BEGIN
2530 in call to move_by_pieces.
2531
2532 * config/sh/sh-mem.c (expand_block_move): Use RETURN_BEGIN in call
2533 to move_by_pieces.
2534
2535 * config/lm32/lm32.c (lm32_block_move_inline): Use RETURN_BEGIN in
2536 call to move_by_pieces.
2537
2538 * config/mips/mips.c (mips_block_move_straight): Use RETURN_BEGIN
2539 in call to move_by_pieces.
2540
2541 * config/microblaze/microblaze.c (microblaze_block_move_straight): Use
2542 RETURN_BEGIN in call to move_by_pieces.
2543 (microblaze_expand_block_move): Likewise.
2544
2545 2018-11-27 Tamar Christina <tamar.christina@arm.com>
2546
2547 * doc/md.texi (xorsign): Document it.
2548
2549 2018-11-27 Martin Liska <mliska@suse.cz>
2550
2551 * config/gnu-user.h (TARGET_F951_OPTIONS): New.
2552 * gcc.c (find_fortran_preinclude_file): New function
2553 to handle Fortran pre-include.
2554
2555 2018-11-27 Martin Liska <mliska@suse.cz>
2556
2557 * asan.c (asan_emit_stack_protection): Use new enum values
2558 instead of int constants.
2559 * builtins.c (expand_builtin_memory_copy_args): Replace int
2560 type with memop_ret enum type.
2561 (expand_builtin_mempcpy_args): Likewise.
2562 (expand_builtin_memcpy): Use new enum values
2563 instead of int constants. Likewise.
2564 (expand_builtin_mempcpy): Likewise.
2565 (expand_movstr): Likewise.
2566 (expand_builtin_strcpy_args): Likewise.
2567 (expand_builtin_stpcpy_1): Likewise.
2568 (expand_builtin_strncpy): Likewise.
2569 (expand_builtin_memset_args): Likewise.
2570 * expr.c (move_by_pieces_d::finish_endp): Rename to ...
2571 (move_by_pieces_d::finish_retmode): ... this.
2572 (move_by_pieces): Change last argument type to memop_ret.
2573 (store_by_pieces): Use new enum values
2574 instead of int constants.
2575 (emit_block_move_hints): Likewise.
2576 (emit_push_insn): Likewise.
2577 (store_expr): Likewise.
2578 * expr.h (store_by_pieces): Change int to newly added enum
2579 type.
2580 * rtl.h (enum memop_ret): Define.
2581 (move_by_pieces): Use the enum type.
2582
2583 2018-11-27 Alan Modra <amodra@gmail.com>
2584
2585 * config/rs6000/aix71.h (ASM_SPEC): Don't select default -maix64
2586 cpu here.
2587 (ASM_CPU_SPEC): Do so here. Rewrite using if .. else if .. specs
2588 form. Error on missing -mcpu case.
2589 * config/rs6000/driver-rs6000.c (asm_names <_AIX>): Update NULL case.
2590 (asm_names <!_AIX>): Add missing cpus. Update NULL case. Apply
2591 PR63177 fix for -mcpu=power8 and -mcpu=powerpc64le.
2592 * config/rs6000/rs6000.h (ASM_CPU_SPEC): Rewrite using if ..
2593 else if .. specs form. Error on missing -mcpu case. Don't output
2594 duplicate -maltivec. Apply PR63177 fix for -mcpu=powerpc64le.
2595
2596 2018-11-26 David Malcolm <dmalcolm@redhat.com>
2597
2598 * dump-context.h (dump_context::dump_loc): Convert 1st param from
2599 dump_flags_t to const dump_metadata_t &. Convert 2nd param from
2600 const dump_location_t & to const dump_user_location_t &.
2601 (dump_context::dump_loc_immediate): Convert 2nd param from
2602 const dump_location_t & to const dump_user_location_t &.
2603 (dump_context::dump_gimple_stmt): Convert 1st param from
2604 dump_flags_t to const dump_metadata_t &.
2605 (dump_context::void dump_gimple_stmt_loc): Likewise; convert
2606 2nd param from const dump_location_t & to
2607 const dump_user_location_t &.
2608 (dump_context::dump_gimple_expr): Convert 1st param from
2609 dump_flags_t to const dump_metadata_t &.
2610 (dump_context::dump_gimple_expr_loc): Likewise; convert
2611 2nd param from const dump_location_t & to
2612 const dump_user_location_t &.
2613 (dump_context::dump_generic_expr): Convert 1st param from
2614 dump_flags_t to const dump_metadata_t &.
2615 (dump_context::dump_generic_expr_loc): Likewise; convert
2616 2nd param from const dump_location_t & to
2617 const dump_user_location_t &.
2618 (dump_context::dump_printf_va): Convert 1st param from
2619 dump_flags_t to const dump_metadata_t &.
2620 (dump_context::dump_printf_loc_va): Likewise; convert
2621 2nd param from const dump_location_t & to
2622 const dump_user_location_t &.
2623 (dump_context::dump_dec): Convert 1st param from
2624 dump_flags_t to const dump_metadata_t &.
2625 (dump_context::dump_symtab_node): Likewise.
2626 (dump_context::begin_scope): Split out 2nd param into
2627 user and impl locations.
2628 (dump_context::ensure_pending_optinfo): Add metadata param.
2629 (dump_context::begin_next_optinfo): Replace dump_location_t param
2630 with metadata and user location.
2631 * dumpfile.c (dump_context::dump_loc): Convert 1st param from
2632 dump_flags_t to const dump_metadata_t &. Convert 2nd param from
2633 const dump_location_t & to const dump_user_location_t &.
2634 (dump_context::dump_loc_immediate): Convert 2nd param from
2635 const dump_location_t & to const dump_user_location_t &.
2636 (dump_context::dump_gimple_stmt): Convert 1st param from
2637 dump_flags_t to const dump_metadata_t &.
2638 (dump_context::void dump_gimple_stmt_loc): Likewise; convert
2639 2nd param from const dump_location_t & to
2640 const dump_user_location_t &.
2641 (dump_context::dump_gimple_expr): Convert 1st param from
2642 dump_flags_t to const dump_metadata_t &.
2643 (dump_context::dump_gimple_expr_loc): Likewise; convert
2644 2nd param from const dump_location_t & to
2645 const dump_user_location_t &.
2646 (dump_context::dump_generic_expr): Convert 1st param from
2647 dump_flags_t to const dump_metadata_t &.
2648 (dump_context::dump_generic_expr_loc): Likewise; convert
2649 2nd param from const dump_location_t & to
2650 const dump_user_location_t &.
2651 (dump_context::dump_printf_va): Convert 1st param from
2652 dump_flags_t to const dump_metadata_t &.
2653 (dump_context::dump_printf_loc_va): Likewise; convert
2654 2nd param from const dump_location_t & to
2655 const dump_user_location_t &.
2656 (dump_context::dump_dec): Convert 1st param from
2657 dump_flags_t to const dump_metadata_t &.
2658 (dump_context::dump_symtab_node): Likewise.
2659 (dump_context::begin_scope): Split out 2nd param into
2660 user and impl locations.
2661 (dump_context::ensure_pending_optinfo): Add metadata param.
2662 (dump_context::begin_next_optinfo): Replace dump_location_t param
2663 with metadata and user location.
2664 (dump_gimple_stmt): Convert 1st param from dump_flags_t to
2665 const dump_metadata_t &.
2666 (dump_gimple_stmt_loc): Likewise; convert 2nd param from
2667 const dump_location_t & to const dump_user_location_t &.
2668 (dump_gimple_expr): Convert 1st param from dump_flags_t to
2669 const dump_metadata_t &.
2670 (dump_gimple_expr_loc): Likewise; convert 2nd param from
2671 const dump_location_t & to const dump_user_location_t &.
2672 (dump_generic_expr): Convert 1st param from dump_flags_t to
2673 const dump_metadata_t &.
2674 (dump_generic_expr_loc): Likewise; convert 2nd param from
2675 const dump_location_t & to const dump_user_location_t &.
2676 (dump_printf): Convert 1st param from dump_flags_t to
2677 const dump_metadata_t &.
2678 (dump_printf_loc): Likewise; convert 2nd param from
2679 const dump_location_t & to const dump_user_location_t &.
2680 (dump_dec): Convert 1st param from dump_flags_t to
2681 const dump_metadata_t &.
2682 (dump_symtab_node): Likewise.
2683 (dump_begin_scope): Split out 2nd param into user and impl
2684 locations.
2685 (selftest::assert_impl_location_eq): New function.
2686 (ASSERT_IMPL_LOCATION_EQ): New macro.
2687 (selftest::test_impl_location): Update to use
2688 ASSERT_IMPL_LOCATION_EQ.
2689 (selftest::test_capture_of_dump_calls): Convert "loc" to
2690 dump_user_location_t. Add ASSERT_IMPL_LOCATION_EQ throughout,
2691 verifying line numbers of dump emissions.
2692 * dumpfile.h (class dump_metadata_t): New class.
2693 (dump_printf): Convert 1st param from dump_flags_t to
2694 const dump_metadata_t &.
2695 (dump_printf_loc): Likewise; convert 2nd param from
2696 const dump_location_t & to const dump_user_location_t &.
2697 (dump_generic_expr_loc): Likewise.
2698 (dump_generic_expr): Convert 1st param from dump_flags_t to
2699 const dump_metadata_t &.
2700 (dump_gimple_stmt_loc): Likewise; convert 2nd param from
2701 const dump_location_t & to const dump_user_location_t &.
2702 (dump_gimple_stmt): Convert 1st param from dump_flags_t to
2703 const dump_metadata_t &.
2704 (dump_gimple_expr_loc): Likewise; convert 2nd param from
2705 const dump_location_t & to const dump_user_location_t &.
2706 (dump_gimple_expr): Convert 1st param from dump_flags_t to
2707 const dump_metadata_t &.
2708 (dump_symtab_node): Likewise.
2709 (dump_dec): Likewise.
2710 (dump_begin_scope): Split out 2nd param into user and impl
2711 locations.
2712 (auto_dump_scope::auto_dump_scope): Split "loc" param into a user
2713 location and impl_location, and capture the impl_location.
2714 (AUTO_DUMP_SCOPE): Rename param from LOC to USER_LOC.
2715 * loop-unroll.c (report_unroll): Update for changes to
2716 dump_printf_loc and dump_printf.
2717 * opt-problem.cc (opt_problem::opt_problem): Update for change to
2718 dump_loc.
2719 * optinfo-emit-json.cc
2720 (selftest::test_building_json_from_dump_calls): Convert "loc" from
2721 dump_location_t to dump_user_location_t.
2722 * optinfo.cc (optinfo::emit_for_opt_problem): Update for change in
2723 dump_loc_immediate.
2724 * profile.c (compute_branch_probabilities): Update for change to
2725 dump_printf_loc.
2726 * selftest.h (ASSERT_STR_CONTAINS_AT): New macro.
2727 * tree-vect-slp.c (vect_print_slp_tree): Update for change to
2728 dump_printf_loc.
2729
2730 2018-11-27 Jozef Lawrynowicz <jozef.l@mittosystems.com>
2731
2732 * doc/sourcebuild.texi: Document check_effective_target_int_eq_float
2733 and check_effective_target_ptr_eq_long.
2734
2735 2018-11-27 Alan Modra <amodra@gmail.com>
2736
2737 * config.gcc (powerpc*-*-freebsd*, powerpc-*-netbsd*),
2738 (powerpc-*-eabisimaltivec*, powerpc-*-eabisim*, powerpc-*-elf*),
2739 (powerpc-*-eabialtivec*, powerpc-*-eabi*, powerpc-*-rtems*),
2740 (powerpc-wrs-vxworks*, powerpc-*-lynxos*, powerpcle-*-elf*),
2741 (powerpcle-*-eabisim*, powerpcle-*-eabi*): Add gnu-user.h to tm_file.
2742 * config/rs6000/freebsd.h (CPLUSPLUS_CPP_SPEC),
2743 (LINK_GCC_C_SEQUENCE_SPEC): Undef.
2744 (ASM_APP_ON, ASM_APP_OFF): Don't define.
2745 * config/rs6000/freebsd64.h (ASM_APP_ON, ASM_APP_OFF): Don't define.
2746 * config/rs6000/lynx.h (ASM_APP_ON, ASM_APP_OFF): Don't define.
2747 * config/rs6000/linux64.h (LINK_GCC_C_SEQUENCE_SPEC): Define.
2748 * config/rs6000/netbsd.h (CPLUSPLUS_CPP_SPEC),
2749 (LINK_GCC_C_SEQUENCE_SPEC): Undef.
2750 * config/rs6000/rtems.h (LINK_GCC_C_SEQUENCE_SPEC): Define.
2751 * config/rs6000/sysv4.h (GNU_USER_TARGET_CRTI): Redefine.
2752 (GNU_USER_TARGET_CRTN): Redefine.
2753 (CC1_SPEC): Use GNU_USER_TARGET_CC1_SPEC.
2754 (LIB_LINUX_SPEC): Use GNU_USER_TARGET_LIB_SPEC.
2755 (CRTOFFLOADBEGIN, CRTOFFLOADEND): Don't define.
2756 (STARTFILE_LINUX_SPEC): Define as GNU_USER_TARGET_STARTFILE_SPEC.
2757 (ENDFILE_LINUX_SPEC): Define as GNU_USER_TARGET_ENDFILE_SPEC.
2758 (UCLIBC_DYNAMIC_LINKER, CHOOSE_DYNAMIC_LINKER): Don't define.
2759 (LINK_EH_SPEC): Don't define.
2760
2761 2018-11-26 Martin Sebor <msebor@redhat.com>
2762
2763 PR 87756
2764 * expr.c (string_constant): Handle top-level decls of all character
2765 types and subobjects of narrow character type.
2766
2767 2018-11-27 Alan Modra <amodra@gmail.com>
2768
2769 * config.gcc (powerpc*-*-linux*): Add linux.h to tm_file.
2770 * config/rs6000/linux.h (TARGET_OS_CPP_BUILTINS): Use
2771 GNU_USER_TARGET_OS_CPP_BUILTINS.
2772 (RS6000_ABI_NAME): Define.
2773 * config/rs6000/linux64.h (TARGET_OS_CPP_BUILTINS): Use
2774 GNU_USER_TARGET_OS_CPP_BUILTINS.
2775 (MUSL_DYNAMIC_LINKER32): Undef before defining.
2776 (UCLIBC_DYNAMIC_LINKER32, UCLIBC_DYNAMIC_LINKER64): Don't define.
2777 (CHOOSE_DYNAMIC_LINKER): Don't define.
2778 (GNU_USER_DYNAMIC_LINKER32, GNU_USER_DYNAMIC_LINKER64): Don't define.
2779 * config/rs6000/sysv4.h (MUSL_DYNAMIC_LINKER): Undef before defining.
2780 (CHOOSE_DYNAMIC_LINKER, GNU_USER_DYNAMIC_LINKER): Only define when
2781 not already defined.
2782 (CPP_OS_LINUX_SPEC): Remove defines and asserts handled by
2783 TARGET_OS_CPP_BUILTINS.
2784
2785 2018-11-26 Jozef Lawrynowicz <jozef.l@mittosystems.com>
2786
2787 * doc/sourcebuild.texi: Document check_effective_target_newlib_nano_io.
2788
2789 2018-11-26 Jakub Jelinek <jakub@redhat.com>
2790
2791 PR target/88195
2792 * config/i386/i386.c (def_builtin2): If tcode == VOID_FTYPE_UINT64
2793 and !TARGET_64BIT, return NULL_TREE.
2794
2795 PR c++/86900
2796 * dwarf2out.c (secname_for_decl): For functions with
2797 DECL_SECTION_NAME if in_cold_section_p, try to return
2798 current_function_section's name if it is a named section.
2799
2800 2018-11-26 Maya Rashish <coypu@sdf.org>
2801
2802 PR target/58397
2803 * config.host (*-*-netbsd*): Use x-netbsd and host-netbsd.o.
2804 * config/x-netbsd: New file.
2805 * config/host-netbsd: New file.
2806
2807 2018-11-26 Jozef Lawrynowicz <jozef.l@mittosystems.com>
2808
2809 * doc/sourcebuild.texi: Document check_effective_target_size20plus.
2810 Clarify documentation for check_effective_target_size32plus.
2811
2812 2018-11-26 Aaron Sawdey <acsawdey@linux.ibm.com>
2813
2814 * config/rs6000/rs6000-string.c (expand_cmp_vec_sequence): Rename
2815 and modify expand_strncmp_vec_sequence.
2816 (emit_final_compare_vec): Rename and modify emit_final_str_compare_vec.
2817 (generate_6432_conversion): New function.
2818 (expand_block_compare): Add support for vsx.
2819 (expand_block_compare_gpr): New function.
2820 * config/rs6000/rs6000.opt (rs6000_block_compare_inline_limit): Increase
2821 default limit to 63 because of more compact vsx code.
2822
2823 2018-11-26 Uros Bizjak <ubizjak@gmail.com>
2824
2825 PR target/88178
2826 * config/i386/i386.c (dbx_register_map): Use IGNORED_DWARF_REGNUM
2827 for registers for which no debug information can be generated.
2828 Use INVALID_REGNUM for non-existent registers.
2829 (dbx64_register_map): Ditto.
2830 (svr4_dbx_register_map): Ditto.
2831
2832 2018-11-26 Sandra Loosemore <sandra@codesourcery.com>
2833
2834 PR c/57182
2835 * doc/invoke.texi (Optimize Options): Document that
2836 -freorder-functions also uses "hot" and "cold" attributes.
2837
2838 2018-11-26 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
2839
2840 * config/aarch64/aarch64.c (aarch64_mangle_type): Fix typo in comment.
2841
2842 2018-11-26 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
2843
2844 * config/arm/types.md (mul64): Rename to...
2845 (widen_mul64): ... This.
2846 * config/arm/arm-generic.md: Rename mul64 to widen_mul64.
2847 * config/arm/cortex-a15.md: Likewise.
2848 * config/arm/cortex-a5.md: Likewise.
2849 * config/arm/cortex-a53.md: Likewise.
2850 * config/arm/cortex-a57.md: Likewise.
2851 * config/arm/cortex-a7.md: Likewise.
2852 * config/arm/cortex-m4.md: Likewise.
2853 * config/arm/exynos-m1.md: Likewise.
2854 * config/arm/marvell-pj4.md: Likewise.
2855 * config/arm/xgene1.md: Likewise.
2856
2857 2018-11-26 Richard Biener <rguenther@suse.de>
2858
2859 PR tree-optimization/88182
2860 * tree-vect-loop.c (vectorizable_reduction): Pick up single
2861 correct reduc_def_info.
2862 * tree-vect-slp.c (vect_analyze_slp_instance): Set
2863 STMT_VINFO_REDUC_DEF of the first stmt.
2864
2865 2018-11-26 Andreas Krebbel <krebbel@linux.ibm.com>
2866
2867 * doc/invoke.texi: Document z14/arch12 -march option.
2868
2869 2018-11-25 Sandra Loosemore <sandra@codesourcery.com>
2870
2871 PR c/57166
2872 * doc/invoke.texi (Option Summary): Add -Wmissing-noreturn.
2873 (Warning Options): Likewise.
2874
2875 2018-11-25 Sandra Loosemore <sandra@codesourcery.com>
2876
2877 PR web/79738
2878 * doc/extend.texi (Common Function Attributes): Clarify that
2879 functions with "const" attribute can read const global variables.
2880
2881 2018-11-26 Alan Modra <amodra@gmail.com>
2882
2883 * config/rs6000/rs6000.h (OBJECT_PEF, TARGET_MACOS): Delete.
2884
2885 2018-11-25 Sandra Loosemore <sandra@codesourcery.com>
2886
2887 PR other/54265
2888 * doc/extend.texi (Common Variable Attributes): Use preferred
2889 placement of type attributes in examples, plus whitespace fixes.
2890 (Type Attributes): Clarify why placement of attributes
2891 immediately after struct/union/enum keyword is preferred.
2892 (Common Type Attributes): Use preferred placement of type
2893 attributes in examples, plus more whitespace fixes.
2894
2895 2018-11-25 Paul Koning <ni1d@arrl.net>
2896
2897 * config/pdp11/pdp11.h (TARGET_HAS_NO_HW_DIVIDE): Define.
2898
2899 2018-11-25 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
2900
2901 * doc/sourcebuild.texi (Effective-Target Keywords, Environment
2902 attributes): Document d_runtime.
2903
2904 2018-11-25 Vladimir Makarov <vmakarov@redhat.com>
2905
2906 PR bootstrap/88157
2907 * ira-costs.c (record_operand_costs): Initiate register move cost
2908 for mode.
2909
2910 2018-11-23 Jeff Law <law@redhat.com>
2911
2912 PR rtl-optimization/87468
2913 * tree-ssa-threadupdate.c (create_block_for_threading): Clear
2914 EDGE_IGNORE on all outgoing edges of the duplicate block.
2915
2916 2018-11-23 Vladimir Makarov <vmakarov@redhat.com>
2917
2918 PR bootstrap/88157
2919 * ira-costs.c (record_operand_costs): Use bigger hard reg class if
2920 its mode does not fit to the original class.
2921
2922 2018-11-23 Martin Sebor <msebor@redhat.com>
2923
2924 PR tree-optimization/87756
2925 * expr.c (string_constant): Synthesize a string literal from
2926 the address of a constant character.
2927 * tree.c (build_string_literal): Add an argument.
2928 * tree.h (build_string_literal): Same.
2929
2930 2018-11-23 Christoph Muellner <christoph.muellner@theobroma-systems.com>
2931
2932 * config/aarch64/aarch64-cores.def: Define emag.
2933 * config/aarch64/aarch64-tune.md: Regenerated with emag.
2934 * config/aarch64/aarch64.c (emag_tunings): New struct.
2935 * doc/invoke.texi: Document mtune value.
2936
2937 2018-11-23 Christoph Muellner <christoph.muellner@theobroma-systems.com>
2938 Philipp Tomsich <philipp.tomsich@theobroma-systems.com>
2939
2940 * config/aarch64/aarch64.c (xgene1_tunings): Optimize Xgene1 tunings
2941 for GCC 9.
2942 * config/aarch64/aarch64.c (xgene1_tunings): Add Xgene1 specific
2943 prefetch tunings.
2944 * config/aarch64/aarch64.c (xgene1_addrcost_table): Correct the post-modify
2945 costs.
2946 * config/arm/aarch-cost-tables.h (xgene1_extra_costs): Update the cost table
2947 for XGene1.
2948
2949 2018-11-23 Richard Biener <rguenther@suse.de>
2950
2951 PR tree-optimization/88149
2952 * tree-vect-slp.c (vect_slp_analyze_node_operations): Detect
2953 the case where there are two different def types for the
2954 same operand at different operand position in the same stmt.
2955
2956 2018-23-11 Mihail Ionescu <mihail.ionescu@arm.com>
2957
2958 * config/arm/arm.c (arm_expand_compare_and_swap): Simplify and call
2959 gen_atomic_compare_swap_1.
2960 (arm_evpc_neon_vuzp): Likewise gen_neon_vuzp_internal.
2961 (arm_evpc_neon_vtrn): Likewise gen_neon_vtrn_internal.
2962 (arm_evpc_neon_vext): Likewise gen_neon_vext_internal.
2963 (arm_evpc_neon_vzip): Likewise gen_neon_vzip_internal.
2964 (arm_evpc_neon_vrev): Replace the function pointer and simplify the mode
2965 checks.
2966 * config/arm/arm.md (neon_vext<mode>),
2967 (neon_vrev64<mode>, neon_vrev32<mode>),
2968 (neon_vrev16<mode>, neon_vtrn<mode>_internal),
2969 (neon_vzip<mode>_internal, neon_vuzp<mode>_internal): Add an '@'character
2970 before the pattern name.
2971 * config/arm/sync.md:
2972 (atomic_compare_and_swap<CCSI:arch><NARROW:mode>_1),
2973 (atomic_compare_and_swap<CCSI:arch><SIDI:mode>_1): Likewise.
2974
2975 2018-11-23 Jakub Jelinek <jakub@redhat.com>
2976
2977 PR tree-optimization/86614
2978 * gimple-ssa-warn-restrict.c (maybe_diag_offset_bounds): Return early
2979 if TREE_NO_WARNING is set on ref.ref.
2980
2981 2018-11-22 Sandra Loosemore <sandra@codesourcery.com>
2982 Alan Coopersmith <alan.coopersmith@oracle.com>
2983
2984 PR c/53608
2985 * doc/extend.texi (Designated Inits): Clarify handling of multiple
2986 initializers for unions.
2987
2988 2018-11-22 Jan Hubicka <jh@suse.cz>
2989
2990 PR lto/88142
2991 * ipa-devirt.c (type_variants_equivalent_p): Drop warn and warned
2992 parameters; do not warn here.
2993 (odr_subtypes_equivalent_p): Likewise.
2994 (warn_odr): Fix typo.
2995 (warn_types_mismatch): Do not output confused warnings on integer types.
2996 (odr_types_equivalent_p): Update.
2997
2998 2018-11-22 Jakub Jelinek <jakub@redhat.com>
2999
3000 * config/i386/i386.c (ix86_option_override_internal,
3001 ix86_can_inline_p, classify_argument, construct_container,
3002 ix86_expand_prologue, ix86_expand_split_stack_prologue,
3003 ix86_expand_carry_flag_compare, expand_set_or_movmem_via_loop,
3004 expand_setmem_epilogue_via_loop, promote_duplicated_reg,
3005 ix86_expand_set_or_movmem, ix86_init_builtins_va_builtins_abi):
3006 Formatting fixes.
3007
3008 * config/i386/i386.c (ix86_option_override_internal): For
3009 stack_protector_guard related options, use opts_set->x_ instead
3010 of global_options_set. and prefix options with opts->x_ . Move
3011 defaults for offset and reg into else block.
3012
3013 2018-11-22 Uros Bizjak <ubizjak@gmail.com>
3014
3015 * config/i386/i386.c (ix86_check_avx_upper_register):
3016 Return true for all SSE registers with mode bitsize > 128.
3017
3018 2018-11-22 Vladimir Makarov <vmakarov@redhat.com>
3019
3020 PR rtl-optimization/87718
3021 * ira-costs.c: Remove trailing white-spaces.
3022 (record_operand_costs): Add a special treatment for moves
3023 involving a hard register.
3024
3025 2018-11-22 Uros Bizjak <ubizjak@gmail.com>
3026
3027 * config/i386/i386.c (ix86_avx_emit_vzeroupper): Remove.
3028 (ix86_emit_mode_set) <case AVX_U128>: Emit vzeroupper here.
3029
3030 2018-11-22 Martin Liska <mliska@suse.cz>
3031
3032 * common/config/i386/i386-common.c (processor_names): Add
3033 static assert and add missing "znver2".
3034 (ix86_get_valid_option_values): Add checking assert for null
3035 values and add "native" value if feasible.
3036 * config/i386/i386.h: Do not declare size of processor_names.
3037 * common/config/i386/i386-common.c:
3038 * config/i386/i386.c: Add static assert for size
3039 of processor_cost_table.
3040
3041 2018-11-22 Thomas Preud'homme <thomas.preudhomme@linaro.org>
3042
3043 * target-insns.def (stack_protect_combined_set): Define new standard
3044 pattern name.
3045 (stack_protect_combined_test): Likewise.
3046 * cfgexpand.c (stack_protect_prologue): Try new
3047 stack_protect_combined_set pattern first.
3048 * function.c (stack_protect_epilogue): Try new
3049 stack_protect_combined_test pattern first.
3050 * config/arm/arm.c (require_pic_register): Add pic_reg and compute_now
3051 parameters to control which register to use as PIC register and force
3052 reloading PIC register respectively. Insert in the stream of insns if
3053 possible.
3054 (legitimize_pic_address): Expose above new parameters in prototype and
3055 adapt recursive calls accordingly. Use pic_reg if non null instead of
3056 cached one.
3057 (arm_load_pic_register): Add pic_reg parameter and use it if non null.
3058 (arm_legitimize_address): Adapt to new legitimize_pic_address
3059 prototype.
3060 (thumb_legitimize_address): Likewise.
3061 (arm_emit_call_insn): Adapt to require_pic_register prototype change.
3062 (arm_expand_prologue): Adapt to arm_load_pic_register prototype change.
3063 (thumb1_expand_prologue): Likewise.
3064 * config/arm/arm-protos.h (legitimize_pic_address): Adapt to prototype
3065 change.
3066 (arm_load_pic_register): Likewise.
3067 * config/arm/predicated.md (guard_addr_operand): New predicate.
3068 (guard_operand): New predicate.
3069 * config/arm/arm.md (movsi expander): Adapt to legitimize_pic_address
3070 prototype change.
3071 (builtin_setjmp_receiver expander): Adapt to thumb1_expand_prologue
3072 prototype change.
3073 (stack_protect_combined_set): New expander..
3074 (stack_protect_combined_set_insn): New insn_and_split pattern.
3075 (stack_protect_set_insn): New insn pattern.
3076 (stack_protect_combined_test): New expander.
3077 (stack_protect_combined_test_insn): New insn_and_split pattern.
3078 (arm_stack_protect_test_insn): New insn pattern.
3079 * config/arm/thumb1.md (thumb1_stack_protect_test_insn): New insn pattern.
3080 * config/arm/unspecs.md (UNSPEC_SP_SET): New unspec.
3081 (UNSPEC_SP_TEST): Likewise.
3082 * doc/md.texi (stack_protect_combined_set): Document new standard
3083 pattern name.
3084 (stack_protect_set): Clarify that the operand for guard's address is
3085 legal.
3086 (stack_protect_combined_test): Document new standard pattern name.
3087 (stack_protect_test): Clarify that the operand for guard's address is
3088 legal.
3089
3090 2018-11-22 Richard Biener <rguenther@suse.de>
3091
3092 PR tree-optimization/88148
3093 * tree-ssa-loop-niter.c (simplify_replace_tree): Get optional
3094 valueization callback parameter and handle it.
3095 * tree-ssa-loop-niter.h (simplify_replace_tree): Export.
3096 * tree-ssa-sccvn.c (process_bb): Eliminate in loop niter trees.
3097
3098 2018-11-22 Richard Biener <rguenther@suse.de>
3099
3100 PR lto/87229
3101 PR lto/88112
3102 * lto-streamer-out.c (lto_is_streamable): Allow CALL_EXPRs
3103 which can appear in size expressions.
3104 * tree-streamer-in.c (unpack_ts_base_value_fields): Stream
3105 CALL_EXPR_BY_DESCRIPTOR.
3106 (streamer_read_tree_bitfields): Stream CALL_EXPR_IFN.
3107 * tree-streamer-out.c (pack_ts_base_value_fields): Stream
3108 CALL_EXPR_BY_DESCRIPTOR.
3109 (streamer_write_tree_bitfields): Stream CALL_EXPR_IFN.
3110
3111 Revert
3112 PR lto/87229
3113 * tree.c (free_lang_data_in_one_sizepos): Free non-gimple-val
3114 sizepos values.
3115
3116 2018-11-22 Richard Biener <rguenther@suse.de>
3117
3118 PR tree-optimization/88069
3119 * tree-ssa-sccvn.c (visit_phi): Tweak previous fix to not
3120 apply to default defs.
3121
3122 2018-11-22 Jakub Jelinek <jakub@redhat.com>
3123
3124 PR target/85644
3125 PR target/86832
3126 * config/i386/i386.c (ix86_option_override_internal): Default
3127 ix86_stack_protector_guard to SSP_TLS only if TARGET_THREAD_SSP_OFFSET
3128 is defined.
3129 * config/i386/i386.md (stack_protect_set, stack_protect_set_<mode>,
3130 stack_protect_test, stack_protect_test_<mode>): Use empty condition
3131 instead of TARGET_SSP_TLS_GUARD.
3132
3133 2018-11-22 Martin Liska <mliska@suse.cz>
3134
3135 PR sanitizer/88017
3136 * config/i386/i386.c (ix86_option_override_internal): Error
3137 about usage -mabi=ms and -fsanitize=thread.
3138
3139 2018-11-21 Uros Bizjak <ubizjak@gmail.com>
3140
3141 Revert the revert:
3142 2013-10-26 Vladimir Makarov <vmakarov@redhat.com>
3143
3144 Revert:
3145 2013-10-25 Vladimir Makarov <vmakarov@redhat.com>
3146
3147 * lra-spills.c (lra_final_code_change): Remove useless move insns.
3148
3149 2018-11-21 Uros Bizjak <ubizjak@gmail.com>
3150
3151 PR middle-end/88129
3152 * function.c (expand_function_end): Do not emit extra blockage insn.
3153
3154 2018-11-21 Lokesh Janghel <lokeshjanghel91@gmail.com>
3155
3156 PR target/85667
3157 * config/i386/i386.c (function_value_ms_64): Return AX_REG instead
3158 of FIRST_SSE_REG for 4 or 8 byte modes.
3159
3160 2018-11-21 Jan Hubicka <jh@suse.cz>
3161
3162 PR lto/87957
3163 * tree.c (fld_decl_context): Break out from ...
3164 (free_lang_data_in_decl): ... here; free TREE_PUBLIC, TREE_PRIVATE
3165 DECL_ARTIFICIAL of TYPE_DECL; do not free TREE_TYPE of TYPE_DECL.
3166 (fld_incomplete_type_of): Build copy of TYP_DECL.
3167 * ipa-devirt.c (free_enum_values): Rename to ...
3168 (free_odr_warning_data): ... this one; free also duplicated TYPE_DECLs
3169 and TREE_TYPEs of TYPE_DECLs.
3170 (get_odr_type): Initialize odr_vtable_hash if needed.
3171
3172 2018-11-21 Alexandre Oliva <oliva@adacore.com>
3173
3174 * final.c (compute_discriminator): Declare. Renamed from...
3175 (maybe_set_discriminator): ... this. Set and return a local.
3176 (override_discriminator): New.
3177 (final_scan_insn_1): Set it.
3178 (notice_source_line): Adjust. Always set discriminator.
3179
3180 2018-11-21 Jakub Jelinek <jakub@redhat.com>
3181
3182 PR target/87839
3183 * config/aarch64/atomics.md (@aarch64_compare_and_swap<mode>): Use
3184 rIJ constraint for aarch64_plus_operand rather than rn.
3185
3186 2018-11-21 Renlin Li <renlin.li@arm.com>
3187
3188 PR middle-end/84877
3189 * explow.h (get_dynamic_stack_size): Declare it as external.
3190 * explow.c (record_new_stack_level): Remove function static attribute.
3191 * function.c (assign_stack_local_1): Dynamically align the stack slot
3192 addr for parameter copy on the stack.
3193
3194 2018-11-21 Richard Biener <rguenther@suse.de>
3195
3196 PR bootstrap/88133
3197 * bitmap.c (bitmap_last_set_bit): Refactor to avoid warning.
3198 * Makefile.in (bitmap.o-warn): Remove again.
3199
3200 2018-11-20 Jeff Law <law@redhat.com>
3201
3202 PR tree-optimization/88069
3203 * tree-ssa-dom.c (record_equivalences_from_phis): Propagate away
3204 degenerate virtual PHIs.
3205
3206 2018-11-21 H.J. Lu <hongjiu.lu@intel.com>
3207
3208 PR target/87317
3209 * config/i386/sse.md (sse4_1_<code>v8qiv8hi2<mask_name>): Replace
3210 nonimmediate_operand with register_operand.
3211 (avx2_<code>v8qiv8si2<mask_name>): Likewise.
3212 (sse4_1_<code>v4qiv4si2<mask_name>): Likewise.
3213 (sse4_1_<code>v4hiv4si2<mask_name>): Likewise.
3214 (sse4_1_<code>v2qiv2di2<mask_name>): Likewise.
3215 (avx512f_<code>v8qiv8di2<mask_name>): Likewise.
3216 (avx2_<code>v4qiv4di2<mask_name>): Likewise.
3217 (avx2_<code>v4hiv4di2<mask_name>): Likewise.
3218 (sse4_1_<code>v2hiv2di2<mask_name>): Likewise.
3219 (sse4_1_<code>v2siv2di2<mask_name>): Likewise.
3220 (*sse4_1_<code>v8qiv8hi2<mask_name>_1): New pattern.
3221 (*sse4_1_<code>v8qiv8hi2<mask_name>_2): Likewise.
3222 (*avx2_<code>v8qiv8si2<mask_name>_1): Likewise.
3223 (*avx2_<code>v8qiv8si2<mask_name>_2): Likewise.
3224 (*sse4_1_<code>v4qiv4si2<mask_name>_1): Likewise.
3225 (*sse4_1_<code>v4qiv4si2<mask_name>_2): Likewise.
3226 (*sse4_1_<code>v4hiv4si2<mask_name>_1): Likewise.
3227 (*sse4_1_<code>v4hiv4si2<mask_name>_2): Likewise.
3228 (*avx512f_<code>v8qiv8di2<mask_name>_1): Likewise.
3229 (*avx512f_<code>v8qiv8di2<mask_name>_2): Likewise.
3230 (*avx2_<code>v4qiv4di2<mask_name>_1): Likewise.
3231 (*avx2_<code>v4qiv4di2<mask_name>_2): Likewise.
3232 (*avx2_<code>v4hiv4di2<mask_name>_1): Likewise.
3233 (*avx2_<code>v4hiv4di2<mask_name>_2): Likewise.
3234 (*sse4_1_<code>v2hiv2di2<mask_name>_1): Likewise.
3235 (*sse4_1_<code>v2hiv2di2<mask_name>_2): Likewise.
3236 (*sse4_1_<code>v2siv2di2<mask_name>_1): Likewise.
3237 (*sse4_1_<code>v2siv2di2<mask_name>_2): Likewise.
3238
3239 2018-11-21 H.J. Lu <hongjiu.lu@intel.com>
3240
3241 * read-rtl.c (apply_subst_iterator): Handle define_split and
3242 define_insn_and_split.
3243
3244 2018-11-21 Jakub Jelinek <jakub@redhat.com>
3245
3246 PR rtl-optimization/87817
3247 * config/i386/i386.md (bmi2_bzhi_<mode>3, *bmi2_bzhi_<mode>3,
3248 *bmi2_bzhi_<mode>3_1, *bmi2_bzhi_<mode>3_1_ccz): Use IF_THEN_ELSE
3249 in the pattern to avoid triggering UB when operands[2] is zero.
3250 (tbm_bextri_<mode>): New expander. Renamed the old define_insn to ...
3251 (*tbm_bextri_<mode>): ... this.
3252
3253 2018-11-21 Tom de Vries <tdevries@suse.de>
3254
3255 PR driver/79855
3256 * params.def (HOT_BB_COUNT_FRACTION): Terminate help message with
3257 period.
3258
3259 2018-11-21 Andreas Krebbel <krebbel@linux.ibm.com>
3260
3261 * configure.ac: Add check for Binutils to determine whether vector
3262 load/store alignments hints are being supported.
3263 * config.in: Regenerate.
3264 * configure: Regenerate.
3265 * config/s390/s390.c (print_operand): Support new output
3266 modifier A.
3267 * config/s390/s390.md ("movti"): Append alignment hint output
3268 using the new output modifier 'A'.
3269 * config/s390/vector.md ("mov<mode>", "*vec_tf_to_v1tf")
3270 ("*vec_ti_to_v1ti"): Likewise.
3271
3272 2018-11-20 Martin Sebor <msebor@redhat.com>
3273
3274 * doc/extend.texi (Other Builtins): Add __builtin_has_attribute.
3275
3276 2018-11-20 Jan Hubicka <hubicka@ucw.cz>
3277
3278 PR lto/84044
3279 * ipa-devirt.c (odr_types_equivalent_p): Use operand_equal_p to
3280 compare ENUM values.
3281
3282 2018-11-20 Jakub Jelinek <jakub@redhat.com>
3283
3284 PR tree-optimization/87895
3285 * omp-simd-clone.c (ipa_simd_modify_function_body): When removing
3286 or replacing GIMPLE_RETURN, set EDGE_FALLTHRU on the edge to EXIT.
3287 (simd_clone_adjust): Don't set EDGE_FALLTHRU here. In a loop that
3288 redirects edges to EXIT to edges to incr_bb, iterate while EXIT
3289 has any preds and always use EDGE_PRED (, 0).
3290
3291 2018-11-20 Uros Bizjak <ubizjak@gmail.com>
3292
3293 PR target/88070
3294 * mode-switching.c (create_pre_exit): After reload, always split the
3295 fallthrough edge to the exit block.
3296
3297 2018-11-20 Jan Hubicka <hubicka@ucw.cz>
3298
3299 * ipa-devirt.c (add_type_duplicate): Do not ICE on incomplete enums.
3300 * tree.c (build_array_type_1): Forward declare.
3301 (fld_type_variant_equal_p): Add INNER_TYPE parameter.
3302 (fld_type_variant): Likewise.
3303 (fld_simplified_types): New hash.
3304 (fld_process_array_type): New function.
3305 (fld_incomplete_type_of): Handle array and enumeration types.
3306 (fld_simplified_type): Handle simplification of arrays.
3307 (free_lang_data): Allocate and free simplified types hash.
3308
3309 2018-11-20 Jan Hubicka <hubicka@ucw.cz>
3310
3311 PR lto/87957
3312 * ipa-devirt.c (odr_subtypes_equivalent_p): Report ODR violation
3313 when sybtype already violates ODR.
3314 (get_odr_type): Do not ICE when insert is false and type duplicate
3315 is not registered yet.
3316 (register_odr_type): Be sure to register subtypes first.
3317
3318 2018-11-20 Andreas Krebbel <krebbel@linux.ibm.com>
3319
3320 * config/s390/s390.md ("clztidi2"): Swap the RTX's written to the
3321 DImode parts of the target operand.
3322
3323 2018-11-20 Nathan Sidwell <nathan@acm.org>
3324
3325 PR 87926
3326 * Makefile.in (bitmap.o-warn): Use -Wno-error=array-bounds.
3327
3328 2018-11-20 Jan Hubicka <hubicka@ucw.cz>
3329
3330 PR lto/87997
3331 * tree.c (free_lang_data_in_cgraph): Add argument fld; break out
3332 type checking to...
3333 (free_lang_data) ... here; update call of free_lang_data_in_cgraph.
3334
3335 2018-11-20 Jan Hubicka <hubicka@ucw.cz>
3336
3337 PR ipa/87706
3338 * ipa-fnsummary.c (pass_ipa_fnsummary): Do not remove functions
3339 * ipa.c (possible_inline_candidate_p): Break out from ..
3340 (process_references): ... here ; drop before_inlining_p;
3341 cleanup handling of alises.
3342 (walk_polymorphic_call_targets): Likewise.
3343 (symbol_table::remove_unreachable_nodes): Likewise.
3344 * passes.c (pass_data_ipa_remove_symbols): New structure.
3345 (pass_ipa_remove_symbols): New pass.
3346 (make_pass_ipa_remove_symbols): New function.
3347 * tree-pass.h (make_pass_ipa_remove_symbols): Declare.
3348 * passes.def (pass_ipa_remove_symbols): Schedule after early passes.
3349
3350 2018-11-20 Richard Biener <rguenther@suse.de>
3351
3352 * tree-vect-stmts.c (vectorizable_condition): Do not get
3353 at else_clause vect def for EXTRACT_LAST_REDUCTION. Remove
3354 pointless vect_is_simple_use calls.
3355
3356 2018-11-20 Richard Biener <rguenther@suse.de>
3357
3358 PR tree-optimization/88074
3359 * tree-ssa-dom.c (pass_dominator::execute): Do not walk
3360 backedges.
3361
3362 2018-11-20 Richard Biener <rguenther@suse.de>
3363
3364 PR tree-optimization/88069
3365 * tree-ssa-sccvn.c (visit_phi): Do not value-number to unvisited
3366 virtual PHI arguments.
3367
3368 2018-11-20 Ilya Leoshkevich <iii@linux.ibm.com>
3369
3370 PR target/88083
3371 * config/s390/s390.md: Skip LT(G) peephole when literal pool is
3372 involved.
3373 * rtl.h (contains_constant_pool_address_p): New function.
3374 * rtlanal.c (contains_constant_pool_address_p): Likewise.
3375
3376 2018-11-20 Richard Biener <rguenther@suse.de>
3377
3378 PR middle-end/83215
3379 * alias.c (component_uses_parent_alias_set_from): Remove
3380 alias-set zero and TYPE_TYPELESS_STORAGE case both already
3381 handled in other ways.
3382
3383 2018-11-20 Richard Biener <rguenther@suse.de>
3384
3385 PR tree-optimization/88087
3386 * tree-ssa-pre.c (create_expression_by_pieces): Re-materialize
3387 call fntype.
3388 * tree-ssa-sccvn.c (copy_reference_ops_from_call): Remember
3389 call fntype.
3390
3391 2018-11-20 Richard Biener <rguenther@suse.de>
3392
3393 PR middle-end/88089
3394 * tree-data-ref.c (lambda_matrix_right_hermite): Use abs_hwi.
3395
3396 2018-11-19 Jan Hubicka <hubicka@ucw.cz>
3397
3398 PR lto/87957
3399 * ipa-devirt.c (free_enum_values): Do not ICE on ODR vilations.
3400
3401 2018-11-19 Sandra Loosemore <sandra@codesourcery.com>
3402
3403 PR driver/50250
3404 * doc/invoke.texi (Link Options): Mention shared libraries
3405 in documentation for the -l option. Simplify discussion and
3406 point to the system linker documentation for details.
3407
3408 2018-11-19 Peter Bergner <bergner@linux.ibm.com>
3409
3410 PR rtl-optimization/88033
3411 * ira-lives.c (non_conflicting_reg_copy_p): Skip copies from a register
3412 to itself. Use HARD_REGISTER_NUM_P.
3413
3414 2018-11-19 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
3415
3416 * tree-vect-loop.c (vect_transform_loop): Disable further unrolling
3417 of the loop if vf is non-constant.
3418
3419 2018-11-19 David Malcolm <dmalcolm@redhat.com>
3420
3421 PR tree-optimization/87025
3422 * dumpfile.c (dump_context::begin_scope): Call end_any_optinfo
3423 immediately after creating the scope optinfo.
3424 (selftest::test_pr87025): New function.
3425 (selftest::dumpfile_c_tests): Call it.
3426 * optinfo-emit-json.cc (optrecord_json_writer::pop_scope): Assert
3427 that we're not popping the top-level records array.
3428 * optinfo.cc (optinfo::handle_dump_file_kind): Assert that we're
3429 not changing the kind of a "scope" optinfo.
3430
3431 2018-11-19 David Malcolm <dmalcolm@redhat.com>
3432
3433 PR tree-optimization/87025
3434 * dump-context.h: Include "optinfo.h".
3435 (class optrecord_json_writer): New forward decl.
3436 (dump_context::forcibly_enable_optinfo_p): Delete.
3437 (dump_context::optinfo_enabled_p): New member function.
3438 (dump_context::optimization_records_enabled_p): New member
3439 function.
3440 (dump_context::set_json_writer): New member function.
3441 (dump_context::emit_optinfo): New member function.
3442 (dump_context::m_forcibly_enable_optinfo): Delete.
3443 (dump_context::m_json_writer): New member data.
3444 * dumpfile.c (dump_context::set_json_writer): New member function.
3445 (dump_context::finish_any_json_writer): New member function.
3446 (dump_context::end_scope): Replace call to
3447 optimization_records_maybe_pop_dump_scope with call to
3448 m_json_writer->pop_scope.
3449 (dump_context::optinfo_enabled_p): New member function.
3450 (dump_context::end_any_optinfo): Replace call to optinfo::emit with call
3451 to dump_context::emit_optinfo.
3452 (dump_context::emit_optinfo): New member function.
3453 (temp_dump_context::temp_dump_context): Replace
3454 m_forcibly_enable_optinfo with call to set_json_writer.
3455 (temp_dump_context::~temp_dump_context): Clean up any json writer.
3456 * optinfo-emit-json.cc (class optrecord_json_writer): Move to
3457 optinfo-emit-json.h
3458 (the_json_writer): Delete.
3459 (optimization_records_start): Delete.
3460 (optimization_records_finish): Delete.
3461 (optimization_records_enabled_p): Delete, in favor of
3462 dump_context::optimization_records_enabled_p.
3463 (optimization_records_maybe_record_optinfo): Delete.
3464 (optimization_records_maybe_pop_dump_scope): Delete.
3465 * optinfo-emit-json.h: Include "json.h". Delete forward
3466 decl of opt_pass.
3467 (optimization_records_start): Delete.
3468 (optimization_records_finish): Delete.
3469 (optimization_records_enabled_p): Delete.
3470 (optimization_records_maybe_record_optinfo): Delete.
3471 (optimization_records_maybe_pop_dump_scope): Delete.
3472 (class optrecord_json_writer): Move here from
3473 optinfo-emit-json.cc.
3474 * optinfo.cc (optinfo::emit_for_opt_problem): Replace call
3475 to optinfo::emit with call to dump_context::emit_optinfo.
3476 (optinfo::emit): Delete, in favor of dump_context::emit_optinfo.
3477 (optinfo_enabled_p): Delete, in favor of
3478 dump_context::optinfo_enabled_p.
3479 (optinfo_wants_inlining_info_p): Update for conversion o
3480 optimization_records_enabled_p to a member function of
3481 dump_context.
3482 * optinfo.h (optinfo_enabled_p): Delete, in favor of
3483 dump_context::optinfo_enabled_p.
3484 (optinfo::emit): Delete, in favor of dump_context::emit_optinfo.
3485 * toplev.c: Include "dump-context.h".
3486 (compile_file): Replace call to optimization_records_finish with
3487 dump_context::finish_any_json_writer.
3488 (do_compile): Replace call to optimization_records_start with
3489 conditionally creating a optrecord_json_writer for the
3490 dump_context.
3491
3492 2018-11-19 Jakub Jelinek <jakub@redhat.com>
3493
3494 PR tree-optimization/88071
3495 * tree-vect-loop.c (vectorize_fold_left_reduction): Pass true instead
3496 of false as last argument to gsi_remove.
3497 * tree-vect-stmts.c (vect_finish_replace_stmt): Pass true instead of
3498 false as last argument to gsi_replace.
3499
3500 PR debug/87039
3501 * omp-expand.c: Don't include debug.h.
3502 (adjust_context_and_scope): Add REGION argument. Find DECL_CONTEXT
3503 from innermost outer parallel, task, teams or target that has a
3504 child_fn set, or, if there is no such outer region, use
3505 current_function_decl. Do the DECL_CONTEXT adjustment regardless of
3506 whether a suitable BLOCK is found or not.
3507 (expand_parallel_call, expand_teams_call): Don't call
3508 adjust_context_and_scope here.
3509 (grid_expand_target_grid_body): Revert 2017-01-25 changes.
3510 (expand_omp_taskreg, expand_omp_target): Likewise. Call
3511 adjust_context_and_scope.
3512 * dwarf2out.c (dwarf2out_early_global_decl): For
3513 decl_function_context recurse instead of calling dwarf2out_decl.
3514
3515 2018-11-20 Eric Botcazou <ebotcazou@adacore.com>
3516
3517 PR rtl-optimization/85925
3518 * rtl.h (word_register_operation_p): New predicate.
3519 * combine.c (record_dead_and_set_regs_1): Only apply specific handling
3520 for WORD_REGISTER_OPERATIONS targets to word_register_operation_p RTX.
3521 * rtlanal.c (nonzero_bits1): Likewise. Adjust couple of comments.
3522 (num_sign_bit_copies1): Likewise.
3523
3524 2018-11-19 Richard Biener <rguenther@suse.de>
3525
3526 PR lto/87229
3527 * tree.c (free_lang_data_in_one_sizepos): Free non-gimple-val
3528 sizepos values.
3529
3530 2018-11-19 Eric Botcazou <ebotcazou@adacore.com>
3531
3532 * compare-elim.c (struct comparison): Add not_in_a field.
3533 (is_not): New static function.
3534 (strip_not): Likewise.
3535 (conforming_compare): Handle a NOT in the first operand.
3536 (can_eliminate_compare): Likewise.
3537 (find_comparison_dom_walker::before_dom_children): Likewise.
3538 (try_eliminate_compare): Likewise.
3539 * config/visium/visium.md (negsi2_insn_set_carry): Turn into...
3540 (neg<mode>2_insn_set_carry): ...this and add missing NEG operation.
3541
3542 2018-11-19 Jonathan Wakely <jwakely@redhat.com>
3543
3544 * doc/extend.texi (Common Type Attributes): Fix typos.
3545
3546 2018-11-19 Martin Liska <mliska@suse.cz>
3547
3548 PR gcov-profile/88045
3549 * coverage.c (coverage_begin_function): Add assert.
3550
3551 2018-11-18 Sandra Loosemore <sandra@codesourcery.com>
3552
3553 PR other/40498
3554 * doc/extend.texi (Common Function Attributes): Document that
3555 no_instrument_function applies to -p and -pg, too.
3556 * doc/invoke.texi (Instrumentation Options): Add cross-references
3557 to docs for -p, -pg, and -finstrument-functions.
3558
3559 2018-11-18 Alan Modra <amodra@gmail.com>
3560
3561 * config/gnu-user.h (GNU_USER_TARGET_CRTI): Define.
3562 (GNU_USER_TARGET_STARTFILE_SPEC): Use it here.
3563 (GNU_USER_TARGET_CRTN): Define.
3564 (GNU_USER_TARGET_ENDFILE_SPEC): Use it here.
3565 (GNU_USER_TARGET_LINK_GCC_C_SEQUENCE_SPEC): Define.
3566
3567 2018-11-18 Alan Modra <amodra@gmail.com>
3568
3569 * config/gnu-user.h (GNU_USER_TARGET_STARTFILE_SPEC): Delete
3570 !HAVE_LD_PIE variant.
3571 (GNU_USER_TARGET_ENDFILE_SPEC): Likewise.
3572
3573 2018-11-17 Nick Clifton <nickc@redhat.com>
3574 Sandra Loosemore <sandra@codesourcery.com>
3575
3576 PR driver/31357
3577 * doc/invoke.texi (Overall Options): Document that --help and
3578 --help=<value> options cannot be combined.
3579
3580 2018-11-17 Jim Wilson <jimw@sifive.com>
3581
3582 * config/riscv/riscv.c (epilogue_cfa_sp_offset): New.
3583 (riscv_restore_reg): If restoring HARD_FRAME_POINTER_REGNUM, and
3584 epilogue_cfa_sp_offset set, then add REG_CFA_DEF_CFA regnote.
3585 (riscv_expand_epilogue): Initialize epilogue_cfa_sp_offset. Set it
3586 to step2 if frame_pointer_needed and step1 is 0.
3587
3588 2018-11-17 Sandra Loosemore <sandra@codesourcery.com>
3589
3590 PR c++/4225
3591 * doc/cpp.texi (System Headers): Add note about implicit
3592 extern "C" block on targets that define SYSTEM_IMPLICIT_EXTERN_C.
3593
3594 2018-11-17 Sandra Loosemore <sandra@codesourcery.com>
3595
3596 PR c++/4025
3597 * doc/invoke.texi (C++ Dialect Options): Clarify usage of
3598 -fno-implicit-templates.
3599
3600 2018-11-17 Jakub Jelinek <jakub@redhat.com>
3601
3602 PR tree-optimization/87546
3603 * tree-vect-patterns.c (vect_look_through_possible_promotion): Add
3604 min_precision variable, initially set it to orig_precision, only does
3605 something if op_type's precision is <= min_precision and update
3606 min_precision whenever calling set_op.
3607
3608 2018-11-16 Jan Hubicka <hubicka@ucw.cz>
3609
3610 PR ipa/87957
3611 * ipa-devirt.c (warn_odr): Look for main variant to get TYPE_DECL.
3612
3613 2018-11-16 Sandra Loosemore <sandra@codesourcery.com>
3614
3615 * doc/invoke.texi (Option Summary): Fix whitespace and line
3616 breaks in @gccoptlist environments.
3617 (Warning Options): Likewise.
3618 (Optimize Options): Likewise.
3619 (PowerPC SPE Options): Likewise.
3620 (RS/6000 and PowerPC Options): Likewise.
3621
3622 2018-11-16 Jeff Law <law@redhat.com>
3623
3624 * config/mn10300/mn10300.md (adddi3_degenerate): Remove bogus
3625 gcc_assert.
3626
3627 2018-11-16 Sandra Loosemore <sandra@codesourcery.com>
3628
3629 PR middle-end/23197
3630 * doc/invoke.texi (Optimize Options): Update options enabled by
3631 fprofile-generate, -fprofile-use, and -fauto-profile.
3632
3633 2018-11-16 Jozef Lawrynowicz <jozef.l@mittosystems.com>
3634
3635 PR target/87927
3636 * target-def.h: Initialize TARGET_ASM_{,UN}ALIGNED_P{S,D,T}I_OP.
3637 Add them to the TARGET_ASM_{,UN}ALIGNED_INT_OP structs.
3638 * target.def: Enumerate TARGET_ASM_{,UN}ALIGNED_P{S,D,T}I_OP in
3639 the byte_op hook.
3640 * target.h: Add psi, pdi, pti to struct asm_int_op definition.
3641 * targhooks.c (default_print_patchable_function_entry): Assert
3642 asm_int_op does not return a NULL string.
3643 * varasm.c (integer_asm_op): Return the op for a partial int type
3644 when the requested size does not correspond to an integer type.
3645 * config/msp430/msp430.c: Initialize TARGET_ASM_{,UN}ALIGNED_PSI_OP.
3646 * doc/tm.texi: Regenerate.
3647
3648 2018-11-12 Jason Merrill <jason@redhat.com>
3649
3650 * gimplify.c (gimplify_case_label_expr): Handle hot/cold attributes.
3651
3652 2018-11-16 Michael Meissner <meissner@linux.ibm.com>
3653
3654 * config/rs6000/constraints.md (wF constraint): Remove power9
3655 fusion documentation. Just document wF's use for power8 fusion.
3656 * config/rs6000/predicates.md (p9_fusion_reg_operand): Delete.
3657 (fusion_gpr_addis): Delete power9 fusion support. Change power8
3658 fusion support to require the upper 12 bits to be all 0's or all
3659 1's.
3660 (fusion_gpr_mem_load): Add comment.
3661 (fusion_addis_mem_combo_load): Remove power9 fusion support.
3662 (fusion_addis_mem_combo_store): Delete.
3663 (fusion_offsettable_mem_operand): Delete.
3664 * config/rs6000/rs6000-cpus.def (ISA_2_7_MASKS_SERVER): Do not set
3665 power8 fusion here.
3666 (ISA_3_0_MASKS_SERVER): Delete power9 fusion.
3667 (POWERPC_MASKS): Delete power9 fusion.
3668 * config/rs6000/rs6000-protos.h (emit_fusion_load_store): Delete.
3669 (fusion_p9_p): Delete.
3670 (expand_fusion_p9_load): Delete.
3671 (expand_fusion_p9_store): Delete.
3672 (emit_fusion_p9_load): Delete.
3673 (emit_fusion_p9_store): Delete.
3674 * config/rs6000/rs6000.c (rs6000_debug_reg_global): Delete power9
3675 fusion support.
3676 (rs6000_option_override_internal): Set power8 fusion based on
3677 whether we are tuning for power8. Delete power9 fusion support.
3678 (rs6000_opt_masks): Delete -mpower9-fusion switch.
3679 (emit_fusion_load): Rename emit_fusion_load_store to
3680 emit_fusion_load, and drop fusion store support. Update callers.
3681 (emit_fusion_load_store): Likewise.
3682 (emit_fusion_gpr_load): Likewise.
3683 (fusion_p9_p): Delete.
3684 (expand_fusion_p9_load): Delete.
3685 (expand_fusion_p9_store): Delete.
3686 (emit_fusion_p9_load): Delete.
3687 (emit_fusion_p9_store): Delete.
3688 * config/rs6000/rs6000.md (UNSPEC_FUSION_P9): Delete.
3689 (GPR_FUSION): Delete.
3690 (FPR_FUSION): Delete.
3691 (power9 fusion peephole2s): Delete.
3692 (fusion_gpr_<P:mode>_<GPR_FUSION:mode>_load): Delete.
3693 (fusion_gpr_<P:mode>_<GPR_FUSION:mode>_store): Delete.
3694 (fusion_vsx_<P:mode>_<FPR_FUSION:mode>_load): Delete.
3695 (fusion_vsx_<P:mode>_<FPR_FUSION:mode>_store): Delete.
3696 (fusion_p9_<mode>_constant): Delete.
3697 * config/rs6000/rs6000.opt (-mpower9-fusion): Delete undocumented
3698 power9 fusion switch.
3699 * doc/md.texi (PowerPC constraints): Update wF constraint
3700 documentation for power8 fusion only.
3701
3702 2018-11-16 Jakub Jelinek <jakub@redhat.com>
3703
3704 PR rtl-optimization/87475
3705 * cfgrtl.c (patch_jump_insn): Allow redirection failure for
3706 CROSSING_JUMP_P insns.
3707 (cfg_layout_redirect_edge_and_branch): Don't ICE if ret is NULL.
3708
3709 2018-11-16 Uros Bizjak <ubizjak@gmail.com>
3710
3711 PR target/88051
3712 * config/i386/i386.md (floatunsdidf2): Allow only 64bit AVX512F targets.
3713 * config/i386/sse.md (UNSPEC_MOVDI_TO_SSE): New UNSPEC.
3714 (movdi_to_sse): Rewrite using UNSPEC_MOVDI_TO_SSE unspec.
3715
3716 2018-11-16 Jakub Jelinek <jakub@redhat.com>
3717
3718 PR middle-end/88032
3719 * optabs.c (expand_binop): For op0_mode use GET_MODE (op0), unless it
3720 is VOIDmode, in which case use int_mode. Similarly for op1_mode.
3721
3722 2018-11-16 Eric Botcazou <ebotcazou@adacore.com>
3723
3724 * tree-switch-conversion.h (switch_decision_tree::emit_case_nodes): Add
3725 location_t parameter.
3726 (switch_decision_tree::emit_cmp_and_jump_insns): Likewise.
3727 (switch_decision_tree::do_jump_if_equal): Likewise.
3728 * tree-switch-conversion.c (switch_decision_tree::emit): Pass location
3729 of switch statement to emit_case_nodes.
3730 (switch_decision_tree::emit_cmp_and_jump_insns): Add LOC parameter and
3731 set it on the newly built GIMPLE comparison statement.
3732 (switch_decision_tree::do_jump_if_equal): Likewise.
3733 (switch_decision_tree::emit_case_nodes): Add LOC parameter and pass it
3734 in calls to do_jump_if_equal as well as recursive calls.
3735
3736 2018-11-16 Andi Kleen <ak@linux.intel.com>
3737
3738 * config/i386/i386.md: Allow memory operands to ptwrite.
3739
3740 2018-11-16 Michael Matz <matz@suse.de>
3741
3742 * system.h (PRsa): New macro.
3743 (SIZE_AMOUNT): Cast number to uint64_t.
3744 * alloc-pool.h (pool_usage::dump): Don't use %zu but PRsa.
3745 (pool_usage::dump_footer): Likewise and also use PRIu64.
3746 * bitmap.h (bitmap_usage::dump): Likewise.
3747 * ggc-common.c (ggc_usage::dump): Likewise.
3748 * ggc-page.c (ggc_print_statistics): Likewise.
3749 * input.c (dump_line_table_statistics): Likewise.
3750 * mem-stats.h (mem_usage::dump): Likewise.
3751 (mem_usage::dump_footer): Likewise.
3752 * rtl.c (dump_rtx_statistics): Likewise.
3753 * tree-cfg.c (dump_cfg_stats): Likewise.
3754 * tree-dfa.c (dump_dfa_stats): Likewise.
3755 * tree-phinodes.c (phinodes_print_statistics): Likewise.
3756 * tree-ssanames (ssanames_print_statistics): Likewise.
3757 * vec.c (vec_usage::dump): Likewise.
3758 (vec_usage::dump_footer): Likewise.
3759
3760 2018-11-16 Richard Biener <rguenther@suse.de>
3761
3762 PR tree-optimization/88011
3763 * tree-vrp.c (extract_range_from_binary_expr): Fix error in
3764 replacing set_value_range_to_undefined and
3765 set_value_range_to_varying with method calls.
3766
3767 2018-11-16 Ilya Leoshkevich <iii@linux.ibm.com>
3768
3769 * config/s390/s390.md
3770 (*r<noxa>sbg_<mode>_srl_bitmask): Do not delegate arithmetic to
3771 assembler.
3772 (*r<noxa>sbg_<mode>_sll): Likewise.
3773 (*r<noxa>sbg_<mode>_srl): Likewise.
3774 (*r<noxa>sbg_sidi_srl): New pattern.
3775
3776 2018-11-16 Jerome Lambourg <lambourg@adacore.com>
3777
3778 * config/vxworks.h (TARGET_VXWORKS_HAVE_CTORS_DTORS): New macro.
3779 Default to TARGET_VXWORKS_RTP.
3780 (SUPPORTS_INIT_PRIORITY): Use TARGET_VXWORKS_HAVE_CTORS_DTORS instead
3781 of TARGET_VXWORKS_RTP.
3782 * config/vxworks.c: Use TARGET_VXWORKS_HAVE_CTORS_DTORS instead
3783 of TARGET_VXWORKS_RTP to set targetm.have_ctors_dtors.
3784
3785 2018-11-15 Sandra Loosemore <sandra@codesourcery.com>
3786
3787 PR c++/25759
3788 * doc/extend.texi (Common Type Attributes): Make it explicit
3789 that attribute "packed" can apply to C++ classes.
3790
3791 2018-11-15 Martin Sebor <msebor@redhat.com>
3792
3793 PR c++/87541
3794 PR c++/87542
3795 * tree.c (type_argument_type): New function.
3796 * tree.h (type_argument_type): Declare it.
3797 * gcc/doc/extend.texi (alloc_align): Update and clarify.
3798 (alloc_size, nonnull, sentinel): Same.
3799
3800 2018-11-15 Andrew Stubbs <ams@codesourcery.com>
3801 Kwok Cheung Yeung <kcy@codesourcery.com>
3802
3803 * tree-vect-stmts.c (vectorizable_store): Don't ICE when
3804 int_mode_for_size fails.
3805 (vectorizable_load): Likewise.
3806
3807 2018-11-15 David Malcolm <dmalcolm@redhat.com>
3808
3809 * doc/ux.texi (Group logically-related diagnostics): Move
3810 discussion of auto_diagnostic_group into this new subsection.
3811 Give an example of where this grouping is used.
3812
3813 2018-11-15 David Malcolm <dmalcolm@redhat.com>
3814
3815 PR other/19165
3816 * Makefile.in (OBJS): Move json.o to...
3817 (OBJS-libcommon): ...here and add diagnostic-format-json.o.
3818 * common.opt (fdiagnostics-format=): New option.
3819 (diagnostics_output_format): New enum.
3820 * diagnostic-format-json.cc: New file.
3821 * diagnostic.c (default_diagnostic_final_cb): New function, taken
3822 from start of diagnostic_finish.
3823 (diagnostic_initialize): Initialize final_cb to
3824 default_diagnostic_final_cb.
3825 (diagnostic_finish): Move "being treated as errors" messages to
3826 default_diagnostic_final_cb. Call any final_cb.
3827 (default_diagnostic_finalizer): Add diagnostic_t param.
3828 (diagnostic_report_diagnostic): Pass "orig_diag_kind" to
3829 diagnostic_finalizer callback.
3830 * diagnostic.h (enum diagnostics_output_format): New enum.
3831 (diagnostic_finalizer_fn): Reimplement, adding diagnostic_t param.
3832 (struct diagnostic_context): Add "final_cb".
3833 (default_diagnostic_finalizer): Add diagnostic_t param.
3834 (diagnostic_output_format_init): New decl.
3835 * doc/invoke.texi (-fdiagnostics-format): New option.
3836 * dwarf2out.c (gen_producer_string): Ignore
3837 OPT_fdiagnostics_format_.
3838 * gcc.c (driver_handle_option): Handle OPT_fdiagnostics_format_.
3839 * lto-wrapper.c (append_diag_options): Ignore it.
3840 * opts.c (common_handle_option): Handle it.
3841
3842 2018-11-15 David Malcolm <dmalcolm@redhat.com>
3843
3844 PR tree-optimization/88015
3845 * graphite-isl-ast-to-gimple.c
3846 (translate_isl_ast_to_gimple::scop_to_isl_ast): Add missing check
3847 for dump_enabled_p.
3848 * graphite-sese-to-poly.c (build_poly_scop): Likewise.
3849
3850 2018-11-15 Richard Biener <rguenther@suse.de>
3851
3852 PR middle-end/88029
3853 * gimple.c (gimple_call_flags): Union flags from decl, type
3854 and call fntype.
3855 * trans-mem.c (is_tm_pure_call): Simplify.
3856
3857 2018-11-15 Richard Biener <rguenther@suse.de>
3858
3859 PR tree-optimization/88031
3860 * tree-vect-loop.c (vectorizable_reduction): Move check
3861 for multiple types earlier so we get the expected dump.
3862 Simplify calls to vectorizable_condition.
3863 * tree-vect-stmts.h (vectorizable_condition): Update prototype.
3864 * tree-vect-stmts.c (vectorizable_condition): Instead of
3865 reduc_def and reduc_index take just a flag. Simplify
3866 code-generation now that we can rely on the defs being set up.
3867 (vectorizable_comparison): Remove unused argument.
3868
3869 2018-11-15 Richard Biener <rguenther@suse.de>
3870
3871 PR tree-optimization/88030
3872 * tree-complex.c (need_eh_cleanup): New global.
3873 (update_complex_assignment): Mark blocks that need EH update.
3874 (expand_complex_comparison): Likewise.
3875 (tree_lower_complex): Allocate and deallocate need_eh_cleanup,
3876 perform EH cleanup and schedule CFG cleanup if that did anything.
3877
3878 2018-11-15 Jakub Jelinek <jakub@redhat.com>
3879
3880 PR rtl-optimization/88018
3881 * cfgrtl.c (fixup_abnormal_edges): Guard moving insns to fallthru edge
3882 on the presence of fallthru edge, rather than if it is a USE or not.
3883
3884 2018-11-15 Richard Biener <rguenther@suse.de>
3885
3886 PR middle-end/87917
3887 * tree-data-ref.c (analyze_miv_subscript): Guard calls to
3888 analyze_subscript_affine_affine properly.
3889
3890 2018-11-15 Xianmiao Qu <xianmiao_qu@c-sky.com>
3891
3892 * config/csky/csky-linux-elf.h (LINUX_DYNAMIC_LINKER): Remove.
3893 (GLIBC_DYNAMIC_LINKER): Define.
3894 (LINUX_TARGET_LINK_SPEC): Update the dynamic linker's name.
3895
3896 2018-11-15 Bin Cheng <bin.cheng@linux.alibaba.com>
3897
3898 PR tree-optimization/84648
3899 * tree-ssa-loop-niter.c (adjust_cond_for_loop_until_wrap): New.
3900 (number_of_iterations_cond): Adjust exit cond for loop-until-wrap case
3901 by calling adjust_cond_for_loop_until_wrap.
3902
3903 2018-11-15 Sandra Loosemore <sandra@codesourcery.com>
3904
3905 PR other/56334
3906 * doc/extend.texi (Common Function Attributes): Clarify linker
3907 restrictions on "aligned" attribute.
3908 (Common Variable Attributes): Likewise. Mention that linker
3909 restrictions don't apply to stack-allocated variables.
3910
3911 2018-11-15 Joern Rennecke <joern.rennecke@riscy-ip.com>
3912
3913 * gensupport.c (add_predicate_code): Properly handle ZERO_EXTRACT
3914 as an lvalue.
3915
3916 2018-11-14 Sandra Loosemore <sandra@codesourcery.com>
3917
3918 PR lto/55102
3919 PR lto/56700
3920 * doc/invoke.texi (Optimize Options): Remove bad example about
3921 interaction between -flto and -O. Replace it with a note that
3922 you need to compile with -O and not just link. Copy-edit -flto
3923 discussion to reduce verbiage and improve flow.
3924
3925 2018-11-14 Sandra Loosemore <sandra@codesourcery.com>
3926
3927 PR middle-end/59658
3928 * doc/invoke.texi (Optimize Options): Clarify that -O0 and -Og
3929 also suppress many optimizations. Alphabetize option lists for
3930 -O1, -O2, and -Os. Add list of options disabled with -Og, and
3931 correct documentation for those options to say that.
3932 * opts.c (default_options_table): Sort table by level and option
3933 name, to make it easier to correlate to the manual.
3934
3935 2018-11-14 Uros Bizjak <ubizjak@gmail.com>
3936
3937 * config/i386/i386.c (ix86_print_operand_address_as): Simplify
3938 printing of the names of segment registers.
3939
3940 2018-11-14 Nathan Sidwell <nathan@acm.org>
3941
3942 PR debug/88006
3943 PR debug/87462
3944 * dwarf2out.c (dwarf2out_finish): Apply resolve_addr to comdat
3945 type list.
3946
3947 2018-11-14 David Malcolm <dmalcolm@redhat.com>
3948
3949 * Makefile.in (CFLAGS-optinfo-emit-json.o): Add $(ZLIBINC).
3950
3951 2018-11-14 Jakub Jelinek <jakub@redhat.com>
3952
3953 P1236R1 - Signed integers are two's complement
3954 * doc/invoke.texi (Wshift-overflow): Adjust documentation for c++2a.
3955
3956 PR bootstrap/86739
3957 * hash-map.h (hash_map::iterator::reference_pair): New class.
3958 (hash_map::iterator::operator*): Return it rather than std::pair.
3959
3960 2018-11-14 Jeff Law <law@redhat.com>
3961
3962 * optabs.c (expand_binop): Pass INT_MODE to operand_subword_force
3963 iff the operand is a constant.
3964
3965 2018-11-14 Aldy Hernandez <aldyh@redhat.com>
3966
3967 * gimple-ssa-evrp-analyze.c
3968 (evrp_range_analyzer::record_ranges_from_incoming_edge): Rename
3969 ignore_equivs_equal_p to equal_p.
3970 * ipa-cp.c (meet_with_1): Use equal_p instead of
3971 ignore_equivs_equal_p.
3972 * ipa-prop.c (ipa_vr_ggc_hash_traits::equal): Same.
3973 * tree-vrp.c (value_range::ignore_equivs_equal_p): Remove.
3974 (value_range::operator==): Remove.
3975 (value_range::operator!=): Remove.
3976 (vrp_prop::visit_stmt): Use equal_p.
3977 * tree-vrp.h (value_range): Remove operator==, operator!=,
3978 ignore_equivs_equal_p.
3979 * vr-values.c (update_value_range): Use equal_p.
3980
3981 2018-11-14 Michael Matz <matz@suse.de>
3982
3983 PR middle-end/86575
3984 * gimplify.c (collect_fallthrough_labels): Add new argument,
3985 return location via that, don't modify statements.
3986 (warn_implicit_fallthrough_r): Adjust call, don't use
3987 statement location directly.
3988
3989 2018-11-14 Richard Biener <rguenther@suse.de>
3990
3991 PR middle-end/87985
3992 * tree-data-ref.c (split_constant_offset): Add wrapper
3993 allocating a cache hash-map.
3994 (split_constant_offset_1): Cache results of expanding
3995 expressions from SSA def stmts.
3996
3997 2018-11-14 Richard Biener <rguenther@suse.de>
3998
3999 PR middle-end/88021
4000 * tree-data-ref.c (lambda_matrix_row_add): Change const1 argument
4001 to lambda_int.
4002 (lambda_vector_mult_const): Likewise.
4003 (lambda_matrix_right_hermite): Use lambda_int temporaries.
4004
4005 2018-11-14 Wilco Dijkstra <wdijkstr@arm.com>
4006 Jackson Woodruff <jackson.woodruff@arm.com>
4007
4008 PR 71026/tree-optimization
4009 * match.pd: Simplify floating point comparisons.
4010
4011 2018-11-14 Jakub Jelinek <jakub@redhat.com>
4012
4013 PR rtl-optimization/87817
4014 * config/i386/i386.c (ix86_fold_builtin): For _bzhi_u{32,64} if
4015 last argument has low 8 bits clear, fold to 0.
4016
4017 2018-11-14 Iain Sandoe <iain@sandoe.co.uk>
4018
4019 * tree-vect-data-refs.c (vect_can_force_dr_alignment_p): Cast
4020 MAX_OFILE_ALIGNMENT as needed.
4021
4022 2018-11-14 Richard Biener <rguenther@suse.de>
4023
4024 PR tree-optimization/88019
4025 * graphite-isl-ast-to-gimple.c (ternary_op_to_tree): Rewrite
4026 COND_EXPR arguments to non-trapping overflow.
4027
4028 2018-11-14 Claudiu Zissulescu <claziss@synopsys.com>
4029
4030 * config/arc/arc.h (reg_class): Reorder registers classes, remove
4031 unused register classes.
4032 (REG_CLASS_NAMES): Likewise.
4033 (REG_CLASS_CONTENTS): Likewise.
4034 (FIXED_REGISTERS): Make lp_count fixed.
4035 (BASE_REG_CLASS): Remove ACC16_BASE_REGS reference.
4036 (PROGRAM_COUNTER_REGNO): Remove.
4037 * config/arc/arc.c (arc_conditional_register_usage): Remove unused
4038 register classes, use constants for register numbers, remove
4039 reg_class_contents references.
4040 (arc_process_double_reg_moves): Add asserts.
4041 (arc_secondary_reload): Remove LPCOUNT_REG reference, use
4042 lra_in_progress predicate.
4043 (arc_init_reg_tables): Remove unused register classes.
4044 (arc_register_move_cost): Likewise.
4045 (arc_preferred_reload_class): Likewise.
4046 (hwloop_optimize): Update rtx patterns involving lp_count register.
4047 (arc_return_address_register): Rename ILINK1, INLINK2 regnums macros.
4048 * config/arc/constraints.md ("c"): Choose between GENERAL_REGS and
4049 CHEAP_CORE_REGS. Former one will be used for LRA.
4050 ("Rac"): Choose between GENERAL_REGS and ALL_CORE_REGS. Former
4051 one will be used for LRA.
4052 ("w"): Choose between GENERAL_REGS and WRITABLE_CORE_REGS. Former
4053 one will be used for LRA.
4054 ("W"): Choose between GENERAL_REGS and MPY_WRITABLE_CORE_REGS.
4055 Former one will be used for LRA.
4056 ("f"): Delete constraint.
4057 ("k"): Likewise.
4058 ("e"): Likewise.
4059 ("l"): Change it from register constraint to constraint.
4060 * config/arc/arc.md (movqi_insn): Remove unsed lp_count constraints.
4061 (movhi_insn): Likewise.
4062 (movsi_insn): Update pattern.
4063 (arc_lp): Likewise.
4064 (dbnz): Likewise.
4065 (stack_tie): Remove 'b' constraint letter.
4066 (R4_REG): Define.
4067 (R9_REG, R15_REG, R16_REG, R25_REG): Likewise.
4068 (R32_REG, R40_REG, R41_REG, R42_REG, R43_REG, R44_REG): Likewise.
4069 (R57_REG, R59_REG, PCL_REG): Likewise.
4070 (ILINK1_REGNUM): Renamed to ILINK1_REG.
4071 (ILINK2_REGNUM): Renamed to ILINK2_REG.
4072 (Rgp): Remove.
4073 (SP_REGS): Likewise.
4074 (Rcw): Remove unused reg classes.
4075 * config/arc/predicates.md (dest_reg_operand): Just default on
4076 register_operand predicate.
4077 (mpy_dest_reg_operand): Likewise.
4078 (move_dest_operand): Use macros instead of constants.
4079 * config/arc/arc.opt (mlra): Switch to lra as default.
4080
4081 2018-11-14 Richard Biener <rguenther@suse.de>
4082
4083 PR tree-optimization/87974
4084 * tree-vect-loop.c (vectorizable_reduction): When computing
4085 the vectorized reduction PHI vector type ignore constant
4086 and external defs.
4087
4088 2018-11-14 Jakub Jelinek <jakub@redhat.com>
4089
4090 PR tree-optimization/87977
4091 * tree-ssa-math-opts.c (optimize_recip_sqrt): Don't reuse division
4092 stmt, build a new one and replace the old one with it. Formatting fix.
4093 Call release_ssa_name (x) if !has_other_use and !delete_div.
4094 (pass_cse_reciprocals::execute): Before calling optimize_recip_sqrt
4095 verify lhs of stmt is still def.
4096
4097 2018-11-13 Peter Bergner <bergner@linux.ibm.com>
4098
4099 PR rtl-optimization/87507
4100 * lower-subreg.c (operand_for_swap_move_operator): New function.
4101 (simple_move): Strip simple operators.
4102 (find_pseudo_copy): Likewise.
4103 (resolve_operand_for_swap_move_operator): New function.
4104 (resolve_simple_move): Strip simple operators and swap operands.
4105
4106 2018-11-13 Jakub Jelinek <jakub@redhat.com>
4107
4108 PR tree-optimization/87898
4109 * omp-simd-clone.c (ipa_simd_modify_stmt_ops): Formatting fix.
4110 (ipa_simd_modify_function_body): Remove debug stmts where the first
4111 argument was changed into a non-decl.
4112
4113 2018-11-13 Peter Bergner <bergner@linux.ibm.com>
4114
4115 PR rtl-optimization/87899
4116 * lra-lives.c (start_living): Update white space in comment.
4117 (enum point_type): New.
4118 (sparseset_contains_pseudos_p): New function.
4119 (update_pseudo_point): Likewise.
4120 (make_hard_regno_live): Use HARD_REGISTER_NUM_P macro.
4121 (make_hard_regno_dead): Likewise. Remove ignore_reg_for_conflicts
4122 handling. Move early exit after adding conflicts.
4123 (mark_pseudo_live): Use HARD_REGISTER_NUM_P macro. Add early exit
4124 if regno is already live. Remove all handling of program points.
4125 (mark_pseudo_dead): Use HARD_REGISTER_NUM_P macro. Add early exit
4126 after adding conflicts. Remove all handling of program points and
4127 ignore_reg_for_conflicts.
4128 (mark_regno_live): Use HARD_REGISTER_NUM_P macro. Remove return value
4129 and do not guard call to mark_pseudo_live.
4130 (mark_regno_dead): Use HARD_REGISTER_NUM_P macro. Remove return value
4131 and do not guard call to mark_pseudo_dead.
4132 (check_pseudos_live_through_calls): Use HARD_REGISTER_NUM_P macro.
4133 (process_bb_lives): Use HARD_REGISTER_NUM_P and HARD_REGISTER_P macros.
4134 Use new function update_pseudo_point. Handle register copies by
4135 removing the source register from the live set. Handle INOUT operands.
4136 Update to the next program point using the unused_set, dead_set and
4137 start_dying sets.
4138 (lra_create_live_ranges_1): Use HARD_REGISTER_NUM_P macro.
4139
4140 2018-11-13 David Malcolm <dmalcolm@redhat.com>
4141
4142 * builtins.c: Replace "source_location" with "location_t".
4143 * diagnostic-show-locus.c: Likewise.
4144 * diagnostic.c: Likewise.
4145 * dumpfile.c: Likewise.
4146 * gcc-rich-location.h: Likewise.
4147 * genmatch.c: Likewise.
4148 * gimple.h: Likewise.
4149 * gimplify.c: Likewise.
4150 * input.c: Likewise.
4151 * input.h: Likewise. Eliminate the typedef.
4152 * omp-expand.c: Likewise.
4153 * selftest.h: Likewise.
4154 * substring-locations.h (get_source_location_for_substring):
4155 Rename to...
4156 (get_location_within_string): ...this.
4157 * tree-cfg.c: Replace "source_location" with "location_t".
4158 * tree-cfgcleanup.c: Likewise.
4159 * tree-diagnostic.c: Likewise.
4160 * tree-into-ssa.c: Likewise.
4161 * tree-outof-ssa.c: Likewise.
4162 * tree-parloops.c: Likewise.
4163 * tree-phinodes.c: Likewise.
4164 * tree-phinodes.h: Likewise.
4165 * tree-ssa-loop-ivopts.c: Likewise.
4166 * tree-ssa-loop-manip.c: Likewise.
4167 * tree-ssa-phiopt.c: Likewise.
4168 * tree-ssa-phiprop.c: Likewise.
4169 * tree-ssa-threadupdate.c: Likewise.
4170 * tree-ssa.c: Likewise.
4171 * tree-ssa.h: Likewise.
4172 * tree-vect-loop-manip.c: Likewise.
4173
4174 2018-11-13 Michael Ploujnikov <michael.ploujnikov@oracle.com>
4175
4176 * doc/extend.texi: Fix typo in the weakref description.
4177
4178 2018-11-13 Richard Biener <rguenther@suse.de>
4179
4180 PR tree-optimization/86991
4181 * tree-vect-loop.c (vect_is_slp_reduction): Delay reduction
4182 group building until we have successfully detected the SLP
4183 reduction.
4184 (vect_is_simple_reduction): Remove fixup code here.
4185
4186 2018-11-13 David Malcolm <dmalcolm@redhat.com>
4187
4188 * dumpfile.c (VERIFY_DUMP_ENABLED_P): New macro.
4189 (dump_gimple_stmt): Use it.
4190 (dump_gimple_stmt_loc): Likewise.
4191 (dump_gimple_expr): Likewise.
4192 (dump_gimple_expr_loc): Likewise.
4193 (dump_generic_expr): Likewise.
4194 (dump_generic_expr_loc): Likewise.
4195 (dump_printf): Likewise.
4196 (dump_printf_loc): Likewise.
4197 (dump_dec): Likewise.
4198 (dump_dec): Likewise.
4199 (dump_hex): Likewise.
4200 (dump_symtab_node): Likewise.
4201 * gimple-loop-interchange.cc (tree_loop_interchange::interchange):
4202 Guard dump call with dump_enabled_p.
4203 * graphite-isl-ast-to-gimple.c (graphite_regenerate_ast_isl): Likewise.
4204 * graphite-optimize-isl.c (optimize_isl): Likewise.
4205 * graphite.c (graphite_transform_loops): Likewise.
4206 * tree-loop-distribution.c (pass_loop_distribution::execute): Likewise.
4207 * tree-parloops.c (parallelize_loops): Likewise.
4208 * tree-ssa-loop-niter.c (number_of_iterations_exit): Likewise.
4209 * tree-vect-data-refs.c (vect_analyze_group_access_1): Likewise.
4210 (vect_prune_runtime_alias_test_list): Likewise.
4211 * tree-vect-loop.c (vect_update_vf_for_slp): Likewise.
4212 (vect_estimate_min_profitable_iters): Likewise.
4213 * tree-vect-slp.c (vect_record_max_nunits): Likewise.
4214 (vect_build_slp_tree_2): Likewise.
4215 (vect_supported_load_permutation_p): Likewise.
4216 (vect_slp_analyze_operations): Likewise.
4217 (vect_slp_analyze_bb_1): Likewise.
4218 (vect_slp_bb): Likewise.
4219 * tree-vect-stmts.c (vect_analyze_stmt): Likewise.
4220 * tree-vectorizer.c (try_vectorize_loop_1): Likewise.
4221 (pass_slp_vectorize::execute): Likewise.
4222 (increase_alignment): Likewise.
4223
4224 2018-11-13 David Malcolm <dmalcolm@redhat.com>
4225
4226 PR ipa/87955
4227 * ipa-inline.c (report_inline_failed_reason): Guard calls to
4228 cl_target_option_print_diff and cl_optimization_print_diff with
4229 if (dump_file).
4230
4231 2018-11-13 David Malcolm <dmalcolm@redhat.com>
4232
4233 * doc/invoke.texi (-fsave-optimization-record): Note that the
4234 output is compressed.
4235 * optinfo-emit-json.cc: Include <zlib.h>.
4236 (optrecord_json_writer::write): Compress the output.
4237
4238 2018-11-13 Aldy Hernandez <aldyh@redhat.com>
4239
4240 * tree-vrp.c (value_range_base::dump): Dump type.
4241 Do not use INF nomenclature for 1-bit types.
4242 (dump_value_range): Group all variants to common dumping code.
4243 (debug): New overloaded functions for value_ranges.
4244 (value_range_base::dump): Remove no argument version.
4245 (value_range::dump): Same.
4246
4247 2018-11-13 Richard Biener <rguenther@suse.de>
4248
4249 PR tree-optimization/87931
4250 * tree-vect-loop.c (vect_is_simple_reduction): Restrict
4251 nested cycles we support to latch computations vectorizable_reduction
4252 handles.
4253
4254 2018-11-13 Martin Liska <mliska@suse.cz>
4255
4256 PR tree-optimization/87885
4257 * cfghooks.c (account_profile_record): Rename
4258 to ...
4259 (profile_record_check_consistency): ... this.
4260 Calculate missing num_mismatched_freq_in.
4261 (profile_record_account_profile): New function
4262 that calculates time and size of a function.
4263 * cfghooks.h (struct profile_record): Remove
4264 all tuples.
4265 (struct cfg_hooks): Remove after_pass flag.
4266 (account_profile_record): Rename to ...
4267 (profile_record_check_consistency): ... this.
4268 (profile_record_account_profile): New.
4269 * cfgrtl.c (rtl_account_profile_record): Remove
4270 after_pass flag.
4271 * passes.c (check_profile_consistency): Do only
4272 checking.
4273 (account_profile): Calculate size and time of
4274 function only.
4275 (pass_manager::dump_profile_report): Reformat
4276 output.
4277 (execute_one_ipa_transform_pass): Call
4278 consistency check before clean upand call account_profile
4279 after a clean up is done.
4280 (execute_one_pass): Call check_profile_consistency and
4281 account_profile instead of using after_pass flag..
4282 * tree-cfg.c (gimple_account_profile_record): Likewise.
4283
4284 2018-11-13 Martin Liska <mliska@suse.cz>
4285
4286 PR sanitizer/87930
4287 * config/i386/i386.c (ix86_option_override_internal): Error
4288 about usage -mabi=ms and -fsanitize={,kernel-}address.
4289
4290 2018-11-13 Andre Vieira <andre.simoesdiasvieira@arm.com>
4291
4292 * config/aarch64/aarch64.c
4293 (aarch64_vectorize_preferred_vector_alignment): Change return type to
4294 poly_uint64.
4295 (aarch64_simd_vector_alignment_reachable): Adapt to preferred vector
4296 alignment being a poly int.
4297 * doc/tm.texi (TARGET_VECTORIZE_PREFERRED_VECTOR_ALIGNMENT): Change
4298 return type to poly_uint64.
4299 * target.def (default_preferred_vector_alignment): Likewise.
4300 * targhooks.c (default_preferred_vector_alignment): Likewise.
4301 * targhooks.h (default_preferred_vector_alignment): Likewise.
4302 * tree-vect-data-refs.c (vect_calculate_target_alignment): Likewise.
4303 (vect_compute_data_ref_alignment): Adapt to vector alignment being a
4304 poly int.
4305 (vect_update_misalignment_for_peel): Likewise.
4306 (vect_enhance_data_refs_alignment): Likewise.
4307 (vect_find_same_alignment_drs): Likewise.
4308 (vect_duplicate_ssa_name_ptr_info): Likewise.
4309 (vect_setup_realignment): Likewise.
4310 (vect_can_force_dr_alignment_p): Change alignment parameter type to
4311 poly_uint64.
4312 * tree-vect-loop-manip.c (get_misalign_in_elems): Learn to construct a
4313 mask with a compile time variable vector alignment.
4314 (vect_gen_prolog_loop_niters): Adapt to vector alignment being a poly
4315 int.
4316 (vect_do_peeling): Exit early if vector alignment is not constant.
4317 * tree-vect-stmts.c (ensure_base_align): Adapt to vector alignment being
4318 a poly int.
4319 (vectorizable_store): Likewise.
4320 (vectorizable_load): Likweise.
4321 * tree-vectorizer.h (struct dr_vec_info): Make target_alignment field a
4322 poly_uint64.
4323 (vect_known_alignment_in_bytes): Adapt to vector alignment being a
4324 poly int.
4325 (vect_can_force_dr_alignment_p): Change alignment parameter type to
4326 poly_uint64.
4327
4328 2018-11-13 Richard Biener <rguenther@suse.de>
4329
4330 PR tree-optimization/87962
4331 * tree-vect-loop.c (vect_is_simple_reduction): More reliably
4332 detect outer reduction for disqualifying in-loop uses.
4333
4334 2018-11-13 Richard Biener <rguenther@suse.de>
4335
4336 PR tree-optimization/87967
4337 * tree-vect-loop.c (vect_transform_loop): Also copy PHIs
4338 for constants for the scalar loop.
4339
4340 2018-11-13 Alan Modra <amodra@gmail.com>
4341
4342 * config/rs6000/linux64.h (ASM_OUTPUT_SPECIAL_POOL_ENTRY_P): Exclude
4343 integer constants when -mcmodel=medium.
4344
4345 2018-11-13 Claudiu Zissulescu <claziss@synopsys.com>
4346
4347 * config/arc/arc.h (FUNCTION_PROFILER): Redefine to empty.
4348 * config/arc/elf.h (PROFILE_HOOK): Define.
4349 * config/arc/linux.h (PROFILE_HOOK): Likewise.
4350
4351 2018-11-13 Claudiu Zissulescu <claziss@synopsys.com>
4352
4353 * config/arc/arc.c (hwloop_optimize): Bailout when detecting a
4354 jump table data in the text section.
4355
4356 2018-11-13 Claudiu Zissulescu <claziss@synopsys.com>
4357
4358 * config/arc/arc.c (arc_eh_return_address_location): Repurpose it
4359 to fit the eh_return pattern.
4360 * config/arc/arc.md (eh_return): Define.
4361 (VUNSPEC_ARC_EH_RETURN): Likewise.
4362 * config/arc/arc-protos.h (arc_eh_return_address_location): Match
4363 new implementation.
4364 * config/arc/arc.h (EH_RETURN_HANDLER_RTX): Remove it.
4365
4366
4367 2018-11-13 Claudiu Zissulescu <claziss@synopsys.com>
4368
4369 * common/config/arc/arc-common.c (arc_option_optimization_table):
4370 Millicode optimization is default on for size optimizations.
4371 * config/arc/arc-protos.h (arc_check_multi): New function.
4372 * config/arc/arc.c (RTX_OK_FOR_OFFSET_P): Rearange.
4373 (ENTER_LEAVE_START_REG): Define.
4374 (ENTER_LEAVE_END_REG): Likewise.
4375 (arc_override_options): Disable millicode when long calls option
4376 is on.
4377 (arc_frame_info): Change it from int to bool.
4378 (arc_compute_frame_size): Clean up.
4379 (arc_save_restore): Remove.
4380 (frame_save_reg): New function.
4381 (frame_restore_reg): Likewise.
4382 (arc_enter_leave_p): Likewise.
4383 (arc_save_callee_saves): Likewise.
4384 (arc_restore_callee_saves): Likewise.
4385 (arc_save_callee_enter): Likewise.
4386 (arc_restore_callee_leave): Likewise.
4387 (arc_save_callee_milli): Likewise.
4388 (arc_restore_callee_milli): Likewise.
4389 (arc_expand_prologue): Reimplement to emit enter/leave
4390 instructions.
4391 (arc_expand_epilogue): Likewise.
4392 (arc_check_multi): New function.
4393 * config/arc/arc.md (push_multi_fp): New pattern.
4394 (push_multi_fp_blink): Likewise.
4395 (pop_multi_fp): Likewise.
4396 (pop_multi_fp_blink): Likewise.
4397 (pop_multi_fp_ret): Likewise.
4398 (pop_multi_fp_blink_ret): Likewise.
4399 * config/arc/arc.opt (mmillicode): Update option.
4400 (mcode-density-frame): New option.
4401 * config/arc/predicates.md (push_multi_operand): New predicate.
4402 (pop_multi_operand): Likewise.
4403 * doc/invoke.texi (ARC): Update ARC options information.
4404
4405
4406 2018-11-13 Claudiu Zissulescu <claziss@synopsys.com>
4407
4408 * config/arc/arc-protos.h (gen_operands_ldd_std): Add.
4409 * config/arc/arc.c (operands_ok_ldd_std): New function.
4410 (mem_ok_for_ldd_std): Likewise.
4411 (gen_operands_ldd_std): Likewise.
4412 * config/arc/arc.md: Add peephole2 rules for std/ldd.
4413
4414 2018-11-13 Eric Botcazou <ebotcazou@adacore.com>
4415
4416 * toplev.c (output_stack_usage): Turn test on flag_stack_usage into
4417 test on stack_usage_file.
4418 (lang_dependent_init): Do not open the .su file if generating LTO.
4419
4420 2018-11-13 Jakub Jelinek <jakub@redhat.com>
4421
4422 PR rtl-optimization/87918
4423 * simplify-rtx.c (simplify_merge_mask): For COMPARISON_P, use
4424 simplify_gen_relational rather than simplify_gen_binary.
4425
4426 2018-11-13 Richard Biener <rguenther@suse.de>
4427
4428 * tree-ssanames.h (set_range_info): Use value_range_base.
4429 (get_range_info): Likewise.
4430 * tree-ssanames.c (set_range_info): Likewise.
4431 (get_range_info): Likewise.
4432 * tree-vrp.c (value_range_base::union_helper): Split
4433 out common parts of value_range[_base]::union_.
4434 (value_range_base::union_): Update.
4435 (value_range::union_): Likewise.
4436 (determine_value_range_1): Use value_range_base.
4437 (determine_value_range): Likewise.
4438 * tree-vrp.h (value_range_base::union_helper): Move ...
4439 (value_range::union_helper): ... from here.
4440
4441 2018-11-13 Alan Modra <amodra@gmail.com>
4442
4443 * config/rs6000/rs6000.c (rs6000_secondary_reload_inner): Negate
4444 offset for PRE_DEC.
4445 (rs6000_secondary_reload_gpr): Don't call find_replacement.
4446
4447 2018-11-13 Sandra Loosemore <sandra@codesourcery.com>
4448
4449 PR middle-end/59634
4450 * doc/invoke.texi (Optimize Options): Clarify that the
4451 l1-cache-line-size, l1-cache-size, and l2-cache-size parameters
4452 apply to data cache size.
4453
4454 2018-11-13 Alan Modra <amodra@gmail.com>
4455
4456 * config/rs6000/predicates.md (logical_const_operand),
4457 (logical_operand): Correct comment.
4458 * config/rs6000/rs6000.c (rs6000_emit_prologue): Comment fix.
4459
4460 2018-11-13 Alan Modra <amodra@gmail.com>
4461
4462 * config/rs6000/rs6000.md (addsi3_high): Prefix with '*'.
4463
4464 2018-11-13 Alan Modra <amodra@gmail.com>
4465
4466 * gcc/doc/md.texi (Machine Constraints): Correct rs6000 h constraint
4467 description.
4468 * config/rs6000/rs6000.md (movsi_internal1): Delete MT%0 case
4469 covered by alternative.
4470 (movcc_internal1): Ignore h for register preference.
4471 (mov<mode>_hardfloat64): Likewise.
4472 (mov<mode>_softfloat): Ignore c, l, h for register preference.
4473
4474 2018-11-12 Sandra Loosemore <sandra@codesourcery.com>
4475
4476 PR preprocessor/47823
4477 * doc/cpp.texi (Alternatives to Wrapper #ifndef): Move #pragma once
4478 documentation to...
4479 (Pragmas): ...here.
4480 * doc/extend.texi (Pragmas): Note additional pragmas documented
4481 in the CPP manual.
4482
4483 2018-11-13 Kugan Vivekanandarajah <kuganv@linaro.org>
4484
4485 PR middle-end/86677
4486 PR middle-end/87528
4487 * tree-scalar-evolution.c (expression_expensive_p): Make
4488 BUILTIN POPCOUNT as expensive when backend does not define it.
4489
4490 2018-11-12 Fredrik Noring <noring@nocrew.org>
4491
4492 * config.gcc: Update with-llsc defaults for MIPS r5900.
4493
4494 2018-11-12 Martin Liska <mliska@suse.cz>
4495
4496 PR gcov-profile/87442
4497 * common.opt: Add -fprofile-filter-files and -fprofile-exclude-files
4498 options.
4499 * doc/invoke.texi: Document them.
4500 * tree-profile.c (parse_profile_filter): New.
4501 (parse_profile_file_filtering): Likewise.
4502 (release_profile_file_filtering): Likewise.
4503 (include_source_file_for_profile): Likewise.
4504 (tree_profiling): Filter source files based on the
4505 newly added options.
4506
4507 2018-11-12 Martin Liska <mliska@suse.cz>
4508
4509 PR target/87903
4510 * doc/extend.texi: Add missing values for __builtin_cpu_is and
4511 __builtin_cpu_supports for x86 target.
4512
4513 2018-11-12 Sandra Loosemore <sandra@codesourcery.com>
4514
4515 PR middle-end/21110
4516 * doc/rtl.texi (Constants): Clarify that mode of "high" doesn't
4517 have to be Pmode.
4518 (Arithmetic): Likewise for "lo_sum".
4519
4520 2018-11-12 Renlin Li <renlin.li@arm.com>
4521
4522 PR target/87815
4523 * dse.c (get_stored_val): Add check for compile-time constantness
4524 of gap.
4525
4526 2018-11-12 Sudakshina Das <sudi.das@arm.com>
4527
4528 * config/arm/arm-cpus.in (armv8_5, sb, predres): New features.
4529 (ARMv8_5a): New fgroup.
4530 (armv8.5-a): New arch.
4531 (armv8-a, armv8.1-a, armv8.2-a, armv8.3-a, armv8.4-a): New options
4532 sb and predres.
4533 * config/arm/arm-tables.opt: Regenerate.
4534 * config/arm/t-aprofile: Add matching rules for -march=armv8.5-a
4535 * config/arm/t-arm-elf (all_v8_archs): Add armv8.5-a.
4536 * config/arm/t-multilib (v8_5_a_simd_variants): New variable.
4537 Add matching rules for -march=armv8.5-a and extensions.
4538 * doc/invoke.texi (ARM options): Document -march=armv8.5-a.
4539 Add sb and predres to all armv8-a except armv8.5-a.
4540
4541 2018-11-12 Richard Biener <rguenther@suse.de>
4542
4543 * tree-vrp.h (value_range[_base]::set): Make public. Provide
4544 overload for single value.
4545 (value_range[_base]::set_nonnull): New.
4546 (value_range[_base]::set_null): Likewise.
4547 (value_range): Document bitmap copying behavior, mark
4548 copy constructor and assignment operator deleted.
4549 (value_range::move): New.
4550 (value_range::set_and_canonicalize): Default bitmap to zero.
4551 (set_value_range_to_nonnull): Remove.
4552 (set_value_range_to_null): Likewise.
4553 (set_value_range): Likewise.
4554 (set_value_range_to_value): Likewise.
4555 (extract_range_from_unary_expr): Work on value_range_base.
4556 (extract_range_from_binary_expr_1): Likewise. Rename to...
4557 (extract_range_from_binary_expr): ... this.
4558 * tree-vrp.c (value_range::update): Clear equiv bitmap
4559 if required.
4560 (value_range::move): New, move equiv bitmap.
4561 (value_range_base::set_undefined): Avoid assignment.
4562 (value_range::set_undefined): Likewise.
4563 (value_range_base::set_varying): Likewise.
4564 (value_range::set_varying): Likewise.
4565 (set_value_range): Remove.
4566 (value_range_base::set): New overload for value.
4567 (value_range::set): Likewise.
4568 (set_value_range_to_nonnull): Remove.
4569 (value_range_base::set_nonnull): New.
4570 (value_range::set_nonnull): Likewise.
4571 (set_value_range_to_null): Remove.
4572 (value_range_base::set_null): New.
4573 (value_range::set_null): Likewise.
4574 (range_is_null): Work on value_range_base.
4575 (range_is_nonnull): Likewise.
4576 (ranges_from_anti_range): Likewise.
4577 (extract_range_into_wide_ints): Likewise.
4578 (extract_range_from_multiplicative_op): Likewise.
4579 (extract_range_from_binary_expr): Likewise. Update for API changes.
4580 (extract_range_from_unary_expr): Likewise. Remove OBJ_TYPE_REF
4581 handling.
4582 (value_range::intersect_helper): Avoid copy and assignment.
4583 (value_range::union_helper): Likewise.
4584 (determine_value_range_1): Adjust.
4585 * gimple-ssa-evrp-analyze.c (evrp_range_analyzer::try_find_new_range):
4586 Avoid assignment by using move.
4587 (evrp_range_analyzer::record_ranges_from_stmt): Avoid assignment.
4588 * tree-ssa-threadedge.c (record_temporary_equivalences_from_phis):
4589 Likewise.
4590 * tree-ssanames.c (get_range_info): Likewise.
4591 * vr-values.h (vr_values::get_vr_for_comparison): Adjust API.
4592 * vr-values.c (vr_values::get_value_range): Adjust.
4593 (vr_values::update_value_range): Likewise.
4594 (symbolic_range_based_on_p): Work on value_range_base.
4595 (vr_values::extract_range_from_binary_expr): Use value_range_base.
4596 (vr_values::extract_range_from_unary_expr): Likewise.
4597 (vr_values::extract_range_from_cond_expr): Avoid assignment.
4598 (vr_values::extract_range_from_comparison): Adjust.
4599 (vr_values::check_for_binary_op_overflow): Use value_range_base.
4600 (vr_values::extract_range_basic): Adjust.
4601 (vr_values::adjust_range_with_scev): Likewise.
4602 (vr_values::vrp_visit_assignment_or_call): Likewise.
4603 (vr_values::get_vr_for_comparison): Change API to avoid
4604 assignment and copy construction.
4605 (vr_values::compare_name_with_value): Adjust accordingly.
4606 (vr_values::compare_names): Likewise.
4607 (vr_values::extract_range_from_phi_node): Avoid assignment and
4608 bogus in-place modify of equiv bitmap.
4609 (vr_values::simplify_bit_ops_using_ranges): Use value_range_base.
4610 * ipa-prop.c (ipa_compute_jump_functions_for_edge): Adjust
4611 for extract_range_from_unary_expr API change.
4612 * ipa-cp.c (ipa_vr_operation_and_type_effects): Likewise.
4613
4614 2018-11-12 Eric Botcazou <ebotcazou@adacore.com>
4615
4616 * config/mcore/mcore.h (WORD_REGISTER_OPERATIONS): Remove duplicate.
4617
4618 2018-11-12 Richard Biener <rguenther@suse.de>
4619
4620 * tree-vrp.h (value_range_base::symbolic_p,
4621 value_range_base::constant_p, value_range_base::zero_p,
4622 value_range_base::singleton_p): Move from value_range.
4623 (value_range::dump): Add.
4624 * gimple-ssa-evrp-analyze.c
4625 (evrp_range_analyzer::record_ranges_from_phis): Use set_varying.
4626 * ipa-cp.c (ipcp_vr_lattice::print): Use dump_value_range.
4627 * tree-ssa-threadedge.c (record_temporary_equivalences_from_phis):
4628 Use set_varying.
4629 * tree-vrp.c (value_range::symbolic_p): Move to value_range_base.
4630 (value_range::constant_p): Likewise.
4631 (value_range::singleton_p): Likewise.
4632 (value_range_base::dump): Add.
4633 (set_value_range_to_undefined): Remove.
4634 (set_value_range_to_varying): Likewise.
4635 (range_int_cst_p): Take value_range_base argument.
4636 (range_int_cst_singleton_p): Likewise.
4637 (value_range_constant_singleton): Likewise.
4638 (vrp_set_zero_nonzero_bits): Likewise.
4639 (extract_range_from_multiplicative_op): Use set_varying.
4640 (extract_range_from_binary_expr_1): Likewise. Use set_undefined.
4641 (extract_range_from_unary_expr): Likewise.
4642 (dump_value_range_base): Change to overload of dump_value_range.
4643 (vrp_prop::vrp_initialize): Use set_varying and set_undefined.
4644 (vrp_prop::visit_stmt): Likewise.
4645 (value_range::intersect_helper): Likewise.
4646 (value_range::union_helper): Likewise.
4647 (determine_value_range_1): Likewise.
4648
4649 2018-11-12 Richard Biener <rguenther@suse.de>
4650
4651 * tree-vrp.c (set_value_range_to_nonnull): Clear equiv.
4652 (set_value_range_to_null): Likewise.
4653 * vr-values.c (vr_values::extract_range_from_comparison):
4654 Clear equiv for constant singleton ranges.
4655
4656 2018-11-12 Wei Xiao <wei3.xiao@intel.com>
4657
4658 * config/i386/sse.md: Combine VFIXUPIMM* patterns
4659 (<avx512>_fixupimm<mode>_maskz<round_saeonly_expand_name>): Update.
4660 (<avx512>_fixupimm<mode><sd_maskz_name><round_saeonly_name>): Update.
4661 (<avx512>_fixupimm<mode>_mask<round_saeonly_name>): Remove.
4662 (avx512f_sfixupimm<mode>_maskz<round_saeonly_expand_name>): Update.
4663 (avx512f_sfixupimm<mode><sd_maskz_name><round_saeonly_name>): Update.
4664 (avx512f_sfixupimm<mode>_mask<round_saeonly_name>): Remove.
4665
4666 2018-11-11 Sandra Loosemore <sandra@codesourcery.com>
4667
4668 PR c/69502
4669 * doc/extend.texi (Common Type Attributes): For the align type
4670 attribute, copy language about decreasing alignment from the
4671 corresponding variable attribute.
4672
4673 2018-11-11 Xianmiao Qu <xianmiao_qu@c-sky.com>
4674
4675 * config/csky/csky.md (*fpuv2_nmulsf3_1, *fpuv2_nmuldf3_1): Handle
4676 -frounding-math.
4677
4678 2018-11-11 Sandra Loosemore <sandra@codesourcery.com>
4679
4680 PR c++/43105
4681 * doc/invoke.texi (C++ Dialect Options): Add warning about mixing
4682 -frtti and -fno-rtti code.
4683
4684 2018-11-11 Sandra Loosemore <sandra@codesourcery.com>
4685
4686 PR c/26366
4687 * doc/extend.texi (Other Builtins): Document probability associated
4688 with __builtin_expect.
4689
4690 2018-11-11 Uros Bizjak <ubizjak@gmail.com>
4691
4692 PR target/87928
4693 * config/i386/i386.h (STACK_BOUNDARY): Use TARGET_64BIT_MS_ABI
4694 instead of (TARGET_64BIT && ix86_abi == MS_ABI).
4695 * config/i386/darwin.h (STACK_BOUNDARY): Ditto.
4696 * config/i386/cygming.h (STACK_BOUNDARY): Remove.
4697
4698 2018-11-11 Xianmiao Qu <xianmiao_qu@c-sky.com>
4699
4700 * config/csky/csky-linux-elf.h (CC1_SPEC): Support -profile.
4701
4702 2018-11-11 Xianmiao Qu <xianmiao_qu@c-sky.com>
4703
4704 * config/csky/csky.h (ASM_PREFERRED_EH_DATA_FORMAT): Define.
4705
4706 2018-11-11 Richard Biener <rguenther@suse.de>
4707
4708 * tree-vrp.h (class value_range_base): New base class for
4709 value_range containing all but the m_equiv member.
4710 (dump_value_range_base): Add.
4711 (range_includes_zero_p): Work on value_range_base.
4712 * tree-vrp.c (value_range_base::set): Split out base handling
4713 from...
4714 (value_range::set): this.
4715 (value_range::set_equiv): New.
4716 (value_range_base::value_range_base): New constructors.
4717 (value_range_base::check): Split out base handling from...
4718 (value_range::check): this.
4719 (value_range::equal_p): Refactor in terms of
4720 ignore_equivs_equal_p which is now member of the base.
4721 (value_range_base::set_undefined): New.
4722 (value_range_base::set_varying): Likewise.
4723 (value_range_base::dump):Split out base handling from...
4724 (value_range::dump): this.
4725 (value_range_base::set_and_canonicalize): Split out base handling
4726 from...
4727 (value_range::set_and_canonicalize): this.
4728 (value_range_base::union_): New.
4729 * ipa-prop.h (struct ipa_jump_func): Use value_range_base *
4730 for m_vr.
4731 * ipa-cp.c (class ipcp_vr_lattice): Use value_range_base
4732 instead of value_range everywhere.
4733 (ipcp_vr_lattice::print): Use dump_value_range_base.
4734 (ipcp_vr_lattice::meet_with): Adjust.
4735 (ipcp_vr_lattice::meet_with_1): Likewise.
4736 (ipa_vr_operation_and_type_effects): Likewise.
4737 (propagate_vr_across_jump_function): Likewise.
4738 * ipa-prop.c (struct ipa_vr_ggc_hash_traits): Likewise.
4739 (ipa_get_value_range): Likewise.
4740 (ipa_set_jfunc_vr): Likewise.
4741 (ipa_compute_jump_functions_for_edge): Likewise.
4742
4743 2018-11-10 Sandra Loosemore <sandra@codesourcery.com>
4744
4745 PR middle-end/65703
4746 * doc/invoke.texi (Optimize Options): Add @opindex entries
4747 for the positive forms of -fno-xxx and -mno-xxx options
4748 that were lacking them.
4749
4750 2018-11-10 Segher Boessenkool <segher@kernel.crashing.org>
4751
4752 * combine.c (make_more_copies): Only make an intermediate copy if the
4753 dest of a move is a pseudo.
4754
4755 2018-11-09 Maya Rashish <coypu@sdf.org>
4756
4757 PR target/87221
4758 * config/netbsd-elf.h (NETBSD_STARTFILE_SPEC): Use crtbeginS.o for PIE.
4759 (NETBSD_ENDFILE_SPEC): Use crtendS.o for PIE.
4760
4761 2018-11-09 Sandra Loosemore <sandra@codesourcery.com>
4762
4763 PR driver/41179
4764 PR middle-end/65703
4765 * doc/invoke.texi (Optimize Options): Clarify default behavior
4766 for -fno-toplevel-reorder, -fno-defer-pop, and -fno-branch-count-reg.
4767
4768 2018-11-09 Bernd Edlinger <bernd.edlinger@hotmail.de>
4769
4770 PR tree-optimization/87940
4771 * expr.c (string_constant): Don't strip NOPS in subexpressions.
4772 Fold PLUS_EXPR correctly.
4773
4774 2018-11-09 Ilya Leoshkevich <iii@linux.ibm.com>
4775
4776 PR target/87762
4777 * config/s390/s390.c (s390_safe_relative_long_p): New function.
4778 (annotate_constant_pool_refs): Skip insns which support
4779 relative addressing.
4780 (annotate_constant_pool_refs_1): New helper function.
4781 (find_constant_pool_ref): Skip insns which support relative
4782 addression.
4783 (find_constant_pool_ref_1): New helper function.
4784 (replace_constant_pool_ref): Skip insns which support
4785 relative addressing.
4786 (replace_constant_pool_ref_1): New helper function.
4787 (s390_mainpool_start): Adapt to the new signature.
4788 (s390_mainpool_finish): Likewise.
4789 (s390_chunkify_start): Likewise.
4790 (s390_chunkify_finish): Likewise.
4791 (pass_s390_early_mach::execute): Likewise.
4792 (s390_prologue_plus_offset): Likewise.
4793 (s390_emit_prologue): Likewise.
4794 (s390_emit_epilogue): Likewise.
4795
4796 2018-11-09 Jakub Jelinek <jakub@redhat.com>
4797
4798 * gimplify.c (gimplify_scan_omp_clauses): Call sorry_at for valid
4799 but unsupported lastprivate with conditional modifier.
4800
4801 2018-11-09 Jeff Law <law@redhat.com>
4802
4803 * config/mips/mips.c (mips_loongson_ext2_prefetch_cookie): Handle
4804 unused argument better. Add gcc_unreachable to silence warning.
4805
4806 2018-11-09 Martin Sebor <msebor@redhat.com>
4807
4808 PR middle-end/81824
4809 * attribs.c (has_attribute): New helper function.
4810 (decls_mismatched_attributes, maybe_diag_alias_attributes): Same.
4811 * attribs.h (decls_mismatched_attributes): Declare.
4812 * cgraphunit.c (handle_alias_pairs): Call maybe_diag_alias_attributes.
4813 (maybe_diag_incompatible_alias): Use OPT_Wattribute_alias_.
4814 * common.opt (-Wattribute-alias): Take an argument.
4815 (-Wno-attribute-alias): New option.
4816 * doc/extend.texi (Common Function Attributes): Document copy.
4817 (Common Variable Attributes): Same.
4818 * doc/invoke.texi (-Wmissing-attributes): Document enhancement.
4819 (-Wattribute-alias): Document new option argument.
4820
4821 2018-11-09 Richard Earnshaw <rearnsha@arm.com>
4822
4823 * config/arm/parsecpu.awk (/alias/): Tighten invisible alias
4824 matching criteria. Remove unused array initializer.
4825
4826 2018-11-09 Bill Schmidt <wschmidt@linux.ibm.com>
4827 Jinsong Ji <jji@us.ibm.com>
4828
4829 * config/rs6000/xmmintrin.h (_mm_cvtss_si32): Fix incorrect
4830 constraints by introducing a new temporary.
4831 (_mm_cvtss_si64): Likewise.
4832
4833 2018-11-09 Martin Liska <mliska@suse.cz>
4834
4835 * common.opt: Add -fipa-stack-alignment flag.
4836 * doc/invoke.texi: Document it.
4837 * final.c (rest_of_clean_state): Guard stack
4838 shrinking with flag.
4839
4840 2018-11-09 Martin Liska <mliska@suse.cz>
4841
4842 * cgraph.h (ipa_discover_readonly_nonaddressable_vars): Rename
4843 to ...
4844 (ipa_discover_variable_flags): ... this.
4845 * common.opt: Come up with new flag -fipa-reference-addressable.
4846 * doc/invoke.texi: Document it.
4847 * ipa-reference.c (propagate): Call the renamed fn.
4848 * ipa-visibility.c (whole_program_function_and_variable_visibility):
4849 Likewise.
4850 * ipa.c (ipa_discover_readonly_nonaddressable_vars): Renamed to
4851 ...
4852 (ipa_discover_variable_flags): ... this. Discover
4853 non-addressable variables only with the newly added flag.
4854 * opts.c: Enable the newly added flag with -O1 and higher
4855 optimization level.
4856
4857 2018-11-09 David Malcolm <dmalcolm@redhat.com>
4858
4859 * json.cc (selftest::test_writing_literals): Fix comment.
4860
4861 2018-11-09 Martin Liska <mliska@suse.cz>
4862
4863 * config/aarch64/aarch64.c (aarch64_parse_arch): Do not copy
4864 string to a stack buffer.
4865 (aarch64_parse_cpu): Likewise.
4866 (aarch64_parse_tune): Likewise.
4867
4868 2018-11-09 Richard Biener <rguenther@suse.de>
4869
4870 PR tree-optimization/87953
4871 * tree-vect-loop.c (vectorizable_reduction): For analysis
4872 always pass ops[0] to vectorizable_condition.
4873
4874 2018-11-09 Stafford Horne <shorne@gmail.com>
4875 Richard Henderson <rth@twiddle.net>
4876 Joel Sherrill <joel@rtems.org>
4877
4878 * common/config/or1k/or1k-common.c: New file.
4879 * config/or1k/*: New.
4880 * config.gcc (or1k*-*-*): New.
4881 * configure.ac (or1k*-*-*): New test for openrisc tls.
4882 * configure: Regenerated.
4883 * doc/install.texi: Document OpenRISC triplets.
4884 * doc/invoke.texi: Document OpenRISC arguments.
4885 * doc/md.texi: Document OpenRISC.
4886
4887 2018-11-09 Richard Earnshaw <rearnsha@arm.com>
4888
4889 * config/arm/arm-cpus.in (arm7tdmi): Add an alias for arm7tdmi-s.
4890 (arm7tdmi-s): Delete CPU.
4891 (arm710t): Add aliases for arm720t and arm740t.
4892 (arm720t, arm740t): Delete CPUs.
4893 (arm920t): Add aliases for arm920, arm922t and arm940t.
4894 (arm920, arm922t, arm940t): Delete CPUs.
4895 (arm10tdmi): Add alias for arm1020t.
4896 (arm1020t): Delete CPU.
4897 (arm9e): Add aliases for arm946e-s, arm966e-s and arm968e-s.
4898 (arm946e-s, arm966e-s, arm968e-s): Delete CPUs.
4899 (arm10e): Add aliases for arm1020e and arm1022e.
4900 (arm1020e, arm1022e): Delete CPU.
4901 * config/arm/arm.md (generic_sched): Remove entries that are now
4902 handled by aliases.
4903 (generic_vfp): Likewise.
4904 * config/arm/arm1020e.md: Simplify tuning selection based on alias
4905 changes.
4906 * config/arm/arm-tune.md: Regenerated.
4907 * config/arm/arm-tables.opt: Regenerated.
4908
4909 2018-11-09 Richard Biener <rguenther@suse.de>
4910
4911 PR tree-optimization/87621
4912 * tree-vect-loop.c (vectorizable_reduction): Handle reduction
4913 op with only phi inputs.
4914 * tree-ssa-loop-ch.c: Include tree-ssa-sccvn.h.
4915 (ch_base::copy_headers): Run CSE on copied loop headers.
4916 (pass_ch_vect::process_loop_p): Simplify.
4917
4918 2018-11-09 Alexandre Oliva <oliva@adacore.com>
4919
4920 * config/i386/mingw32.h (LINK_SPEC_LARGE_ADDR_AWARE): Adjust
4921 for non-w64 x86_64 biarch.
4922
4923 2018-11-09 Alexandre Oliva <aoliva@redhat.com>
4924
4925 PR rtl-optimization/86438
4926 * compare-elim.c (try_eliminate_compare): Use SET_SRC instead
4927 of in_b for the compare if in_b is SET_DEST.
4928
4929 PR target/87793
4930 * config/i386/i386.c (ix86_const_not_ok_for_debug_p): Reject
4931 non-toplevel UNSPEC.
4932
4933 2018-11-08 Aldy Hernandez <aldyh@redhat.com>
4934
4935 * tree-vrp.c (value_range::check): Do not access internals
4936 directly.
4937 (value_range::singleton_p): Same.
4938 (value_range::type): Same.
4939 (vrp_finalize): Use value_range API.
4940
4941 2018-11-08 Aldy Hernandez <aldyh@redhat.com>
4942
4943 * tree-vrp.c (may_contain_p): Do not access m_min/m_max directly.
4944
4945 2018-11-08 Aldy Hernandez <aldyh@redhat.com>
4946
4947 * vr-values.c (vr_values::get_value_range): Use value_range API
4948 instead of piecing together ranges.
4949 (vr_values::update_value_range): Same.
4950
4951 2018-11-08 Aldy Hernandez <aldyh@redhat.com>
4952
4953 * gimple-fold.c (size_must_be_zero_p): Use value_range API instead
4954 of performing ad-hoc calculations.
4955 * tree-ssanames.c (set_range_info): New overloaded function
4956 accepting value_range &.
4957 (get_range_info): Same.
4958 * tree-ssanames.h (set_range_info_raw): Remove.
4959 (set_range_info): New prototype.
4960 (get_range_info): Same.
4961 * tree-vrp.h (value_range::null_p): Rename to zero_p.
4962 * tree-vrp.c (value_range::null_p): Same.
4963
4964 2018-11-09 Jan Hubicka <jh@suse.cz>
4965
4966 * tree.c (fld_type_variant_equal_p): Test user align flag.
4967 (flt_type_variant): Copy user align flag.
4968 (fld_incomplete_type_of): Clear it.
4969
4970 2018-11-09 Prathamesh Kulkarni <prathamesh.kulkarni@linaro.org>
4971
4972 * config/arm/neon.md (div<mode>3): New pattern.
4973
4974 2018-11-08 Andi Kleen <ak@linux.intel.com>
4975
4976 * common/config/i386/i386-common.c (OPTION_MASK_ISA_PTWRITE_SET): New.
4977 (OPTION_MASK_ISA_PTWRITE_UNSET): New.
4978 (ix86_handle_option): Handle OPT_mptwrite.
4979 * config/i386/cpuid.h (bit_PTWRITE): Add.
4980 * config/i386/driver-i386.c (host_detect_local_cpu): Detect ptwrite.
4981 * config/i386/i386-builtin.def (BDESC): Add ptwrite32/64.
4982 * config/i386/i386-c.c (ix86_target_macros_internal): Define __PTWRITE__.
4983 * config/i386/i386.c (ix86_target_string): Handle ptwrite.
4984 (ix86_option_override_internal): Handle PTA_PTWRITE.
4985 (ix86_valid_target_attribute_inner_p): Define ptwrite.
4986 (def_builtin2): Force UINT64 to be 64bit only.
4987 * config/i386/i386.h (TARGET_PTWRITE): Add.
4988 (TARGET_PTWRITE_P): Add.
4989 (PTA_PTWRITE): Add.
4990 * config/i386/i386.md: Define ptwrite.
4991 * config/i386/i386.opt: Add -mptwrite.
4992 * config/i386/immintrin.h (_ptwrite64): Add.
4993 (_ptwrite32): Add
4994 * doc/extend.texi: Document __builtin_ia32_ptwrite*.
4995 * doc/invoke.texi: Document -mptwrite.
4996
4997 2018-11-08 Peter Bergner <bergner@linux.ibm.com>
4998
4999 PR rtl-optimization/87600
5000 * cfgexpand.c (expand_asm_stmt): Catch illegal asm constraint usage.
5001 * lra-constraints.c (process_alt_operands): Skip illegal hard
5002 register usage. Prefer reloading non hard register operands.
5003
5004 2018-11-08 Sandra Loosemore <sandra@codesourcery.com>
5005
5006 PR other/36572
5007 * doc/invoke.texi (Optimize Options): Clarify default behavior
5008 for -fno-sched-interblock and -fno-sched-spec.
5009
5010 2018-11-08 Roman Geissler <roman.geissler@amadeus.com>
5011
5012 * collect2.c (linker_select): Add USE_LLD_LD.
5013 (ld_suffixes): Add ld.lld.
5014 (main): Handle -fuse-ld=lld.
5015 * common.opt (-fuse-ld=lld): New option.
5016 * doc/invoke.texi (-fuse-ld=lld): Document.
5017 * opts.c (common_handle_option): Handle OPT_fuse_ld_lld.
5018
5019 2018-11-08 Paul Koning <ni1d@arrl.net>
5020
5021 * config/pdp11/constraints.md: Add "Z" series constraints for use
5022 with pre-dec and post-inc addressing.
5023 * config/pdp11/pdp11-protos.m (expand_block_move): Delete.
5024 (pdp11_expand_operands): Add int argument (word count).
5025 (pdp11_sp_frame_offset): Delete.
5026 (pdp11_cmp_length): New function.
5027 (pushpop_regeq): New function.
5028 * config/pdp11/pdp11.c (TARGET_STACK_PROTECT_RUNTIME_ENABLED_P):
5029 Add hook.
5030 (pdp11_expand_prologue, pdp11_expand_epilogue): Rewrite for new
5031 frame layout.
5032 (pdp11_initial_elimination_offset): Ditto.
5033 (pdp11_expand_operands): Add word count argument. Bugfixes.
5034 (output_move_multiple): Change how pointer adjustment is done.
5035 (pdp11_gen_int_label): Correct format.
5036 (output_ascii): Ditto.
5037 (pdp11_asm_output_var): Add code for DEC assembler case.
5038 (pdp11_asm_print_operand): Bugfix for CONST_DOUBLE holding integer
5039 value.
5040 (legitimate_const_double_p): Ditto.
5041 (pdp11_register_move_cost): Adjust for new register classes.
5042 (pdp11_regno_reg_class): Ditto.
5043 (expand_block_move): Delete.
5044 (pushpop_regeq): New function.
5045 (pdp11_legitimate_address_p): Bugfix in check for constant
5046 offset.
5047 (pdp11_sp_frame_offset): Delete.
5048 (pdp11_reg_save_size): New helper function for new frame layout.
5049 (output_addr_const_pdp11): Remove CONST_DOUBLE case.
5050 (pdp11_expand_shift): Bugfix in check for constant shift count.
5051 (pdp11_shift_length): Ditto.
5052 (pdp11_assemble_shift): Copy input to pdp11_expand_operands.
5053 (pdp11_cmp_length): New function.
5054 * config/pdp11/pdp11.h (TARGET_CPU_CPP_BUILTINS): Add macros for
5055 some compile options.
5056 (FIXED_REGISTERS): Remove HARD_FRAME_POINTER_REGNUM.
5057 (CALL_USED_REGISTERS): Ditto.
5058 (ELIMINABLE_REGS): Ditto.
5059 (REGISTER_NAMES): Ditto.
5060 (reg_class): Add classes NOTR0_REG through NOTSP_REG for use by Z
5061 constraints.
5062 (REG_CLASS_NAMES): Ditto.
5063 (REG_CLASS_CONTENTS): Ditto. Also remove
5064 HARD_FRAME_POINTER_REGNUM.
5065 (CPU_REG_CLASS): New macro.
5066 (CLASS_MAX_NREGS): Adjust for new register classes.
5067 (FUNCTION_PROFILER): Make no-op.
5068 (may_call_alloca): Remove unused declaration.
5069 (ASM_OUTPUT_ALIGN): Add workaround for PR87795.
5070 (ASM_OUTPUT_SKIP): Fix format.
5071 * config/pdp11/pdp11.md (unspecv): Add UNSPECV_MOVMEM.
5072 (HARD_FRAME_POINTER_REGNUM): Remove.
5073 (return): Delete.
5074 (*rts): Rename. Remove epilogue related checks.
5075 (cmpsi, cmpdi): New insn.
5076 (cbranch<mode>4): Change to apply to SI and DI modes as well.
5077 (mov<mode>): Change constraints to enforce that push/pop
5078 destination cannot use the same register as source.
5079 (*mov<mode><cc_cc>): Ditto.
5080 (movmemhi, movmemhi1, movmemhi_nocc): Change to expand block move
5081 at assembly output rather than as RTL expander.
5082 (zero_extendqihi2): Bugfix in check for same registers.
5083 (adddi3_nocc): Bugfix in check for constant operand.
5084 (addsi3_nocc): Ditto.
5085 (subdi3_nocc): Ditto.
5086 (subsi3_nocc): Ditto.
5087 (negdi2_nocc): Copy input to pdp11_expand_operands.
5088 (negsi2_nocc): Ditto.
5089 (bswap2_nocc): Ditto.
5090 * config/pdp11/pdp11.opt (mlra): Fix documentation.
5091 * config/pdp11/t-pdp11: Use -Os.
5092
5093 2018-11-08 Richard Earnshaw <rearnsha@arm.com>
5094
5095 * config/arm/parsecpu.awk (/alias/): New parsing rule.
5096 (/begin cpu/): Check that the cpu name hasn't been previously defined.
5097 (gen_comm_data): Print out CPU alias tables.
5098 (check_cpu): Match aliases when checking the CPU name.
5099 * config/arm/arm-protos.h (cpu_alias): New structure.
5100 (cpu_option): Add entry for aliases.
5101 * config/arm/arm-cpus.in (strongarm): Add aliases for strongarm110
5102 strongarm1100 and strongarm1110.
5103 (strongarm110, strongarm1100, strongarm1110): Delete CPU entries.
5104 (config/arm/arm-generic.md): Remove redundant references to
5105 strongarm110, strongarm1100 and strongarm1110.
5106 * common/config/arm/arm-common.c (arm_print_hint_for_cpu_option):
5107 Scan aliases for additional hints.
5108 (arm_parse_cpu_option_name): Also match a cpu name against the list
5109 of aliases.
5110 * config/arm/arm-tables.opt: Regenerated.
5111 * config/arm/arm-tune.md: Regenerated.
5112
5113 2018-11-08 Jakub Jelinek <jakub@redhat.com>
5114
5115 * builtin-types.def (BT_FN_VOID_BOOL, BT_FN_VOID_SIZE_SIZE_PTR,
5116 BT_FN_UINT_UINT_PTR_PTR, BT_FN_UINT_OMPFN_PTR_UINT_UINT,
5117 BT_FN_BOOL_UINT_LONGPTR_LONG_LONG_LONGPTR_LONGPTR_PTR_PTR,
5118 BT_FN_BOOL_UINT_ULLPTR_LONG_ULL_ULLPTR_ULLPTR_PTR_PTR,
5119 BT_FN_BOOL_LONG_LONG_LONG_LONG_LONG_LONGPTR_LONGPTR_PTR_PTR,
5120 BT_FN_BOOL_BOOL_ULL_ULL_ULL_LONG_ULL_ULLPTR_ULLPTR_PTR_PTR): New.
5121 * gengtype.c (open_base_files): Add omp-general.h.
5122 * gimple.c (gimple_build_omp_critical):
5123 (gimple_build_omp_taskgroup): Add CLAUSES argument. Call
5124 gimple_omp_taskgroup_set_clauses.
5125 (gimple_build_omp_atomic_load): Add mo argument, call
5126 gimple_omp_atomic_set_memory_order.
5127 (gimple_build_omp_atomic_store): Likewise.
5128 (gimple_copy): Adjust handling of GIMPLE_OMP_TASKGROUP.
5129 * gimple.def (GIMPLE_OMP_TASKGROUP): Use GSS_OMP_SINGLE_LAYOUT
5130 instead of GSS_OMP.
5131 (GIMPLE_OMP_TEAMS): Use GSS_OMP_PARALLEL_LAYOUT instead
5132 of GSS_OMP_SINGLE_LAYOUT, adjust comments.
5133 * gimple.h (enum gf_mask): Add GF_OMP_TEAMS_HOST, GF_OMP_TASK_TASKWAIT
5134 and GF_OMP_ATOMIC_MEMORY_ORDER. Remove GF_OMP_ATOMIC_SEQ_CST, use
5135 different value for GF_OMP_ATOMIC_NEED_VALUE.
5136 (struct gimple_statement_omp_taskreg): Add GIMPLE_OMP_TEAMS to
5137 comments.
5138 (struct gimple_statement_omp_single_layout): And remove here.
5139 (struct gomp_teams): Inherit from gimple_statement_omp_taskreg rather
5140 than gimple_statement_omp_single_layout.
5141 (is_a_helper <gimple_statement_omp_taskreg *>::test): Allow
5142 GIMPLE_OMP_TEAMS.
5143 (is_a_helper <const gimple_statement_omp_taskreg *>::test): Likewise.
5144 (gimple_omp_subcode): Formatting fix.
5145 (gimple_omp_teams_child_fn, gimple_omp_teams_child_fn_ptr,
5146 gimple_omp_teams_set_child_fn, gimple_omp_teams_data_arg,
5147 gimple_omp_teams_data_arg_ptr, gimple_omp_teams_set_data_arg,
5148 gimple_omp_teams_host, gimple_omp_teams_set_host,
5149 gimple_omp_task_taskwait_p, gimple_omp_task_set_taskwait_p,
5150 gimple_omp_taskgroup_clauses, gimple_omp_taskgroup_clauses_ptr,
5151 gimple_omp_taskgroup_set_clauses): New inline functions.
5152 (gimple_build_omp_atomic_load): Add enum omp_memory_order argument.
5153 (gimple_build_omp_atomic_store): Likewise.
5154 (gimple_omp_atomic_seq_cst_p): Remove.
5155 (gimple_omp_atomic_memory_order): New function.
5156 (gimple_omp_atomic_set_seq_cst): Remove.
5157 (gimple_omp_atomic_set_memory_order): New function.
5158 (gimple_build_omp_taskgroup): Add clauses argument.
5159 * gimple-pretty-print.c (dump_gimple_omp_taskgroup): New function.
5160 (dump_gimple_omp_task): Print taskwait with depend clauses.
5161 (dump_gimple_omp_atomic_load, dump_gimple_omp_atomic_store): Use
5162 dump_omp_atomic_memory_order.
5163 (pp_gimple_stmt_1): Handle GIMPLE_OMP_TASKGROUP.
5164 * gimplify.c (enum gimplify_omp_var_data): Add GOVD_MAP_ALLOC_ONLY,
5165 GOVD_MAP_FROM_ONLY and GOVD_NONTEMPORAL.
5166 (enum omp_region_type): Reserve bits 1 and 2 for auxiliary flags,
5167 renumber values of most of ORT_* enumerators, add ORT_HOST_TEAMS,
5168 ORT_COMBINED_HOST_TEAMS, ORT_TASKGROUP, ORT_TASKLOOP and
5169 ORT_UNTIED_TASKLOOP enumerators.
5170 (enum gimplify_defaultmap_kind): New.
5171 (struct gimplify_omp_ctx): Remove target_map_scalars_firstprivate and
5172 target_map_pointers_as_0len_arrays members, add defaultmap.
5173 (new_omp_context): Initialize defaultmap member.
5174 (gimple_add_tmp_var): Handle ORT_TASKGROUP like ORT_WORKSHARE.
5175 (maybe_fold_stmt): Don't fold even in host teams regions.
5176 (omp_firstprivatize_variable): Handle ORT_TASKGROUP like
5177 ORT_WORKSHARE. Test ctx->defaultmap[GDMK_SCALAR] instead of
5178 ctx->omp_firstprivatize_variable.
5179 (omp_add_variable): Don't add private/firstprivate for VLAs in
5180 ORT_TASKGROUP.
5181 (omp_default_clause): Print "taskloop" rather than "task" if
5182 ORT_*TASKLOOP.
5183 (omp_notice_variable): Handle ORT_TASKGROUP like ORT_WORKSHARE.
5184 Handle new defaultmap clause kinds.
5185 (omp_is_private): Handle ORT_TASKGROUP like ORT_WORKSHARE. Allow simd
5186 iterator to be lastprivate or private. Fix up diagnostics if linear
5187 is used on collapse>1 simd iterator.
5188 (omp_check_private): Handle ORT_TASKGROUP like ORT_WORKSHARE.
5189 (gimplify_omp_depend): New function.
5190 (gimplify_scan_omp_clauses): Add shared clause on parallel for
5191 combined parallel master taskloop{, simd} if taskloop has
5192 firstprivate, lastprivate or reduction clause. Handle
5193 OMP_CLAUSE_REDUCTION_TASK diagnostics. Adjust tests for
5194 ORT_COMBINED_TEAMS. Gimplify depend clauses with iterators. Handle
5195 cancel and simd OMP_CLAUSE_IF_MODIFIERs. Handle
5196 OMP_CLAUSE_NONTEMPORAL. Handle new defaultmap clause kinds. Handle
5197 OMP_CLAUSE_{TASK,IN}_REDUCTION. Diagnose invalid conditional
5198 lastprivate.
5199 (gimplify_adjust_omp_clauses_1): Ignore GOVD_NONTEMPORAL. Handle
5200 GOVD_MAP_ALLOC_ONLY and GOVD_MAP_FROM_ONLY.
5201 (gimplify_adjust_omp_clauses): Handle OMP_CLAUSE_NONTEMPORAL. Handle
5202 OMP_CLAUSE_{TASK,IN}_REDUCTION.
5203 (gimplify_omp_task): Handle taskwait with depend clauses.
5204 (gimplify_omp_for): Add shared clause on parallel for combined
5205 parallel master taskloop{, simd} if taskloop has firstprivate,
5206 lastprivate or reduction clause. Use ORT_TASKLOOP or
5207 ORT_UNTIED_TASKLOOP instead of ORT_TASK or ORT_UNTIED_TASK. Adjust
5208 tests for ORT_COMBINED_TEAMS. Handle C++ range for loops with
5209 NULL TREE_PURPOSE in OMP_FOR_ORIG_DECLS. Firstprivatize
5210 __for_end and __for_range temporaries on OMP_PARALLEL for
5211 distribute parallel for{, simd}. Move OMP_CLAUSE_REDUCTION
5212 and OMP_CLAUSE_IN_REDUCTION from taskloop to the task construct
5213 sandwiched in between two taskloops.
5214 (computable_teams_clause): Test ctx->defaultmap[GDMK_SCALAR]
5215 instead of ctx->omp_firstprivatize_variable.
5216 (gimplify_omp_workshare): Set ort to ORT_HOST_TEAMS or
5217 ORT_COMBINED_HOST_TEAMS if not inside of target construct. If
5218 host teams, use gimplify_and_return_first etc. for body like
5219 for target or target data constructs, and at the end call
5220 gimple_omp_teams_set_host on the GIMPLE_OMP_TEAMS object.
5221 (gimplify_omp_atomic): Use OMP_ATOMIC_MEMORY_ORDER instead
5222 of OMP_ATOMIC_SEQ_CST, pass it as new argument to
5223 gimple_build_omp_atomic_load and gimple_build_omp_atomic_store, remove
5224 gimple_omp_atomic_set_seq_cst calls.
5225 (gimplify_expr) <case OMP_TASKGROUP>: Move handling into a separate
5226 case, handle taskgroup clauses.
5227 * lto-streamer-out.c (hash_tree): Handle
5228 OMP_CLAUSE_{TASK,IN}_REDUCTION.
5229 * Makefile.in (GTFILES): Add omp-general.h.
5230 * omp-builtins.def (BUILT_IN_GOMP_TASKWAIT_DEPEND,
5231 BUILT_IN_GOMP_LOOP_NONMONOTONIC_RUNTIME_START,
5232 BUILT_IN_GOMP_LOOP_MAYBE_NONMONOTONIC_RUNTIME_START,
5233 BUILT_IN_GOMP_LOOP_START, BUILT_IN_GOMP_LOOP_ORDERED_START,
5234 BUILT_IN_GOMP_LOOP_DOACROSS_START,
5235 BUILT_IN_GOMP_LOOP_NONMONOTONIC_RUNTIME_NEXT,
5236 BUILT_IN_GOMP_LOOP_MAYBE_NONMONOTONIC_RUNTIME_NEXT,
5237 BUILT_IN_GOMP_LOOP_ULL_NONMONOTONIC_RUNTIME_START,
5238 BUILT_IN_GOMP_LOOP_ULL_MAYBE_NONMONOTONIC_RUNTIME_START,
5239 BUILT_IN_GOMP_LOOP_ULL_START, BUILT_IN_GOMP_LOOP_ULL_ORDERED_START,
5240 BUILT_IN_GOMP_LOOP_ULL_DOACROSS_START,
5241 BUILT_IN_GOMP_LOOP_ULL_NONMONOTONIC_RUNTIME_NEXT,
5242 BUILT_IN_GOMP_LOOP_ULL_MAYBE_NONMONOTONIC_RUNTIME_NEXT,
5243 BUILT_IN_GOMP_PARALLEL_LOOP_NONMONOTONIC_RUNTIME,
5244 BUILT_IN_GOMP_PARALLEL_LOOP_MAYBE_NONMONOTONIC_RUNTIME,
5245 BUILT_IN_GOMP_PARALLEL_REDUCTIONS, BUILT_IN_GOMP_SECTIONS2_START,
5246 BUILT_IN_GOMP_TEAMS_REG, BUILT_IN_GOMP_TASKGROUP_REDUCTION_REGISTER,
5247 BUILT_IN_GOMP_TASKGROUP_REDUCTION_UNREGISTER,
5248 BUILT_IN_GOMP_TASK_REDUCTION_REMAP,
5249 BUILT_IN_GOMP_WORKSHARE_TASK_REDUCTION_UNREGISTER): New builtins.
5250 * omp-expand.c (workshare_safe_to_combine_p): Return false for
5251 non-worksharing loops.
5252 (omp_adjust_chunk_size): Don't adjust anything if chunk_size is zero.
5253 (determine_parallel_type): Don't combine parallel with worksharing
5254 which has _reductemp_ clause.
5255 (expand_parallel_call): Emit the GOMP_*nonmonotonic_runtime* or
5256 GOMP_*maybe_nonmonotonic_runtime* builtins instead of GOMP_*runtime*
5257 if there is nonmonotonic modifier or if there is no modifier and no
5258 ordered clause. For dynamic and guided schedule without monotonic
5259 and nonmonotonic modifier, default to nonmonotonic.
5260 (expand_omp_for): Likewise. Adjust expand_omp_for_generic caller, use
5261 GOMP_loop{,_ull}{,_ordered,_doacross}_start builtins if there are
5262 task reductions.
5263 (expand_task_call): Add GOMP_TASK_FLAG_REDUCTION flag to flags if
5264 there are any reduction clauses.
5265 (expand_taskwait_call): New function.
5266 (expand_teams_call): New function.
5267 (expand_omp_taskreg): Allow GIMPLE_OMP_TEAMS and call
5268 expand_teams_call for it. Formatting fix. Handle taskwait with
5269 depend clauses.
5270 (expand_omp_for_generic): Add SCHED_ARG argument. Handle expansion
5271 of worksharing loops with task reductions.
5272 (expand_omp_for_static_nochunk, expand_omp_for_static_chunk): Handle
5273 expansion of worksharing loops with task reductions.
5274 (expand_omp_sections): Handle expansion of sections with task
5275 reductions.
5276 (expand_omp_synch): For host teams call expand_omp_taskreg.
5277 (omp_memory_order_to_memmodel): New function.
5278 (expand_omp_atomic_load, expand_omp_atomic_store,
5279 expand_omp_atomic_fetch_op): Use it and gimple_omp_atomic_memory_order
5280 instead of gimple_omp_atomic_seq_cst_p.
5281 (build_omp_regions_1, omp_make_gimple_edges): Treat taskwait with
5282 depend clauses as a standalone directive.
5283 * omp-general.c (enum omp_requires): New variable.
5284 (omp_extract_for_data): Initialize have_reductemp member. Allow
5285 NE_EXPR even in OpenMP loops, transform them into LT_EXPR or
5286 GT_EXPR loops depending on incr sign. Formatting fixes.
5287 * omp-general.h (struct omp_for_data): Add have_reductemp member.
5288 (enum omp_requires): New enum.
5289 (omp_requires_mask): Declare.
5290 * omp-grid.c (grid_eliminate_combined_simd_part): Formatting fix.
5291 Fix comment typos.
5292 * omp-low.c (struct omp_context): Add task_reductions and
5293 task_reduction_map fields.
5294 (is_host_teams_ctx): New function.
5295 (is_taskreg_ctx): Return true also if is_host_teams_ctx.
5296 (use_pointer_for_field): Use is_global_var instead of
5297 TREE_STATIC || DECL_EXTERNAL, and apply only if not privatized
5298 in outer contexts.
5299 (build_outer_var_ref): Ignore taskgroup outer contexts.
5300 (delete_omp_context): Release task_reductions and task_reduction_map.
5301 (scan_sharing_clauses): Don't add any fields for reduction clause on
5302 taskloop. Handle OMP_CLAUSE__REDUCTEMP_. Handle
5303 OMP_CLAUSE_{IN,TASK}_REDUCTION and OMP_CLAUSE_REDUCTION with task
5304 modifier. Don't ignore shared clauses in is_host_teams_ctx contexts.
5305 Handle OMP_CLAUSE_NONTEMPORAL.
5306 (add_taskreg_looptemp_clauses): Add OMP_CLAUSE__REDUCTEMP_ clause if
5307 needed.
5308 (scan_omp_parallel): Add _reductemp_ clause if there are any reduction
5309 clauses with task modifier.
5310 (scan_omp_task): Handle taskwait with depend clauses.
5311 (finish_taskreg_scan): Move field corresponding to _reductemp_ clause
5312 first. Move also OMP_CLAUSE__REDUCTEMP_ clause in front if present.
5313 Handle GIMPLE_OMP_TEAMS like GIMPLE_OMP_PARALLEL.
5314 (scan_omp_for): Fix comment formatting.
5315 (scan_omp_teams): Handle host teams constructs.
5316 (check_omp_nesting_restrictions): Allow teams with no outer
5317 OpenMP context. Adjust diagnostics for teams strictly nested into
5318 some explicit OpenMP construct other than target. Allow OpenMP atomics
5319 inside of simd regions.
5320 (scan_omp_1_stmt): Call scan_sharing_clauses for taskgroups.
5321 (scan_omp_1_stmt) <case GIMPLE_OMP_TEAMS>: Temporarily bump
5322 taskreg_nesting_level while scanning host teams construct.
5323 (task_reduction_read): New function.
5324 (lower_rec_input_clauses): Handle OMP_CLAUSE_REDUCTION on taskloop
5325 construct. Handle OMP_CLAUSE_IN_REDUCTION and OMP_CLAUSE__REDUCTEMP_
5326 clauses. Handle OMP_CLAUSE_REDUCTION with task modifier. Remove
5327 second argument create_tmp_var if it is NULL. Don't ignore shared
5328 clauses in is_host_teams_ctx contexts. Handle
5329 OMP_CLAUSE_FIRSTPRIVATE_NO_REFERENCE on OMP_CLAUSE_FIRSTPRIVATE
5330 clauses.
5331 (lower_reduction_clauses): Ignore reduction clauses with task
5332 modifier. Remove second argument create_tmp_var if it is NULL.
5333 Initialize OMP_ATOMIC_MEMORY_ORDER to relaxed.
5334 (lower_send_clauses): Ignore reduction clauses with task modifier.
5335 Handle OMP_CLAUSE__REDUCTEMP_. Don't send anything for
5336 OMP_CLAUSE_REDUCTION on taskloop. Handle OMP_CLAUSE_IN_REDUCTION.
5337 (maybe_add_implicit_barrier_cancel): Add OMP_RETURN argument, don't
5338 rely that it is the last stmt in body so far. Ignore outer taskgroup
5339 contexts.
5340 (omp_task_reductions_find_first, omp_task_reduction_iterate,
5341 lower_omp_task_reductions): New functions.
5342 (lower_omp_sections): Handle reduction clauses with taskgroup
5343 modifiers. Adjust maybe_add_implicit_barrier_cancel caller.
5344 (lower_omp_single): Adjust maybe_add_implicit_barrier_cancel caller.
5345 (lower_omp_for): Likewise. Handle reduction clauses with taskgroup
5346 modifiers.
5347 (lower_omp_taskgroup): Handle taskgroup reductions.
5348 (create_task_copyfn): Copy over OMP_CLAUSE__REDUCTEMP_ pointer.
5349 Handle OMP_CLAUSE_IN_REDUCTION and OMP_CLAUSE_REDUCTION clauses.
5350 (lower_depend_clauses): If there are any
5351 OMP_CLAUSE_DEPEND_DEPOBJ or OMP_CLAUSE_DEPEND_MUTEXINOUTSET
5352 depend clauses, use a new array format. If OMP_CLAUSE_DEPEND_LAST is
5353 seen, assume lowering is done already and return early. Set kind
5354 on artificial depend clause to OMP_CLAUSE_DEPEND_LAST.
5355 (lower_omp_taskreg): Handle reduction clauses with task modifier on
5356 parallel construct. Handle reduction clause on taskloop construct.
5357 Handle taskwait with depend clauses.
5358 (lower_omp_1): Use lower_omp_taskreg instead of lower_omp_teams
5359 for host teams constructs.
5360 * tree.c (omp_clause_num_ops): Add in_reduction, task_reduction,
5361 nontemporal and _reductemp_ clause entries.
5362 (omp_clause_code_name): Likewise.
5363 (walk_tree_1): Handle OMP_CLAUSE_{IN,TASK}_REDUCTION,
5364 OMP_CLAUSE_NONTEMPORAL and OMP_CLAUSE__REDUCTEMP_.
5365 * tree-core.h (enum omp_clause_code): Add
5366 OMP_CLAUSE_{{IN,TASK}_REDUCTION,NONTEMPORAL,_REDUCTEMP_}.
5367 (enum omp_clause_defaultmap_kind, enum omp_memory_order): New.
5368 (struct tree_base): Add omp_atomic_memory_order field into union.
5369 Remove OMP_ATOMIC_SEQ_CST comment.
5370 (enum omp_clause_depend_kind): Add OMP_CLAUSE_DEPEND_MUTEXINOUTSET
5371 and OMP_CLAUSE_DEPEND_DEPOBJ.
5372 (struct tree_omp_clause): Add subcode.defaultmap_kind.
5373 * tree.def (OMP_TASKGROUP): Add another operand, move next to other
5374 OpenMP constructs with body and clauses operands.
5375 * tree.h (OMP_BODY): Use OMP_MASTER instead of OMP_TASKGROUP.
5376 (OMP_CLAUSES): Use OMP_TASKGROUP instead of OMP_SINGLE.
5377 (OMP_TASKGROUP_CLAUSES): Define.
5378 (OMP_CLAUSE_DECL): Use OMP_CLAUSE__REDUCTEMP_ instead of
5379 OMP_CLAUSE__LOOPTEMP_.
5380 (OMP_ATOMIC_SEQ_CST): Remove.
5381 (OMP_ATOMIC_MEMORY_ORDER, OMP_CLAUSE_FIRSTPRIVATE_NO_REFERENCE,
5382 OMP_CLAUSE_LASTPRIVATE_CONDITIONAL): Define.
5383 (OMP_CLAUSE_REDUCTION_CODE, OMP_CLAUSE_REDUCTION_INIT,
5384 OMP_CLAUSE_REDUCTION_MERGE, OMP_CLAUSE_REDUCTION_PLACEHOLDER,
5385 OMP_CLAUSE_REDUCTION_DECL_PLACEHOLDER,
5386 OMP_CLAUSE_REDUCTION_OMP_ORIG_REF): Handle
5387 OMP_CLAUSE_{,IN_,TASK_}REDUCTION.
5388 (OMP_CLAUSE_REDUCTION_TASK, OMP_CLAUSE_REDUCTION_INSCAN,
5389 OMP_CLAUSE_DEFAULTMAP_KIND, OMP_CLAUSE_DEFAULTMAP_CATEGORY,
5390 OMP_CLAUSE_DEFAULTMAP_BEHAVIOR, OMP_CLAUSE_DEFAULTMAP_SET_KIND):
5391 Define.
5392 * tree-inline.c (remap_gimple_stmt): Remap taskgroup clauses.
5393 * tree-nested.c (convert_nonlocal_omp_clauses): Handle
5394 OMP_CLAUSE__REDUCTEMP_, OMP_CLAUSE_NONTEMPORAL.
5395 (convert_local_omp_clauses): Likewise. Remove useless test.
5396 * tree-parloops.c (create_call_for_reduction_1): Pass
5397 OMP_MEMORY_ORDER_RELAXED as new argument to
5398 dump_gimple_omp_atomic_load and dump_gimple_omp_atomic_store.
5399 * tree-pretty-print.c (dump_omp_iterators): New function.
5400 (dump_omp_clause): Handle OMP_CLAUSE__REDUCTEMP_,
5401 OMP_CLAUSE_NONTEMPORAL, OMP_CLAUSE_{TASK,IN}_REDUCTION. Print
5402 reduction modifiers. Handle OMP_CLAUSE_DEPEND_DEPOBJ and
5403 OMP_CLAUSE_DEPEND_MUTEXINOUTSET. Print iterators in depend clauses.
5404 Print __internal__ for OMP_CLAUSE_DEPEND_LAST. Handle cancel and
5405 simd OMP_CLAUSE_IF_MODIFIERs. Handle new kinds of
5406 OMP_CLAUSE_DEFAULTMAP. Print conditional: for
5407 OMP_CLAUSE_LASTPRIVATE_CONDITIONAL.
5408 (dump_omp_atomic_memory_order): New function.
5409 (dump_generic_node): Use it. Print taskgroup clauses. Print
5410 taskwait with depend clauses.
5411 * tree-pretty-print.h (dump_omp_atomic_memory_order): Declare.
5412 * tree-streamer-in.c (unpack_ts_omp_clause_value_fields):
5413 Handle OMP_CLAUSE_{TASK,IN}_REDUCTION.
5414 * tree-streamer-out.c (pack_ts_omp_clause_value_fields,
5415 write_ts_omp_clause_tree_pointers): Likewise.
5416
5417 2018-11-08 David Malcolm <dmalcolm@redhat.com>
5418
5419 PR ipa/86395
5420 * doc/invoke.texi (-fdump-ipa-): Document the "-optimized",
5421 "-missed", "-note", and "-all" sub-options.
5422 * ipa-inline.c (caller_growth_limits): Port from fprintf to dump
5423 API.
5424 (can_early_inline_edge_p): Likewise.
5425 (want_early_inline_function_p): Likewise.
5426 (want_inline_self_recursive_call_p): Likewise.
5427 (recursive_inlining): Likewise.
5428 (inline_small_functions): Likewise.
5429 (flatten_function): Likewise.
5430 (ipa_inline): Likewise.
5431 (inline_always_inline_functions): Likewise.
5432 (early_inline_small_functions): Likewise.
5433 (early_inliner): Likewise.
5434 * tree-inline.c (expand_call_inline): Likewise.
5435
5436 2018-11-08 David Malcolm <dmalcolm@redhat.com>
5437
5438 * pretty-print.c (pp_format): Handle %f.
5439 (selftest::test_pp_format): Add test of %f.
5440 * pretty-print.h (pp_double): New macro.
5441
5442 2018-11-08 David Malcolm <dmalcolm@redhat.com>
5443
5444 * dump-context.h (ASSERT_IS_CGRAPH_NODE): New macro.
5445 * dumpfile.c (make_item_for_dump_cgraph_node): Move to before...
5446 (dump_pretty_printer::decode_format): Implement "%C" for
5447 cgraph_node *.
5448 (selftest::test_capture_of_dump_calls): Rename "where" to
5449 "stmt_loc". Convert test_decl to a function decl and set its
5450 location. Add a symbol_table_test RAII instance and a
5451 cgraph_node, using it to test "%C" and dump_symtab_node.
5452
5453 2018-11-08 Eric Botcazou <ebotcazou@adacore.com>
5454
5455 PR middle-end/87916
5456 * cgraphclones.c (duplicate_thunk_for_node): Also set DECL_IGNORED_P.
5457
5458 2018-11-08 David Malcolm <dmalcolm@redhat.com>
5459
5460 * cgraph.c: Include "selftest.h".
5461 (saved_symtab): New variable.
5462 (selftest::symbol_table_test::symbol_table_test): New ctor.
5463 (selftest::symbol_table_test::~symbol_table_test): New dtor.
5464 (selftest::test_symbol_table_test): New test.
5465 (selftest::cgraph_c_tests): New.
5466 * cgraph.h (saved_symtab): New decl.
5467 (selftest::symbol_table_test): New class.
5468 * selftest-run-tests.c (selftest::run_tests): Call
5469 selftest::cgraph_c_tests.
5470 * selftest.h (selftest::cgraph_c_tests): New decl.
5471
5472 2018-11-08 Richard Biener <rguenther@suse.de>
5473
5474 * tree-data-ref.h (lambda_int): New typedef.
5475 (lambda_vector_gcd): Adjust.
5476 (lambda_vector_new): Likewise.
5477 (lambda_matrix_new): Likewise.
5478 * tree-data-ref.c (print_lambda_vector): Adjust.
5479
5480 2018-11-08 Richard Biener <rguenther@suse.de>
5481
5482 PR tree-optimization/87929
5483 * tree-complex.c (expand_complex_comparison): Clean EH.
5484
5485 2018-11-08 Martin Liska <mliska@suse.cz>
5486
5487 * doc/extend.texi: Reword.
5488 * predict.c (expr_expected_value_1): Likewise.
5489
5490 2018-11-08 Richard Biener <rguenther@suse.de>
5491
5492 PR tree-optimization/87913
5493 * tree-ssa-phiopt.c (minmax_replacement): Turn EQ/NE compares
5494 of extreme values to ordered comparisons.
5495
5496 2018-11-07 Sandra Loosemore <sandra@codesourcery.com>
5497
5498 PR middle-end/42726
5499 * doc/invoke.texi (Code Gen Options): Clarify -fno-common behavior.
5500
5501 2018-11-07 Sandra Loosemore <sandra@codesourcery.com>
5502
5503 * doc/invoke.texi: Remove leading dash from @opindex entries
5504 throughout the file.
5505
5506 2018-11-07 Sandra Loosemore <sandra@codesourcery.com>
5507
5508 PR driver/80828
5509 * doc/invoke.texi (Option Summary): Add -e and --entry.
5510 (Link Options): Likewise.
5511
5512 2018-11-07 Nathan Sidwell <nathan@acm.org>
5513
5514 PR 87926
5515 * Makefile.in (bitmap.o-warn): Add -Wno-error to unbreak
5516 --disable-checking bootstrap.
5517
5518 2018-11-07 Hafiz Abid Qadeer <abidh@codesourcery.com>
5519
5520 * configure: Regenerated.
5521
5522 2018-11-07 Jozef Lawrynowicz <jozef.l@mittosystems.com>
5523
5524 PR c/87691
5525 * stor-layout.c (compute_record_mode): Set TYPE_MODE of UNION_TYPE
5526 to the mode of the widest field iff the widest field has mode class
5527 MODE_INT, or MODE_PARTIAL_INT and the union would be passed by
5528 reference.
5529
5530 2018-11-07 Nikolai Merinov <n.merinov@inango-systems.com>
5531
5532 * common.opt: Add -Wattribute-warning.
5533 * doc/invoke.texi: Add documentation for -Wno-attribute-warning.
5534 * expr.c (expand_expr_real_1): Add new attribute to warning_at
5535 call to allow user configure behavior of "warning" attribute.
5536
5537 2018-11-07 Segher Boessenkool <segher@kernel.crashing.org>
5538
5539 * target.def: Put @: after every vs., e.g., and i.e. where it is
5540 followed by whitespace.
5541 * doc/extend.texi: Ditto.
5542 * doc/fragments.texi: Ditto.
5543 * doc/gimple.texi: Ditto.
5544 * doc/implement-c.texi: Ditto.
5545 * doc/install.texi: Ditto.
5546 * doc/invoke.texi: Ditto.
5547 * doc/md.texi: Ditto.
5548 * doc/plugins.texi: Ditto.
5549 * doc/rtl.texi: Ditto.
5550 * doc/sourcebuild.texi: Ditto.
5551 * doc/tm.texi.in: Ditto.
5552 * doc/ux.texi: Ditto.
5553 * doc/tm.texi: Regenerate.
5554
5555 2018-11-07 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
5556
5557 * config/arm/arm-cpus.in (ares): New entry.
5558 * config/arm/arm-tables.opt: Regenerate.
5559 * config/arm/arm-tune.md: Likewise.
5560 * doc/invoke.texi (ARM Options): Document ares.
5561
5562 2018-11-07 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
5563
5564 * config/aarch64/aarch64-cores.def (ares): Define.
5565 * config/aarch64/aarch64-tune.md: Regenerate.
5566 * doc/invoke.texi (AArch64 Options): Document ares value for mtune.
5567
5568 2018-11-07 Jan Hubicka <jh@suse.cz>
5569
5570 * tree.c (fld_incomplete_type_of): Clear TREE_ADDRESSABLE.
5571 (free_lang_data_in_decl): Set TREE_ADDRESSABLE for public vars and
5572 functions; clear TYPE_DECL_SUPPRESS_DEBUG and DECL_MODE for
5573 TYPE_DECL.
5574
5575 2018-11-07 Richard Biener <rguenther@suse.de>
5576
5577 PR tree-optimization/87914
5578 * tree-vect-loop.c (vect_is_simple_reduction): Improve detection
5579 of nested cycles.
5580 (vectorizable_reduction): Handle shifts and rotates by dispatching
5581 to vectorizable_shift.
5582 * tree-vect-stmts.c (vect_get_vec_def_for_operand_1): Handle
5583 in-loop uses of vect_nested_cycle defs. Merge cycle and internal
5584 def cases.
5585 (vectorizable_shift): Export and handle being called as
5586 vect_nested_cycle.
5587 (vect_analyze_stmt): Call vectorizable_shift after
5588 vectorizable_reduction.
5589 * tree-vectorizer.h (vectorizable_shift): Declare.
5590
5591 2018-11-07 Jan Hubicka <jh@suse.cz>
5592
5593 * ipa-devirt.c (odr_types_equivalent_p): Expect constants
5594 than const decls in TREE_VALUE of enum.
5595 (dump_type_inheritance_graph): Improve duplicate dumping.
5596 (free_enum_values): New.
5597 (build_type_inheritance_graph): Use it.
5598 * tree.c (free_lang_data_in_type): Free TYPE_VALUES of enums
5599 which are not main variants or not ODR types.
5600 (verify_type_variant): Expect variants to have no TYPE_VALUES.
5601
5602 2018-11-07 Richard Biener <rguenther@suse.de>
5603
5604 * ipa-inline.c (want_inline_small_function_p): Compute
5605 big_speedup_p lazily and last.
5606
5607 2018-11-07 Jan Hubicka <jh@suse.cz>
5608
5609 * tree.c (fld_type_variant_equal_p): Skip TYPE_ALIGN check when
5610 building incomplete variant of complete type.
5611 (fld_type_variant): Do not copy TYPE_ALIGN when building incomplete
5612 variant of complete type.
5613
5614 2018-11-07 Chenghua Xu <paul.hua.gm@gmail.com>
5615
5616 * config/mips/mips.c: Fix typo in documentation of
5617 mips_loongson_ext2_prefetch_cookie.
5618 (mips_option_override): fix brain twister logical.
5619 * config/mips/mips.h: Fix typo in documentation of
5620 ISA_HAS_CTZ_CTO and define pattern.
5621 * config/mips/mips.md (prefetch): Hoist EXT2 above
5622 the 2EF/EXT block.
5623 (prefetch_indexed): Hoist EXT2 above the EXT block.
5624
5625 2018-11-07 Jan Hubicka <jh@suse.cz>
5626
5627 * tree.c (free_lang_data_in_type): Add fld parameter; simplify
5628 return and parameter types of function and method types.
5629 (free_lang_data_in_cgraph): Update.
5630
5631 2018-11-07 Martin Liska <mliska@suse.cz>
5632
5633 PR rtl-optimization/87868
5634 * postreload-gcse.c (eliminate_partially_redundant_load): Set
5635 threshold to max_count if we would overflow.
5636 * profile-count.h: Make max_count a public constant.
5637
5638 2018-11-07 Martin Liska <mliska@suse.cz>
5639
5640 * mem-stats.h: Fix GNU coding style.
5641
5642 2018-11-07 Chenghua Xu <paul.hua.gm@gmail.com>
5643
5644 * config/mips/gs264e.md: New.
5645 * config/mips/mips-cpus.def: Define gs264e.
5646 * config/mips/mips-tables.opt: Regenerate.
5647 * config/mips/mips.c (mips_rtx_cost_data): Add DEFAULT_COSTS for
5648 gs264e.
5649 (mips_issue_rate): Add support for gs264e.
5650 (mips_multipass_dfa_lookahead): Likewise.
5651 * config/mips/mips.h: Define TARGET_GS264E and TUNE_GS264E.
5652 (MIPS_ISA_LEVEL_SPEC): Infer mips64r2 from gs264e.
5653 (MIPS_ASE_MSA_SPEC): New.
5654 (BASE_DRIVER_SELF_SPECS): march=gs264e implies -mmsa.
5655 (ISA_HAS_FUSED_MADD4): Enable for TARGET_GS264E.
5656 (ISA_HAS_UNFUSED_MADD4): Exclude TARGET_GS264E.
5657 * config/mips/mips.md: Include gs264e.md.
5658 (processor): Add gs264e.
5659 * config/mips/mips.opt (MSA): Use Mask instead of Var.
5660 * doc/invoke.texi: Add gs264e to supported architectures.
5661
5662 2018-11-07 Chenghua Xu <paul.hua.gm@gmail.com>
5663
5664 * config/mips/gs464e.md: New.
5665 * config/mips/mips-cpus.def: Define gs464e.
5666 * config/mips/mips-tables.opt: Regenerate.
5667 * config/mips/mips.c (mips_rtx_cost_data): Add DEFAULT_COSTS for
5668 gs464e.
5669 (mips_issue_rate): Add support for gs464e.
5670 (mips_multipass_dfa_lookahead): Likewise.
5671 (mips_option_override): Enable MMI, EXT and EXT2 for gs464e.
5672 * config/mips/mips.h: Define TARGET_GS464E and TUNE_GS464E.
5673 (MIPS_ISA_LEVEL_SPEC): Infer mips64r2 from gs464e.
5674 (ISA_HAS_FUSED_MADD4): Enable for TARGET_GS464E.
5675 (ISA_HAS_UNFUSED_MADD4): Exclude TARGET_GS464E.
5676 * config/mips/mips.md: Include gs464e.md.
5677 (processor): Add gs464e.
5678 * doc/invoke.texi: Add gs464e to supported architectures.
5679
5680 2018-11-07 Chenghua Xu <paul.hua.gm@gmail.com>
5681
5682 * config/mips/loongson3a.md: Rename to ...
5683 * config/mips/gs464.md: ... here.
5684 * config/mips/mips-cpus.def: Define gs464; Add loongson3a
5685 as an alias of gs464 processor.
5686 * config/mips/mips-tables.opt: Regenerate.
5687 * config/mips/mips.c (mips_issue_rate): Use PROCESSOR_GS464
5688 instead of PROCESSOR_LOONGSON_3A.
5689 (mips_multipass_dfa_lookahead): Use TUNE_GS464 instead of
5690 TUNE_LOONGSON_3A.
5691 (mips_option_override): Enable MMI and EXT for gs464.
5692 * config/mips/mips.h: Rename TARGET_LOONGSON_3A to TARGET_GS464;
5693 Rename TUNE_LOONGSON_3A to TUNE_GS464.
5694 (MIPS_ISA_LEVEL_SPEC): Infer mips64r2 from gs464.
5695 (ISA_HAS_ODD_SPREG, ISA_AVOID_DIV_HILO, ISA_HAS_FUSED_MADD4,
5696 ISA_HAS_UNFUSED_MADD4): Use TARGET_GS464 instead of
5697 TARGET_LOONGSON_3A.
5698 * config/mips/mips.md: Include gs464.md instead of loongson3a.md.
5699 (processor): Add gs464;
5700 * doc/invoke.texi: Add gs464 to supported architectures.
5701
5702 2018-11-07 Chenghua Xu <paul.hua.gm@gmail.com>
5703
5704 * config/mips/mips-protos.h
5705 (mips_loongson_ext2_prefetch_cookie): New prototype.
5706 * config/mips/mips.c (mips_loongson_ext2_prefetch_cookie): New.
5707 (mips_option_override): Enable TARGET_LOONGSON_EXT when
5708 TARGET_LOONGSON_EXT2 is true.
5709 * config/mips/mips.h (TARGET_CPU_CPP_BUILTINS): Define
5710 __mips_loongson_ext2, __mips_loongson_ext_rev=2.
5711 (ISA_HAS_CTZ_CTO): New, true if TARGET_LOONGSON_EXT2.
5712 (ISA_HAS_PREFETCH): Include TARGET_LOONGSON_EXT and
5713 TARGET_LOONGSON_EXT2.
5714 (ASM_SPEC): Add mloongson-ext2 and mno-loongson-ext2.
5715 (define_insn "ctz<mode>2"): New insn pattern.
5716 (define_insn "prefetch"): Include TARGET_LOONGSON_EXT2.
5717 (define_insn "prefetch_indexed_<mode>"): Include
5718 TARGET_LOONGSON_EXT and TARGET_LOONGSON_EXT2.
5719 * config/mips/mips.opt (-mloongson-ext2): Add option.
5720 * gcc/doc/invoke.texi (-mloongson-ext2): Document.
5721
5722 2018-11-07 Chenghua Xu <paul.hua.gm@gmail.com>
5723
5724 * config/mips/mips.h (TARGET_CPU_CPP_BUILTINS): Add
5725 __mips_loongson_ext.
5726 (MIPS_ASE_LOONGSON_EXT_SPEC): New.
5727 (BASE_DRIVER_SELF_SPECS): march=loongson3a implies
5728 -mloongson-ext.
5729 (ASM_SPEC): Add mloongson-ext and mno-loongson-ext.
5730 * config/mips/mips.md (mul<mode>3, mul<mode>3_mul3_nohilo,
5731 <u>div<mode>3, <u>mod<mode>3, prefetch): Use TARGET_LOONGSON_EXT
5732 instead of TARGET_LOONGSON_3A.
5733 * config/mips/mips.opt (-mloongson-ext): Add option.
5734 * gcc/doc/invoke.texi (-mloongson-ext): Document.
5735
5736 2018-11-07 Chenghua Xu <paul.hua.gm@gmail.com>
5737
5738 * config.gcc (extra_headers): Add loongson-mmiintrin.h.
5739 * config/mips/loongson.md: Move to ...
5740 * config/mips/loongson-mmi.md: here; Adjustment.
5741 * config/mips/loongson.h: Move to ...
5742 State as deprecated. Include loongson-mmiintrin.h for back
5743 compatibility and warning.
5744 * config/mips/loongson-mmiintrin.h: ... here.
5745 * config/mips/mips.c (mips_hard_regno_mode_ok_uncached,
5746 mips_vector_mode_supported_p, AVAIL_NON_MIPS16): Use
5747 TARGET_LOONGSON_MMI instead of TARGET_LOONGSON_VECTORS.
5748 (mips_option_override): Make sure MMI use hard float;
5749 (mips_shift_truncation_mask, mips_expand_vpc_loongson_even_odd,
5750 mips_expand_vpc_loongson_pshufh, mips_expand_vpc_loongson_bcast,
5751 mips_expand_vector_init): Use TARGET_LOONGSON_MMI instead of
5752 TARGET_LOONGSON_VECTORS.
5753 * gcc/config/mips/mips.h (TARGET_LOONGSON_VECTORS): Delete.
5754 (TARGET_CPU_CPP_BUILTINS): Add __mips_loongson_mmi.
5755 (MIPS_ASE_DSP_SPEC, MIPS_ASE_LOONGSON_MMI_SPEC): New.
5756 (BASE_DRIVER_SELF_SPECS): march=loongson2e/2f/3a implies
5757 -mloongson-mmi.
5758 (SHIFT_COUNT_TRUNCATED): Use TARGET_LOONGSON_MMI instead of
5759 TARGET_LOONGSON_VECTORS.
5760 * gcc/config/mips/mips.md (MOVE64, MOVE128): Use
5761 TARGET_LOONGSON_MMI instead of TARGET_LOONGSON_VECTORS.
5762 (Loongson MMI patterns): Include loongson-mmi.md instead of
5763 loongson.md.
5764 * gcc/config/mips/mips.opt (-mloongson-mmi): New option.
5765 * gcc/doc/invoke.texi (-mloongson-mmi): Document.
5766
5767 2018-11-07 Richard Biener <rguenther@suse.de>
5768
5769 PR lto/87906
5770 * tree-streamer-in.c (lto_input_ts_block_tree_pointers): Fixup
5771 BLOCK_ABSTRACT_ORIGIN to be the ultimate origin.
5772
5773 2018-11-07 Alexandre Oliva <aoliva@redhat.com>
5774
5775 PR rtl-optimization/87874
5776 * lra.c (lra_substitute_pseudo): Do not create a subreg for
5777 const wide ints.
5778
5779 2018-11-06 Aaron Sawdey <acsawdey@linux.ibm.com>
5780
5781 * config/rs6000/rs6000.md (bswap<mode>2): Force address into register
5782 if not in indexed or indirect form.
5783 (bswap<mode>2_load): Change predicate to indexed_or_indirect_operand.
5784 (bswap<mode>2_store): Ditto.
5785
5786 2018-11-06 Richard Earnshaw <rearnsha@arm.com>
5787
5788 * config/aarch64/aarch64.md (speculation_tracker): Set the mode for
5789 the UNSPEC.
5790
5791 2018-11-06 Richard Biener <rguenther@suse.de>
5792
5793 PR tree-optimization/86850
5794 * vec.h (vec<T, va_heap, vl_ptr>::splice): Check src.length ()
5795 instead of src.m_vec.
5796
5797 2018-11-06 Jan Hubicka <jh@suse.cz>
5798
5799 * tree.c (fld_simplified_type_name): Break out form ...
5800 (free_lang_data_in_type): ... here.
5801 (fld_type_variant_equal_p): Use it.
5802
5803 2018-11-06 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
5804
5805 * config/default-d.c: Include memmodel.h.
5806
5807 * config/sol2-d.c: New file.
5808 * config/t-sol2 (sol2-d.o): New rule.
5809 * config.gcc <*-*-solaris2*>: Set d_target_objs,
5810 target_has_targetdm.
5811
5812 2018-11-06 Jan Hubicka <jh@suse.cz>
5813
5814 * tree.c (fld_type_variant): Also copy alignment; be sure that
5815 new variant is equal.
5816
5817 2018-11-06 Ilya Leoshkevich <iii@linux.ibm.com>
5818
5819 PR target/87762
5820 * config/s390/s390.md: Add relative_long attribute.
5821
5822 2018-11-06 Jan Hubicka <jh@suse.cz>
5823
5824 * ipa-pure-const.c (check_decl): Do not test TYPE_NEEDS_CONSTRUCTING.
5825 * lto-streamer-out.c (hash_tree): Do not hash TYPE_NEEDS_CONSTRUCTING.
5826 * tree-streamer-in.c (unpack_ts_type_common_value_fields): Do not
5827 stream TYPE_NEEDS_CONSTRUCTING.
5828 * tree-streamer-out.c (pack_ts_type_common_value_fields): Likewise.
5829 * tree.c (free_lang_data_in_type): Clear TYPE_NEEDS_CONSTRUCTING.
5830
5831 2018-11-06 Richard Biener <rguenther@suse.de>
5832
5833 * tree-vect-slp.c (vect_slp_bb): Move opening of vect_slp_analyze_bb
5834 dump-scope ...
5835 (vect_slp_analyze_bb_1): ... here to avoid hiding optimized locations.
5836
5837 2018-11-06 Jozef Lawrynowicz <jozef.l@mittosystems.com>
5838
5839 * gcc/config/msp430/msp430.h (REG_CLASS_CONTENTS): Add R0 to
5840 REG_CLASS_CONTENTS[GEN_REGS].
5841 (REGNO_REG_CLASS): Return NO_REGS for R2 and R3.
5842
5843 2018-11-06 Jan Hubicka <jh@suse.cz>
5844
5845 * tree.c (fld_simplified_type_of): Clear TYPELESS_STORAGE flag.
5846
5847 2018-11-06 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
5848
5849 PR sanitizer/80953
5850 * config/sol2.h (ASAN_CC1_SPEC): Define.
5851 (LD_WHOLE_ARCHIVE_OPTION): Define.
5852 (LD_NO_WHOLE_ARCHIVE_OPTION): Define.
5853 (ASAN_REJECT_SPEC): Provide default.
5854 (LIBASAN_EARLY_SPEC): Define.
5855 (LIBTSAN_EARLY_SPEC): Define.
5856 (LIBLSAN_EARLY_SPEC): Define.
5857 * config/i386/sol2.h (CC1_SPEC): Redefine.
5858 (ASAN_REJECT_SPEC): Define.
5859
5860 * config/sparc/sparc.c (sparc_asan_shadow_offset): Declare.
5861 (TARGET_ASAN_SHADOW_OFFSET): Define.
5862 (sparc_asan_shadow_offset): New function.
5863 * config/sparc/sol2.h (CC1_SPEC): Append ASAN_CC1_SPEC.
5864 (ASAN_REJECT_SPEC): Define.
5865
5866 2018-11-06 Jan Hubicka <jh@suse.cz>
5867
5868 * tree.c (fld_type_variant): Copy canonical type.
5869 (fld_incomplete_type_of): Check that canonical types looks sane;
5870 copy canonical type.
5871 (verify_type): Accept when incomplete type has complete canonical type.
5872
5873 2018-11-06 Jan Hubicka <jh@suse.cz>
5874
5875 * tree.c (free_lang_data): Reset overwite_assembler_name,
5876 print_xnode, print_decl, print_type and print_identifier of
5877 langhooks.
5878
5879 2018-11-06 Richard Biener <rguenther@suse.de>
5880
5881 PR tree-optimization/87889
5882 * tree-vect-loop-manip.c (slpeel_duplicate_current_defs_from_edges):
5883 Do nothing if old and new arg are the same
5884
5885 2018-11-06 Andreas Krebbel <krebbel@linux.ibm.com>
5886
5887 PR target/87723
5888 * config/s390/s390.md ("*r<noxa>sbg_di_rotl"): Remove mode
5889 attributes for operands 3 and 4.
5890
5891 2018-11-06 Richard Biener <rguenther@suse.de>
5892
5893 PR middle-end/18041
5894 * simplify-rtx.c (simplify_binary_operation_1): Add pattern
5895 matching bitfield insertion.
5896
5897 2018-11-06 Alexandre Oliva <aoliva@redhat.com>
5898
5899 * auto-inc-dec.c: Include valtrack.h. Improve comments.
5900 (reg_next_debug_use): New.
5901 (attempt_change): Propagate adjusted expression into affected
5902 debug insns.
5903 (merge_in_block): Track uses in debug insns.
5904 (pass_inc_dec::execute): Allocate and release
5905 reg_next_debug_use.
5906
5907 2018-11-06 Wei Xiao <wei3.xiao@intel.com>
5908
5909 * config/i386/avx512fintrin.h: Update VFIXUPIMM* intrinsics.
5910 (_mm512_fixupimm_round_pd): Update parameters and builtin.
5911 (_mm512_maskz_fixupimm_round_pd): Ditto.
5912 (_mm512_fixupimm_round_ps): Ditto.
5913 (_mm512_maskz_fixupimm_round_ps): Ditto.
5914 (_mm_fixupimm_round_sd): Ditto.
5915 (_mm_maskz_fixupimm_round_sd): Ditto.
5916 (_mm_fixupimm_round_ss): Ditto.
5917 (_mm_maskz_fixupimm_round_ss): Ditto.
5918 (_mm512_fixupimm_pd): Ditto.
5919 (_mm512_maskz_fixupimm_pd): Ditto.
5920 (_mm512_fixupimm_ps): Ditto.
5921 (_mm512_maskz_fixupimm_ps): Ditto.
5922 (_mm_fixupimm_sd): Ditto.
5923 (_mm_maskz_fixupimm_sd): Ditto.
5924 (_mm_fixupimm_ss): Ditto.
5925 (_mm_maskz_fixupimm_ss): Ditto.
5926 (_mm512_mask_fixupimm_round_pd): Update builtin.
5927 (_mm512_mask_fixupimm_round_ps): Ditto.
5928 (_mm_mask_fixupimm_round_sd): Ditto.
5929 (_mm_mask_fixupimm_round_ss): Ditto.
5930 (_mm512_mask_fixupimm_pd): Ditto.
5931 (_mm512_mask_fixupimm_ps): Ditto.
5932 (_mm_mask_fixupimm_sd): Ditto.
5933 (_mm_mask_fixupimm_ss): Ditto.
5934 * config/i386/avx512vlintrin.h:
5935 (_mm256_fixupimm_pd): Update parameters and builtin.
5936 (_mm256_maskz_fixupimm_pd): Ditto.
5937 (_mm256_fixupimm_ps): Ditto.
5938 (_mm256_maskz_fixupimm_ps): Ditto.
5939 (_mm_fixupimm_pd): Ditto.
5940 (_mm_maskz_fixupimm_pd): Ditto.
5941 (_mm_fixupimm_ps): Ditto.
5942 (_mm_maskz_fixupimm_ps): Ditto.
5943 (_mm256_mask_fixupimm_pd): Update builtin.
5944 (_mm256_mask_fixupimm_ps): Ditto.
5945 (_mm_mask_fixupimm_pd): Ditto.
5946 (_mm_mask_fixupimm_ps): Ditto.
5947 * config/i386/i386-builtin-types.def: Add new types and remove useless ones.
5948 * config/i386/i386-builtin.def: Update builtin definitions.
5949 * config/i386/i386.c: Handle new builtin types and remove useless ones.
5950 * config/i386/sse.md: Update VFIXUPIMM* patterns.
5951 (<avx512>_fixupimm<mode>_maskz<round_saeonly_expand_name>): Update.
5952 (<avx512>_fixupimm<mode><sd_maskz_name><round_saeonly_name>): Update.
5953 (<avx512>_fixupimm<mode>_mask<round_saeonly_name>): Update.
5954 (avx512f_sfixupimm<mode>_maskz<round_saeonly_expand_name>): Update.
5955 (avx512f_sfixupimm<mode><sd_maskz_name><round_saeonly_name>): Update.
5956 (avx512f_sfixupimm<mode>_mask<round_saeonly_name>): Update.
5957 * config/i386/subst.md:
5958 (round_saeonly_sd_mask_operand4): Add new subst_attr.
5959 (round_saeonly_sd_mask_op4): Ditto.
5960 (round_saeonly_expand_operand5): Ditto.
5961 (round_saeonly_expand): Update.
5962
5963 2018-11-05 Max Filippov <jcmvbkbc@gmail.com>
5964
5965 * config/xtensa/uclinux.h (XTENSA_ALWAYS_PIC): Change to 0.
5966
5967 2018-11-05 Segher Boessenkool <segher@kernel.crashing.org>
5968
5969 PR rtl-optimization/87871
5970 * combine.c (make_more_copies): Skip if dest is frame_pointer_rtx.
5971
5972 2018-11-05 Paul Koning <ni1d@arrl.net>
5973
5974 * doc/sourcebuild.texi (target attributes): Document new "inf"
5975 effective target keyword.
5976
5977 2018-11-05 Robin Dapp <rdapp@linux.ibm.com>
5978
5979 * config/s390/s390.c (s390_register_move_cost): Increase costs for
5980 moves involving the CC reg.
5981
5982 2018-11-05 Richard Biener <rguenther@suse.de>
5983
5984 PR tree-optimization/87873
5985 * tree-ssa-loop-manip.h (split_loop_exit_edge): Add copy_constants_p
5986 argument.
5987 * tree-ssa-loop-manip.c (split_loop_exit_edge): Likewise.
5988 * tree-vect-loop.c (vect_transform_loop): When splitting the
5989 loop exit also create forwarder PHIs for constants.
5990 * tree-vect-loop-manip.c (slpeel_duplicate_current_defs_from_edges):
5991 Handle constant to_arg, add extra checking we match up the correct
5992 PHIs.
5993
5994 2018-11-05 Robin Dapp <rdapp@linux.ibm.com>
5995
5996 * config/s390/s390.md: QImode and HImode for load on condition.
5997
5998 2018-11-05 Robin Dapp <rdapp@linux.ibm.com>
5999
6000 * config/s390/predicates.md: Fix typo.
6001 * config/s390/s390.md: Allow immediates for load on condition.
6002
6003 2018-11-05 Martin Liska <mliska@suse.cz>
6004
6005 * alloc-pool.h (struct pool_usage): Use SIZE_AMOUNT.
6006 * bitmap.h (struct bitmap_usage): Likewise.
6007 * ggc-common.c (SCALE): Remove.
6008 (LABEL): Likewise.
6009 (struct ggc_usage): Use SIZE_AMOUNT. And update
6010 compare method.
6011 * ggc-page.c (SCALE): Remove.
6012 (STAT_LABEL): Remove.
6013 (ggc_print_statistics): Use SIZE_AMOUNT.
6014 * gimple.h (SCALE): Remove.
6015 (LABEL): Likewise.
6016 * input.c (ONE_K): Remove.
6017 (ONE_M): Likewise.
6018 (SCALE): Likewise.
6019 (STAT_LABEL): Likewise.
6020 (FORMAT_AMOUNT): Likewise.
6021 (dump_line_table_statistics): Use SIZE_AMOUNT.
6022 * mem-stats.h (struct mem_usage): Likewise.
6023 * rtl.c (dump_rtx_statistics): Likewise.
6024 (rtx_alloc_counts): Change type to size_t.
6025 (rtx_alloc_sizes): Likewise.
6026 (rtx_count_cmp): New.
6027 (dump_rtx_statistics): Sort first based on counts.
6028 * tree.c (tree_nodes_cmp): New.
6029 (tree_codes_cmp): New.
6030 (dump_tree_statistics): Sort first based on counts.
6031 * system.h (ONE_K): New.
6032 (ONE_M): Likewise.
6033 (SIZE_SCALE): Likewise.
6034 (SIZE_LABEL): Likewise.
6035 (SIZE_AMOUNT): Likewise.
6036 * tree-cfg.c (dump_cfg_stats): Use SIZE_AMOUNT.
6037 * tree-dfa.c (dump_dfa_stats): Likewise.
6038 * tree-phinodes.c (phinodes_print_statistics): Likewise.
6039 * tree-ssanames.c (ssanames_print_statistics): Likewise.
6040 * tree.c (dump_tree_statistics): Likewise.
6041 * vec.c (struct vec_usage): Likewise.
6042 * trans-mem.c (tm_mangle): Enlarge buffer in order to not
6043 trigger a -Werror=format-overflow with
6044 --enable-gather-detailed-stats.
6045
6046 2018-11-05 Martin Liska <mliska@suse.cz>
6047
6048 * mem-stats.h (mem_alloc_description::release_instance_overhead):
6049 Return T *.
6050 * vec.c (struct vec_usage): Register m_element_size.
6051 (vec_prefix::register_overhead): New arguments: elements and
6052 element_size.
6053 (vec_prefix::release_overhead): Subtract elements.
6054 * vec.h (struct vec_prefix): Change signature.
6055 (va_heap::reserve): Pass proper arguments.
6056 (va_heap::release): Likewise.
6057
6058 2018-11-05 Martin Liska <mliska@suse.cz>
6059
6060 * mem-stats.h (mem_alloc_description::get_list): Fix GNU coding
6061 style.
6062 * vec.c: Likewise.
6063
6064 2018-11-05 Richard Biener <rguenther@suse.de>
6065
6066 * tree-scalar-evolution.h (final_value_replacement_loop): Update
6067 prototype.
6068 * tree-scalar-evolution.c (final_value_replacement_loop): Return
6069 whether anything was done.
6070 (scev_const_prop): Remove constant propagation part, fold
6071 remains into ...
6072 * tree-ssa-loop.c (pass_scev_cprop::execute): ... here.
6073 (pass_data_scev_cprop): TODO_cleanup_cfg is now done
6074 conditionally.
6075
6076 2018-11-05 Jakub Jelinek <jakub@redhat.com>
6077
6078 PR tree-optimization/87859
6079 * gimple-ssa-store-merging.c (struct merged_store_group): Add
6080 only_constants and first_nonmergeable_order members.
6081 (merged_store_group::merged_store_group): Initialize them.
6082 (merged_store_group::do_merge): Clear only_constants member if
6083 adding something other than INTEGER_CST store.
6084 (imm_store_chain_info::coalesce_immediate_stores): Don't merge
6085 stores with order >= first_nonmergeable_order. Use
6086 merged_store->only_constants instead of always recomputing it.
6087 Set merged_store->first_nonmergeable_order if we've skipped any
6088 stores. Attempt to merge overlapping INTEGER_CST stores that
6089 we would otherwise skip.
6090
6091 PR sanitizer/87837
6092 * match.pd (X + Y < X): Don't optimize if TYPE_OVERFLOW_SANITIZED.
6093
6094 2018-11-05 Xuepeng Guo <xuepeng.guo@intel.com>
6095
6096 PR target/87853
6097 * config/i386/emmintrin.h (__v16qs): New to cope with option
6098 -funsigned-char.
6099 (_mm_cmpeq_epi8): Replace __v16qi with __v16qs.
6100 (_mm_cmplt_epi8): Likewise.
6101 (_mm_cmpgt_epi8): Likewise.
6102
6103 2018-11-05 Richard Biener <rguenther@suse.de>
6104
6105 PR rtl-optimization/87852
6106 * fwprop.c (use_killed_between): Only consider single-defs of the
6107 use whose definition statement dominates the use.
6108
6109 2018-11-05 Martin Liska <mliska@suse.cz>
6110
6111 PR web/87829
6112 * doc/invoke.texi: Remove options that are
6113 not disabled with -Os.
6114
6115 2018-11-05 Martin Liska <mliska@suse.cz>
6116
6117 PR c/87811
6118 * doc/extend.texi: Update constrain about the last argument
6119 of __builtin_expect_with_probability.
6120
6121 2018-11-05 Martin Liska <mliska@suse.cz>
6122
6123 PR c/87811
6124 * predict.c (expr_expected_value_1): Verify
6125 that last argument is a real constants and emit
6126 error.
6127
6128 2018-11-05 Martin Liska <mliska@suse.cz>
6129
6130 PR gcov-profile/77698
6131 * ipa-profile.c (ipa_profile): Adjust hotness threshold
6132 only in LTO mode.
6133
6134 2018-11-04 Bernd Edlinger <bernd.edlinger@hotmail.de>
6135
6136 PR tree-optimization/86572
6137 * builtins.c (c_strlen): Handle negative offsets in a safe way.
6138
6139 2018-11-04 Bernd Edlinger <bernd.edlinger@hotmail.de>
6140
6141 PR tree-optimization/87672
6142 * gimple-fold.c (gimple_fold_builtin_stxcpy_chk): Gimplify.
6143 * tree-ssa-strlen.c (handle_builtin_strcat): Adjust object size.
6144
6145 2018-11-04 Uros Bizjak <ubizjak@gmail.com>
6146
6147 PR middle-end/58372
6148 * cfgexpand.c (pass_expand::execute): Move the call to
6149 finish_eh_generation in front of the call to expand_stack_alignment.
6150
6151 2018-11-04 Venkataramanan Kumar <venkataramanan.kumar@amd.com>
6152
6153 * common/config/i386/i386-common.c (processor_alias_table): Add
6154 znver2 entry.
6155 * config.gcc (i[34567]86-*-linux* | ...): Add znver2.
6156 (case ${target}): Add znver2.
6157 * config/i386/driver-i386.c: (host_detect_local_cpu): Let
6158 -march=native recognize znver2 processors.
6159 * config/i386/i386-c.c (ix86_target_macros_internal): Add znver2.
6160 * config/i386/i386.c (m_znver2): New definition.
6161 (m_ZNVER): New definition.
6162 (m_AMD_MULTIPLE): Includes m_znver2.
6163 (processor_cost_table): Add znver2 entry.
6164 (processor_target_table): Add znver2 entry.
6165 (get_builtin_code_for_version): Set priority for
6166 PROCESSOR_ZNVER2.
6167 (processor_model): Add M_AMDFAM17H_ZNVER2.
6168 (arch_names_table): Ditto.
6169 (ix86_reassociation_width): Include znver2.
6170 * config/i386/i386.h (TARGET_znver2): New definition.
6171 (struct ix86_size_cost): Add TARGET_ZNVER2.
6172 (enum processor_type): Add PROCESSOR_ZNVER2.
6173 * config/i386/i386.md (define_attr "cpu"): Add znver2.
6174 * config/i386/x86-tune-costs.h: (processor_costs) Add znver2 costs.
6175 * config/i386/x86-tune-sched.c: (ix86_issue_rate): Add znver2.
6176 (ix86_adjust_cost): Add znver2.
6177 * config/i386/x86-tune.def: Replace m_ZNVER1 by m_ZNVER.
6178 * gcc/doc/extend.texi: Add details about znver2.
6179 * gcc/doc/invoke.texi: Add details about znver2.
6180
6181 2018-11-03 Sandra Loosemore <sandra@codesourcery.com>
6182
6183 PR target/87079
6184
6185 * config/nios2/nios2.c (nios2_rtx_costs): Recognize <mul>sidi3
6186 pattern.
6187
6188 2018-11-02 Aaron Sawdey <acsawdey@linux.ibm.com>
6189
6190 * config/rs6000/rs6000-string.c (expand_strncmp_gpr_sequence): Pay
6191 attention to TARGET_AVOID_XFORM and BYTES_BIG_ENDIAN.
6192
6193 2018-11-02 Richard Earnshaw <rearnsha@arm.com>
6194
6195 * config/aarch64/aarch64.c ((aarch64_override_options): Disable
6196 shrink-wrapping when -mtrack-speculation.
6197
6198 2018-11-02 Richard Biener <rguenther@suse.de>
6199
6200 * tree-ssa-coalesce.c (struct coalesce_list): Add obstack member.
6201 (pop_cost_one_pair): Do not free pair.
6202 (pop_best_coalesce): Likewise.
6203 (create_coalesce_list): Initialize obstack.
6204 (delete_coalesce_list): Free obstack.
6205 (find_coalesce_pair): Obstack-allocate coalesce pairs.
6206 (add_cost_one_coalesce): Likewise.
6207 (struct live_track): Remove bitmap pointer indirections.
6208 (new_live_track): Adjust.
6209 (delete_live_track): Likewise.
6210 (live_track_remove_partition): Likewise.
6211 (live_track_add_partition): Likewise.
6212 (live_track_live_p): Likewise.
6213 (live_track_process_def): Likewise.
6214 (live_track_clear_base_vars): Likewise.
6215
6216 2018-11-02 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
6217
6218 * configure.ac (gcc_cv_as_sparc_register_op): Remove.
6219 * configure: Regenerate.
6220 * config.in: Regenerate.
6221 * config/sparc/sparc.c (sparc_output_scratch_registers): Remove
6222 HAVE_AS_REGISTER_PSEUDO_OP guard.
6223 * config/sparc/sparc.h (ASM_ARCH64_SPEC): Remove
6224 !HAVE_AS_REGISTER_PSEUDO_OP support.
6225 (ASM_DECLARE_REGISTER_GLOBAL): Remove HAVE_AS_REGISTER_PSEUDO_OP
6226 guard.
6227
6228 2018-11-02 Richard Biener <rguenther@suse.de>
6229
6230 * dwarf2out.c (build_abbrev_table): Guard lookup_external_ref call
6231 with is_type_die.
6232
6233 2018-11-02 Richard Biener <rguenther@suse.de>
6234
6235 PR tree-optimization/87776
6236 * tree-ssa-sccvn.c (do_rpo_vn): Do not mark backedges
6237 executable when iterating but running into rpo-vn-max-loop-depth
6238 and not eliding the iteration.
6239
6240 2018-11-30 Jan Hubicka <jh@suse.cz>
6241
6242 * tree.c (free_lang_data_in_decl): Free TREE_TYPE and alignment of
6243 TYPE_DECL.
6244
6245 2018-11-01 Aaron Sawdey <acsawdey@linux.ibm.com>
6246
6247 * config/rs6000/rs6000-protos.h (rs6000_address_for_fpconvert): Remove
6248 prototype.
6249 * config/rs6000/rs6000.c (rs6000_force_indexed_or_indirect_mem):
6250 Combine with rs6000_address_for_fpconvert.
6251 (rs6000_address_for_fpconvert): Combine with
6252 rs6000_force_indexed_or_indirect_mem.
6253 (rs6000_expand_vector_init): Change function call from
6254 rs6000_address_for_fpconvert to rs6000_force_indexed_or_indirect_mem.
6255 * config/rs6000/rs6000.md (floatsi<mode>2_lfiwax): Change call from
6256 rs6000_address_for_fpconvert to rs6000_force_indexed_or_indirect_mem.
6257 (floatsi<mode>2_lfiwax_mem): Ditto.
6258 (floatunssi<mode>2_lfiwzx): Ditto.
6259 (floatunssi<mode>2_lfiwzx_mem): Ditto.
6260 (float<QHI:mode><FP_ISA3:mode>2): Ditto.
6261 (floatuns<QHI:mode><FP_ISA3:mode>2): Ditto.
6262 (fix_trunc<mode>si2_stfiwx): Ditto.
6263 (fixuns_trunc<mode>si2_stfiwx): Ditto.
6264 (float_<mode>si2_hw): Ditto.
6265 (floatuns_<mode>si2_hw): Ditto.
6266 * config/rs6000/vsx.md (*vsx_extract_si): Ditto.
6267 (vsx_splat_<mode>): Ditto.
6268
6269 2018-11-01 Joseph Myers <joseph@codesourcery.com>
6270
6271 * configure.ac (gcc_cv_as_ia64_ltoffx_ldxmov_relocs): Add newline
6272 at end of assembler input text.
6273 * configure: Regenerate.
6274
6275 2018-11-01 Jakub Jelinek <jakub@redhat.com>
6276
6277 PR tree-optimization/87826
6278 * gimple-ssa-store-merging.c (do_shift_rotate): Punt if count is
6279 negative or larger or equal to type's precision.
6280
6281 2018-10-31 Alexandre Oliva <aoliva@redhat.com>
6282
6283 * opts.c (default_options_table): Do not enable
6284 OPT_fdelayed_branch at -Og.
6285 * doc/invoke.texi (-fdelayed-branch): Document it.
6286
6287 2018-10-31 Richard Henderson <richard.henderson@linaro.org>
6288
6289 * optabs-libfuncs.c (build_libfunc_function_visibility):
6290 New, split out from...
6291 (build_libfunc_function): ... here.
6292 (init_one_libfunc_visibility): New, split out from ...
6293 (init_one_libfunc): ... here.
6294
6295 * config/aarch64/atomics.md (aarch64_atomic_<ATOMIC_LDOP><ALLI>_lse):
6296 scratch register need not be early-clobber. Document the reason
6297 why we cannot use ST<OP>.
6298
6299 2018-10-31 Joseph Myers <joseph@codesourcery.com>
6300
6301 PR bootstrap/82856
6302 * configure.ac: Remove AC_PREREQ. Use AC_LANG_SOURCE. Use single
6303 line for second argument of AC_DEFINE_UNQUOTED.
6304 * doc/install.texi (Tools/packages necessary for modifying GCC):
6305 Update to autoconf 2.69 and automake 1.15.1.
6306 * aclocal.m4, config.in, configure: Regenerate.
6307
6308 2018-10-31 Pat Haugen <pthaugen@us.ibm.com>
6309
6310 * tree-ssa-loop-ivcanon.c (try_peel_loop): Fix typo and remove dead
6311 initialization.
6312
6313 2018-10-31 Martin Liska <mliska@suse.cz>
6314
6315 PR driver/83193
6316 * common/config/aarch64/aarch64-common.c (aarch64_parse_extension):
6317 Add new argument invalid_extension.
6318 (aarch64_get_all_extension_candidates): New function.
6319 (aarch64_rewrite_selected_cpu): Add NULL to function call.
6320 * config/aarch64/aarch64-protos.h (aarch64_parse_extension): Add
6321 new argument.
6322 (aarch64_get_all_extension_candidates): New function.
6323 * config/aarch64/aarch64.c (aarch64_parse_arch): Add new
6324 argument invalid_extension.
6325 (aarch64_parse_cpu): Likewise.
6326 (aarch64_print_hint_for_extensions): New function.
6327 (aarch64_validate_mcpu): Provide hint about invalid extension.
6328 (aarch64_validate_march): Likewise.
6329 (aarch64_handle_attr_arch): Pass new argument.
6330 (aarch64_handle_attr_cpu): Provide hint about invalid extension.
6331 (aarch64_handle_attr_isa_flags): Likewise.
6332
6333 2018-10-31 Richard Biener <rguenther@suse.de>
6334
6335 PR middle-end/70359
6336 PR middle-end/86270
6337 * tree-outof-ssa.c (insert_backedge_copies): Restrict
6338 copy generation to useful cases. Place the copy before
6339 the definition of the backedge value when possible.
6340
6341 2018-10-31 Claudiu Zissulescu <claziss@synopsys.com>
6342
6343 * config/arc/arc-arch.h (ARC_TUNE_ARC7XX): New tune value.
6344 * config/arc/arc.c (arc_active_insn): New function.
6345 (check_store_cacheline_hazard): Likewise.
6346 (workaround_arc_anomaly): Use check_store_cacheline_hazard.
6347 (arc_override_options): Disable delay slot scheduler for older
6348 A7.
6349 (arc_store_addr_hazard_p): New implementation, old one renamed to
6350 ...
6351 (arc_store_addr_hazard_internal_p): Renamed.
6352 (arc_reorg): Don't combine into brcc instructions which are part
6353 of hardware hazard solution.
6354 * config/arc/arc.md (attr tune): Consider new arc7xx tune value.
6355 (tune_arc700): Likewise.
6356 * config/arc/arc.opt (arc7xx): New tune value.
6357 * config/arc/arc700.md: Improve A7 scheduler.
6358
6359 2018-10-31 Claudiu Zissulescu <claziss@synopsys.com>
6360
6361 * config/arc/arc.c (arc_override_options): Remove
6362 TARGET_COMPACT_CASESI.
6363 * config/arc/arc.h (ASM_OUTPUT_ADDR_DIFF_ELT): Update.
6364 (CASE_VECTOR_MODE): Likewise.
6365 (CASE_VECTOR_PC_RELATIVE): Likewise.
6366 (CASE_VECTOR_SHORTEN_MODE): Likewise.
6367 (CASE_VECTOR_SHORTEN_MODE1): Delete.
6368 (ADDR_VEC_ALIGN): Update.
6369 (ASM_OUTPUT_CASE_LABEL): Undefine.
6370 (ASM_OUTPUT_BEFORE_CASE_LABEL): Undefine.
6371 (TARGET_BI_BIH): Define.
6372 (DEFAULT_BRANCH_INDEX): Likewise.
6373 * config/arc/arc.md (casesi): Rework to accept BI/BIH
6374 instructions, remove compact_casesi use case.
6375 (casesi_compact_jump): Remove.
6376 (casesi_dispatch): New pattern.
6377 * config/arc/arc.opt: Add mbranch-index option. Deprecate
6378 compact_casesi option.
6379 * doc/invoke.texi: Document mbranch-index option.
6380
6381 2018-10-31 Claudiu Zissulescu <claziss@synopsys.com>
6382
6383 * config/arc/arc.c (arc_get_tp): Remove function.
6384 (arc_emit_call_tls_get_addr): Likewise.
6385 (arc_call_tls_get_addr): New function.
6386 (arc_legitimize_tls_address): Make use of arc_call_tls_get_addr.
6387 * config/arc/arc.md (tls_load_tp_soft): Remove.
6388 (tls_gd_get_addr): Likewise.
6389
6390 2018-10-31 Claudiu Zissulescu <claziss@synopsys.com>
6391
6392 * config/arc/arc.md (mulsi3): Remove call to mulsi_600_lib.
6393 (mulsi3_600_lib): Remove pattern.
6394 (umulsi3_highpart_600_lib_le): Likewise.
6395 (umulsi3_highpart): Remove call to umulsi3_highpart_600_lib_le.
6396 (umulsidi3): Remove call to umulsidi3_600_lib.
6397 (umulsidi3_600_lib): Remove pattern.
6398 (peephole2): Remove peephole using the above deprecated patterns.
6399
6400 2018-10-31 Thomas Preud'homme <thomas.preudhomme@linaro.org>
6401
6402 PR target/87374
6403 * config/arm/arm.c (arm_option_check_internal): Disable the combined
6404 use of -mslow-flash-data and -mword-relocations.
6405 (arm_option_override): Enable -mword-relocations if -fpic or -fPIC.
6406 * config/arm/arm.md (SYMBOL_REF MOVT splitter): Stop checking for
6407 flag_pic.
6408 * doc/invoke.texi (-mword-relocations): Mention conflict with
6409 -mslow-flash-data.
6410 (-mslow-flash-data): Reciprocally.
6411
6412 2018-10-31 Richard Henderson <richard.henderson@linaro.org>
6413
6414 * config/aarch64/aarch64.c (aarch64_hard_regno_mode_ok): Force
6415 16-byte modes held in GP registers to use an even regno.
6416
6417 * config/aarch64/aarch64.c (aarch64_emit_bic): Remove.
6418 (aarch64_atomic_ldop_supported_p): Remove.
6419 (aarch64_gen_atomic_ldop): Remove.
6420 * config/aarch64/atomic.md (atomic_<atomic_optab><ALLI>):
6421 Fully expand LSE operations here.
6422 (atomic_fetch_<atomic_optab><ALLI>): Likewise.
6423 (atomic_<atomic_optab>_fetch<ALLI>): Likewise.
6424 (aarch64_atomic_<ATOMIC_LDOP><ALLI>_lse): Drop atomic_op iterator
6425 and use ATOMIC_LDOP instead; use register_operand for the input;
6426 drop the split and emit insns directly.
6427 (aarch64_atomic_fetch_<ATOMIC_LDOP><ALLI>_lse): Likewise.
6428 (aarch64_atomic_<atomic_op>_fetch<ALLI>_lse): Remove.
6429 (@aarch64_atomic_load<ATOMIC_LDOP><ALLI>): Remove.
6430
6431 * config/aarch64/aarch64.c (aarch64_emit_atomic_swap): Remove.
6432 (aarch64_gen_atomic_ldop): Don't call it.
6433 * config/aarch64/atomics.md (atomic_exchange<ALLI>):
6434 Use aarch64_reg_or_zero.
6435 (aarch64_atomic_exchange<ALLI>): Likewise.
6436 (aarch64_atomic_exchange<ALLI>_lse): Remove split; remove & from
6437 operand 0; use aarch64_reg_or_zero for input; merge ...
6438 (@aarch64_atomic_swp<ALLI>): ... this and remove.
6439
6440 * config/aarch64/aarch64.c (aarch64_gen_compare_reg_maybe_ze): New.
6441 (aarch64_split_compare_and_swap): Use it.
6442 (aarch64_expand_compare_and_swap): Likewise. Remove convert_modes;
6443 test oldval against the proper predicate.
6444 * config/aarch64/atomics.md (@atomic_compare_and_swap<ALLI>):
6445 Use nonmemory_operand for expected.
6446 (cas_short_expected_pred): New.
6447 (@aarch64_compare_and_swap<SHORT>): Use it; use "rn" not "rI" to match.
6448 (@aarch64_compare_and_swap<GPI>): Use "rn" not "rI" for expected.
6449 * config/aarch64/predicates.md (aarch64_plushi_immediate): New.
6450 (aarch64_plushi_operand): New.
6451
6452 * config/aarch64/aarch64.c (aarch64_expand_compare_and_swap):
6453 Force oldval into the rval register for TARGET_LSE; emit the compare
6454 during initial expansion so that it may be deleted if unused.
6455 (aarch64_gen_atomic_cas): Remove.
6456 * config/aarch64/atomics.md (@aarch64_compare_and_swap<SHORT>_lse):
6457 Change =&r to +r for operand 0; use match_dup for operand 2;
6458 remove is_weak and mod_f operands as unused. Drop the split
6459 and merge with...
6460 (@aarch64_atomic_cas<SHORT>): ... this pattern's output; remove.
6461 (@aarch64_compare_and_swap<GPI>_lse): Similarly.
6462 (@aarch64_atomic_cas<GPI>): Similarly.
6463
6464 2018-10-31 Richard Biener <rguenther@suse.de>
6465
6466 * tree-eh.c (replace_trapping_overflow): Simplify ABS_EXPR case
6467 using ABSU_EXPR.
6468
6469 2018-10-31 Sameera Deshpande <sameera.deshpande@linaro.org>
6470
6471 * config/aarch64/aarch64-cores.def (saphira): Use saphira pipeline.
6472 * config/aarch64/aarch64.md: Include saphira.md
6473 * config/aarch64/saphira.md: New file for pipeline description.
6474
6475 2018-10-30 Martin Sebor <msebor@redhat.com>
6476
6477 PR middle-end/87041
6478 * gimple-ssa-sprintf.c (format_directive): Use %G to include
6479 inlining context.
6480 (sprintf_dom_walker::compute_format_length):
6481 Avoid setting POSUNDER4K here.
6482 (get_destination_size): Handle null argument values.
6483 (get_user_idx_format): New function.
6484 (sprintf_dom_walker::handle_gimple_call): Handle all printf-like
6485 functions, including user-defined with attribute format printf.
6486 Use %G to include inlining context.
6487 Set POSUNDER4K here.
6488
6489 2018-10-30 Jan Hubicka <jh@suse.cz>
6490
6491 * params.def (lto-partitions): Bump from 32 to 128.
6492
6493 2018-10-30 Jan Hubicka <jh@suse.cz>
6494
6495 * tree.c
6496 (free_lang_data_d, add_tree_to_fld_list, fld_worklist_push): Move
6497 head in file.
6498 (free_lang_data_in_type): Forward declare.
6499 (fld_type_variant_equal_p): New function.
6500 (fld_type_variant): New function
6501 (fld_incomplete_types): New hash.
6502 (fld_incomplete_type_of): New function
6503 (fld_simplfied-type): New function.
6504 (free_lang_data_in_decl): Add fld parameter; simplify type of FIELD_DECL
6505 (free_lang_data): Allocate and free fld_incomplete_type; update call
6506 of free_lang_data_in_decl.
6507
6508 2018-10-30 Eric Botcazou <ebotcazou@adacore.com>
6509
6510 * gcov.c (output_lines): Remove duplicate line.
6511
6512 2018-10-30 Aaron Sawdey <acsawdey@linux.ibm.com>
6513
6514 * config/rs6000/rs6000.md (bswapdi2): Force address into register
6515 if not in indexed or indirect form.
6516 (bswapdi2_load): Change predicate to indexed_or_indirect_operand.
6517 (bswapdi2_store): Ditto.
6518 * config/rs6000/rs6000.c (rs6000_force_indexed_or_indirect_mem): New
6519 helper function.
6520 * config/rs6000/rs6000-protos.h (rs6000_force_indexed_or_indirect_mem):
6521 Prototype for helper function.
6522
6523 2018-10-30 Martin Sebor <msebor@redhat.com>
6524
6525 * doc/extend.texi (optimize): Clarify/expand attribute documentation.
6526 (target, pragma GCC optimize, pragma GCC target): Ditto.
6527
6528 2018-10-30 Jonathan Wakely <jwakely@redhat.com>
6529
6530 * doc/extend.texi: Fix prototype and description of
6531 __builtin_expect_with_probability.
6532
6533 2018-10-30 Michael Ploujnikov <michael.ploujnikov@oracle.com>
6534
6535 * cgraph.h (clone_function_name_1): Replaced by new
6536 clone_function_name_numbered that takes name as string; for
6537 privatize_symbol_name_1 use only.
6538 (clone_function_name): Renamed to
6539 clone_function_name_numbered to be explicit about numbering.
6540 (clone_function_name): New two-argument function that does
6541 not number its output.
6542 (clone_function_name): New three-argument function that
6543 takes a number to append to its output.
6544 * cgraphclones.c (duplicate_thunk_for_node):
6545 (clone_function_name_1): Renamed.
6546 (clone_function_name_numbered): Two new functions.
6547 (clone_function_name): Improved documentation.
6548 (cgraph_node::create_virtual_clone): Use clone_function_name_numbered.
6549 * config/rs6000/rs6000.c (make_resolver_func): Ditto.
6550 * final.c (final_scan_insn_1): Use the new clone_function_name
6551 without numbering.
6552 * multiple_target.c (create_dispatcher_calls): Ditto.
6553 (create_target_clone): Ditto.
6554 * omp-expand.c (grid_expand_target_grid_body): Ditto.
6555 * omp-low.c (create_omp_child_function_name): Ditto.
6556 * omp-simd-clone.c (simd_clone_create): Ditto.
6557 * symtab.c (simd_symtab_node::noninterposable_alias): Use the
6558 new clone_function_name without numbering.
6559
6560 2018-10-30 Richard Earnshaw <rearnsha@arm.com>
6561
6562 * alloc-pool.h (base_pool_allocator <TBlockAllocator>::initialize):
6563 Assert that the allocation size is not zero.
6564
6565 2018-10-30 Richard Biener <rguenther@suse.de>
6566
6567 PR tree-optimization/87800
6568 * tree-vect-slp.c (vect_build_slp_tree_2): Reject any
6569 non-induction or reduction PHIs.
6570
6571 2018-10-30 Sameera Deshpande <sameera.deshpande@linaro.org>
6572
6573 * config/aarch64/falkor-tag-collision-avoidance.c
6574 (execute_tag_collision_avoidance): Call df_note_add_problem.
6575
6576 2018-10-30 Martin Liska <mliska@suse.cz>
6577
6578 * doc/extend.texi: Fix typo in documentation
6579 of __builtin_expect_with_probability.
6580
6581 2018-10-29 David Malcolm <dmalcolm@redhat.com>
6582
6583 PR c++/87721
6584 * input.c (get_substring_ranges_for_loc): Detect if
6585 linemap_resolve_location gives us a NULL map, and reject
6586 this case.
6587
6588 2018-10-29 Iain Buclaw <ibuclaw@gdcproject.org>
6589
6590 * config.gcc (xstormy16-*-elf): Set tm_d_file.
6591
6592 2018-10-29 David Malcolm <dmalcolm@redhat.com>
6593 Martin Sebor <msebor@redhat.com>
6594 Manuel Lopez-Ibanez <manu@gcc.gnu.org>
6595
6596 * doc/ux.texi (Quoting): New subsection, adapted from material at
6597 https://gcc.gnu.org/wiki/DiagnosticsGuidelines written by
6598 MartinSebor and ManuelLopezIbanez.
6599 (Fix-it hints): Note that fix-it hints shouldn't be marked for
6600 translation.
6601
6602 2018-10-29 Kugan Vivekanandarajah <kuganv@linaro.org>
6603
6604 PR middle-end/87469
6605 * tree-ssa-loop-niter.c (number_of_iterations_popcount): Fix niter
6606 max value.
6607
6608 2018-10-29 Paul A. Clarke <pc@us.ibm.com>
6609
6610 * gcc.target/powerpc/ssse3-check.h: Remove inaccurate comment.
6611
6612 2018-10-29 Paul Koning <ni1d@arrl.net>
6613
6614 * doc/rtl.texi (CONST_WIDE_INT_ELT): Give correct macro name.
6615
6616 2018-10-29 Paul A. Clarke <pc@us.ibm.com>
6617
6618 * gcc/config/rs6000/mmintrin.h (_mm_packs_pi16, _mm_packs_pi32,
6619 _mm_packs_pu16, _mm_unpackhi_pi8, _mm_unpacklo_pi8, _mm_add_pi8,
6620 _mm_add_pi16, _mm_add_pi32, _mm_sub_pi8, _mm_sub_pi16, _mm_sub_pi32,
6621 _mm_cmpgt_pi8, _mm_cmpeq_pi16, _mm_cmpgt_pi16, _mm_cmpeq_pi32,
6622 _mm_cmpgt_pi32, _mm_adds_pi8, _mm_adds_pi16, _mm_adds_pu8,
6623 _mm_adds_pu16, _mm_subs_pi8, _mm_subs_pi16, _mm_subs_pu8,
6624 _mm_subs_pu16, _mm_madd_pi16, _mm_mulhi_pi16, _mm_mullo_pi16,
6625 _mm_sll_pi16, _mm_sra_pi16, _mm_srl_pi16, _mm_set1_pi16, _mm_set1_pi8):
6626 Change 'vector' to '__vector'.
6627 * gcc/config/rs6000/xmmintrin.h (_mm_cvtps_pi32, _mm_cvttps_pi32,
6628 _mm_cvtps_pi16, _mm_cvtps_pi8, _mm_max_pi16, _mm_max_pu8, _mm_min_pi16,
6629 _mm_min_pu8, _mm_mulhi_pu16, _mm_shuffle_pi16, _mm_avg_pu8,
6630 _mm_avg_pu16): Likewise. And, whitespace corrections.
6631
6632 2018-10-29 Richard Biener <rguenther@suse.de>
6633
6634 PR tree-optimization/87785
6635 * tree-vect-slp.c (vect_gather_slp_loads): Only gather
6636 internal defs.
6637
6638 2018-10-29 Olivier Hainque <hainque@adacore.com>
6639
6640 * VXWORKS_NET_LIBS_RTP: New macro, network part of VXWORKS_LIBS_RTP.
6641
6642 2018-10-29 Olivier Hainque <hainque@adacore.com>
6643
6644 * config/vxworks.h (VXWORKS_PERSONALITY): New VxWorks
6645 ports configuration macro, defaults to "gnu".
6646 (VXWORKS_OS_CPP_BUILTINS): Use it. Feed TOOL and
6647 TOOL_FAMILY instead of _VX_TOOL/_VXTOOL_FAMILY.
6648
6649 2018-10-29 Olivier Hainque <hainque@adacore.com>
6650
6651 * config/vxworks.h (CLEAR_INSN_CACHE): #undef before #define.
6652
6653 2018-10-29 Richard Biener <rguenther@suse.de>
6654
6655 PR tree-optimization/87790
6656 * tree-vect-slp.c (vect_mark_slp_stmts): Simplify.
6657 (vect_make_slp_decision): Adjust.
6658 (vect_slp_analyze_bb_1): Likewise.
6659 (vect_detect_hybrid_slp_stmts): Properly union SLP type over
6660 edges.
6661
6662 2018-10-29 Richard Biener <rguenther@suse.de>
6663
6664 PR tree-optimization/87785
6665 * tree-vect-slp.c (vect_build_slp_tree_2): Remove loads argument
6666 and processing.
6667 (vect_build_slp_tree): Likewise.
6668 (vect_gather_slp_loads): New function.
6669 (vect_analyze_slp_instance): Gather loads separately from the
6670 SLP tree build.
6671
6672 2018-10-29 Martin Liska <mliska@suse.cz>
6673
6674 * Makefile.in: Make dependency to json.o.
6675 * doc/gcov.texi: Document new JSON format, remove
6676 old intermediate format documentation.
6677 * gcov.c (struct function_info): Come up with m_name and
6678 m_demangled_name.
6679 (function_info::function_info): Initialize it.
6680 (function_info::~function_info): Release it.
6681 (main): Rename flag_intermediate_format to flag_json_format.
6682 (print_usage): Describe --json-format.
6683 (process_args): Set flag_json_format.
6684 (output_intermediate_line): Remove.
6685 (output_intermediate_json_line): Likewise.
6686 (get_gcov_intermediate_filename): Return new extension
6687 ".gcov.json.gz".
6688 (output_intermediate_file): Implement JSON emission.
6689 (output_json_intermediate_file): Implement JSON emission.
6690 (generate_results): Use ::get_name for function name.
6691 Handle JSON output file.
6692 (read_graph_file): Use ::get_name instead of cplus_demangle.
6693 (read_count_file): Likewise.
6694 (solve_flow_graph): Likewise.
6695 (add_line_counts): Likewise.
6696 (accumulate_line_counts): Use new flag_json_format.
6697 (output_function_details): Use ::get_name instead of cplus_demangle.
6698 (output_lines): Likewise.
6699 * json.cc (test_writing_literals): Add new tests.
6700 * json.h (class literal): Add new boolean constructor.
6701
6702 2018-10-29 Segher Boessenkool <segher@kernel.crashing.org>
6703
6704 PR rtl-optimization/87701
6705 PR rtl-optimization/87780
6706 * combine.c (make_more_copies): Rewrite.
6707
6708 2018-10-28 Kugan Vivekanandarajah <kuganv@linaro.org>
6709
6710 * doc/generic.texi (ABSU_EXPR): Document.
6711 * match.pd (absu(x)*absu(x) -> x*x): Handle.
6712 (absu(absu(X)) -> absu(X)): Likewise.
6713 (absu(-X) -> absu(X)): Likewise.
6714 (absu(X) where X is nonnegative -> X): Likewise.
6715
6716 2018-10-28 Iain Buclaw <ibuclaw@gdcproject.org>
6717
6718 * Makefile.in (tm_d_file_list, tm_d_include_list): New variables.
6719 (TM_D_H, D_TARGET_DEF, D_TARGET_H, D_TARGET_OBJS): New variables.
6720 (tm_d.h, cs-tm_d.h, default-d.o): New rules.
6721 (d/d-target-hooks-def.h, s-d-target-hooks-def-h): New rules.
6722 (s-tm-texi): Also check timestamp on d-target.def.
6723 (generated_files): Add TM_D_H and d-target-hooks-def.h.
6724 (build/genhooks.o): Also depend on D_TARGET_DEF.
6725 * config.gcc (tm_d_file, d_target_objs, target_has_targetdm): New
6726 variables.
6727 * config/aarch64/aarch64-d.c: New file.
6728 * config/aarch64/aarch64-linux.h (GNU_USER_TARGET_D_CRITSEC_SIZE):
6729 Define.
6730 * config/aarch64/aarch64-protos.h (aarch64_d_target_versions): New
6731 prototype.
6732 * config/aarch64/aarch64.h (TARGET_D_CPU_VERSIONS): Define.
6733 * config/aarch64/t-aarch64 (aarch64-d.o): New rule.
6734 * config/arm/arm-d.c: New file.
6735 * config/arm/arm-protos.h (arm_d_target_versions): New prototype.
6736 * config/arm/arm.h (TARGET_D_CPU_VERSIONS): Define.
6737 * config/arm/linux-eabi.h (EXTRA_TARGET_D_OS_VERSIONS): Define.
6738 * config/arm/t-arm (arm-d.o): New rule.
6739 * config/default-d.c: New file.
6740 * config/glibc-d.c: New file.
6741 * config/gnu.h (GNU_USER_TARGET_D_OS_VERSIONS): Define.
6742 * config/i386/i386-d.c: New file.
6743 * config/i386/i386-protos.h (ix86_d_target_versions): New prototype.
6744 * config/i386/i386.h (TARGET_D_CPU_VERSIONS): Define.
6745 * config/i386/linux-common.h (EXTRA_TARGET_D_OS_VERSIONS): Define.
6746 (GNU_USER_TARGET_D_CRITSEC_SIZE): Define.
6747 * config/i386/t-i386 (i386-d.o): New rule.
6748 * config/kfreebsd-gnu.h (GNU_USER_TARGET_D_OS_VERSIONS): Define.
6749 * config/kopensolaris-gnu.h (GNU_USER_TARGET_D_OS_VERSIONS): Define.
6750 * config/linux-android.h (ANDROID_TARGET_D_OS_VERSIONS): Define.
6751 * config/linux.h (GNU_USER_TARGET_D_OS_VERSIONS): Define.
6752 * config/mips/linux-common.h (EXTRA_TARGET_D_OS_VERSIONS): Define.
6753 * config/mips/mips-d.c: New file.
6754 * config/mips/mips-protos.h (mips_d_target_versions): New prototype.
6755 * config/mips/mips.h (TARGET_D_CPU_VERSIONS): Define.
6756 * config/mips/t-mips (mips-d.o): New rule.
6757 * config/powerpcspe/linux.h (GNU_USER_TARGET_D_OS_VERSIONS): Define.
6758 * config/powerpcspe/linux64.h (GNU_USER_TARGET_D_OS_VERSIONS): Define.
6759 * config/powerpcspe/powerpcspe-d.c: New file.
6760 * config/powerpcspe/powerpcspe-protos.h (rs6000_d_target_versions):
6761 New prototype.
6762 * config/powerpcspe/powerpcspe.c (rs6000_output_function_epilogue):
6763 Support GNU D by using 0 as the language type.
6764 * config/powerpcspe/powerpcspe.h (TARGET_D_CPU_VERSIONS): Define.
6765 * config/powerpcspe/t-powerpcspe (powerpcspe-d.o): New rule.
6766 * config/riscv/riscv-d.c: New file.
6767 * config/riscv/riscv-protos.h (riscv_d_target_versions): New
6768 prototype.
6769 * config/riscv/riscv.h (TARGET_D_CPU_VERSIONS): Define.
6770 * config/riscv/t-riscv (riscv-d.o): New rule.
6771 * config/rs6000/linux.h (GNU_USER_TARGET_D_OS_VERSIONS): Define.
6772 * config/rs6000/linux64.h (GNU_USER_TARGET_D_OS_VERSIONS): Define.
6773 * config/rs6000/rs6000-d.c: New file.
6774 * config/rs6000/rs6000-protos.h (rs6000_d_target_versions): New
6775 prototype.
6776 * config/rs6000/rs6000.c (rs6000_output_function_epilogue):
6777 Support GNU D by using 0 as the language type.
6778 * config/rs6000/rs6000.h (TARGET_D_CPU_VERSIONS): Define.
6779 * config/rs6000/t-rs6000 (rs6000-d.o): New rule.
6780 * config/s390/s390-d.c: New file.
6781 * config/s390/s390-protos.h (s390_d_target_versions): New prototype.
6782 * config/s390/s390.h (TARGET_D_CPU_VERSIONS): Define.
6783 * config/s390/t-s390 (s390-d.o): New rule.
6784 * config/sparc/sparc-d.c: New file.
6785 * config/sparc/sparc-protos.h (sparc_d_target_versions): New
6786 prototype.
6787 * config/sparc/sparc.h (TARGET_D_CPU_VERSIONS): Define.
6788 * config/sparc/t-sparc (sparc-d.o): New rule.
6789 * config/t-glibc (glibc-d.o): New rule.
6790 * configure: Regenerated.
6791 * configure.ac (tm_d_file): New variable.
6792 (tm_d_file_list, tm_d_include_list, d_target_objs): Add substitutes.
6793 * doc/contrib.texi (Contributors): Add self for the D frontend.
6794 * doc/frontends.texi (G++ and GCC): Mention D as a supported language.
6795 * doc/install.texi (Configuration): Mention libphobos as an option for
6796 --enable-shared. Mention d as an option for --enable-languages.
6797 (Testing): Mention check-d as a target.
6798 * doc/invoke.texi (Overall Options): Mention .d, .dd, and .di as file
6799 name suffixes. Mention d as a -x option.
6800 * doc/sourcebuild.texi (Top Level): Mention libphobos.
6801 * doc/standards.texi (Standards): Add section on D language.
6802 * doc/tm.texi: Regenerated.
6803 * doc/tm.texi.in: Add @node for D language and ABI, and @hook for
6804 TARGET_CPU_VERSIONS, TARGET_D_OS_VERSIONS, and TARGET_D_CRITSEC_SIZE.
6805 * dwarf2out.c (is_dlang): New function.
6806 (gen_compile_unit_die): Use DW_LANG_D for D.
6807 (declare_in_namespace): Return module die for D, instead of adding
6808 extra declarations into the namespace.
6809 (gen_namespace_die): Generate DW_TAG_module for D.
6810 (gen_decl_die): Handle CONST_DECLSs for D.
6811 (dwarf2out_decl): Likewise.
6812 (prune_unused_types_walk_local_classes): Handle DW_tag_interface_type.
6813 (prune_unused_types_walk): Handle DW_tag_interface_type same as other
6814 kinds of aggregates.
6815 * gcc.c (default_compilers): Add entries for .d, .dd and .di.
6816 * genhooks.c: Include d/d-target.def.
6817
6818 2018-10-28 Iain Sandoe <iain@sandoe.co.uk>
6819
6820 PR target/85669
6821 * config/rs6000/darwin.h (STACK_BOUNDARY): New.
6822 (RS6000_STARTING_FRAME_OFFSET): Adjust to preserve 16byte alignment.
6823 (STACK_DYNAMIC_OFFSET): Likewise.
6824
6825 2018-10-27 Sandra Loosemore <sandra@codesourcery.com>
6826
6827 PR target/80024
6828 * config/nios2/nios2.c (nios2_valid_target_attribute_rec): Fix
6829 error message.
6830
6831 2018-10-26 Tulio Magno Quites Machado Filho <tuliom@linux.ibm.com>
6832
6833 * doc/extend.texi (PowerPC builtins): Fix __builtin_unpack_ibm128
6834 return type and other typos.
6835
6836 2018-10-26 Aaron Sawdey <acsawdey@linux.ibm.com>
6837
6838 * config/rs6000/rs6000-string.c (expand_strncmp_gpr_sequence): Change to
6839 a shorter sequence with fewer branches.
6840 (emit_final_str_compare_gpr): Ditto.
6841
6842 2018-10-26 Paul A. Clarke <pc@us.ibm.com>
6843
6844 * config/rs6000/tmmintrin.h: New file.
6845 * config.gcc (powerpc*-*-*): Add tmmintrin.h to extra_headers.
6846
6847 2018-10-26 Paul A. Clarke <pc@us.ibm.com>
6848
6849 * config/rs6000/mmintrin.h: Enable 32bit compilation.
6850 * config/rs6000/xmmintrin.h: Likewise.
6851
6852 2018-10-26 Paul A. Clarke <pc@us.ibm.com>
6853
6854 * config/rs6000/xmmintrin.h (_mm_extract_pi16): Fix for big-endian.
6855
6856 2018-10-26 Richard Biener <rguenther@suse.de>
6857
6858 * tree-vect-slp.c (vect_mark_slp_stmts): Add visited hash_set
6859 and wrapper.
6860 (vect_mark_slp_stmts_relevant): Likewise.
6861 (vect_detect_hybrid_slp_stmts): Likewise.
6862 (vect_bb_slp_scalar_cost): Likewise.
6863 (vect_remove_slp_scalar_calls): Likewise.
6864
6865 2018-10-26 Jan Hubicka <jh@suse.cz>
6866
6867 * ipa-devirt.c (odr_subtypes_equivalent_p): Fix recursion.
6868 (warn_types_mismatch): Fix walk of DECL_NAME.
6869 (odr_types_equivalent_p): Fix overactive assert.
6870
6871 2018-10-26 Richard Biener <rguenther@suse.de>
6872
6873 PR tree-optimization/87105
6874 * tree-vectorizer.h (_slp_tree::refcnt): New member.
6875 * tree-vect-slp.c (vect_free_slp_tree): Decrement and honor
6876 refcnt.
6877 (vect_create_new_slp_node): Initialize refcnt to one.
6878 (bst_traits): Move.
6879 (scalar_stmts_set_t, bst_fail): Remove.
6880 (vect_build_slp_tree_2): Add bst_map argument and adjust calls.
6881 (vect_build_slp_tree): Add bst_map argument and lookup
6882 already created SLP nodes.
6883 (vect_print_slp_tree): Handle a SLP graph, print SLP node
6884 addresses.
6885 (vect_slp_rearrange_stmts): Handle a SLP graph.
6886 (vect_analyze_slp_instance): Adjust and free SLP nodes from
6887 the CSE map. Fix indenting.
6888 (vect_schedule_slp_instance): Add short-cut.
6889
6890 2018-10-26 Martin Liska <mliska@suse.cz>
6891
6892 PR testsuite/86158
6893 * ipa-prop.c (struct ipa_vr_ggc_hash_traits): Hash with
6894 addr_expr and not with pointers.
6895
6896 2018-10-26 Jan Hubicka <jh@suse.cz>
6897
6898 * tree.c (free_lang_data_in_type): Only check main variants.
6899 * ipa-devirt.c (warn_odr): Make static.
6900 (types_same_for_odr): Drop strict variant.
6901 (types_odr_comparable): Likewise.
6902 (odr_or_derived_type_p): Look for main variants.
6903 (odr_name_hasher::equal): Cleanup comment.
6904 (odr_subtypes_equivalent): Add warn and warned arguments; check main
6905 variants.
6906 (type_variants_equivalent_p): break out from ...
6907 (odr_types_equivalent): ... here; go for main variants where needed.
6908 (warn_odr): ... here; turn static.
6909 (warn_types_mismatch): Compare mangled names of main variants.
6910 * ipa-utils.h (types_odr_comparable): Drop strict parameter.
6911 (type_with_linkage_p): Sanity check that we look at main variant.
6912 * lto.c (lto_read_decls): Only consider main variant to be ODR type.
6913 * tree.h (types_same_for_odr): Drop strict argument.
6914
6915 2018-10-26 Richard Biener <rguenther@suse.de>
6916
6917 PR tree-optimization/87746
6918 * tree-vect-data-refs.c (vect_update_misalignment_for_peel):
6919 Simplify and fix WRT strided store groups with size not
6920 equal to step in element count.
6921 (vect_analyze_group_access_1): Dump the whole group.
6922
6923 2018-10-25 Carl Love <cel@us.ibm.com>
6924
6925 * config/rs6000/rs6000-c.c (P9V_BUILTIN_VEC_VSCEDPGT,
6926 P9V_BUILTIN_VEC_VSCEDPLT, P9V_BUILTIN_VEC_VSCEDPEQ,
6927 P9V_BUILTIN_VEC_VSCEDPUO): Rename base overloaded name. Add quad
6928 precicion entry for each overloaded builtin.
6929 * config/rs6000/rs6000-builtin.def (VSCEDPGT, VSCEDPLT, VSCEDPEQ,
6930 VSCEDPUO): Rename overloaded name.
6931 (VSCEDPGT, VSCEQPGT, VSCEDPLT, VSCEQPLT, VSCEDPEQ, VSCEQPEQ,
6932 VSCEDPUO, VSCEQPUO): Add defitions for overloaded builtins.
6933 * config/rs6000/vsx.md (xscmpexpqp_<code>_<mode>): Add
6934 define_expand for xscmpexqp instruction.
6935 (*xscmpexpqp): Add define_insn for the xscmpexqp instruction.
6936
6937 2018-10-25 Bill Schmidt <wschmidt@linux.ibm.com>
6938 Jinsong Ji <jji@us.ibm.com>
6939
6940 * config/rs6000/emmintrin.h (_mm_slli_epi16): Replace deprecated
6941 function with vec_sl.
6942 (_mm_slli_epi32): Likewise.
6943 (_mm_slli_epi64): Likewise.
6944 (_mm_srai_epi16): Replace deprecated function with vec_sra.
6945 (_mm_srai_epi32): Likewise.
6946 (_mm_srli_epi16): Replace deprecated function with vec_sr.
6947 (_mm_srli_epi32): Likewise.
6948 (_mm_srli_epi64): Likewise.
6949 (_mm_sll_epi16): Replace deprecated function with vec_sl.
6950 (_mm_sll_epi32): Likewise.
6951 (_mm_sll_epi64): Likewise.
6952 (_mm_sra_epi16): Replace deprecated function with vec_sra.
6953 (_mm_sra_epi32): Likewise.
6954 (_mm_srl_epi16): Replace deprecated function with vec_sr.
6955 (_mm_srl_epi32): Likewise.
6956 (_mm_srl_epi64): Likewise.
6957
6958 2018-10-25 Bill Schmidt <wschmidt@linux.ibm.com>
6959 Jinsong Ji <jji@us.ibm.com>
6960
6961 * gcc/config/rs6000/emmintrin.h (_mm_sll_epi16): Replace
6962 comparison operators with vec_cmp* for compatibility due to
6963 unfortunate history; clean up formatting and use types more
6964 appropriately.
6965 (_mm_sll_epi32): Likewise.
6966 (_mm_sll_epi64): Likewise.
6967 (_mm_srl_epi16): Likewise.
6968 (_mm_srl_epi32): Likewise.
6969 (_mm_srl_epi64): Likewise.
6970
6971 2018-10-25 Bill Schmidt <wschmidt@linux.ibm.com>
6972 Jinsong Ji <jji@us.ibm.com>
6973
6974 * config/rs6000/emmintrin.h (_mm_sll_epi64): Remove wrong cast.
6975 * config/rs6000/xmmintrin.h (_mm_min_ps): Change m's type to
6976 __vector __bool int. Use vec_cmpgt in preference to deprecated
6977 function vec_vcmpgtfp.
6978 (_mm_max_ps): Likewise.
6979
6980 2018-10-25 Jeff Law <law@redhat.com>
6981
6982 * config/rl78/rl78.c (insn_ok_now): Always re-recognize the insn
6983 if returning false.
6984
6985 2018-10-25 Martin Sebor <msebor@redhat.com>
6986
6987 * doc/extend.texi (aligned): Expand attribute description.
6988 (Alignment): Rename section. Discuss function arguments.
6989
6990 2018-10-25 Jan Hubicka <jh@suse.cz>
6991
6992 * ipa-devirt.c (main_odr_variant): Remove.
6993 (hash_odr_name, types_same_for_odr, types_odr_comparable,
6994 odr_name_hasher::equal, odr_subtypes_equivalent_p):
6995 Drop use of main_odr_variant.
6996 (add_type_duplicate): Silence confused warnings on integer types.
6997 (get_odr_type): Always look for main variant.
6998 (register_odr_type): Simplify.
6999
7000 2018-10-25 Richard Biener <rguenther@suse.de>
7001
7002 * tree-vect-data-refs.c (vect_analyze_data_ref_accesses):
7003 Initialize ng to silence error with release checking bootstrap.
7004
7005 2018-10-25 Richard Biener <rguenther@suse.de>
7006
7007 * tree-if-conv.c: Include tree-ssa-sccvn.h.
7008 (tree_if_conversion): Run CSE on the if-converted loop body.
7009
7010 2018-10-25 Ilya Leoshkevich <iii@linux.ibm.com>
7011
7012 * config/s390/constraints.md (ZL): New constraint.
7013 * config/s390/s390.c (legitimate_pic_operand_p): Accept LARL
7014 operands.
7015 * config/s390/s390.md (movdi_larl): Remove.
7016 (movdi_64): Add the LARL alternative.
7017
7018 2018-10-25 Ilya Leoshkevich <iii@linux.ibm.com>
7019
7020 PR bootstrap/87747
7021 * rtl.c (RTX_CODE_HWINT_P_1): New helper macro.
7022 (RTX_CODE_HWINT_P): New macro.
7023 (rtx_code_size): Use RTX_CODE_HWINT_P ().
7024
7025 2018-10-25 Jan Hubicka <jh@suse.cz>
7026
7027 * ipa-devirt.c (odr_types_equivalent_p): Do not ICE if one of types
7028 is anonymous.
7029
7030 2018-10-25 Richard Biener <rguenther@suse.de>
7031
7032 PR tree-optimization/87665
7033 PR tree-optimization/87745
7034 * tree-vectorizer.h (get_earlier_stmt): Remove.
7035 (get_later_stmt): Pick up UID from the original non-pattern stmt.
7036
7037 2018-10-25 Sam Tebbs <sam.tebbs@arm.com>
7038
7039 * options.texi (Deprecated): Move list to Var section.
7040
7041 2018-10-24 Bill Schmidt <wschmidt@linux.ibm.com>
7042 Jinsong Ji <jji@us.ibm.com>
7043
7044 * config/rs6000/emmintrin.h (_mm_cvtpd_epi32): Change deprecated
7045 __vector long to __vector long long.
7046 (_mm_cvtpd_ps): Likewise.
7047 (_mm_cvttpd_epi32): Likewise.
7048 (_mm_cvtpi32_pd): Likewise.
7049 (_mm_unpackhi_epi64): Likewise.
7050 (_mm_unpacklo_epi64): Likewise.
7051
7052 2018-10-24 Segher Boessenkool <segher@kernel.crashing.org>
7053
7054 PR rtl-optimization/87720
7055 * combine.c (make_more_copies): Skip if the dest is pc_rtx.
7056
7057 2018-10-24 Alexandre Oliva <aoliva@redhat.com>
7058
7059 * gimple-ssa-isolate-paths.c
7060 (find_implicit_erroneous_behavior): Do not change code if the
7061 pass is running for warnings only.
7062 (find_explicit_erroneous_behavior): Likewise.
7063
7064 2018-10-24 Michael Meissner <meissner@linux.ibm.com>
7065
7066 * config/rs6000/rs6000.c (TARGET_MANGLE_DECL_ASSEMBLER_NAME):
7067 Define as rs6000_mangle_decl_assembler_name.
7068 (rs6000_mangle_decl_assembler_name): If the user switched from IBM
7069 long double to IEEE long double, switch the names of the long
7070 double built-in functions to be <func>f128 instead of <func>l.
7071
7072 2018-10-24 Martin Sebor <msebor@redhat.com>
7073
7074 * doc/extend.texi (nonnull): List no-argument form. Reference
7075 -fno-delete-null-pointer-checks and -fisolate-erroneous-paths-attribute.
7076
7077 2018-10-24 Richard Biener <rguenther@suse.de>
7078
7079 * tree-ssa-sccvn.c (do_rpo_vn): Free rpo_state.
7080
7081 2018-10-24 Martin Liska <mliska@suse.cz>
7082
7083 PR tree-optimization/84436
7084 * tree-switch-conversion.c (switch_conversion::contains_same_values_p):
7085 Remove.
7086 (switch_conversion::contains_linear_function_p): New.
7087 (switch_conversion::build_one_array): Support linear
7088 transformation on input.
7089 * tree-switch-conversion.h (struct switch_conversion): Add
7090 contains_linear_function_p declaration.
7091
7092 2018-10-24 Richard Biener <rguenther@suse.de>
7093
7094 * varasm.c (const_hash_1): Return hash of ADDR_EXPR
7095 if its argument is CONSTANT_CLASS_P.
7096
7097 2018-10-11 Jan Hubicka <hubicka@ucw.cz>
7098
7099 * ipa-utils.h (type_with_linkage_p): No longer check for TYPE_STUB_DECL;
7100 it is wrong for forward declarations.
7101
7102 2018-10-24 Ilya Leoshkevich <iii@linux.ibm.com>
7103
7104 * config/s390/s390.c (s390_check_qrst_address): Add the missing
7105 SYMBOL_REF_P () check.
7106
7107 2018-10-24 Richard Biener <rguenther@suse.de>
7108
7109 PR tree-optimization/87105
7110 * tree-vect-data-refs.c (vect_analyze_group_access_1): Adjust
7111 dump classification.
7112 (vect_analyze_data_ref_accesses): Handle duplicate loads and
7113 stores by splitting the affected group after the fact.
7114 * tree-vect-slp.c (vect_build_slp_tree_2): Dump when we
7115 fail the SLP build because of size constraints.
7116
7117 2018-10-24 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
7118
7119 * configure.ac (gcc_cv_ld_aligned_shf_merge): New test.
7120 * configure: Regenerate.
7121 * config.in: Regenerate.
7122 * varasm.c (mergeable_string_section): Use readonly_data_section
7123 if linker doesn't support SHF_MERGE with alignment > 8.
7124 (mergeable_constant_section): Likewise.
7125
7126 2018-10-24 Richard Biener <rguenther@suse.de>
7127
7128 PR tree-optimization/84013
7129 * tree-ssa-structalias.c (struct msdi_data): New struct for
7130 marshalling data to walk_stmt_load_store_ops.
7131 (maybe_set_dependence_info): Refactor as callback for
7132 walk_stmt_load_store_ops.
7133 (compute_dependence_clique): Set restrict info on all stmt kinds.
7134
7135 2018-10-24 Martin Liska <mliska@suse.cz>
7136
7137 * cgraph.c (cgraph_node::dump):
7138 Remove reduntant dumps and make tp_first_run dump more compact.
7139
7140 2018-10-24 Richard Biener <rguenther@suse.de>
7141
7142 PR tree-optimization/87665
7143 * tree-vect-data-refs.c (vect_preserves_scalar_order_p): Adjust
7144 to reflect reality.
7145
7146 2018-10-12 Jeff Law <law@redhat.com>
7147
7148 * config/h8300/h8300.c (h8300_expand_prologue): Fix stm generation
7149 for H8/S.
7150
7151 2018-10-23 Richard Biener <rguenther@suse.de>
7152
7153 * tree-vrp.c (add_assert_info): Guard dump_printf with
7154 dump_enabled_p.
7155 * gimple-ssa-evrp-analyze.c
7156 (evrp_range_analyzer::record_ranges_from_incoming_edge):
7157 Use value_range::ignore_equivs_equal_p.
7158
7159 2018-10-23 Richard Biener <rguenther@suse.de>
7160
7161 PR tree-optimization/87105
7162 PR tree-optimization/87608
7163 * passes.def (pass_all_early_optimizations): Add early phi-opt
7164 after dce.
7165 * tree-ssa-phiopt.c (value_replacement): Ignore NOPs and predicts in
7166 addition to debug stmts.
7167 (tree_ssa_phiopt_worker): Add early_p argument, do only min/max
7168 and abs replacement early.
7169 * tree-cfg.c (gimple_empty_block_p): Likewise.
7170
7171 2018-10-23 Richard Earnshaw <rearnsha@arm.com>
7172
7173 PR target/86383
7174 * config.gcc (arm*-*-netbsdelf*): Default to StrongARM if no CPU
7175 specified to configure.
7176 (arm*-*-*): Use ARM7TDMI as the target CPU if no default provided.
7177
7178 2018-10-23 Richard Biener <rguenther@suse.de>
7179
7180 PR tree-optimization/87700
7181 * tree-ssa-copy.c (set_copy_of_val): Fix change detection logic.
7182
7183 2018-10-23 Jakub Jelinek <jakub@redhat.com>
7184
7185 PR target/87674
7186 * config/i386/avx512vlintrin.h (_mm_mask_mullo_epi32): Change type of
7187 second argument from __mmask16 to __mmask8.
7188 * config/i386/avx512vlbwintrin.h (_mm_mask_packus_epi32,
7189 _mm_mask_packs_epi32): Likewise.
7190 * config/i386/avx512pfintrin.h (_mm512_mask_prefetch_i64scatter_ps):
7191 Likewise.
7192 (_mm512_mask_prefetch_i64scatter_pd): Likewise. Formatting fix.
7193
7194 2018-10-23 Richard Biener <rguenther@suse.de>
7195
7196 * tree-vect-stmts.c (vect_analyze_stmt): Fix typo in comment.
7197
7198 2018-10-23 Richard Biener <rguenther@suse.de>
7199
7200 PR tree-optimization/86144
7201 * tree-vect-stmts.c (vect_analyze_stmt): Prefer -mveclibabi
7202 over simd attribute.
7203
7204 2018-10-23 Richard Biener <rguenther@suse.de>
7205
7206 PR tree-optimization/87693
7207 * tree-ssa-threadedge.c (thread_around_empty_blocks): Handle
7208 the case we do not find the taken edge.
7209
7210 2018-10-22 Bill Schmidt <wschmidt@linux.ibm.com>
7211 Jinsong Ji <jji@us.ibm.com>
7212
7213 * config/rs6000/emmintrin.h (_MM_SHUFFLE2): Comment cleanup.
7214 (_mm_store_pd): Use unaligned vector type for pointer cast.
7215 (_mm_maskmoveu_si128): Likewise.
7216 * config/rs6000/xmmintrin.h (__m128_u): New typedef.
7217 (_mm_store_ps): Use unaligned vector type for pointer cast.
7218
7219 2018-10-22 Paul Koning <ni1d@arrl.net>
7220
7221 * symtab.c (symtab_node::increase_alignment): Correct max
7222 alignment check.
7223
7224 2018-10-22 Yury Gribov <tetra2005@gmail.com>
7225
7226 PR tree-optimization/87633
7227 * match.pd: Do not generate unordered integer comparisons.
7228
7229 2018-10-22 Segher Boessenkool <segher@kernel.crashing.org>
7230
7231 PR rtl-optimization/87600
7232 * combine.c: Add include of expr.h.
7233 (cant_combine_insn_p): Do not combine moves from any hard non-fixed
7234 register to a pseudo.
7235 (make_more_copies): New function, add a copy to a new pseudo after
7236 the moves from hard registers into pseudos.
7237 (rest_of_handle_combine): Declare rebuild_jump_labels_after_combine
7238 later. Call make_more_copies.
7239
7240 2018-10-22 Andrew Stubbs <ams@codesourcery.com>
7241
7242 * lra-constraints.c (process_alt_operands): New local array,
7243 matching_early_clobber. Check matching_early_clobber before
7244 decrementing reject, and set matching_early_clobber after.
7245
7246 2018-10-22 Segher Boessenkool <segher@kernel.crashing.org>
7247
7248 PR target/87598
7249 * config/rs6000/rs6000.c (print_operand_address): For unexpected RTL
7250 call output_addr_const and hope for the best.
7251
7252 2018-10-22 Richard Biener <rguenther@suse.de>
7253
7254 * gimple-ssa-evrp-analyze.c
7255 (evrp_range_analyzer::record_ranges_from_incoming_edge): Be
7256 smarter about what ranges to use.
7257 * tree-vrp.c (add_assert_info): Dump here.
7258 (register_edge_assert_for_2): Instead of here at multiple but
7259 not all places.
7260
7261 * gcc.dg/tree-ssa/evrp12.c: New testcase.
7262 * gcc.dg/predict-6.c: Adjust.
7263 * gcc.dg/tree-ssa/vrp33.c: Disable EVRP.
7264 * gcc.dg/tree-ssa/vrp02.c: Likewise.
7265 * gcc.dg/tree-ssa/cunroll-9.c: Likewise.
7266
7267 2018-10-22 Steven Bosscher <steven@gcc.gnu.org>
7268 Richard Biener <rguenther@suse.de>
7269
7270 * bitmap.h: Update data structure documentation, including a
7271 description of bitmap views as either linked-lists or splay trees.
7272 (struct bitmap_element_def): Update comments for splay tree bitmaps.
7273 (struct bitmap_head_def): Likewise.
7274 (bitmap_list_view, bitmap_tree_view): New prototypes.
7275 (bitmap_initialize_stat): Initialize a bitmap_head's indx and
7276 tree_form fields.
7277 (bmp_iter_set_init): Assert the iterated bitmaps are in list form.
7278 (bmp_iter_and_init, bmp_iter_and_compl_init): Likewise.
7279 * bitmap.c (bitmap_elem_to_freelist): Unregister overhead of a
7280 released bitmap element here.
7281 (bitmap_element_free): Remove.
7282 (bitmap_elt_clear_from): Work on splay tree bitmaps.
7283 (bitmap_list_link_element): Renamed from bitmap_element_link. Move
7284 this function similar ones such that linked-list bitmap implementation
7285 functions are grouped.
7286 (bitmap_list_unlink_element): Renamed from bitmap_element_unlink,
7287 and moved for grouping.
7288 (bitmap_list_insert_element_after): Renamed from
7289 bitmap_elt_insert_after, and moved for grouping.
7290 (bitmap_list_find_element): New function spliced from bitmap_find_bit.
7291 (bitmap_tree_link_left, bitmap_tree_link_right,
7292 bitmap_tree_rotate_left, bitmap_tree_rotate_right, bitmap_tree_splay,
7293 bitmap_tree_link_element, bitmap_tree_unlink_element,
7294 bitmap_tree_find_element): New functions for splay-tree bitmap
7295 implementation.
7296 (bitmap_element_link, bitmap_element_unlink, bitmap_elt_insert_after):
7297 Renamed and moved, see above entries.
7298 (bitmap_tree_listify_from): New function to convert part of a splay
7299 tree bitmap to a linked-list bitmap.
7300 (bitmap_list_view): Convert a splay tree bitmap to linked-list form.
7301 (bitmap_tree_view): Convert a linked-list bitmap to splay tree form.
7302 (bitmap_find_bit): Remove.
7303 (bitmap_clear, bitmap_clear_bit, bitmap_set_bit,
7304 bitmap_single_bit_set_p, bitmap_first_set_bit, bitmap_last_set_bit):
7305 Handle splay tree bitmaps.
7306 (bitmap_copy, bitmap_count_bits, bitmap_and, bitmap_and_into,
7307 bitmap_elt_copy, bitmap_and_compl, bitmap_and_compl_into,
7308 bitmap_compl_and_into, bitmap_elt_ior, bitmap_ior, bitmap_ior_into,
7309 bitmap_xor, bitmap_xor_into, bitmap_equal_p, bitmap_intersect_p,
7310 bitmap_intersect_compl_p, bitmap_ior_and_compl,
7311 bitmap_ior_and_compl_into, bitmap_set_range, bitmap_clear_range,
7312 bitmap_hash): Reject trying to act on splay tree bitmaps. Make
7313 corresponding changes to use linked-list specific bitmap_element
7314 manipulation functions as applicable for efficiency.
7315 (bitmap_tree_to_vec): New function.
7316 (debug_bitmap_elt_file): New function split out from ...
7317 (debug_bitmap_file): ... here. Handle splay tree bitmaps.
7318 (bitmap_print): Likewise.
7319
7320 PR tree-optimization/63155
7321 * tree-ssa-propagate.c (ssa_prop_init): Use tree-view for the
7322 SSA edge worklists.
7323 * tree-ssa-coalesce.c (coalesce_ssa_name): Populate used_in_copies
7324 in tree-view.
7325
7326 2018-10-22 Martin Liska <mliska@suse.cz>
7327
7328 PR tree-optimization/87686
7329 Revert
7330 2018-08-29 Martin Liska <mliska@suse.cz>
7331
7332 * tree-switch-conversion.c (switch_conversion::expand):
7333 Strenghten assumption about gswitch statements.
7334
7335 2018-10-22 Martin Liska <mliska@suse.cz>
7336
7337 * ipa-icf.c (sem_item::compare_attributes): Remove.
7338 (sem_item::compare_referenced_symbol_properties): Use
7339 attribute_list_equal instead.
7340 (sem_function::equals_wpa): Likewise.
7341 * ipa-icf.h: Remove compare_attributes.
7342
7343 2018-10-22 Richard Biener <rguenther@suse.de>
7344
7345 PR middle-end/87682
7346 * mem-stats.h (mem_usage::operator==): Fix pasto.
7347
7348 2018-10-22 Richard Biener <rguenther@suse.de>
7349
7350 PR tree-optimization/87640
7351 * tree-vrp.c (set_value_range_with_overflow): Decompose
7352 incomplete result.
7353 (extract_range_from_binary_expr_1): Adjust.
7354
7355 2018-10-22 Martin Jambor <mjambor@suse.cz>
7356
7357 * tree-eh.h (stmt_could_throw_p): Add function parameter.
7358 (stmt_can_throw_external): Likewise.
7359 (stmt_can_throw_internal): Likewise.
7360 * tree-eh.c (lower_eh_constructs_2): Pass cfun to stmt_could_throw_p.
7361 (lower_eh_constructs_2): Likewise.
7362 (stmt_could_throw_p): Add fun parameter, use it instead of cfun.
7363 (stmt_can_throw_external): Likewise.
7364 (stmt_can_throw_internal): Likewise.
7365 (maybe_clean_eh_stmt_fn): Pass cfun to stmt_could_throw_p.
7366 (maybe_clean_or_replace_eh_stmt): Pass cfun to stmt_could_throw_p.
7367 (maybe_duplicate_eh_stmt_fn): Pass new_fun to stmt_could_throw_p.
7368 (maybe_duplicate_eh_stmt): Pass cfun to stmt_could_throw_p.
7369 (pass_lower_eh_dispatch::execute): Pass cfun to
7370 stmt_can_throw_external.
7371 (cleanup_empty_eh): Likewise.
7372 (verify_eh_edges): Pass cfun to stmt_could_throw_p.
7373 * cgraph.c (cgraph_edge::set_call_stmt): Pass a function to
7374 stmt_can_throw_external instead of pushing it to cfun.
7375 (symbol_table::create_edge): Likewise.
7376 * gimple-fold.c (fold_builtin_atomic_compare_exchange): Pass cfun to
7377 stmt_can_throw_internal.
7378 * gimple-ssa-evrp.c (evrp_dom_walker::before_dom_children): Pass cfun
7379 to stmt_could_throw_p.
7380 * gimple-ssa-store-merging.c (handled_load): Pass cfun to
7381 stmt_can_throw_internal.
7382 (pass_store_merging::execute): Likewise.
7383 * gimple-ssa-strength-reduction.c
7384 (find_candidates_dom_walker::before_dom_children): Pass cfun to
7385 stmt_could_throw_p.
7386 * gimplify-me.c (gimple_regimplify_operands): Pass cfun to
7387 stmt_can_throw_internal.
7388 * ipa-pure-const.c (check_call): Pass cfun to stmt_could_throw_p and
7389 to stmt_can_throw_external.
7390 (check_stmt): Pass cfun to stmt_could_throw_p.
7391 (check_stmt): Pass cfun to stmt_can_throw_external.
7392 (pass_nothrow::execute): Likewise.
7393 * trans-mem.c (expand_call_tm): Pass cfun to stmt_can_throw_internal.
7394 * tree-cfg.c (is_ctrl_altering_stmt): Pass cfun to
7395 stmt_can_throw_internal.
7396 (verify_gimple_in_cfg): Pass cfun to stmt_could_throw_p.
7397 (stmt_can_terminate_bb_p): Pass cfun to stmt_can_throw_external.
7398 (gimple_purge_dead_eh_edges): Pass cfun to stmt_can_throw_internal.
7399 * tree-complex.c (expand_complex_libcall): Pass cfun to
7400 stmt_could_throw_p and to stmt_can_throw_internal.
7401 (expand_complex_multiplication): Pass cfun to stmt_can_throw_internal.
7402 * tree-inline.c (copy_edges_for_bb): Likewise.
7403 (maybe_move_debug_stmts_to_successors): Likewise.
7404 * tree-outof-ssa.c (ssa_is_replaceable_p): Pass cfun to
7405 stmt_could_throw_p.
7406 * tree-parloops.c (oacc_entry_exit_ok_1): Likewise.
7407 * tree-sra.c (scan_function): Pass cfun to stmt_can_throw_external.
7408 * tree-ssa-alias.c (stmt_kills_ref_p): Pass cfun to
7409 stmt_can_throw_internal.
7410 * tree-ssa-ccp.c (optimize_atomic_bit_test_and): Likewise.
7411 * tree-ssa-dce.c (mark_stmt_if_obviously_necessary): Pass cfun to
7412 stmt_could_throw_p.
7413 (mark_aliased_reaching_defs_necessary_1): Pass cfun to
7414 stmt_can_throw_internal.
7415 * tree-ssa-forwprop.c (pass_forwprop::execute): Likewise.
7416 * tree-ssa-loop-im.c (movement_possibility): Pass cfun to
7417 stmt_could_throw_p.
7418 * tree-ssa-loop-ivopts.c (find_givs_in_stmt_scev): Likewise.
7419 (add_autoinc_candidates): Pass cfun to stmt_can_throw_internal.
7420 * tree-ssa-math-opts.c (pass_cse_reciprocals::execute): Likewise.
7421 (convert_mult_to_fma_1): Likewise.
7422 (convert_to_divmod): Likewise.
7423 * tree-ssa-phiprop.c (propagate_with_phi): Likewise.
7424 * tree-ssa-pre.c (compute_avail): Pass cfun to stmt_could_throw_p.
7425 * tree-ssa-propagate.c
7426 (substitute_and_fold_dom_walker::before_dom_children): Likewise.
7427 * tree-ssa-reassoc.c (suitable_cond_bb): Likewise.
7428 (maybe_optimize_range_tests): Likewise.
7429 (linearize_expr_tree): Likewise.
7430 (reassociate_bb): Likewise.
7431 * tree-ssa-sccvn.c (copy_reference_ops_from_call): Likewise.
7432 * tree-ssa-scopedtables.c (hashable_expr_equal_p): Likewise.
7433 * tree-ssa-strlen.c (adjust_last_stmt): Likewise.
7434 (handle_char_store): Likewise.
7435 * tree-vect-data-refs.c (vect_find_stmt_data_reference): Pass cfun to
7436 stmt_can_throw_internal.
7437 * tree-vect-patterns.c (check_bool_pattern): Pass cfun to
7438 stmt_could_throw_p.
7439 * tree-vect-stmts.c (vect_finish_stmt_generation_1): Likewise.
7440 (vectorizable_call): Pass cfun to stmt_can_throw_internal.
7441 (vectorizable_simd_clone_call): Likewise.
7442 * value-prof.c (gimple_ic): Pass cfun to stmt_could_throw_p.
7443 (gimple_stringop_fixed_value): Likewise.
7444
7445 2018-10-22 Ilya Leoshkevich <iii@linux.ibm.com>
7446
7447 * config/s390/s390.c (s390_loadrelative_operand_p): Accept
7448 literal pool references.
7449 (s390_check_qrst_address): Adapt to the new behavior of
7450 s390_loadrelative_operand_p ().
7451
7452 2018-10-22 H.J. Lu <hongjiu.lu@intel.com>
7453
7454 PR target/72782
7455 * config/i386/sse.md (*andnot<mode>3_bcst): New.
7456
7457 2018-10-22 H.J. Lu <hongjiu.lu@intel.com>
7458
7459 PR target/72782
7460 * config/i386/sse.md (*<code><mode>3_bcst): New.
7461
7462 2018-10-22 H.J. Lu <hongjiu.lu@intel.com>
7463
7464 PR target/72782
7465 * config/i386/sse.md (avx512bcst): Updated for V4SI, V2DI, V8SI,
7466 V4DI, V16SI and V8DI.
7467 (*sub<mode>3<mask_name>_bcst): New.
7468 (*add<mode>3<mask_name>_bcst): Likewise.
7469
7470 2018-10-21 Bill Schmidt <wschmidt@linux.ibm.com>
7471 Jinsong Ji <jji@us.ibm.com>
7472
7473 * config/rs6000/emmintrin.h (_mm_movemask_pd): Replace __vector
7474 __m64 with __vector unsigned long long for compatibility.
7475 (_mm_movemask_epi8): Likewise.
7476 * config/rs6000/xmmintrin.h (_mm_cvtps_pi32): Likewise.
7477 (_mm_cvttps_pi32): Likewise.
7478 (_mm_cvtpi32_ps): Likewise.
7479 (_mm_cvtps_pi16): Likewise.
7480 (_mm_loadh_pi): Likewise.
7481 (_mm_storeh_pi): Likewise.
7482 (_mm_movehl_ps): Likewise.
7483 (_mm_movelh_ps): Likewise.
7484 (_mm_loadl_pi): Likewise.
7485 (_mm_storel_pi): Likewise.
7486 (_mm_movemask_ps): Likewise.
7487 (_mm_shuffle_pi16): Likewise.
7488
7489 2018-10-21 H.J. Lu <hongjiu.lu@intel.com>
7490
7491 PR target/72782
7492 * config/i386/avx512fintrin.h (_mm512_fnmsub_round_pd): Use
7493 __builtin_ia32_vfnmsubpd512_mask.
7494 (_mm512_mask_fnmsub_round_pd): Likewise.
7495 (_mm512_fnmsub_pd): Likewise.
7496 (_mm512_mask_fnmsub_pd): Likewise.
7497 (_mm512_maskz_fnmsub_round_pd): Use
7498 __builtin_ia32_vfnmsubpd512_maskz.
7499 (_mm512_maskz_fnmsub_pd): Likewise.
7500 (_mm512_fnmsub_round_ps): Use __builtin_ia32_vfnmsubps512_mask.
7501 (_mm512_mask_fnmsub_round_ps): Likewise.
7502 (_mm512_fnmsub_ps): Likewise.
7503 (_mm512_mask_fnmsub_ps): Likewise.
7504 (_mm512_maskz_fnmsub_round_ps): Use
7505 __builtin_ia32_vfnmsubps512_maskz.
7506 (_mm512_maskz_fnmsub_ps): Likewise.
7507 * config/i386/avx512vlintrin.h (_mm256_mask_fnmsub_pd): Use
7508 __builtin_ia32_vfnmsubpd256_mask.
7509 (_mm256_maskz_fnmsub_pd): Use __builtin_ia32_vfnmsubpd256_maskz.
7510 (_mm_mask_fnmsub_pd): Use __builtin_ia32_vfmaddpd128_mask
7511 (_mm_maskz_fnmsub_pd): Use __builtin_ia32_vfnmsubpd128_maskz.
7512 (_mm256_mask_fnmsub_ps): Use __builtin_ia32_vfnmsubps256_mask.
7513 (_mm256_mask_fnmsub_ps): Use __builtin_ia32_vfnmsubps256_mask.
7514 (_mm256_maskz_fnmsub_ps): Use __builtin_ia32_vfnmsubps256_maskz.
7515 (_mm_mask_fnmsub_ps): Use __builtin_ia32_vfnmsubps128_mask.
7516 (_mm_maskz_fnmsub_ps): Use __builtin_ia32_vfnmsubps128_maskz.
7517 * config/i386/fmaintrin.h (_mm_fnmsub_pd): Use
7518 __builtin_ia32_vfnmsubpd.
7519 (_mm256_fnmsub_pd): Use __builtin_ia32_vfnmsubpd256.
7520 (_mm_fnmsub_ps): Use __builtin_ia32_vfnmsubps.
7521 (_mm256_fnmsub_ps): Use __builtin_ia32_vfnmsubps256.
7522 (_mm_fnmsub_sd): Use __builtin_ia32_vfnmsubsd3.
7523 (_mm_fnmsub_ss): Use __builtin_ia32_vfnmsubss3.
7524 * config/i386/i386-builtin.def: Add
7525 __builtin_ia32_vfnmsubpd256_mask,
7526 __builtin_ia32_vfnmsubpd256_maskz,
7527 __builtin_ia32_vfnmsubpd128_mask,
7528 __builtin_ia32_vfnmsubpd128_maskz,
7529 __builtin_ia32_vfnmsubps256_mask,
7530 __builtin_ia32_vfnmsubps256_maskz,
7531 __builtin_ia32_vfnmsubps128_mask,
7532 __builtin_ia32_vfnmsubps128_maskz,
7533 __builtin_ia32_vfnmsubpd512_mask,
7534 __builtin_ia32_vfnmsubpd512_maskz,
7535 __builtin_ia32_vfnmsubps512_mask,
7536 __builtin_ia32_vfnmsubps512_maskz, __builtin_ia32_vfnmsubss3,
7537 __builtin_ia32_vfnmsubsd3, __builtin_ia32_vfnmsubps,
7538 __builtin_ia32_vfnmsubpd, __builtin_ia32_vfnmsubps256 and.
7539 __builtin_ia32_vfnmsubpd256.
7540 * config/i386/sse.md (fma4i_fnmsub_<mode>): New.
7541 (<avx512>_fnmsub_<mode>_maskz<round_expand_name>): Likewise.
7542 (*<sd_mask_codefor>fma_fnmsub_<mode><sd_maskz_name>_bcst_1):
7543 Likewise.
7544 (*<sd_mask_codefor>fma_fnmsub_<mode><sd_maskz_name>_bcst_2):
7545 Likewise.
7546 (*<sd_mask_codefor>fma_fnmsub_<mode><sd_maskz_name>_bcst_3):
7547 Likewise.
7548 (fmai_vmfnmsub_<mode><round_name>): Likewise.
7549
7550 2018-10-21 H.J. Lu <hongjiu.lu@intel.com>
7551
7552 PR target/72782
7553 * config/i386/avx512fintrin.h (_mm512_fnmadd_round_pd): Use
7554 __builtin_ia32_vfnmaddpd512_mask.
7555 (_mm512_mask_fnmadd_round_pd): Likewise.
7556 (_mm512_fnmadd_pd): Likewise.
7557 (_mm512_mask_fnmadd_pd): Likewise.
7558 (_mm512_maskz_fnmadd_round_pd): Use
7559 __builtin_ia32_vfnmaddpd512_maskz.
7560 (_mm512_maskz_fnmadd_pd): Likewise.
7561 (_mm512_fnmadd_round_ps): Use __builtin_ia32_vfnmaddps512_mask.
7562 (_mm512_mask_fnmadd_round_ps): Likewise.
7563 (_mm512_fnmadd_ps): Likewise.
7564 (_mm512_mask_fnmadd_ps): Likewise.
7565 (_mm512_maskz_fnmadd_round_ps): Use
7566 __builtin_ia32_vfnmaddps512_maskz.
7567 (_mm512_maskz_fnmadd_ps): Likewise.
7568 * config/i386/avx512vlintrin.h (_mm256_mask_fnmadd_pd): Use
7569 __builtin_ia32_vfnmaddpd256_mask.
7570 (_mm256_maskz_fnmadd_pd): Use __builtin_ia32_vfnmaddpd256_maskz.
7571 (_mm_mask_fnmadd_pd): Use __builtin_ia32_vfmaddpd128_mask
7572 (_mm_maskz_fnmadd_pd): Use __builtin_ia32_vfnmaddpd128_maskz.
7573 (_mm256_mask_fnmadd_ps): Use __builtin_ia32_vfnmaddps256_mask.
7574 (_mm256_mask_fnmadd_ps): Use __builtin_ia32_vfnmaddps256_mask.
7575 (_mm256_maskz_fnmadd_ps): Use __builtin_ia32_vfnmaddps256_maskz.
7576 (_mm_mask_fnmadd_ps): Use __builtin_ia32_vfnmaddps128_mask.
7577 (_mm_maskz_fnmadd_ps): Use __builtin_ia32_vfnmaddps128_maskz.
7578 * config/i386/fmaintrin.h (_mm_fnmadd_pd): Use
7579 __builtin_ia32_vfnmaddpd.
7580 (_mm256_fnmadd_pd): Use __builtin_ia32_vfnmaddpd256.
7581 (_mm_fnmadd_ps): Use __builtin_ia32_vfnmaddps.
7582 (_mm256_fnmadd_ps): Use __builtin_ia32_vfnmaddps256.
7583 (_mm_fnmadd_sd): Use __builtin_ia32_vfnmaddsd3.
7584 (_mm_fnmadd_ss): Use __builtin_ia32_vfnmaddss3.
7585 * config/i386/i386-builtin.def: Add
7586 __builtin_ia32_vfnmaddpd256_mask,
7587 __builtin_ia32_vfnmaddpd256_maskz,
7588 __builtin_ia32_vfnmaddpd128_mask,
7589 __builtin_ia32_vfnmaddpd128_maskz,
7590 __builtin_ia32_vfnmaddps256_mask,
7591 __builtin_ia32_vfnmaddps256_maskz,
7592 __builtin_ia32_vfnmaddps128_mask,
7593 __builtin_ia32_vfnmaddps128_maskz,
7594 __builtin_ia32_vfnmaddpd512_mask,
7595 __builtin_ia32_vfnmaddpd512_maskz,
7596 __builtin_ia32_vfnmaddps512_mask,
7597 __builtin_ia32_vfnmaddps512_maskz, __builtin_ia32_vfnmaddss3,
7598 __builtin_ia32_vfnmaddsd3, __builtin_ia32_vfnmaddps,
7599 __builtin_ia32_vfnmaddpd, __builtin_ia32_vfnmaddps256 and.
7600 __builtin_ia32_vfnmaddpd256.
7601 * config/i386/sse.md (fma4i_fnmadd_<mode>): New.
7602 (<avx512>_fnmadd_<mode>_maskz<round_expand_name>): Likewise.
7603 (*<sd_mask_codefor>fma_fnmadd_<mode><sd_maskz_name>_bcst_1):
7604 Likewise.
7605 (*<sd_mask_codefor>fma_fnmadd_<mode><sd_maskz_name>_bcst_2):
7606 Likewise.
7607 (*<sd_mask_codefor>fma_fnmadd_<mode><sd_maskz_name>_bcst_3):
7608 Likewise.
7609 (fmai_vmfnmadd_<mode><round_name>): Likewise.
7610
7611 2018-10-21 H.J. Lu <hongjiu.lu@intel.com>
7612
7613 PR target/72782
7614 * config/i386/avx512fintrin.h (_mm512_fmsub_round_pd): Use
7615 __builtin_ia32_vfmsubpd512_mask.
7616 (_mm512_mask_fmsub_round_pd): Likewise.
7617 (_mm512_fmsub_pd): Likewise.
7618 (_mm512_mask_fmsub_pd): Likewise.
7619 (_mm512_maskz_fmsub_round_pd): Use
7620 __builtin_ia32_vfmsubpd512_maskz.
7621 (_mm512_maskz_fmsub_pd): Likewise.
7622 (_mm512_fmsub_round_ps): Use __builtin_ia32_vfmsubps512_mask.
7623 (_mm512_mask_fmsub_round_ps): Likewise.
7624 (_mm512_fmsub_ps): Likewise.
7625 (_mm512_mask_fmsub_ps): Likewise.
7626 (_mm512_maskz_fmsub_round_ps): Use
7627 __builtin_ia32_vfmsubps512_maskz.
7628 (_mm512_maskz_fmsub_ps): Likewise.
7629 * config/i386/avx512vlintrin.h (_mm256_mask_fmsub_pd): Use
7630 __builtin_ia32_vfmsubpd256_mask.
7631 (_mm256_maskz_fmsub_pd): Use __builtin_ia32_vfmsubpd256_maskz.
7632 (_mm_mask_fmsub_pd): Use __builtin_ia32_vfmaddpd128_mask
7633 (_mm_maskz_fmsub_pd): Use __builtin_ia32_vfmsubpd128_maskz.
7634 (_mm256_mask_fmsub_ps): Use __builtin_ia32_vfmsubps256_mask.
7635 (_mm256_mask_fmsub_ps): Use __builtin_ia32_vfmsubps256_mask.
7636 (_mm256_maskz_fmsub_ps): Use __builtin_ia32_vfmsubps256_maskz.
7637 (_mm_mask_fmsub_ps): Use __builtin_ia32_vfmsubps128_mask.
7638 (_mm_maskz_fmsub_ps): Use __builtin_ia32_vfmsubps128_maskz.
7639 * config/i386/fmaintrin.h (_mm_fmsub_pd): Use
7640 __builtin_ia32_vfmsubpd.
7641 (_mm256_fmsub_pd): Use __builtin_ia32_vfmsubpd256.
7642 (_mm_fmsub_ps): Use __builtin_ia32_vfmsubps.
7643 (_mm256_fmsub_ps): Use __builtin_ia32_vfmsubps256.
7644 (_mm_fmsub_sd): Use __builtin_ia32_vfmsubsd3.
7645 (_mm_fmsub_ss): Use __builtin_ia32_vfmsubss3.
7646 * config/i386/i386-builtin.def: Add
7647 __builtin_ia32_vfmsubpd256_mask,
7648 __builtin_ia32_vfmsubpd256_maskz,
7649 __builtin_ia32_vfmsubpd128_mask,
7650 __builtin_ia32_vfmsubpd128_maskz,
7651 __builtin_ia32_vfmsubps256_mask,
7652 __builtin_ia32_vfmsubps256_maskz,
7653 __builtin_ia32_vfmsubps128_mask,
7654 __builtin_ia32_vfmsubps128_maskz,
7655 __builtin_ia32_vfmsubpd512_mask,
7656 __builtin_ia32_vfmsubpd512_maskz,
7657 __builtin_ia32_vfmsubps512_mask,
7658 __builtin_ia32_vfmsubps512_maskz, __builtin_ia32_vfmsubss3,
7659 __builtin_ia32_vfmsubsd3, __builtin_ia32_vfmsubps,
7660 __builtin_ia32_vfmsubpd, __builtin_ia32_vfmsubps256 and.
7661 __builtin_ia32_vfmsubpd256.
7662 * config/i386/sse.md (fma4i_fmsub_<mode>): New.
7663 (<avx512>_fmsub_<mode>_maskz<round_expand_name>): Likewise.
7664 (*<sd_mask_codefor>fma_fmsub_<mode><sd_maskz_name>_bcst_1):
7665 Likewise.
7666 (*<sd_mask_codefor>fma_fmsub_<mode><sd_maskz_name>_bcst_2):
7667 Likewise.
7668 (*<sd_mask_codefor>fma_fmsub_<mode><sd_maskz_name>_bcst_3):
7669 Likewise.
7670 (fmai_vmfmsub_<mode><round_name>): Likewise.
7671
7672 2018-10-21 H.J. Lu <hongjiu.lu@intel.com>
7673
7674 * config/i386/sse.md (*<plusminus_insn><mode>3<mask_name>_bcst_1):
7675 Remove plus. Renamed to ...
7676 (*sub<mode>3<mask_name>_bcst): This.
7677 (*add<mode>3<mask_name>_bcst_2): Renamede to ...
7678 (*add<mode>3<mask_name>_bcst): This.
7679
7680 2018-10-21 H.J. Lu <hongjiu.lu@intel.com>
7681
7682 PR target/72782
7683 * config/i386/sse.md (*mul<mode>3<mask_name>_bcst): New.
7684
7685 2018-10-21 H.J. Lu <hongjiu.lu@intel.com>
7686
7687 PR target/87662
7688 * i386/avx512vlintrin.h (_mm256_or_epi32): New.
7689 (_mm_or_epi32): Likewise.
7690 (_mm256_xor_epi32): Likewise.
7691 (_mm_xor_epi32): Likewise.
7692 (_mm256_or_epi64): Likewise.
7693 (_mm_or_epi64): Likewise.
7694 (_mm256_xor_epi64): Likewise.
7695 (_mm_xor_epi64): Likewise.
7696
7697 2018-10-20 H.J. Lu <hongjiu.lu@intel.com>
7698
7699 PR target/72782
7700 * config/i386/sse.md (*<avx512>_div<mode>3<mask_name>_bcst): New.
7701
7702 2018-10-20 Jakub Jelinek <jakub@redhat.com>
7703
7704 PR middle-end/87647
7705 * varasm.c (decode_addr_const): Handle COMPOUND_LITERAL_EXPR.
7706
7707 2018-10-20 Andreas Schwab <schwab@linux-m68k.org>
7708
7709 * doc/ux.texi: Move @section directly after @node.
7710
7711 2018-10-19 Jakub Jelinek <jakub@redhat.com>
7712
7713 PR middle-end/85488
7714 PR middle-end/87649
7715 * omp-low.c (check_omp_nesting_restrictions): Diagnose ordered without
7716 depend closely nested inside of loop with ordered clause with
7717 a parameter.
7718
7719 2018-10-19 David Malcolm <dmalcolm@redhat.com>
7720
7721 * Makefile.in (TEXI_GCCINT_FILES): Add ux.texi.
7722 * doc/gccint.texi: Include ux.texi and use it in top-level menu.
7723 * doc/ux.texi: New file.
7724
7725 2018-10-19 Segher Boessenkool <segher@kernel.crashing.org>
7726
7727 * config/rs6000/rs6000.h (REG_ALLOC_ORDER): Move 68 (that is, CR0) to
7728 be the first CR field allocated.
7729
7730 2018-10-19 Richard Biener <rguenther@suse.de>
7731
7732 PR target/87657
7733 * config/i386/i386.c (ix86_builtin_vectorization_cost): Use
7734 TYPE_VECTOR_SUBPARTS and avoid relying on vector mode.
7735
7736 2018-10-19 H.J. Lu <hongjiu.lu@intel.com>
7737
7738 PR target/72782
7739 * config/i386/sse.md
7740 (*<plusminus_insn><mode>3<mask_name>_bcst_1): New.
7741 (*add<mode>3<mask_name>_bcst_2): Likewise.
7742
7743 2018-10-19 H.J. Lu <hongjiu.lu@intel.com>
7744
7745 * config/i386/sse.md
7746 (*<sd_mask_codefor>fma_fmadd_<mode><sd_maskz_name>_bcst_1):
7747 Replace nonimmediate_operand with register_operand.
7748 (*<sd_mask_codefor>fma_fmadd_<mode><sd_maskz_name>_bcst_2):
7749 Likewise.
7750 (*<sd_mask_codefor>fma_fmadd_<mode><sd_maskz_name>_bcst_3):
7751 Likewise.
7752
7753 2018-10-19 Ilya Leoshkevich <iii@linux.ibm.com>
7754
7755 PR rtl-optimization/87596
7756 * lra-constraints.c (spill_hard_reg_in_range): Use INSN_P () +
7757 lra_get_insn_recog_data () instead of lra_insn_recog_data[]
7758 for instructions in FROM..TO range.
7759
7760 2018-10-19 Eric Botcazou <ebotcazou@adacore.com>
7761
7762 * cfgexpand.c (expand_one_var): Use specific wording in error message
7763 for non-local frame variables.
7764 * stor-layout.c (layout_decl): Do not issue a warning for them.
7765
7766 2018-10-19 Robin Dapp <rdapp@linux.ibm.com>
7767
7768 * haifa-sched.c (priority): Add force_recompute parameter.
7769 (apply_replacement): Call priority () with force_recompute = true.
7770 (restore_pattern): Likewise.
7771
7772 2018-10-18 H.J. Lu <hongjiu.lu@intel.com>
7773
7774 * simplify-rtx.c (simplify_subreg): Limit mask of vec_merge to
7775 HOST_BITS_PER_WIDE_INT.
7776 (test_vector_ops_duplicate): Likewise.
7777
7778 2018-10-18 H.J. Lu <hongjiu.lu@intel.com>
7779
7780 PR target/72782
7781 * config/i386/sse.md (VF_AVX512): New.
7782 (avx512bcst): Likewise.
7783 (*<sd_mask_codefor>fma_fmadd_<mode><sd_maskz_name>_bcst_1):
7784 Likewise.
7785 (*<sd_mask_codefor>fma_fmadd_<mode><sd_maskz_name>_bcst_2):
7786 Likewise.
7787 (*<sd_mask_codefor>fma_fmadd_<mode><sd_maskz_name>_bcst_3):
7788 Likewise.
7789
7790 2018-10-18 Jonathan Wakely <jwakely@redhat.com>
7791
7792 * doc/invoke.texi (-dumpversion): Improve grammar.
7793 (-dumpfullversion): Make more consistent with -dumpversion.
7794
7795 2018-10-18 Uros Bizjak <ubizjak@gmail.com>
7796
7797 * config/i386/i386.c (ix86_emit_fp_unordered_jump):
7798 Set JUMP_LABEL to the jump insn.
7799 (ix86_emit_i387_log1p): Use ix86_expand_branch to expand branch.
7800 Predict emitted jump and add label to jump insn.
7801
7802 2018-10-18 David Malcolm <dmalcolm@redhat.com>
7803
7804 PR tree-optimization/87562
7805 * input.c (get_substring_ranges_for_loc): Use
7806 LRK_SPELLING_LOCATION rather than LRK_MACRO_EXPANSION_POINT when
7807 getting the linemap for the endpoint. Verify that it's either
7808 in the same linemap as the start point's spelling location, or
7809 at least in the same file.
7810
7811 2018-10-18 Richard Biener <rguenther@suse.de>
7812
7813 * config/i386/i386.c (ix86_builtin_vectorization_cost): Do not
7814 feed width-specific load/store costs through ix86_vec_cost.
7815 * config/i386/x86-tune-costs.h (athlon_cost): Adjust.
7816 (k8_cost): Likewise.
7817 (bdver_cost): Likewise.
7818 (znver1_cost): Likewise.
7819 (btver1_cost): Likewise.
7820 (btver2_cost): Likewise.
7821
7822 2018-10-18 H.J. Lu <hongjiu.lu@intel.com>
7823
7824 * simplify-rtx.c (simplify_subreg): Call simplify_gen_subreg
7825 to simplify subreg of vec_merge.
7826
7827 2018-10-18 Richard Biener <rguenther@suse.de>
7828
7829 * config/i386/i386.c: Fix costing of vector FMA.
7830
7831 2018-10-18 Richard Biener <rguenther@suse.de>
7832
7833 * config/i386/i386.c (ix86_vec_cost): Remove !parallel path
7834 and argument.
7835 (ix86_builtin_vectorization_cost): For vec_construct properly
7836 cost insertion into SSE regs.
7837 (...): Adjust calls to ix86_vec_cost.
7838
7839 2018-10-18 Richard Biener <rguenther@suse.de>
7840
7841 PR middle-end/87087
7842 Revert
7843 2018-02-07 Richard Biener <rguenther@suse.de>
7844
7845 PR tree-optimization/84204
7846 * tree-chrec.c (chrec_fold_plus_1): Remove size limiting in
7847 this place.
7848
7849 2018-10-18 H.J. Lu <hongjiu.lu@intel.com>
7850
7851 PR target/87537
7852 * simplify-rtx.c (simplify_subreg): Simplify subreg of vec_merge
7853 of vec_duplicate.
7854 (test_vector_ops_duplicate): Add test for a scalar subreg of a
7855 VEC_MERGE of a VEC_DUPLICATE.
7856
7857 2018-10-17 Joseph Myers <joseph@codesourcery.com>
7858
7859 * doc/cpp.texi (__STDC_VERSION__): Document C2X handling.
7860 * doc/invoke.texi (-std=c2x, -std=gnu2x): Document new options.
7861 * doc/standards.texi (C Language): Document C2X.
7862 * dwarf2out.c (highest_c_language), config/rl78/rl78.c
7863 (rl78_option_override): Handle "GNU C2X" language name.
7864
7865 2018-10-17 Joseph Myers <joseph@codesourcery.com>
7866
7867 * doc/invoke.texi (-std=c17), doc/standards.texi (C Language):
7868 Document C17 as published in 2018.
7869
7870 2018-10-17 Eric Botcazou <ebotcazou@adacore.com>
7871
7872 PR middle-end/87623
7873 * fold-const.c (fold_truth_andor_1): If the right side is not constant,
7874 bail out if both sides do not have the same storage order.
7875
7876 2018-10-17 Aldy Hernandez <aldyh@redhat.com>
7877
7878 * bitmap.c (bitmap_head::dump): New.
7879 * bitmap.h (bitmap_head): Add dump().
7880 * gimple-ssa-evrp-analyze.c
7881 (evrp_range_analyzer::try_find_new_range): Adjust for value_range API.
7882 (evrp_range_analyzer::set_ssa_range_info): Same.
7883 (evrp_range_analyzer::record_ranges_from_phis): Same.
7884 (evrp_range_analyzer::record_ranges_from_stmt): Same.
7885 * gimple-ssa-evrp.c (evrp_dom_walker::before_dom_children): Same.
7886 * gimple-ssa-sprintf.c (get_int_range): Same.
7887 (format_integer): Same.
7888 (sprintf_dom_walker::handle_gimple_call): Same.
7889 * ipa-cp.c (ipcp_vr_lattice::meet_with_1): Same.
7890 (ipcp_vr_lattice::top_p): Same.
7891 (ipcp_vr_lattice::bottom_p): Same.
7892 (ipcp_vr_lattice::set_to_bottom): Same.
7893 (ipa_vr_operation_and_type_effects): Same.
7894 (propagate_vr_across_jump_function): Same.
7895 (ipcp_store_vr_results): Same.
7896 * ipa-prop.c (struct ipa_vr_ggc_hash_traits): Same.
7897 (ipa_print_node_jump_functions_for_edge): Same.
7898 (ipa_get_value_range): Same.
7899 (ipa_compute_jump_functions_for_edge): Same.
7900 (ipa_write_jump_function): Same.
7901 * tree-ssa-dom.c (simplify_stmt_for_jump_threading): Same.
7902 * tree-ssa-threadedge.c (record_temporary_equivalences_from_phis):
7903 Same.
7904 * vr-values.c (set_value_range_to_nonnegative): Same.
7905 (set_value_range_to_truthvalue): Same.
7906 (vr_values::get_value_range): Same.
7907 (vr_values::set_defs_to_varying): Same.
7908 (vr_values::update_value_range): Same.
7909 (symbolic_range_based_on_p): Same.
7910 (vr_values::op_with_boolean_value_range_p): Same.
7911 (vr_values::extract_range_for_var_from_comparison_expr): Same.
7912 (vr_values::extract_range_from_ssa_name): Same.
7913 (vr_values::extract_range_from_binary_expr): Same.
7914 (vr_values::extract_range_from_unary_expr): Same.
7915 (vr_values::extract_range_from_cond_expr): Same.
7916 (vr_values::extract_range_from_comparison): Same.
7917 (vr_values::check_for_binary_op_overflow): Same.
7918 (vr_values::extract_range_basic): Same.
7919 (vr_values::extract_range_from_assignment): Same.
7920 (compare_ranges): Same.
7921 (compare_range_with_value): Same.
7922 (vr_values::adjust_range_with_scev): Same.
7923 (vrp_valueize): Same.
7924 (vrp_valueize_1): Same.
7925 (vr_values::get_vr_for_comparison): Same.
7926 (vr_values::compare_name_with_value): Same.
7927 (vr_values::compare_names): Same.
7928 (vr_values::vrp_evaluate_conditional): Same.
7929 (find_case_label_ranges): Same.
7930 (vr_values::vrp_visit_switch_stmt): Same.
7931 (vr_values::extract_range_from_phi_node): Same.
7932 (vr_values::simplify_div_or_mod_using_ranges): Same.
7933 (vr_values::simplify_bit_ops_using_ranges): Same.
7934 (test_for_singularity): Same.
7935 (range_fits_type_p): Same.
7936 (vr_values::simplify_cond_using_ranges_1): Same.
7937 (vr_values::simplify_switch_using_ranges): Same.
7938 (vr_values::simplify_float_conversion_using_ranges): Same.
7939 (vr_values::two_valued_val_range_p): Same.
7940 (vr_values::add_equivalence): Move to value_range::equiv_add.
7941 * vr-values.h (vr_values::add_equivalence): Remove.
7942 (VR_INITIALIZER): Remove.
7943 * tree-vrp.c (value_range::set): New.
7944 (value_range::equiv_add): New.
7945 (value_range::value_range): New.
7946 (value_range::deep_copy): New.
7947 (value_range::check): New.
7948 (value_range::equal_p): New.
7949 (value_range::ignore_equivs_equal_p): New.
7950 (value_range::operator==): New.
7951 (value_range::operator!=): New.
7952 (value_range::symbolic_p): New.
7953 (value_range::numeric_p): New.
7954 (value_range::set_undefined): New.
7955 (value_range::set_varying): New.
7956 (value_range::may_contain_p): New.
7957 (value_range::equiv_clear): New.
7958 (value_range::singleton_p): New.
7959 (value_range::intersect): New.
7960 (value_range::dump): New.
7961 (value_range::set_and_canonicalize): New.
7962 (set_value_range): Adjust for value_range API.
7963 (set_value_range_to_undefined): Same.
7964 (set_value_range_to_varying): Same.
7965 (set_and_canonicalize_value_range): Same.
7966 (set_value_range_to_nonnull): Same.
7967 (set_value_range_to_null): Same.
7968 (range_is_null): Same.
7969 (range_is_nonnull): Same.
7970 (range_int_cst_p): Same.
7971 (range_int_cst_singleton_p): Same.
7972 (symbolic_range_p): Same.
7973 (range_includes_zero_p): Same.
7974 (value_range_constant_singleton): Same.
7975 (vrp_set_zero_nonzero_bits): Same.
7976 (ranges_from_anti_range): Same.
7977 (extract_range_into_wide_ints): Same.
7978 (extract_range_from_multiplicative_op): Same.
7979 (set_value_range_with_overflow): Same.
7980 (extract_range_from_binary_expr_1): Same.
7981 (extract_range_from_unary_expr): Same.
7982 (dump_value_range): Same.
7983 (debug_value_range): Same.
7984 (vrp_prop::check_array_ref): Same.
7985 (vrp_prop::check_mem_ref): Same.
7986 (vrp_prop::vrp_initialize): Same.
7987 (vrp_prop::visit_stmt): Same.
7988 (intersect_ranges): Same.
7989 (vrp_prop::visit_phi): Same.
7990 (vrp_prop::vrp_finalize): Same.
7991 (determine_value_range_1): Same.
7992 (determine_value_range): Same.
7993 (vrp_intersect_ranges_1): Rename to...
7994 (vrp_intersect_1): this.
7995 (vrp_intersect_ranges): Rename to...
7996 (value_range::intersect_helper): ...this.
7997 (vrp_meet_1): Rename to...
7998 (value_range::union_helper): ...this.
7999 (vrp_meet): Rename to...
8000 (value_range::union_): ...this.
8001 (copy_value_range): Remove.
8002 * tree-vrp.h (struct value_range): Rewrite into a proper class.
8003 (value_range::vrtype): New.
8004 (value_range::type): New.
8005 (value_range::equiv): New.
8006 (value_range::min): New.
8007 (value_range::max): New.
8008 (value_range::varying_p): New.
8009 (value_range::undefined_p): New.
8010 (value_range::null_p): New.
8011 (value_range::equiv_add): New.
8012 (copy_value_range): Remove.
8013
8014 2018-10-17 David Malcolm <dmalcolm@redhat.com>
8015
8016 * Makefile.in (SELFTEST_TARGETS): New.
8017 (selftest) Change from s-selftest-c to $(SELFTEST_TARGETS).
8018 (C_SELFTEST_FLAGS, C_SELFTEST_DEPS, s-selftest-c, selftest-c-gdb)
8019 (selftest-gdb, selftest-c-valgrind, selftest-valgrind): Move to
8020 c/Make-lang.in.
8021 (CPP_SELFTEST_FLAGS, CPP_SELFTEST_DEPS, s-selftest-c++)
8022 (selftest-c++-gdb, selftest-c++-valgrind): Move to
8023 cp/Make-lang.in.
8024 * configure: Regenerate.
8025 * configure.ac (selftest_languages): New.
8026
8027 2018-10-17 Aldy Hernandez <aldyh@redhat.com>
8028
8029 * tree-vrp.c (extract_range_from_multiplicative_op): Remove
8030 overflow wraps argument.
8031 (extract_range_from_binary_expr_1): Do not pass overflow wraps to
8032 wide_int_range_multiplicative_op.
8033 * wide-int-range.cc (wide_int_range_mult_wrapping): Remove
8034 overflow wraps argument.
8035 (wide_int_range_multiplicative_op): Same.
8036 (wide_int_range_lshift): Same.
8037 (wide_int_range_div): Same.
8038 * wide-int-range.h (wide_int_range_multiplicative_op): Same.
8039 (wide_int_range_lshift): Same.
8040 (wide_int_range_div): Same.
8041
8042 2018-10-17 Aldy Hernandez <aldyh@redhat.com>
8043
8044 * wide-int-range.h (wide_int_range_shift_undefined_p): Adjust to
8045 use sign as argument.
8046 * tree-vrp.c (extract_range_from_binary_expr_1): Pass sign to
8047 wide_int_range_shift_undefined_p.
8048
8049 2018-10-16 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
8050
8051 * config/aarch64/aarch64.md (despeculate_copy<ALLI_TI:mode>):
8052 Rename to...
8053 (@despeculate_copy<ALLI_TI:mode>): ... This.
8054 * config/aarch64/aarch64.c (aarch64_speculation_safe_value): Remove
8055 switch statement.
8056
8057 2018-10-16 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
8058
8059 * config.gcc: Obsolete *-*-solaris2.10*.
8060 * doc/install.texi (Specific, *-*-solaris2*): Document it.
8061
8062 2018-10-12 Jeff Law <law@redhat.com>
8063
8064 * config/ft32/ft32.md (ft32_general_movsrc_operand): Disable
8065 reg + sym +- const_int addressing modes.
8066
8067 2018-10-15 David Malcolm <dmalcolm@redhat.com>
8068
8069 * common.opt (fdiagnostics-minimum-margin-width=): New option.
8070 * diagnostic-show-locus.c (layout::layout): Apply the minimum
8071 margin width.
8072 (layout::start_annotation_line): Only print up to 3 of the
8073 margin character, to avoid touching the left-hand side.
8074 (selftest::test_diagnostic_show_locus_fixit_lines): Update for
8075 minimum margin width, as set by test_diagnostic_context's ctor.
8076 (selftest::test_fixit_insert_containing_newline): Likewise.
8077 (selftest::test_fixit_insert_containing_newline_2): Likewise.
8078 (selftest::test_line_numbers_multiline_range): Clear
8079 dc.min_margin_width.
8080 * diagnostic.c (diagnostic_initialize): Initialize
8081 min_margin_width.
8082 * diagnostic.h (struct diagnostic_context): Add field
8083 "min_margin_width".
8084 * doc/invoke.texi: Add -fdiagnostics-minimum-margin-width=.
8085 * opts.c (common_handle_option): Handle
8086 OPT_fdiagnostics_minimum_margin_width_.
8087 * selftest-diagnostic.c
8088 (selftest::test_diagnostic_context::test_diagnostic_context):
8089 Initialize min_margin_width to 6.
8090 * toplev.c (general_init): Initialize global_dc->min_margin_width.
8091
8092 2018-10-15 David Malcolm <dmalcolm@redhat.com>
8093
8094 * gcc-rich-location.h (gcc_rich_location::add_location_if_nearby):
8095 Fix usage of "error_at_rich_loc" in the comment.
8096
8097 2018-10-15 Renlin Li <renlin.li@arm.com>
8098
8099 PR target/87563
8100 * tree-vectorizer.c (try_vectorize_loop_1): Don't use
8101 if-conversioned loop when it contains ifn with types not
8102 supported by backend.
8103 * internal-fn.c (expand_direct_optab_fn): Add an assert.
8104 (direct_internal_fn_supported_p): New helper function.
8105 * internal-fn.h (direct_internal_fn_supported_p): Declare.
8106
8107 2018-10-15 Jakub Jelinek <jakub@redhat.com>
8108
8109 PR target/87572
8110 * common/config/i386/i386-common.c (OPTION_MASK_ISA_AVX512F_UNSET):
8111 Remove OPTION_MASK_ISA_AVX5124FMAPS_UNSET and
8112 OPTION_MASK_ISA_AVX5124VNNIW_UNSET.
8113
8114 2018-10-15 Bin Cheng <bin.cheng@linux.alibaba.com>
8115
8116 PR tree-optimization/87022
8117 * tree-loop-distribution.c (pg_add_dependence_edges): Check all
8118 bits in dist vector rather than the first one.
8119
8120 2018-10-15 Richard Biener <rguenther@suse.de>
8121
8122 PR middle-end/87610
8123 * tree-ssa-structalias.c (struct vls_data): Add escaped_p member.
8124 (visit_loadstore): When a used restrict tag escaped verify that
8125 the points-to solution of "other" pointers do not include
8126 escaped.
8127 (compute_dependence_clique): If a used restrict tag escaped
8128 communicated that down to visit_loadstore.
8129
8130 2018-10-15 Andreas Krebbel <krebbel@linux.ibm.com>
8131
8132 * config/s390/s390.c (s390_expand_vec_init): Force vector element
8133 into reg if it isn't a general operand.
8134
8135 2018-10-14 H.J. Lu <hongjiu.lu@intel.com>
8136
8137 PR target/87599
8138 * config/i386/sse.md (*vec_dupv2di): Add register source to
8139 movddup.
8140
8141 2018-10-14 H.J. Lu <hongjiu.lu@intel.com>
8142
8143 PR target/87572
8144 * common/config/i386/i386-common.c (OPTION_MASK_ISA_AVX512F_UNSET):
8145 Add OPTION_MASK_ISA_AVX512IFMA_UNSET,
8146 OPTION_MASK_ISA_AVX5124FMAPS_UNSET and
8147 OPTION_MASK_ISA_AVX5124VNNIW_UNSET.
8148
8149 2018-10-13 Eric Botcazou <ebotcazou@adacore.com>
8150
8151 * dwarf2cfi.c (struct dw_trace_info): Add args_size_defined_for_eh.
8152 (notice_args_size): Set it in the current trace if no insn that can
8153 throw internally has been seen yet.
8154 (connect_traces): When connecting args_size between traces, allow the
8155 incoming values not to match if there is an insn setting it before the
8156 first insn that can throw internally; in that case, force the creation
8157 of a CFI note on this latter insn.
8158
8159 2018-10-13 Jonathan Wakely <jwakely@redhat.com>
8160
8161 * opt-problem.h (opt_wrapper): Use template-argument-list when naming
8162 the base class, because using the injected-class-name was not clearly
8163 specified until DR 176.
8164
8165 2018-10-12 Paul Koning <ni1d@arrl.net>
8166
8167 * config/pdp11/pdp11.md (doloop_end): New expander.
8168 (doloop_end_insn): renamed from "doloop_end".
8169 (addqi3): New pattern.
8170 (subqi3): New pattern.
8171 * config/pdp11/predicates.md (incdec_operand): New predicate.
8172
8173 2018-10-12 Yury Gribov <tetra2005@gmail.com>
8174
8175 PR middle-end/81376
8176 * real.c (format_helper::can_represent_integral_type_p): New function
8177 * real.h (format_helper::can_represent_integral_type_p): Ditto.
8178 * match.pd: New pattern.
8179
8180 2018-10-12 Alexandre Oliva <oliva@adacore.com>
8181
8182 * configure.ac: Introduce --enable-large-address-aware
8183 to define MINGW_DEFAULT_LARGE_ADDR_AWARE.
8184 * doc/install.texi: Document it.
8185 * configure, config.in: Rebuilt.
8186 * config/i386/mingw32.h (LINK_SPEC_LARGE_ADDR_AWARE): Define,
8187 based on MINGW_DEFAULT_LARGE_ADDR_AWARE.
8188 (LINK_SPEC): Insert it.
8189 * config/i386/mingw-w64.h: Likewise.
8190
8191 * cygming.h (HAVE_GAS_ALIGNED_COMM): Fallback-define.
8192
8193 2018-10-12 Peter Bergner <bergner@linux.ibm.com>
8194
8195 PR rtl-optimization/87600
8196 * ira-lives (non_conflicting_reg_copy_p): Disable for non LRA targets.
8197
8198 2018-10-12 Paul Koning <ni1d@arrl.net>
8199
8200 * doc/md.texi (doloop_end): Document that the pattern code may
8201 need to check operand mode.
8202
8203 2018-10-12 Wilco Dijkstra <wdijkstr@arm.com>
8204
8205 * config/aarch64/aarch64.md (zero_extendsidi2_aarch64): Add alternatives
8206 to zero-extend between int and floating-point registers.
8207 (load_pair_zero_extendsidi2_aarch64): Add alternative for zero-extended
8208 ldp into floating-point registers. Add type and arch attributes.
8209 (zero_extend<SHORT:mode><GPI:mode>2_aarch64): Add arch attribute.
8210 Use f_loads for type attribute.
8211
8212 2018-10-11 Martin Sebor <msebor@redhat.com>
8213
8214 * doc/extend.texi (attribute packed): Correct typos.
8215
8216 2018-10-11 Martin Sebor <msebor@redhat.com>
8217
8218 * doc/extend.texi (attribute flatten): Mention interaction with
8219 noinline.
8220
8221 2018-10-11 Jan Hubicka <hubicka@ucw.cz>
8222
8223 PR target/87156
8224 * cgraphclones.c (cgraph_node::create_version_clone_with_body):
8225 Set new_decl virtual flag to zero.
8226
8227 2018-10-11 Martin Sebor <msebor@redhat.com>
8228
8229 PR middle-end/87593
8230 * doc/extend.texi (attribute format_arg): Discuss using multiple
8231 attributes on a single function.
8232
8233 2018-10-11 Giuliano Belinassi <giuliano.belinassi@usp.br>
8234
8235 PR tree-optimization/86829
8236 * match.pd (sin (atan (x))): New simplification rules.
8237 (cos (atan (x))): Likewise.
8238 * real.c (build_sinatan_real): New function.
8239 * real.h (build_sinatan_real): Prototype.
8240
8241 2018-10-11 Will Schmidt <will_schmidt@vnet.ibm.com>
8242
8243 * config/rs6000/rs6000.c (map_to_integral_tree_type): New helper
8244 function.
8245 (fold_mergeeo_helper): New helper function.
8246 (rs6000_gimple_fold_builtin): Add hooks for vec_mergee and vec_mergeo
8247 intrinsics. Correct some whitespace indentation issues.
8248
8249 2018-10-11 Wilco Dijkstra <wdijkstr@arm.com>
8250
8251 PR target/87511
8252 * config/aarch64/aarch64.c (aarch64_mask_and_shift_for_ubfiz_p):
8253 Use HOST_WIDE_INT_1U for shift.
8254
8255 2018-10-11 Doug Rupp <rupp@adacore.com>
8256 Olivier Hainque <hainque@adacore.com>
8257
8258 * config/rs6000/vxworks.h (VXWORKS_RELAX_LINK_SPEC): New macro.
8259 Pass --relax to the linker for RTPs.
8260 (LINK_SPEC): Append VXWORKS_RELAX_LINK_SPEC.
8261
8262 2018-10-11 Andrew Stubbs <ams@codesourcery.com>
8263 Jan Hubicka <jh@suse.cz>
8264 Martin Jambor <mjambor@suse.cz>
8265
8266 * print-rtl.c (print_rtx_operand_codes_E_and_V): Print how many times
8267 the same elements are repeated rather than printing all of them.
8268 * read-rtl.c (rtx_reader::read_rtx_operand): Recognize and expand
8269 "repeated" elements.
8270 * read-rtl-function.c (test_loading_repeat): New function.
8271 (read_rtl_function_c_tests): Call test_loading_repeat.
8272 * rtl-tests.c (test_dumping_repeat): New function.
8273 (rtl_tests_c_tests): Call test_dumping_repeat.
8274
8275 2018-10-11 Richard Biener <rguenther@suse.de>
8276
8277 * config/i386/x86-tune-costs.h (bdver?_memcpy, bdver?_memset,
8278 bdver?_cost): Unify to ...
8279 (bdver_memcpy, bdver_memset, bdver_cost): ... this.
8280 * config/i386/i386.c (processor_cost_table): Adjust.
8281
8282 2018-10-10 Eric Botcazou <ebotcazou@adacore.com>
8283
8284 PR middle-end/87574
8285 * cgraphunit.c (cgraph_node::expand_thunk): Force DECL_IGNORED_P on
8286 the thunk when expanding to GIMPLE.
8287
8288 2018-10-10 Bernd Edlinger <bernd.edlinger@hotmail.de>
8289
8290 PR bootstrap/87551
8291 * varasm.c (mergeable_string_section): Don't try to move zero-length
8292 strings to the merge section.
8293
8294 2018-10-10 Uros Bizjak <ubizjak@gmail.com>
8295
8296 PR target/87573
8297 * config/i386/mmx.md (const_vector 0 -> mem splitter): New splitter.
8298
8299 2018-10-10 Jakub Jelinek <jakub@redhat.com>
8300
8301 PR target/87550
8302 * config/i386/i386-builtin.def (IX86_BUILTIN_RDPMC): Move from args set
8303 to special_args set.
8304
8305 2018-10-10 Richard Biener <rguenther@suse.de>
8306
8307 * config/i386/sse.md (reduc_plus_scal_v8df, reduc_plus_scal_v4df,
8308 reduc_plus_scal_v2df, reduc_plus_scal_v16sf, reduc_plus_scal_v8sf,
8309 reduc_plus_scal_v4sf): Merge into pattern reducing to half width
8310 and recursing and pattern terminating the recursion on SSE
8311 vector width using ix86_expand_reduc.
8312 (reduc_sminmax_scal_<mode>): Split into part reducing to half
8313 width and recursing and SSE2 vector variant doing the final
8314 reduction with ix86_expand_reduc.
8315 (reduc_uminmax_scal_<mode>): Likewise for the AVX512 variants
8316 with terminating the recursion at AVX level, splitting that
8317 to SSE there.
8318
8319 2018-10-09 David Malcolm <dmalcolm@redhat.com>
8320
8321 * genmatch.c (error_cb): Rename to...
8322 (diagnostic_cb): ...this, converting int params to enums.
8323 (fatal_at): Update for renaming.
8324 (warning_at): Likewise.
8325 (main): Likewise.
8326 * input.c (selftest::ebcdic_execution_charset::apply):
8327 Update for renaming of...
8328 (selftest::ebcdic_execution_charset::on_error): ...this, renaming
8329 to...
8330 (selftest::ebcdic_execution_charset::on_diagnostic): ...this,
8331 converting level and reason to enums.
8332 (class selftest::lexer_error_sink): Rename to...
8333 (class selftest::lexer_test_options): ...this, renaming field
8334 "m_errors" to "m_diagnostics".
8335 (selftest::lexer_test_options::apply): Update for renaming of...
8336 (selftest::lexer_test_options::on_error): ...this, renaming to...
8337 (selftest::lexer_test_options::on_diagnostic): ...this
8338 converting level and reason to enums.
8339 (selftest::test_lexer_string_locations_raw_string_unterminated):
8340 Update for renamings.
8341 * opth-gen.awk (struct cpp_reason_option_codes_t): Use enum for
8342 "reason".
8343
8344 2018-10-09 Paul A. Clarke <pc@us.ibm.com>
8345
8346 * config.gcc (powerpc*-*-*): Add pmmintrin.h to extra_headers.
8347 * config/rs6000/pmmintrin.h: New file.
8348
8349 2018-10-09 Eric Botcazou <ebotcazou@adacore.com>
8350
8351 PR tree-optimization/86659
8352 * gimple-match.h (gimple_match_op constructors): Initialize reverse.
8353
8354 2018-10-09 Richard Biener <rguenther@suse.de>
8355
8356 PR tree-optimization/63155
8357 * tree-ssa-structalias.c: Include tree-ssa.h.
8358 (get_constraint_for_ssa_var): For undefs return nothing_id.
8359 (find_func_aliases): Cleanup PHI handling.
8360
8361 2018-10-09 Richard Biener <rguenther@suse.de>
8362
8363 * tree-vectorizer.c (dump_stmt_cost): Fix cut&paste missing
8364 replacements.
8365
8366 2018-10-09 Martin Liska <mliska@suse.cz>
8367
8368 * asan.c (asan_emit_stack_protection): If a stack variable
8369 is located in a same file as current function, then emit
8370 line info into variable definition string.
8371
8372 2018-10-08 Eric Botcazou <ebotcazou@adacore.com>
8373
8374 * print-rtl.c (rtx_writer::print_rtx_operand_code_i): Print column
8375 information.
8376
8377 2018-10-08 Eric Botcazou <ebotcazou@adacore.com>
8378
8379 * cgraphunit.c (cgraph_node::expand_thunk): Do not force DECL_IGNORED_P
8380 on the thunk.
8381
8382 2018-10-08 Eric Botcazou <ebotcazou@adacore.com>
8383
8384 PR tree-optimization/86659
8385 * gimple-match.h (struct gimple_match_op): Add reverse field.
8386 (gimple_match_op::set_op): New overloaded method.
8387 * gimple-match-head.c (maybe_build_generic_op) <BIT_FIELD_REF>: Set
8388 the REF_REVERSE_STORAGE_ORDER flag on the value.
8389 (gimple_simplify) <GIMPLE_ASSIGN>: For BIT_FIELD_REF, propagate the
8390 REF_REVERSE_STORAGE_ORDER flag and avoid simplifying if it is set.
8391
8392 2018-10-08 Richard Sandiford <richard.sandiford@arm.com>
8393
8394 PR middle-end/63155
8395 * gimple-ssa-backprop.c (backprop::intersect_uses): Use
8396 FOR_EACH_IMM_USE_FAST instead of FOR_EACH_IMM_USE_STMT.
8397
8398 2018-10-08 H.J. Lu <hongjiu.lu@intel.com>
8399
8400 PR target/87517
8401 * config/i386/avx512fintrin.h (_mm512_mask_fmaddsub_round_pd):
8402 Defined with __builtin_ia32_vfmaddsubpd512_mask.
8403
8404 2018-10-08 Richard Biener <rguenther@suse.de>
8405
8406 * config/i386/x86-tune-costs.h (znver1_cost): Make AVX256 vector loads
8407 cost the same as AVX128 ones.
8408
8409 2018-10-08 Paul Koning <ni1d@arrl.net>
8410
8411 * config/pdp11/pdp11-protos.h (output_block_move): Remove.
8412 (expand_block_move): New function.
8413 * config/pdp11/pdp11.c (output_block_move): Remove.
8414 (expand_block_move): New function.
8415 * config/pdp11/pdp11.h (MOVE_RATIO): New definition.
8416 * config/pdp11/pdp11.md (movmemhi): Use expand_block_move.
8417 (*movmemhi1): Remove.
8418
8419 2018-10-08 Robin Dapp <rdapp@linux.ibm.com>
8420
8421 * config/s390/2827.md: Increase latencies for some FP instructions.
8422
8423 2018-10-08 Richard Biener <rguenther@suse.de>
8424
8425 * tree-vect-loop.c (vect_compute_single_scalar_iteration_cost):
8426 Open a dump scope.
8427 * tree-vectorizer.c (dump_stmt_cost): Add cost param and dump it.
8428 * tree-vectorizer.h (dump_stmt_cost): Adjust.
8429 (add_stmt_cost): Dump return value of the hook.
8430
8431 2018-10-08 Richard Biener <rguenther@suse.de>
8432
8433 PR tree-optimization/63155
8434 * tree-ssa-propagate.c (add_ssa_edge): Do cheap check first.
8435 (ssa_propagation_engine::ssa_propagate): Remove redundant
8436 bitmap bit clearing.
8437
8438 2018-10-05 Peter Bergner <bergner@linux.ibm.com>
8439
8440 PR rtl-optimization/86939
8441 PR rtl-optimization/87479
8442 * ira.h (non_conflicting_reg_copy_p): New prototype.
8443 * ira-lives.c (ignore_reg_for_conflicts): New static variable.
8444 (make_hard_regno_dead): Don't add conflicts for register
8445 ignore_reg_for_conflicts.
8446 (make_object_dead): Likewise.
8447 (non_conflicting_reg_copy_p): New function.
8448 (process_bb_node_lives): Set ignore_reg_for_conflicts for copies.
8449 Remove special conflict handling of REAL_PIC_OFFSET_TABLE_REGNUM.
8450 * lra-lives.c (ignore_reg_for_conflicts): New static variable.
8451 (make_hard_regno_dead): Don't add conflicts for register
8452 ignore_reg_for_conflicts. Remove special conflict handling of
8453 REAL_PIC_OFFSET_TABLE_REGNUM. Remove now unused argument
8454 check_pic_pseudo_p and update callers.
8455 (mark_pseudo_dead): Don't add conflicts for register
8456 ignore_reg_for_conflicts.
8457 (process_bb_lives): Set ignore_reg_for_conflicts for copies.
8458
8459 2018-10-05 Andrew Waterman <andrew@sifive.com>
8460 Jim Wilson <jimw@sifive.com>
8461
8462 * config/riscv/riscv.md (f<quiet_pattern>_quiet<ANYF:mode><X:mode>4):
8463 Add define_expand. Add ! HONOR_SNANS check to current pattern. Add
8464 new pattern using HONOR_SNANS that emits one extra instruction.
8465
8466 2018-10-05 Segher Boessenkool <segher@kernel.crashing.org>
8467
8468 * config/rs6000/rs6000.md (unnamed mfcr scc_comparison_operator
8469 patterns): Merge SI and DI patterns to a GPR pattern.
8470 (unnamed define_insn and define_split for record form of that): Merge
8471 to a single define_insn_and_split pattern.
8472
8473 2018-10-05 David Malcolm <dmalcolm@redhat.com>
8474
8475 PR c++/56856
8476 * input.c (expand_location_to_spelling_point): Add param "aspect"
8477 and use rather than hardcoding LOCATION_ASPECT_CARET.
8478 (get_substring_ranges_for_loc): Handle the case of a single token
8479 within a macro expansion.
8480 * input.h (expand_location_to_spelling_point): Add "aspect" param,
8481 defaulting to LOCATION_ASPECT_CARET.
8482
8483 2018-10-05 Paul Koning <ni1d@arrl.net>
8484
8485 * config/pdp11/pdp11.c (TARGET_CXX_GUARD_TYPE): Define.
8486 (TARGET_CXX_CLASS_DATA_ALWAYS_COMDAT): Define.
8487 (TARGET_CXX_LIBRARY_RTTI_COMDAT): Define.
8488 (pdp11_guard_type): New function.
8489
8490 2018-10-05 Paul Koning <ni1d@arrl.net>
8491
8492 * config/pdp11/pdp11.h (FLOAT_TYPE_SIZE): Always 32.
8493 * config/pdp11/pdp11.opt (mfloat32): Remove.
8494 (mfloat64): Remove.
8495 * doc/invoke.texi (pdp11 -mfloat32): Remove:
8496 (pdp11 -mfloat64): Remove.
8497
8498 2018-10-05 Uros Bizjak <ubizjak@gmail.com>
8499
8500 * config/i386/i386.md (*cmpxf_cc_i387): Remove pattern.
8501 (*cmp<mode>_cc_i387): Ditto.
8502 (*cmpu<mode>_cc_i387): Ditto.
8503 (*cmp<X87MODEF:mode>_<SWI24:mode>_cc_i387): Ditto.
8504 * config/i386/i386.c (ix86_expand_fp_compare): Remove
8505 "scratch" argument.
8506 <case IX86_FPCMP_SAHF>: Do not generate pattern with HImode clobber.
8507 Emit x86_sahf_1 pattern.
8508 (ix86_expand_compare): Update call to ix86_expand_fp_compare.
8509 (ix86_expand_carry_flag_compare): Ditto.
8510
8511 2018-10-05 Uros Bizjak <ubizjak@gmail.com>
8512
8513 * config/i386/i386.md (*cmpxf_i387): Change operand 2 predicate
8514 to reg_or_0_operand. Add "C" constraint.
8515 (*cmpxf_cc_i387): Ditto.
8516 (*cmp<mode>_i387): Change operand 2 predicate
8517 to nonimm_or_0_operand. Add "C" constraint.
8518 (*cmp<mode>_cc_i387): Ditto.
8519 (*cmp<mode>_0_i387): Remove insn pattern.
8520 (*cmp<mode>_0_cc_i387): Ditto.
8521
8522 2018-10-05 Uros Bizjak <ubizjak@gmail.com>
8523
8524 * config/i386/constraints.md ("C"): Do not depend on TARGET_SSE.
8525 * config/i386/predicates.md (nonimm_or_0_operand): Rename
8526 from vector_move_operand. Update all uses.
8527
8528 2018-10-05 Martin Sebor <msebor@redhat.com>
8529
8530 PR tree-optimization/87490
8531 * builtins.c (expand_builtin_strnlen): Handle a null data.decl
8532 consistently.
8533
8534 2018-10-05 Richard Biener <rguenther@suse.de>
8535
8536 PR tree-optimization/63155
8537 * tree-ssa-ccp.c (ccp_propagate::visit_phi): Avoid excess
8538 vertical space in dumpfiles.
8539 * tree-ssa-propagate.h
8540 (ssa_propagation_engine::process_ssa_edge_worklist): Remove.
8541 * tree-ssa-propagate.c (cfg_blocks_back): New global.
8542 (ssa_edge_worklist_back): Likewise.
8543 (curr_order): Likewise.
8544 (cfg_blocks_get): Remove abstraction.
8545 (cfg_blocks_add): Likewise.
8546 (cfg_blocks_empty_p): Likewise.
8547 (add_ssa_edge): Add to current or next worklist based on
8548 RPO index.
8549 (add_control_edge): Likewise.
8550 (ssa_propagation_engine::process_ssa_edge_worklist): Fold
8551 into ...
8552 (ssa_propagation_engine::ssa_propagate): ... here. Unify
8553 iteration from CFG and SSA edge worklist so we process
8554 everything in RPO order, prioritizing forward progress
8555 over iteration.
8556 (ssa_prop_init): Allocate new worklists, do not dump
8557 immediate uses.
8558 (ssa_prop_fini): Free new worklists.
8559
8560 2018-10-05 Richard Biener <rguenther@suse.de>
8561
8562 * tree-core.h (tree_block::abstract_flag): Remove.
8563 (tree_block::block_num): Make full 32bits.
8564 * tree.def (BLOCK): Remove docs about BLOCK_ABSTRACT.
8565 * tree.h (BLOCK_ABSTRACT): Remove.
8566 * dwarf2out.c (gen_lexical_block_die): Remove dead code
8567 resulting from BLOCK_ABSTRACT being always false.
8568 (gen_inlined_subroutine_die): Likewise.
8569 (gen_block_die): Likewise.
8570 * tree.c (block_ultimate_origin): Likewise.
8571 * tree-pretty-print.c (dump_block_node): Remove code dealing
8572 with BLOCK_ABSTRACT.
8573 * tree-ssa-live.c (dump_scope_block): Likewise.
8574 * tree-streamer-in.c (unpack_ts_block_value_fields): Likewise.
8575 * tree-streamer-out.c (pack_ts_block_value_fields): Likewise.
8576
8577 2018-10-05 Richard Biener <rguenther@suse.de>
8578
8579 * config/i386/i386.c (ix86_add_stmt_cost): When scalar cost
8580 is asked for initialize mode to the component mode of the
8581 vector type.
8582
8583 2018-10-05 H.J. Lu <hongjiu.lu@intel.com>
8584
8585 PR target/87522
8586 * config/i386/gnu-user.h (ASM_SPEC): Don't pass -msse2avx to
8587 assembler for -mavx.
8588 * config/i386/gnu-user64.h (ASM_SPEC): Likewise.
8589
8590 2018-10-05 Segher Boessenkool <segher@kernel.crashing.org>
8591
8592 PR target/87509
8593 * config/rs6000/rs6000-builtin.def (RS6000_BUILTIN_SET_FPSCR_DRN): Use
8594 RS6000_BTM_DFP.
8595 * config/rs6000/rs6000.md (rs6000_set_fpscr_rn): Require the operand
8596 to be DImode. When using mffscrn, force the operand to a register.
8597
8598 2018-10-04 Uros Bizjak <ubizjak@gmail.com>
8599
8600 * config/i386/i386.md (*fop_<X87MODEF:mode>_2_i387): Macroize insn
8601 from *fop_<MODEF:mode>_2_i387 and *fop_xf_2_i387 using
8602 X87MODEF mode iterator.
8603 (*fop_<X87MODEF:mode>_3_i387): Macroize insn from
8604 *fop_<MODEF:mode>_3_i387 and *fop_xf_3_i387 using
8605 X87MODEF mode iterator.
8606
8607 2018-10-04 Vinay Kumar <vinay.kumar@blackfigtech.com>
8608
8609 * doc/invoke.texi (-Wno-prio-ctor-dtor): Document new warning
8610 -Wno-prio-ctor-dtor.
8611
8612 2018-10-04 David Malcolm <dmalcolm@redhat.com>
8613
8614 * Makefile.in (OBJS): Add opt-problem.o.
8615 * dump-context.h: Include "selftest.h.
8616 (selftest::temp_dump_context): New forward decl.
8617 (class dump_context): Make friend of class
8618 selftest::temp_dump_context.
8619 (dump_context::dump_loc_immediate): New decl.
8620 (class dump_pretty_printer): Move here from dumpfile.c.
8621 (class temp_dump_context): Move to namespace selftest.
8622 (temp_dump_context::temp_dump_context): Add param
8623 "forcibly_enable_dumping".
8624 (selftest::verify_dumped_text):
8625 (ASSERT_DUMPED_TEXT_EQ): Move here from dumpfile.c.
8626 (selftest::verify_item):
8627 (ASSERT_IS_TEXT): Move here from dumpfile.c.
8628 (ASSERT_IS_TREE): Likewise.
8629 (ASSERT_IS_GIMPLE): Likewise.
8630 * dumpfile.c (dump_context::dump_loc): Move immediate dumping
8631 to...
8632 (dump_context::dump_loc_immediate): ...this new function.
8633 (class dump_pretty_printer): Move to dump-context.h.
8634 (dump_switch_p_1): Don't enable MSG_PRIORITY_REEMITTED.
8635 (opt_info_switch_p_1): Enable MSG_PRIORITY_REEMITTED.
8636 (temp_dump_context::temp_dump_context): Move to "selftest"
8637 namespace. Add param "forcibly_enable_dumping", and use it to
8638 conditionalize the use of m_pp;
8639 (selftest::verify_dumped_text): Make non-static.
8640 (ASSERT_DUMPED_TEXT_EQ): Move to dump-context.h.
8641 (selftest::verify_item): Make non-static.
8642 (ASSERT_IS_TEXT): Move to dump-context.h.
8643 (ASSERT_IS_TREE): Likewise.
8644 (ASSERT_IS_GIMPLE): Likewise.
8645 (selftest::test_capture_of_dump_calls): Pass "true" for new
8646 param of temp_dump_context.
8647 * dumpfile.h (enum dump_flag): Add MSG_PRIORITY_REEMITTED, adding
8648 it to MSG_ALL_PRIORITIES. Update values of TDF_COMPARE_DEBUG and
8649 TDF_COMPARE_DEBUG.
8650 * opt-problem.cc: New file.
8651 * opt-problem.h: New file.
8652 * optinfo-emit-json.cc
8653 (selftest::test_building_json_from_dump_calls): Pass "true" for
8654 new param of temp_dump_context.
8655 * optinfo.cc (optinfo_kind_to_dump_flag): New function.
8656 (optinfo::emit_for_opt_problem): New function.
8657 (optinfo::emit): Clarity which emit_item is used.
8658 * optinfo.h (optinfo::get_dump_location): New accessor.
8659 (optinfo::emit_for_opt_problem): New decl.
8660 (optinfo::emit): Make const.
8661 * selftest-run-tests.c (selftest::run_tests): Call
8662 selftest::opt_problem_cc_tests.
8663 * selftest.h (selftest::opt_problem_cc_tests): New decl.
8664 * tree-data-ref.c (dr_analyze_innermost): Convert return type from
8665 bool to opt_result, converting fprintf messages to
8666 opt_result::failure_at calls. Add "stmt" param for use by the
8667 failure_at calls.
8668 (create_data_ref): Pass "stmt" to the dr_analyze_innermost call.
8669 (runtime_alias_check_p): Convert return type from bool to
8670 opt_result, converting dump_printf calls to
8671 opt_result::failure_at, using the statement DDR_A for their
8672 location.
8673 (find_data_references_in_stmt): Convert return type from bool to
8674 opt_result, converting "return false" to opt_result::failure_at
8675 with a new message.
8676 * tree-data-ref.h: Include "opt-problem.h".
8677 (dr_analyze_innermost): Convert return type from bool to opt_result,
8678 and add a const gimple * param.
8679 (find_data_references_in_stmt): Convert return type from bool to
8680 opt_result.
8681 (runtime_alias_check_p): Likewise.
8682 * tree-predcom.c (find_looparound_phi): Pass "init_stmt" to
8683 dr_analyze_innermost.
8684 * tree-vect-data-refs.c (vect_mark_for_runtime_alias_test):
8685 Convert return type from bool to opt_result, adding a message for
8686 the PARAM_VECT_MAX_VERSION_FOR_ALIAS_CHECKS zero case.
8687 (vect_analyze_data_ref_dependence): Convert return type from bool
8688 to opt_result. Change sense of return type from "false"
8689 effectively meaning "no problems" to "false" meaning a problem,
8690 so that "return false" becomes "return opt_result::success".
8691 Convert "return true" calls to opt_result::failure_at, using
8692 the location of statement A rather than vect_location.
8693 (vect_analyze_data_ref_dependences): Convert return type from bool
8694 to opt_result.
8695 (verify_data_ref_alignment): Likewise, converting dump_printf_loc
8696 calls to opt_result::failure_at, using the stmt location rather
8697 than vect_location.
8698 (vect_verify_datarefs_alignment): Convert return type from bool
8699 to opt_result.
8700 (vect_enhance_data_refs_alignment): Likewise. Split local "stat"
8701 into multiple more-tightly-scoped copies.
8702 (vect_analyze_data_refs_alignment): Convert return type from bool
8703 to opt_result.
8704 (vect_analyze_data_ref_accesses): Likewise, converting a
8705 "return false" to a "return opt_result::failure_at", adding a
8706 new message.
8707 (vect_prune_runtime_alias_test_list): Convert return type from
8708 bool to opt_result, converting dump_printf_loc to
8709 opt_result::failure_at. Add a %G to show the pertinent statement,
8710 and use the stmt's location rather than vect_location.
8711 (vect_find_stmt_data_reference): Convert return type from
8712 bool to opt_result, converting dump_printf_loc to
8713 opt_result::failure_at, using stmt's location.
8714 (vect_analyze_data_refs): Convert return type from bool to
8715 opt_result. Convert "return false" to "return
8716 opt_result::failure_at", adding messages as needed.
8717 * tree-vect-loop.c (vect_determine_vf_for_stmt_1): Convert return
8718 type from bool to opt_result.
8719 (vect_determine_vf_for_stmt): Likewise.
8720 (vect_determine_vectorization_factor): Likewise, converting
8721 dump_printf_loc to opt_result::failure_at, using location of phi
8722 rather than vect_location.
8723 (vect_analyze_loop_form_1): Convert return type from bool to
8724 opt_result, converting dump_printf_loc calls, retaining the use of
8725 vect_location.
8726 (vect_analyze_loop_form): Convert return type from loop_vec_info
8727 to opt_loop_vec_info.
8728 (vect_analyze_loop_operations): Convert return type from bool to
8729 opt_result, converting dump_printf_loc calls, using the location
8730 of phi/stmt rather than vect_location where available. Convert
8731 various "return false" to "return opt_result::failure_at" with
8732 "unsupported phi" messages.
8733 (vect_get_datarefs_in_loop): Convert return type from bool to
8734 opt_result. Add a message for the
8735 PARAM_LOOP_MAX_DATAREFS_FOR_DATADEPS failure.
8736 (vect_analyze_loop_2): Convert return type from bool to
8737 opt_result. Ensure "ok" is set to a opt_result::failure_at before
8738 each "goto again;", adding new messages where needed.
8739 Add "unsupported grouped {store|load}" messages.
8740 (vect_analyze_loop): Convert return type from loop_vec_info to
8741 opt_loop_vec_info.
8742 * tree-vect-slp.c (vect_analyze_slp): Convert return type from
8743 bool to opt_result.
8744 * tree-vect-stmts.c (process_use): Likewise, converting
8745 dump_printf_loc call and using stmt location, rather than
8746 vect_location.
8747 (vect_mark_stmts_to_be_vectorized): Likeise.
8748 (vect_analyze_stmt): Likewise, adding a %G.
8749 (vect_get_vector_types_for_stmt): Convert return type from bool to
8750 opt_result, converting dump_printf_loc calls and using stmt
8751 location, rather than vect_location.
8752 (vect_get_mask_type_for_stmt): Convert return type from tree to
8753 opt_tree, converting dump_printf_loc calls and using stmt location.
8754 * tree-vectorizer.c: Include "opt-problem.h.
8755 (try_vectorize_loop_1): Flag "Analyzing loop at" dump message as
8756 MSG_PRIORITY_INTERNALS. Convert local "loop_vinfo" from
8757 loop_vec_info to opt_loop_vec_info. If if fails, and dumping is
8758 enabled, use it to report at the top level "couldn't vectorize
8759 loop" followed by the problem.
8760 * tree-vectorizer.h (opt_loop_vec_info): New typedef.
8761 (vect_mark_stmts_to_be_vectorized): Convert return type from bool
8762 to opt_result.
8763 (vect_analyze_stmt): Likewise.
8764 (vect_get_vector_types_for_stmt): Likewise.
8765 (tree vect_get_mask_type_for_stmt): Likewise.
8766 (vect_analyze_data_ref_dependences): Likewise.
8767 (vect_enhance_data_refs_alignment): Likewise.
8768 (vect_analyze_data_refs_alignment): Likewise.
8769 (vect_verify_datarefs_alignment): Likewise.
8770 (vect_analyze_data_ref_accesses): Likewise.
8771 (vect_prune_runtime_alias_test_list): Likewise.
8772 (vect_find_stmt_data_reference): Likewise.
8773 (vect_analyze_data_refs): Likewise.
8774 (vect_analyze_loop): Convert return type from loop_vec_info to
8775 opt_loop_vec_info.
8776 (vect_analyze_loop_form): Likewise.
8777 (vect_analyze_slp): Convert return type from bool to opt_result.
8778
8779 2018-10-04 David Malcolm <dmalcolm@redhat.com>
8780
8781 * doc/invoke.texi (-fopt-info): Document new "internals"
8782 sub-option.
8783 * dump-context.h (dump_context::apply_dump_filter_p): New decl.
8784 * dumpfile.c (dump_options): Update for renaming of MSG_ALL to
8785 MSG_ALL_KINDS.
8786 (optinfo_verbosity_options): Add "internals".
8787 (kind_as_string): Update for renaming of MSG_ALL to MSG_ALL_KINDS.
8788 (dump_context::apply_dump_filter_p): New member function.
8789 (dump_context::dump_loc): Use apply_dump_filter_p rather than
8790 explicitly masking the dump_kind.
8791 (dump_context::begin_scope): Increment the scope depth first. Use
8792 apply_dump_filter_p rather than explicitly masking the dump_kind.
8793 (dump_context::emit_item): Use apply_dump_filter_p rather than
8794 explicitly masking the dump_kind.
8795 (dump_dec): Likewise.
8796 (dump_hex): Likewise.
8797 (dump_switch_p_1): Default to MSG_ALL_PRIORITIES.
8798 (opt_info_switch_p_1): Default to MSG_PRIORITY_USER_FACING.
8799 (opt_info_switch_p): Update handling of default
8800 MSG_OPTIMIZED_LOCATIONS to cope with default of
8801 MSG_PRIORITY_USER_FACING.
8802 (dump_basic_block): Use apply_dump_filter_p rather than explicitly
8803 masking the dump_kind.
8804 (selftest::test_capture_of_dump_calls): Update test_dump_context
8805 instances to use MSG_ALL_KINDS | MSG_PRIORITY_USER_FACING rather
8806 than MSG_ALL. Generalize scope test to be run at all four
8807 combinations of with/without MSG_PRIORITY_USER_FACING and
8808 MSG_PRIORITY_INTERNALS, adding examples of explicit priority
8809 for each of the two values.
8810 * dumpfile.h (enum dump_flag): Add comment about the MSG_* flags.
8811 Rename MSG_ALL to MSG_ALL_KINDS. Add MSG_PRIORITY_USER_FACING,
8812 MSG_PRIORITY_INTERNALS, and MSG_ALL_PRIORITIES, updating the
8813 values for TDF_COMPARE_DEBUG and TDF_ALL_VALUES.
8814 (AUTO_DUMP_SCOPE): Add a note to the comment about the interaction
8815 with MSG_PRIORITY_*.
8816 * tree-vect-loop-manip.c (vect_loop_versioning): Mark versioning
8817 dump messages as MSG_PRIORITY_USER_FACING.
8818 * tree-vectorizer.h (DUMP_VECT_SCOPE): Add a note to the comment
8819 about the interaction with MSG_PRIORITY_*.
8820
8821 2018-10-04 Bernd Edlinger <bernd.edlinger@hotmail.de>
8822
8823 * varasm.c (output_constant): Add new parameter merge_strings.
8824 Make strings properly zero terminated in merge string sections.
8825 (mergeable_string_section): Don't fail if the last char is non-zero.
8826 (assemble_variable_contents): Handle merge string sections.
8827 (assemble_variable): Likewise.
8828 (assemble_constant_contents): Likewise.
8829 (output_constant_def_contents): Likewise.
8830 (output_constructor_array_range,
8831 output_constructor_regular_field): Adjust call to output_constant.
8832 (output_object_block): Adjust call to assemble_constant_contents
8833 and assemble_variable_contents.
8834
8835 2018-10-04 Martin Liska <mliska@suse.cz>
8836
8837 PR c/87483
8838 * cgraphunit.c (process_function_and_variable_attributes):
8839 Warn about a function with alias attribute and a body.
8840
8841 2018-10-04 Martin Liska <mliska@suse.cz>
8842
8843 PR ipa/82625
8844 * multiple_target.c (redirect_to_specific_clone): New function.
8845 (ipa_target_clone): Use it.
8846 * tree-inline.c: Fix comment.
8847
8848 2018-10-04 David Malcolm <dmalcolm@redhat.com>
8849
8850 * dumpfile.c (gcc::dump_manager::dump_manager): Initialize new
8851 fields.
8852 (gcc::dump_manager::~dump_manager): Free m_optinfo_filename.
8853 (gcc::dump_manager::register_pass): New member function, adapted
8854 from loop body in gcc::pass_manager::register_pass, adding a
8855 call to update_dfi_for_opt_info.
8856 (gcc::dump_manager::opt_info_enable_passes): Store the
8857 -fopt-info options into the new fields. Move the loop
8858 bodies into...
8859 (gcc::dump_manager::update_dfi_for_opt_info): ...this new member
8860 function.
8861 * dumpfile.h (struct opt_pass): New forward decl.
8862 (gcc::dump_manager::register_pass): New decl.
8863 (gcc::dump_manager::update_dfi_for_opt_info): New decl.
8864 (class gcc::dump_manager): Add fields "m_optgroup_flags",
8865 "m_optinfo_flags", and "m_optinfo_filename".
8866 * passes.c (gcc::pass_manager::register_pass): Move all of the
8867 dump-handling code to gcc::dump_manager::register_pass.
8868
8869 2018-10-04 Peter Bergner <bergner@linux.ibm.com>
8870
8871 PR rtl-optimization/87466
8872 * target.def (setjmp_preserves_nonvolatile_regs_p): New target hook.
8873 * doc/tm.texi.in (TARGET_SETJMP_PRESERVES_NONVOLATILE_REGS_P): New hook.
8874 * doc/tm.texi: Regenerate.
8875 * ira-lives.c (process_bb_node_lives): Use the new target hook.
8876 * lra-lives.c (process_bb_lives): Likewise.
8877 * config/rs6000/rs6000.c (TARGET_SETJMP_PRESERVES_NONVOLATILE_REGS_P):
8878 Define.
8879
8880 2018-10-04 Tamar Christina <tamar.christina@arm.com>
8881
8882 * params.c (add_params): Fix initialization.
8883
8884 2018-10-04 Martin Liska <mliska@suse.cz>
8885
8886 PR gcov-profile/84107
8887 * tree-profile.c (init_ic_make_global_vars):
8888 Remove ic_void_ptr_var and ic_gcov_type_ptr_var.
8889 Come up with new ic_tuple* variables. Emit
8890 __gcov_indirect_call{,_topn} variables.
8891 (gimple_gen_ic_profiler): Access the variable
8892 and emit gimple.
8893 (gimple_gen_ic_func_profiler): Access
8894 __gcov_indirect_call.callee field.
8895 (gimple_init_gcov_profiler): Use ptr_type_node.
8896 * value-prof.c (gimple_ic): Use ptr_type_node.
8897
8898 2018-10-04 Prathamesh Kulkarni <prathamesh.kulkarni@linaro.org>
8899
8900 PR tree-optimization/85787
8901 * ipa-pure-const.c (malloc_candidate_p_1): Move most of
8902 malloc_candidate_p into this function and add support for
8903 detecting multiple phis.
8904 (DUMP_AND_RETURN): Move from malloc_candidate_p into top-level macro.
8905
8906 2018-10-04 Martin Liska <mliska@suse.cz>
8907
8908 PR ipa/87491
8909 * ipa-inline.c (inline_to_all_callers_1):
8910 Call ultimate_alias_target for node being inlined.
8911
8912 2018-10-03 Jeff Law <law@redhat.com>
8913
8914 * gimple-ssa-sprintf.c (format_string): Do not hardcode size of
8915 target's wchar_t.
8916 * tree.c (get_typenode_from_name): Moved from fortran/trans-types.c.
8917 * tree.h (get_typenode_from_name): Prototype.
8918
8919 2018-10-03 Uros Bizjak <ubizjak@gmail.com>
8920
8921 * config/i386/i386.md (*cmp<X87MODEF:mode>_<SWI24:mode>_i387):
8922 Change operand 2 predicate to nonimmediate_operand.
8923 (*cmp<X87MODEF:mode>_<SWI24:mode>_cc_i387): Ditto.
8924
8925 2018-10-03 Martin Sebor <msebor@redhat.com>
8926 Jeff Law <law@redhat.com>
8927
8928 * gimple-ssa-sprintf.c (struct fmtresult): Add new member and
8929 initialize it.
8930 (get_string_length): Detect unterminated arrays.
8931 (format_string): Same.
8932 (format_directive): Warn about unterminated arrays.
8933 (handle_gimple_call): Mark statements with no_warning as needed.
8934
8935 2018-10-03 Jim Wilson <jimw@sifive.com>
8936
8937 * config/riscv/riscv-c.c (riscv_cpu_cpp_builtins): For ABI_ILP32E,
8938 also define __riscv_abi_rve. Delete trailing white space.
8939
8940 2018-10-03 Paul Koning <ni1d@arrl.net>
8941
8942 Enable LRA register allocator for PDP11.
8943 * config/pdp11/constraints.md (Q): Use define_memory_constraint.
8944 (R): Likewise.
8945 (D): Likewise.
8946 * config/pdp11/pdp11.c (pdp11_lra_p): New function.
8947 * config/pdp11/pdp11.opt (-mlra): New option.
8948 * doc/invoke.texi (PDP-11 Options): Document -mlra.
8949
8950 2018-10-03 Uros Bizjak <ubizjak@gmail.com>
8951
8952 * config/i386/i386.md (*<absneg:code>extendsfdf2): Remove.
8953 (*<absneg:code>extend<mode>xf2): Ditto.
8954
8955 2018-10-03 Aldy Hernandez <aldyh@redhat.com>
8956
8957 PR tree-optimization/87415
8958 * tree-vrp.c (set_value_range_with_overflow): Special case one bit
8959 precision fields.
8960
8961 2018-10-02 Jeff Law <law@redhat.com>
8962
8963 * gimple-fold.c (get_range_strlen): Only set *nonstr when
8964 an unterminated string is discovered. Bubble up range
8965 even for unterminated strings.
8966 (gimple_fold_builtin_strlen): Do not fold if get_range_strlen
8967 indicates the string was not terminated via NONSTR.
8968
8969 2018-10-03 Aldy Hernandez <aldyh@redhat.com>
8970
8971 * tree-vrp.c (extract_range_from_unary_expr): Special case all
8972 pointer conversions.
8973 Do not do anything special for anti-ranges.
8974
8975 2018-10-03 Jérôme Lambourg <lambourg@adacore.com>
8976
8977 * config/arm/vxworks.h (ARM_TARGET2_DWARF_FORMAT): Adjust to
8978 DW_EH_PE_pcrel | DW_EH_PE_indirect for RTPs.
8979
8980 2018-10-03 Martin Liska <mliska@suse.cz>
8981
8982 PR gcov-profile/86109
8983 * coverage.c (coverage_begin_function): Do not
8984 mark lambdas as artificial.
8985 * tree-core.h (struct GTY): Remove tm_clone_flag
8986 and introduce new lambda_function.
8987 * tree.h (DECL_LAMBDA_FUNCTION): New macro.
8988
8989 2018-10-02 Aaron Sawdey <acsawdey@linux.ibm.com>
8990
8991 PR target/87474
8992 * config/rs6000/rs6000-string.c (expand_strn_compare): Check that both
8993 P8_VECTOR and VSX are enabled.
8994
8995 2018-10-02 Andreas Krebbel <krebbel@linux.ibm.com>
8996
8997 * config/s390/driver-native.c (s390_host_detect_local_cpu): Add
8998 0x3907 as CPU model number.
8999
9000 2018-10-02 Andreas Krebbel <krebbel@linux.ibm.com>
9001
9002 * common/config/s390/s390-common.c: Rename PF_ARCH12 to PF_Z14.
9003 * config/s390/s390.h (enum processor_flags): Rename PF_ARCH12 to
9004 PF_Z14. Rename TARGET_CPU_ARCH12 to TARGET_CPU_Z14,
9005 TARGET_CPU_ARCH12_P to TARGET_CPU_Z14_P, TARGET_ARCH12 to
9006 TARGET_Z14, and TARGET_ARCH12_P to TARGET_Z14_P.
9007 * config/s390/s390.md: Likewise. Rename also the cpu attribute
9008 value from arch12 to z14.
9009
9010 2018-10-02 Uros Bizjak <ubizjak@gmail.com>
9011
9012 * config/i386/i386.md (fxam<mode>2_i387_with_temp): Remove.
9013 (isinfxf2): Ditto.
9014 (isinf<mode>2): Ditto.
9015
9016 2018-10-02 Uros Bizjak <ubizjak@gmail.com>
9017
9018 * config/i386/i386.c (ix86_emit_i387_round): Extend op1 to XFmode
9019 before emitting fxam. Perform calculations in XFmode.
9020
9021 2018-10-02 Marc Glisse <marc.glisse@inria.fr>
9022
9023 * match.pd (((X /[ex] A) +- B) * A): New transformation.
9024
9025 2018-10-02 Marc Glisse <marc.glisse@inria.fr>
9026
9027 PR middle-end/87319
9028 * fold-const.c (fold_plusminus_mult_expr): Handle complex and vectors.
9029 * tree.c (signed_or_unsigned_type_for): Handle complex.
9030
9031 2018-10-02 Jeff Law <law@redhat.com>
9032
9033 * gimple-fold.c (get_range_strlen): Remove dead code.
9034
9035 2018-10-02 Martin Sebor <msebor@redhat.com>
9036 Jeff Law <law@redhat.com>
9037
9038 * builtins.c (unterminated_array): Add new arguments.
9039 If argument is not terminated, bubble up size and exact
9040 state to callers.
9041 (expand_builtin_strnlen): Detect, avoid expanding
9042 and diagnose unterminated arrays.
9043 (c_strlen): Fill in offset of start of unterminated strings.
9044 * builtins.h (unterminated_array): Update prototype.
9045
9046 2018-10-02 Richard Biener <rguenther@suse.de>
9047
9048 * config/i386/sse.md (reduc_plus_scal_v4df): Avoid the use
9049 of haddv4df, first reduce to SSE width and exploit the fact
9050 that we only need element zero with the reduction result.
9051 (reduc_plus_scal_v2df): Likewise.
9052
9053 2018-10-02 Eric Botcazou <ebotcazou@adacore.com>
9054
9055 * dojump.h (do_jump): Delete.
9056 (do_jump_1): Likewise.
9057 (split_comparison): Move around.
9058 * dojump.c (do_jump): Make static.
9059 (do_jump_1): Likewise.
9060 (jumpifnot): Move around.
9061 (jumpifnot_1): Likewise.
9062 (jumpif): Likewise.
9063 (jumpif_1): Likewise.
9064 * expr.c (expand_expr_real_1): Call jumpif[not] instead of do_jump.
9065
9066 2018-10-02 Eric Botcazou <ebotcazou@adacore.com>
9067
9068 * reorg.c (make_return_insns): Use emit_copy_of_insn_after for the
9069 insns in the delay slot and add_insn_after for the jump insn.
9070
9071 2018-10-02 Richard Biener <rguenther@suse.de>
9072
9073 * tree-inline.c (expand_call_inline): Use the location of
9074 the callee declaration for the inline-entry marker.
9075 * final.c (notice_source_line): Remove special-casing of
9076 NOTE_INSN_INLINE_ENTRY.
9077
9078 2018-10-01 Carl Love <cel@us.ibm.com>
9079
9080 PR 69431
9081 * config/rs6000/rs6000-builtin.def (__builtin_mffsl): New.
9082 (__builtin_mtfsb0): New.
9083 (__builtin_mtfsb1): New.
9084 ( __builtin_set_fpscr_rn): New.
9085 (__builtin_set_fpscr_drn): New.
9086 * config/rs6000/rs6000.c (rs6000_expand_mtfsb_builtin): Add.
9087 (rs6000_expand_set_fpscr_rn_builtin): Add.
9088 (rs6000_expand_set_fpscr_drn_builtin): Add.
9089 (rs6000_expand_builtin): Add case statement entries for
9090 RS6000_BUILTIN_MTFSB0, RS6000_BUILTIN_MTFSB1,
9091 RS6000_BUILTIN_SET_FPSCR_RN, RS6000_BUILTIN_SET_FPSCR_DRN,
9092 RS6000_BUILTIN_MFFSL.
9093 (rs6000_init_builtins): Add ftype initialization and def_builtin
9094 calls for __builtin_mffsl, __builtin_mtfsb0, __builtin_mtfsb1,
9095 __builtin_set_fpscr_rn, __builtin_set_fpscr_drn.
9096 * config/rs6000.md (rs6000_mtfsb0, rs6000_mtfsb1, rs6000_mffscrn,
9097 rs6000_mffscdrn): Add define_insn.
9098 (rs6000_set_fpscr_rn, rs6000_set_fpscr_drn): Add define_expand.
9099 * doc/extend.texi: Add documentation for the builtins.
9100
9101 2018-10-01 Richard Biener <rguenther@suse.de>
9102
9103 PR tree-optimization/87465
9104 * tree-ssa-loop-ivcanon.c (tree_estimate_loop_size): Fix typo
9105 causing branch miscounts.
9106
9107 2018-10-01 Tamar Christina <tamar.christina@arm.com>
9108
9109 * common/config/aarch64/aarch64-common.c (TARGET_OPTION_DEFAULT_PARAM,
9110 aarch64_option_default_param): New.
9111 (params.h): Include.
9112 (TARGET_OPTION_VALIDATE_PARAM, aarch64_option_validate_param): New.
9113 * config/aarch64/aarch64.c (aarch64_override_options_internal): Simplify
9114 stack-clash protection validation code.
9115
9116 2018-10-01 Tamar Christina <tamar.christina@arm.com>
9117
9118 * params.c (validate_param): New.
9119 (add_params): Use it.
9120 (set_param_value): Refactor param validation into validate_param.
9121 (diagnostic.h): Include.
9122 * diagnostic.h (diagnostic_ready_p): New.
9123
9124 2018-10-01 Tamar Christina <tamar.christina@arm.com>
9125
9126 * params.c (set_param_value):
9127 Add index of parameter being validated.
9128 * common/common-target.def (option_validate_param): New.
9129 * common/common-targhooks.h (default_option_validate_param): New.
9130 * common/common-targhooks.c (default_option_validate_param): New.
9131 * doc/tm.texi.in (TARGET_OPTION_VALIDATE_PARAM): New.
9132 * doc/tm.texi: Regenerate.
9133
9134 2018-10-01 Tamar Christina <tamar.christina@arm.com>
9135
9136 PR target/86486
9137 * config/aarch64/aarch64.c (aarch64_override_options_internal):
9138 Add validation for stack-clash parameters and set defaults.
9139
9140 2018-10-01 Tamar Christina <tamar.christina@arm.com>
9141
9142 PR target/86486
9143 * configure.ac: Add stack-clash-protection-guard-size.
9144 * doc/install.texi: Document it.
9145 * config.in (DEFAULT_STK_CLASH_GUARD_SIZE): New.
9146 * params.def: Update comment for guard-size.
9147 (PARAM_STACK_CLASH_PROTECTION_GUARD_SIZE,
9148 PARAM_STACK_CLASH_PROTECTION_PROBE_INTERVAL): Update description.
9149 * configure: Regenerate.
9150
9151 2018-10-01 Tamar Christina <tamar.christina@arm.com>
9152
9153 PR target/86486
9154 * config/aarch64/aarch64.h (STACK_CLASH_MIN_BYTES_OUTGOING_ARGS,
9155 STACK_DYNAMIC_OFFSET): New.
9156 * config/aarch64/aarch64.c (aarch64_layout_frame):
9157 Update outgoing args size.
9158 (aarch64_stack_clash_protection_alloca_probe_range,
9159 TARGET_STACK_CLASH_PROTECTION_ALLOCA_PROBE_RANGE): New.
9160
9161 2018-10-01 Tamar Christina <tamar.christina@arm.com>
9162
9163 PR target/86486
9164 * explow.c (anti_adjust_stack_and_probe_stack_clash): Support custom
9165 probe ranges.
9166 * target.def (stack_clash_protection_alloca_probe_range): New.
9167 (stack_clash_protection_final_dynamic_probe): Remove.
9168 * targhooks.h (default_stack_clash_protection_alloca_probe_range) New.
9169 (default_stack_clash_protection_final_dynamic_probe): Remove.
9170 * targhooks.c: Likewise.
9171 * doc/tm.texi.in (TARGET_STACK_CLASH_PROTECTION_ALLOCA_PROBE_RANGE): New.
9172 (TARGET_STACK_CLASH_PROTECTION_FINAL_DYNAMIC_PROBE): Remove.
9173 * doc/tm.texi: Regenerate.
9174
9175 2018-10-01 Tamar Christina <tamar.christina@arm.com>
9176
9177 PR target/86486
9178 * config/aarch64/aarch64-protos.h (aarch64_output_probe_sve_stack_clash): New.
9179 * config/aarch64/aarch64.c (aarch64_output_probe_sve_stack_clash,
9180 aarch64_clamp_to_uimm12_shift): New.
9181 (aarch64_allocate_and_probe_stack_space): Add SVE specific section.
9182 * config/aarch64/aarch64.md (probe_sve_stack_clash): New.
9183
9184 2018-10-01 Tamar Christina <tamar.christina@arm.com>
9185
9186 PR target/86486
9187 * config/aarch64/aarch64.c (aarch64_layout_frame): Add assert.
9188
9189 2018-10-01 Jeff Law <law@redhat.com>
9190 Richard Sandiford <richard.sandiford@linaro.org>
9191 Tamar Christina <tamar.christina@arm.com>
9192
9193 PR target/86486
9194 * config/aarch64/aarch64.md
9195 (probe_stack_range): Add k (SP) constraint.
9196 * config/aarch64/aarch64.h (STACK_CLASH_CALLER_GUARD,
9197 STACK_CLASH_MAX_UNROLL_PAGES): New.
9198 * config/aarch64/aarch64.c (aarch64_output_probe_stack_range): Emit
9199 stack probes for stack clash.
9200 (aarch64_allocate_and_probe_stack_space): New.
9201 (aarch64_expand_prologue): Use it.
9202 (aarch64_expand_epilogue): Likewise and update IP regs re-use criteria.
9203 (aarch64_sub_sp): Add emit_move_imm optional param.
9204
9205 2018-10-01 MCC CS <deswurstes@users.noreply.github.com>
9206
9207 PR tree-optimization/87261
9208 * match.pd: Remove trailing whitespace.
9209 Add (x & y) | ~(x | y) -> ~(x ^ y),
9210 (~x | y) ^ (x ^ y) -> x | ~y and (x ^ y) | ~(x | y) -> ~(x & y)
9211
9212 2018-10-01 Claudiu Zissulescu <claziss@synopsys.com>
9213
9214 * config/arc/arc.md (*add_n): Clean up pattern, update instruction
9215 constraints.
9216 (ashlsi3_insn): Update instruction constraints.
9217 (ashrsi3_insn): Likewise.
9218 (rotrsi3): Likewise.
9219 (add_shift): Likewise.
9220 * config/arc/constraints.md (Csz): New 32 bit constraint. It
9221 avoids placing in the limm field small constants which, otherwise,
9222 could end into a small instruction.
9223
9224 2018-10-01 Claudiu Zissulescu <claziss@synopsys.com>
9225
9226 * config/arc/arc.md (maddsidi4_split): Don't use dmac if the
9227 destination register is not odd-even.
9228 (umaddsidi4_split): Likewise.
9229
9230 2018-10-01 Richard Biener <rguenther@suse.de>
9231
9232 * tree-inline.c (expand_call_inline): Store origin of fn
9233 in BLOCK_ABSTRACT_ORIGIN for the inline BLOCK.
9234 * tree.c (block_ultimate_origin): Simplify and do some
9235 checking.
9236
9237 2018-09-30 Uros Bizjak <ubizjak@gmail.com>
9238
9239 * config/i386/mmx.md (EMMS): New int iterator.
9240 (emms): New int attribute.
9241 (mmx_<emms>): Macroize insn from *mmx_emms and *mmx_femms using
9242 EMMS int iterator. Explicitly declare clobbers.
9243 (mmx_emms): Remove expander.
9244 (mmx_femms): Ditto.
9245 * config/i386/predicates.md (emms_operation): Remove predicate.
9246 (vzeroall_pattern): New predicate.
9247 (vzeroupper_pattern): Rename from vzeroupper_operation.
9248 * config/i386/i386.c (ix86_avx_u128_mode_after): Use
9249 vzeroupper_pattern and vzeroall_pattern predicates.
9250
9251 2018-09-30 Peter Bergner <bergner@linux.ibm.com>
9252
9253 PR rtl-optimization/86939
9254 * ira-lives.c (make_hard_regno_born): Rename from this...
9255 (make_hard_regno_live): ... to this. Remove update to conflict
9256 information. Update function comment.
9257 (make_hard_regno_dead): Add conflict information update. Update
9258 function comment.
9259 (make_object_born): Rename from this...
9260 (make_object_live): ... to this. Remove update to conflict information.
9261 Update function comment.
9262 (make_object_dead): Add conflict information update. Update function
9263 comment.
9264 (mark_pseudo_regno_live): Call make_object_live.
9265 (mark_pseudo_regno_subword_live): Likewise.
9266 (mark_hard_reg_dead): Update function comment.
9267 (mark_hard_reg_live): Call make_hard_regno_live.
9268 (process_bb_node_lives): Likewise.
9269 * lra-lives.c (make_hard_regno_born): Rename from this...
9270 (make_hard_regno_live): ... to this. Remove update to conflict
9271 information. Remove now uneeded check_pic_pseudo_p argument.
9272 Update function comment.
9273 (make_hard_regno_dead): Add check_pic_pseudo_p argument and add update
9274 to conflict information. Update function comment.
9275 (mark_pseudo_live): Remove update to conflict information. Update
9276 function comment.
9277 (mark_pseudo_dead): Add conflict information update.
9278 (mark_regno_live): Call make_hard_regno_live.
9279 (mark_regno_dead): Call make_hard_regno_dead with new arguement.
9280 (process_bb_lives): Call make_hard_regno_live and make_hard_regno_dead.
9281
9282 2018-09-29 H.J. Lu <hongjiu.lu@intel.com>
9283
9284 PR target/87370
9285 * config/i386/i386.c (construct_container): Use TImode for
9286 BLKmode values in 2 integer registers.
9287
9288 2018-09-29 Jeff Law <law@redhat.com>
9289
9290 * builtins.c (unterminated_array): Pass in c_strlen_data * to
9291 c_strlen rather than just a tree *.
9292 (c_strlen): Change NONSTR argument to a c_strlen_data pointer.
9293 Update recursive calls appropriately. If caller did not provide a
9294 suitable data pointer, create a local one. When a non-terminated
9295 string is discovered, bubble up information about the string via the
9296 c_strlen_data object.
9297 * builtins.h (c_strlen): Update prototype.
9298 (c_strlen_data): New structure.
9299 * gimple-fold.c (get_range_strlen): Update calls to c_strlen.
9300 For a type 2 call, if c_strlen indicates a non-terminated string
9301 use the length of the non-terminated string.
9302 (gimple_fold_builtin_stpcpy): Update calls to c_strlen.
9303
9304 2018-09-29 Jakub Jelinek <jakub@redhat.com>
9305
9306 PR target/87467
9307 * config/i386/avx512fintrin.h (_mm512_abs_pd, _mm512_mask_abs_pd): Use
9308 __m512d type for __A argument rather than __m512.
9309
9310 2018-09-28 John David Anglin <danglin@gcc.gnu.org>
9311
9312 * match.pd (simple_comparison): Don't optimize if either operand is
9313 a function pointer when target needs function pointer canonicalization.
9314
9315 2018-09-28 Segher Boessenkool <segher@kernel.crashing.org>
9316
9317 * config/rs6000/driver-rs6000.c (asm_names): Adjust the entries for
9318 power5 .. power9 to remove indirection.
9319 * config/rs6000/rs6000.h (ASM_CPU_POWER5_SPEC, ASM_CPU_POWER6_SPEC,
9320 ASM_CPU_POWER7_SPEC, ASM_CPU_POWER8_SPEC, ASM_CPU_POWER9_SPEC,
9321 ASM_CPU_476_SPEC): Delete.
9322 (ASM_CPU_SPEC): Adjust.
9323 (EXTRA_SPECS): Delete asm_cpu_power5, asm_cpu_power6, asm_cpu_power7,
9324 asm_cpu_power8, asm_cpu_power9, asm_cpu_476.
9325
9326 2018-09-28 Segher Boessenkool <segher@kernel.crashing.org>
9327
9328 * config.in: Delete HAVE_AS_DCI.
9329 * config/powerpcspe/powerpcspe.h: Treat HAVE_AS_DCI as always true.
9330 * config/rs6000/rs6000.h: Ditto.
9331 * configure.ac: Delete HAVE_AS_DCI.
9332 * configure: Regenerate.
9333
9334 2018-09-28 Segher Boessenkool <segher@kernel.crashing.org>
9335
9336 * config.in (HAVE_AS_LWSYNC): Delete.
9337 * config/powerpcspe/powerpcspe.h (TARGET_LWSYNC_INSTRUCTION): Delete.
9338 * config/powerpcspe/sync.md (*lwsync): Always generate lwsync, never
9339 do it as a .long .
9340 * config/rs6000/rs6000.h (TARGET_LWSYNC_INSTRUCTION): Delete.
9341 * config/rs6000/sync.md (*lwsync): Always generate lwsync, never do it
9342 as a .long .
9343 * configure.ac: Delete HAVE_AS_LWSYNC.
9344 * configure: Regenerate.
9345
9346 2018-09-28 Eric Botcazou <ebotcazou@adacore.com>
9347 Pierre-Marie de Rodat <derodat@adacore.com>
9348
9349 * calls.c (expand_call): Try to do a tail call for thunks at -O0 too.
9350 * cgraph.h (struct cgraph_thunk_info): Add indirect_offset.
9351 (cgraph_node::create_thunk): Add indirect_offset parameter.
9352 (thunk_adjust): Likewise.
9353 * cgraph.c (cgraph_node::create_thunk): Add indirect_offset parameter
9354 and initialize the corresponding field with it.
9355 (cgraph_node::dump): Dump indirect_offset field.
9356 * cgraphclones.c (duplicate_thunk_for_node): Deal with indirect_offset.
9357 * cgraphunit.c (cgraph_node::analyze): Be prepared for external thunks.
9358 (thunk_adjust): Add indirect_offset parameter and deal with it.
9359 (cgraph_node::expand_thunk): Deal with the indirect_offset field and
9360 pass it to thunk_adjust. Do not call the target hook if it's non-zero
9361 or if the thunk is external or local. Fix formatting. Do not chain
9362 the RESULT_DECL to BLOCK_VARS. Pass the static chain to the target,
9363 if any, in the GIMPLE representation.
9364 * ipa-icf.c (sem_function::equals_wpa): Deal with indirect_offset.
9365 * lto-cgraph.c (lto_output_node): Write indirect_offset field.
9366 (input_node): Read indirect_offset field.
9367 * tree-inline.c (expand_call_inline): Pass indirect_offset field in the
9368 call to thunk_adjust.
9369 * tree-nested.c (struct nesting_info): Add thunk_p field.
9370 (create_nesting_tree): Set it.
9371 (convert_all_function_calls): Copy static chain from targets to thunks.
9372 (finalize_nesting_tree_1): Return early for thunks.
9373 (unnest_nesting_tree_1): Do not finalize thunks.
9374 (gimplify_all_functions): Do not gimplify thunks.
9375
9376 2018-09-28 David Malcolm <dmalcolm@redhat.com>
9377
9378 * opt-suggestions.c (option_proposer::build_option_suggestions):
9379 Release "option_values".
9380
9381 2018-09-28 David Malcolm <dmalcolm@redhat.com>
9382
9383 * coverage.c (get_coverage_counts): Convert problem-reporting dump
9384 messages from MSG_OPTIMIZED_LOCATIONS to MSG_MISSED_OPTIMIZATION.
9385 * dumpfile.c (kind_as_string): New function.
9386 (dump_loc): Rather than a hardcoded prefix of "note: ", use
9387 kind_as_string to vary the prefix based on dump_kind.
9388 (selftest::test_capture_of_dump_calls): Update for above.
9389
9390 2018-09-28 Uros Bizjak <ubizjak@gmail.com>
9391
9392 * config/i386/i386.h (SSE_REGNO): Fix check for FIRST_REX_SSE_REG.
9393 (GET_SSE_REGNO): Rename from SSE_REGNO. Update all uses for rename.
9394
9395 2018-09-28 Uros Bizjak <ubizjak@gmail.com>
9396
9397 * config/i386/i386.h (CC_REGNO): Remove FPSR_REG.
9398 * config/i386/i386.c (ix86_fixed_condition_code_regs): Use
9399 INVALID_REGNUM instead of FPSR_REG.
9400 (ix86_md_asm_adjust): Do not clobber FPSR_REG.
9401 * config/i386/i386.md: Update comment of FP compares.
9402 (fldenv): Do not clobber FPSR_REG.
9403
9404 2018-09-28 Richard Biener <rguenther@suse.de>
9405
9406 * tree.h (BLOCK_ORIGIN): New.
9407 * omp-expand.c (grid_expand_target_grid_body): Assign
9408 BLOCK_ORIGIN to BLOCK_ABSTRACT_ORIGIN.
9409 * tree-inline.c (remap_block): Likewise.
9410 * auto-profile.c (get_function_decl_from_block): Simplify
9411 by eliding the BLOCK_ABSTRACT_ORIGIN chasing.
9412 * langhooks.c (lhd_print_error_function): Likewise.
9413 * optinfo-emit-json.cc (optrecord_json_writer::inlining_chain_to):
9414 Likewise.
9415 * tree-ssa-live.c (remove_unused_scope_block_p): Likewise.
9416 * tree.c (block_nonartificial_location): Likewise.
9417 (block_ultimate_origin): Likewise.
9418 * tree-pretty-print.c (percent_K_format): Likewise. Remove
9419 no longer needed LTO case.
9420
9421 2018-09-28 Andrew Stubbs <ams@codesourcery.com>
9422 Jan Hubicka <jh@suse.cz>
9423 Martin Jambor <mjambor@suse.cz>
9424
9425 * simplify-rtx.c (simplify_merge_mask): New function.
9426 (simplify_ternary_operation): Use it, also see if VEC_MERGEs with the
9427 same masks are used in op1 or op2.
9428 (test_vec_merge): New function.
9429 (test_vector_ops): Call test_vec_merge.
9430
9431 2018-09-28 Eric Botcazou <ebotcazou@adacore.com>
9432
9433 * config/sparc/sparc-protos.h (sparc_branch_cost): Declare.
9434 * config/sparc/sparc.h (BRANCH_COST): Call sparc_branch_cost.
9435 * config/sparc/sparc.c (struct processor_costs): Add branch_cost field.
9436 (cypress_costs): Set it.
9437 (supersparc_costs): Likewise.
9438 (hypersparc_costs): Likewise.
9439 (leon_cost): Likewise.
9440 (leon3_costs): Likewise.
9441 (sparclet_costs): Likewise.
9442 (ultrasparc_costs): Likewise.
9443 (ultrasparc_costs): Likewise.
9444 (niagara_costs): Likewise.
9445 (niagara2_costs): Likewise.
9446 (niagara3_costs): Likewise.
9447 (niagara4_costs): Likewise.
9448 (niagara7_costs): Likewise.
9449 (m8_costs): Likewise.
9450 (TARGET_CAN_FOLLOW_JUMP): Define.
9451 (pass_work_around_errata::gate): Minor tweak.
9452 (sparc_option_override): Remove MASK_FSMULD mask for V7 processors.
9453 Do not set both MASK_VIS4 and MASK_VIS4B for M8 processor.
9454 Automaitcally clear MASK_FSMULD mask for V7 processors.
9455 (sparc_can_follow_jump): New static function.
9456 (output_ubranch): Deal with CROSSING_JUMP_P.
9457 (sparc_use_sched_lookahead): Rewrite using switch statement.
9458 (sparc_issue_rate): Reorder.
9459 (sparc_branch_cost): New function.
9460
9461 2018-09-27 Martin Sebor <msebor@redhat.com>
9462
9463 * tree.h (tree_to_shwi): Add attribute nonnull and pure.
9464 (tree_to_poly_int64, tree_to_uhwi, tree_to_poly_uint64): Same.
9465 (int_fits_type_p): Same.
9466
9467 2018-09-27 Uros Bizjak <ubizjak@gmail.com>
9468
9469 * config/i386/i386.md (FPCR_REG): Remove.
9470 (UNSPEC_FLDCW): Remove.
9471 (x86_fnstcw_1): Use (const_int 0) instead of FPCR_REG.
9472 (x86_fldcw_1): Remove insn pattern.
9473 (fnstenv): Do not clobber FPCR_REG.
9474 (fldenv): Ditto.
9475 * config/i386/i386.h (FIXED_REGISTERS) Remove fpsr register.
9476 (CALL_USED_REGISTERS): Ditto.
9477 (REG_ALLOC_ORDER): Ditto.
9478 (REG_CLASS_CONTENTS): Ditto.
9479 (HI_REGISTER_NAMES): Ditto.
9480 (ADDITIONAL_REGISTER_NAMES): Use defines instead
9481 of numerical constants.
9482 * config/i386/i386.c (regclass_map): Remove fpsr register.
9483 (dbx_register_map): Ditto.
9484 (dbx64_register_map): Ditto.
9485 (svr4_dbx_register_map): Ditto.
9486 (print_reg): Do not handle FPCR_REG.
9487
9488 2018-09-27 Segher Boessenkool <segher@kernel.crashing.org>
9489
9490 PR target/87149
9491 * config.in (HAVE_AS_CMPB, HAVE_AS_DFP, HAVE_AS_FPRND, HAVE_AS_MFPGPR,
9492 HAVE_AS_POPCNTB, HAVE_AS_POPCNTD, HAVE_AS_POWER8, HAVE_AS_POWER9):
9493 Delete, always treat as true.
9494 * config/powerpcspe/powerpcspe.c (rs6000_option_override_internal):
9495 Ditto. Simplify remaining code.
9496 * config/powerpcspe/powerpcspe.h: Ditto.
9497 * config/rs6000/rs6000.c (rs6000_option_override_internal): Ditto.
9498 Simplify remaining code.
9499 (rs6000_expand_builtin): Ditto.
9500 * config/rs6000/rs6000.h: Ditto.
9501 * configure.ac: Ditto.
9502 * configure: Regenerate.
9503
9504 2018-09-27 Martin Liska <mliska@suse.cz>
9505
9506 * coverage.c (get_coverage_counts): Revert the formatting
9507 of missing profile opt info.
9508
9509 2018-09-27 Richard Biener <rguenther@suse.de>
9510
9511 PR debug/37801
9512 PR debug/87440
9513 * dwarf2out.c (set_block_origin_self): Do not mark outermost
9514 block as we do not output that.
9515 (gen_inlined_subroutine_die): Elide the originally outermost
9516 block, matching what we do for concrete instances.
9517 (decls_for_scope): Add parameter specifying whether to recurse
9518 to subblocks.
9519
9520 2018-09-27 Andrew Stubbs <ams@codesourcery.com>
9521 Tom de Vries <tom@codesourcery.com>
9522
9523 PR 82089
9524
9525 * expmed.c (emit_cstore): Fix handling of result_mode == BImode and
9526 STORE_FLAG_VALUE == 1.
9527
9528 2018-09-27 Andreas Krebbel <krebbel@linux.ibm.com>
9529
9530 * config/s390/s390.md (PPA_TX_ABORT, PPA_OOO_BARRIER): New
9531 constant definitions.
9532 ("tx_assist"): Replace magic number with PPA_TX_ABORT.
9533 ("*ppa"): Enable pattern also for -march=zEC12 -mno-htm.
9534 ("speculation_barrier"): New expander definition.
9535
9536 2018-09-26 Indu Bhagat <indu.bhagat@oracle.com>
9537
9538 PR gcov-profile/86957
9539 * common.opt: New warning option -Wmissing-profile.
9540 * coverage.c (get_coverage_counts): Add warning for missing .gcda file.
9541 * doc/invoke.texi: Document -Wmissing-profile.
9542
9543 2018-09-26 Jim Wilson <jimw@sifive.com>
9544
9545 * config/riscv/riscv.md (subsi3_extended2): Add J constraint.
9546 (negdi2, negsi2, negsi2_extended, negsi2_extended2): New.
9547
9548 2018-09-26 Martin Sebor <msebor@redhat.com>
9549
9550 * tree.c (zerop): Change return type to bool.
9551 (integer_zerop, integer_onep, integer_each_onep): Same.
9552 (integer_all_onesp, integer_minus_onep, integer_pow2p): Same.
9553 (integer_nonzerop, integer_truep, tree_ctz, real_zerop): Same.
9554 (real_onep, real_minus_onep, chain_index): Same.
9555 (print_type_hash_statistics, type_list_equal): Same.
9556 * tree.h (zerop): Same.
9557 (zerop, integer_zerop, integer_onep, integer_each_onep): Same.
9558 (integer_all_onesp, integer_minus_onep, integer_pow2p): Same.
9559 (integer_nonzerop, integer_truep, tree_ctz, real_zerop): Same.
9560 (real_onep, real_minus_onep, chain_index): Same.
9561 (print_type_hash_statistics, type_list_equal): Same.
9562
9563 2018-09-26 Jim Wilson <jimw@sifive.com>
9564
9565 * config/riscv/riscv.h (FUNCTION_ARG_REGNO_P): Fix comment.
9566
9567 2018-09-26 Jakub Jelinek <jakub@redhat.com>
9568
9569 PR target/87414
9570 * config/i386/i386.c: Include debug.h and dwarf2out.h.
9571 (output_indirect_thunk): Emit DW_CFA_def_cfa_offset after the
9572 call.
9573
9574 2018-09-25 Andrew Stubbs <ams@codesourcery.com>
9575
9576 * builtins.c (get_builtin_sync_mem): Force address mode conversion.
9577
9578 2018-09-26 Uros Bizjak <ubizjak@gmail.com>
9579
9580 * config/i386/i386.h (enum reg_class): Remove FP_TOP_SSE_REGS
9581 and FP_SECOND_SSE_REGS.
9582 (REG_CLASS_NAMES): Ditto.
9583 (REG_CLASS_CONTENTS): Ditto.
9584 * config/i386/i386.c (ix86_preferred_reload_class) Do not handle
9585 FP_TOP_SSE_REGS and FP_SECOND_SSE_REGS classes.
9586 (ix86_preferred_output_reload_class): Ditto.
9587 * config/i386/i386.md (fix_trunc<mode>_i387_fisttp): Change "=&1f"
9588 clobber constraint to "=&f".
9589 (fix_truncdi_i387): Ditto.
9590 (lrintxfdi2): Ditto.
9591 (fistdi2_<rounding>): Ditto.
9592 (fpremxf4_i387): Change "=u" constraint to "=f".
9593 (fprem1xf4_i387): Ditto.
9594 (sincosxf3): Ditto.
9595 (fptanxf4_i387): Ditto.
9596 (fxtractxf3_i387): Ditto.
9597 (fscalexf4_i387): Ditto.
9598 (atan2xf3): Change "u" constraint to "f".
9599 (fyl2xxf3_i387): Ditto.
9600 (fyl2xp1xf3_i387): Ditto.
9601
9602 2018-09-26 Uros Bizjak <ubizjak@gmail.com>
9603
9604 PR target/87439
9605 * config/i386/i386.h (NUM_MODES_FOR_MODE_SWITCHING): Update
9606 for removed I387_MASK_PM entity.
9607
9608
9609 2018-09-26 Jeff Law <law@redhat.com>
9610 Revert
9611 2018-09-26 Alexey Neyman <stilor@att.net>
9612
9613 * graphite.h: Include <isl/id.h> and <isl/space.h>; these
9614 headers are no longer pulled in by <isl/val.h>.
9615
9616 2018-09-26 Richard Biener <rguenther@suse.de>
9617
9618 PR debug/87443
9619 * dwarf2out.c (gen_lexical_block_die): Do not equate inline
9620 or concrete instance DIE to the tree. Create abstract origin
9621 attributes also for concrete instances.
9622
9623 2018-09-26 Alexey Neyman <stilor@att.net>
9624
9625 * graphite.h: Include <isl/id.h> and <isl/space.h>; these
9626 headers are no longer pulled in by <isl/val.h>.
9627
9628 2018-09-26 Matthew Malcomson <matthew.malcomson@arm.com>
9629
9630 * config/arm/arm.c (arm_split_compare_and_swap, arm_split_atomic_op):
9631 Use new helper functions.
9632 * config/arm/sync.md (atomic_load<mode>, atomic_store<mode>):
9633 Use new helper functions.
9634 * config/arm/aarch-common-protos.h (aarch_mm_needs_acquire,
9635 aarch_mm_needs_release): New declarations.
9636 * config/arm/aarch-common.c (aarch_mm_needs_acquire,
9637 aarch_mm_needs_release): New.
9638
9639 2018-09-26 Eric Botcazou <ebotcazou@adacore.com>
9640
9641 * config/arm/arm.c (arm_reorg): Skip Thumb reorg pass for thunks.
9642 (arm32_output_mi_thunk): Deal with long calls.
9643
9644 2018-09-26 Richard Biener <rguenther@suse.de>
9645
9646 PR debug/87428
9647 PR debug/87362
9648 * tree-inline.c (expand_call_inline): When the location
9649 of the call is UNKNOWN_LOCATION use DECL_SOURCE_LOCATION
9650 or BUILTINS_LOCATION for the BLOCK_SOURCE_LOCATION of
9651 the inserted BLOCK to make inlined_function_outer_scope_p
9652 recognize it.
9653 * dwarf2out.c (add_call_src_coords_attributes): Do not add
9654 coords for reserved locations.
9655
9656 2018-09-25 Segher Boessenkool <segher@kernel.crashing.org>
9657
9658 * config/rs6000/rs6000.md (*movcc_internal1): Use set_attr_alternative.
9659 (*call_indirect_nonlocal_sysv<mode>): Ditto.
9660 (*call_value_indirect_nonlocal_sysv<mode>): Ditto.
9661 (*sibcall_nonlocal_sysv<mode>): Ditto.
9662 (*sibcall_value_nonlocal_sysv<mode>): Ditto.
9663 (<bd>_<mode>): Ditto.
9664 (<bd>tf_<mode>): Ditto.
9665
9666 2018-09-25 Segher Boessenkool <segher@kernel.crashing.org>
9667
9668 * config/rs6000/altivec.md (*altivec_mov<mode>): Write the output
9669 control string as a list of templates instead of as C code.
9670 (*altivec_movti): Ditto.
9671 * config/rs6000/darwin.md (movdf_low_di): Ditto.
9672
9673 2018-09-25 Jim Wilson <jimw@sifive.com>
9674
9675 * config/riscv/riscv.c (riscv_split_symbol): Mark auipc label as weak
9676 when target symbol is weak.
9677
9678 2018-09-25 Bernd Edlinger <bernd.edlinger@hotmail.de>
9679
9680 PR c/87387
9681 * builtins.c (unterminated_array): Simplify.
9682 * expr.c (string_constant): Handle SSA_NAME. Add more exceptions
9683 where pointer arithmetic is safe.
9684
9685 2018-09-25 Segher Boessenkool <segher@kernel.crashing.org>
9686
9687 PR target/86987
9688 * config/rs6000/altivec.md (altivec_vspltb): Use
9689 const_0_to_15_operand instead of u5bit_cint_operand.
9690 (*altivec_vspltb_internal): Ditto.
9691 (altivec_vspltb_direct): Ditto.
9692 (altivec_vsplth): Use const_0_to_7_operand instead of
9693 u5bit_cint_operand.
9694 (*altivec_vsplth_internal): Ditto.
9695 (altivec_vsplth_direct): Ditto.
9696 (altivec_vspltw): Use const_0_to_3_operand instead of
9697 u5bit_cint_operand.
9698 (*altivec_vspltw_internal): Ditto.
9699 (altivec_vspltw_direct): Ditto.
9700 (altivec_vspltsf): Ditto.
9701 (*altivec_vspltsf_internal): Ditto.
9702 * config/rs6000/rs6000.c (rs6000_expand_binop_builtin): Handle the
9703 various splats with the proper size immediate. Reorder the various
9704 cases by ascending size of immediate, and put all such together.
9705
9706 2018-09-25 Richard Biener <rguenther@suse.de>
9707
9708 PR debug/83941
9709 * dwarf2out.c (add_AT_external_die_ref): Remove now redundant
9710 GC-ification.
9711 (maybe_create_die_with_external_ref): Do not create
9712 DW_TAG_imported_unit here.
9713 (add_abstract_origin_attribute): Handle external BLOCK refs.
9714 (dwarf2out_abstract_function): Simplify LTO case.
9715 (dwarf2out_early_finish): Create DW_TAG_imported_unit explicitely
9716 rather than using maybe_create_die_with_external_ref.
9717
9718 2018-09-25 Uros Bizjak <ubizjak@gmail.com>
9719
9720 PR target/71278
9721 * config/i386/i386.md (frndintxf2_mask_pm): Remove.
9722 (frndintxf2_mask_pm_i387): Ditto.
9723 (nearbyintxf2): Rewrite expander pattern to match rintxf2.
9724 Enable for !flag_trapping_math.
9725 (nearbyint<mode>2): Enable x87 modes for !flag_trapping_math.
9726 Enable SSE modes for TARGET_SSE4_1 and expand them with round insn.
9727 Change operand 1 predicate to nonimmediate_operand.
9728 (attr "i387_cw"): Remove mask_pm.
9729 * config/i386/i386.h (enum ix86_stack_slot): Remove SLOT_CW_MASK_PM.
9730 (enum ix86_entity): Remove I387_MASK_PM.
9731 * config/i386/i386.c (ix86_i387_mode_needed): Do not
9732 handle I387_MASK_PM.
9733 (ix86_mode_needed): Ditto.
9734 (ix86_mode_after): Ditto.
9735 (ix86_mode_entry): Ditto.
9736 (ix86_mode_exit): Ditto.
9737 (emit_i387_cw_initialization): Do not handle I387_CW_MASK_PM.
9738
9739 2018-09-25 Jakub Jelinek <jakub@redhat.com>
9740
9741 * vr-values.c (vr_values::vr_values): Initialize to_remove_edges and
9742 to_update_switch_stmts to vNULL instead of calling create on them
9743 immediately.
9744
9745 2018-09-25 Richard Biener <rguenther@suse.de>
9746
9747 PR tree-optimization/87402
9748 * tree-ssa-sccvn.c (SSA_VISITED): Remove unused function.
9749 (visit_phi): Re-instantiate handling of supposed to be VARYING
9750 but non-VARYING backedge value.
9751
9752 2018-09-25 Richard Biener <rguenther@suse.de>
9753
9754 PR debug/83941
9755 * dwarf2out.c (struct sym_off_pair): New.
9756 (external_die_map): New global.
9757 (lookup_decl_die): When in LTO create DIEs lazily from the
9758 external_die_map.
9759 (lookup_block_die): New function, create DIEs lazily in LTO.
9760 (equate_block_to_die): New function.
9761 (dwarf2out_die_ref_for_decl): During WPA get the association
9762 from the external DIE map.
9763 (dwarf2out_register_external_die): Record mapping into the
9764 external DIE map.
9765 (maybe_create_die_with_external_ref): New function split out from
9766 DIE generation part of old dwarf2out_register_external_die.
9767 (add_abstract_origin_attribute): Do not return the DIE. When
9768 in LTO reference externals directly.
9769 (dwarf2out_abstract_function): When in LTO ignore calls for
9770 decls with external DIEs (already present abstract instances).
9771 (gen_call_site_die): Adjust.
9772 (add_high_low_attributes): Likewise.
9773 (gen_lexical_block_die): Likewise.
9774 (gen_inlined_subroutine_die): Likewie.
9775 (gen_block_die): Likewise.
9776 (dwarf2out_inline_entry): Likewise.
9777 (dwarf2out_early_finish): In LTRANS phase create DW_TAG_imported_unit
9778 DIEs.
9779
9780 2018-09-25 Martin Liska <mliska@suse.cz>
9781
9782 * ipa-fnsummary.c (estimate_node_size_and_time): Scale by two
9783 integers and not by a float value.
9784
9785 2018-09-25 Martin Liska <mliska@suse.cz>
9786
9787 PR fortran/87394
9788 * dbgcnt.c (dbg_cnt_process_single_pair): Return false
9789 instead of NULL.
9790 * dumpfile.c (dump_enable_all): Remove extra parenthesis.
9791 * gcov-tool.c: Declare the function with ATTRIBUTE_NORETURN.
9792 * godump.c (go_format_type): Remove extra parenthesis.
9793
9794 2018-09-25 Martin Liska <mliska@suse.cz>
9795
9796 * alias.c (set_dest_equal_p): Remove unused function.
9797 * config/i386/i386.c (def_builtin_pure2): Likewise.
9798 * diagnostic-show-locus.c (class layout): Remove
9799 unused field.
9800 (layout::layout): Likewise here.
9801 * dump-context.h (class temp_dump_context): Likewise.
9802 * dwarf2out.c (add_AT_fde_ref): Remove unused function.
9803 (add_AT_loclistsptr): Likewise.
9804 (add_AT_offset): Likewise.
9805 (get_AT_hi_pc): Likewise.
9806 (is_comdat_die): Likewise.
9807 (type_is_enum): Likewise.
9808 (ceiling): Likewise.
9809 (add_AT_vms_delta): Likewise.
9810 (is_class_die): Likewise.
9811 * edit-context.c (class line_event): Remove unused field.
9812 * graphite-sese-to-poly.c (tree_int_to_gmp): Remove
9813 unused function.
9814 * ipa-cp.c (ipa_get_vr_lat): Likewise.
9815 * lra-constraints.c (ok_for_index_p_nonstrict): Likewise.
9816 (ok_for_base_p_nonstrict): Likewise.
9817 * tree-chrec.c (is_not_constant_evolution): Likewise.
9818 (chrec_fold_poly_cst): Likewise.
9819 * tree-if-conv.c (has_pred_critical_p): Likewise.
9820 * tree-ssa-coalesce.c (print_exprs): Likewise.
9821 * tree-ssa-pre.c (bitmap_set_contains_expr): Likewise.
9822 * tree-ssa-uninit.c (is_and_or_or_p): Likewise.
9823 * tree-vrp.c (value_ranges_intersect_p): Likewise.
9824 (value_range_nonnegative_p): Likewise.
9825
9826 2018-09-25 Martin Liska <mliska@suse.cz>
9827
9828 * config/powerpcspe/powerpcspe.c (rs6000_output_function_epilogue):
9829 Do not handle "GNU Pascal".
9830 * config/rs6000/rs6000.c (rs6000_output_function_epilogue):
9831 Likewise.
9832 * config/sparc/sparc.c (sparc_pass_by_reference): Remove Pascal
9833 from documentation. Likewise.
9834 * dbxout.c (dbxout_range_type): Likewise.
9835 * doc/cpp.texi: Likewise.
9836 * doc/extend.texi: Likewise.
9837 * doc/frontends.texi: Likewise.
9838 * doc/invoke.texi: Remove Pascal entry.
9839 * tree.def (CLEANUP_POINT_EXPR): Likewise.
9840 * doc/rtl.texi (MODE_FUNCTION): Remove not used entry.
9841
9842 2018-09-25 Martin Liska <mliska@suse.cz>
9843
9844 PR middle-end/86078
9845 * doc/invoke.texi: Document all parameters and remove default
9846 of the parameters.
9847
9848 2018-09-25 Ilya Leoshkevich <iii@linux.ibm.com>
9849
9850 PR bootstrap/87417
9851 * rtl.c (rtx_code_size): Take into account that EQ_ATTR_ALT
9852 contains HOST_WIDE_INTs when computing its size.
9853
9854 2018-09-24 Jim Wilson <jimw@sifive.com>
9855
9856 PR target/87391
9857 * config/riscv/riscv.h (STACK_BOUNDARY): Test riscv_abi == ABI_ILP32E
9858 not TARGET_RVE.
9859 (ABI_STACK_BOUNDARY, MAX_ARGS_IN_REGISTERS): Likewise.
9860
9861 2018-09-24 Andrew Pinski <apinski@marvell.com>
9862
9863 * config/aarch64/aarch64.c (aarch_macro_fusion_pair_p): Don't
9864 access prev before checking it for NULLness in the
9865 AARCH64_FUSE_CMP_BRANCH case.
9866
9867 2018-09-24 H.J. Lu <hongjiu.lu@intel.com>
9868
9869 PR target/82699
9870 * config/i386/i386.c (rest_of_insert_endbranch): Set
9871 endbr_queued_at_entrance to true and don't insert ENDBR if
9872 x86_function_profiler will be called.
9873 (x86_function_profiler): Insert ENDBR if endbr_queued_at_entrance
9874 is true.
9875 * config/i386/i386.h (machine_function): Add
9876 endbr_queued_at_entrance.
9877
9878 2018-09-24 Ilya Leoshkevich <iii@linux.ibm.com>
9879
9880 * genattrtab.c (mk_attr_alt): Use alternative_mask.
9881 (attr_rtx_1): Adjust caching to match the new EQ_ATTR_ALT field
9882 types.
9883 (check_attr_test): Use alternative_mask.
9884 (get_attr_value): Likewise.
9885 (compute_alternative_mask): Use alternative_mask and XWINT.
9886 (make_alternative_compare): Use alternative_mask.
9887 (attr_alt_subset_p): Use XWINT.
9888 (attr_alt_subset_of_compl_p): Likewise.
9889 (attr_alt_intersection): Use alternative_mask and XWINT.
9890 (attr_alt_union): Likewise.
9891 (attr_alt_complement): Use HOST_WIDE_INT and XWINT.
9892 (mk_attr_alt): Use alternative_mask and HOST_WIDE_INT.
9893 (simplify_test_exp): Use alternative_mask and XWINT.
9894 (write_test_expr): Use alternative_mask and XWINT, adjust bit
9895 number calculation to support 64 bits. Generate code that
9896 checks 64-bit masks.
9897 (main): Use alternative_mask.
9898 * rtl.def (EQ_ATTR_ALT): Change field types from ii to ww.
9899
9900 2018-09-24 Ilya Leoshkevich <iii@linux.ibm.com>
9901
9902 PR target/80080
9903 * config/s390/s390.c (s390_emit_epilogue): Do not use PARALLEL
9904 RETURN+USE when returning via %r14.
9905
9906 2018-09-24 Martin Liska <mliska@suse.cz>
9907
9908 * gcov.c (output_lines): Print colorization legend
9909 for both flag_use_colors and flag_use_hotness_colors.
9910 Reword the help.
9911
9912 2018-09-24 Martin Liska <mliska@suse.cz>
9913
9914 * coverage.c (get_coverage_counts): Use warning_at
9915 with current_function_decl location. Use %qD in warning
9916 message.
9917
9918 2018-09-24 Martin Liska <mliska@suse.cz>
9919
9920 * memory-block.h (memory_block_pool::release): Annotate with
9921 valgrind that the memory is not accessible.
9922
9923 2018-09-24 Martin Liska <mliska@suse.cz>
9924
9925 PR sanitizer/85774
9926 * asan.c: Make asan_handled_variables extern.
9927 * asan.h: Likewise.
9928 * cfgexpand.c (expand_stack_vars): Make sure
9929 a representative is unpoison if another
9930 variable in the partition is handled by
9931 use-after-scope sanitization.
9932
9933 2018-09-24 Richard Biener <rguenther@suse.de>
9934
9935 PR tree-optimization/63155
9936 * tree-ssa-propagate.c (add_ssa_edge): Avoid adding PHIs to
9937 the worklist when the edge of the respective argument isn't
9938 executable.
9939
9940 2018-09-23 Uros Bizjak <ubizjak@gmail.com>
9941
9942 * config/i386/i386.h (enum reg_class): Rename MASK_REGS to
9943 ALL_MASK_REGS and MASK_EVEX_REGS to MASK_REGS.
9944 (MASK_CLASS_P): Update for rename.
9945 (MAYBE_MASK_CLASS_P): Ditto.
9946 (REG_CLASS_NAMES): Update.
9947 (REG_CLASS_CONTENT): Update.
9948 * config/i386/i386.c (regclass_map): Update for MASK_REG
9949 and ALL_MASK_REGS rename.
9950 * config/i386/constraints.md (Yk): Update for rename.
9951 (k): Ditto.
9952
9953 2018-09-23 Uros Bizjak <ubizjak@gmail.com>
9954
9955 * config/i386/i386.h (enum reg_class): Remove
9956 EVEX_SSE_REGS and MOD4_SSE_REGS.
9957 (REG_CLASS_NAMES): Update.
9958 (REG_CLASS_CONTENT): Update.
9959 * config/i386/i386.c (regclass_map): Declare AVX-512 SSE
9960 registers as ALL_SSE_REGS.
9961 (ix86_additional_allocno_class_p): Remove.
9962 (TARGET_ADDITIONAL_ALLOCNO_CLASS_P): Remove.
9963 (ix86_register_priority): Lower priority of EVEX SSE registers.
9964 Use IN_RANGE macro where appropriate.
9965 (ix86_hard_regno_mode_ok): Merge AVX-5124FMAPS and
9966 AVX-5124VNNIW checks.
9967 (ix86_modes_tieable_p): Tie 512-bit SSE modes.
9968 * config/i386/sse.md (avx5124fmaddps_4fmaddps)
9969 (avx5124fmaddps_4fmaddps_mask, avx5124fmaddps_4fmaddps_maskz)
9970 (avx5124fmaddps_4fmaddss, avx5124fmaddps_4fmaddss_mask)
9971 (avx5124fmaddps_4fmaddss_maskz, avx5124fmaddps_4fnmaddps)
9972 (avx5124fmaddps_4fnmaddps_mask, avx5124fmaddps_4fnmaddps_maskz)
9973 (avx5124fmaddps_4fnmaddss, avx5124fmaddps_4fnmaddss_mask)
9974 (avx5124fmaddps_4fnmaddss_maskz, avx5124vnniw_vp4dpwssd)
9975 (avx5124vnniw_vp4dpwssd_mask, avx5124vnniw_vp4dpwssd_maskz)
9976 (avx5124vnniw_vp4dpwssds, avx5124vnniw_vp4dpwssds_mask)
9977 (avx5124vnniw_vp4dpwssds_maskz): Use "v" instead of "Yh" constraint.
9978 * config/i386/constraints.md (Yh): Remove.
9979
9980 2018-09-23 Uros Bizjak <ubizjak@gmail.com>
9981
9982 * config/i386/i386.c (regclass_map): Declare integer REX registers
9983 as GENERAL_REGS.
9984
9985 2018-09-23 Gerald Pfeifer <gerald@pfeifer.com>
9986
9987 * doc/service.texi (Service): Switch the fsf.org link to https.
9988
9989 2018-09-22 Chung-Ju Wu <jasonwucj@gmail.com>
9990
9991 PR target/86798
9992 * config/nds32/nds32.c (TARGET_HAVE_SPECULATION_SAFE_VALUE):
9993 Define to speculation_safe_value_not_needed.
9994
9995 2018-09-21 Florian Weimer <fweimer@redhat.com>
9996
9997 PR middle-end/81035
9998 * doc/extend.texi (Common Function Attributes): Mention that
9999 noreturn suppresses tail call optimization.
10000
10001 2018-09-21 Jeff Law <law@redhat.com>
10002
10003 * gimple-ssa-evrp.c (evrp_dom_walker::cleanup): Call
10004 vr_values::cleanup_edges_and_switches.
10005 * tree-vrp.c (to_remove_edges, to_update_switch_stmts): Moved into
10006 vr_values class.
10007 (identify_jump_threads): Remove EDGE_IGNORE handling.
10008 (execute_vrp): Move handling of to_remove_edges and
10009 to_update_switch_stmts into vr_values class member functions.
10010 * tree-vrp.h (switch_update, to_remove_edges): Remove declarations.
10011 (to_update_switch_stmts): Likewise.
10012 * vr-values.c: Include cfghooks.h.
10013 (vr_values::vr_values): Initialize to_remove_edges and
10014 to_update_switch_stmts.
10015 (vr_values::~vr_values): Verify to_remove_edges and
10016 to_update_switch_stmts are empty.
10017 (vr_values::simplify_switch_using_ranges): Set EDGE_IGNORE as needed.
10018 (vr_values::cleanup_edges_and_switches): New member function.
10019 * vr-values.h (vr_values): Add cleanup_edges_and_switches member
10020 function. Add new data members.
10021
10022 2018-09-21 David Malcolm <dmalcolm@redhat.com>
10023
10024 PR tree-optimization/87309
10025 * dumpfile.c (dump_context::begin_scope): Filter the dump_loc
10026 calls with pflags and alt_flags.
10027 (selftest::test_capture_of_dump_calls): Add test of interaction of
10028 MSG_OPTIMIZED_LOCATIONS with AUTO_DUMP_SCOPE.
10029
10030 2018-09-21 Olivier Hainque <hainque@adacore.com>
10031
10032 * config.gcc: Factorize and comment inclusion of vxworks-dummy.h.
10033
10034 2018-09-21 Olivier Hainque <hainque@adacore.com>
10035
10036 * config/vxworks.h (CLEAR_INSN_CACHE): #define to 1.
10037
10038 2018-09-21 Olivier Hainque <hainque@adacore.com>
10039
10040 * config/vxworks.h (VXWORKS_LIBGCC_SPEC): Remove -lc_internal.
10041 Merge block comment with the one ahead of VXWORKS_LIBS_RTP. Then:
10042 (VXWORKS_LIBS_RTP): Minor reordering.
10043
10044 2018-09-21 Olivier Hainque <hainque@adacore.com>
10045
10046 * config/vxworks.h (STARTFILE_PREFIX_SPEC): Define.
10047 (VXWORKS_LIBS_DIR_RTP): Remove definition and use.
10048
10049 2018-09-21 Olivier Hainque <hainque@adacore.com>
10050
10051 * config/vxworks.h (SIZE_TYPE): Account for TARGET_VXWORKS64.
10052 (PTRDIFF_TYPE): Likewise.
10053
10054 2018-09-21 Olivier Hainque <hainque@adacore.com>
10055
10056 * config.gcc: Enforce def of TARGET_VXWORKS64 to 1 from
10057 triplet, similar to support for VxWorks7.
10058 * config/vxworks-dummy.h: Provide a default definition
10059 of TARGET_VXWORKS64 to 0.
10060
10061 2018-09-21 Olivier Hainque <hainque@adacore.com>
10062
10063 * config/vxworks.h (TARGET_VXWORKS7): Move default definition ...
10064 * config/vxworks-dummy.h: here.
10065
10066 2018-09-21 Olivier Hainque <hainque@adacore.com>
10067
10068 * config.gcc: Prepend vxworks-dummy.h to tm_file for powerpc*
10069
10070 2018-09-21 Shaokun Zhang <zhangshaokun@hisilicon.com>
10071 Bo Zhou <zbo.zhou@hisilicon.com>
10072
10073 * config/aarch64/aarch64-cores.def (tsv110): New CPU.
10074 * config/aarch64/aarch64-tune.md: Regenerated.
10075 * doc/invoke.texi (AArch64 Options/-mtune): Add "tsv110".
10076 * config/aarch64/aarch64.c (tsv110_tunings): New tuning table.
10077 * config/aarch64/aarch64-cost-tables.h: Add "tsv110" extra costs.
10078
10079 2018-09-21 Andrew Stubbs <ams@codesourcery.com>
10080 Julian Brown <julian@codesourcery.com>
10081
10082 * builtins.c (get_builtin_sync_mem): Handle address spaces.
10083
10084 2018-09-21 Eric Botcazou <ebotcazou@adacore.com>
10085
10086 * config/rs6000/rs6000.c (rs6000_function_ok_for_sibcall): Return false
10087 if the call takes a static chain.
10088
10089 2018-09-21 Martin Liska <mliska@suse.cz>
10090
10091 * auto-profile.c (autofdo_source_profile::read): Do not
10092 set sum_all.
10093 (read_profile): Do not add working sets.
10094 (read_autofdo_file): Remove sum_all.
10095 (afdo_callsite_hot_enough_for_early_inline): Remove const
10096 qualifier.
10097 * coverage.c (struct counts_entry): Remove gcov_summary.
10098 (read_counts_file): Read new GCOV_TAG_OBJECT_SUMMARY,
10099 do not support GCOV_TAG_PROGRAM_SUMMARY.
10100 (get_coverage_counts): Remove summary and expected
10101 arguments.
10102 * coverage.h (get_coverage_counts): Likewise.
10103 * doc/gcov-dump.texi: Remove -w option.
10104 * gcov-dump.c (dump_working_sets): Remove.
10105 (main): Do not support '-w' option.
10106 (print_usage): Likewise.
10107 (tag_summary): Likewise.
10108 * gcov-io.c (gcov_write_summary): Do not dump
10109 histogram.
10110 (gcov_read_summary): Likewise.
10111 (gcov_histo_index): Remove.
10112 (gcov_histogram_merge): Likewise.
10113 (compute_working_sets): Likewise.
10114 * gcov-io.h (GCOV_TAG_OBJECT_SUMMARY): Mark
10115 it not obsolete.
10116 (GCOV_TAG_PROGRAM_SUMMARY): Mark it obsolete.
10117 (GCOV_TAG_SUMMARY_LENGTH): Adjust.
10118 (GCOV_HISTOGRAM_SIZE): Remove.
10119 (GCOV_HISTOGRAM_BITVECTOR_SIZE): Likewise.
10120 (struct gcov_summary): Simplify rapidly just
10121 to runs and sum_max fields.
10122 (gcov_histo_index): Remove.
10123 (NUM_GCOV_WORKING_SETS): Likewise.
10124 (compute_working_sets): Likewise.
10125 * gcov-tool.c (print_overlap_usage_message): Remove
10126 trailing empty line.
10127 * gcov.c (read_count_file): Read GCOV_TAG_OBJECT_SUMMARY.
10128 (output_lines): Remove program related line.
10129 * ipa-profile.c (ipa_profile): Do not consider GCOV histogram.
10130 * lto-cgraph.c (output_profile_summary): Do not stream GCOV
10131 histogram.
10132 (input_profile_summary): Do not read it.
10133 (merge_profile_summaries): And do not merge it.
10134 (input_symtab): Do not call removed function.
10135 * modulo-sched.c (sms_schedule): Do not print sum_max.
10136 * params.def (HOT_BB_COUNT_FRACTION): Reincarnate param that was
10137 removed when histogram method was invented.
10138 (HOT_BB_COUNT_WS_PERMILLE): Mention that it's used only in LTO
10139 mode.
10140 * postreload-gcse.c (eliminate_partially_redundant_load): Fix
10141 GCOV coding style.
10142 * predict.c (get_hot_bb_threshold): Use HOT_BB_COUNT_FRACTION
10143 and dump selected value.
10144 * profile.c (add_working_set): Remove.
10145 (get_working_sets): Likewise.
10146 (find_working_set): Likewise.
10147 (get_exec_counts): Do not work with working sets.
10148 (read_profile_edge_counts): Do not inform as sum_max is removed.
10149 (compute_branch_probabilities): Likewise.
10150 (compute_value_histograms): Remove argument for call of
10151 get_coverage_counts.
10152 * profile.h: Do not make gcov_summary const.
10153
10154 2018-09-21 Monk Chiang <sh.chiang04@gmail.com>
10155
10156 * config.gcc (nds32*-*-*): Set TARGET_DEFAULT_TLSDESC_TRAMPOLINE=0.
10157
10158 2018-09-21 Eric Botcazou <ebotcazou@adacore.com>
10159
10160 PR tree-optimization/86990
10161 * gimple-ssa-store-merging.c (imm_store_chain_info:coalesce_immediate):
10162 Check that the entire merged store group is made of constants only for
10163 overlapping stores.
10164
10165 2018-09-20 Allan Sandfeld Jensen <allan.jensen@qt.io>
10166
10167 * gcc.c (LINK_COMMAND_SPEC): Handle -r like -nostdlib.
10168 (VTABLE_VERIFICATION_SPEC): Likewise.
10169 (SANITIZER_EARLY_SPEC): Likewise.
10170 (SANITIZER_SPEC): Likewise.
10171 * config/darwin.h (LINK_COMMAND_SPEC): Likewise.
10172 * doc/invoke.texi (Link Options): Document -r.
10173
10174 2018-09-20 Richard Biener <rguenther@suse.de>
10175
10176 PR middle-end/87054
10177 * gimplify.c (gimplify_expr): Retain alignment of
10178 addressable lvalue in dereference.
10179
10180 2018-09-20 Alexandre Oliva <aoliva@redhat.com>
10181
10182 PR bootstrap/87013
10183 * configure.ac: Check for .loc is_stmt support.
10184 * configure, config.in: Rebuilt.
10185 * dwarf2out.c (dwarf2out_source_line): Skip is_stmt
10186 if not supported.
10187
10188 2018-09-20 Segher Boessenkool <segher@kernel.crashing.org>
10189
10190 * config/rs6000/rs6000.opt (misel=no, misel=yes): Delete.
10191 * doc/invoke.texi (RS/6000 and PowerPC Options): Delete -misel=yes and
10192 -misel=no.
10193
10194 2018-09-20 Segher Boessenkool <segher@kernel.crashing.org>
10195
10196 * config/rs6000/rs6000-opts.h (enum rs6000_vector): Delete
10197 VECTOR_OTHER.
10198 * config/rs6000/rs6000.c (rs6000_debug_vector_unit): Delete
10199 case VECTOR_OTHER.
10200
10201 2018-09-20 Marek Polacek <polacek@redhat.com>
10202
10203 * doc/invoke.texi: Add -Wno-init-list-lifetime to C++ Language Options.
10204
10205 2018-09-20 Richard Sandiford <richard.sandiford@arm.com>
10206
10207 PR tree-optimization/87288
10208 * tree-vect-loop.c (vect_analyze_loop_2): Take PEELING_FOR_GAPS
10209 into account when determining PEELING_FOR_NITERS.
10210
10211 2018-09-20 Richard Sandiford <richard.sandiford@arm.com>
10212
10213 PR tree-optimization/86877
10214 * tree-vect-loop.c (vect_analyze_loop_2): Call
10215 vect_verify_datarefs_alignment.
10216
10217 2018-09-19 Marek Polacek <polacek@redhat.com>
10218
10219 * doc/invoke.texi: Document -Wclass-conversion.
10220
10221 2018-09-19 John David Anglin <danglin@gcc.gnu.org>
10222
10223 * config/pa/pa.c (pa_adjust_priority): Delete.
10224 (TARGET_SCHED_ADJUST_PRIORITY): Delete define.
10225
10226 * config/pa/pa.md (atomic_storeqi): Restore deleted expander.
10227 (atomic_storehi): Likewise.
10228 (atomic_storesi): Likewise.
10229 (atomic_loaddi): Restore compare and swap exchange loop code.
10230
10231 2018-09-19 Segher Boessenkool <segher@kernel.crashing.org>
10232
10233 PR rtl-optimization/86902
10234 * combine.c (try_combine): When changing the CC mode used, don't change
10235 an unrelated mode in other_insn to that new CC mode.
10236
10237 2018-09-19 David Malcolm <dmalcolm@redhat.com>
10238
10239 * tree-data-ref.c (runtime_alias_check_p): Use formatted printing
10240 with %T in place of calls to dump_generic_expr.
10241 (prune_runtime_alias_test_list): Likewise.
10242 (create_runtime_alias_checks): Likewise.
10243 * tree-vect-data-refs.c (vect_check_nonzero_value): Likewise.
10244 (vect_analyze_data_ref_dependence): Likewise.
10245 (vect_slp_analyze_data_ref_dependence): Likewise.
10246 (vect_record_base_alignment): Likewise. Use %G in place of call
10247 to dump_gimple_stmt.
10248 (vect_compute_data_ref_alignment): Likewise.
10249 (verify_data_ref_alignment): Likewise.
10250 (vect_find_same_alignment_drs): Likewise.
10251 (vect_analyze_group_access_1): Likewise.
10252 (vect_analyze_data_ref_accesses): Likewise.
10253 (dependence_distance_ge_vf): Likewise.
10254 (dump_lower_bound): Likewise.
10255 (vect_prune_runtime_alias_test_list): Likewise.
10256 (vect_find_stmt_data_reference): Likewise.
10257 (vect_analyze_data_refs): Likewise.
10258 (vect_create_addr_base_for_vector_ref): Likewise.
10259 (vect_create_data_ref_ptr): Likewise.
10260 * tree-vect-loop-manip.c (vect_set_loop_condition): Likewise.
10261 (vect_can_advance_ivs_p): Likewise.
10262 (vect_update_ivs_after_vectorizer): Likewise.
10263 (vect_gen_prolog_loop_niters): Likewise.
10264 (vect_prepare_for_masked_peels): Likewise.
10265 * tree-vect-loop.c (vect_determine_vf_for_stmt): Likewise.
10266 (vect_determine_vectorization_factor): Likewise.
10267 (vect_is_simple_iv_evolution): Likewise.
10268 (vect_analyze_scalar_cycles_1): Likewise.
10269 (vect_analyze_loop_operations): Likewise.
10270 (report_vect_op): Likewise.
10271 (vect_is_slp_reduction): Likewise.
10272 (check_reduction_path): Likewise.
10273 (vect_is_simple_reduction): Likewise.
10274 (vect_create_epilog_for_reduction): Likewise.
10275 (vect_finalize_reduction:): Likewise.
10276 (vectorizable_induction): Likewise.
10277 (vect_transform_loop_stmt): Likewise.
10278 (vect_transform_loop): Likewise.
10279 (optimize_mask_stores): Likewise.
10280 * tree-vect-patterns.c (vect_pattern_detected): Likewise.
10281 (vect_split_statement): Likewise.
10282 (vect_recog_over_widening_pattern): Likewise.
10283 (vect_recog_average_pattern): Likewise.
10284 (vect_determine_min_output_precision_1): Likewise.
10285 (vect_determine_precisions_from_range): Likewise.
10286 (vect_determine_precisions_from_users): Likewise.
10287 (vect_mark_pattern_stmts): Likewise.
10288 (vect_pattern_recog_1): Likewise.
10289 * tree-vect-slp.c (vect_get_and_check_slp_defs): Likewise.
10290 (vect_record_max_nunits): Likewise.
10291 (vect_build_slp_tree_1): Likewise.
10292 (vect_build_slp_tree_2): Likewise.
10293 (vect_print_slp_tree): Likewise.
10294 (vect_analyze_slp_instance): Likewise.
10295 (vect_detect_hybrid_slp_stmts): Likewise.
10296 (vect_detect_hybrid_slp_1): Likewise.
10297 (vect_slp_analyze_operations): Likewise.
10298 (vect_slp_analyze_bb_1): Likewise.
10299 (vect_transform_slp_perm_load): Likewise.
10300 (vect_schedule_slp_instance): Likewise.
10301 * tree-vect-stmts.c (vect_mark_relevant): Likewise.
10302 (vect_mark_stmts_to_be_vectorized): Likewise.
10303 (vect_init_vector_1): Likewise.
10304 (vect_get_vec_def_for_operand): Likewise.
10305 (vect_finish_stmt_generation_1): Likewise.
10306 (vect_check_load_store_mask): Likewise.
10307 (vectorizable_call): Likewise.
10308 (vectorizable_conversion): Likewise.
10309 (vectorizable_operation): Likewise.
10310 (vectorizable_load): Likewise.
10311 (vect_analyze_stmt): Likewise.
10312 (vect_is_simple_use): Likewise.
10313 (vect_get_vector_types_for_stmt): Likewise.
10314 (vect_get_mask_type_for_stmt): Likewise.
10315 * tree-vectorizer.c (increase_alignment): Likewise.
10316
10317 2018-09-19 Andrew Stubbs <ams@codesourcery.com>
10318
10319 * doc/rtl.texi: Adjust vec_select description.
10320 * simplify-rtx.c (simplify_binary_operation_1): Allow VEC_SELECT to use
10321 non-constant selectors.
10322
10323 2018-09-19 Matthew Malcomson <matthew.malcomson@arm.com>
10324
10325 * config/aarch64/aarch64-protos.h
10326 (aarch64_offset_9bit_signed_unscaled_p): New declaration.
10327 * config/aarch64/aarch64.md (arches): New "rcpc8_4" attribute value.
10328 (arch_enabled): Add check for "rcpc8_4" attribute value of "arch".
10329 * config/aarch64/aarch64.h (AARCH64_FL_RCPC8_4): New bitfield.
10330 (AARCH64_FL_FOR_ARCH8_4): Include AARCH64_FL_RCPC8_4.
10331 (AARCH64_FL_PROFILE): Move index so flags are ordered.
10332 (AARCH64_ISA_RCPC8_4): New flag.
10333 * config/aarch64/aarch64.c (offset_9bit_signed_unscaled_p): Renamed
10334 to aarch64_offset_9bit_signed_unscaled_p.
10335 * config/aarch64/atomics.md (atomic_store<mode>): Allow offset
10336 and use stlur.
10337 * config/aarch64/constraints.md (Ust): New constraint.
10338 * config/aarch64/predicates.md.
10339 (aarch64_9bit_offset_memory_operand): New predicate.
10340 (aarch64_rcpc_memory_operand): New predicate.
10341
10342 2018-09-19 Eric Botcazou <ebotcazou@adacore.com>
10343
10344 PR rtl-optimization/87361
10345 * rtlanal.c (nonzero_bits1): Revert accidental change.
10346
10347 2018-09-19 Richard Biener <rguenther@suse.de>
10348
10349 PR tree-optimization/87349
10350 PR tree-optimization/87342
10351 * tree-ssa-sccvn.c (do_rpo_vn): Iterate max_rpo computation.
10352
10353 2018-09-18 Marek Polacek <polacek@redhat.com>
10354
10355 P1064R0 - Allowing Virtual Function Calls in Constant Expressions
10356 * gimple-fold.c (gimple_get_virt_method_for_vtable): Adjust assert.
10357
10358 2018-09-18 Segher Boessenkool <segher@kernel.crashing.org>
10359
10360 * config/rs6000/rs6000.md: Remove old "Cygnus sibcall" comment.
10361
10362 2018-09-18 Segher Boessenkool <segher@kernel.crashing.org>
10363
10364 PR rtl-optimization/86882
10365 * rtlanal.c (reg_overlap_mentioned_p): Handle CLOBBER.
10366
10367 2018-09-18 Uros Bizjak <ubizjak@gmail.com>
10368
10369 * config/i386/i386.md (*<code>extend<mode>xf2): Macroize insn from
10370 *<code>extendsfxf2 and *<code>extenddfxf2 using MODEF mode iterator.
10371
10372 2018-09-18 Jonathan Wakely <jwakely@redhat.com>
10373
10374 PR other/87353
10375 * doc/invoke.texi (Link Options): Fix formatting and grammar.
10376
10377 2018-09-18 Richard Biener <rguenther@suse.de>
10378
10379 PR middle-end/63155
10380 * tree-ssa-coalesce.c (tree_int_map_hasher): Remove.
10381 (compute_samebase_partition_bases): Likewise.
10382 (coalesce_ssa_name): Always use compute_optimized_partition_bases.
10383 (gimple_can_coalesce_p): Simplify.
10384
10385 2018-09-18 Hans-Peter Nilsson <hp@bitrange.com>
10386
10387 Handle a library implementation of ffs calling __builtin_ffs.
10388 * config/mmix/mmix.c (TARGET_INIT_LIBFUNCS): Override with...
10389 (mmix_init_libfuncs): New function: make __builtin_ffs expand
10390 to __ffsdi2.
10391
10392 2018-09-17 David Malcolm <dmalcolm@redhat.com>
10393
10394 * diagnostic-show-locus.c (class layout_range): Add field
10395 "m_original_idx".
10396 (layout_range::layout_range): Add "original_idx" param and use it
10397 to initialize new field.
10398 (make_range): Use 0 for original_idx.
10399 (layout::layout): Pass in index to calls to
10400 maybe_add_location_range.
10401 (layout::maybe_add_location_range): Add param "original_idx" and
10402 pass it on to layout_range.
10403 (layout::print_any_labels): Pass on range->m_original_idx to
10404 get_text call.
10405 (gcc_rich_location::add_location_if_nearby): Use 0 for
10406 original_idx.
10407 * gcc-rich-location.h (text_range_label::get_text): Update for new
10408 param.
10409 (range_label_for_type_mismatch::get_text): Likewise.
10410
10411 2018-09-17 Uros Bizjak <ubizjak@gmail.com>
10412
10413 * config/i386/i386.c (ix86_emit_i387_log1p): Emit fldln2 earlier.
10414
10415 2018-09-17 David Malcolm <dmalcolm@redhat.com>
10416
10417 * gimple-ssa-sprintf.c (fmtwarn): Update for introduction of
10418 format_string_diagnostic_t.
10419 (fmtwarn_n): Likewise.
10420 * substring-locations.c
10421 (format_string_diagnostic_t::format_string_diagnostic_t) New ctor.
10422 (format_warning_n_va): Convert to...
10423 (format_string_diagnostic_t::emit_warning_n_va): ...this.
10424 (format_warning_va): Convert to...
10425 (format_string_diagnostic_t::emit_warning_va): ...this.
10426 (format_warning_at_substring): Convert to...
10427 (format_string_diagnostic_t::emit_warning): ...this.
10428 (format_warning_at_substring_n): Convert to...
10429 (format_string_diagnostic_t::emit_warning_n): ...this.
10430 * substring-locations.h (class format_string_diagnostic_t): New
10431 class.
10432 (format_warning_va): Convert to
10433 format_string_diagnostic_t::emit_warning_va.
10434 (format_warning_n_va): Convert to
10435 format_string_diagnostic_t::emit_warning_n_va.
10436 (format_warning_at_substring): Convert to
10437 format_string_diagnostic_t::emit_warning.
10438 (format_warning_at_substring_n): Convert to
10439 format_string_diagnostic_t::emit_warning_n.
10440
10441 2018-09-17 Cesar Philippidis <cesar@codesourcery.com>
10442 Bernd Schmidt <bernds_cb1@t-online.de>
10443
10444 * config/nvptx/nvptx.md (atomic_fetch_<logic><mode>): Enable with
10445 SImode args.
10446
10447 2018-09-17 Uros Bizjak <ubizjak@gmail.com>
10448
10449 * config/i386/i386.md (truncxf<mode>2_i387_noop_unspec): Change
10450 operand 0 predicate to nonimmediate operand.
10451 (rint<mode>2_frndint): Remove insn pattern.
10452 (rint<mode>2): Change operand 1 predicate to general_operand.
10453 Extend operand 1 to XFmode and generate rintxf2 insn.
10454 (frndintxf2_<rounding>): Rename from frndint<mode>2_<rounding>.
10455 Do not use X87MODEF mode macro.
10456 (frndintxf2_<rounding>_i387): Rename from
10457 frndint<mode>2_<rounding>_i387. Do not use X87MODEF mode macro.
10458 (<rounding_insn><mode>2): For non-SSE modes, extend operand 1
10459 to XFmode and generate significandxf3 insn.
10460
10461 2018-09-17 Richard Biener <rguenther@suse.de>
10462
10463 PR tree-optimization/87328
10464 * tree-ssa-sccvn.c (process_bb): Remove assertion about not
10465 visiting unexecutable backedges when not iterating.
10466 (do_rpo_vn): Mark all edges not executable even when not
10467 iterating.
10468
10469 2018-09-17 Martin Jambor <mjambor@suse.cz>
10470
10471 PR c/63886
10472 * doc/invoke.texi (Warning Options): Likewise.
10473
10474 2018-09-17 Richard Biener <rguenther@suse.de>
10475
10476 PR tree-optimization/87301
10477 * tree-ssa-sccvn.c (eliminate_dom_walker::eliminate_cleanup): Properly
10478 clean EH info from leftover copy assignments.
10479
10480 2018-09-17 Martin Liska <mliska@suse.cz>
10481
10482 PR gcov-profile/85871
10483 * gcov.c (output_intermediate_file): Fix out of bounds
10484 access.
10485
10486 2018-09-17 Vineet Gupta <vgupta@synopsys.com>
10487
10488 * config/arc/arc.c: Object attributes for core4 not reflected
10489 correctly.
10490 * config/arc/arc.h: Don't restrict DBNZ to core3 (core4 includes
10491 core3).
10492
10493 2018-09-17 Alexey Brodkin <abrodkin@synopsys.com>
10494
10495 * config/arc/linux.h (LINK_EH_SPEC): Add missing space.
10496
10497 2018-09-17 Martin Liska <mliska@suse.cz>
10498
10499 * doc/gcov.texi: Document new option --use-hotness-colors.
10500 * gcov.c (struct source_info): Declare new field.
10501 (source_info::source_info): Set default for maximum_count.
10502 (print_usage): Add new -q option.
10503 (process_args): Process it.
10504 (accumulate_line_info): Save src->maximum_count.
10505 (output_line_beginning): Make color line number if
10506 flag_use_hotness_colors is set.
10507 (output_line_details): Pass default argument value.
10508 (output_lines): Pass src->maximum_count.
10509
10510 2018-09-17 Martin Liska <mliska@suse.cz>
10511
10512 * common/config/i386/i386-common.c (ix86_get_valid_option_values):
10513 Use processor_names table.
10514 * config/i386/i386.c (ix86_default_align): Use
10515 processor_cost_table for alignment values.
10516 (ix86_option_override_internal): Use processor_names.
10517 (ix86_function_specific_print): Likewise.
10518 * config/i386/i386.h (struct processor_costs):
10519 Add alignment values.
10520 (struct ptt): Remove and replace with const char *.
10521 * config/i386/x86-tune-costs.h (struct processor_costs):
10522 Declare default alignments for all costs.
10523
10524 2018-09-17 Aldy Hernandez <aldyh@redhat.com>
10525
10526 * tree-vrp.c (extract_range_from_unary_expr): Do not special case
10527 symbolics or VR_VARYING ranges for ABS_EXPR.
10528 * wide-int-range.cc (wide_int_range_abs): Return positive numbers
10529 when range will wrap.
10530
10531 2018-09-15 Eric Botcazou <ebotcazou@adacore.com>
10532
10533 PR middle-end/86864
10534 * cfgexpand.c (expand_gimple_basic_block): Be prepared for a BARRIER
10535 before and after a JUMP_TABLE_DATA.
10536
10537 2018-09-14 John David Anglin <danglin@gcc.gnu.org>
10538
10539 PR middle-end/87188
10540 * dojump.c (do_compare_and_jump): Canonicalize function pointers
10541 when one operand is a function pointer. Use POINTER_TYPE_P and
10542 FUNC_OR_METHOD_TYPE_P.
10543 * expr.c (do_store_flag): Use POINTER_TYPE_P and FUNC_OR_METHOD_TYPE_P.
10544 * fold-const.c (build_range_check): Likewise.
10545 * match.pd (simple_comparison): Likewise.
10546
10547 2018-09-14 David Malcolm <dmalcolm@redhat.com>
10548
10549 PR c/82967
10550 * spellcheck.c (get_edit_distance_cutoff): New function.
10551 (selftest::test_edit_distance_unit_test_oneway): Rename to...
10552 (selftest::test_get_edit_distance_one_way): ...this.
10553 (selftest::test_get_edit_distance_unit): Rename to...
10554 (selftest::test_get_edit_distance_both_ways): ...this.
10555 (selftest::test_edit_distances): Move tests to this new function,
10556 and test some more pairs of strings. Update for above renaming.
10557 (selftest::get_old_cutoff): New function.
10558 (selftest::test_get_edit_distance_cutoff): New function.
10559 (selftest::assert_suggested_for): New function.
10560 (ASSERT_SUGGESTED_FOR): New macro.
10561 (selftest::assert_not_suggested_for): New function.
10562 (ASSERT_NOT_SUGGESTED_FOR): New macro.
10563 (selftest::test_suggestions): New function.
10564 (selftest::spellcheck_c_tests): Move test_get_edit_distance_unit
10565 tests to selftest::test_edit_distances and call it. Add calls to
10566 selftest::test_get_edit_distance_cutoff and
10567 selftest::test_suggestions.
10568 * spellcheck.h (get_edit_distance_cutoff): New function declaration.
10569 (best_match::consider): Replace hard-coded cutoff calculation with
10570 a call to...
10571 (best_match::get_cutoff): New declaration.
10572 (best_match::get_best_meaningful_candidate): Likewise.
10573
10574 2018-09-14 Bernd Edlinger <bernd.edlinger@hotmail.de>
10575
10576 * builtins.c (fold_builtin_strlen): Remove TODO comment.
10577
10578 2018-09-14 Bernd Edlinger <bernd.edlinger@hotmail.de>
10579
10580 revert:
10581 2018-07-30 Bernd Edlinger <bernd.edlinger@hotmail.de>
10582
10583 * tree-ssa-forwprop.c (simplify_builtin_call): Don't create a not NUL
10584 terminated string literal.
10585
10586 2018-09-14 Martin Sebor <msebor@redhat.com>
10587
10588 * builtins.c (unterminated_array): Handle ARRAY_REF.
10589 (expand_builtin_stpcpy_1): Detect unterminated char arrays.
10590 * builtins.h (unterminated_array): Declare extern.
10591 * gimple-fold.c (gimple_fold_builtin_stpcpy): Detect unterminated
10592 arrays.
10593 (gimple_fold_builtin_sprintf): Propagate NO_WARNING to transformed
10594 calls.
10595
10596 2018-09-14 Martin Sebor <msebor@redhat.com>
10597 Jeff Law <law@redhat.com>
10598
10599 * builtins.c (unterminated_array): New.
10600 (expand_builtin_strcpy): Adjust.
10601 (expand_builtin_strcpy_args): Detect unterminated arrays.
10602 * gimple-fold.c (get_maxval_strlen): Add argument. Detect
10603 unterminated arrays.
10604 * gimple-fold.h (get_maxval_strlen): Add argument.
10605 (gimple_fold_builtin_strcpy): Detec unterminated arrays.
10606
10607 * gimple-fold.c (get_range_strlen): Add argument.
10608 (get_maxval_strlen): Adjust.
10609 * gimple-fold.h (get_range_strlen): Add argument.
10610
10611 2018-09-14 Wei Xiao <wei3.xiao@intel.com>
10612
10613 * config/i386/movdirintrin.h: Fix copyright year.
10614
10615 2018-09-14 Uros Bizjak <ubizjak@gmail.com>
10616
10617 * reg-stack.c: Include regs.h.
10618 (replace_reg): Assert that mode is MODE_FLOAT or MODE_COMPLEX_FLOAT.
10619 (emit_pop_insn): Default pop insn mode to the reg_raw_mode of
10620 FIRST_STACK_REG, not DFmode.
10621 (emit_swap_insn): Default swap insn mode to the reg_raw_mode of
10622 FIRST_STACK_REG, not XFmode. Explicitly construct swap RTX.
10623 (change stack): Default register mode to the reg_raw_mode of
10624 FIRST_STACK_REG, not DFmode.
10625 * config/i386/i386.md (*swap<mode>): Remove insn pattern.
10626 (*swapxf): Rename from swapxf.
10627
10628 2018-09-14 Carl Love <cel@us.ibm.com>
10629
10630 * config/rs6000/emmintrin.h: Add _MM_SHUFFLE2.
10631 * config/rs6000/xmmintrin.h: Add _MM_SHUFFLE.
10632
10633 2018-09-14 Segher Boessenkool <segher@kernel.crashing.org>
10634
10635 PR target/87224
10636 * config/rs6000/rs6000.md (*mov<mode>_hardfloat64): Add Z to the Y
10637 alternatives.
10638
10639 2018-09-14 Sam Tebbs <sam.tebbs@arm.com>
10640
10641 PR target/85628
10642 * config/aarch64/aarch64.md (*aarch64_bfxilsi_uxtw): Define.
10643
10644 2018-09-14 Jason Merrill <jason@redhat.com>
10645
10646 Fix --enable-gather-detailed-mem-stats.
10647 * hash-table.c (hash_table_usage): Change from variable to function.
10648 * hash-table.h: Adjust.
10649 * Makefile.in: Add missing dependencies on hash-table.h.
10650
10651 2018-09-14 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
10652
10653 PR tree-optimization/87259
10654 PR lto/87283
10655 (pass_cse_reciprocals::execute): Run optimize_recip_sqrt after
10656 execute_cse_reciprocals_1 has tried transforming.
10657
10658 2018-09-14 Aldy Hernandez <aldyh@redhat.com>
10659
10660 * tree-vrp.c (extract_range_from_binary_expr_1): Normalize
10661 VR_VARYING for PLUS/MINUS_EXPR.
10662
10663 2018-09-14 Ilya Leoshkevich <iii@linux.ibm.com>
10664
10665 * config/s390/s390-passes.def (INSERT_PASS_BEFORE): Improve
10666 formatting.
10667
10668 2018-09-14 Richard Biener <rguenther@suse.de>
10669
10670 PR middle-end/63155
10671 * tree-ssa-coalesce.c (ssa_conflicts_merge): Remove conflict
10672 bits for the merged partition.
10673
10674 2018-09-13 Martin Sebor <msebor@redhat.com>
10675 Bernd Edlinger <bernd.edlinger@hotmail.de>
10676
10677 * builtins.h (c_srlen): Add argument.
10678 * builtins.c (warn_string_no_nul): New function.
10679 (c_strlen): Add argument and use it. Update recursive calls.
10680 Pass DECL argument to string_constant to get info on non
10681 terminated strings. Update *NONSTR as needed.
10682 (fold_builtin_strlen): Add argument to calls to c_strlen.
10683 Warn for unterminated arrays.
10684 (warn_string_no_null): Add prototype.
10685 * expr.c (string_constant): Update arguments. Update recursive
10686 calls appropriately. Detect missing NUL terminator and outermost
10687 declaration its missing in.
10688 Improve checks for arrays with nonzero lower bound or elements
10689 that are not a single byte. Simplify offset computation.
10690 Simplify checks for non-NUL terminated strings.
10691 * gimple-fold.c (get_range_strlen): Add argument to c_strlen call.
10692 * gimple-ssa-sprintf.c (get_string_length): Remove unnecessary code.
10693
10694 2018-09-13 Bernd Edlinger <bernd.edlinger@hotmail.de>
10695
10696 * builtins.c (c_strlen): Handle not zero terminated STRING_CSTs
10697 correctly.
10698 * fold-const.c (c_getstr): Fix function comment. Remove unused third
10699 argument. Fix range checks.
10700 * fold-const.h (c_getstr): Adjust protoype.
10701 * gimple-fold.c (gimple_fold_builtin_memory_op): Avoid folding when
10702 string is constant but contains no NUL byte.
10703
10704 * expr.c (string_constant): Adjust function comment.
10705 Remove bogus check for zero termination.
10706
10707 * fold-const.c (c_getstr): Clamp STRING_LENGTH to STRING_SIZE.
10708
10709 * varasm.c (compare_constant): Compare type size of STRING_CSTs.
10710 (get_constant_size): Don't make STRING_CSTs larger than they are.
10711 (check_string_literal): New check function for STRING_CSTs.
10712 (output_constant): Use it.
10713
10714 2018-09-13 Eric Botcazou <ebotcazou@adacore.com>
10715
10716 PR target/86812
10717 * config/visium/visium.c (TARGET_HAVE_SPECULATION_SAFE_VALUE): Define.
10718
10719 2018-09-13 Richard Biener <rguenther@suse.de>
10720
10721 PR tree-optimization/87263
10722 * tree-ssa-sccvn.c (visit_phi): Revert some earlier changes.
10723 (struct unwind_state): Add max_rpo field.
10724 (do_rpo_vn): Allow up-to-date loop state to be used when not iterating.
10725 Compute max_rpo, the max RPO number a block can be backwards reached
10726 from. Re-write non-iterating mode to a RPO ordered worklist approach,
10727 separating it from the iterating mode.
10728
10729 2018-09-13 Vlad Lazar <vlad.lazar@arm.com>
10730
10731 * haifa-sched.c (rank_for_schedule): Schedule by INSN_COST.
10732 (rfs_decision): New scheduling decision.
10733
10734 2018-09-13 Richard Biener <rguenther@suse.de>
10735
10736 PR bootstrap/87134
10737 * tree-ssa-sccvn.c (vn_nary_op_insert_into): Fix assert.
10738 (vn_nary_op_insert_pieces_predicated): Do not write useless
10739 valid_dominated_by_p entry outside of the allocated storage.
10740
10741 2018-09-13 Omar Sandoval <osandov@osandov.com>
10742 Tom de Vries <tdevries@suse.de>
10743
10744 PR debug/86985
10745 * dwarf2out.c (is_c): New function.
10746 (add_subscript_info): Add DW_AT_count of 0 for C zero-length arrays.
10747
10748 2018-09-13 Sam Tebbs <sam.tebbs@arm.com>
10749
10750 PR target/85628
10751 * config/aarch64/aarch64.md (*aarch64_bfxil):
10752 Define.
10753 * config/aarch64/constraints.md (Ulc): Define.
10754 * config/aarch64/aarch64-protos.h (aarch64_high_bits_all_ones_p):
10755 Define.
10756 * config/aarch64/aarch64.c (aarch64_high_bits_all_ones_p):
10757 New function.
10758
10759 2018-09-13 Vlad Lazar <vlad.lazar@arm.com>
10760
10761 * config/aarch64/aarch64.h (TARGET_COMPUTE_FRAME_LAYOUT): Define.
10762 * config/aarch64/aarch64.c (aarch64_expand_prologue): Remove
10763 aarch64_layout_frame call.
10764 (aarch64_expand_epilogue): Likewise.
10765 (aarch64_initial_elimination_offset): Likewise.
10766 (aarch64_get_separate_components): Likewise.
10767 (aarch64_use_return_insn_p): Likewise.
10768 (aarch64_layout_frame): Remove unneeded check.
10769
10770 2018-09-13 Jakub Jelinek <jakub@redhat.com>
10771
10772 * configure.ac: Only append
10773 " : (reconfigured) $TOPLEVEL_CONFIGURE_ARGUMENTS" to
10774 gcc_config_arguments if it was never reconfigured or last reconfigure
10775 was with different arguments.
10776 * configure: Regenerated.
10777
10778 2018-09-13 Jakub Jelinek <jakub@redhat.com>
10779 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
10780
10781 PR middle-end/87290
10782 * expr.c (maybe_optimize_pow2p_mod_cmp): New function.
10783 (maybe_optimize_mod_cmp): Use it if integer_pow2p treeop1.
10784
10785 2018-09-13 Jakub Jelinek <jakub@redhat.com>
10786
10787 PR tree-optimization/87287
10788 * fold-const.c (fold_binary_loc) <case EQ_EXPR>: Move signed modulo
10789 X % C == 0 to X % (unsigned) C == 0 optimization to ...
10790 * match.pd (X % C == 0): ... here. New optimization.
10791
10792 2018-09-12 Jakub Jelinek <jakub@redhat.com>
10793
10794 PR middle-end/82853
10795 * expr.h (maybe_optimize_mod_cmp): Declare.
10796 * expr.c (mod_inv): New function.
10797 (maybe_optimize_mod_cmp): New function.
10798 (do_store_flag): Use it.
10799 * cfgexpand.c (expand_gimple_cond): Likewise.
10800
10801 2018-09-09 Cesar Philippidis <cesar@codesourcery.com>
10802 Julian Brown <julian@codesourcery.com>
10803
10804 PR middle-end/86336
10805 * gimplify.c (gimplify_scan_omp_clauses): Set
10806 target_firstprivatize_array_bases in OpenACC parallel and kernels
10807 region contexts. Remove GOMP_MAP_FIRSTPRIVATE_REFERENCE clauses from
10808 OpenACC data regions.
10809
10810 2018-09-12 Uros Bizjak <ubizjak@gmail.com>
10811
10812 * config/i386/i386.md (sqrt_extend<mode>xf3_i387): Remove.
10813 (sqrt<mode>2): Extend operand 1 to XFmode and generate sqrtxf3 insn.
10814
10815 2018-09-12 Richard Biener <rguenther@suse.de>
10816
10817 PR tree-optimization/87280
10818 * tree-ssa-sccvn.c (process_bb): Handle the case of executable
10819 edge but unreachable target.
10820 (do_rpo_vn): For conservatively handling a PHI only mark
10821 the backedge executable but not the block reachable.
10822
10823 2018-09-12 Richard Biener <rguenther@suse.de>
10824
10825 PR tree-optimization/87266
10826 * tree-ssa-sccvn.c (do_rpo_vn): Always iterate to not yet
10827 visited blocks.
10828
10829 2018-09-12 Andreas Krebbel <krebbel@linux.ibm.com>
10830
10831 * config/s390/s390.md (PFPO_RND_MODE_DFP, PFPO_RND_MODE_BFP): New
10832 constants.
10833 ("trunc<BFP:mode><DFP_ALL:mode>2")
10834 ("trunc<DFP_ALL:mode><BFP:mode>2")
10835 ("extend<BFP:mode><DFP_ALL:mode>2")
10836 ("extend<DFP_ALL:mode><BFP:mode>2"): Set proper rounding mode
10837 according to the target operand type.
10838
10839 2018-09-12 Jakub Jelinek <jakub@redhat.com>
10840 Andreas Krebbel <krebbel@linux.ibm.com>
10841
10842 PR tree-optimization/86844
10843 * gimple-ssa-store-merging.c
10844 (imm_store_chain_info::coalesce_immediate): For overlapping stores, if
10845 there are any overlapping stores in between them, make sure they are
10846 also coalesced or we give up completely.
10847
10848 2018-09-12 Jakub Jelinek <jakub@redhat.com>
10849
10850 PR middle-end/87248
10851 * fold-const.c (fold_ternary_loc) <case COND_EXPR>: Verify also that
10852 BIT_AND_EXPR's second operand is a power of two. Formatting fix.
10853
10854 2018-09-12 Tom de Vries <tdevries@suse.de>
10855
10856 * common.opt (gdescribe-dies): Add option.
10857 * dwarf2out.c (add_name_and_src_coords_attributes): Add description
10858 attribute for artifical and nameless decls.
10859 (dwarf2out_register_external_die): Add description attribute to
10860 external reference die.
10861 (add_desc_attribute): New functions.
10862 (gen_subprogram_die): Add description attribute to
10863 DW_TAG_call_site_parameter.
10864 * tree-pretty-print.c (print_generic_expr_to_str): New function.
10865 * tree-pretty-print.h (print_generic_expr_to_str): Declare.
10866 * doc/invoke.texi (@item Debugging Options): Add -gdescribe-dies and
10867 -gno-describe-dies.
10868 (@item -gdescribe-dies): Add.
10869
10870 2018-09-12 Aldy Hernandez <aldyh@redhat.com>
10871
10872 * tree-vrp.c (vrp_shift_undefined_p): Remove.
10873 (extract_range_from_binary_expr_1: Call
10874 wide_int_range_shift_undefined_p instead of vrp_shift_undefined_p.
10875 * wide-int-range.h (wide_int_range_shift_undefined_p): Do not
10876 depend on sign.
10877
10878 2018-09-12 Aldy Hernandez <aldyh@redhat.com>
10879
10880 * gimple-ssa-warn-alloca.c
10881 (alloca_type_and_limit::alloca_type_and_limit): Initialize limit
10882 field for ALLOCA_BOUND_*_LARGE.
10883
10884 2018-09-11 Nathan Sidwell <nathan@acm.org>
10885
10886 * gcc.c (load_specs, execute, run_attempt): Use %qs not '%s'.
10887
10888 2018-09-11 Uros Bizjak <ubizjak@gmail.com>
10889
10890 * reg-stack.c (subst_asm_stack_regs): Call replace_reg also
10891 for clobbers. Remove obsolete comment.
10892
10893 2018-09-11 Uros Bizjak <ubizjak@gmail.com>
10894
10895 * config/i386/i386.md (define_attr "type"): Remove mpxmov, mpxmk,
10896 mpxchk, mpxld and mpxst types.
10897 (define_attr length_immediate): Remove all processing of mpx types.
10898 (define_attr prefix_0f): Ditto.
10899 (define_attr memory): Ditto.
10900
10901 2018-09-11 Uros Bizjak <ubizjak@gmail.com>
10902
10903 * config/i386/i386.md (fyl2x_extend<mode>xf3_i387): Remove.
10904 (log<mode>2): Change operand 1 predicate to general_operand.
10905 Extend operand 1 to XFmode and generate logxf3 insn.
10906 (log10<mode>2): Change operand 1 predicate to general_operand.
10907 Extend operand 1 to XFmode and generate log10xf3 insn.
10908 (log2<mode>2): Change operand 1 predicate to general_operand.
10909 Extend operand 1 to XFmode and generate log2xf3 insn.
10910 (fyl2xp1_extend<mode>xf3_i387): Remove.
10911 (log1p<mode>2): Change operand 1 predicate to general_operand.
10912 Extend operand 1 to XFmode and generate log1pxf3 insn.
10913 (fxtract_extend<mode>xf3_i387): Remove.
10914 (logb<mode>2): Change operand 1 predicate to general_operand.
10915 Extend operand 1 to XFmode and generate logbxf3 insn.
10916 (ilogb<mode>2): Change operand 1 predicate to general_operand.
10917 Extend operand 1 to XFmode and generate fxtractxf3_i387 insn.
10918 (significand<mode>2): Change operand 1 predicate to general_operand.
10919 Extend operand 1 to XFmode and generate significandxf3 insn.
10920
10921 2018-09-11 Nathan Sidwell <nathan@acm.org>
10922
10923 * gcc.c (perror_with_name, pfatal_with_name): Delete.
10924 (load_specs): Use fatal_error.
10925 (DELETE_IF_ORDINARY, process_command): Use error.
10926 (execute, run_attempt): Use fatal_error.
10927
10928 2018-09-11 Andrew Stubbs <ams@codesourcery.com>
10929
10930 * diagnostic-core.h (sorry_at): New prototype.
10931 * diagnostic.c (sorry_at): New function.
10932
10933 2018-09-11 Aldy Hernandez <aldyh@redhat.com>
10934
10935 * tree-vrp.c (extract_range_from_binary_expr_1): Treat all divisions
10936 by zero as VR_UNDEFINED.
10937
10938 2018-09-10 Uros Bizjak <ubizjak@gmail.com>
10939
10940 * config/i386/i386.md (<sincos>xf2): Rename from *<sincos>xf2_i387.
10941 (*<sincos>_extend<mode>xf2_i387): Remove insn pattern.
10942 (<sincos>mode2): New expander.
10943 (sincos_extend<mode>xf3_i387): Remove insn pattern.
10944 (sincos -> sin, cos splitters): Remove splitter patterns.
10945 (sincos<mode>3): Change operand 2 predicate to general_operand.
10946 Extend operand 2 to XFmode and generate sincosxf3 insn.
10947 (fptanxf4_i387): Change mode of operands 0 and 3 to SFmode.
10948 Change operand 3 predicate to const1_operand.
10949 (fptan_extend<mode>xf4_i387): Remove insn pattern.
10950 (tanxf2): Update operands in the call to fptanxf4_i387.
10951 (tan<mode>2): Change operand 1 predicate to general_operand.
10952 Extend operand 1 to XFmode and generate tanxf3 insn.
10953 (atan2xf3): Rename from *fpatanxf3_i387.
10954 (fpatan_extend<mode>xf3_i387): Remove insn pattern.
10955 (atan2xf3): Remove expander.
10956 (atan2<mode<3): Change operand 1 and 2 predicates to general_operand.
10957 Extend operands 1 and 2 to XFmode and generate atan2xf3 insn.
10958 (atan<mode>2): Change operand 1 predicate to general_operand.
10959 Extend operand 1 to XFmode and generate atanxf3 insn.
10960
10961 2018-09-10 Uros Bizjak <ubizjak@gmail.com>
10962
10963 * config/i386/i386.md (x87/SSE constant load splitter): Use
10964 memory_operand instead of nonimmediate_operand for input operand
10965 predicate.
10966
10967 2018-09-09 Uros Bizjak <ubizjak@gmail.com>
10968
10969 * config/i386/i386.md (float partial SSE register stall splitter): Move
10970 splitter near its instruction pattern.
10971 (float_extend partial SSE register stall splitter): Ditto.
10972 (float_truncate partial SSE register stall splitter): Ditto.
10973
10974 2018-09-09 Hans-Peter Nilsson <hp@bitrange.com>
10975
10976 PR target/86794
10977 * config/mmix/mmix.c (TARGET_HAVE_SPECULATION_SAFE_VALUE): Redefine
10978 to speculation_safe_value_not_needed.
10979
10980 PR target/85666
10981 * config/mmix/mmix.c (mmix_assemble_integer): Handle byte-size
10982 non-CONST_INT rtx:es using assemble_integer_with_op ".byte".
10983 (MMIX_CFUN_NEEDS_SAVED_EH_RETURN_ADDRESS): Don't call
10984 leaf_function_p, instead use has_hard_reg_initial_val.
10985
10986 2018-09-09 Nathan Sidwell <nathan@acm.org>
10987
10988 * gcc.h (pfatal_with_name): Don't declare here.
10989 * gcc.c (pfatal_with_name): Make static.
10990
10991 2018-09-09 Xianmiao Qu <xianmiao_qu@c-sky.com>
10992
10993 * config/csky/csky.md (*cskyv2_adddi3, *cskyv2_subdi3): Add
10994 earlyclobber.
10995
10996 2018-09-08 John David Anglin <danglin@gcc.gnu.org>
10997
10998 PR rtl-optimization/85458
10999 * sel-sched.c (sel_target_adjust_priority): Allow backend adjust
11000 priority hook to reduce the priority of EXPR.
11001
11002 2018-09-07 Uros Bizjak <ubizjak@gmail.com>
11003
11004 * config/i386/i386.md (float<SWI48x:mode><MODEF:mode>2) Enable
11005 DImode for x87 on 32bit targets. Conditionally disable x87 modes
11006 with X87_ENABLE_FLOAT. Remove preparation code.
11007 (*float<SWI48:mode><MODEF:mode>2): Rename from
11008 *float<SWI48:mode><MODEF:mode>2_mixed. Handle x87, SSE and mixed
11009 math using "enabled" attribute.
11010 (*floatdi<MODEF:mode>2_i387): Rename from
11011 *float<SWI48x:mode><MODEF:mode>2_i387. Handle only DImode and
11012 enable for 32bit targets only.
11013 (floatdi<X87MODEF:mode>2_i387_with_xmm pre-reload splitter): New
11014 splitter.
11015 (floatdi<X87MODEF:mode>2_i387_with_xmm): Use register_operand
11016 as operand 1 predicate. Rewrite as define_insn_and_split.
11017 (floatdi<X87MODEF:mode>2_i387_with_xmm memory input splitter): Remove.
11018
11019 2018-09-06 Uros Bizjak <ubizjak@gmail.com>
11020
11021 * reg-stack.c (get_true_reg) <case FLOAT_TRUNCATE>: Reorder
11022 to fallthru to FLOAT case.
11023
11024 2018-09-06 Will Schmidt <will_schmidt@vnet.ibm.com>
11025
11026 PR target/86731
11027 * config/rs6000/rs6000.c (rs6000_gimple_fold_builtin): Update logic
11028 around folding of vec_sl to handle out of range shift values.
11029
11030 2018-09-06 Uros Bizjak <ubizjak@gmail.com>
11031
11032 * config/i386/i386.md (fix_trunc<mode>_fisttp_i387_1): Remove.
11033 Update callers to gen_fix_trunc<mode>_i387_fisttp
11034 (fix_trunc<mode>_i387_fisttp): Change operand 0 predicate to
11035 nonimmediate_operand.
11036 (fix_trunc<mode>_i387_fisttp_with_temp): Remove insn pattern
11037 and corresponding splitters.
11038 (*fix_trunc<mode>_i387_1): Always expand with fix_trunc<mode>_i387.
11039 (fix_truncdi_i387): Change operand 0 predicate to nonimmediate_operand.
11040 (fix_truncdi_i387_with_temp): Remove insn pattern
11041 and corresponding splitters.
11042 (fix_trunc<mode>_i387): Change operand 0 predicate to
11043 nonimmediate_operand.
11044 (fix_trunc<mode>_i387_with_temp): Remove insn pattern
11045 and corresponding splitters.
11046 (*fistdi2_1): Remove.
11047 (fistdi2): Ditto.
11048 (fistdi2_with_temp): Remove insn pattern and corresponding splitters.
11049 (lrintxfdi2): Remove expander. Reimplement as define_insn.
11050 (*fist<mode>2_1): Remove.
11051 (fist<mode>2): Ditto.
11052 (fist<mode>2_with_temp): Remove insn pattern and corresponding
11053 splitters.
11054 (lrintxf<mode>2): Remove expander. Reimplement as define_insn.
11055 (*fist<mode>2_<rounding>_1): Always expand with fist<mode>2_<rounding>.
11056 (fistdi2_<rounding>): Change operand 0 predicate to
11057 nonimmediate_operand.
11058 (fistdi2_<rounding>_with_temp): Remove insn pattern
11059 and corresponding splitters.
11060 (fist<mode>2_<rounding>): Change operand 0 predicate to
11061 nonimmediate_operand.
11062 (fist<mode>2_<rounding>_with_temp): Remove insn pattern
11063 and corresponding splitters.
11064
11065 (*fixuns_trunc<mode>si2_avx512f_zext): Depend on TARGET_SSE_MATH.
11066
11067 2018-09-06 Bernd Edlinger <bernd.edlinger@hotmail.de>
11068
11069 * varasm.c (output_constructor_regular_field): Check TYPE_SIZE_UNIT of
11070 the init value.
11071
11072 2018-09-06 Will Schmidt <will_schmidt@vnet.ibm.com>
11073
11074 * config/rs6000/rs6000.c (rs6000_gimple_fold_builtin): Add support for
11075 early gimple folding of vec_splat().
11076 * tree-vect-generic.c: Remove static from tree_vec_extract() definition.
11077 * gimple-fold.h: Add an extern define for tree_vec_extract().
11078
11079 2018-09-06 Will Schmidt <will_schmidt@vnet.ibm.com>
11080
11081 * config/rs6000/rs6000.c (fold_mergehl_helper): Add types_compatible_p
11082 wrappers around TREE_TYPE comparisons.
11083
11084 2018-09-06 Ilya Leoshkevich <iii@linux.ibm.com>
11085
11086 PR target/80080
11087 * config/s390/predicates.md: Add nonsym_memory_operand.
11088 * config/s390/s390.c (s390_legitimize_cs_operand): If operand
11089 contains a SYMBOL_REF, load it into an intermediate pseudo.
11090 (s390_emit_compare_and_swap): Legitimize operand.
11091 * config/s390/s390.md: Use the new nonsym_memory_operand
11092 with UNSPECV_CAS patterns.
11093
11094 2018-09-06 Ilya Leoshkevich <iii@linux.ibm.com>
11095
11096 PR target/80080
11097 * config/s390/s390-passes.def: New file.
11098 * config/s390/s390-protos.h (class rtl_opt_pass): Add forward
11099 declaration.
11100 (make_pass_s390_early_mach): Add declaration.
11101 * config/s390/s390.c (make_pass_s390_early_mach):
11102 (s390_option_override): Remove dynamic registration.
11103 * config/s390/t-s390: Add s390-passes.def.
11104
11105 2018-09-06 Ilya Leoshkevich <iii@linux.ibm.com>
11106
11107 * config/s390/s390.c (s390_decompose_constant_pool_ref):
11108 Remove UNSPEC_LTREL_BASE check.
11109 (annotate_constant_pool_refs): Likewise.
11110 (find_constant_pool_ref): Likewise.
11111 (find_ltrel_base): Removed.
11112 (replace_ltrel_base): Removed.
11113 (s390_mainpool_finish): Remove replace_ltrel_base call.
11114 (s390_chunkify_start): Remove pending LTREL_BASE logic.
11115 (s390_chunkify_finish): Remove replace_ltrel_base call.
11116 * config/s390/s390.md: Remove UNSPEC_LTREL_BASE.
11117
11118 2018-09-06 Hans-Peter Nilsson <hp@axis.com>
11119
11120 PR target/86779
11121 * config/cris/cris.c (TARGET_HAVE_SPECULATION_SAFE_VALUE): Redefine
11122 to speculation_safe_value_not_needed.
11123
11124 2018-09-05 Cesar Philippidis <cesar@codesourcery.com>
11125 Bernd Schmidt <bernds_cb1@t-online.de>
11126
11127 * config/nvptx/nvptx-opts.h: New file.
11128 * config/nvptx/nvptx.c (nvptx_file_start): Print the correct .target.
11129 * config/nvptx/nvptx.h: Include "nvptx-opts.h".
11130 (ASM_SPEC): Define.
11131 (TARGET_SM35): New macro.
11132 * config/nvptx/nvptx.md (atomic_fetch_<logic><mode>): Enable with the
11133 correct predicate.
11134 * config/nvptx/nvptx.opt (ptx_isa, sm_30, sm_35): New enum and its
11135 values.
11136 (misa=): New option.
11137 * doc/invoke.texi (Nvidia PTX Options): Document -misa.
11138
11139 2018-09-05 Uros Bizjak <ubizjak@gmail.com>
11140
11141 * config/i386/i386.md (truncdfsf2): Remove expander.
11142 (truncdfsf2_with_temp): Ditto.
11143 (truncxf<mode>2): Ditto.
11144 (*truncdfsf_fast_mixed): Remove insn pattern.
11145 (*truncdfsf_fast_i387): Ditto.
11146 (*truncdfsf_mixed): Ditto.
11147 (*truncdfsf_i387): Ditto.
11148 (*truncdfsf2_i387_1): Ditto.
11149 (*truncxfsf2_mixed): Ditto.
11150 (*truncxfdf2_mixed): Ditto.
11151 (*truncxf<mode>2_i387_noop): Ditto. Update callers
11152 to call gen_truncxf<mode>2 instead.
11153 (*truncxf<mode>2_i387): Remove.
11154 (reg->reg splitters): Remove splitter pattern.
11155 (reg->mem splitters): Ditto.
11156
11157 (truncdfsf2): New insn pattern.
11158 (truncxf<mode>2): Ditto.
11159
11160 2018-09-05 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
11161
11162 * tree-ssa-math-opts.c (is_mult_by): New function.
11163 (is_square_of): Use the above.
11164 (optimize_recip_sqrt): New function.
11165 (pass_cse_reciprocals::execute): Use the above.
11166
11167 2018-09-05 Richard Biener <rguenther@suse.de>
11168
11169 PR bootstrap/87134
11170 * tree-ssa-sccvn.c (rpo_elim::eliminate_push_avail): Make sure
11171 to zero-init the emplaced vec.
11172
11173 2018-09-05 Martin Liska <mliska@suse.cz>
11174
11175 PR tree-optimization/87205
11176 * tree-switch-conversion.c (pass_lower_switch::execute):
11177 Group cases for switch statements.
11178
11179 2018-09-05 Richard Biener <rguenther@suse.de>
11180
11181 PR tree-optimization/87217
11182 * tree-ssa-sccvn.c (vuse_valueize): New.
11183 (vn_reference_lookup_pieces): Use it.
11184 (vn_reference_lookup): Likewise.
11185
11186 2018-09-05 Nathan Sidwell <nathan@acm.org>
11187
11188 PR c++/87137
11189 * stor-layout.c (place_field): Scan forwards to check last
11190 bitfield when ms_bitfield_placement is in effect.
11191
11192 2018-09-05 Richard Biener <rguenther@suse.de>
11193
11194 PR bootstrap/87225
11195 * tree-vect-stmts.c (vectorizable_simd_clone_call): Fix bogus
11196 return.
11197
11198 2018-09-05 Siddhesh Poyarekar <siddhesh@sourceware.org>
11199 Kugan Vivekanandarajah <kugan.vivekanandarajah@linaro.org>
11200
11201 * config/aarch64/falkor-tag-collision-avoidance.c: New file.
11202 * config.gcc (extra_objs): Build it.
11203 * config/aarch64/t-aarch64 (falkor-tag-collision-avoidance.o):
11204 Likewise.
11205 * config/aarch64/aarch64-passes.def
11206 (pass_tag_collision_avoidance): New pass.
11207 * config/aarch64/aarch64.c (qdf24xx_tunings): Add
11208 AARCH64_EXTRA_TUNE_RENAME_LOAD_REGS to tuning_flags.
11209 (aarch64_classify_address): Remove static qualifier.
11210 (aarch64_address_info, aarch64_address_type): Move to...
11211 * config/aarch64/aarch64-protos.h: ... here.
11212 (make_pass_tag_collision_avoidance): New function.
11213 * config/aarch64/aarch64-tuning-flags.def (rename_load_regs):
11214 New tuning flag.
11215
11216 2018-09-05 Martin Liska <mliska@suse.cz>
11217
11218 * doc/gcov.texi: Update documentation of humar
11219 readable mode.
11220 * gcov.c (format_count): Print one decimal place, it provides
11221 more fine number of situations like '1G' vs. '1.4G'.
11222
11223 2018-09-05 Martin Liska <mliska@suse.cz>
11224
11225 PR target/87164
11226 * config/rs6000/rs6000.opt: Mark the option as Deprecated.
11227 * optc-gen.awk: Allow 'Var' for Deprecated options in order
11228 to generate a MASK value.
11229
11230 2018-09-04 H.J. Lu <hongjiu.lu@intel.com>
11231
11232 PR debug/86593
11233 * dwarf2out.c (based_loc_descr): Allow hard frame pointer even
11234 if frame pointer isn't used.
11235 (compute_frame_pointer_to_fb_displacement): Likewise.
11236
11237 2018-09-04 Jakub Jelinek <jakub@redhat.com>
11238
11239 PR target/87198
11240 * common/config/i386/i386-common.c (OPTION_MASK_ISA_XSAVEOPT_SET,
11241 OPTION_MASK_ISA_XSAVES_SET, OPTION_MASK_ISA_XSAVEC_SET): Use
11242 OPTION_MASK_ISA_XSAVE_SET instead of OPTION_MASK_ISA_XSAVE.
11243 (OPTION_MASK_ISA_XSAVE_UNSET): Add OPTION_MASK_ISA_XSAVES_UNSET
11244 and OPTION_MASK_ISA_XSAVEC_UNSET.
11245
11246 2018-09-04 Max Filippov <jcmvbkbc@gmail.com>
11247
11248 * config/xtensa/xtensa.c (xtensa_expand_atomic): Reorder AND and
11249 XOR operations in NAND case.
11250
11251 2018-09-04 Aldy Hernandez <aldyh@redhat.com>
11252
11253 * wide-int-range.cc (wide_int_range_convert): New.
11254 * wide-int-range.h (wide_int_range_convert): New.
11255 * tree-vrp.c (extract_range_from_unary_expr): Abstract wide int
11256 code into wide_int_range_convert.
11257 (extract_range_into_wide_ints): Do not munge anti range constants
11258 into the entire domain. Just return the range back.
11259
11260 2018-09-04 Martin Liska <mliska@suse.cz>
11261
11262 * genmatch.c (output_line_directive): Add new argument
11263 fnargs.
11264 (dt_simplify::gen_1): Encapsulate dump within __builtin_expect.
11265
11266 2018-09-04 Jonathan Wakely <jwakely@redhat.com>
11267
11268 * doc/invoke.texi (Option Summary): Add whitespace.
11269
11270 * doc/invoke.texi (Option Summary): Add -Waligned-new.
11271
11272 2018-09-04 Richard Biener <rguenther@suse.de>
11273
11274 PR tree-optimization/87211
11275 * tree-ssa-sccvn.c (visit_phi): When value-numbering to a
11276 backedge value we're supposed to treat as VARYING also number
11277 the PHI to VARYING in case it got a different value-number already.
11278
11279 2018-09-04 Aldy Hernandez <aldyh@redhat.com>
11280
11281 * tree-vrp.c (vrp_can_optimize_bit_op): Remove.
11282 (extract_range_from_binary_expr_1): Do not call
11283 vrp_can_optimize_bit_op.
11284 * wide-int-range.cc (wide_int_range_can_optimize_bit_op): Make
11285 static.
11286 (wide_int_range_get_mask_and_bounds): New.
11287 (wide_int_range_optimize_bit_op): New.
11288 (wide_int_range_bit_ior): Call wide_int_range_optimize_bit_op.
11289 (wide_int_range_bit_and): Same.
11290 * wide-int-range.h (wide_int_range_can_optimize_bit_op): Remove.
11291 (wide_int_range_optimize_bit_op): New.
11292 (wide_int_range_get_mask_and_bounds): New.
11293
11294 2018-09-04 Richard Biener <rguenther@suse.de>
11295
11296 PR tree-optimization/87176
11297 * tree-ssa-sccvn.c (visit_phi): Remove redundant allsame
11298 variable. When value-numbering a virtual PHI node make sure
11299 to not value-number to the backedge value.
11300
11301 2018-09-04 Jonathan Wakely <jwakely@redhat.com>
11302
11303 * doc/extend.texi (Long Long, Hex Floats): Document support for
11304 long long and hex floats in more recent versions of ISO C++.
11305
11306 2018-09-03 Richard Biener <rguenther@suse.de>
11307
11308 PR tree-optimization/87177
11309 * tree-ssa-sccvn.c (vuse_ssa_val): Revert previous change, keep
11310 cleanup.
11311
11312 2018-09-03 Alexander Monakov <amonakov@ispras.ru>
11313
11314 * bb-reorder.c (edge_order): Convert to C-qsort-style
11315 tri-state comparator.
11316 (reorder_basic_blocks_simple): Change std::stable_sort to
11317 gcc_stablesort.
11318
11319 2018-09-03 Alexander Monakov <amonakov@ispras.ru>
11320
11321 * tree-loop-distribution.c (offset_cmp): Convert to C-qsort-style
11322 tri-state comparator.
11323 (fuse_memset_builtins): Change std::stable_sort to gcc_stablesort.
11324
11325 2018-09-03 Alexander Monakov <amonakov@ispras.ru>
11326
11327 * sort.cc (struct sort_ctx): New field 'nlim'. Use it...
11328 (mergesort): ... here as maximum count for using netsort.
11329 (gcc_qsort): Set nlim to 3 if stable sort is requested.
11330 (gcc_stablesort): New.
11331 * system.h (gcc_stablesort): Declare.
11332
11333 2018-09-03 Alexander Monakov <amonakov@ispras.ru>
11334
11335 * sort.cc (gcc_qsort) [CHECKING_P]: Call qsort_chk.
11336 * system.h (qsort): Always redirect to gcc_qsort. Update comment.
11337 * vec.c (qsort_chk): Do not call gcc_qsort. Update comment.
11338
11339 2018-09-03 Segher Boessenkool <segher@kernel.crashing.org>
11340
11341 * config/rs6000/rs6000.md (*mov<mode>_hardfloat32): Remove %U from the
11342 lxsdx and stxsdx alternatives.
11343 (*mov<mode>_hardfloat64): Ditto.
11344 * config/rs6000/vsx.md (*vsx_extract_<mode>_store): Ditto.
11345
11346 2018-09-03 Richard Biener <rguenther@suse.de>
11347
11348 PR tree-optimization/87200
11349 * tree-ssa-sccvn.c (vn_nary_build_or_lookup_1): Valueize a
11350 simplify result.
11351
11352 2018-09-03 Martin Liska <mliska@suse.cz>
11353
11354 PR tree-optimization/87201
11355 * tree-switch-conversion.c (switch_decision_tree::balance_case_nodes):
11356 Fix parenthesis in an expression.
11357
11358 2018-09-03 Richard Biener <rguenther@suse.de>
11359
11360 PR tree-optimization/87197
11361 * tree-ssa-sccvn.c (vn_nary_build_or_lookup_1): Mark the new def
11362 visited. CSE the VN_INFO hashtable lookup.
11363
11364 PR tree-optimization/87169
11365 * tree-ssa-sccvn.c (do_rpo_vn): When marking loops for not
11366 iterating make sure there's no extra backedges from irreducible
11367 regions feeding the header. Mark the destination block
11368 executable.
11369
11370 2018-09-03 Martin Liska <mliska@suse.cz>
11371
11372 PR driver/83193
11373 * common/common-target.def: Add TARGET_GET_VALID_OPTION_VALUES.
11374 * common/common-targhooks.c (default_get_valid_option_values):
11375 New function.
11376 * common/common-targhooks.h (default_get_valid_option_values):
11377 Likewise.
11378 * common/config/i386/i386-common.c: Move processor_target_table
11379 from i386.c.
11380 (ix86_get_valid_option_values): New function.
11381 (TARGET_GET_VALID_OPTION_VALUES): New macro.
11382 * config/i386/i386.c (struct ptt): Move to i386-common.c.
11383 (PTA_*): Move all defined masks into i386-common.c.
11384 (ix86_function_specific_restore): Use new processor_cost_table.
11385 * config/i386/i386.h (struct ptt): Moved from i386.c.
11386 (struct pta): Likewise.
11387 * doc/tm.texi: Document new TARGET_GET_VALID_OPTION_VALUES.
11388 * doc/tm.texi.in: Likewise.
11389 * opt-suggestions.c (option_proposer::suggest_option):
11390 Pass prefix to build_option_suggestions.
11391 (option_proposer::get_completions): Likewise.
11392 (option_proposer::build_option_suggestions): Use the new target
11393 hook.
11394 * opts.c (struct option_help_tuple): New struct.
11395 (print_filtered_help): Use the new target hook.
11396
11397 2018-09-03 Martin Liska <mliska@suse.cz>
11398
11399 PR middle-end/59521
11400 * predict.c (set_even_probabilities): Add likely_edges
11401 argument and handle cases where we have precisely one
11402 likely edge.
11403 (combine_predictions_for_bb): Catch also likely_edges.
11404 (tree_predict_by_opcode): Handle gswitch statements.
11405 * tree-cfg.h (find_case_label_for_value): New declaration.
11406 (find_taken_edge_switch_expr): Likewise.
11407 * tree-switch-conversion.c (switch_decision_tree::balance_case_nodes):
11408 Find pivot in decision tree based on probabily, not by number of
11409 nodes.
11410
11411 2018-09-02 Gerald Pfeifer <gerald@pfeifer.com>
11412
11413 * doc/standards.texi (Standards): Update Objective-C reference.
11414
11415 2018-09-01 Gerald Pfeifer <gerald@pfeifer.com>
11416
11417 * doc/install.texi (Prerequisites): Update link for MPC.
11418
11419 2018-09-01 Michael Matz <matz@suse.de>
11420
11421 PR tree-optimization/87074
11422 * gimple-loop-jam.c (unroll_jam_possible_p): Check loop exit
11423 PHIs for outer-loop uses.
11424
11425 2018-09-01 Gerald Pfeifer <gerald@pfeifer.com>
11426
11427 * doc/generic.texi (OpenMP): Adjust link to openmp.org.
11428 * doc/invoke.texi (C Dialect Options): Ditto.
11429
11430 2018-09-01 Gerald Pfeifer <gerald@pfeifer.com>
11431
11432 * doc/install.texi (Prerequisites): Adjust link mpfr.org.
11433
11434 2018-08-31 Richard Biener <rguenther@suse.de>
11435
11436 PR tree-optimization/87168
11437 * tree-ssa-sccvn.c (SSA_VAL): Add visited output parameter.
11438 (rpo_elim::eliminate_avail): When OP was not visited it must
11439 be available.
11440
11441 2018-08-31 David Malcolm <dmalcolm@redhat.com>
11442
11443 * tree-vrp.c (copy_value_range): Convert param "from" from
11444 "value_range *" to "const value_range *".
11445 (range_is_null): Likewise for param "vr".
11446 (range_int_cst_p): Likewise.
11447 (range_int_cst_singleton_p): Likewise.
11448 (symbolic_range_p): Likewise.
11449 (value_ranges_intersect_p): Likewise for both params.
11450 (value_range_nonnegative_p): Likewise for param "vr".
11451 (value_range_constant_singleton): Likewise.
11452 (vrp_set_zero_nonzero_bits): Likewise for param "ar".
11453 (extract_range_into_wide_ints): Likewise for param "vr".
11454 (extract_range_from_multiplicative_op): Likewise for params "vr0"
11455 and "vr1".
11456 (vrp_can_optimize_bit_op): Likewise.
11457 (extract_range_from_binary_expr_1): Likewise for params "vr0_" and
11458 "vr1_".
11459 (extract_range_from_unary_expr): Likewise.
11460 (debug_value_range): Likewise for param "vr".
11461 (value_range::dump): Add "const" qualifier.
11462 (vrp_prop::check_array_ref): Convert local "vr" from
11463 "value_range *" to "const value_range *".
11464 (vrp_prop::check_mem_ref): Likewise.
11465 (vrp_prop::visit_stmt): Likewise for local "old_vr".
11466 (vrp_intersect_ranges_1): Likewise for param "vr_1".
11467 (vrp_intersect_ranges): Likewise.
11468 (simplify_stmt_for_jump_threading): Likewise for local "vr".
11469 (vrp_prop::vrp_finalize): Likewise.
11470 * tree-vrp.h (value_range::dump): Add "const" qualifier.
11471 (vrp_intersect_ranges): Add "const" qualifier to params as above.
11472 (extract_range_from_unary_expr): Likewise.
11473 (value_range_constant_singleton): Likewise.
11474 (symbolic_range_p): Likewise.
11475 (copy_value_range): Likewise.
11476 (extract_range_from_binary_expr_1): Likewise.
11477 (range_int_cst_p): Likewise.
11478 (vrp_set_zero_nonzero_bits): Likewise.
11479 (range_int_cst_singleton_p): Likewise.
11480
11481 2018-08-31 Vlad Lazar <vlad.lazar@arm.com>
11482
11483 * config/aarch64/arm_neon.h (vabsd_s64): New.
11484 (vnegd_s64): Likewise.
11485
11486 2018-08-31 Martin Jambor <mjambor@suse.cz>
11487
11488 * ipa-cp.c (estimate_local_effects): Replace wrong MAX with MIN.
11489
11490 2018-08-31 Martin Liska <mliska@suse.cz>
11491
11492 * ipa-icf.c (sem_item::add_type): Use
11493 sem_item::m_type_hash_cache.
11494 * ipa-icf.h: Move the cache from sem_item_optimizer
11495 to sem_item.
11496
11497 2018-08-31 Nathan Sidwell <nathan@acm.org>
11498
11499 * doc/extend.texi (Backwards Compatibility): Remove implicit
11500 extern C leeway of () being (...).
11501
11502 2018-08-31 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
11503
11504 * ipa-inline.c (can_inline_edge_by_limits_p): Fix typos in comment.
11505
11506 2018-08-31 Segher Boessenkool <segher@kernel.crashing.org>
11507
11508 PR target/86684
11509 PR target/87149
11510 * config/rs6000/rs6000.md (lround<mode>di2): Gate on TARGET_FPRND.
11511
11512 2018-08-31 Jakub Jelinek <jakub@redhat.com>
11513
11514 PR middle-end/87138
11515 * expmed.c (expand_mult_const): Use immed_wide_int_const instead of
11516 gen_int_mode. Formatting fixes.
11517
11518 2018-08-30 Sandra Loosemore <sandra@codesourcery.com>
11519
11520 * target.def (custom_function_descriptors): Improve documentation.
11521 * doc/tm.texi.in (Trampolines): Expand discussion of function
11522 descriptors and move TARGET_CUSTOM_FUNCTION_DESCRIPTORS to the
11523 beginning of the section.
11524 * doc/tm.texi: Regenerated.
11525
11526 2018-08-30 Jose E. Marchesi <jose.marchesi@oracle.com>
11527
11528 * cfg.h (class auto_edge_flag): Spell out the template-id of the
11529 base class in the initializer list. This is a workaround for
11530 building with older GCC.
11531 (class auto_bb_flag): Likewise.
11532
11533 2018-08-30 Aaron Sawdey <acsawdey@linux.ibm.com>
11534
11535 * config/rs6000/altivec.md (altivec_eq<mode>): Remove star.
11536 (altivec_vcmpequ<VI_char>_p): Remove star.
11537 * config/rs6000/rs6000-string.c (do_load_for_compare): Support
11538 vector load modes.
11539 (expand_strncmp_vec_sequence): New function.
11540 (emit_final_str_compare_vec): New function.
11541 (expand_strn_compare): Add support for vector strncmp.
11542 * config/rs6000/rs6000.opt (-mstring-compare-inline-limit): Change
11543 length specification to bytes.
11544 * config/rs6000/vsx.md (vsx_ld_elemrev_v16qi_internal): Remove star.
11545 (vcmpnezb_p): New pattern.
11546 * doc/invoke.texi (RS/6000 and PowerPC Options): Update documentation
11547 for option -mstring-compare-inline-limit.
11548
11549 2018-08-30 Thiago Macieira <thiago.macieira@intel.com>
11550
11551 * config/i386/i386.c (PTA_WESTMERE): Remove PTA_AES.
11552 (PTA_SKYLAKE): Add PTA_AES.
11553 (PTA_GOLDMONT): Likewise.
11554
11555 2018-08-29 Jan Hubicka <jh@suse.cz>
11556
11557 PR lto/86517
11558 * lto-opts.c (lto_write_options): Always stream PIC/PIE mode.
11559 * lto-wrapper.c (merge_and_complain): Fix merging of PIC/PIE.
11560
11561 2018-08-29 Jan Hubicka <jh@suse.cz>
11562
11563 * lto-streamer-out.c (DFS::DFS_write_tree_body): Do not follow
11564 TYPE_STUB_DECL.
11565 (hash_tree): Do not visit TYPE_STUB_DECL.
11566 * tree-streamer-out.c (write_ts_type_common_tree_pointers): Do not
11567 stream TYPE_STUB_DECL.
11568 * tree-streamer-in.c (lto_input_ts_type_common_tree_pointers): Likewise.
11569 * ipa-utils.h (type_with_linkage_p): Do not rely on TYPE_STUB_DECL
11570 after free_lang_data.
11571 (type_in_anonymous_namespace_p): Likewise.
11572
11573 2018-08-29 Jan Hubicka <jh@suse.cz>
11574
11575 * sreal.h (SREAL_PART_BITS): Change to 31; remove seemingly unnecessary
11576 comment that it has to be even number.
11577 (class sreal): Change m_sig type to int32_t.
11578 * sreal.c (sreal::dump, sreal::to_int, opreator+, operator-): Use
11579 int64_t for temporary calculations.
11580 (sreal_verify_basics): Drop one bit from minimum and maximum.
11581
11582 2018-08-30 Richard Biener <rguenther@suse.de>
11583
11584 PR tree-optimization/87147
11585 * tree-ssa-sccvn.c (SSA_VISITED): New function.
11586 (visit_phi): When the degenerate result is from the backedge and
11587 we didn't visit its definition yet drop to VARYING.
11588 (do_rpo_vn): Properly mark blocks with incoming backedges as executable.
11589
11590 2018-08-29 Jan Hubicka <jh@suse.cz>
11591
11592 * lto-streamer-out.c (DFS::DFS_write_tree_body): Do not walk
11593 DECL_VINDEX.
11594 (hash_tree): Likewise.
11595
11596 2018-08-29 Jan Hubicka <jh@suse.cz>
11597
11598 * tree.c (find_decls_types_r): Walk also TYPE_NEXT_PTR_TO
11599 and TYPE_NEXT_REF_TO.
11600
11601 2018-08-29 Jan Hubicka <jh@suse.cz>
11602
11603 * sreal.h (SREAL_PART_BITS): Change to 31; remove seemingly unnecessary
11604 comment that it has to be even number.
11605 (class sreal): Change m_sig type to int32_t.
11606 * sreal.c (sreal::dump, sreal::to_int, opreator+, operator-): Use
11607 int64_t for temporary calculations.
11608 (sreal_verify_basics): Drop one bit from minimum and maximum.
11609
11610 2018-08-30 Tamar Christina <tamar.christina@arm.com>
11611
11612 * config/aarch64/aarch64.c (aarch64_expand_movmem): Set TImode max.
11613
11614 2018-08-30 Vlad Lazar <vlad.lazar@arm.com>
11615
11616 PR middle-end/86995
11617 * expmed.c (canonicalize_comparison): Use wi::sub instead of wi::add
11618 if to_add is negative.
11619
11620 2018-08-29 Bernd Edlinger <bernd.edlinger@hotmail.de>
11621
11622 PR middle-end/87053
11623 * builtins.c (c_strlen): Improve range checks.
11624
11625 2018-08-29 Martin Sebor <msebor@redhat.com>
11626 Jeff Law <law@redhat.com>
11627
11628 PR tree-optimization/86714
11629 PR tree-optimization/86711
11630 * builtins.c (c_strlen): Add arguments to call to string_constant.
11631 * expr.c (string_constant): Add argument. Detect missing nul
11632 terminator and outermost declaration it's missing in.
11633 * expr.h (string_constant): Add argument.
11634 * fold-const.c (read_from_constant_string): Add arguments to call to
11635 string_constant.
11636 (c_getstr): Likewise.
11637 * tree-ssa-forwprop.c (simplify_builtin_call): Likewise.
11638 to string_constant.
11639 * tree-ssa-strlen.c (get_stridx): Likewise.
11640
11641 2018-08-29 Jan Hubicka <jh@suse.cz>
11642
11643 * tree-streamer-in.c (lto_input_ts_function_decl_tree_pointers):
11644 Do not stream DECL_VINDEX.
11645 * tree-streamer-out.c (write_ts_function_decl_tree_pointers): Likewise.
11646 * tree.c (free_lang_data_in_decl): Clear DECL_VINDEX.
11647 (decl_function_context): Use DECL_VIRTUAL_P rather than DECL_VINDEX.
11648
11649 2018-08-29 Richard Biener <rguenther@suse.de>
11650
11651 * tree-ssa-sccvn.c (vuse_ssa_val): Return NULL for unvisited
11652 virtual operands that are not default defs to honor region
11653 boundaries.
11654 (rpo_vn_valueize): Remove ineffective code here.
11655
11656 2018-08-29 Richard Biener <rguenther@suse.de>
11657
11658 PR tree-optimization/87132
11659 * tree-ssa-alias.c (get_continuation_for_phi): Do not translate
11660 when skipping defs reachable over backedges.
11661
11662 2018-08-29 Richard Biener <rguenther@suse.de>
11663
11664 * tree-core.h: Document use of deprecated_flag in SSA_NAME.
11665 * tree.h (SSA_NAME_POINTS_TO_READONLY_MEMORY): Define.
11666 * tree-into-ssa.c (pass_build_ssa::execute): Initialize
11667 function parameters SSA_NAME_POINTS_TO_READONLY_MEMORY from fnspec.
11668 * tree-ssa-sccvn.c (const_parms, init_const_parms): Remove.
11669 (vn_reference_lookup_3): Remove use of const_parms.
11670 (free_rpo_vn): Do not free const_parms.
11671 (do_rpo_vn): Do not call init_const_parms.
11672 * tree-ssa-alias.c (refs_may_alias_p_1): Honor
11673 SSA_NAME_POINTS_TO_READONLY_MEMORY.
11674 (call_may_clobber_ref_p_1): Likewise.
11675
11676 2018-08-29 Alexander Monakov <amonakov@ispras.ru>
11677
11678 PR other/86726
11679 * invoke.texi (Optimization Options): List -ftree-scev-cprop.
11680 (-O): Ditto.
11681 (-ftree-scev-cprop): Document.
11682
11683 2018-08-29 Jan Hubicka <jh@suse.cz>
11684
11685 * sreal.h (normalize, normalize_up, normalize_down): Add new_sig/new_exp
11686 parameters.
11687 (sreal constructor): Update.
11688 * sreal.c (sreal:operator+, sreal:operator-, sreal:operator*,
11689 sreal:operator/): Update.
11690
11691 2018-08-29 Martin Liska <mliska@suse.cz>
11692
11693 * tree-switch-conversion.c (switch_conversion::expand):
11694 Strenghten assumption about gswitch statements.
11695
11696 2018-08-29 Richard Biener <rguenther@suse.de>
11697
11698 PR tree-optimization/87117
11699 * tree-ssa-sccvn.c (eliminate_dom_walker::eliminate_stmt): Only
11700 re-value-number released SSA VDEFs.
11701
11702 2018-08-29 Richard Biener <rguenther@suse.de>
11703
11704 PR tree-optimization/87126
11705 * tree-ssa-sccvn.c (vn_reference_insert): Remove assert.
11706
11707 2018-08-28 Jim Wilson <jimw@sifive.com>
11708
11709 * config/riscv/pic.md: Rewrite.
11710 * config/riscv/riscv.c (riscv_address_insns): Return cost of 3 for
11711 invalid address.
11712 * config/riscv/riscv.md (ZERO_EXTEND_LOAD): Delete.
11713 (SOFTF, default_load, softload, softstore): New.
11714
11715 2018-08-28 Jeff Law <law@redhat.com>
11716
11717 * fold-const.c (fold_binary_loc): Remove recently added assert.
11718
11719 2018-08-28 Joern Rennecke <joern.rennecke@riscy-ip.com>
11720
11721 * genpreds.c (write_predicate_subfunction): Also add ATTRIBUTE_UNUSED
11722 to OP parmeter of generated function.
11723
11724 2018-08-28 MCC CS <deswurstes@users.noreply.github.com>
11725
11726 PR tree-optimization/87009
11727 * match.pd: Add boolean optimizations.
11728
11729 2018-08-28 Martin Sebor <msebor@redhat.com>
11730
11731 PR middle-end/86631
11732 * calls.c (alloc_max_size): Treat HOST_WIDE_INT special.
11733 * gimple-ssa-warn-alloca.c (adjusted_warn_limit): New function.
11734 (pass_walloca::gate): Use it.
11735 (alloca_call_type): Same.
11736 (pass_walloca::execute): Same.
11737 * stor-layout.c (layout_decl): Treat HOST_WIDE_INT special.
11738
11739 2018-08-28 David Malcolm <dmalcolm@redhat.com>
11740
11741 * dumpfile.h (ATTRIBUTE_GCC_DUMP_PRINTF): Change version check on
11742 GCC_VERSION for usage of "__gcc_dump_printf__" format from
11743 >= 3005 to >= 9000.
11744
11745 2018-08-28 Richard Biener <rguenther@suse.de>
11746
11747 PR tree-optimization/87124
11748 * tree-ssa-sccvn.c (vn_lookup_simplify_result): Guard against
11749 constants before looking up avail.
11750
11751 2018-08-28 Jakub Jelinek <jakub@redhat.com>
11752
11753 PR middle-end/87099
11754 * calls.c (maybe_warn_nonstring_arg): Punt early if
11755 warn_stringop_overflow is zero. Don't call get_range_strlen
11756 on 3rd argument, keep iterating until lenrng[1] is INTEGER_CST.
11757 Swap comparison operands to have constants on rhs. Only use
11758 lenrng[1] if non-NULL and INTEGER_CST. Don't uselessly
11759 increment lenrng[0].
11760
11761 2018-08-28 Richard Sandiford <richard.sandiford@arm.com>
11762
11763 * tree-ssa-sccvn.c (fully_constant_vn_reference_p): Fix unguarded
11764 use of tree_to_shwi. Remove duplicated test for the size being
11765 a whole number of bytes.
11766
11767 2018-08-28 Richard Biener <rguenther@suse.de>
11768
11769 PR tree-optimization/87117
11770 * tree-ssa-sccvn.c (eliminate_dom_walker::eliminate_cleanup):
11771 Handle removed stmt without LHS (GIMPLE_NOP).
11772
11773 2018-08-28 Richard Biener <rguenther@suse.de>
11774
11775 PR tree-optimization/87117
11776 * tree-ssa-sccvn.c (fully_constant_vn_reference_p): Exclude
11777 void which is is_gimple_reg_type by checking for COMPLETE_TYPE_P.
11778
11779 2018-08-28 Richard Biener <rguenther@suse.de>
11780
11781 PR tree-optimization/87117
11782 * tree-ssa-pre.c (compute_avail): Do not make expressions
11783 with predicated values available.
11784 (get_expr_value_id): Assert we do not run into predicated value
11785 expressions.
11786
11787 2018-08-28 Richard Biener <rguenther@suse.de>
11788
11789 PR tree-optimization/87117
11790 * tree-ssa-operands.c (add_stmt_operand): STRING_CST may
11791 get virtual operands.
11792 (get_expr_operands): Handle STRING_CST like other decls.
11793
11794 2018-08-28 Martin Liska <mliska@suse.cz>
11795
11796 * tree.h: Update documentation of fndecl_built_in_p
11797 functions.
11798
11799
11800 2018-08-27 Jeff Law <law@redhat.com>
11801 PR tree-optimization/87110
11802 * tree-ssa-dse.c (compute_trims): Handle non-constant
11803 TYPE_SIZE_UNIT.
11804
11805 2018-08-27 Martin Sebor <msebor@redhat.com>
11806
11807 PR tree-optimization/86914
11808 * tree-ssa-strlen.c (maybe_set_strlen_range): Avoid MEM_REF.
11809
11810 2018-08-27 Martin Sebor <msebor@redhat.com>
11811
11812 PR tree-optimization/87112
11813 * builtins.c (expand_builtin_strnlen): Convert c_strlen result to
11814 the type of the bound argument.
11815
11816 2018-08-27 Jeff Law <law@redhat.com>
11817
11818 * tree-ssa-dse.c (compute_trims): Handle case where the reference's
11819 type does not have a TYPE_SIZE_UNIT.
11820
11821 2018-08-27 Steve Ellcey <sellcey@cavium.com>
11822
11823 * config/aarch64/aarch64-speculation.cc: Replace include of cfg.h
11824 with include of backend.h.
11825
11826 2018-08-27 Richard Biener <rguenther@suse.de>
11827
11828 PR tree-optimization/86927
11829 * tree-vect-loop.c (vect_create_epilog_for_reduction): Properly
11830 use const cond reduction code.
11831
11832 2018-08-27 Alexander Monakov <amonakov@ispras.ru>
11833
11834 PR tree-optimization/85758
11835 * match.pd ((X & Y) ^ Y): Add :s qualifier to inner expression.
11836
11837 2018-08-27 David Malcolm <dmalcolm@redhat.com>
11838
11839 PR c++/87091
11840 * diagnostic-show-locus.c (class layout_range): Update for
11841 conversion of show_caret_p to a tri-state.
11842 (layout_range::layout_range): Likewise.
11843 (make_range): Likewise.
11844 (layout::maybe_add_location_range): Likewise.
11845 (layout::should_print_annotation_line_p): Don't show annotation
11846 lines for ranges that are SHOW_LINES_WITHOUT_RANGE.
11847 (layout::get_state_at_point): Update for conversion of
11848 show_caret_p to a tri-state. Bail out early for
11849 SHOW_LINES_WITHOUT_RANGE, so that such ranges don't affect
11850 underlining or source colorization.
11851 (gcc_rich_location::add_location_if_nearby): Update for conversion
11852 of show_caret_p to a tri-state.
11853 (selftest::test_one_liner_multiple_carets_and_ranges): Likewise.
11854 (selftest::test_one_liner_fixit_replace_equal_secondary_range):
11855 Likewise.
11856 (selftest::test_one_liner_labels): Likewise.
11857 * gcc-rich-location.c (gcc_rich_location::add_expr): Update for
11858 conversion of show_caret_p to a tri-state.
11859 * pretty-print.c (text_info::set_location): Likewise.
11860 * pretty-print.h (text_info::set_location): Likewise.
11861 * substring-locations.c (format_warning_n_va): Likewise.
11862 * tree-diagnostic.c (default_tree_printer): Likewise.
11863 * tree-pretty-print.c (newline_and_indent): Likewise.
11864
11865 2018-08-27 David Malcolm <dmalcolm@redhat.com>
11866
11867 PR c++/87091
11868 * diagnostic-show-locus.c (get_line_span_for_fixit_hint): Show the
11869 line above for line-insertion fix-it hints.
11870 (selftest::test_fixit_insert_containing_newline): Update the
11871 expected results, and add a test with line-numbering enabled.
11872
11873 2018-08-27 Martin Liska <mliska@suse.cz>
11874
11875 PR sanitizer/86962
11876 * sanopt.c (sanitize_rewrite_addressable_params): Ignore
11877 params with DECL_HAS_VALUE_EXPR_P.
11878
11879 2018-08-27 Martin Liska <mliska@suse.cz>
11880
11881 * config/i386/i386.c (ix86_expand_set_or_movmem): Dump
11882 selected expansion strategy.
11883
11884 2018-08-27 Martin Liska <mliska@suse.cz>
11885
11886 * builtins.h (is_builtin_fn): Remove and fndecl_built_in_p.
11887 * builtins.c (is_builtin_fn): Likewise.
11888 * attribs.c (diag_attr_exclusions): Use new function
11889 fndecl_built_in_p and remove check for FUNCTION_DECL if
11890 possible.
11891 (builtin_mathfn_code): Likewise.
11892 (fold_builtin_expect): Likewise.
11893 (fold_call_expr): Likewise.
11894 (fold_builtin_call_array): Likewise.
11895 (fold_call_stmt): Likewise.
11896 (set_builtin_user_assembler_name): Likewise.
11897 (is_simple_builtin): Likewise.
11898 * calls.c (gimple_alloca_call_p): Likewise.
11899 (maybe_warn_nonstring_arg): Likewise.
11900 * cfgexpand.c (expand_call_stmt): Likewise.
11901 * cgraph.c (cgraph_update_edges_for_call_stmt_node): Likewise.
11902 (cgraph_edge::verify_corresponds_to_fndecl): Likewise.
11903 (cgraph_node::verify_node): Likewise.
11904 * cgraphclones.c (build_function_decl_skip_args): Likewise.
11905 (cgraph_node::create_clone): Likewise.
11906 * config/arm/arm.c (arm_insert_attributes): Likewise.
11907 * config/i386/i386.c (ix86_gimple_fold_builtin): Likewise.
11908 * dse.c (scan_insn): Likewise.
11909 * expr.c (expand_expr_real_1): Likewise.
11910 * fold-const.c (operand_equal_p): Likewise.
11911 (fold_binary_loc): Likewise.
11912 * gimple-fold.c (gimple_fold_stmt_to_constant_1): Likewise.
11913 * gimple-low.c (lower_stmt): Likewise.
11914 * gimple-pretty-print.c (dump_gimple_call): Likewise.
11915 * gimple-ssa-warn-restrict.c (wrestrict_dom_walker::check_call):
11916 Likewise.
11917 * gimple.c (gimple_build_call_from_tree): Likewise.
11918 (gimple_call_builtin_p): Likewise.
11919 (gimple_call_combined_fn): Likewise.
11920 * gimplify.c (gimplify_call_expr): Likewise.
11921 (gimple_boolify): Likewise.
11922 (gimplify_modify_expr): Likewise.
11923 (gimplify_addr_expr): Likewise.
11924 * hsa-gen.c (gen_hsa_insns_for_call): Likewise.
11925 * ipa-cp.c (determine_versionability): Likewise.
11926 * ipa-fnsummary.c (compute_fn_summary): Likewise.
11927 * ipa-param-manipulation.c (ipa_modify_formal_parameters): Likewise.
11928 * ipa-split.c (visit_bb): Likewise.
11929 (split_function): Likewise.
11930 * ipa-visibility.c (cgraph_externally_visible_p): Likewise.
11931 * lto-cgraph.c (input_node): Likewise.
11932 * lto-streamer-out.c (write_symbol): Likewise.
11933 * omp-low.c (setjmp_or_longjmp_p): Likewise.
11934 (lower_omp_1): Likewise.
11935 * predict.c (strip_predict_hints): Likewise.
11936 * print-tree.c (print_node): Likewise.
11937 * symtab.c (symtab_node::output_to_lto_symbol_table_p): Likewise.
11938 * trans-mem.c (is_tm_irrevocable): Likewise.
11939 (is_tm_load): Likewise.
11940 (is_tm_simple_load): Likewise.
11941 (is_tm_store): Likewise.
11942 (is_tm_simple_store): Likewise.
11943 (is_tm_abort): Likewise.
11944 (tm_region_init_1): Likewise.
11945 * tree-call-cdce.c (gen_shrink_wrap_conditions): Likewise.
11946 * tree-cfg.c (verify_gimple_call): Likewise.
11947 (move_stmt_r): Likewise.
11948 (stmt_can_terminate_bb_p): Likewise.
11949 * tree-eh.c (lower_eh_constructs_2): Likewise.
11950 * tree-if-conv.c (if_convertible_stmt_p): Likewise.
11951 * tree-inline.c (remap_gimple_stmt): Likewise.
11952 (copy_bb): Likewise.
11953 (estimate_num_insns): Likewise.
11954 (fold_marked_statements): Likewise.
11955 * tree-sra.c (scan_function): Likewise.
11956 * tree-ssa-ccp.c (surely_varying_stmt_p): Likewise.
11957 (optimize_stack_restore): Likewise.
11958 (pass_fold_builtins::execute): Likewise.
11959 * tree-ssa-dce.c (mark_stmt_if_obviously_necessary): Likewise.
11960 (mark_all_reaching_defs_necessary_1): Likewise.
11961 * tree-ssa-dom.c (dom_opt_dom_walker::optimize_stmt): Likewise.
11962 * tree-ssa-forwprop.c (simplify_builtin_call): Likewise.
11963 (pass_forwprop::execute): Likewise.
11964 * tree-ssa-loop-im.c (stmt_cost): Likewise.
11965 * tree-ssa-math-opts.c (pass_cse_reciprocals::execute): Likewise.
11966 * tree-ssa-sccvn.c (fully_constant_vn_reference_p): Likewise.
11967 * tree-ssa-strlen.c (get_string_length): Likewise.
11968 * tree-ssa-structalias.c (handle_lhs_call): Likewise.
11969 (find_func_aliases_for_call): Likewise.
11970 * tree-ssa-ter.c (find_replaceable_in_bb): Likewise.
11971 * tree-stdarg.c (optimize_va_list_gpr_fpr_size): Likewise.
11972 * tree-tailcall.c (find_tail_calls): Likewise.
11973 * tree.c (need_assembler_name_p): Likewise.
11974 (free_lang_data_in_decl): Likewise.
11975 (get_call_combined_fn): Likewise.
11976 * ubsan.c (is_ubsan_builtin_p): Likewise.
11977 * varasm.c (incorporeal_function_p): Likewise.
11978 * tree.h (DECL_BUILT_IN): Remove and replace with
11979 fndecl_built_in_p.
11980 (DECL_BUILT_IN_P): Transfort to fndecl_built_in_p.
11981 (fndecl_built_in_p): New.
11982
11983 2018-08-27 Martin Liska <mliska@suse.cz>
11984
11985 PR tree-optimization/86847
11986 * tree-switch-conversion.c (switch_decision_tree::dump_case_nodes):
11987 Dump also subtree probability.
11988 (switch_decision_tree::do_jump_if_equal): New function.
11989 (switch_decision_tree::emit_case_nodes): Handle special
11990 situations in balanced tree that can be emitted much simpler.
11991 Fix calculation of probabilities that happen in tree expansion.
11992 * tree-switch-conversion.h (struct cluster): Add
11993 is_single_value_p.
11994 (struct simple_cluster): Likewise.
11995 (struct case_tree_node): Add new function has_child.
11996 (do_jump_if_equal): New.
11997
11998 2018-08-27 Martin Liska <mliska@suse.cz>
11999
12000 * tree-switch-conversion.c (bit_test_cluster::find_bit_tests):
12001 Add new argument to bit_test_cluster constructor.
12002 (bit_test_cluster::emit): Set bits really number of values
12003 handlel by a test.
12004 (bit_test_cluster::hoist_edge_and_branch_if_true): Add
12005 probability argument.
12006 * tree-switch-conversion.h (struct bit_test_cluster):
12007 Add m_handles_entire_switch.
12008
12009 2018-08-27 Martin Liska <mliska@suse.cz>
12010
12011 PR tree-optimization/86702
12012 * tree-switch-conversion.c (jump_table_cluster::emit):
12013 Make probabilities even for values in jump table
12014 according to number of cases handled.
12015 (switch_decision_tree::compute_cases_per_edge): Pass
12016 argument to reset_out_edges_aux function.
12017 (switch_decision_tree::analyze_switch_statement): Likewise.
12018 * tree-switch-conversion.h (switch_decision_tree::reset_out_edges_aux):
12019 Make it static.
12020
12021 2018-08-27 Martin Liska <mliska@suse.cz>
12022
12023 * cfgexpand.c (expand_asm_stmt): Use label_to_block and pass
12024 cfun argument explicitly.
12025 * gimple-pretty-print.c (dump_gimple_switch): Likewise.
12026 * hsa-gen.c (gen_hsa_insns_for_switch_stmt): Use new
12027 function gimple_switch_default_bb.
12028 (convert_switch_statements):
12029 (expand_builtins):
12030 * ipa-fnsummary.c (set_switch_stmt_execution_predicate):
12031 * stmt.c (label_to_block_fn): Use label_to_block and pass
12032 cfun argument explicitly and use gimple_switch_label_bb.
12033 (expand_case): Likewise.
12034 * tree-cfg.c (lower_phi_internal_fn): Use label_to_block and pass
12035 cfun argument explicitly. Likewise.
12036 (make_edges_bb): Likewise.
12037 (make_cond_expr_edges): Likewise.
12038 (get_cases_for_edge): Likewise.
12039 (make_gimple_switch_edges): Likewise.
12040 (label_to_block_fn): Likewise.
12041 (label_to_block): Likewise.
12042 (make_goto_expr_edges): Likewise.
12043 (make_gimple_asm_edges): Likewise.
12044 (main_block_label): Likewise.
12045 (group_case_labels_stmt): Likewise.
12046 (find_taken_edge_computed_goto): Likewise.
12047 (find_taken_edge_switch_expr): Likewise.
12048 (gimple_verify_flow_info): Likewise.
12049 (gimple_redirect_edge_and_branch): Likewise.
12050 (gimple_switch_label_bb): New function.
12051 (gimple_switch_default_bb): Likewise.
12052 (gimple_switch_edge): Likewise.
12053 (gimple_switch_default_edge): Likewise.
12054 * tree-cfg.h (label_to_block_fn): Remove and replace ...
12055 (label_to_block): ... with this.
12056 (gimple_switch_label_bb): New.
12057 (gimple_switch_default_bb): Likewise.
12058 (gimple_switch_edge): Likewise.
12059 (gimple_switch_default_edge): Likewise.
12060 * tree-cfgcleanup.c (convert_single_case_switch): Use
12061 new gimple functions and pass new argument to label_to_block.
12062 (cleanup_control_flow_bb):
12063 * tree-eh.c (make_eh_dispatch_edges): Use label_to_block and pass
12064 cfun argument explicitly.
12065 (make_eh_edges): Likewise.
12066 (redirect_eh_dispatch_edge): Likewise.
12067 (lower_resx): Likewise.
12068 (lower_eh_dispatch): Likewise.
12069 (maybe_remove_unreachable_handlers): Likewise.
12070 (unsplit_eh): Likewise.
12071 (cleanup_empty_eh): Likewise.
12072 (verify_eh_edges): Likewise.
12073 (verify_eh_dispatch_edge): Likewise.
12074 * tree-ssa-dom.c (record_edge_info): Likewise.
12075 * tree-ssa-forwprop.c (simplify_gimple_switch_label_vec): Likewise.
12076 * tree-ssa-threadedge.c (thread_around_empty_blocks): Likewise.
12077 (thread_through_normal_block): Likewise.
12078 * tree-ssa-uncprop.c (associate_equivalences_with_edges): Likewise.
12079 * tree-ssa-uninit.c (convert_control_dep_chain_into_preds):
12080 * tree-switch-conversion.c (switch_conversion::collect): Use new
12081 gimple functions.
12082 (switch_conversion::check_final_bb): Likewise.
12083 (switch_conversion::gather_default_values): Pass new argument
12084 to label_to_block.
12085 (switch_conversion::build_constructors): Likewise.
12086 (switch_decision_tree::compute_cases_per_edge): Use new
12087 gimple_switch_edge function.
12088 (switch_decision_tree::analyze_switch_statement): Pass new argument
12089 to label_to_block.
12090 (switch_decision_tree::try_switch_expansion): Use
12091 gimple_switch_default_edge.
12092 * tree-vrp.c (find_switch_asserts): Pass new argument
12093 to label_to_block.
12094 * vr-values.c (vr_values::vrp_visit_switch_stmt): Likewise.
12095 (vr_values::simplify_switch_using_ranges): Likewise.
12096
12097 2018-08-27 Richard Biener <rguenther@suse.de>
12098
12099 * cfganal.h (rev_post_order_and_mark_dfs_back_seme): Declare.
12100 * cfganal.c (rev_post_order_and_mark_dfs_back_seme): New function.
12101
12102 * tree-ssa-sccvn.h (struct vn_pval): New structure.
12103 (struct vn_nary_op_s): Add unwind_to member. Add
12104 predicated_values flag and put result into a union together
12105 with a linked list of vn_pval.
12106 (struct vn_ssa_aux): Add name member to make maintaining
12107 a map of SSA name to vn_ssa_aux possible. Remove no longer
12108 needed info, dfsnum, low, visited, on_sccstack, use_processed
12109 and range_info_anti_range_p members.
12110 (run_scc_vn, vn_eliminate, free_scc_vn, vn_valueize): Remove.
12111 (do_rpo_vn, run_rpo_vn, eliminate_with_rpo_vn, free_rpo_vn):
12112 New functions.
12113 (vn_valueize): New global.
12114 (vn_context_bb): Likewise.
12115 (VN_INFO_RANGE_INFO, VN_INFO_ANTI_RANGE_P, VN_INFO_RANGE_TYPE,
12116 VN_INFO_PTR_INFO): Remove.
12117 * tree-ssa-sccvn.c: ... (rewrite)
12118 (pass_fre::execute): For -O2+ initialize loops and run
12119 RPO VN in optimistic mode (iterating). For -O1 and -Og
12120 run RPO VN in non-optimistic mode.
12121 * params.def (PARAM_SCCVN_MAX_SCC_SIZE): Remove.
12122 (PARAM_RPO_VN_MAX_LOOP_DEPTH): Add.
12123 * doc/invoke.texi (sccvn-max-scc-size): Remove.
12124 (rpo-vn-max-loop-depth): Document.
12125 * tree-ssa-alias.c (walk_non_aliased_vuses): Stop walking
12126 when valuezing the VUSE signals we walked out of the region.
12127 * tree-ssa-pre.c (phi_translate_1): Ignore predicated values.
12128 (phi_translate): Set VN context block to use for availability
12129 lookup.
12130 (compute_avail): Likewise.
12131 (pre_valueize): New function.
12132 (pass_pre::execute): Adjust to the RPO VN API.
12133
12134 * tree-ssa-loop-ivcanon.c: Include tree-ssa-sccvn.h.
12135 (propagate_constants_for_unrolling): Remove.
12136 (tree_unroll_loops_completely): Perform value-numbering
12137 on the unrolled bodies loop parent.
12138
12139 2018-08-27 Richard Biener <rguenther@suse.de>
12140
12141 * tree-ssa-pre.c (compute_antic): Re-use inverted postorder
12142 for partial antic compute.
12143
12144 2018-08-27 Jakub Jelinek <jakub@redhat.com>
12145
12146 PR rtl-optimization/87065
12147 * combine.c (simplify_if_then_else): Formatting fix.
12148 (if_then_else_cond): Guard MULT optimization with SCALAR_INT_MODE_P
12149 check.
12150 (known_cond): Don't return const_true_rtx for vector modes. Use
12151 CONST0_RTX instead of const0_rtx. Formatting fixes.
12152
12153 2018-08-27 Martin Liska <mliska@suse.cz>
12154
12155 PR gcov-profile/87069
12156 * gcov.c (process_file): Record files already processed
12157 and warn about a file being processed multiple times.
12158
12159 2018-08-27 Martin Liska <mliska@suse.cz>
12160
12161 PR driver/83193
12162 * config/aarch64/aarch64.c (aarch64_override_options_internal):
12163 Set default values for x_aarch64_*_string strings.
12164 * config/aarch64/aarch64.opt: Remove --{march,mcpu,mtune}==
12165 prefix. For -mabi do not print '=ABI' in help and use
12166 <option_value> format for -msve-vector-bits and -moverride
12167 options.
12168
12169 2018-08-26 Jeff Law <law@redhat.com>
12170
12171 * config/mips/frame-header-opt.c: Include "backend.h" rather than
12172 "cfg.h"
12173
12174 2018-08-26 Marek Polacek <polacek@redhat.com>
12175
12176 PR c++/87029, Implement -Wredundant-move.
12177 * doc/invoke.texi: Document -Wredundant-move.
12178
12179 2018-08-25 Martin Sebor <msebor@redhat.com>
12180
12181 PR tree-optimization/87059
12182 * builtins.c (expand_builtin_strncmp): Convert MIN_EXPR operand
12183 to the same type as the other.
12184 * fold-const.c (fold_binary_loc): Assert expectation.
12185
12186 2018-08-25 Iain Sandoe <iain@sandoe.co.uk>
12187
12188 * config/darwin.c (machopic_legitimize_pic_address): Clean up
12189 extraneous parentheses, dead code section and formatting.
12190
12191 2018-08-24 David Malcolm <dmalcolm@redhat.com>
12192
12193 PR c++/87091
12194 * diagnostic-show-locus.c (layout::layout): Ensure the margin is
12195 wide enough for jumps in the line-numbering to be visible.
12196 (layout::print_gap_in_line_numbering): New member function.
12197 (layout::calculate_line_spans): When using line numbering, merge
12198 line spans that are only 1 line apart.
12199 (diagnostic_show_locus): When printing line numbers, show gaps in
12200 line numbering directly, rather than printing headers.
12201 (selftest::test_diagnostic_show_locus_fixit_lines): Add test of
12202 line-numbering with multiple line spans.
12203 (selftest::test_fixit_insert_containing_newline_2): Add test of
12204 line-numbering, in which the spans are close enough to be merged.
12205
12206 2018-08-24 Aldy Hernandez <aldyh@redhat.com>
12207
12208 * gimple-ssa-evrp-analyze.c (set_ssa_range_info): Pass value_range
12209 to range_includes_zero_p. Do not special case VR_ANTI_RANGE.
12210 * tree-vrp.c (range_is_nonnull): Remove.
12211 (range_includes_zero_p): Accept value_range instead of min/max.
12212 (extract_range_from_binary_expr_1): Do not early bail on
12213 POINTER_PLUS_EXPR.
12214 Use range_includes_zero_p instead of range_is_nonnull.
12215 (extract_range_from_unary_expr): Use range_includes_zero_p instead
12216 of range_is_nonnull.
12217 (vrp_meet_1): Pass value_range to range_includes_zero_p. Do not
12218 special case VR_ANTI_RANGE.
12219 (vrp_finalize): Same.
12220 * tree-vrp.h (range_includes_zero_p): Pass value_range as argument
12221 instead of min/max.
12222 (range_is_nonnull): Remove.
12223 * vr-values.c (vrp_stmt_computes_nonzero): Use
12224 range_includes_zero_p instead of range_is_nonnull.
12225 (extract_range_basic): Pass value_range to range_includes_zero_p
12226 instead of range_is_nonnull.
12227
12228 2018-08-24 Uros Bizjak <ubizjak@gmail.com>
12229
12230 * emit-rtl.c (init_emit_once): Do not emit MODE_POINTER_BOUNDS RTXes.
12231 * emit-rtl.h (rtl_data): Remove return_bnd.
12232 * explow.c (trunc_int_for_mode): Do not handle POINTER_BOUNDS_MODE_P.
12233 * function.c (diddle_return_value): Do not handle crtl->return_bnd.
12234 * genmodes.c (complete_mode): Do not handle MODE_POINTER_BOUNDS.
12235 (POINTER_BOUNDS_MODE): Remove definition.
12236 (make_pointer_bounds_mode): Remove.
12237 (get_mode_class): Do not handle MODE_POINTER_BOUNDS.
12238 * machmode.h (POINTER_BOUNDS_MODE_P): Remove definition.
12239 (scalare_mode::includes_p): Do not handle MODE_POINTER_BOUNDS.
12240 * mode-classes.def: Do not define MODE_POINTER_BOUNDS.
12241 * stor-layout.c (int_mode_for_mode): Do not handle MODE_POINTER_BOUNDS.
12242 * tree-core.h (enum tree_index): Remove TI_POINTER_BOUNDS_TYPE.
12243 * varasm.c (output_constant_pool_2): Do not handle MODE_POINTER_BOUNDS.
12244
12245 * config/i386/i386-modes.def (BND32, BND64): Remove.
12246 * config/i386/i386.c (dbx_register_map): Remove bound registers.
12247 (dbx64_register_map): Ditto.
12248 (svr4_dbx_register_map): Ditto.
12249 (indirect_thunk_bnd_needed): Remove.
12250 (indirect_thunks_bnd_used): Ditto.
12251 (indirect_return_bnd_needed): Ditto.
12252 (indirect_return_via_cx_bnd): Ditto.
12253 (enum indirect_thunk_prefix): Remove indirect_thunk_prefix_bnd.
12254 (indirect_thunk_name): Remove handling of indirect_thunk_prefix_bnd.
12255 (output_indirect_thunk): Ditto. Remove need_prefix argument.
12256 (output_indirect_thunk_function): Remove handling of
12257 indirect_return_bnd_needed, indirect_return_via_cx_bnd,
12258 indirect_thunk_bnd_needed and indirect_thunks_bnd_used variables.
12259 (ix86_save_reg): Remove handling of crtl->return_bnd.
12260 (ix86_legitimate_constant_p): Remove handling of POINTER_BOUNDS_MODE_P.
12261 (ix86_print_operand_address_as): Remove handling of UNSPEC_BNDMK_ADDR
12262 and UNSPEC_BNDLX_ADDR.
12263 (ix86_output_indirect_branch_via_reg): Remove handling of
12264 indirect_thunk_prefix_bnd.
12265 (ix86_output_indirect_branch_via_push): Ditto.
12266 (ix86_output_function_return): Ditto.
12267 (ix86_output_indirect_function_return): Ditto.
12268 (avoid_func_arg_motion): Do not handle UNSPEC_BNDSTX.
12269 * config/i386/i386.h (FIXED_REGISTERS): Remove bound registers.
12270 (CALL_USED_REGISTERS): Ditto.
12271 (REG_ALLOC_ORDER): Update for removal of bound registers.
12272 (HI_REGISTER_NAMES): Ditto.
12273 * config/i386/i386.md (UNSPEC_BNDMK, UNSPEC_BNDMK_ADDR, UNSPEC_BNDSTX)
12274 (UNSPEC_BNDLDX, UNSPEC_BNDLDX_ADDR, UNSPEC_BNDCL, UNSPEC_BNDCU)
12275 (UNSPEC_BNDCN, UNSPEC_MPX_FENCE): Remove.
12276 (BND0_REG, BND1_REG, BND2_REG, BND3_REG): Remove
12277 (FIRST_PSEUDO_REG): Update.
12278 (BND): Remove mode iterator.
12279 * config/i386/predicates.md (bnd_mem_operator): Remove.
12280
12281 2018-08-24 Richard Sandiford <richard.sandiford@arm.com>
12282
12283 * tree-vect-stmts.c (vectorizable_bswap): Handle variable-length
12284 vectors.
12285
12286 2018-08-24 Richard Sandiford <richard.sandiford@arm.com>
12287
12288 * tree-vect-slp.c (vect_transform_slp_perm_load): Separate out
12289 the case in which the permute needs only a single element and
12290 repeats for every vector of the result. Extend that case to
12291 handle variable-length vectors.
12292 * tree-vect-stmts.c (vectorizable_load): Update accordingly.
12293
12294 2018-08-24 H.J. Lu <hongjiu.lu@intel.com>
12295
12296 PR debug/79342
12297 * dwarf2out.c (save_macinfo_strings): Call set_indirect_string
12298 on DW_MACINFO_start_file for -gsplit-dwarf -g3.
12299
12300 2018-08-24 Richard Biener <rguenther@suse.de>
12301
12302 * cfg.h (struct control_flow_graph): Add edge_flags_allocated and
12303 bb_flags_allocated members.
12304 (auto_flag): New RAII class for allocating flags.
12305 (auto_edge_flag): New RAII class for allocating edge flags.
12306 (auto_bb_flag): New RAII class for allocating bb flags.
12307 * cfgloop.c (verify_loop_structure): Allocate temporary edge
12308 flag dynamically.
12309 * cfganal.c (dfs_enumerate_from): Remove use of visited sbitmap
12310 in favor of temporarily allocated BB flag.
12311 * hsa-brig.c: Re-order includes.
12312 * hsa-dump.c: Likewise.
12313 * hsa-regalloc.c: Likewise.
12314 * print-rtl.c: Likewise.
12315 * profile-count.c: Likewise.
12316
12317 2018-08-24 Segher Boessenkool <segher@kernel.crashing.org>
12318
12319 PR target/86989
12320 * config/rs6000/rs6000.c (toc_relative_expr_p): Check that the base is
12321 the TOC register.
12322
12323 2018-08-24 Aldy Hernandez <aldyh@redhat.com>
12324
12325 PR 87073/bootstrap
12326 * wide-int-range.cc (wide_int_range_div): Do not ignore result
12327 from wide_int_range_multiplicative_op.
12328
12329 2018-08-23 Prathamesh Kulkarni <prathamesh.kulkarni@linaro.org>
12330
12331 * tree-vect-data-refs.c (vect_grouped_store_supported): Fix typo
12332 "permutaion".
12333
12334 2018-08-23 Giuliano Belinassi <giuliano.belinassi@usp.br>
12335
12336 * genmatch.c (parser::parse_operation): Fix typo 'exapnded'
12337 to 'expanded'.
12338
12339 2018-08-23 Alexander Monakov <amonakov@ispras.ru>
12340
12341 * tree-scalar-evolution.c (final_value_replacement_loop): Dump
12342 full GENERIC expression used for replacement.
12343
12344 2018-08-23 Aldy Hernandez <aldyh@redhat.com>
12345
12346 * tree-vrp.c (abs_extent_range): Remove.
12347 (extract_range_into_wide_ints): Pass wide ints by reference.
12348 (extract_range_from_binary_expr_1): Rewrite the *DIV_EXPR code.
12349 Pass wide ints by reference in all calls to
12350 extract_range_into_wide_ints.
12351 * wide-int-range.cc (wide_int_range_div): New.
12352 * wide-int-range.h (wide_int_range_div): New.
12353 (wide_int_range_includes_zero_p): New.
12354 (wide_int_range_zero_p): New.
12355
12356 2018-08-23 Matthew Malcomson <matthew.malcomson@arm.com>
12357
12358 * config/aarch64/aarch64.md (arches): New enum.
12359 (arch): New enum attr.
12360 (arch_enabled): New attr.
12361 (enabled): Now uses arch_enabled only.
12362 (simd, sve, fp16): Removed attribute.
12363 (fp): Attr now defined in terms of 'arch'.
12364 (*mov<mode>_aarch64, *movsi_aarch64, *movdi_aarch64, *movti_aarch64,
12365 *movhf_aarch64, <optab><fcvt_target><GPF:mode>2,
12366 <FCVT_F2FIXED:fcvt_fixed_insn><GPF:mode>3,
12367 <FCVT_FIXED2F:fcvt_fixed_insn><GPI:mode>3): Merge 'fp' and 'simd'
12368 attributes into 'arch'.
12369 (*movsf_aarch64, *movdf_aarch64, *movtf_aarch64, *add<mode>3_aarch64,
12370 subdi3, neg<mode>2, <optab><mode>3, one_cmpl<mode>2,
12371 *<NLOGICAL:optab>_one_cmpl<mode>3, *xor_one_cmpl<mode>3,
12372 *aarch64_ashl_sisd_or_int_<mode>3, *aarch64_lshr_sisd_or_int_<mode>3,
12373 *aarch64_ashr_sisd_or_int_<mode>3, *aarch64_sisd_ushl): Convert use of
12374 'simd' attribute into 'arch'.
12375 (load_pair_sw_<SX:mode><SX2:mode>, load_pair_dw_<DX:mode><DX2:mode>,
12376 store_pair_sw_<SX:mode><SX2:mode>, store_pair_dw_<DX:mode><DX2:mode>):
12377 Convert use of 'fp' attribute to 'arch'.
12378 * config/aarch64/aarch64-simd.md (move_lo_quad_internal_<mode>,
12379 move_lo_quad_internal_<mode>): (different modes) Merge 'fp' and 'simd'
12380 into 'arch'.
12381 (move_lo_quad_internal_be_<mode>, move_lo_quad_internal_be_<mode>):
12382 (different modes) Merge 'fp' and 'simd' into 'arch'.
12383 (*aarch64_combinez<mode>, *aarch64_combinez_be<mode>): Merge 'fp' and
12384 'simd' into 'arch'.
12385
12386 2018-08-23 Segher Boessenkool <segher@kernel.crashing.org>
12387
12388 PR rtl-optimization/87026
12389 * expmed.c (canonicalize_comparison): If we can no longer create
12390 pseudoregisters, don't.
12391
12392 2018-08-23 Richard Earnshaw <rearnsha@arm.com>
12393
12394 PR target/86951
12395 * config/arm/arm-protos.h (arm_emit_speculation_barrier): New
12396 prototype.
12397 * config/arm/arm.c (speculation_barrier_libfunc): New static
12398 variable.
12399 (arm_init_libfuncs): Initialize it.
12400 (arm_emit_speculation_barrier): New function.
12401 * config/arm/arm.md (speculation_barrier): Call
12402 arm_emit_speculation_barrier for architectures that do not have
12403 DSB or ISB.
12404 (speculation_barrier_insn): Only match on Armv7 or later.
12405
12406 2018-08-23 Richard Biener <rguenther@suse.de>
12407
12408 PR middle-end/87024
12409 * tree-inline.c (copy_bb): Drop unused __builtin_va_arg_pack_len
12410 calls.
12411
12412 2018-08-23 Richard Sandiford <richard.sandiford@arm.com>
12413
12414 * config/aarch64/aarch64.c (aarch64_evpc_sve_tbl): Fix handling
12415 of single-vector TBLs.
12416 (aarch64_vectorize_vec_perm_const): Set one_vector_p when only
12417 one input is given.
12418
12419 2018-08-23 Richard Sandiford <richard.sandiford@arm.com>
12420
12421 PR target/85910
12422 * config/aarch64/aarch64.c (aarch64_expand_vec_perm_const_1): Fix
12423 aarch64_evpc_tbl guard.
12424
12425 2018-08-22 Bernd Edlinger <bernd.edlinger@hotmail.de>
12426
12427 * tree-ssa-dse.c (compute_trims): Avoid folding away undefined
12428 behaviour.
12429
12430 2018-08-22 Martin Sebor <msebor@redhat.com>
12431
12432 PR middle-end/87052
12433 * tree-pretty-print.c (pretty_print_string): Add argument.
12434 (dump_generic_node): Call to pretty_print_string with string size.
12435
12436 2018-08-22 Segher Boessenkool <segher@kernel.crashing.org>
12437
12438 PR rtl-optimization/86771
12439 * combine.c (try_combine): Do not allow splitting a resulting PARALLEL
12440 of two SETs into those two SETs, one to be placed at i2, if that SETs
12441 destination is modified between i2 and i3.
12442
12443 2018-08-22 Richard Sandiford <richard.sandiford@arm.com>
12444
12445 PR tree-optimization/86725
12446 * tree-vect-loop.c (vect_inner_phi_in_double_reduction_p): New
12447 function.
12448 (vect_analyze_scalar_cycles_1): Check it.
12449
12450 2018-08-22 Richard Sandiford <richard.sandiford@arm.com>
12451
12452 PR tree-optimization/86725
12453 * tree-vect-loop.c (vect_is_simple_reduction): When treating
12454 an outer loop phi as a double reduction, make sure that the
12455 single user of the phi result is an inner loop phi.
12456
12457 2018-08-22 Richard Sandiford <richard.sandiford@arm.com>
12458
12459 * tree-vect-data-refs.c (vect_analyze_group_access_1): Convert
12460 grouped stores with gaps to a strided group.
12461
12462 2018-08-22 Richard Sandiford <richard.sandiford@arm.com>
12463
12464 * tree-vect-stmts.c (get_group_load_store_type)
12465 (get_load_store_type): Only test STMT_VINFO_STRIDED_P for the
12466 first statement in a group.
12467
12468 2018-08-22 Iain Sandoe <iain@sandoe.co.uk>
12469
12470 * config/darwin.h (LINK_COMMAND_SPEC_A): Sync LTO options with
12471 the sequence used in gcc/gcc.c.
12472
12473 2018-08-22 Iain Sandoe <iain@sandoe.co.uk>
12474
12475 PR other/704
12476 * gcc-ar.c (main): Don’t try to invoke the plug-in if we’re not
12477 building it.
12478
12479 2018-08-22 Iain Sandoe <iain@sandoe.co.uk>
12480
12481 * config/darwin10.h (LINK_GCC_C_SEQUENCE_SPEC): Adjust to use the
12482 Darwin10-specific unwinder-shim.
12483 * config/darwin12.h (LINK_GCC_C_SEQUENCE_SPEC): Remove.
12484 * config/rs6000/darwin.h (DARWIN_CRT1_SPEC, DARWIN_DYLIB1_SPEC):
12485 New to cater for Darwin10 Rosetta.
12486
12487 2018-08-22 Iain Sandoe <iain@sandoe.co.uk>
12488
12489 * config/i386/i386.c (ix86_output_addr_diff_elt): Move the MACH-O
12490 specific test before the one for HAVE_AS_GOTOFF_IN_DATA.
12491
12492 2018-08-22 Iain Sandoe <iain@sandoe.co.uk>
12493
12494 PR bootstrap/81033
12495 PR target/81733
12496 PR target/52795
12497 * gcc/dwarf2out.c (FUNC_SECOND_SECT_LABEL): New.
12498 (dwarf2out_switch_text_section): Generate a local label for the
12499 second function sub-section and apply it as the second FDE start
12500 label.
12501 * gcc/final.c (final_scan_insn_1): Emit second FDE label after the
12502 second sub-section start.
12503
12504 2018-08-22 Richard Biener <rguenther@suse.de>
12505
12506 PR tree-optimization/86988
12507 * tree-vrp.c (vrp_prop::check_mem_ref): Bail out on VLAs.
12508
12509 2018-08-22 Richard Biener <rguenther@suse.de>
12510
12511 PR tree-optimization/86945
12512 * tree-cfg.c (generate_range_test): Use unsigned arithmetic.
12513
12514 2018-08-22 Alexandre Oliva <oliva@adacore.com>
12515
12516 * config/rs6000/rs6000.c (SMALL_DATA_RELOC, SMALL_DATA_REG): Add
12517 a comment about how uses of r2 for .sdata2 come about.
12518
12519 2018-08-22 Alexandre Oliva <aoliva@redhat.com>
12520
12521 * tree-ssa-reassoc.c (is_reassociable_op): Fix cut&pasto.
12522
12523 2018-08-21 Marek Polacek <polacek@redhat.com>
12524
12525 PR c++/86981, Implement -Wpessimizing-move.
12526 * doc/invoke.texi: Document -Wpessimizing-move.
12527
12528 2018-08-21 Jan Hubicka <jh@suse.cz>
12529
12530 * tree.c (find_decls_types_r): Do not check for redundant typedefs.
12531 * tree.h (is_redundant_typedef): Remove.
12532 * dwarf2out.c (is_redundant_typedef): Turn into static function.
12533
12534 2018-08-21 Jan Hubicka <jh@suse.cz>
12535
12536 * tree.c (free_lang_data_in_decl): Remove types from DECL_CONTEXT
12537 when possible.
12538
12539 2018-08-21 Tamar Christina <tamar.christina@arm.com>
12540
12541 * expmed.c (extract_low_bits): Reject invalid subregs early.
12542
12543 2018-08-21 Bernd Edlinger <bernd.edlinger@hotmail.de>
12544
12545 PR middle-end/86121
12546 * tree-ssa-strlen.c (adjust_last_stmt): Avoid folding away undefined
12547 behaviour.
12548
12549 2018-08-21 Rasmus Villemoes <rv@rasmusvillemoes.dk>
12550
12551 * config/vxworks.h: Guard vxworks_asm_out_constructor and
12552 vxworks_asm_out_destructor by !HAVE_INITFINI_ARRAY_SUPPORT
12553 * config/vxworks.c: Likewise.
12554
12555 2018-08-21 Rasmus Villemoes <rv@rasmusvillemoes.dk>
12556
12557 * config/vxworks.c: Set targetm.have_ctors_dtors
12558 if HAVE_INITFINI_ARRAY_SUPPORT.
12559 * config/vxworks.h: Set SUPPORTS_INIT_PRIORITY
12560 if HAVE_INITFINI_ARRAY_SUPPORT.
12561
12562 2018-08-21 Rasmus Villemoes <rv@rasmusvillemoes.dk>
12563
12564 * config/vxworks.h: Add $(WIND_BASE)/target/h/wrn/coreip to
12565 default search path for VxWorks < 7.
12566
12567 2018-08-21 Bernd Edlinger <bernd.edlinger@hotmail.de>
12568
12569 * gimple-ssa-sprintf.c (decl_constant_value): Remove.
12570 (get_format_string): Refer to c_getstr.
12571
12572 2018-08-21 Tom de Vries <tdevries@suse.de>
12573
12574 * cgraph.h (debuginfo_early_init, debuginfo_init, debuginfo_fini)
12575 (debuginfo_start, debuginfo_stop, debuginfo_early_start)
12576 (debuginfo_early_stop): Declare.
12577 * cgraphunit.c (debuginfo_early_init, debuginfo_init, debuginfo_fini)
12578 (debuginfo_start, debuginfo_stop, debuginfo_early_start)
12579 (debuginfo_early_stop): New function.
12580 (symbol_table::finalize_compilation_unit): Call debuginfo_early_start
12581 and debuginfo_early_stop.
12582 * dwarf2out.c (dwarf2out_finish, dwarf2out_early_finish): Dump dwarf.
12583 * toplev.c (compile_file): Call debuginfo_start and debuginfo_stop.
12584 (general_init): Call debuginfo_early_init.
12585 (finalize): Call debuginfo_fini.
12586 (do_compile): Call debuginfo_init.
12587 * doc/invoke.texi (@gccoptlist): Add -fdump-debug and
12588 -fdump-early-debug.
12589 (@item -fdump-debug, @item -fdump-earlydebug): Add.
12590
12591 2018-08-21 Tom de Vries <tdevries@suse.de>
12592
12593 * dwarf2out.c (print_dw_val, print_loc_descr, print_die): Handle
12594 flag_dump_noaddr and flag_dump_unnumbered.
12595
12596 2018-08-21 Aldy Hernandez <aldyh@redhat.com>
12597
12598 * wide-int-range.cc (wide_int_range_abs): New.
12599 (wide_int_range_order_set): Rename from wide_int_range_min_max.
12600 * wide-int-range.h (wide_int_range_abs): New.
12601 (wide_int_range_min_max): New.
12602 * tree-vrp.c (extract_range_from_unary_expr): Rewrite ABS_EXPR
12603 case to call wide_int_range_abs.
12604 Rewrite MIN/MAX_EXPR to call wide_int_range_min_max.
12605 (extract_range_from_abs_expr): Delete.
12606
12607 2018-08-20 Michael Meissner <meissner@linux.ibm.com>
12608
12609 PR target/87033
12610 * config/rs6000/rs6000.md (extendsi<mode>2): Change constraints
12611 from 'Y' to 'YZ' to enable the LWAX instruction to be generated
12612 for indexed loads.
12613
12614 2018-08-20 Nathan Sidwell <nathan@acm.org>
12615 Jeff Law <law@redhat.com>
12616
12617 * config/s390/s390-c (s390_macro_to_expand): Use cpp_macro_p.
12618 * config/spu/spu-c.c (spu_macro_to_expand): Likewise.
12619
12620 2018-08-20 David Malcolm <dmalcolm@redhat.com>
12621
12622 PR other/84889
12623 * attribs.c (diag_attr_exclusions): Add auto_diagnostic_group instance.
12624 (decl_attributes): Likewise.
12625 * calls.c (maybe_warn_nonstring_arg): Add auto_diagnostic_group
12626 instance.
12627 * cgraphunit.c (maybe_diag_incompatible_alias): Likewise.
12628 * diagnostic-core.h (class auto_diagnostic_group): New class.
12629 * diagnostic.c (diagnostic_initialize): Initialize the new fields.
12630 (diagnostic_report_diagnostic): Handle the first diagnostics within
12631 a group.
12632 (emit_diagnostic): Add auto_diagnostic_group instance.
12633 (inform): Likewise.
12634 (inform_n): Likewise.
12635 (warning): Likewise.
12636 (warning_at): Likewise.
12637 (warning_n): Likewise.
12638 (pedwarn): Likewise.
12639 (permerror): Likewise.
12640 (error): Likewise.
12641 (error_n): Likewise.
12642 (error_at): Likewise.
12643 (sorry): Likewise.
12644 (fatal_error): Likewise.
12645 (internal_error): Likewise.
12646 (internal_error_no_backtrace): Likewise.
12647 (auto_diagnostic_group::auto_diagnostic_group): New ctor.
12648 (auto_diagnostic_group::~auto_diagnostic_group): New dtor.
12649 * diagnostic.h (struct diagnostic_context): Add fields
12650 "diagnostic_group_nesting_depth",
12651 "diagnostic_group_emission_count", "begin_group_cb",
12652 "end_group_cb".
12653 * gimple-ssa-isolate-paths.c (find_implicit_erroneous_behavior):
12654 Add auto_diagnostic_group instance(s).
12655 (find_explicit_erroneous_behavior): Likewise.
12656 * gimple-ssa-warn-alloca.c (pass_walloca::execute): Likewise.
12657 * gimple-ssa-warn-restrict.c (maybe_diag_offset_bounds): Likewise.
12658 * gimplify.c (warn_implicit_fallthrough_r): Likewise.
12659 (gimplify_va_arg_expr): Likewise.
12660 * hsa-gen.c (HSA_SORRY_ATV): Likewise.
12661 (HSA_SORRY_AT): Likewise.
12662 * ipa-devirt.c (compare_virtual_tables): Likewise.
12663 (warn_odr): Likewise.
12664 * multiple_target.c (expand_target_clones): Likewise.
12665 * opts-common.c (cmdline_handle_error): Likewise.
12666 * reginfo.c (globalize_reg): Likewise.
12667 * substring-locations.c (format_warning_n_va): Likewise.
12668 * tree-inline.c (expand_call_inline): Likewise.
12669 * tree-ssa-ccp.c (pass_post_ipa_warn::execute): Likewise.
12670 * tree-ssa-loop-niter.c
12671 (do_warn_aggressive_loop_optimizations): Likewise.
12672 * tree-ssa-uninit.c (warn_uninit): Likewise.
12673 * tree.c (warn_deprecated_use): Likewise.
12674
12675 2018-08-20 H.J. Lu <hongjiu.lu@intel.com>
12676
12677 PR target/87014
12678 * config/i386/i386.md (eh_return): Always update EH return
12679 address in word_mode.
12680
12681 2018-08-20 Chung-Lin Tang <cltang@codesourcery.com>
12682
12683 * targhooks.c (std_gimplify_va_arg_expr): Properly handle case of when
12684 TARGET_SPLIT_COMPLEX_ARG is defined.
12685
12686 2018-08-20 Bernd Edlinger <bernd.edlinger@hotmail.de>
12687
12688 * expr.c (store_field): Change gcc_assert to gcc_checking_assert.
12689
12690 2018-08-20 Bernd Edlinger <bernd.edlinger@hotmail.de>
12691
12692 PR target/86984
12693 * expr.c (expand_assignment): Assert that bitpos is positive.
12694 (store_field): Likewise
12695 (expand_expr_real_1): Make sure that bitpos is positive.
12696 * config/alpha/alpha.h (CONSTANT_ADDRESS_P): Avoid signed
12697 integer overflow.
12698
12699 2018-08-20 Nathan Sidwell <nathan@acm.org>
12700
12701 * Makefile.in (CPP_ID_DATA_H): Delete.
12702 (CPP_INTERNAL_H): Don't add it.
12703 (GTFILES): Replace CPP_ID_DATA_H with CPPLIB_H.
12704 * gengtype.c (open_base_files): Replace cpp-id-data.h with cpplib.h
12705
12706 2018-08-20 Richard Biener <rguenther@suse.de>
12707
12708 PR tree-optimization/78655
12709 * tree-vrp.c (extract_range_from_binary_expr_1): Make
12710 pointer + offset nonnull if either operand is nonnull work.
12711
12712 2018-08-20 Tom de Vries <tdevries@suse.de>
12713
12714 * dwarf2out.c (add_scalar_info): Don't add reference to existing die
12715 unless the referenced die describes the added property using
12716 DW_AT_location or DW_AT_const_value. Fall back to exprloc case.
12717 Otherwise, add a DW_AT_location to the referenced die.
12718
12719 2018-08-19 Uros Bizjak <ubizjak@gmail.com>
12720
12721 PR target/86994
12722 * config/i386/i386.c (ix86_rtx_costs) [case SET]: Check source for
12723 register_operand when calling ix86_set_reg_reg_cost.
12724 [case CONST_INT, case CONST, case LABEL_REF, case SYMBOL_REF]:
12725 Set *total to 0 for operands that satisfy x86_64_immediate_operand
12726 predicate and to 1 otherwise.
12727
12728 2018-08-18 Iain Sandoe <iain@sandoe.co.uk>
12729
12730 * config/darwin.c (darwin_override_options): If -gsplit-dwarf is set,
12731 emit a diagnostic that it is not supported and reset the option.
12732 * config/darwin.h (DRIVER_SELF_SPECS): Note that gsplit-dwarf is not
12733 supported and consume the option. (ASM_FINAL_SPEC): New.
12734
12735 2018-08-17 Segher Boessenkool <segher@kernel.crashing.org>
12736
12737 * doc/md.texi (Patterns): Use @ref instead of @xref in the middle of
12738 a sentence.
12739
12740 2018-08-17 Sandra Loosemore <sandra@codesourcery.com>
12741
12742 C-SKY port: Documentation
12743
12744 * doc/extend.texi (C-SKY Function Attributes): New section.
12745 * doc/invoke.texi (Option Summary): Add C-SKY options.
12746 (C-SKY Options): New section.
12747 * doc/md.texi (Machine Constraints): Document C-SKY constraints.
12748
12749 2018-08-17 Jojo <jijie_rong@c-sky.com>
12750 Huibin Wang <huibin_wang@c-sky.com>
12751 Sandra Loosemore <sandra@codesourcery.com>
12752 Chung-Lin Tang <cltang@codesourcery.com>
12753
12754 C-SKY port: Backend implementation
12755
12756 * config/csky/*: New.
12757 * common/config/csky/*: New.
12758
12759 2018-08-17 Jojo <jijie_rong@c-sky.com>
12760 Huibin Wang <huibin_wang@c-sky.com>
12761 Sandra Loosemore <sandra@codesourcery.com>
12762 Chung-Lin Tang <cltang@codesourcery.com>
12763 Andrew Jenner <andrew@codesourcery.com>
12764
12765 C-SKY port: Configury
12766
12767 * config.gcc (csky-*-*): New.
12768 * configure.ac: Add csky to targets for dwarf2 debug_line support.
12769 * configure: Regenerated.
12770
12771 2018-08-17 David Malcolm <dmalcolm@redhat.com>
12772
12773 * dump-context.h: Include "dumpfile.h".
12774 (dump_context::dump_printf_va): Convert final param from va_list
12775 to va_list *. Convert from ATTRIBUTE_PRINTF to
12776 ATTRIBUTE_GCC_DUMP_PRINTF.
12777 (dump_context::dump_printf_loc_va): Likewise.
12778 * dumpfile.c: Include "stringpool.h".
12779 (make_item_for_dump_printf_va): Delete.
12780 (make_item_for_dump_printf): Delete.
12781 (class dump_pretty_printer): New class.
12782 (dump_pretty_printer::dump_pretty_printer): New ctor.
12783 (dump_pretty_printer::emit_items): New member function.
12784 (dump_pretty_printer::emit_any_pending_textual_chunks): New member
12785 function.
12786 (dump_pretty_printer::emit_item): New member function.
12787 (dump_pretty_printer::stash_item): New member function.
12788 (dump_pretty_printer::format_decoder_cb): New member function.
12789 (dump_pretty_printer::decode_format): New member function.
12790 (dump_context::dump_printf_va): Reimplement in terms of
12791 dump_pretty_printer.
12792 (dump_context::dump_printf_loc_va): Convert final param from va_list
12793 to va_list *.
12794 (dump_context::begin_scope): Reimplement call to
12795 make_item_for_dump_printf.
12796 (dump_printf): Update for change to dump_printf_va.
12797 (dump_printf_loc): Likewise.
12798 (selftest::test_capture_of_dump_calls): Convert "stmt" from
12799 greturn * to gimple *. Add a test_decl. Add tests of dump_printf
12800 with %T, %E, and %G.
12801 * dumpfile.h (ATTRIBUTE_GCC_DUMP_PRINTF): New macro.
12802 (dump_printf): Replace ATTRIBUTE_PRINTF_2 with
12803 ATTRIBUTE_GCC_DUMP_PRINTF (2, 3).
12804 (dump_printf_loc): Replace ATTRIBUTE_PRINTF_3 with
12805 ATTRIBUTE_GCC_DUMP_PRINTF (3, 0).
12806 * tree-vect-data-refs.c (vect_lanes_optab_supported_p): Convert
12807 use of HOST_WIDE_INT_PRINT_DEC on unsigned HOST_WIDE_INT "count"
12808 within a dump_printf_loc call to "%wu".
12809 (vector_alignment_reachable_p): Merge two dump_printf[_loc] calls,
12810 converting a use of HOST_WIDE_INT_PRINT_DEC to "%wd". Add a
12811 missing space after "=".
12812 * tree-vect-loop.c (vect_analyze_loop_2) Within a dump_printf
12813 call, convert use of HOST_WIDE_INT_PRINT_DEC to "%wd".
12814 * tree-vect-slp.c (vect_slp_bb): Within a dump_printf_loc call,
12815 convert use of HOST_WIDE_INT_PRINT_UNSIGNED to "%wu".
12816 * tree-vectorizer.c (try_vectorize_loop_1): Likewise. Remove
12817 duplicate "vectorized" from message.
12818
12819 2018-08-17 Szabolcs Nagy <szabolcs.nagy@arm.com>
12820
12821 * config/arm/arm-builtins.c (arm_init_simd_builtin_types): Clear
12822 polyNxK_t element's TYPE_STRING_FLAG.
12823
12824 2018-08-17 Segher Boessenkool <segher@kernel.crashing.org>
12825
12826 * config/rs6000/rs6000.md (*cbranch, *creturn): Name these patterns
12827 (they were unnamed before). Fix comments.
12828
12829 2018-08-17 Nathan Sidwell <nathan@acm.org>
12830
12831 * cppbuiltin.c: Include "cpplib.h", not "cpp-id-data.h".
12832
12833 2018-08-17 Richard Biener <rguenther@suse.de>
12834
12835 PR tree-optimization/86841
12836 * wide-int-range.cc (wide_int_range_lshift): Use to_uhwi.
12837
12838 2018-08-17 Martin Liska <mliska@suse.cz>
12839
12840 * common.opt: Remove Warn, Init and Report for options with
12841 Ignore/Deprecated flag. Warning is done automatically for
12842 Deprecated flags.
12843 * config/i386/i386.opt: Likewise.
12844 * config/ia64/ia64.opt: Likewise.
12845 * config/rs6000/rs6000.opt: Likewise.
12846 * cppbuiltin.c (define_builtin_macros_for_compilation_flags):
12847 Remove usage of flag_check_pointer_bounds.
12848 * lto-wrapper.c (merge_and_complain): Do not handle
12849 OPT_fcheck_pointer_bounds.
12850 (append_compiler_options): Likewise.
12851 * opt-functions.awk: Do not handle Deprecated.
12852 * optc-gen.awk: Check that Var, Report and Init are not
12853 used for an option with Ignore/Deprecated flag.
12854 * opts-common.c (decode_cmdline_option): Do not report
12855 CL_ERR_DEPRECATED.
12856 (read_cmdline_option): Report warning for OPT_SPECIAL_deprecated
12857 options.
12858 * opts.h (struct cl_option): Remove cl_deprecated flag.
12859 (CL_ERR_DEPRECATED): Remove error enum value.
12860
12861 2018-08-17 Richard Biener <rguenther@suse.de>
12862
12863 PR middle-end/86505
12864 * tree-inline.c (copy_bb): When inlining __builtin_va_arg_pack_len ()
12865 across a va-arg-pack using call adjust its return value accordingly.
12866
12867 2018-08-16 Martin Sebor <msebor@redhat.com>
12868
12869 PR tree-optimization/86853
12870 * gimple-ssa-sprintf.c (struct format_result): Rename member.
12871 (struct fmtresult): Add member and initialize it in ctors.
12872 (format_character): Handle %C. Extend range to NUL. Set MAYFAIL.
12873 (format_string): Handle %S the same as %ls. Set MAYFAIL.
12874 (format_directive): Set POSUNDER4K when MAYFAIL is set.
12875 (parse_directive): Handle %C same as %c.
12876 (sprintf_dom_walker::compute_format_length): Adjust.
12877 (is_call_safe): Adjust.
12878
12879 2018-08-16 Bernd Edlinger <bernd.edlinger@hotmail.de>
12880
12881 * builtins.c (c_strlen): Add new parameter eltsize. Use it
12882 for determining how to count the elements.
12883 * builtins.h (c_strlen): Adjust prototype.
12884 * expr.c (string_constant): Add new parameter mem_size.
12885 Set *mem_size appropriately.
12886 * expr.h (string_constant): Adjust protoype.
12887 * gimple-fold.c (get_range_strlen): Add new parameter eltsize.
12888 * gimple-fold.h (get_range_strlen): Adjust prototype.
12889 * gimple-ssa-sprintf.c (get_string_length): Add new parameter eltsize.
12890 (format_string): Call get_string_length with eltsize.
12891
12892 2018-08-16 David Malcolm <dmalcolm@redhat.com>
12893
12894 * diagnostic.c (default_diagnostic_start_span_fn): Call pp_string
12895 to emit the span, rather than setting it as the prefix.
12896
12897 2018-08-16 David Malcolm <dmalcolm@redhat.com>
12898
12899 * diagnostic-show-locus.c (layout::start_annotation_line): Add
12900 "margin_char" parameter, defaulting to space. Use it in place
12901 of pp_space for the initial part of the margin.
12902 (layout::print_leading_fixits): Use '+' when filling the margin
12903 of line-insertion fix-it hints.
12904
12905 2018-08-16 Segher Boessenkool <segher@kernel.crashing.org>
12906
12907 * config/rs6000/rs6000.md (two unnamed define_insn and define_split):
12908 Delete.
12909
12910 2018-08-16 Segher Boessenkool <segher@kernel.crashing.org>
12911
12912 * config/rs6000/altivec.md: Don't set length attribute to the default
12913 value.
12914 * config/rs6000/darwin.md: Ditto.
12915 * config/rs6000/dfp.md: Ditto.
12916 * config/rs6000/htm.md: Ditto.
12917 * config/rs6000/rs6000.md: Ditto.
12918 * config/rs6000/sync.md: Ditto.
12919 * config/rs6000/vsx.md: Ditto.
12920
12921 2018-08-16 Segher Boessenkool <segher@kernel.crashing.org>
12922
12923 * config/rs6000/altivec.md: Don't set length attribute to the default
12924 value, for branch instructions.
12925 * config/rs6000/darwin.md: Ditto.
12926 * config/rs6000/rs6000.md: Ditto.
12927
12928 2018-08-16 Segher Boessenkool <segher@kernel.crashing.org>
12929
12930 * config/rs6000/rs6000.md (length): Always define as const_int 4.
12931 (unnamed conditional branch define_insn): Set length to 4 or 8
12932 depending on offset.
12933 (<bd>_<mode>): Similar, for alternative 0.
12934 (<bd>tf_<mode>): Ditto.
12935
12936 2018-08-16 Tamar Christina <tamar.christina@arm.com>
12937
12938 * expr.c (copy_blkmode_to_reg): Perform larger copies when safe.
12939
12940 2018-08-16 Matthew Malcomson <matthew.malcomson@arm.com>
12941
12942 * doc/rtl.texi: Replace old RTX class names with new names.
12943
12944
12945 2018-08-16 Vlad Lazar <vlad.lazar@arm.com>
12946
12947 * expmed.h (canonicalize_comparison): New declaration.
12948 * expmed.c (canonicalize_comparison, equivalent_cmp_code): New function.
12949 * expmed.c (emit_store_flag_1): Add call to canonicalize_comparison.
12950 * optabs.c (prepare_cmp_insn): Likewise.
12951 * rtl.h (unsigned_condition_p): New function which checks if a
12952 comparison operator is unsigned.
12953
12954 2018-08-16 Nathan Sidwell <nathan@acm.org>
12955
12956 * config/rs6000/rs6000-c.c (rs6000_macro_to_expend): Use cpp_macro_p.
12957 * config/powerpcspc/powerpcspe-c.c (rs6000_macro_to_expend): Likewise.
12958
12959 2018-08-16 Tamar Christina <tamar.christina@arm.com>
12960
12961 PR target/84711
12962 * config/arm/arm.c (arm_can_change_mode_class): Disallow subreg.
12963 * config/arm/neon.md (movv4hf, movv8hf): Refactored to..
12964 (mov<mov>): ..this and enable unconditionally.
12965
12966 2018-08-16 Tamar Christina <tamar.christina@arm.com>
12967
12968 * config/arm/neon.md (*neon_mov<mode>): Remove reg-to-reg alternative.
12969
12970 2018-08-16 Sam Tebbs <sam.tebbs@arm.com>
12971
12972 * config/aarch64/aarch64.opt (mlow-precision-recip-sqrt)
12973 (mlow-precision-sqrt, mlow-precision-div, mverbose-cost-dump): Replace
12974 "Common" with "Target".
12975
12976 2018-08-15 Uros Bizjak <ubizjak@gmail.com>
12977
12978 * config/i386/i386.opt (mmitigate-rop): Mark as deprecated.
12979 * doc/invoke.texi (mmitigate-rop): Remove.
12980 * config/i386/i386.c: Do not include "regrename.h".
12981 (ix86_rop_should_change_byte_p, reg_encoded_number)
12982 (ix86_get_modrm_for_rop, set_rop_modrm_reg_bits, ix86_mitigate_rop):
12983 Remove.
12984 (ix86_reorg): Remove call to ix86_mitigate_rop.
12985 * config/i386/i386.md (attr "modrm_class"): Remove.
12986 (cmp<mode>_ccno_1, mov<mode>_xor, movstrict<mode>_xor)
12987 (x86_mov<mode>cc_0_m1. x86_mov<mode>cc_0_m1_se)
12988 (x86_mov<mode>cc_0_m1_neg): Remove modrm_class attribute override.
12989
12990 2018-08-15 Will Schmidt <will_schmidt@vnet.ibm.com>
12991
12992 * config/rs6000/rs600.c (rs6000_gimple_fold_builtin): Add entries to
12993 allow folding of mergeh() and mergel() for the float and double types.
12994 (fold_mergehl_helper): Rework to handle building a permute tree
12995 for float vectors.
12996
12997 2018-08-15 Uros Bizjak <ubizjak@gmail.com>
12998
12999 * config/i386/i386.c (expand_vec_perm_movs): Enable V4SFmode
13000 for TARGET_SSE.
13001
13002 2018-08-15 David Malcolm <dmalcolm@redhat.com>
13003
13004 * common.opt (fdiagnostics-show-labels): New option.
13005 * diagnostic-show-locus.c (class layout_range): Add field
13006 "m_label".
13007 (class layout): Add field "m_show_labels_p".
13008 (layout_range::layout_range): Add param "label" and use it to
13009 initialize m_label.
13010 (make_range): Pass in NULL for new "label" param of layout_range's
13011 ctor.
13012 (layout::layout): Initialize m_show_labels_p.
13013 (layout::maybe_add_location_range): Pass in loc_range->m_label
13014 when constructing layout_range instances.
13015 (struct line_label): New struct.
13016 (layout::print_any_labels): New member function.
13017 (layout::print_line): Call it if label-printing is enabled.
13018 (selftest::test_one_liner_labels): New test.
13019 (selftest::test_diagnostic_show_locus_one_liner): Call it.
13020 * diagnostic.c (diagnostic_initialize): Initialize
13021 context->show_labels_p.
13022 * diagnostic.h (struct diagnostic_context): Add field
13023 "show_labels_p".
13024 * doc/invoke.texi (Diagnostic Message Formatting Options): Add
13025 -fno-diagnostics-show-labels.
13026 * dwarf2out.c (gen_producer_string): Add
13027 OPT_fdiagnostics_show_labels to the ignored options.
13028 * gcc-rich-location.c (gcc_rich_location::add_expr): Add "label"
13029 param.
13030 (gcc_rich_location::maybe_add_expr): Likewise.
13031 * gcc-rich-location.h (gcc_rich_location::gcc_rich_location): Add
13032 label" param, defaulting to NULL.
13033 (gcc_rich_location::add_expr): Add "label" param.
13034 (gcc_rich_location::maybe_add_expr): Likewise.
13035 (class text_range_label): New class.
13036 (class range_label_for_type_mismatch): New class.
13037 * gimple-ssa-sprintf.c (fmtwarn): Pass NULL for new label params
13038 of format_warning_va.
13039 (fmtwarn_n): Likewise for new params of format_warning_n_va.
13040 * lto-wrapper.c (merge_and_complain): Add
13041 OPT_fdiagnostics_show_labels to the "pick one setting" options.
13042 (append_compiler_options): Likewise to the dropped options.
13043 (append_diag_options): Likewise to the passed-on options.
13044 * opts.c (common_handle_option): Handle the new option.
13045 * selftest-diagnostic.c
13046 (test_diagnostic_context::test_diagnostic_context): Enable
13047 show_labels_p.
13048 * substring-locations.c: Include "gcc-rich-location.h".
13049 (format_warning_n_va): Add "fmt_label" and "param_label" params
13050 and use them as appropriate.
13051 (format_warning_va): Add "fmt_label" and "param_label" params,
13052 passing them on to format_warning_n_va.
13053 (format_warning_at_substring): Likewise.
13054 (format_warning_at_substring_n): Likewise.
13055 * substring-locations.h (format_warning_va): Add "fmt_label" and
13056 "param_label" params.
13057 (format_warning_n_va): Likewise.
13058 (format_warning_at_substring): Likewise.
13059 (format_warning_at_substring_n): Likewise.
13060 * toplev.c (general_init): Initialize global_dc->show_labels_p.
13061
13062 2018-08-15 Qing Zhao <qing.zhao@oracle.com>
13063
13064 PR testsuite/86519
13065 * builtins.c (expand_builtin_memcmp): Do not expand the call
13066 when overflow is detected.
13067
13068 2018-08-15 Martin Sebor <msebor@redhat.com>
13069
13070 PR tree-optimization/71625
13071 * config/aarch64/aarch64-builtins.c
13072 (aarch64_init_simd_builtin_types): Clear Poly8_t's TYPE_STRING_FLAG.
13073
13074 2018-08-15 Ilya Leoshkevich <iii@linux.ibm.com>
13075
13076 * config/s390/s390.c (s390_reorg): Remove loop.
13077
13078 2018-08-15 Iain Sandoe <iain@sandoe.co.uk>
13079
13080 * config/darwin.c
13081 (darwin_function_switched_text_sections): Delete.
13082 * gcc/config/darwin.h
13083 (TARGET_ASM_FUNCTION_SWITCHED_TEXT_SECTIONS): Likewise.
13084
13085 2018-08-15 Iain Sandoe <iain@sandoe.co.uk>
13086
13087 PR target/81685
13088 * config/darwin.h: (DEBUG_STR_OFFSETS_SECTION, DEBUG_LOCLISTS_SECTION,
13089 DEBUG_RNGLISTS_SECTION) new macros. (DEBUG_PUBNAMES_SECTION,
13090 DEBUG_PUBTYPES_SECTION) update to include GNU variant.
13091
13092 2018-08-15 Martin Liska <mliska@suse.cz>
13093
13094 PR tree-optimization/86925
13095 * predict.c (expr_expected_value_1): When taking
13096 later predictor, assign also probability.
13097 Use fold_build2_initializer_loc in order to fold
13098 the expression in -frounding-math.
13099
13100 2018-08-14 Allan Sandfeld Jensen <allan.jensen@qt.io>
13101
13102 * config/i386/i386.c (expand_vec_perm_movs): New method matching movs
13103 patterns.
13104 (expand_vec_perm_1): Try the new method.
13105
13106 2018-08-14 Ilya Leoshkevich <iii@linux.ibm.com>
13107
13108 PR target/86547
13109 * lra-lives.c (remove_some_program_points_and_update_live_ranges):
13110 Check whether lra_live_max_point is 0 before dividing.
13111
13112 2018-08-14 Martin Sebor <msebor@redhat.com>
13113
13114 PR tree-optimization/86650
13115 * tree-vrp.c (vrp_prop::check_array_ref): Print an inform message.
13116 (vrp_prop::check_mem_ref): Same.
13117
13118 2018-08-13 Liu Hao <lh_mouse@126.com>
13119
13120 * pretty-print.c (eat_esc_sequence): Swap the foreground and
13121 background colors if the COMMON_LVB_REVERSE_VIDEO flag is set,
13122 and clear it thereafter, as it only works for DBCS.
13123
13124 2018-08-13 Liu Hao <lh_mouse@126.com>
13125
13126 * pretty-print.c (mingw_ansi_fputs): Do not call _close() on the
13127 handle returned by _get_osf_handle().
13128
13129 2018-08-13 Will Schmidt <will_schmidt@vnet.ibm.com>
13130
13131 * gcc/config/rs6000/rs6000.c (rs6000_gimple_fold_builtin): Add support
13132 for folding vec_perm.
13133
13134 2018-08-13 Will Schmidt <will_schmidt@vnet.ibm.com>
13135
13136 * config/rs6000/rs6000.c (rs6000_gimple_fold_builtin):
13137 Add support for gimple-folding of vec_pack() and vec_unpack()
13138 intrinsics.
13139
13140 2018-08-13 Will Schmidt <will_schmidt@vnet.ibm.com>
13141
13142 * config/rs6000/rs6000.c (rs6000_builtin_valid_without_lhs): Add
13143 vec_xst variants to the list.
13144 (rs6000_gimple_fold_builtin): Add support for folding unaligned
13145 vector loads and stores.
13146
13147 2018-08-13 David Edelsohn <dje.gcc@gmail.com>
13148
13149 * config.gcc (rs6000-ibm-aix4.x): Delete.
13150 (rs6000-ibm-aix5.1): Delete.
13151 (rs6000-ibm-aix5.2): Delete.
13152 (rs6000-ibm-aix5.3): Delete.
13153 * config/rs6000/aix43.h: Delete.
13154 * config/rs6000/aix51.h: Delete.
13155 * config/rs6000/aix52.h: Delete.
13156 * config/rs6000/t-aix43: Delete.
13157
13158 2018-08-13 Ilya Leoshkevich <iii@linux.ibm.com>
13159
13160 * config/s390/s390.c (s390_decompose_constant_pool_ref):
13161 New function.
13162 (s390_decompose_address): Factor out constant pool ref
13163 decomposition.
13164
13165 2018-08-12 Chung-Ju Wu <jasonwucj@gmail.com>
13166
13167 * config/nds32/nds32-predicates.c
13168 (nds32_can_use_bclr_p): Change return type as bool.
13169 (nds32_can_use_bset_p): Ditto.
13170 (nds32_can_use_btgl_p): Ditto.
13171 (nds32_can_use_bitci_p): Ditto.
13172 * config/nds32/nds32-protos.h
13173 (nds32_can_use_bclr_p): Change declaration.
13174 (nds32_can_use_bset_p): Ditto.
13175 (nds32_can_use_btgl_p): Ditto.
13176 (nds32_can_use_bitci_p): Ditto.
13177
13178 2018-08-12 Chung-Ju Wu <jasonwucj@gmail.com>
13179
13180 * config/nds32/nds32.c (nds32_expand_prologue, nds32_expand_epilogue):
13181 Support -msched-prolog-epilog option.
13182 * config/nds32/nds32.opt (msched-prolog-epilog): New option.
13183
13184 2018-08-12 Chung-Ju Wu <jasonwucj@gmail.com>
13185
13186 * common/config/nds32/nds32-common.c
13187 (nds32_option_optimization_table): Enalbe -malways-align.
13188
13189 2018-08-12 Chung-Ju Wu <jasonwucj@gmail.com>
13190
13191 * config.gcc (nds32*): Add nds32_isr.h and nds32_init.inc in
13192 extra_headers.
13193 * common/config/nds32/nds32-common.c (nds32_handle_option): Handle
13194 OPT_misr_secure_ case.
13195 * config/nds32/nds32-isr.c: Implementation of backward compatibility.
13196 * config/nds32/nds32-protos.h (nds32_isr_function_critical_p): New.
13197 * config/nds32/nds32.c (nds32_attribute_table): Add critical and
13198 secure attribute.
13199 * config/nds32/nds32.h (nds32_isr_nested_type): Add NDS32_CRITICAL.
13200 (nds32_isr_info): New field security_level.
13201 (TARGET_ISR_VECTOR_SIZE_4_BYTE): New macro.
13202 * config/nds32/nds32.md (return_internal): Consider critical attribute.
13203 * config/nds32/nds32.opt (misr-secure): New option.
13204 * config/nds32/nds32_init.inc: New file.
13205 * config/nds32/nds32_isr.h: New file.
13206
13207 2018-08-11 John David Anglin <danglin@gcc.gnu.org>
13208
13209 * config/pa/pa.md (UNSPEC_MEMORY_BARRIER): New unspec enum.
13210 Update comment for atomic instructions.
13211 (atomic_storeqi, atomic_storehi, atomic_storesi, atomic_storesf,
13212 atomic_loaddf, atomic_loaddf_1, atomic_storedf, atomic_storedf_1):
13213 Remove.
13214 (atomic_loaddi): Revise fence expansion to only emit fence prior to
13215 load for __ATOMIC_SEQ_CST model.
13216 (atomic_loaddi_1): Remove float register target.
13217 (atomic_storedi): Handle CONST_INT values.
13218 (atomic_storedi_1): Remove float register source. Add special case
13219 for zero value.
13220 (memory_barrier): New expander and insn.
13221
13222 2018-08-11 Jakub Jelinek <jakub@redhat.com>
13223
13224 PR tree-optimization/86835
13225 * tree-ssa-math-opts.c (insert_reciprocals): Even when inserting
13226 new_stmt after def_gsi, make sure to insert new_square_stmt after
13227 that stmt, not 2 stmts before it.
13228
13229 2018-08-10 Alexander Monakov <amonakov@ispras.ru>
13230
13231 PR target/82418
13232 * config/i386/i386.md (<s>mul<mode>3_highpart): Use DWIH mode iterator
13233 instead of SWI48.
13234
13235 2018-08-10 Martin Liska <mliska@suse.cz>
13236
13237 PR target/83610
13238 * builtin-types.def (BT_FN_LONG_LONG_LONG_DOUBLE): Add new
13239 function type.
13240 * builtins.c (expand_builtin_expect_with_probability):
13241 New function.
13242 (expand_builtin_expect_with_probability): New function.
13243 (build_builtin_expect_predicate): Add new argumnet probability
13244 for BUILT_IN_EXPECT_WITH_PROBABILITY.
13245 (fold_builtin_expect):
13246 (fold_builtin_2):
13247 (fold_builtin_3):
13248 * builtins.def (BUILT_IN_EXPECT_WITH_PROBABILITY):
13249 * builtins.h (fold_builtin_expect): Set new argument.
13250 * doc/extend.texi: Document __builtin_expect_with_probability.
13251 * doc/invoke.texi: Likewise.
13252 * gimple-fold.c (gimple_fold_call): Pass new argument.
13253 * ipa-fnsummary.c (find_foldable_builtin_expect): Handle
13254 also BUILT_IN_EXPECT_WITH_PROBABILITY.
13255 * predict.c (get_predictor_value): New function.
13256 (expr_expected_value): Add new argument probability. Assume
13257 that predictor and probability are always non-null.
13258 (expr_expected_value_1): Likewise. For __builtin_expect and
13259 __builtin_expect_with_probability set probability. Handle
13260 combination in binary expressions.
13261 (tree_predict_by_opcode): Simplify code by simply calling
13262 get_predictor_value.
13263 (pass_strip_predict_hints::execute): Add handling of
13264 BUILT_IN_EXPECT_WITH_PROBABILITY.
13265 * predict.def (PRED_BUILTIN_EXPECT_WITH_PROBABILITY): Add
13266 new predictor.
13267 * tree.h (DECL_BUILT_IN_P): New function.
13268
13269 2018-08-10 Martin Liska <mliska@suse.cz>
13270
13271 PR tree-optimization/85799
13272 * passes.def: Add argument for pass_strip_predict_hints.
13273 * predict.c (class pass_strip_predict_hints): Add new argument
13274 early_p.
13275 (strip_predictor_early): New function.
13276 (pass_strip_predict_hints::execute): Call the function to
13277 strip predictors.
13278 (strip_predict_hints): New function.
13279 * predict.def: Fix comment.
13280
13281 2018-08-10 Thomas Preud'homme <thomas.preudhomme@linaro.org>
13282
13283 * Makefile.in: Clarify which tm.texi to copy over to assert the
13284 right to grant a GFDL license for all.
13285
13286 2018-08-09 Jeff Law <law@redhat.com>
13287
13288 * config/m68k/m68k.c (m68k_adjust_decorated_operand): Remove
13289 unused variable.
13290
13291 2018-08-09 Andreas Schwab <schwab@linux-m68k.org>
13292
13293 * config/m68k/m68k-protos.h (m68k_final_prescan_insn): Remove
13294 prototype.
13295
13296 2018-08-09 Richard Sandiford <richard.sandiford@arm.com>
13297
13298 * tree-vect-loop.c (vectorizable_reduction): Allow inner-loop
13299 reductions for variable-length vectors.
13300
13301 2018-08-09 David Malcolm <dmalcolm@redhat.com>
13302
13303 PR other/84889
13304 * common.opt (fdiagnostics-show-line-numbers): New option.
13305 * diagnostic-show-locus.c (class layout): Add fields
13306 "m_show_line_numbers_p" and "m_linenum_width";
13307 (num_digits): New function.
13308 (test_num_digits): New function.
13309 (layout::layout): Initialize new fields. Update m_x_offset
13310 logic to handle any left margin.
13311 (layout::print_source_line): Print line number when requested.
13312 (layout::start_annotation_line): New member function.
13313 (layout::print_annotation_line): Call it.
13314 (layout::print_leading_fixits): Likewise.
13315 (layout::print_trailing_fixits): Likewise. Update calls to
13316 move_to_column for new parameter.
13317 (layout::get_x_bound_for_row): Add "add_left_margin" param and use
13318 it to potentially call start_annotation_line.
13319 (layout::show_ruler): Call start_annotation_line.
13320 (selftest::test_line_numbers_multiline_range): New selftest.
13321 (selftest::diagnostic_show_locus_c_tests): Call test_num_digits
13322 and selftest::test_line_numbers_multiline_range.
13323 * diagnostic.c (diagnostic_initialize): Initialize
13324 show_line_numbers_p.
13325 * diagnostic.h (struct diagnostic_context): Add field
13326 "show_line_numbers_p".
13327 * doc/invoke.texi (Diagnostic Message Formatting Options): Add
13328 -fno-diagnostics-show-line-numbers.
13329 * dwarf2out.c (gen_producer_string): Add
13330 OPT_fdiagnostics_show_line_numbers to the ignored options.
13331 * lto-wrapper.c (merge_and_complain): Likewise to the "pick
13332 one setting" options.
13333 (append_compiler_options): Likewise to the dropped options.
13334 (append_diag_options): Likewise to the passed-on options.
13335 * opts.c (common_handle_option): Handle the new option.
13336 * toplev.c (general_init): Set up global_dc->show_line_numbers_p.
13337
13338 2018-08-09 Kelvin Nilsen <kelvin@gcc.gnu.org>
13339
13340 * doc/extend.texi (PowerPC AltiVec Built-in Functions Available on
13341 ISA 2.07): Correct spelling of bcdsub to be __builtin_bcdsub. Add
13342 third argument of type "const signed char" to descriptions of
13343 __builtin_bcdadd, __builtin_bcdadd_lt, __builtin_bcdadd_eq,
13344 __builtin_bcdadd_gt, __builtin_bcdadd_ov, __builtin_bcdsub,
13345 __builtin_bcdsub_lt, __builtin_bcdsub_eq, __builtin_bcdsub_gt,
13346 __builtin_bcdsub_ov functions.
13347
13348 2018-08-09 Richard Sandiford <richard.sandiford@arm.com>
13349
13350 PR tree-optimization/86858
13351 * tree-vect-loop.c (vect_is_simple_reduction): Restore
13352 flow_bb_inside_loop_p calls.
13353
13354 2018-08-09 Richard Sandiford <richard.sandiford@arm.com>
13355
13356 PR tree-optimization/86871
13357 * tree-vect-stmts.c (vect_transform_stmt): Use gimple_get_lhs
13358 instead of gimple_assign_lhs.
13359
13360 2018-08-09 Richard Earnshaw <rearnsha@arm.com>
13361
13362 PR target/86887
13363 * config/aarch64/aarch64.md (add<mode>3_carryinC_zero): Add missing
13364 register constraint to operand 0.
13365 (add<mode>3_carryinC): Likewise.
13366 (add<mode>3_carryinV_zero, add<mode>3_carryinV): Likewise.
13367
13368 2018-08-09 Martin Liska <mliska@suse.cz>
13369
13370 PR c/86895
13371 * common.opt: Remove extra line.
13372
13373 2018-08-09 Martin Liska <mliska@suse.cz>
13374
13375 * params.def (PARAM_ALIGN_LOOP_ITERATIONS): Remove double dots
13376 at the end of a line, make first letter capital and end up
13377 a sentence with a dot.
13378 (PARAM_LOOP_INTERCHANGE_STRIDE_RATIO): Likewise.
13379 (PARAM_LOOP_BLOCK_TILE_SIZE): Likewise.
13380 (PARAM_GRAPHITE_MAX_NB_SCOP_PARAMS): Likewise.
13381 (PARAM_GRAPHITE_MAX_ARRAYS_PER_SCOP): Likewise.
13382 (PARAM_MAX_ISL_OPERATIONS): Likewise.
13383 (PARAM_GRAPHITE_ALLOW_CODEGEN_ERRORS): Likewise.
13384 (PARAM_PROFILE_FUNC_INTERNAL_ID): Likewise.
13385 (PARAM_INDIR_CALL_TOPN_PROFILE): Likewise.
13386 (PARAM_SLP_MAX_INSNS_IN_BB): Likewise.
13387 (PARAM_IPA_CP_EVAL_THRESHOLD): Likewise.
13388 (PARAM_IPA_CP_RECURSION_PENALTY): Likewise.
13389 (PARAM_IPA_CP_SINGLE_CALL_PENALTY): Likewise.
13390 (PARAM_IPA_CP_LOOP_HINT_BONUS): Likewise.
13391 (PARAM_IPA_CP_ARRAY_INDEX_HINT_BONUS): Likewise.
13392 (PARAM_TREE_REASSOC_WIDTH): Likewise.
13393 (PARAM_HSA_GEN_DEBUG_STORES): Likewise.
13394 (PARAM_MAX_SPECULATIVE_DEVIRT_MAYDEFS): Likewise.
13395 (PARAM_MAX_VRP_SWITCH_ASSERTIONS): Likewise.
13396
13397 2018-08-09 Andreas Krebbel <krebbel@linux.ibm.com>
13398
13399 PR target/84332
13400 * config/s390/s390.c (s390_option_override_internal): Reduce the
13401 stack-clash-protection-probe-interval param if it would be too big
13402 for z900.
13403
13404 2018-08-08 Andreas Schwab <schwab@linux-m68k.org>
13405
13406 PR target/46179
13407 * config/m68k/m68k.h (FINAL_PRESCAN_INSN): Don't define.
13408 * config/m68k/m68k.c (handle_move_double): Don't call
13409 m68k_final_prescan_insn.
13410 (m68k_adjust_decorated_operand): Renamed from
13411 m68k_final_prescan_insn, remove first and third operand and
13412 simplify.
13413 (print_operand): Call it.
13414 (print_operand_address): Call it.
13415
13416 2018-08-08 Nathan Sidwell <nathan@acm.org>
13417
13418 * diagnostic.c (diagnostic_report_current_module): Use
13419 linemap_included_from & linemap_included_from_linemap.
13420
13421 2018-08-08 Hongbo Zhang <hongbo.zhang@linaro.org>
13422
13423 * config/aarch64/aarch64-cores.def: Add phecda core.
13424 * config/aarch64/aarch64-tune.md: Regenerate.
13425 * doc/invoke.texi: Add phecda core.
13426
13427 2018-08-08 Andreas Krebbel <krebbel@linux.ibm.com>
13428
13429 PR target/85295
13430 * config/s390/constraints.md ("NxHD0", "NxSD0"): New constraint
13431 definitions.
13432 * config/s390/s390.md ("movti"): Add more alternatives for
13433 constant to GPR copies.
13434
13435 2018-08-08 Andreas Krebbel <krebbel@linux.ibm.com>
13436
13437 * config/s390/s390.c: Fix whitespace damage throughout the file.
13438 * config/s390/s390.h: Likewise.
13439 * config/s390/tpf.h: Likewise.
13440
13441 2018-08-08 Ilya Leoshkevich <iii@linux.ibm.com>
13442
13443 * config/s390/s390.c (s390_loadrelative_operand_p):
13444 Remove TARGET_CPU_ZARCH usages.
13445 (s390_rtx_costs): Likewise.
13446 (s390_legitimate_constant_p): Likewise.
13447 (s390_cannot_force_const_mem): Likewise.
13448 (legitimate_reload_constant_p): Likewise.
13449 (s390_preferred_reload_class): Likewise.
13450 (legitimize_pic_address): Likewise.
13451 (legitimize_tls_address): Likewise.
13452 (s390_split_branches): Removed.
13453 (s390_add_execute): Removed.
13454 (s390_dump_pool): Remove TARGET_CPU_ZARCH usages.
13455 (s390_mainpool_start): Likewise.
13456 (s390_mainpool_finish): Likewise.
13457 (s390_mainpool_cancel): Removed.
13458 (s390_chunkify_start): Remove TARGET_CPU_ZARCH usages.
13459 (s390_chunkify_cancel): Likewise.
13460 (s390_return_addr_rtx): Likewise.
13461 (s390_register_info): Remove split_branches_pending_p uages.
13462 (s390_optimize_register_info): Likewise.
13463 (s390_init_frame_layout): Remove TARGET_CPU_ZARCH and
13464 split_branches_pending_p usages.
13465 (s390_can_eliminate): Remove TARGET_CPU_ZARCH usages.
13466 (s390_load_got): Likewise.
13467 (s390_expand_split_stack_prologue): Likewise.
13468 (output_asm_nops): Likewise.
13469 (s390_function_profiler): Likewise.
13470 (s390_emit_call): Likewise.
13471 (s390_conditional_register_usage): Likewise.
13472 (s390_optimize_prologue): Likewise.
13473 (s390_reorg): Remove TARGET_CPU_ZARCH and
13474 split_branches_pending_p usages.
13475 (s390_option_override_internal): Remove TARGET_CPU_ZARCH
13476 usages.
13477 (s390_output_indirect_thunk_function): Likewise.
13478 * config/s390/s390.h (TARGET_CPU_ZARCH): Removed.
13479 (TARGET_CPU_ZARCH_P): Removed.
13480 (struct machine_function): Remove split_branches_pending_p.
13481 * config/s390/s390.md: Remove TARGET_CPU_ZARCH usages.
13482
13483 2018-08-08 Ilya Leoshkevich <iii@linux.ibm.com>
13484
13485 * common/config/s390/s390-common.c (processor_flags_table):
13486 Remove flags.
13487 * config.gcc: Remove with_arch/with_tune support.
13488 * config/s390/2064.md: Remove cpu attribute comparisons.
13489 * config/s390/driver-native.c (s390_host_detect_local_cpu):
13490 Remove MTN.
13491 * config/s390/linux.h (ASM_SPEC):
13492 Remove -march support.
13493 * config/s390/s390-c.c (s390_cpu_cpp_builtins_internal):
13494 Use a table to get an arch level.
13495 * config/s390/s390-opts.h (enum processor_type):
13496 Remove enum values.
13497 * config/s390/s390.c
13498 (processor_table): Remove entries, add arch_level values.
13499 (s390_issue_rate): Remove cases.
13500 (s390_option_override): Adjust
13501 s390_option_override_internal() call.
13502 (s390_option_override_internal): Remove deprecation warning.
13503 (s390_valid_target_attribute_tree): Adjust
13504 s390_option_override_internal() call.
13505 * config/s390/s390.h (struct s390_processor):
13506 Share with s390-c.c, add arch_level field.
13507 * config/s390/s390.md:
13508 Remove occurrences in cpu attribute.
13509 * config/s390/s390.opt: Remove -march/-mtune support.
13510 * config/s390/tpf.h (ASM_SPEC): Remove -march support.
13511 * doc/invoke.texi: Remove deprecation warning.
13512
13513 2018-08-08 Luis Machado <luis.machado@linaro.org>
13514
13515 * config/aarch64/aarch64.c (qdf24xx_vector_cost): New static
13516 global.
13517 (qdf24xx_tunings): Set vector cost structure to
13518 qdf24xx_vector_cost.
13519
13520 * config/aarch64/aarch64.c (qdf24xx_addrcost_table)
13521 <register_sextend>: Set to 3.
13522
13523 2018-08-07 Richard Sandiford <richard.sandiford@arm.com>
13524
13525 PR target/86838
13526 * config/aarch64/iterators.md (FRECP, frecp_suffix): Delete.
13527 * config/aarch64/aarch64-simd.md
13528 (aarch64_frecp<FRECP:frecp_suffix><mode>): Fold FRECPE into...
13529 (@aarch64_frecpe<mode>): ...here and the move FRECPX to...
13530 (aarch64_frecpx<mode>): ...this new pattern.
13531 * config/aarch64/aarch64-simd-builtins.def: Remove comment
13532 about aarch64_frecp<FRECP:frecp_suffix><mode>.
13533
13534 2018-08-07 Martin Liska <mliska@suse.cz>
13535
13536 PR middle-end/83023
13537 * predict.c (expr_expected_value_1): Handle DECL_IS_MALLOC,
13538 BUILT_IN_REALLOC and DECL_IS_OPERATOR_NEW.
13539 * predict.def (PRED_MALLOC_NONNULL): New predictor.
13540 * doc/extend.texi: Document that malloc attribute adds
13541 hit to compiler.
13542
13543 2018-08-06 John David Anglin <danglin@gcc.gnu.org>
13544
13545 PR target/86785
13546 * config/pa/pa.c (TARGET_HAVE_SPECULATION_SAFE_VALUE):
13547 Define to speculation_safe_value_not_needed.
13548
13549 2018-08-06 Jeff Law <law@redhat.com>
13550
13551 * tree-ssa-dom.c (dom_opt_dom_walker::optimize_stmt): Pass down
13552 the vr_values instance to cprop_into_stmt.
13553 (cprop_into_stmt): Pass vr_values instance down to cprop_operand.
13554 (cprop_operand): Also query EVRP to determine if OP is a constant.
13555
13556 2018-08-06 Nathan Sidwell <nathan@acm.org>
13557
13558 * diagnostic.c (diagnostic_report_current_module): Reroll
13559 included-at loop. Translate text.
13560
13561 2018-08-06 David Malcolm <dmalcolm@redhat.com>
13562
13563 * function-tests.c (selftest::test_expansion_to_rtl): Call
13564 free_after_compilation.
13565
13566 2018-08-06 Alan Hayward <alan.hayward@arm.com>
13567
13568 * config/aarch64/aarch64.md: Add clobber highs to tls_desc.
13569
13570 2018-08-06 Andreas Krebbel <krebbel@linux.ibm.com>
13571
13572 * config/s390/s390.c (s390_loop_unroll_adjust): Prevent small
13573 loops with memory block operations from getting unrolled.
13574
13575 2018-08-06 Ulrich Weigand <uweigand@de.ibm.com>
13576
13577 PR target/86807
13578 * config/spu/spu.c (TARGET_HAVE_SPECULATION_SAFE_VALUE):
13579 Define to speculation_safe_value_not_needed.
13580
13581 2018-08-06 Jeff Law <law@redhat.com>
13582
13583 * reload1.c (forget_old_reloads_1): Adjust CLOBBER_HIGH
13584 assert.
13585
13586 2018-08-06 Jozef Lawrynowicz <jozef.l@mittosystems.com>
13587
13588 PR target/86662
13589 * gcc/tree.c (build_common_tree_nodes): Initialize integer_types array
13590 with all enabled __intN types.
13591
13592 * gcc/testsuite/gcc.target/msp430/pr86662.c: New test.
13593
13594 2018-08-06 Alan Hayward <alan.hayward@arm.com>
13595
13596 * alias.c (record_set): Check for clobber high.
13597 * cfgexpand.c (expand_gimple_stmt): Likewise.
13598 * combine-stack-adj.c (single_set_for_csa): Likewise.
13599 * combine.c (find_single_use_1): Likewise.
13600 (set_nonzero_bits_and_sign_copies): Likewise.
13601 (get_combine_src_dest): Likewise.
13602 (is_parallel_of_n_reg_sets): Likewise.
13603 (try_combine): Likewise.
13604 (record_dead_and_set_regs_1): Likewise.
13605 (reg_dead_at_p_1): Likewise.
13606 (reg_dead_at_p): Likewise.
13607 * dce.c (deletable_insn_p): Likewise.
13608 (mark_nonreg_stores_1): Likewise.
13609 (mark_nonreg_stores_2): Likewise.
13610 * df-scan.c (df_find_hard_reg_defs): Likewise.
13611 (df_uses_record): Likewise.
13612 (df_get_call_refs): Likewise.
13613 * dwarf2out.c (mem_loc_descriptor): Likewise.
13614 * haifa-sched.c (haifa_classify_rtx): Likewise.
13615 * ira-build.c (create_insn_allocnos): Likewise.
13616 * ira-costs.c (scan_one_insn): Likewise.
13617 * ira.c (equiv_init_movable_p): Likewise.
13618 (rtx_moveable_p): Likewise.
13619 (interesting_dest_for_shprep): Likewise.
13620 * jump.c (mark_jump_label_1): Likewise.
13621 * postreload-gcse.c (record_opr_changes): Likewise.
13622 * postreload.c (reload_cse_simplify): Likewise.
13623 (struct reg_use): Add source expr.
13624 (reload_combine): Check for clobber high.
13625 (reload_combine_note_use): Likewise.
13626 (reload_cse_move2add): Likewise.
13627 (move2add_note_store): Likewise.
13628 * print-rtl.c (print_pattern): Likewise.
13629 * recog.c (decode_asm_operands): Likewise.
13630 (store_data_bypass_p): Likewise.
13631 (if_test_bypass_p): Likewise.
13632 * regcprop.c (kill_clobbered_value): Likewise.
13633 (kill_set_value): Likewise.
13634 * reginfo.c (reg_scan_mark_refs): Likewise.
13635 * reload1.c (maybe_fix_stack_asms): Likewise.
13636 (eliminate_regs_1): Likewise.
13637 (elimination_effects): Likewise.
13638 (mark_not_eliminable): Likewise.
13639 (scan_paradoxical_subregs): Likewise.
13640 (forget_old_reloads_1): Likewise.
13641 * reorg.c (find_end_label): Likewise.
13642 (try_merge_delay_insns): Likewise.
13643 (redundant_insn): Likewise.
13644 (own_thread_p): Likewise.
13645 (fill_simple_delay_slots): Likewise.
13646 (fill_slots_from_thread): Likewise.
13647 (dbr_schedule): Likewise.
13648 * resource.c (update_live_status): Likewise.
13649 (mark_referenced_resources): Likewise.
13650 (mark_set_resources): Likewise.
13651 * rtl.c (copy_rtx): Likewise.
13652 * rtlanal.c (reg_referenced_p): Likewise.
13653 (single_set_2): Likewise.
13654 (noop_move_p): Likewise.
13655 (note_stores): Likewise.
13656 * sched-deps.c (sched_analyze_reg): Likewise.
13657 (sched_analyze_insn): Likewise.
13658
13659 2018-08-06 Alan Hayward <alan.hayward@arm.com>
13660
13661 * cse.c (invalidate_reg): New function extracted from...
13662 (invalidate): ...here.
13663 (canonicalize_insn): Check for clobber high.
13664 (invalidate_from_clobbers): invalidate clobber highs.
13665 (invalidate_from_sets_and_clobbers): Likewise.
13666 (count_reg_usage): Check for clobber high.
13667 (insn_live_p): Likewise.
13668 * cselib.c (cselib_expand_value_rtx_1):Likewise.
13669 (cselib_invalidate_regno): Check for clobber in setter.
13670 (cselib_invalidate_rtx): Pass through setter.
13671 (cselib_invalidate_rtx_note_stores):
13672 (cselib_process_insn): Check for clobber high.
13673 * cselib.h (cselib_invalidate_rtx): Add operand.
13674
13675 2018-08-06 Alan Hayward <alan.hayward@arm.com>
13676
13677 * lra-eliminations.c (lra_eliminate_regs_1): Check for clobber high.
13678 (mark_not_eliminable): Likewise.
13679 * lra-int.h (struct lra_insn_reg): Add clobber high marker.
13680 * lra-lives.c (process_bb_lives): Check for clobber high.
13681 * lra.c (new_insn_reg): Remember clobber highs.
13682 (collect_non_operand_hard_regs): Check for clobber high.
13683 (lra_set_insn_recog_data): Likewise.
13684 (add_regs_to_insn_regno_info): Likewise.
13685 (lra_update_insn_regno_info): Likewise.
13686
13687 2018-08-06 Alan Hayward <alan.hayward@arm.com>
13688
13689 * rtl.h (reg_is_clobbered_by_clobber_high): Add declarations.
13690 * rtlanal.c (reg_is_clobbered_by_clobber_high): Add function.
13691
13692 2018-08-06 Alan Hayward <alan.hayward@arm.com>
13693
13694 * emit-rtl.c (verify_rtx_sharing): Check for CLOBBER_HIGH.
13695 (copy_insn_1): Likewise.
13696 (gen_hard_reg_clobber_high): New gen function.
13697 * genconfig.c (walk_insn_part): Check for CLOBBER_HIGH.
13698 * genemit.c (gen_exp): Likewise.
13699 (gen_emit_seq): Pass through info.
13700 (gen_insn): Check for CLOBBER_HIGH.
13701 (gen_expand): Pass through info.
13702 (gen_split): Likewise.
13703 (output_add_clobbers): Likewise.
13704 * genrecog.c (validate_pattern): Check for CLOBBER_HIGH.
13705 (remove_clobbers): Likewise.
13706 * rtl.h (gen_hard_reg_clobber_high): New declaration.
13707
13708 2018-08-06 Alan Hayward <alan.hayward@arm.com>
13709
13710 * doc/rtl.texi (clobber_high): Add.
13711 (parallel): Add in clobber high
13712 * rtl.c (rtl_check_failed_code3): Add function.
13713 * rtl.def (CLOBBER_HIGH): Add expression.
13714 * rtl.h (RTL_CHECKC3): Add macro.
13715 (rtl_check_failed_code3): Add declaration.
13716 (XC3EXP): Add macro.
13717
13718 2018-08-05 H.J. Lu <hongjiu.lu@intel.com>
13719
13720 PR target/86386
13721 * config/i386/i386.c (ix86_finalize_stack_frame_flags): Set
13722 cfun->machine->max_used_stack_alignment if needed.
13723
13724 2018-08-04 Martin Sebor <msebor@redhat.com>
13725
13726 PR tree-optimization/86571
13727 * gimple-ssa-sprintf.c (format_floating): Extend upper bound of
13728 NaN output to 4.
13729
13730 2018-08-03 Sandra Loosemore <sandra@codesourcery.com>
13731
13732 PR target/86799
13733 * config/nios2/nios2.c (TARGET_HAVE_SPECULATION_SAFE_VALUE):
13734 Define.
13735
13736 2018-08-03 Jeff Law <law@redhat.com>
13737
13738 PR target/86795
13739 * config/mn10300/mn10300.c (TARGET_HAVE_SPECULATION_SAFE_VALUE):
13740 Define to speculation_safe_value_not_needed.
13741
13742 2018-08-03 David Malcolm <dmalcolm@redhat.com>
13743
13744 * doc/gcov.texi (-x): Remove duplicate "to".
13745 * doc/invoke.texi (-Wnoexcept-type): Remove duplicate "calls".
13746 (-Wif-not-aligned): Remove duplicate "is".
13747 (-flto): Remove duplicate "the".
13748 (MicroBlaze Options): In examples of "-mcpu=cpu-type", remove
13749 duplicate "v5.00.b".
13750 (MSP430 Options): Remove duplicate "and" from the description
13751 of "-mgprel-sec=regexp".
13752 (x86 Options): Remove duplicate copies of "vmldLog102" and
13753 vmlsLog104 from description of "-mveclibabi=type".
13754
13755 2018-08-03 Richard Sandiford <richard.sandiford@arm.com>
13756
13757 * internal-fn.h (first_commutative_argument): Declare.
13758 * internal-fn.c (first_commutative_argument): New function.
13759 * tree-vect-slp.c (vect_get_and_check_slp_defs): Remove extra
13760 restrictions for pattern statements. Use first_commutative_argument
13761 to look for commutative operands in calls to internal functions.
13762
13763 2018-08-03 Aldy Hernandez <aldyh@redhat.com>
13764
13765 * Makefile.in (wide-int-range.o): New.
13766 * tree-vrp.c: Move all the wide_int_* functions to...
13767 * wide-int-range.cc: ...here.
13768 * tree-vrp.h: Move all the wide_int_* prototypes to...
13769 * wide-int-range.h: ...here.
13770
13771 2018-08-03 Tom de Vries <tdevries@suse.de>
13772
13773 * common/config/nvptx/nvptx-common.c (nvptx_except_unwind_info): Return
13774 UI_NONE.
13775 * config/nvptx/nvptx.c (TARGET_ASM_BYTE_OP): Remove define.
13776 * except.c (output_function_exception_table): Do early exit if
13777 targetm_common.except_unwind_info (&global_options) == UI_NONE.
13778
13779 2018-08-03 Martin Liska <mliska@suse.cz>
13780
13781 * predict.c (dump_prediction): Change to 2 digits
13782 in fraction part.
13783
13784 2018-08-03 Siddhesh Poyarekar <siddhesh@sourceware.org>
13785
13786 * config/aarch64/falkor.md (falkor_am_1_vxvy_vxvy): Move
13787 neon_dup_q to...
13788 (falkor_am_1_gtov_gtov): ... a new insn reservation.
13789
13790 2018-07-19 Ilya Leoshkevich <iii@linux.ibm.com>
13791
13792 * config/nds32/nds32.c (nds32_hard_regno_mode_ok): Replace > with >=.
13793 * df-problems.c (df_remove_dead_eq_notes): Replace > with >=.
13794 * dwarf2out.c (mem_loc_descriptor): Replace > with >=.
13795 * lra-constraints.c (spill_hard_reg_in_range): Replace <= with <.
13796 * lra-remat.c (call_used_input_regno_present_p): Replace <= with <.
13797
13798 2018-08-02 David Malcolm <dmalcolm@redhat.com>
13799
13800 * diagnostic-show-locus.c (diagnostic_show_locus): Use
13801 pp_take_prefix when saving the existing prefix.
13802 * diagnostic.c (diagnostic_append_note): Likewise.
13803 * langhooks.c (lhd_print_error_function): Likewise.
13804 * pretty-print.c (pp_set_prefix): Drop the "const" from "prefix"
13805 param's type. Free the existing prefix.
13806 (pp_take_prefix): New function.
13807 (pretty_printer::pretty_printer): Drop the prefix parameter.
13808 Rename the length parameter to match the comment.
13809 (pretty_printer::~pretty_printer): Free the prefix.
13810 * pretty-print.h (pretty_printer::pretty_printer): Drop the prefix
13811 parameter.
13812 (struct pretty_printer): Drop the "const" from "prefix" field's
13813 type and clarify memory management.
13814 (pp_set_prefix): Drop the "const" from the 2nd param.
13815 (pp_take_prefix): New decl.
13816
13817 2018-08-02 Aaron Sawdey <acsawdey@linux.ibm.com>
13818
13819 * config/rs6000/rs6000-string.c (select_block_compare_mode): Move test
13820 for word_mode_ok here instead of passing as argument.
13821 (expand_block_compare): Change select_block_compare_mode() call.
13822 (expand_strncmp_gpr_sequence): New function.
13823 (expand_strn_compare): Make use of expand_strncmp_gpr_sequence.
13824
13825 2018-08-02 Jeff Law <law@redhat.com>
13826
13827 PR target/86790
13828 * config/m68k/m68k.c (TARGET_HAVE_SPECULATION_SAFE_VALUE):
13829 Define to speculation_safe_value_not_needed.
13830
13831 PR target/86784
13832 * config/h8300/h8300.c (TARGET_HAVE_SPECULATION_SAFE_VALUE):
13833 Define to speculation_safe_value_not_needed.
13834
13835 2018-08-02 Tom de Vries <tdevries@suse.de>
13836
13837 PR target/86660
13838 * common/config/nvptx/nvptx-common.c (nvptx_except_unwind_info): New
13839 function. Return UI_TARGET unconditionally.
13840 (TARGET_EXCEPT_UNWIND_INFO): Redefine to nvptx_except_unwind_info.
13841 * config/nvptx/nvptx.c (TARGET_ASM_BYTE_OP): Emit commented out '.byte'.
13842
13843 2018-08-02 Richard Sandiford <richard.sandiford@arm.com>
13844
13845 * genemit.c (print_overload_test): Fix typo.
13846
13847 2018-08-02 Richard Biener <rguenther@suse.de>
13848
13849 PR tree-optimization/86816
13850 * tree-ssa-tail-merge.c (tail_merge_valueize): New function
13851 which checks for value availability before querying it.
13852 (gvn_uses_equal): Use it.
13853 (same_succ_hash): Likewise.
13854 (gimple_equal_p): Likewise.
13855
13856 2018-08-02 Nick Clifton <nickc@redhat.com>
13857
13858 PR target/86813
13859 * config/stormy16/stormy16.c (TARGET_HAVE_SPECULATION_SAFE_VALUE):
13860 Define to speculation_safe_value_not_needed.
13861
13862 PR target/86810
13863 * config/v850/v850.c (TARGET_HAVE_SPECULATION_SAFE_VALUE):
13864 Define to speculation_safe_value_not_needed.
13865
13866 PR target/86810
13867 * config/v850/v850.c (TARGET_HAVE_SPECULATION_SAFE_VALUE):
13868 Define to speculation_safe_value_not_needed.
13869
13870 PR target/86803
13871 * config/rx/rx.c (TARGET_HAVE_SPECULATION_SAFE_VALUE):
13872 Define to speculation_safe_value_not_needed.
13873
13874 PR target/86797
13875 * config/msp430/msp430.c (TARGET_HAVE_SPECULATION_SAFE_VALUE):
13876 Define to speculation_safe_value_not_needed.
13877
13878 PR target/86791
13879 * config/mcore/mcore.c (TARGET_HAVE_SPECULATION_SAFE_VALUE):
13880 Define to speculation_safe_value_not_needed.
13881
13882 PR target/86789
13883 * config/m32r/m32r.c (TARGET_HAVE_SPECULATION_SAFE_VALUE):
13884 Define to speculation_safe_value_not_needed.
13885
13886 PR target/86787
13887 * config/iq2000/iq2000.c (TARGET_HAVE_SPECULATION_SAFE_VALUE):
13888 Define to speculation_safe_value_not_needed.
13889
13890 PR target/86782
13891 * config/frv/frv.c (TARGET_HAVE_SPECULATION_SAFE_VALUE): Define to
13892 speculation_safe_value_not_needed.
13893
13894 PR target/86781
13895 * config/fr30/fr30.c (TARGET_HAVE_SPECULATION_SAFE_VALUE): Define
13896 to speculation_safe_value_not_needed.
13897
13898 2018-08-02 Richard Sandiford <richard.sandiford@arm.com>
13899
13900 * doc/md.texi: Expand the documentation of instruction names
13901 to mention port-local uses. Document '@' in pattern names.
13902 * read-md.h (overloaded_instance, overloaded_name): New structs.
13903 (mapping): Declare.
13904 (md_reader::handle_overloaded_name): New member function.
13905 (md_reader::get_overloads): Likewise.
13906 (md_reader::m_first_overload): New member variable.
13907 (md_reader::m_next_overload_ptr): Likewise.
13908 (md_reader::m_overloads_htab): Likewise.
13909 * read-md.c (md_reader::md_reader): Initialize m_first_overload,
13910 m_next_overload_ptr and m_overloads_htab.
13911 * read-rtl.c (iterator_group): Add "type" and "get_c_token" fields.
13912 (get_mode_token, get_code_token, get_int_token): New functions.
13913 (map_attr_string): Add an optional argument that passes back
13914 the associated iterator.
13915 (overloaded_name_hash, overloaded_name_eq_p, named_rtx_p):
13916 (md_reader::handle_overloaded_name, add_overload_instance): New
13917 functions.
13918 (apply_iterators): Handle '@' names. Report an error if '@'
13919 is used without iterators.
13920 (initialize_iterators): Initialize the new iterator_group fields.
13921 * genopinit.c (handle_overloaded_code_for)
13922 (handle_overloaded_gen): New functions.
13923 (main): Use them to print declarations of maybe_code_for_* and
13924 maybe_gen_* functions, and inline definitions of code_for_* and gen_*.
13925 * genemit.c (print_overload_arguments, print_overload_test)
13926 (handle_overloaded_code_for, handle_overloaded_gen): New functions.
13927 (main): Use it to print definitions of maybe_code_for_* and
13928 maybe_gen_* functions.
13929 * config/aarch64/aarch64.c (aarch64_split_128bit_move): Use
13930 gen_aarch64_mov{low,high}_di and gen_aarch64_movdi_{low,high}
13931 instead of explicit mode checks.
13932 (aarch64_split_simd_combine): Likewise gen_aarch64_simd_combine.
13933 (aarch64_split_simd_move): Likewise gen_aarch64_split_simd_mov.
13934 (aarch64_emit_load_exclusive): Likewise gen_aarch64_load_exclusive.
13935 (aarch64_emit_store_exclusive): Likewise gen_aarch64_store_exclusive.
13936 (aarch64_expand_compare_and_swap): Likewise
13937 gen_aarch64_compare_and_swap and gen_aarch64_compare_and_swap_lse
13938 (aarch64_gen_atomic_cas): Likewise gen_aarch64_atomic_cas.
13939 (aarch64_emit_atomic_swap): Likewise gen_aarch64_atomic_swp.
13940 (aarch64_constant_pool_reload_icode): Delete.
13941 (aarch64_secondary_reload): Use code_for_aarch64_reload_movcp
13942 instead of aarch64_constant_pool_reload_icode. Use
13943 code_for_aarch64_reload_mov instead of explicit mode checks.
13944 (rsqrte_type, get_rsqrte_type, rsqrts_type, get_rsqrts_type): Delete.
13945 (aarch64_emit_approx_sqrt): Use gen_aarch64_rsqrte instead of
13946 get_rsqrte_type and gen_aarch64_rsqrts instead of gen_rqrts_type.
13947 (recpe_type, get_recpe_type, recps_type, get_recps_type): Delete.
13948 (aarch64_emit_approx_div): Use gen_aarch64_frecpe instead of
13949 get_recpe_type and gen_aarch64_frecps instead of get_recps_type.
13950 (aarch64_atomic_load_op_code): Delete.
13951 (aarch64_emit_atomic_load_op): Likewise.
13952 (aarch64_gen_atomic_ldop): Use UNSPECV_ATOMIC_* instead of
13953 aarch64_atomic_load_op_code. Use gen_aarch64_atomic_load
13954 instead of aarch64_emit_atomic_load_op.
13955 * config/aarch64/aarch64.md (aarch64_reload_movcp<GPF_TF:mode><P:mode>)
13956 (aarch64_reload_movcp<VALL:mode><P:mode>, aarch64_reload_mov<mode>)
13957 (aarch64_movdi_<mode>low, aarch64_movdi_<mode>high)
13958 (aarch64_mov<mode>high_di, aarch64_mov<mode>low_di): Add a '@'
13959 character before the pattern name.
13960 * config/aarch64/aarch64-simd.md (aarch64_split_simd_mov<mode>)
13961 (aarch64_rsqrte<mode>, aarch64_rsqrts<mode>)
13962 (aarch64_simd_combine<mode>, aarch64_frecpe<mode>)
13963 (aarch64_frecps<mode>): Likewise.
13964 * config/aarch64/atomics.md (atomic_compare_and_swap<mode>)
13965 (aarch64_compare_and_swap<mode>, aarch64_compare_and_swap<mode>_lse)
13966 (aarch64_load_exclusive<mode>, aarch64_store_exclusive<mode>)
13967 (aarch64_atomic_swp<mode>, aarch64_atomic_cas<mode>)
13968 (aarch64_atomic_load<atomic_ldop><mode>): Likewise.
13969
13970 2018-08-02 Richard Sandiford <richard.sandiford@arm.com>
13971
13972 * config/aarch64/aarch64.c (aarch64_float_const_representable_p):
13973 Allow HFmode constants if TARGET_FP_F16INST.
13974
13975 2018-08-02 Jackson Woodruff <jackson.woodruff@arm.com>
13976
13977 PR target/86014
13978 * config/aarch64/aarch64.c (aarch64_operands_adjust_ok_for_ldpstp):
13979 No longer check last store for clobber of address register.
13980
13981 2018-08-02 Martin Liska <mliska@suse.cz>
13982
13983 PR gcov-profile/86817
13984 * gcov.c (process_all_functions): New function.
13985 (main): Call it.
13986 (process_file): Move functions processing to
13987 process_all_functions.
13988
13989 2018-08-02 David Malcolm <dmalcolm@redhat.com>
13990
13991 * dumpfile.c (dump_user_location_t::dump_user_location_t): Add
13992 "const" to the "gimple *" and "rtx_insn *" parameters.
13993 * dumpfile.h (dump_user_location_t::dump_user_location_t):
13994 Likewise.
13995 (dump_location_t::dump_location_t): Likewise.
13996
13997 2018-08-01 Martin Sebor <msebor@redhat.com>
13998
13999 PR tree-optimization/86650
14000 * gimple-pretty-print.c (percent_G_format): Accept a "gimple *"
14001 rather than a "gcall *". Directly pass the data of interest
14002 to percent_K_format, rather than building a temporary CALL_EXPR
14003 to hold it.
14004 * gimple-fold.c (gimple_fold_builtin_strncpy): Adjust.
14005 (gimple_fold_builtin_strncat): Adjust.
14006 * gimple-ssa-warn-restrict.h (check_bounds_or_overlap): Replace
14007 gcall* argument with gimple*.
14008 * gimple-ssa-warn-restrict.c (check_call): Same.
14009 (wrestrict_dom_walker::before_dom_children): Same.
14010 (builtin_access::builtin_access): Same.
14011 (check_bounds_or_overlap): Same
14012 (maybe_diag_overlap): Same.
14013 (maybe_diag_offset_bounds): Same.
14014 * tree-diagnostic.c (default_tree_printer): Move usage of
14015 EXPR_LOCATION (t) and TREE_BLOCK (t) from within percent_K_format
14016 to this callsite.
14017 * tree-pretty-print.c (percent_K_format): Add argument.
14018 * tree-pretty-print.h: Add argument.
14019 * tree-ssa-ccp.c (pass_post_ipa_warn::execute): Adjust.
14020 * tree-ssa-strlen.c (maybe_diag_stxncpy_trunc): Adjust.
14021 (maybe_diag_stxncpy_trunc): Same.
14022 (handle_builtin_stxncpy): Same.
14023 (handle_builtin_strcat): Same.
14024
14025 2018-08-01 Richard Sandiford <richard.sandiford@arm.com>
14026
14027 * match.pd: Optimise pointer range checks.
14028
14029 2018-08-01 Richard Sandiford <richard.sandiford@arm.com>
14030
14031 PR tree-optimization/86758
14032 * tree-vect-stmts.c (vectorizable_simd_clone_call): Don't try
14033 to remove pattern statements.
14034
14035 2018-08-01 Richard Sandiford <richard.sandiford@arm.com>
14036
14037 * tree-vect-loop.c (_loop_vec_info::_loop_vec_info): Use the
14038 result of dfs_enumerate_from when constructing stmt_vec_infos,
14039 instead of additionally calling get_loop_body.
14040
14041 2018-08-01 Richard Sandiford <richard.sandiford@arm.com>
14042
14043 * tree-vectorizer.h (vect_create_data_ref_ptr): Remove inv_p
14044 parameter.
14045 * tree-vect-data-refs.c (vect_create_data_ref_ptr): Likewise.
14046 When creating an iv, assert that the step is not known to be zero.
14047 (vect_setup_realignment): Update call accordingly.
14048 * tree-vect-stmts.c (vectorizable_store): Likewise.
14049 (vectorizable_load): Likewise. Handle VMAT_INVARIANT separately.
14050
14051 2018-08-01 Richard Sandiford <richard.sandiford@arm.com>
14052
14053 * tree-vectorizer.h (vect_stmt_to_vectorize): New function.
14054 * tree-vect-loop.c (vect_update_vf_for_slp): Use it.
14055 (vectorizable_reduction): Likewise.
14056 * tree-vect-slp.c (vect_analyze_slp_instance): Likewise.
14057 (vect_detect_hybrid_slp_stmts): Likewise.
14058 * tree-vect-stmts.c (vect_is_simple_use): Likewise.
14059
14060 2018-08-01 Aldy Hernandez <aldyh@redhat.com>
14061
14062 * tree-vrp (zero_nonzero_bits_from_bounds): Rename to...
14063 (wide_int_set_zero_nonzero_bits): ...this.
14064 (zero_nonzero_bits_from_vr): Rename to...
14065 (vrp_set_zero_nonzero_bits): ...this.
14066 (extract_range_from_multiplicative_op_1): Abstract wide int
14067 code...
14068 (wide_int_range_multiplicative_op): ...here.
14069 (extract_range_from_binary_expr_1): Extract wide int binary
14070 operations into their own functions.
14071 (wide_int_range_lshift): New.
14072 (wide_int_range_can_optimize_bit_op): New.
14073 (wide_int_range_shift_undefined_p): New.
14074 (wide_int_range_bit_xor): New.
14075 (wide_int_range_bit_ior): New.
14076 (wide_int_range_bit_and): New.
14077 (wide_int_range_trunc_mod): New.
14078 (extract_range_into_wide_ints): New.
14079 (vrp_shift_undefined_p): New.
14080 (extract_range_from_multiplicative_op): New.
14081 (vrp_can_optimize_bit_op): New.
14082 * tree-vrp.h (value_range::dump): New.
14083 (wide_int_range_multiplicative_op): New.
14084 (wide_int_range_lshift):New.
14085 (wide_int_range_shift_undefined_p): New.
14086 (wide_int_range_bit_xor): New.
14087 (wide_int_range_bit_ior): New.
14088 (wide_int_range_bit_and): New.
14089 (wide_int_range_trunc_mod): New.
14090 (zero_nonzero_bits_from_bounds): Rename to...
14091 (wide_int_set_zero_nonzero_bits): ...this.
14092 (zero_nonzero_bits_from_vr): Rename to...
14093 (vrp_set_zero_nonzero_bits): ...this.
14094 (range_easy_mask_min_max): Rename to...
14095 (wide_int_range_can_optimize_bit_op): this.
14096 * vr-values.c (simplify_bit_ops_using_ranges): Rename
14097 zero_nonzero_bits_from_vr into vrp_set_zero_nonzero_bits.
14098
14099 2018-08-01 Richard Sandiford <richard.sandiford@arm.com>
14100
14101 * tree-vectorizer.h (vect_orig_stmt): New function.
14102 * tree-vect-data-refs.c (vect_preserves_scalar_order_p): Use it.
14103 * tree-vect-loop.c (vect_model_reduction_cost): Likewise.
14104 (vect_create_epilog_for_reduction): Likewise.
14105 (vectorizable_live_operation): Likewise.
14106 * tree-vect-slp.c (vect_find_last_scalar_stmt_in_slp): Likewise.
14107 (vect_detect_hybrid_slp_stmts, vect_schedule_slp): Likewise.
14108 * tree-vect-stmts.c (vectorizable_call): Likewise.
14109 (vectorizable_simd_clone_call, vect_remove_stores): Likewise.
14110
14111 2018-08-01 Richard Sandiford <richard.sandiford@arm.com>
14112
14113 * tree-vectorizer.h (vect_transform_stmt): Remove grouped_store
14114 argument.
14115 * tree-vect-stmts.c (vect_transform_stmt): Likewise.
14116 * tree-vect-loop.c (vect_transform_loop_stmt): Update call accordingly.
14117 (vect_transform_loop): Likewise.
14118 * tree-vect-slp.c (vect_schedule_slp_instance): Likewise.
14119
14120 2018-08-01 Richard Sandiford <richard.sandiford@arm.com>
14121
14122 * tree-vectorizer.h (vect_schedule_slp): Return void.
14123 * tree-vect-slp.c (vect_schedule_slp_instance): Likewise.
14124 (vect_schedule_slp): Likewise.
14125
14126 2018-08-01 Richard Sandiford <richard.sandiford@arm.com>
14127
14128 * tree-vect-loop.c (vect_transform_loop_stmt): Remove slp_scheduled
14129 argument.
14130 (vect_transform_loop): Update calls accordingly. Schedule SLP
14131 instances before the main loop, if any exist.
14132
14133 2018-08-01 Richard Sandiford <richard.sandiford@arm.com>
14134
14135 PR tree-optimization/86749
14136 * tree-vect-patterns.c (vect_determine_min_output_precision_1):
14137 If the lhs is used in a COND_EXPR, check that it is being used
14138 as the "then" or "else" value.
14139
14140 2018-08-01 Tom de Vries <tdevries@suse.de>
14141
14142 PR target/86800
14143 * config/nvptx/nvptx.c (TARGET_HAVE_SPECULATION_SAFE_VALUE): Define to
14144 speculation_safe_value_not_needed.
14145
14146 2018-08-01 Richard Biener <rguenther@suse.de>
14147
14148 * tree-ssa-sccvn.c (visit_phi): Compare invariant addresses
14149 as base and offset.
14150
14151 2018-08-01 Martin Liska <mliska@suse.cz>
14152
14153 * value-prof.c (gimple_divmod_fixed_value_transform): Unify
14154 format how successful transformation is dumped.
14155 (gimple_mod_pow2_value_transform): Likewise.
14156 (gimple_mod_subtract_transform): Likewise.
14157 (gimple_stringops_transform): Likewise.
14158
14159 2018-08-01 Martin Liska <mliska@suse.cz>
14160
14161 PR value-prof/35543
14162 * value-prof.c (interesting_stringop_to_profile_p):
14163 Simplify the code and add BUILT_IN_MEMMOVE.
14164 (gimple_stringops_transform): Likewise.
14165
14166 2018-08-01 Sam Tebbs <sam.tebbs@arm.com>
14167
14168 * config/aarch64/aarch64-simd.md
14169 (*aarch64_get_lane_zero_extendsi<mode>): Rename to...
14170 (*aarch64_get_lane_zero_extend<GPI:mode><VDQQH:mode>): ... This and
14171 use GPI iterator instead of SI mode.
14172
14173 2018-08-01 Richard Earnshaw <rearnsha@arm.com>
14174
14175 * config/rs6000/rs6000.md (speculation_barrier): Renamed from
14176 rs6000_speculation_barrier.
14177 * config/rs6000/rs6000.c (rs6000_expand_builtin): Adjust for
14178 new barrier pattern name.
14179
14180 2018-08-01 Richard Earnshaw <rearnsha@arm.com>
14181
14182 * config/i386/i386.md (unspecv): Add UNSPECV_SPECULATION_BARRIER.
14183 (speculation_barrier): New insn.
14184
14185 2018-08-01 Richard Biener <rguenther@suse.de>
14186
14187 PR bootstrap/86724
14188 * graphite.h: Include isl/id.h and isl/space.h to allow build
14189 with ISL 0.20.
14190
14191 2018-08-01 Jan Willem Jagersma <jwjagersma@gmail.com>
14192
14193 PR target/86651
14194 * dwarf2out.c (dwarf2out_early_finish): Do not generate assembly in LTO
14195 mode for COFF targets.
14196 * defaults.h (TARGET_COFF): Define.
14197 * config/i386/djgpp.h (TARGET_ASM_LTO_START, TARGET_ASM_LTO_END,
14198 TARGET_COFF): Define.
14199 (i386_djgpp_asm_lto_start, i386_djgpp_asm_lto_end): Declare.
14200 * config/i386/djgpp.c (saved_debug_info_level): New static variable.
14201 (i386_djgpp_asm_lto_start, i386_djgpp_asm_lto_end): New functions.
14202
14203 2018-07-31 Alexandre Oliva <oliva@adacore.com>
14204
14205 * gimple-streamer-in.c (input_bb): Restore BB discriminator.
14206 * gimple-streamer-out.c (output_bb): Save it.
14207 * lto-streamer-in.c (input_struct_function_base): Restore
14208 instance discriminator if available. Create map on demand.
14209 * lto-streamer-out.c (output_struct_function_base): Save it if
14210 available.
14211 * final.c (decl_to_instance_map): Document LTO strategy.
14212
14213 2018-07-31 Alexandre Oliva <oliva@adacore.com>
14214 Olivier Hainque <hainque@adacore.com>
14215
14216 * debug.h (decl_to_instance_map_t): New type.
14217 (decl_to_instance_map): Declare.
14218 (maybe_create_decl_to_instance_map): New inline function.
14219 * final.c (bb_discriminator, last_bb_discriminator): New statics,
14220 to track basic block discriminators.
14221 (final_start_function_1): Initialize them.
14222 (final_scan_insn_1): On NOTE_INSN_BASIC_BLOCK, track
14223 bb_discriminator.
14224 (decl_to_instance_map): New variable.
14225 (map_decl_to_instance, maybe_set_discriminator): New functions.
14226 (notice_source_line): Set discriminator.
14227
14228 2018-07-31 Ian Lance Taylor <iant@golang.org>
14229
14230 * targhooks.c (default_have_speculation_safe_value): Add
14231 ATTRIBUTE_UNUSED.
14232
14233 2018-07-31 David Malcolm <dmalcolm@redhat.com>
14234
14235 * dump-context.h: Include "pretty-print.h".
14236 (dump_context::refresh_dumps_are_enabled): New decl.
14237 (dump_context::emit_item): New decl.
14238 (class dump_context): Add fields "m_test_pp" and
14239 "m_test_pp_flags".
14240 (temp_dump_context::temp_dump_context): Add param "test_pp_flags".
14241 (temp_dump_context::get_dumped_text): New decl.
14242 (class temp_dump_context): Add field "m_pp".
14243 * dumpfile.c (refresh_dumps_are_enabled): Convert to...
14244 (dump_context::refresh_dumps_are_enabled): ...and add a test for
14245 m_test_pp.
14246 (set_dump_file): Update for above change.
14247 (set_alt_dump_file): Likewise.
14248 (dump_loc): New overload, taking a pretty_printer *.
14249 (dump_context::dump_loc): Call end_any_optinfo. Dump the location
14250 to any test pretty-printer.
14251 (make_item_for_dump_gimple_stmt): New function, adapted from
14252 optinfo::add_gimple_stmt.
14253 (dump_context::dump_gimple_stmt): Call it, and use the result,
14254 eliminating the direct usage of dump_file and alt_dump_file in
14255 favor of indirectly using them via emit_item.
14256 (make_item_for_dump_gimple_expr): New function, adapted from
14257 optinfo::add_gimple_expr.
14258 (dump_context::dump_gimple_expr): Call it, and use the result,
14259 eliminating the direct usage of dump_file and alt_dump_file in
14260 favor of indirectly using them via emit_item.
14261 (make_item_for_dump_generic_expr): New function, adapted from
14262 optinfo::add_tree.
14263 (dump_context::dump_generic_expr): Call it, and use the result,
14264 eliminating the direct usage of dump_file and alt_dump_file in
14265 favor of indirectly using them via emit_item.
14266 (make_item_for_dump_printf_va): New function, adapted from
14267 optinfo::add_printf_va.
14268 (make_item_for_dump_printf): New function.
14269 (dump_context::dump_printf_va): Call make_item_for_dump_printf_va,
14270 and use the result, eliminating the direct usage of dump_file and
14271 alt_dump_file in favor of indirectly using them via emit_item.
14272 (make_item_for_dump_dec): New function.
14273 (dump_context::dump_dec): Call it, and use the result,
14274 eliminating the direct usage of dump_file and alt_dump_file in
14275 favor of indirectly using them via emit_item.
14276 (make_item_for_dump_symtab_node): New function, adapted from
14277 optinfo::add_symtab_node.
14278 (dump_context::dump_symtab_node): Call it, and use the result,
14279 eliminating the direct usage of dump_file and alt_dump_file in
14280 favor of indirectly using them via emit_item.
14281 (dump_context::begin_scope): Reimplement, avoiding direct usage
14282 of dump_file and alt_dump_file in favor of indirectly using them
14283 via emit_item.
14284 (dump_context::emit_item): New member function.
14285 (temp_dump_context::temp_dump_context): Add param "test_pp_flags".
14286 Set up test pretty-printer on the underlying context. Call
14287 refresh_dumps_are_enabled.
14288 (temp_dump_context::~temp_dump_context): Call
14289 refresh_dumps_are_enabled.
14290 (temp_dump_context::get_dumped_text): New member function.
14291 (selftest::verify_dumped_text): New function.
14292 (ASSERT_DUMPED_TEXT_EQ): New macro.
14293 (selftest::test_capture_of_dump_calls): Run all tests twice, with
14294 and then without optinfo enabled. Add uses of
14295 ASSERT_DUMPED_TEXT_EQ to all tests. Add test of nested scopes.
14296 * dumpfile.h: Update comment for the dump_* API.
14297 * optinfo-emit-json.cc
14298 (selftest::test_building_json_from_dump_calls): Update for new
14299 param for temp_dump_context ctor.
14300 * optinfo.cc (optinfo_item::optinfo_item): Remove "owned" param
14301 and "m_owned" field.
14302 (optinfo_item::~optinfo_item): Likewise.
14303 (optinfo::add_item): New member function.
14304 (optinfo::emit): Update comment.
14305 (optinfo::add_string): Delete.
14306 (optinfo::add_printf): Delete.
14307 (optinfo::add_printf_va): Delete.
14308 (optinfo::add_gimple_stmt): Delete.
14309 (optinfo::add_gimple_expr): Delete.
14310 (optinfo::add_tree): Delete.
14311 (optinfo::add_symtab_node): Delete.
14312 (optinfo::add_dec): Delete.
14313 * optinfo.h (class dump_context): New forward decl.
14314 (optinfo::add_item): New decl.
14315 (optinfo::add_string): Delete.
14316 (optinfo::add_printf): Delete.
14317 (optinfo::add_printf_va): Delete.
14318 (optinfo::add_gimple_stmt): Delete.
14319 (optinfo::add_gimple_expr): Delete.
14320 (optinfo::add_tree): Delete.
14321 (optinfo::add_symtab_node): Delete.
14322 (optinfo::add_dec): Delete.
14323 (optinfo::add_poly_int): Delete.
14324 (optinfo_item::optinfo_item): Remove "owned" param.
14325 (class optinfo_item): Remove field "m_owned".
14326
14327 2018-07-31 Jozef Lawrynowicz <jozef.l@mittosystems.com>
14328
14329 PR middle-end/86705
14330 * gcc/cfgexpand.c (set_parm_rtl): Use the alignment of Pmode when
14331 MAX_SUPPORTED_STACK_ALIGNMENT would otherwise be exceeded by the
14332 requested variable alignment.
14333 (expand_one_ssa_partition): Likewise.
14334 (expand_one_var): Likewise.
14335
14336 2018-07-31 Richard Earnshaw <rearnsha@arm.com>
14337
14338 * config/pdp11/pdp11.c (TARGET_HAVE_SPECULATION_SAFE_VALUE): Redefine
14339 to speculation_safe_value_not_needed.
14340
14341 2018-07-31 Richard Earnshaw <rearnsha@arm.com>
14342
14343 * targhooks.h (speculation_safe_value_not_needed): New prototype.
14344 * targhooks.c (speculation_safe_value_not_needed): New function.
14345 * target.def (have_speculation_safe_value): Update documentation.
14346 * doc/tm.texi: Regenerated.
14347
14348 2018-07-31 Richard Earnshaw <rearnsha@arm.com>
14349
14350 * config/aarch64/iterators.md (ALLI_TI): New iterator.
14351 * config/aarch64/aarch64.md (despeculate_copy<ALLI_TI:mode>): New
14352 expand.
14353 (despeculate_copy<ALLI:mode>_insn): New insn.
14354 (despeculate_copyti_insn): New insn.
14355 (despeculate_simple<ALLI:mode>): New insn
14356 (despeculate_simpleti): New insn.
14357 * config/aarch64/aarch64.c (aarch64_speculation_safe_value): New
14358 function.
14359 (TARGET_SPECULATION_SAFE_VALUE): Redefine to
14360 aarch64_speculation_safe_value.
14361 (aarch64_print_operand): Handle const0_rtx in modifier 'H'.
14362
14363 2018-07-31 Richard Earnshaw <rearnsha@arm.com>
14364
14365 * config/aarch64/aarch64-speculation.cc: New file.
14366 * config/aarch64/aarch64-passes.def (pass_track_speculation): Add
14367 before pass_reorder_blocks.
14368 * config/aarch64/aarch64-protos.h (make_pass_track_speculation): Add
14369 prototype.
14370 * config/aarch64/aarch64.c (aarch64_conditional_register_usage): Fix
14371 X14 and X15 when tracking speculation.
14372 * config/aarch64/aarch64.md (register name constants): Add
14373 SPECULATION_TRACKER_REGNUM and SPECULATION_SCRATCH_REGNUM.
14374 (unspec): Add UNSPEC_SPECULATION_TRACKER.
14375 (speculation_barrier): New insn attribute.
14376 (cmp<mode>): Allow SP in comparisons.
14377 (speculation_tracker): New insn.
14378 (speculation_barrier): Add speculation_barrier attribute.
14379 * config/aarch64/t-aarch64: Add make rule for aarch64-speculation.o.
14380 * config.gcc (aarch64*-*-*): Add aarch64-speculation.o to extra_objs.
14381 * doc/invoke.texi (AArch64 Options): Document -mtrack-speculation.
14382
14383 2018-07-31 Richard Earnshaw <rearnsha@arm.com>
14384
14385 * config/aarch64/aarch64.md (cb<optab><mode>1): Disable when
14386 aarch64_track_speculation is true.
14387 (tb<optab><mode>1): Likewise.
14388 * config/aarch64/aarch64.c (aarch64_split_compare_regs): Do not
14389 generate CB[N]Z when tracking speculation.
14390 (aarch64_split_compare_and_swap): Likewise.
14391 (aarch64_split_atomic_op): Likewise.
14392
14393 2018-07-31 Richard Earnshaw <rearnsha@arm.com>
14394
14395 * config/aarch64/aarch64.opt (mtrack-speculation): New target option.
14396
14397 2018-07-31 Richard Earnshaw <rearnsha@arm.com>
14398
14399 * config/aarch64.md (unspecv): Add UNSPECV_SPECULAION_BARRIER.
14400 (speculation_barrier): New insn.
14401
14402 2018-07-31 Richard Earnshaw <rearnsha@arm.com>
14403
14404 * config/arm/unspecs.md (unspecv): Add VUNSPEC_SPECULATION_BARRIER.
14405 * config/arm/arm.md (speculation_barrier): New expand.
14406 (speculation_barrier_insn): New pattern.
14407
14408 2018-07-31 Richard Earnshaw <rearnsha@arm.com>
14409
14410 * builtin-types.def (BT_FN_PTR_PTR_VAR): New function type.
14411 (BT_FN_I1_I1_VAR, BT_FN_I2_I2_VAR, BT_FN_I4_I4_VAR): Likewise.
14412 (BT_FN_I8_I8_VAR, BT_FN_I16_I16_VAR): Likewise.
14413 * builtin-attrs.def (ATTR_NOVOPS_NOTHROW_LEAF_LIST): New attribute
14414 list.
14415 * builtins.def (BUILT_IN_SPECULATION_SAFE_VALUE_N): New builtin.
14416 (BUILT_IN_SPECULATION_SAFE_VALUE_PTR): New internal builtin.
14417 (BUILT_IN_SPECULATION_SAFE_VALUE_1): Likewise.
14418 (BUILT_IN_SPECULATION_SAFE_VALUE_2): Likewise.
14419 (BUILT_IN_SPECULATION_SAFE_VALUE_4): Likewise.
14420 (BUILT_IN_SPECULATION_SAFE_VALUE_8): Likewise.
14421 (BUILT_IN_SPECULATION_SAFE_VALUE_16): Likewise.
14422 * builtins.c (expand_speculation_safe_value): New function.
14423 (expand_builtin): Call it.
14424 * doc/cpp.texi: Document predefine __HAVE_SPECULATION_SAFE_VALUE.
14425 * doc/extend.texi: Document __builtin_speculation_safe_value.
14426 * doc/md.texi: Document "speculation_barrier" pattern.
14427 * doc/tm.texi.in: Pull in TARGET_SPECULATION_SAFE_VALUE and
14428 TARGET_HAVE_SPECULATION_SAFE_VALUE.
14429 * doc/tm.texi: Regenerated.
14430 * target.def (have_speculation_safe_value, speculation_safe_value): New
14431 hooks.
14432 * targhooks.c (default_have_speculation_safe_value): New function.
14433 (default_speculation_safe_value): New function.
14434 * targhooks.h (default_have_speculation_safe_value): Add prototype.
14435 (default_speculation_safe_value): Add prototype.
14436
14437 2018-07-31 David Malcolm <dmalcolm@redhat.com>
14438
14439 * dump-context.h (dump_context::dump_loc): New decl.
14440 * dumpfile.c (dump_context::dump_loc): New member function.
14441 (dump_context::dump_gimple_stmt_loc): Reimplement using dump_loc
14442 and dump_gimple_stmt.
14443 (dump_context::dump_gimple_expr_loc): Likewise, using
14444 dump_gimple_expr.
14445 (dump_context::dump_generic_expr_loc): Likewise, using
14446 dump_generic_expr.
14447 (dump_context::dump_printf_loc_va): Likewise, using
14448 dump_printf_va.
14449 (dump_context::begin_scope): Explicitly using the global function
14450 "dump_loc", rather than the member function.
14451
14452 2018-07-31 Martin Sebor <msebor@redhat.com>
14453
14454 PR tree-optimization/86741
14455 * tree-vrp.c (vrp_prop::check_mem_ref): Avoid incomplete types.
14456
14457 2018-07-31 Andreas Krebbel <krebbel@linux.ibm.com>
14458
14459 * config/s390/s390.c (s390_expand_setmem): Make the unrolling to
14460 depend on whether prefetch instructions will be emitted or not.
14461 Use TARGET_SETMEM_PFD for checking whether prefetch instructions
14462 will be emitted or not.
14463 * config/s390/s390.h (TARGET_SETMEM_PREFETCH_DISTANCE)
14464 (TARGET_SETMEM_PFD): New macros.
14465
14466 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
14467
14468 * tree-vectorizer.h (stmt_vec_info): Turn back into a typedef.
14469 (NULL_STMT_VEC_INFO): Delete.
14470 (stmt_vec_info::operator*): Likewise.
14471 (stmt_vec_info::operator gimple *): Likewise.
14472 * tree-vect-loop.c (vectorizable_reduction): Use NULL instead
14473 of NULL_STMT_VEC_INFO.
14474 * tree-vect-patterns.c (vect_init_pattern_stmt): Likewise.
14475 (vect_reassociating_reduction_p): Likewise.
14476 * tree-vect-stmts.c (vect_build_gather_load_calls): Likewise.
14477 (vectorizable_store): Likewise.
14478 * tree-vectorizer.c (vec_info::set_vinfo_for_stmt): Likewise.
14479 (vec_info::free_stmt_vec_infos): Likewise.
14480
14481 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
14482
14483 * tree-vectorizer.h (vect_stmt_in_region_p): Delete.
14484 * tree-vectorizer.c (vect_stmt_in_region_p): Likewise.
14485
14486 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
14487
14488 * tree-vectorizer.h (vec_info::new_vinfo_for_stmt)
14489 (vec_info::set_vinfo_for_stmt, vec_info::free_stmt_vec_infos)
14490 (vec_info::free_stmt_vec_info): New private member functions.
14491 (set_stmt_vec_info_vec, free_stmt_vec_infos, vinfo_for_stmt)
14492 (set_vinfo_for_stmt, new_stmt_vec_info, free_stmt_vec_info): Delete.
14493 * tree-parloops.c (gather_scalar_reductions): Remove calls to
14494 set_stmt_vec_info_vec and free_stmt_vec_infos.
14495 * tree-vect-loop.c (_loop_vec_info): Remove call to
14496 set_stmt_vec_info_vec.
14497 * tree-vect-stmts.c (new_stmt_vec_info, set_stmt_vec_info_vec)
14498 (free_stmt_vec_infos, free_stmt_vec_info): Delete in favor of...
14499 * tree-vectorizer.c (vec_info::new_stmt_vec_info)
14500 (vec_info::set_vinfo_for_stmt, vec_info::free_stmt_vec_infos)
14501 (vec_info::free_stmt_vec_info): ...these new functions. Remove
14502 assignments in {vec_info::,}new_stmt_vec_info that are redundant
14503 with the clearing in the xcalloc.
14504 (stmt_vec_info_vec): Delete.
14505 (vec_info::vec_info): Don't call set_stmt_vec_info_vec.
14506 (vectorize_loops): Likewise.
14507 (vec_info::~vec_info): Remove argument from call to
14508 free_stmt_vec_infos.
14509 (vec_info::add_stmt): Remove vinfo argument from call to
14510 new_stmt_vec_info.
14511
14512 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
14513
14514 * tree-vectorizer.h (free_stmt_vec_info): Take a stmt_vec_info
14515 rather than a gimple stmt.
14516 * tree-vect-stmts.c (free_stmt_vec_info): Likewise. Don't free
14517 information for pattern statements when passed the original
14518 statement; instead wait to be passed the pattern statement itself.
14519 Don't call set_vinfo_for_stmt here.
14520 (free_stmt_vec_infos): Update call to free_stmt_vec_info.
14521 * tree-vect-loop.c (_loop_vec_info::~loop_vec_info): Don't free
14522 stmt_vec_infos here.
14523 * tree-vect-slp.c (_bb_vec_info::~bb_vec_info): Likewise.
14524 * tree-vectorizer.c (vec_info::remove_stmt): Nullify the statement's
14525 stmt_vec_infos entry.
14526
14527 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
14528
14529 * tree-vectorizer.h (vec_info::replace_stmt): Declare.
14530 * tree-vectorizer.c (vec_info::replace_stmt): New function.
14531 * tree-vect-slp.c (vect_remove_slp_scalar_calls): Use it.
14532 * tree-vect-stmts.c (vectorizable_call): Likewise.
14533 (vectorizable_simd_clone_call): Likewise.
14534
14535 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
14536
14537 * tree-vectorizer.h (vec_info::remove_stmt): Declare.
14538 * tree-vectorizer.c (vec_info::remove_stmt): New function.
14539 * tree-vect-loop-manip.c (vect_set_loop_condition): Use it.
14540 * tree-vect-loop.c (vect_transform_loop): Likewise.
14541 * tree-vect-slp.c (vect_schedule_slp): Likewise.
14542 * tree-vect-stmts.c (vect_remove_stores): Likewise.
14543
14544 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
14545
14546 * tree-vectorizer.h (vec_info::lookup_dr): New member function.
14547 (vect_dr_stmt): Delete.
14548 * tree-vectorizer.c (vec_info::lookup_dr): New function.
14549 * tree-vect-loop-manip.c (vect_update_inits_of_drs): Use it instead
14550 of DR_VECT_AUX.
14551 * tree-vect-data-refs.c (vect_analyze_possibly_independent_ddr)
14552 (vect_analyze_data_ref_dependence, vect_record_base_alignments)
14553 (vect_verify_datarefs_alignment, vect_peeling_supportable)
14554 (vect_analyze_data_ref_accesses, vect_prune_runtime_alias_test_list)
14555 (vect_analyze_data_refs): Likewise.
14556 (vect_slp_analyze_data_ref_dependence): Likewise. Take a vec_info
14557 argument.
14558 (vect_find_same_alignment_drs): Likewise.
14559 (vect_slp_analyze_node_dependences): Update calls accordingly.
14560 (vect_analyze_data_refs_alignment): Likewise. Use vec_info::lookup_dr
14561 instead of DR_VECT_AUX.
14562 (vect_get_peeling_costs_all_drs): Take a loop_vec_info instead
14563 of a vector data references. Use vec_info::lookup_dr instead of
14564 DR_VECT_AUX.
14565 (vect_peeling_hash_get_lowest_cost): Update calls accordingly.
14566 (vect_enhance_data_refs_alignment): Likewise. Use vec_info::lookup_dr
14567 instead of DR_VECT_AUX.
14568
14569 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
14570
14571 * tree-vectorizer.h (_loop_vec_info::unaligned_dr): Change to
14572 dr_vec_info.
14573 * tree-vect-data-refs.c (vect_enhance_data_refs_alignment): Update
14574 accordingly.
14575 * tree-vect-loop.c (vect_analyze_loop_2): Likewise.
14576 * tree-vect-loop-manip.c (get_misalign_in_elems): Likewise.
14577 (vect_gen_prolog_loop_niters): Likewise.
14578
14579 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
14580
14581 * tree-vectorizer.h (set_dr_misalignment, dr_misalignment)
14582 (DR_TARGET_ALIGNMENT, aligned_access_p, known_alignment_for_access_p)
14583 (vect_known_alignment_in_bytes, vect_dr_behavior)
14584 (vect_get_scalar_dr_size): Take references as dr_vec_infos
14585 instead of data_references. Update calls to other routines for
14586 which the same change has been made.
14587 * tree-vect-data-refs.c (vect_preserves_scalar_order_p): Take
14588 dr_vec_infos instead of stmt_vec_infos.
14589 (vect_analyze_data_ref_dependence): Update call accordingly.
14590 (vect_slp_analyze_data_ref_dependence)
14591 (vect_record_base_alignments): Use DR_VECT_AUX.
14592 (vect_calculate_target_alignment, vect_compute_data_ref_alignment)
14593 (vect_update_misalignment_for_peel, verify_data_ref_alignment)
14594 (vector_alignment_reachable_p, vect_get_data_access_cost)
14595 (vect_peeling_supportable, vect_analyze_group_access_1)
14596 (vect_analyze_group_access, vect_analyze_data_ref_access)
14597 (vect_vfa_segment_size, vect_vfa_access_size, vect_vfa_align)
14598 (vect_compile_time_alias, vect_small_gap_p)
14599 (vectorizable_with_step_bound_p, vect_duplicate_ssa_name_ptr_info):
14600 (vect_supportable_dr_alignment): Take references as dr_vec_infos
14601 instead of data_references. Update calls to other routines for
14602 which the same change has been made.
14603 (vect_verify_datarefs_alignment, vect_get_peeling_costs_all_drs)
14604 (vect_find_same_alignment_drs, vect_analyze_data_refs_alignment)
14605 (vect_slp_analyze_and_verify_node_alignment)
14606 (vect_analyze_data_ref_accesses, vect_prune_runtime_alias_test_list)
14607 (vect_create_addr_base_for_vector_ref, vect_create_data_ref_ptr)
14608 (vect_setup_realignment): Use dr_vec_infos. Update calls after
14609 above changes.
14610 (_vect_peel_info::dr): Replace with...
14611 (_vect_peel_info::dr_info): ...this new field.
14612 (vect_peeling_hash_get_most_frequent)
14613 (vect_peeling_hash_choose_best_peeling): Update accordingly.
14614 (vect_peeling_hash_get_lowest_cost):
14615 (vect_enhance_data_refs_alignment): Likewise. Update calls to other
14616 routines for which the same change has been made.
14617 (vect_peeling_hash_insert): Likewise. Take a dr_vec_info instead of a
14618 data_reference.
14619 * tree-vect-loop-manip.c (get_misalign_in_elems)
14620 (vect_gen_prolog_loop_niters): Use dr_vec_infos. Update calls after
14621 above changes.
14622 * tree-vect-loop.c (vect_analyze_loop_2): Likewise.
14623 * tree-vect-stmts.c (vect_get_store_cost, vect_get_load_cost)
14624 (vect_truncate_gather_scatter_offset, compare_step_with_zero)
14625 (get_group_load_store_type, get_negative_load_store_type)
14626 (vect_get_data_ptr_increment, vectorizable_store)
14627 (vectorizable_load): Likewise.
14628 (ensure_base_align): Take a dr_vec_info instead of a data_reference.
14629 Update calls to other routines for which the same change has been made.
14630
14631 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
14632
14633 * tree-vectorizer.h (vec_info::move_dr): New member function.
14634 (dataref_aux): Rename to...
14635 (dr_vec_info): ...this and add "dr" and "stmt" fields.
14636 (_stmt_vec_info::dr_aux): Update accordingly.
14637 (_stmt_vec_info::data_ref_info): Delete.
14638 (STMT_VINFO_GROUPED_ACCESS, DR_GROUP_FIRST_ELEMENT)
14639 (DR_GROUP_NEXT_ELEMENT, DR_GROUP_SIZE, DR_GROUP_STORE_COUNT)
14640 (DR_GROUP_GAP, DR_GROUP_SAME_DR_STMT, REDUC_GROUP_FIRST_ELEMENT):
14641 (REDUC_GROUP_NEXT_ELEMENT, REDUC_GROUP_SIZE): Use dr_aux.dr instead
14642 of data_ref.
14643 (STMT_VINFO_DATA_REF): Likewise. Turn into an lvalue.
14644 (STMT_VINFO_DR_INFO): New macro.
14645 (DR_VECT_AUX): Use STMT_VINFO_DR_INKFO and vect_dr_stmt.
14646 (set_dr_misalignment): Update after rename of dataref_aux.
14647 (vect_dr_stmt): Move earlier in file. Return dr_aux.stmt.
14648 * tree-vect-stmts.c (new_stmt_vec_info): Remove redundant
14649 initialization of STMT_VINFO_DATA_REF.
14650 * tree-vectorizer.c (vec_info::move_dr): New function.
14651 * tree-vect-patterns.c (vect_recog_bool_pattern)
14652 (vect_recog_mask_conversion_pattern)
14653 (vect_recog_gather_scatter_pattern): Use it.
14654 * tree-vect-data-refs.c (vect_analyze_data_refs): Initialize
14655 the "dr" and "stmt" fields of dr_vec_info instead of
14656 STMT_VINFO_DATA_REF.
14657
14658 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
14659
14660 * tree-vectorizer.h (_stmt_vec_info::pattern_stmt_p): New field.
14661 (is_pattern_stmt_p): Use it.
14662 * tree-vect-patterns.c (vect_init_pattern_stmt): Set pattern_stmt_p
14663 on pattern statements.
14664
14665 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
14666
14667 * tree-vect-patterns.c (vect_mark_pattern_stmts): Take the
14668 original stmt as a stmt_vec_info rather than a gimple stmt.
14669 (vect_pattern_recog_1): Take the statement directly as a
14670 stmt_vec_info, rather than via a gimple_stmt_iterator.
14671 Update call to vect_mark_pattern_stmts.
14672 (vect_pattern_recog): Update calls accordingly.
14673
14674 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
14675
14676 * tree-vectorizer.h (vect_get_vec_defs_for_stmt_copy)
14677 (vect_get_vec_def_for_stmt_copy): Take a vec_info rather than
14678 a vect_def_type for the first argument.
14679 * tree-vect-stmts.c (vect_get_vec_defs_for_stmt_copy): Likewise.
14680 (vect_get_vec_def_for_stmt_copy): Likewise. Return the original
14681 operand if it isn't defined by a vectorized statement.
14682 (vect_build_gather_load_calls): Remove the mask_dt argument and
14683 update calls to vect_get_vec_def_for_stmt_copy.
14684 (vectorizable_bswap): Likewise the dt argument.
14685 (vectorizable_call): Update calls to vectorizable_bswap and
14686 vect_get_vec_def_for_stmt_copy.
14687 (vectorizable_simd_clone_call, vectorizable_assignment)
14688 (vectorizable_shift, vectorizable_operation, vectorizable_condition)
14689 (vectorizable_comparison): Update calls to
14690 vect_get_vec_def_for_stmt_copy.
14691 (vectorizable_store): Likewise. Remove now-unnecessary calls to
14692 vect_is_simple_use.
14693 (vect_get_loop_based_defs): Remove dt argument and update call
14694 to vect_get_vec_def_for_stmt_copy.
14695 (vectorizable_conversion): Update calls to vect_get_loop_based_defs
14696 and vect_get_vec_def_for_stmt_copy.
14697 (vectorizable_load): Update calls to vect_build_gather_load_calls
14698 and vect_get_vec_def_for_stmt_copy.
14699 * tree-vect-loop.c (vect_create_epilog_for_reduction)
14700 (vectorizable_reduction, vectorizable_live_operation): Update calls
14701 to vect_get_vec_def_for_stmt_copy.
14702
14703 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
14704
14705 * tree-vect-data-refs.c (vect_record_base_alignment): Replace vec_info
14706 and gimple stmt arguments with a stmt_vec_info.
14707 (vect_record_base_alignments): Update calls accordingly.
14708 * tree-vect-slp.c (vect_record_max_nunits): Replace vec_info
14709 and gimple stmt arguments with a stmt_vec_info.
14710 (vect_build_slp_tree_1): Remove vinfo argument and update call
14711 to vect_record_max_nunits.
14712 (vect_build_slp_tree_2): Update calls to vect_build_slp_tree_1
14713 and vect_record_max_nunits.
14714
14715 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
14716
14717 * tree-vectorizer.h (nested_in_vect_loop_p): Move further down
14718 file and take a stmt_vec_info instead of a gimple stmt.
14719 (supportable_widening_operation, vect_finish_replace_stmt)
14720 (vect_finish_stmt_generation, vect_get_store_rhs)
14721 (vect_get_vec_def_for_operand_1, vect_get_vec_def_for_operand)
14722 (vect_get_vec_defs, vect_init_vector, vect_transform_stmt)
14723 (vect_remove_stores, vect_analyze_stmt, vectorizable_condition)
14724 (vect_get_smallest_scalar_type, vect_check_gather_scatter)
14725 (vect_create_data_ref_ptr, bump_vector_ptr)
14726 (vect_permute_store_chain, vect_setup_realignment)
14727 (vect_transform_grouped_load, vect_record_grouped_load_vectors)
14728 (vect_create_addr_base_for_vector_ref, vectorizable_live_operation)
14729 (vectorizable_reduction, vectorizable_induction)
14730 (get_initial_def_for_reduction, is_simple_and_all_uses_invariant)
14731 (vect_get_place_in_interleaving_chain): Take stmt_vec_infos rather
14732 than gimple stmts as arguments.
14733 * tree-vect-data-refs.c (vect_get_smallest_scalar_type)
14734 (vect_preserves_scalar_order_p, vect_slp_analyze_node_dependences)
14735 (can_group_stmts_p, vect_check_gather_scatter)
14736 (vect_create_addr_base_for_vector_ref, vect_create_data_ref_ptr)
14737 (bump_vector_ptr, vect_permute_store_chain, vect_setup_realignment)
14738 (vect_permute_load_chain, vect_shift_permute_load_chain)
14739 (vect_transform_grouped_load)
14740 (vect_record_grouped_load_vectors): Likewise.
14741 * tree-vect-loop.c (vect_fixup_reduc_chain)
14742 (get_initial_def_for_reduction, vect_create_epilog_for_reduction)
14743 (vectorize_fold_left_reduction, is_nonwrapping_integer_induction)
14744 (vectorizable_reduction, vectorizable_induction)
14745 (vectorizable_live_operation, vect_loop_kill_debug_uses): Likewise.
14746 * tree-vect-patterns.c (type_conversion_p, adjust_bool_stmts)
14747 (vect_get_load_store_mask): Likewise.
14748 * tree-vect-slp.c (vect_get_place_in_interleaving_chain)
14749 (vect_analyze_slp_instance, vect_mask_constant_operand_p): Likewise.
14750 * tree-vect-stmts.c (vect_mark_relevant)
14751 (is_simple_and_all_uses_invariant)
14752 (exist_non_indexing_operands_for_use_p, process_use)
14753 (vect_init_vector_1, vect_init_vector, vect_get_vec_def_for_operand_1)
14754 (vect_get_vec_def_for_operand, vect_get_vec_defs)
14755 (vect_finish_stmt_generation_1, vect_finish_replace_stmt)
14756 (vect_finish_stmt_generation, vect_truncate_gather_scatter_offset)
14757 (compare_step_with_zero, vect_get_store_rhs, get_group_load_store_type)
14758 (get_negative_load_store_type, get_load_store_type)
14759 (vect_check_load_store_mask, vect_check_store_rhs)
14760 (vect_build_gather_load_calls, vect_get_strided_load_store_ops)
14761 (vectorizable_bswap, vectorizable_call, vectorizable_simd_clone_call)
14762 (vect_create_vectorized_demotion_stmts, vectorizable_conversion)
14763 (vectorizable_assignment, vectorizable_shift, vectorizable_operation)
14764 (get_group_alias_ptr_type, vectorizable_store, hoist_defs_of_uses)
14765 (vectorizable_load, vectorizable_condition, vectorizable_comparison)
14766 (vect_analyze_stmt, vect_transform_stmt, vect_remove_stores)
14767 (supportable_widening_operation): Likewise.
14768
14769 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
14770
14771 * tree-vect-data-refs.c (vect_describe_gather_scatter_call): Take
14772 a stmt_vec_info instead of a gcall.
14773 (vect_check_gather_scatter): Update call accordingly.
14774 * tree-vect-loop-manip.c (iv_phi_p): Take a stmt_vec_info instead
14775 of a gphi.
14776 (vect_can_advance_ivs_p, vect_update_ivs_after_vectorizer)
14777 (slpeel_update_phi_nodes_for_loops):): Update calls accordingly.
14778 * tree-vect-loop.c (vect_transform_loop_stmt): Take a stmt_vec_info
14779 instead of a gimple stmt.
14780 (vect_transform_loop): Update calls accordingly.
14781 * tree-vect-slp.c (vect_split_slp_store_group): Take and return
14782 stmt_vec_infos instead of gimple stmts.
14783 (vect_analyze_slp_instance): Update use accordingly.
14784 * tree-vect-stmts.c (read_vector_array, write_vector_array)
14785 (vect_clobber_variable, vect_stmt_relevant_p, permute_vec_elements)
14786 (vect_use_strided_gather_scatters_p, vect_build_all_ones_mask)
14787 (vect_build_zero_merge_argument, vect_get_gather_scatter_ops)
14788 (vect_gen_widened_results_half, vect_get_loop_based_defs)
14789 (vect_create_vectorized_promotion_stmts, can_vectorize_live_stmts):
14790 Take a stmt_vec_info instead of a gimple stmt and pass stmt_vec_infos
14791 down to subroutines.
14792
14793 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
14794
14795 * tree-vect-loop.c (vect_analyze_scalar_cycles_1): Change the type
14796 of the worklist from a vector of gimple stmts to a vector of
14797 stmt_vec_infos.
14798 * tree-vect-stmts.c (vect_mark_relevant, process_use)
14799 (vect_mark_stmts_to_be_vectorized): Likewise
14800
14801 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
14802
14803 * tree-vect-loop.c (vect_analyze_loop_operations): Look up the
14804 statement before passing it to vect_analyze_stmt.
14805 (vect_create_epilog_for_reduction): Use a stmt_vec_info to walk
14806 the chain of phi vector definitions. Track the exit phi via its
14807 stmt_vec_info.
14808 (vectorizable_reduction): Set cond_stmt_vinfo directly from the
14809 STMT_VINFO_REDUC_DEF.
14810 * tree-vect-slp.c (vect_get_place_in_interleaving_chain): Use
14811 stmt_vec_infos to handle the statement chains.
14812 (vect_get_slp_defs): Record the first statement in the node
14813 using a stmt_vec_info.
14814 * tree-vect-stmts.c (vect_mark_stmts_to_be_vectorized): Look up
14815 statements here and pass their stmt_vec_info down to subroutines.
14816 (vect_init_vector_1): Hoist call to vinfo_for_stmt and pass it
14817 down to vect_finish_stmt_generation.
14818 (vect_init_vector, vect_get_vec_defs, vect_finish_replace_stmt)
14819 (vect_finish_stmt_generation): Call vinfo_for_stmt and pass
14820 stmt_vec_infos to subroutines.
14821 (vect_remove_stores): Use stmt_vec_infos to handle the statement
14822 chains.
14823
14824 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
14825
14826 * tree-vect-data-refs.c (vect_slp_analyze_node_dependences):
14827 (vect_check_gather_scatter, vect_create_data_ref_ptr, bump_vector_ptr)
14828 (vect_permute_store_chain, vect_setup_realignment)
14829 (vect_permute_load_chain, vect_shift_permute_load_chain)
14830 (vect_transform_grouped_load): Use stmt_vec_info rather than gimple
14831 stmts internally, and when passing values to other vectorizer routines.
14832 * tree-vect-loop-manip.c (vect_can_advance_ivs_p): Likewise.
14833 * tree-vect-loop.c (vect_analyze_scalar_cycles_1)
14834 (vect_analyze_loop_operations, get_initial_def_for_reduction)
14835 (vect_create_epilog_for_reduction, vectorize_fold_left_reduction)
14836 (vectorizable_reduction, vectorizable_induction)
14837 (vectorizable_live_operation, vect_transform_loop_stmt)
14838 (vect_transform_loop): Likewise.
14839 * tree-vect-patterns.c (vect_reassociating_reduction_p)
14840 (vect_recog_widen_op_pattern, vect_recog_mixed_size_cond_pattern)
14841 (vect_recog_bool_pattern, vect_recog_gather_scatter_pattern): Likewise.
14842 * tree-vect-slp.c (vect_analyze_slp_instance): Likewise.
14843 (vect_slp_analyze_node_operations_1): Likewise.
14844 * tree-vect-stmts.c (vect_mark_relevant, process_use)
14845 (exist_non_indexing_operands_for_use_p, vect_init_vector_1)
14846 (vect_mark_stmts_to_be_vectorized, vect_get_vec_def_for_operand)
14847 (vect_finish_stmt_generation_1, get_group_load_store_type)
14848 (get_load_store_type, vect_build_gather_load_calls)
14849 (vectorizable_bswap, vectorizable_call, vectorizable_simd_clone_call)
14850 (vect_create_vectorized_demotion_stmts, vectorizable_conversion)
14851 (vectorizable_assignment, vectorizable_shift, vectorizable_operation)
14852 (vectorizable_store, vectorizable_load, vectorizable_condition)
14853 (vectorizable_comparison, vect_analyze_stmt, vect_transform_stmt)
14854 (supportable_widening_operation): Likewise.
14855 (vect_get_vector_types_for_stmt): Likewise.
14856 * tree-vectorizer.h (vect_dr_behavior): Likewise.
14857
14858 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
14859
14860 * tree-vect-data-refs.c (vect_analyze_data_ref_dependence)
14861 (vect_slp_analyze_node_dependences, vect_analyze_data_ref_accesses)
14862 (vect_permute_store_chain, vect_permute_load_chain)
14863 (vect_shift_permute_load_chain, vect_transform_grouped_load): Avoid
14864 repeated stmt_vec_info lookups.
14865 * tree-vect-loop-manip.c (vect_can_advance_ivs_p): Likewise.
14866 (vect_update_ivs_after_vectorizer): Likewise.
14867 * tree-vect-loop.c (vect_is_simple_reduction): Likewise.
14868 (vect_create_epilog_for_reduction, vectorizable_reduction): Likewise.
14869 * tree-vect-patterns.c (adjust_bool_stmts): Likewise.
14870 * tree-vect-slp.c (vect_analyze_slp_instance): Likewise.
14871 (vect_bb_slp_scalar_cost): Likewise.
14872 * tree-vect-stmts.c (get_group_alias_ptr_type): Likewise.
14873
14874 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
14875
14876 * tree-vect-data-refs.c (vect_check_gather_scatter): Pass the
14877 gcall rather than the generic gimple stmt to gimple_call_internal_fn.
14878 (vect_get_smallest_scalar_type, can_group_stmts_p): Use dyn_cast
14879 to get gassigns and gcalls, rather than operating on generc gimple
14880 stmts.
14881 * tree-vect-stmts.c (exist_non_indexing_operands_for_use_p)
14882 (vect_mark_stmts_to_be_vectorized, vectorizable_store)
14883 (vectorizable_load, vect_analyze_stmt): Likewise.
14884 * tree-vect-loop.c (vectorizable_reduction): Likewise gphi.
14885
14886 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
14887
14888 * tree-vectorizer.h (get_earlier_stmt, get_later_stmt): Take and
14889 return stmt_vec_infos rather than gimple stmts. Do not accept
14890 null arguments.
14891 (vect_find_last_scalar_stmt_in_slp): Return a stmt_vec_info instead
14892 of a gimple stmt.
14893 * tree-vect-slp.c (vect_find_last_scalar_stmt_in_slp): Likewise.
14894 Update use of get_later_stmt.
14895 (vect_get_constant_vectors): Update call accordingly.
14896 (vect_schedule_slp_instance): Likewise
14897 * tree-vect-data-refs.c (vect_slp_analyze_node_dependences): Likewise.
14898 (vect_slp_analyze_instance_dependence): Likewise.
14899 (vect_preserves_scalar_order_p): Update use of get_earlier_stmt.
14900
14901 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
14902
14903 * tree-vectorizer.h (stmt_info_for_cost::stmt): Replace with...
14904 (stmt_info_for_cost::stmt_info): ...this new field.
14905 (add_stmt_costs): Update accordingly.
14906 * tree-vect-loop.c (vect_compute_single_scalar_iteration_cost)
14907 (vect_get_known_peeling_cost): Likewise.
14908 (vect_estimate_min_profitable_iters): Likewise.
14909 * tree-vect-stmts.c (record_stmt_cost): Likewise.
14910
14911 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
14912
14913 * tree-vectorizer.h (_loop_vec_info::may_misalign_stmts): Change
14914 from an auto_vec<gimple *> to an auto_vec<stmt_vec_info>.
14915 * tree-vect-data-refs.c (vect_enhance_data_refs_alignment): Update
14916 accordingly.
14917 * tree-vect-loop-manip.c (vect_create_cond_for_align_checks): Likewise.
14918
14919 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
14920
14921 * tree-vectorizer.h (_stmt_vec_info::same_dr_stmt): Change from
14922 a gimple stmt to a stmt_vec_info.
14923 * tree-vect-stmts.c (vectorizable_load): Update accordingly.
14924
14925 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
14926
14927 * tree-vectorizer.h (vec_info::grouped_stores): Change from
14928 an auto_vec<gimple *> to an auto_vec<stmt_vec_info>.
14929 (_loop_vec_info::reduction_chains): Likewise.
14930 * tree-vect-loop.c (vect_fixup_scalar_cycles_with_patterns): Update
14931 accordingly.
14932 * tree-vect-slp.c (vect_analyze_slp): Likewise.
14933
14934 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
14935
14936 * tree-vectorizer.h (_stmt_vec_info::first_element): Change from
14937 a gimple stmt to a stmt_vec_info.
14938 (_stmt_vec_info::next_element): Likewise.
14939 * tree-vect-data-refs.c (vect_update_misalignment_for_peel)
14940 (vect_slp_analyze_and_verify_node_alignment)
14941 (vect_analyze_group_access_1, vect_analyze_group_access)
14942 (vect_small_gap_p, vect_prune_runtime_alias_test_list)
14943 (vect_create_data_ref_ptr, vect_record_grouped_load_vectors)
14944 (vect_supportable_dr_alignment): Update accordingly.
14945 * tree-vect-loop.c (vect_fixup_reduc_chain): Likewise.
14946 (vect_fixup_scalar_cycles_with_patterns, vect_is_slp_reduction)
14947 (vect_is_simple_reduction, vectorizable_reduction): Likewise.
14948 * tree-vect-patterns.c (vect_reassociating_reduction_p): Likewise.
14949 * tree-vect-slp.c (vect_build_slp_tree_1)
14950 (vect_attempt_slp_rearrange_stmts, vect_supported_load_permutation_p)
14951 (vect_split_slp_store_group, vect_analyze_slp_instance)
14952 (vect_analyze_slp, vect_transform_slp_perm_load): Likewise.
14953 * tree-vect-stmts.c (vect_model_store_cost, vect_model_load_cost)
14954 (get_group_load_store_type, get_load_store_type)
14955 (get_group_alias_ptr_type, vectorizable_store, vectorizable_load)
14956 (vect_transform_stmt, vect_remove_stores): Likewise.
14957
14958 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
14959
14960 * tree-vectorizer.h (vect_dr_stmt): Return a stmt_vec_info rather
14961 than a gimple stmt.
14962 * tree-vect-data-refs.c (vect_analyze_data_ref_dependence)
14963 (vect_slp_analyze_data_ref_dependence, vect_record_base_alignments)
14964 (vect_calculate_target_alignmentm, vect_compute_data_ref_alignment)
14965 (vect_update_misalignment_for_peel, vect_verify_datarefs_alignment)
14966 (vector_alignment_reachable_p, vect_get_data_access_cost)
14967 (vect_get_peeling_costs_all_drs, vect_peeling_hash_get_lowest_cost)
14968 (vect_peeling_supportable, vect_enhance_data_refs_alignment)
14969 (vect_find_same_alignment_drs, vect_analyze_data_refs_alignment)
14970 (vect_analyze_group_access_1, vect_analyze_group_access)
14971 (vect_analyze_data_ref_access, vect_analyze_data_ref_accesses)
14972 (vect_vfa_access_size, vect_small_gap_p, vect_analyze_data_refs)
14973 (vect_supportable_dr_alignment): Remove vinfo_for_stmt from the
14974 result of vect_dr_stmt and use the stmt_vec_info instead of
14975 the associated gimple stmt.
14976 * tree-vect-loop-manip.c (get_misalign_in_elems): Likewise.
14977 (vect_gen_prolog_loop_niters): Likewise.
14978 * tree-vect-loop.c (vect_analyze_loop_2): Likewise.
14979
14980 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
14981
14982 * tree-vectorizer.h (_slp_tree::stmts): Change from a vec<gimple *>
14983 to a vec<stmt_vec_info>.
14984 * tree-vect-slp.c (vect_free_slp_tree): Update accordingly.
14985 (vect_create_new_slp_node): Take a vec<gimple *> instead of a
14986 vec<stmt_vec_info>.
14987 (_slp_oprnd_info::def_stmts): Change from a vec<gimple *>
14988 to a vec<stmt_vec_info>.
14989 (bst_traits::value_type, bst_traits::value_type): Likewise.
14990 (bst_traits::hash): Update accordingly.
14991 (vect_get_and_check_slp_defs): Change the stmts parameter from
14992 a vec<gimple *> to a vec<stmt_vec_info>.
14993 (vect_two_operations_perm_ok_p, vect_build_slp_tree_1): Likewise.
14994 (vect_build_slp_tree): Likewise.
14995 (vect_build_slp_tree_2): Likewise. Update uses of
14996 SLP_TREE_SCALAR_STMTS.
14997 (vect_print_slp_tree): Update uses of SLP_TREE_SCALAR_STMTS.
14998 (vect_mark_slp_stmts, vect_mark_slp_stmts_relevant)
14999 (vect_slp_rearrange_stmts, vect_attempt_slp_rearrange_stmts)
15000 (vect_supported_load_permutation_p, vect_find_last_scalar_stmt_in_slp)
15001 (vect_detect_hybrid_slp_stmts, vect_slp_analyze_node_operations_1)
15002 (vect_slp_analyze_node_operations, vect_slp_analyze_operations)
15003 (vect_bb_slp_scalar_cost, vect_slp_analyze_bb_1)
15004 (vect_get_constant_vectors, vect_get_slp_defs)
15005 (vect_transform_slp_perm_load, vect_schedule_slp_instance)
15006 (vect_remove_slp_scalar_calls, vect_schedule_slp): Likewise.
15007 (vect_analyze_slp_instance): Build up a vec of stmt_vec_infos
15008 instead of gimple stmts.
15009 * tree-vect-data-refs.c (vect_slp_analyze_node_dependences): Change
15010 the stores parameter for a vec<gimple *> to a vec<stmt_vec_info>.
15011 (vect_slp_analyze_instance_dependence): Update uses of
15012 SLP_TREE_SCALAR_STMTS.
15013 (vect_slp_analyze_and_verify_node_alignment): Likewise.
15014 (vect_slp_analyze_and_verify_instance_alignment): Likewise.
15015 * tree-vect-loop.c (neutral_op_for_slp_reduction): Likewise.
15016 (get_initial_defs_for_reduction): Likewise.
15017 (vect_create_epilog_for_reduction): Likewise.
15018 (vectorize_fold_left_reduction): Likewise.
15019 * tree-vect-stmts.c (vect_prologue_cost_for_slp_op): Likewise.
15020 (vect_model_simple_cost, vectorizable_shift, vectorizable_load)
15021 (can_vectorize_live_stmts): Likewise.
15022
15023 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
15024
15025 * tree-vectorizer.h (_loop_vec_info::reductions): Change from an
15026 auto_vec<gimple *> to an auto_vec<stmt_vec_info>.
15027 (vect_force_simple_reduction): Take and return stmt_vec_infos rather
15028 than gimple stmts.
15029 * tree-parloops.c (valid_reduction_p): Take a stmt_vec_info instead
15030 of a gimple stmt.
15031 (gather_scalar_reductions): Update after above interface changes.
15032 * tree-vect-loop.c (vect_analyze_scalar_cycles_1): Likewise.
15033 (vect_is_simple_reduction): Take and return stmt_vec_infos rather
15034 than gimple stmts.
15035 (vect_force_simple_reduction): Likewise.
15036 * tree-vect-patterns.c (vect_pattern_recog_1): Update use of
15037 LOOP_VINFO_REDUCTIONS.
15038 * tree-vect-slp.c (vect_analyze_slp_instance): Likewise.
15039
15040 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
15041
15042 * tree-vectorizer.h (_stmt_vec_info::reduc_def): Change from
15043 a gimple stmt to a stmt_vec_info.
15044 * tree-vect-loop.c (vect_active_double_reduction_p)
15045 (vect_force_simple_reduction, vectorizable_reduction): Update
15046 accordingly.
15047
15048 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
15049
15050 * tree-vectorizer.h (_slp_tree::vec_stmts): Change from a
15051 vec<gimple *> to a vec<stmt_vec_info>.
15052 * tree-vect-loop.c (vect_create_epilog_for_reduction): Change
15053 the reduction_phis argument from a vec<gimple *> to a
15054 vec<stmt_vec_info>.
15055 (vectorizable_reduction): Likewise the phis local variable that
15056 is passed to vect_create_epilog_for_reduction. Update for new type
15057 of SLP_TREE_VEC_STMTS.
15058 (vectorizable_induction): Update for new type of SLP_TREE_VEC_STMTS.
15059 (vectorizable_live_operation): Likewise.
15060 * tree-vect-slp.c (vect_get_slp_vect_defs): Likewise.
15061 (vect_transform_slp_perm_load, vect_schedule_slp_instance): Likewise.
15062
15063 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
15064
15065 * tree-vectorizer.h (_stmt_vec_info::vectorized_stmt): Change from
15066 a gimple stmt to a stmt_vec_info.
15067 (vectorizable_condition, vectorizable_live_operation)
15068 (vectorizable_reduction, vectorizable_induction): Pass back the
15069 vectorized statement as a stmt_vec_info.
15070 * tree-vect-data-refs.c (vect_record_grouped_load_vectors): Update
15071 use of STMT_VINFO_VEC_STMT.
15072 * tree-vect-loop.c (vect_create_epilog_for_reduction): Likewise,
15073 accumulating the inner phis that feed the STMT_VINFO_VEC_STMT
15074 as stmt_vec_infos rather than gimple stmts.
15075 (vectorize_fold_left_reduction): Change vec_stmt from a gimple stmt
15076 to a stmt_vec_info.
15077 (vectorizable_live_operation): Likewise.
15078 (vectorizable_reduction, vectorizable_induction): Likewise,
15079 updating use of STMT_VINFO_VEC_STMT.
15080 * tree-vect-stmts.c (vect_get_vec_def_for_operand_1): Update use
15081 of STMT_VINFO_VEC_STMT.
15082 (vect_build_gather_load_calls, vectorizable_bswap, vectorizable_call)
15083 (vectorizable_simd_clone_call, vectorizable_conversion)
15084 (vectorizable_assignment, vectorizable_shift, vectorizable_operation)
15085 (vectorizable_store, vectorizable_load, vectorizable_condition)
15086 (vectorizable_comparison, can_vectorize_live_stmts): Change vec_stmt
15087 from a gimple stmt to a stmt_vec_info.
15088 (vect_transform_stmt): Update use of STMT_VINFO_VEC_STMT. Pass a
15089 pointer to a stmt_vec_info to the vectorizable_* routines.
15090
15091 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
15092
15093 * tree-vectorizer.h (_stmt_vec_info::related_stmt): Change from
15094 a gimple stmt to a stmt_vec_info.
15095 (is_pattern_stmt_p): Update accordingly.
15096 * tree-vect-data-refs.c (vect_preserves_scalar_order_p): Likewise.
15097 (vect_record_grouped_load_vectors): Likewise.
15098 * tree-vect-loop.c (vect_determine_vf_for_stmt): Likewise.
15099 (vect_fixup_reduc_chain, vect_update_vf_for_slp): Likewise.
15100 (vect_model_reduction_cost): Likewise.
15101 (vect_create_epilog_for_reduction): Likewise.
15102 (vectorizable_reduction, vectorizable_induction): Likewise.
15103 * tree-vect-patterns.c (vect_init_pattern_stmt): Likewise.
15104 Return the stmt_vec_info for the pattern statement.
15105 (vect_set_pattern_stmt): Update use of STMT_VINFO_RELATED_STMT.
15106 (vect_split_statement, vect_mark_pattern_stmts): Likewise.
15107 * tree-vect-slp.c (vect_detect_hybrid_slp_stmts): Likewise.
15108 (vect_detect_hybrid_slp, vect_get_slp_defs): Likewise.
15109 * tree-vect-stmts.c (vect_mark_relevant): Likewise.
15110 (vect_get_vec_def_for_operand_1, vectorizable_call): Likewise.
15111 (vectorizable_simd_clone_call, vect_analyze_stmt, new_stmt_vec_info)
15112 (free_stmt_vec_info, vect_is_simple_use): Likewise.
15113
15114 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
15115
15116 * tree-vectorizer.h (vect_finish_replace_stmt): Return a stmt_vec_info
15117 (vect_finish_stmt_generation): Likewise.
15118 * tree-vect-stmts.c (vect_finish_stmt_generation_1): Likewise.
15119 (vect_finish_replace_stmt, vect_finish_stmt_generation): Likewise.
15120 (vect_build_gather_load_calls): Use the return value of the above
15121 functions instead of a separate call to vinfo_for_stmt. Use narrow
15122 scopes for the input gimple stmt and wider scopes for the associated
15123 stmt_vec_info. Use vec_info::lookup_def when setting these
15124 stmt_vec_infos from an SSA_NAME definition.
15125 (vectorizable_bswap, vectorizable_call, vectorizable_simd_clone_call)
15126 (vect_create_vectorized_demotion_stmts, vectorizable_conversion)
15127 (vectorizable_assignment, vectorizable_shift, vectorizable_operation)
15128 (vectorizable_store, vectorizable_load, vectorizable_condition)
15129 (vectorizable_comparison): Likewise.
15130 * tree-vect-loop.c (vectorize_fold_left_reduction): Likewise.
15131 (vectorizable_reduction): Likewise.
15132
15133 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
15134
15135 * tree-vectorizer.h (vect_is_simple_use): Add an optional
15136 stmt_vec_info * parameter before the optional gimple **.
15137 * tree-vect-stmts.c (vect_is_simple_use): Likewise.
15138 (process_use, vect_get_vec_def_for_operand_1): Update callers.
15139 (vect_get_vec_def_for_operand, vectorizable_shift): Likewise.
15140 * tree-vect-loop.c (vectorizable_reduction): Likewise.
15141 (vectorizable_live_operation): Likewise.
15142 * tree-vect-patterns.c (type_conversion_p): Likewise.
15143 (vect_look_through_possible_promotion): Likewise.
15144 (vect_recog_rotate_pattern): Likewise.
15145 * tree-vect-slp.c (vect_get_and_check_slp_defs): Likewise.
15146
15147 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
15148
15149 * tree-vectorizer.h (stmt_vec_info): Temporarily change from
15150 a typedef to a wrapper class.
15151 (NULL_STMT_VEC_INFO): New macro.
15152 (vec_info::stmt_infos): Change to vec<stmt_vec_info>.
15153 (stmt_vec_info::operator*): New function.
15154 (stmt_vec_info::operator gimple *): Likewise.
15155 (set_vinfo_for_stmt): Use NULL_STMT_VEC_INFO.
15156 (add_stmt_costs): Likewise.
15157 * tree-vect-loop-manip.c (iv_phi_p): Likewise.
15158 * tree-vect-loop.c (vect_compute_single_scalar_iteration_cost)
15159 (vect_get_known_peeling_cost): Likewise.
15160 (vect_estimate_min_profitable_iters): Likewise.
15161 * tree-vect-patterns.c (vect_init_pattern_stmt): Likewise.
15162 * tree-vect-slp.c (vect_remove_slp_scalar_calls): Likewise.
15163 * tree-vect-stmts.c (vect_build_gather_load_calls): Likewise.
15164 (vectorizable_store, free_stmt_vec_infos): Likewise.
15165 (new_stmt_vec_info): Change return type of xcalloc to
15166 _stmt_vec_info *.
15167
15168 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
15169
15170 * tree-vectorizer.h (vec_info::lookup_single_use): Declare.
15171 * tree-vectorizer.c (vec_info::lookup_single_use): New function.
15172 * tree-vect-loop.c (vectorizable_reduction): Use it instead of
15173 a single_imm_use-based sequence.
15174 * tree-vect-stmts.c (supportable_widening_operation): Likewise.
15175
15176 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
15177
15178 * tree-vectorizer.h (vec_info::lookup_def): Declare.
15179 * tree-vectorizer.c (vec_info::lookup_def): New function.
15180 * tree-vect-patterns.c (vect_get_internal_def): Use it.
15181 (vect_widened_op_tree): Likewise.
15182 * tree-vect-stmts.c (vect_is_simple_use): Likewise.
15183 * tree-vect-loop.c (vect_analyze_loop_operations): Likewise.
15184 (vectorizable_reduction): Likewise.
15185 (vect_valid_reduction_input_p): Take a stmt_vec_info instead
15186 of a gimple *.
15187 (vect_is_slp_reduction): Update calls accordingly. Use
15188 vec_info::lookup_def.
15189 (vect_is_simple_reduction): Likewise
15190 * tree-vect-slp.c (vect_detect_hybrid_slp_1): Use vec_info::lookup_def.
15191
15192 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
15193
15194 * tree-vectorizer.h (vec_info::lookup_stmt): Declare.
15195 * tree-vectorizer.c (vec_info::lookup_stmt): New function.
15196 * tree-vect-loop.c (vect_determine_vf_for_stmt): Use it instead
15197 of vinfo_for_stmt.
15198 (vect_determine_vectorization_factor, vect_analyze_scalar_cycles_1)
15199 (vect_compute_single_scalar_iteration_cost, vect_analyze_loop_form)
15200 (vect_update_vf_for_slp, vect_analyze_loop_operations)
15201 (vect_is_slp_reduction, vectorizable_induction)
15202 (vect_transform_loop_stmt, vect_transform_loop): Likewise.
15203 * tree-vect-patterns.c (vect_init_pattern_stmt):
15204 (vect_determine_min_output_precision_1, vect_determine_precisions)
15205 (vect_pattern_recog): Likewise.
15206 * tree-vect-stmts.c (vect_analyze_stmt, vect_transform_stmt): Likewise.
15207 * config/powerpcspe/powerpcspe.c (rs6000_density_test): Likewise.
15208 * config/rs6000/rs6000.c (rs6000_density_test): Likewise.
15209 * tree-vect-slp.c (vect_detect_hybrid_slp_stmts): Likewise.
15210 (vect_detect_hybrid_slp_1, vect_detect_hybrid_slp_2)
15211 (vect_detect_hybrid_slp): Likewise. Change the walk_stmt_info
15212 info field from a loop to a loop_vec_info.
15213
15214 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
15215
15216 * tree-vectorizer.h (stmt_vec_info): Move typedef earlier in file.
15217 (vec_info::add_stmt): Declare.
15218 * tree-vectorizer.c (vec_info::add_stmt): New function.
15219 * tree-vect-data-refs.c (vect_create_data_ref_ptr): Use it.
15220 * tree-vect-loop.c (_loop_vec_info::_loop_vec_info): Likewise.
15221 (vect_create_epilog_for_reduction, vectorizable_reduction): Likewise.
15222 (vectorizable_induction): Likewise.
15223 * tree-vect-slp.c (_bb_vec_info::_bb_vec_info): Likewise.
15224 * tree-vect-stmts.c (vect_finish_stmt_generation_1): Likewise.
15225 (vectorizable_simd_clone_call, vectorizable_store): Likewise.
15226 (vectorizable_load): Likewise.
15227 * tree-vect-patterns.c (vect_init_pattern_stmt): Likewise.
15228 (vect_recog_bool_pattern, vect_recog_mask_conversion_pattern)
15229 (vect_recog_gather_scatter_pattern): Likewise.
15230 (append_pattern_def_seq): Likewise. Remove a check that is
15231 performed by add_stmt itself.
15232
15233 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
15234
15235 * tree-vect-loop.c (vectorizable_reduction): Fix an instance in
15236 which make_ssa_name was called with new_stmt before new_stmt
15237 had been created.
15238
15239 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
15240
15241 * tree-vect-loop.c (vect_valid_reduction_input_p): New function,
15242 split out from...
15243 (vect_is_slp_reduction): ...here...
15244 (vect_is_simple_reduction): ...and here. Remove repetition of tests
15245 that are already known to be false.
15246
15247 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
15248
15249 * tree-vectorizer.h (vect_free_slp_instance): Add a final_p parameter.
15250 * tree-vect-slp.c (vect_free_slp_tree): Likewise. Don't update
15251 STMT_VINFO_NUM_SLP_USES when it's true.
15252 (vect_free_slp_instance): Add a final_p parameter and pass it to
15253 vect_free_slp_tree.
15254 (vect_build_slp_tree_2): Update call to vect_free_slp_instance.
15255 (vect_analyze_slp_instance): Likewise.
15256 (vect_slp_analyze_operations): Likewise.
15257 (vect_slp_analyze_bb_1): Likewise.
15258 * tree-vectorizer.c (vec_info): Likewise.
15259 * tree-vect-loop.c (vect_transform_loop): Likewise.
15260
15261 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
15262
15263 * tree-vect-loop.c (vectorizable_reduction): Assert that the
15264 function is not called for second and subsequent members of
15265 a reduction group.
15266
15267 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
15268
15269 * tree-vect-loop.c (get_initial_def_for_reduction): Move special
15270 cases for nested loops from here to ...
15271 (vect_create_epilog_for_reduction): ...here. Only call
15272 vect_is_simple_use for inner-loop reductions.
15273
15274 2018-07-31 Martin Liska <mliska@suse.cz>
15275
15276 PR gcov-profile/85338
15277 PR gcov-profile/85350
15278 PR gcov-profile/85372
15279 * profile.c (struct location_triplet): New.
15280 (struct location_triplet_hash): Likewise.
15281 (output_location): Do not output a BB that
15282 is already recorded for a line.
15283 (branch_prob): Use streamed_locations.
15284
15285 2018-07-31 Martin Liska <mliska@suse.cz>
15286
15287 PR gcov-profile/85370
15288 * coverage.c (coverage_begin_function): Do not mark target
15289 clones as artificial functions.
15290
15291 2018-07-31 Martin Liska <mliska@suse.cz>
15292
15293 PR gcov-profile/83813
15294 PR gcov-profile/84758
15295 PR gcov-profile/85217
15296 PR gcov-profile/85332
15297 * profile.c (branch_prob): Do not record GOTO expressions
15298 for GIMPLE statements which locations are already streamed.
15299
15300 2018-07-31 Olivier Hainque <hainque@adacore.com>
15301
15302 * gcc.c (handle_spec_function): Accept a soft_matched_part
15303 argument, as do_spec_1. Pass it down to ...
15304 (eval_spec_function): Accept a soft_matched_part argument,
15305 and pass it down to ...
15306 (do_spec_2): Accept a soft_matched_part argument, and pass
15307 it down to do_spec_1.
15308 (do_spec_1): Pass soft_matched_part to handle_spec_function.
15309 (handle_braces): Update call to handle_spec_function.
15310 (driver::set_up_specs): Update calls to do_spec_2.
15311 (compare_debug_dump_opt_spec_function): Likewise.
15312 (compare_debug_self_opt_spec_function): Likewise.
15313
15314 2018-07-31 Olivier Hainque <hainque@adacore.com>
15315
15316 * common.opt (nolibc): New option.
15317 * doc/invoke.texi (Link Options): Document it.
15318 * gcc.c (LINK_GCC_C_SEQUENCE_SPEC): Honor nolibc.
15319 * config/alpha/linux.h: Likewise.
15320 * config/arc/elf.h: Likewise.
15321 * config/arm/uclinux-elf.h: Likewise.
15322 * config/arm/unknown-elf.h: Likewise.
15323 * config/avr/avrlibc.h: Likewise.
15324 * config/bfin/bfin.h: Likewise.
15325 * config/bfin/linux.h: Likewise.
15326 * config/bfin/uclinux.h: Likewise.
15327 * config/darwin.h: Likewise.
15328 * config/darwin10.h: Likewise.
15329 * config/darwin12.h: Likewise.
15330 * config/gnu-user.h: Likewise.
15331 * config/lm32/uclinux-elf.h: Likewise.
15332 * config/pa/pa-hpux11.h: Likewise.
15333 * config/pa/pa64-hpux.h: Likewise.
15334 * config/sparc/sparc.h: Likewise.
15335
15336 2018-07-31 Olivier Hainque <hainque@adacore.com>
15337
15338 * gcc.c (getenv_spec_function): Prepend '/' to value for allowed
15339 undefined variables.
15340
15341 2018-07-30 Segher Boessenkool <segher@kernel.crashing.org>
15342
15343 PR target/86640
15344 * config/arm/arm.c (arm_block_set_aligned_vect): Use gen_int_mode
15345 instead of GEN_INT.
15346
15347 2018-07-30 Bernd Edlinger <bernd.edlinger@hotmail.de>
15348
15349 * tree-ssa-forwprop.c (simplify_builtin_call): Don't create a not NUL
15350 terminated string literal.
15351
15352 2018-07-30 Segher Boessenkool <segher@kernel.crashing.org>
15353
15354 PR rtl-optimization/85160
15355 * combine.c (is_just_move): New function.
15356 (try_combine): Allow combining two instructions into two if neither of
15357 the original instructions was a move.
15358
15359 2018-07-30 Alexander Monakov <amonakov@ispras.ru>
15360
15361 PR target/86673
15362 * doc/extend.texi (Global Register Variables): Discourage use of type
15363 qualifiers.
15364 (Local Register Variables): Likewise.
15365
15366 2018-07-30 Richard Sandiford <richard.sandiford@arm.com>
15367
15368 PR tree-optimization/86506
15369 * hwint.h (ceil_log2): Resync with hwint.c implementation.
15370
15371 2018-07-30 Ilya Leoshkevich <iii@linux.ibm.com>
15372
15373 PR target/86547
15374 * lra-constraints.c (spill_hard_reg_in_range): When selecting the
15375 hard_regno, make sure no insn between `from` and `to` clobbers it.
15376
15377 2018-07-30 Cesar Philippidis <cesar@codesourcery.com>
15378 Tom de Vries <tdevries@suse.de>
15379
15380 * config/nvptx/nvptx.c (PTX_GANG_DEFAULT): Rename to ...
15381 (PTX_DEFAULT_RUNTIME_DIM): ... this.
15382 (nvptx_goacc_validate_dims): Set default worker and gang dims to
15383 PTX_DEFAULT_RUNTIME_DIM.
15384 (nvptx_dim_limit): Ignore GOMP_DIM_WORKER.
15385
15386 2018-07-29 John David Anglin <danglin@gcc.gnu.org>
15387
15388 * config/pa/pa.c (pa_output_addr_vec): Align address table.
15389 * config/pa/pa.h (JUMP_TABLES_IN_TEXT_SECTION): Revise comment.
15390 * config/pa/pa32-linux.h (JUMP_TABLES_IN_TEXT_SECTION): Define.
15391
15392 2018-07-27 Michael Meissner <meissner@linux.ibm.com>
15393
15394 * config/rs6000/constraints.md (wG constraint): Delete, no longer
15395 used.
15396 * config/rs6000/predicates.md (p9_fusion_reg_operand): Rename
15397 predicate to reflect toc fusion has been deleted.
15398 (toc_fusion_mem_raw): Delete, no longer used.
15399 (toc_fusion_mem_wrapped): Likewise.
15400 * config/rs6000/rs6000-cpus.def (POWERPC_MASKS): Delete toc
15401 fusion mask bit.
15402 * config/rs6000/rs6000-protos.h (fusion_wrap_memory_address):
15403 Delete, no longer used.
15404 * config/rs6000/rs6000.c (struct rs6000_reg_addr): Delete fields
15405 meant to be used for toc fusion.
15406 (rs6000_debug_print_mode): Delete toc fusion debugging.
15407 (rs6000_debug_reg_global): Likewise.
15408 (rs6000_init_hard_regno_mode_ok): Delete setting up fields for toc
15409 fusion and secondary reload support that were never used.
15410 (rs6000_option_override_internal): Delete TOC fusion, that was only
15411 partially defined, and it did not work unless you also used the
15412 -mcmodel= switch.
15413 (rs6000_legitimate_address_p): Delete TOC fusion support.
15414 (rs6000_opt_masks): Likewise.
15415 (fusion_wrap_memory_address): Delete function, no longer used.
15416 (fusion_split_address); Delete TOC fusion support.
15417 * config/rs6000/rs6000.h (TARGET_TOC_FUSION_INT): Delete, no
15418 longer used with toc fusion being deleted.
15419 (TARGET_TOC_FUSION_FP): Likewise.
15420 * config/rs6000/rs6000.md (UNSPEC_FUSION_ADDIS): Delete TOC fusion
15421 UNSPEC.
15422 (toc fusion spliter): Delete TOC fusion support.
15423 (toc_fusionload_<mode>): Likewise.
15424 (toc_fusionload_di): Likewise.
15425 (fusion_gpr_load_<mode>): Delete generator function, this insn no
15426 longer needs to be named. Rename predicate to delete TOC fusion.
15427 (fusion_gpr_<P:mode>_<GPR_FUSION:mode>_load): Likewise.
15428 (fusion_gpr_<P:mode>_<GPR_FUSION:mode>_store): Likewise.
15429 (fusion_vsx_<P:mode>_<GPR_FUSION:mode>_load): Likewise.
15430 (fusion_vsx_<P:mode>_<GPR_FUSION:mode>_store): Likewise.
15431 (p9 fusion peephole2s): Rename predicate to delete TOC fusion.
15432
15433 2018-07-27 Kelvin Nilsen <kelvin@gcc.gnu.org>
15434
15435 * doc/extend.texi (Basic PowerPC Built-in Functions Available on
15436 ISA 2.05): Replace __uint128_t with __uint128 and __int128_t with
15437 __int128 in built-in function prototypes.
15438 (PowerPC AltiVec Built-in Functions on ISA 2.07): Likewise.
15439 (PowerPC AltiVec Built-in Functions on ISA 3.0): Likewise.
15440
15441 2018-07-27 Martin Sebor <msebor@redhat.com>
15442
15443 PR tree-optimization/86696
15444 * tree-ssa-strlen.c (get_min_string_length): Handle all integer
15445 types, including enums.
15446 (handle_char_store): Be prepared for the above function to fail.
15447
15448 2018-07-26 Qing Zhao <qing.zhao@oracle.com>
15449
15450 * builtins.c (inline_expand_builtin_string_cmp): Disable inlining
15451 when optimization level is lower than 2 or optimize for size.
15452
15453 2018-07-26 Martin Sebor <msebor@redhat.com>
15454
15455 PR tree-optimization/86043
15456 PR tree-optimization/86042
15457 * tree-ssa-strlen.c (handle_builtin_memcpy): Handle strict overlaps.
15458 (get_string_cst_length): Rename...
15459 (get_min_string_length): ...to this. Add argument.
15460 (handle_char_store): Extend to handle multi-character stores by
15461 MEM_REF.
15462 * tree.c (initializer_zerop): Use new argument. Handle MEM_REF.
15463 * tree.h (initializer_zerop): Add argument.
15464
15465 2018-07-26 Jakub Jelinek <jakub@redhat.com>
15466
15467 PR middle-end/86660
15468 * omp-low.c (scan_sharing_clauses): Don't ignore map clauses for
15469 declare target to variables if they have always,{to,from,tofrom} map
15470 kinds.
15471
15472 2018-07-26 Martin Liska <mliska@suse.cz>
15473
15474 PR lto/86548
15475 * lto-wrapper.c: Add linker_output as prefix
15476 for ltrans_output_file.
15477
15478 2018-07-26 Segher Boessenkool <segher@kernel.crashing.org>
15479
15480 PR rtl-optimization/85805
15481 * combine.c (reg_nonzero_bits_for_combine): Only use the last set
15482 value for hard registers if that was written in the same mode.
15483
15484 2018-07-26 Martin Liska <mliska@suse.cz>
15485
15486 PR gcov-profile/86536
15487 * gcov.c (format_gcov): Use printf format %.*f directly
15488 and do not handle special values.
15489
15490 2018-07-25 Claudiu Zissulescu <claziss@synopsys.com>
15491
15492 * common/config/arc/arc-common.c (arc_option_optimization_table):
15493 Update default optimizations for size.
15494
15495 2018-07-25 Claudiu Zissulescu <claziss@synopsys.com>
15496
15497 * config/arc/arc.md (movsf_insn): Add short instruction selection.
15498 * config/arc/constraints.md (CfZ): New constraint.
15499 * config/arc/fpu.md (addssf3_fpu): Use CfZ constraint.
15500 (subsf3_fpu): Likewise.
15501 (cmpsf_fpu): Likewise.
15502 (cmpsf_fpu_uneq): Likewise.
15503
15504 2018-07-25 Claudiu Zissulescu <claziss@synopsys.com>
15505
15506 * config/arc/arc.c (compact_memory_operand_p): Check for uncached
15507 accesses as well.
15508 (arc_is_uncached_mem_p): uncached applies to both the variable and
15509 the pointer.
15510
15511 2018-07-25 Claudiu Zissulescu <claziss@synopsys.com>
15512
15513 * config/arc/arc.h (ADDITIONAL_REGISTER_NAMES): Add additional
15514 register names.
15515
15516 2018-07-25 David Malcolm <dmalcolm@redhat.com>
15517
15518 * optinfo-emit-json.cc (class optrecord_json_writer): Convert
15519 field "m_scopes" from vec to auto_vec.
15520
15521 2018-07-25 Martin Liska <mliska@suse.cz>
15522
15523 * config/powerpcspe/powerpcspe-protos.h (rs6000_loop_align): Fix
15524 return type.
15525
15526 2018-07-25 Richard Biener <rguenther@suse.de>
15527
15528 PR debug/86654
15529 * dwarf2out.c (dwarf2out_decl): Do not handle nested functions
15530 special wrt context_die late.
15531 (gen_subprogram_die): Re-use DIEs in local scope.
15532
15533 2018-07-25 Richard Sandiford <richard.sandiford@arm.com>
15534
15535 PR tree-optimization/86644
15536 * hwint.c (ceil_log2): Fix comment. Return 0 for 0.
15537
15538 2018-07-25 Martin Liska <mliska@suse.cz>
15539
15540 PR middle-end/86645
15541 * dumpfile.c: And excluded values with TDF_ALL_VALUES.
15542 * dumpfile.h (enum dump_flag): Defince TDF_ALL_VALUES.
15543
15544 2018-07-25 Martin Liska <mliska@suse.cz>
15545
15546 PR sanitizer/79635
15547 * params.def: Explain ASan abbreviation and provide
15548 a documentation link.
15549
15550 2018-07-24 Martin Sebor <msebor@redhat.com>
15551
15552 PR tree-optimization/86622
15553 PR tree-optimization/86532
15554 * builtins.h (string_length): Declare.
15555 * builtins.c (c_strlen): Correct handling of non-constant offsets.
15556 (check_access): Be prepared for non-constant length ranges.
15557 (string_length): Make extern.
15558 * expr.c (string_constant): Only handle the minor non-constant
15559 array index. Use string_constant to compute the length of
15560 a generic string constant.
15561
15562 2018-07-24 Richard Sandiford <richard.sandiford@arm.com>
15563
15564 PR tree-optimization/86618
15565 * tree-vect-stmts.c (vectorizable_call): Don't take the address
15566 of LOOP_VINFO_MASKS (loop_vinfo) when loop_vinfo is null.
15567
15568 2018-07-24 David Malcolm <dmalcolm@redhat.com>
15569
15570 PR tree-optimization/86636
15571 * json.cc (json::object::set): Fix comment. Add assertions.
15572 (json::array::append): Move here from json.h. Add comment and an
15573 assertion.
15574 (json::string::string): Likewise.
15575 * json.h (json::array::append): Move to json.cc.
15576 (json::string::string): Likewise.
15577 * optinfo-emit-json.cc
15578 (optrecord_json_writer::impl_location_to_json): Assert that we
15579 aren't attempting to write out UNKNOWN_LOCATION, or an ad-hoc
15580 wrapper around it. Expand the location once, rather than three
15581 times.
15582 (optrecord_json_writer::inlining_chain_to_json): Fix the check for
15583 UNKNOWN_LOCATION, to use LOCATION_LOCUS to look through ad-hoc
15584 wrappers.
15585 (optrecord_json_writer::optinfo_to_json): Likewise, in four
15586 places. Fix some overlong lines.
15587
15588 2018-07-24 Matthew Malcomson <matthew.malcomson@arm.com>
15589
15590 * config/aarch64/aarch64-simd.md
15591 (aarch64_<ANY_EXTEND:su><ADDSUB:optab>w<mode>): Split into...
15592 (aarch64_<ANY_EXTEND:su>subw<mode>): ... This...
15593 (aarch64_<ANY_EXTEND:su>addw<mode>): ... And this.
15594 (aarch64_<ANY_EXTEND:su><ADDSUB:optab>w<mode>_internal): Split into...
15595 (aarch64_<ANY_EXTEND:su>subw<mode>_internal): ... This...
15596 (aarch64_<ANY_EXTEND:su>addw<mode>_internal): ... And this.
15597 (aarch64_<ANY_EXTEND:su><ADDSUB:optab>w2<mode>_internal): Split into...
15598 (aarch64_<ANY_EXTEND:su>subw2<mode>_internal): ... This...
15599 (aarch64_<ANY_EXTEND:su>addw2<mode>_internal): ... And this.
15600
15601 2018-07-24 Jakub Jelinek <jakub@redhat.com>
15602
15603 PR middle-end/86627
15604 * expmed.c (expand_divmod): Punt if d == HOST_WIDE_INT_MIN
15605 and size > HOST_BITS_PER_WIDE_INT. For size > HOST_BITS_PER_WIDE_INT
15606 and abs_d == d, do the power of two handling if profitable.
15607
15608 2018-07-24 Richard Biener <rguenther@suse.de>
15609
15610 * match.pd: Add BIT_FIELD_REF canonicalizations.
15611
15612 2018-07-23 Bernd Edlinger <bernd.edlinger@hotmail.de>
15613
15614 PR c/86617
15615 * genmatch.c (dt_operand::gen_match_op): Avoid folding volatile values.
15616
15617 2018-07-23 Bernd Edlinger <bernd.edlinger@hotmail.de>
15618
15619 * gimple-fold.c (gimple_fold_builtin_printf): Don't create a not NUL
15620 terminated STRING_CST object.
15621
15622 2018-07-23 Bernd Edlinger <bernd.edlinger@hotmail.de>
15623
15624 hsa-dump.c (dump_hsa_symbol): Avoid out of scope access to buf.
15625
15626 2018-07-23 Segher Boessenkool <segher@kernel.crashing.org>
15627
15628 * config/rs6000/rs6000-p8swap.c (rtx_is_swappable_p): Adjust.
15629 * config/rs6000/rs6000-protos.h (rs6000_split_v4si_init): Delete.
15630 * config/rs6000/rs6000.c (rs6000_expand_vector_init): Always force
15631 the elements into a register.
15632 (rs6000_split_v4si_init_di_reg): Delete.
15633 (rs6000_split_v4si_init): Delete.
15634 * config/rs6000/vsx.md (unspec): Delete UNSPEC_VSX_VEC_INIT.
15635 (vsx_init_v4si): Rewrite as a define_expand.
15636
15637 2018-07-23 Segher Boessenkool <segher@kernel.crashing.org>
15638
15639 * config/rs6000/rs6000.md (splitters for rldimi and rlwimi with the
15640 zero_extend argument from memory): New.
15641
15642 2018-07-22 Martin Sebor <msebor@redhat.com>
15643
15644 PR bootstrap/86621
15645 * gimple-ssa-warn-alloca.c (alloca_call_type_by_arg): Avoid
15646 diagnosing calls with unknown arguments unless -Walloca-larger-than
15647 is restricted to less than PTRDIFF_MAX bytes.
15648
15649 2018-07-22 Gerald Pfeifer <gerald@pfeifer.com>
15650
15651 * doc/gcov.texi (Invoking Gcov): Editorial changes.
15652
15653 2018-07-20 David Malcolm <dmalcolm@redhat.com>
15654
15655 * pretty-print.c (text_info::set_location): Remove redundant
15656 "line_table" parameter from call to rich_location::set_range.
15657
15658 2018-07-20 Martin Sebor <msebor@redhat.com>
15659
15660 PR middle-end/82063
15661 * builtins.c (expand_builtin_alloca): Adjust.
15662 * calls.c (alloc_max_size): Simplify.
15663 * cgraphunit.c (cgraph_node::expand): Adjust.
15664 * common.opt (larger_than_size, warn_frame_larger_than): Remove
15665 variables.
15666 (frame_larger_than_size): Same.
15667 (-Wframe-larger-than, -Wlarger-than, -Wstack-usage): Change options
15668 to take a HOST_WIDE_INT argument and accept a byte-size suffix.
15669 Initialize.
15670 * doc/invoke.texi (GCC Command Options): Document option arguments.
15671 Explain byte-size arguments and suffixes.
15672 (-Wvla-larger-than, -Wno-alloc-size-larger-than): Update.
15673 (-Wno-alloca-larger-than, -Wno-vla-larger-than): Same.
15674 (-Wframe-larger-than, -Wlarger-than, -Wstack-usage): Same.
15675 * doc/options.texi (UInteger): Expand.
15676 (Host_Wide_Int, ByteSize): Document new properties.
15677 * final.c (final_start_function_1): Include sizes in an error message.
15678 * function.c (frame_offset_overflow): Same.
15679 * gimple-ssa-warn-alloca.c (pass_walloca::gate): Adjust.
15680 (alloca_call_type_by_arg): Change function argument to HOST_WIDE_INT.
15681 Diagnose unbounded alloca calls only for limits of less than
15682 PTRDIFF_MAX.
15683 (alloca_call_type): Adjust. Diagnose possibly out-of-bounds alloca
15684 calls and VLA size only for limits of less than PTRDIFF_MAX. Same
15685 for alloca(0).
15686 (pass_walloca::execute): Adjust. Diagnose alloca calls in loops
15687 only for limits of less than PTRDIFF_MAX.
15688 * langhooks-def.h (lhd_handle_option): Change function argument
15689 to HOST_WIDE_INT.
15690 * langhooks.c (lhd_handle_option): Same.
15691 * langhooks.h (handle_option): Same.
15692 * opt-functions.awk (switch_bit_fields): Handle Host_Wide_Int and
15693 ByteSize flags.
15694 (var_type, var_type_struct): Same.
15695 (var_set): Handle ByteSize flag.
15696 * optc-gen.awk: Add comments to output to ease debugging. Make
15697 use of HOST_WIDE_INT where appropriate.
15698 * opts-gen-save.awk: Use %lx to format unsigned long.
15699 * opth-gen.awk: Change function argument to HOST_WIDE_INT.
15700 * opts-common.c (integral_argument): Return HOST_WIDE_INT and add
15701 arguments. Parse bytes-size suffixes.
15702 (enum_arg_to_value): Change function argument to HOST_WIDE_INT.
15703 (enum_value_to_arg): Same.
15704 (decode_cmdline_option): Handle cl_host_wide_int. Adjust.
15705 (handle_option): Adjust.
15706 (generate_option): Change function argument to HOST_WIDE_INT.
15707 (cmdline_handle_error): Adjust.
15708 (read_cmdline_option): Change function argument to HOST_WIDE_INT.
15709 (set_option): Change function argument to HOST_WIDE_INT.
15710 (option_enabled): Handle cl_host_wide_int.
15711 (get_option_state): Handle CLVC_SIZE.
15712 (control_warning_option): Same.
15713 * opts.c (common_handle_option): Change function argument to
15714 HOST_WIDE_INT. Remove handling of OPT_Walloca_larger_than_ and
15715 OPT_Wvla_larger_than_.
15716 * opts.h (enum cl_var_type): Add an enumerator.
15717 * stor-layout.c (layout_decl): Print a more meaningful warning.
15718 * toplev.c (output_stack_usage): Adjust.
15719
15720 2018-07-20 Qing Zhao <qing.zhao@oracle.com>
15721
15722 * builtins.c (expand_builtin_memcmp): Delete the last parameter for
15723 call to inline_expand_builtin_string_cmp.
15724 (expand_builtin_strcmp): Likewise.
15725 (expand_builtin_strncmp): Likewise.
15726 (inline_string_cmp): Delete the last parameter, change char_type_node
15727 to unsigned_char_type_node for strcmp/strncmp, add conversions to the
15728 two operands.
15729 (inline_expand_builtin_string_cmp): Delete the last parameter, give up
15730 the inlining expansion on target where the type of the call has same or
15731 narrower precision than unsigned char.
15732
15733 2018-07-20 David Malcolm <dmalcolm@redhat.com>
15734
15735 * Makefile.in (OBJS): Add json.o and optinfo-emit-json.o.
15736 (CFLAGS-optinfo-emit-json.o): Define TARGET_NAME.
15737 * common.opt (fsave-optimization-record): New option.
15738 * coretypes.h (struct kv_pair): Move here from dumpfile.c.
15739 * doc/invoke.texi (-fsave-optimization-record): New option.
15740 * dumpfile.c: Include "optinfo-emit-json.h".
15741 (struct kv_pair): Move to coretypes.h.
15742 (optgroup_options): Make non-static.
15743 (dump_context::end_scope): Call
15744 optimization_records_maybe_pop_dump_scope.
15745 * dumpfile.h (optgroup_options): New decl.
15746 * json.cc: New file.
15747 * json.h: New file.
15748 * optinfo-emit-json.cc: New file.
15749 * optinfo-emit-json.h: New file.
15750 * optinfo.cc: Include "optinfo-emit-json.h".
15751 (optinfo::emit): Call optimization_records_maybe_record_optinfo.
15752 (optinfo_enabled_p): Check optimization_records_enabled_p.
15753 (optinfo_wants_inlining_info_p): Likewise.
15754 * optinfo.h: Update comment.
15755 * profile-count.c (profile_quality_as_string): New function.
15756 * profile-count.h (profile_quality_as_string): New decl.
15757 (profile_count::quality): New accessor.
15758 * selftest-run-tests.c (selftest::run_tests): Call json_cc_tests
15759 and optinfo_emit_json_cc_tests.
15760 * selftest.h (selftest::json_cc_tests): New decl.
15761 (selftest::optinfo_emit_json_cc_tests): New decl.
15762 * toplev.c: Include "optinfo-emit-json.h".
15763 (compile_file): Call optimization_records_finish.
15764 (do_compile): Call optimization_records_start.
15765 * tree-ssa-live.c: Include optinfo.h.
15766 (remove_unused_scope_block_p): Retain inlining information if
15767 optinfo_wants_inlining_info_p returns true.
15768
15769 2018-07-20 Richard Biener <rguenther@suse.de>
15770
15771 PR debug/86585
15772 * dwarf2out.c (dwarf2out_die_ref_for_decl): Test in_lto_p
15773 to cover -flto-partition=none.
15774
15775 2018-07-20 Martin Liska <mliska@suse.cz>
15776
15777 * tree.h (DECL_LOCATION_RANGE): Remove unused macro.
15778 (get_decl_source_range): Remove unused function.
15779
15780 2018-07-20 Richard Biener <rguenther@suse.de>
15781
15782 * tree-ssa-sccvn.h (struct vn_nary_op_s): Add next member.
15783 (struct vn_phi_s): Likewise.
15784 (struct vn_reference_s): Likewise.
15785 * tree-ssa-sccvn.c (vn_nary_op_hasher::equal): Add shortcut
15786 for searching the slot of an entry known to be in the hash itself.
15787 (vn_phi_hasher::equal): Likewise.
15788 (vn_reference_hasher::equal): Likewise.
15789 (last_inserted_ref, last_inserted_phi, last_inserted_nary): New
15790 globals.
15791 (optimistic_info, current_info): Remove, keeping only valid_info.
15792 (vn_reference_lookup_1): Remove fallback lookup.
15793 (vn_reference_lookup_2): Likewise.
15794 (vn_nary_op_lookup_1): Likewise.
15795 (vn_phi_lookup): Likewise.
15796 (vn_nary_build_or_lookup_1): Make sure to not chain the built
15797 hash element.
15798 (vn_reference_insert): Adjust, chain the inserted hash element
15799 at last_inserted_ref.
15800 (vn_reference_insert_pieces): Likewise.
15801 (visit_reference_op_call): Likewise.
15802 (vn_nary_op_insert_into): Chain the inserted hash element at
15803 last_inserted_nary.
15804 (vn_nary_op_insert_pieces): Adjust.
15805 (vn_nary_op_insert): Likewise.
15806 (vn_nary_op_insert_stmt): Likewise.
15807 (vn_phi_insert): Adjust, chain the inserted hash element at
15808 last_inserted_phi.
15809 (process_scc): Remove clearing and copying the optimistic
15810 table. Instead remove elements inserted during an optimistic
15811 iteration from the single table we maintain.
15812 (init_scc_vn): Adjust.
15813 (free_scc_vn): Likewise.
15814 (sccvn_dom_walker::record_cond): Likewise.
15815 (sccvn_dom_walker::after_dom_children): Likewise.
15816
15817 2018-07-19 Martin Sebor <msebor@redhat.com>
15818
15819 PR tree-optimization/84047
15820 PR tree-optimization/83776
15821 * tree-vrp.c (vrp_prop::check_mem_ref): New function.
15822 (check_array_bounds): Call it.
15823
15824 2018-07-19 Martin Sebor <msebor@redhat.com>
15825
15826 * align.h (align_flags): Use member initialization.
15827
15828 2018-07-19 David Malcolm <dmalcolm@redhat.com>
15829
15830 * Makefile.in (OBJS): Add optinfo.o.
15831 * coretypes.h (class symtab_node): New forward decl.
15832 (struct cgraph_node): New forward decl.
15833 (class varpool_node): New forward decl.
15834 * dump-context.h: New file.
15835 * dumpfile.c: Include "optinfo.h", "dump-context.h", "cgraph.h",
15836 "tree-pass.h".
15837 (refresh_dumps_are_enabled): Use optinfo_enabled_p.
15838 (set_dump_file): Call dumpfile_ensure_any_optinfo_are_flushed.
15839 (set_alt_dump_file): Likewise.
15840 (dump_context::~dump_context): New dtor.
15841 (dump_gimple_stmt): Move implementation to...
15842 (dump_context::dump_gimple_stmt): ...this new member function.
15843 Add the stmt to any pending optinfo, creating one if need be.
15844 (dump_gimple_stmt_loc): Move implementation to...
15845 (dump_context::dump_gimple_stmt_loc): ...this new member function.
15846 Start a new optinfo and add the stmt to it.
15847 (dump_gimple_expr): Move implementation to...
15848 (dump_context::dump_gimple_expr): ...this new member function.
15849 Add the stmt to any pending optinfo, creating one if need be.
15850 (dump_gimple_expr_loc): Move implementation to...
15851 (dump_context::dump_gimple_expr_loc): ...this new member function.
15852 Start a new optinfo and add the stmt to it.
15853 (dump_generic_expr): Move implementation to...
15854 (dump_context::dump_generic_expr): ...this new member function.
15855 Add the tree to any pending optinfo, creating one if need be.
15856 (dump_generic_expr_loc): Move implementation to...
15857 (dump_context::dump_generic_expr_loc): ...this new member
15858 function. Add the tree to any pending optinfo, creating one if
15859 need be.
15860 (dump_printf): Move implementation to...
15861 (dump_context::dump_printf_va): ...this new member function. Add
15862 the text to any pending optinfo, creating one if need be.
15863 (dump_printf_loc): Move implementation to...
15864 (dump_context::dump_printf_loc_va): ...this new member function.
15865 Start a new optinfo and add the stmt to it.
15866 (dump_dec): Move implementation to...
15867 (dump_context::dump_dec): ...this new member function. Add the
15868 value to any pending optinfo, creating one if need be.
15869 (dump_context::dump_symtab_node): New member function.
15870 (dump_context::get_scope_depth): New member function.
15871 (dump_context::begin_scope): New member function.
15872 (dump_context::end_scope): New member function.
15873 (dump_context::ensure_pending_optinfo): New member function.
15874 (dump_context::begin_next_optinfo): New member function.
15875 (dump_context::end_any_optinfo): New member function.
15876 (dump_context::s_current): New global.
15877 (dump_context::s_default): New global.
15878 (dump_scope_depth): Delete global.
15879 (dumpfile_ensure_any_optinfo_are_flushed): New function.
15880 (dump_symtab_node): New function.
15881 (get_dump_scope_depth): Reimplement in terms of dump_context.
15882 (dump_begin_scope): Likewise.
15883 (dump_end_scope): Likewise.
15884 (selftest::temp_dump_context::temp_dump_context): New ctor.
15885 (selftest::temp_dump_context::~temp_dump_context): New dtor.
15886 (selftest::verify_item): New function.
15887 (ASSERT_IS_TEXT): New macro.
15888 (ASSERT_IS_TREE): New macro.
15889 (ASSERT_IS_GIMPLE): New macro.
15890 (selftest::test_capture_of_dump_calls): New test.
15891 (selftest::dumpfile_c_tests): Call it.
15892 * dumpfile.h (dump_printf, dump_printf_loc, dump_basic_block)
15893 (dump_generic_expr_loc, dump_generic_expr, dump_gimple_stmt_loc)
15894 (dump_gimple_stmt, dump_dec): Gather these related decls and add a
15895 descriptive comment.
15896 (dump_function, print_combine_total_stats, enable_rtl_dump_file)
15897 (dump_node, dump_bb): Move these unrelated decls.
15898 (class dump_manager): Add leading comment.
15899 * optinfo.cc: New file.
15900 * optinfo.h: New file.
15901
15902 2018-07-19 Michael Collison <michael.collison@arm.com>
15903 Richard Henderson <rth@redhat.com>
15904
15905 * config/aarch64/aarch64.md (subv<GPI>4, usubv<GPI>4): New patterns.
15906 (subti): Handle op1 zero.
15907 (subvti4, usub4ti4): New.
15908 (*sub<GPI>3_compare1_imm): New.
15909 (sub<GPI>3_carryinCV): New.
15910 (*sub<GPI>3_carryinCV_z1_z2, *sub<GPI>3_carryinCV_z1): New.
15911 (*sub<GPI>3_carryinCV_z2, *sub<GPI>3_carryinCV): New.
15912
15913 2018-07-19 Michael Collison <michael.collison@arm.com>
15914 Richard Henderson <rth@redhat.com>
15915
15916 * config/aarch64/aarch64.md: (addv<GPI>4, uaddv<GPI>4): New.
15917 (addti3): Create simpler code if low part is already known to be 0.
15918 (addvti4, uaddvti4): New.
15919 (*add<GPI>3_compareC_cconly_imm): New.
15920 (*add<GPI>3_compareC_cconly): New.
15921 (*add<GPI>3_compareC_imm): New.
15922 (*add<GPI>3_compareC): Rename from add<GPI>3_compare1; do not
15923 handle constants within this pattern..
15924 (*add<GPI>3_compareV_cconly_imm): New.
15925 (*add<GPI>3_compareV_cconly): New.
15926 (*add<GPI>3_compareV_imm): New.
15927 (add<GPI>3_compareV): New.
15928 (add<GPI>3_carryinC, add<GPI>3_carryinV): New.
15929 (*add<GPI>3_carryinC_zero, *add<GPI>3_carryinV_zero): New.
15930 (*add<GPI>3_carryinC, *add<GPI>3_carryinV): New.
15931 ((*add<GPI>3_compareC_cconly_imm): Replace 'ne' operator
15932 with 'comparison' operator.
15933 (*add<GPI>3_compareV_cconly_imm): Ditto.
15934 (*add<GPI>3_compareV_cconly): Ditto.
15935 (*add<GPI>3_compareV_imm): Ditto.
15936 (add<GPI>3_compareV): Ditto.
15937 (add<mode>3_carryinC): Ditto.
15938 (*add<mode>3_carryinC_zero): Ditto.
15939 (*add<mode>3_carryinC): Ditto.
15940 (add<mode>3_carryinV): Ditto.
15941 (*add<mode>3_carryinV_zero): Ditto.
15942 (*add<mode>3_carryinV): Ditto.
15943
15944 2018-07-19 Michael Collison <michael.collison@arm.com>
15945 Richard Henderson <rth@redhat.com>
15946
15947 * config/aarch64/aarch64-modes.def (CC_V): New.
15948 * config/aarch64/aarch64-protos.h
15949 (aarch64_addti_scratch_regs): Declare
15950 (aarch64_subvti_scratch_regs): Declare.
15951 (aarch64_expand_subvti): Declare.
15952 (aarch64_gen_unlikely_cbranch): Declare
15953 * config/aarch64/aarch64.c (aarch64_select_cc_mode): Test
15954 for signed overflow using CC_Vmode.
15955 (aarch64_get_condition_code_1): Handle CC_Vmode.
15956 (aarch64_gen_unlikely_cbranch): New function.
15957 (aarch64_addti_scratch_regs): New function.
15958 (aarch64_subvti_scratch_regs): New function.
15959 (aarch64_expand_subvti): New function.
15960
15961 2018-07-19 Andre Vieira <andre.simoesdiasvieira@arm.com>
15962
15963 * config/aarch64/aarch64-option-extensions.def: New entry for profile
15964 extension.
15965 * config/aarch64/aarch64.h (AARCH64_FL_PROFILE): New.
15966 * doc/invoke.texi (aarch64-feature-modifiers): New entry for profile
15967 extension.
15968
15969 2018-07-19 Andre Vieira <andre.simoesdiasvieira@arm.com>
15970
15971 PR target/83009
15972 * config/aarch64/predicates.md (aarch64_mem_pair_lanes_operand): Make
15973 address check not strict.
15974
15975 2018-07-19 Andre Vieira <andre.simoesdiasvieira@arm.com>
15976
15977 * config/aarch64/aarch64-simd.md (aarch64_simd_mov<VQ:mode>): Replace
15978 Umq with Umn.
15979 (store_pair_lanes<mode>): Likewise.
15980 * config/aarch64/aarch64-protos.h (aarch64_addr_query_type): Add new
15981 enum value 'ADDR_QUERY_LDP_STP_N'.
15982 * config/aarch64/aarch64.c (aarch64_addr_query_type): Likewise.
15983 (aarch64_print_address_internal): Add declaration.
15984 (aarch64_print_ldpstp_address): Remove.
15985 (aarch64_classify_address): Adapt mode for 'ADDR_QUERY_LDP_STP_N'.
15986 (aarch64_print_operand): Change printing of 'y'.
15987 * config/aarch64/predicates.md (aarch64_mem_pair_lanes_operand): Use
15988 new enum value 'ADDR_QUERY_LDP_STP_N', don't hardcode mode and use
15989 'true' rather than '1'.
15990 * config/aarch64/constraints.md (Uml): Likewise.
15991 (Uml): Rename to Umn.
15992 (Umq): Remove.
15993
15994 2018-07-19 Richard Biener <rguenther@suse.de>
15995
15996 * tree-ssa-sccvn.h (struct vn_phi_s): Make phiargs member
15997 a trailing array.
15998 * tree-ssa-sccvn.c: Remove alloc-pool.h use.
15999 (vn_phi_hasher): Derive from nofree_ptr_hash and remove remove method.
16000 (vn_reference_hasher): Likewise.
16001 (struct vn_tables_s): Remove obstack and alloc-pool members.
16002 (vn_tables_obstack, vn_tables_insert_obstack): New global obstacks.
16003 (vn_nary_build_or_lookup_1): Manually build in vn_tables_insert_obstack.
16004 (vn_reference_insert): Allocate from obstack instead of from alloc-pool.
16005 (vn_reference_insert_pieces): Likewise.
16006 (alloc_vn_nary_op_noinit): Adjust.
16007 (vn_nary_op_insert_stmt): Allocate phiargs in-place.
16008 (vn_phi_eq): Adjust.
16009 (shared_lookup_phiargs): Remove.
16010 (vn_phi_lookup): Allocate temporary vn_phi_s on the stack.
16011 (vn_phi_insert): Allocate from obstack instead of from alloc-pool.
16012 (visit_reference_op_call): Likewise.
16013 (copy_nary, copy_phi, copy_reference): Remove.
16014 (process_scc): Rewind the obstack when iterating. Do not
16015 copy the elements to valid_info but just move them from one
16016 hashtable to the other.
16017 (allocate_vn_table): Adjust.
16018 (free_vn_table): Likewise.
16019 (init_scc_vn): Likewise.
16020 (free_scc_vn): Likewise.
16021
16022 2018-07-19 H.J. Lu <hongjiu.lu@intel.com>
16023
16024 PR target/86560
16025 * config/i386/i386.c (rest_of_insert_endbranch): Lookup
16026 indirect_return as function type attribute.
16027 (ix86_attribute_table): Change indirect_return to function
16028 type attribute.
16029 * doc/extend.texi: Update indirect_return attribute.
16030
16031 2018-07-19 Aldy Hernandez <aldyh@redhat.com>
16032
16033 * wide-int.h (widest2_int): New.
16034 * gimple-fold.c (arith_overflowed_p): Use it.
16035 * tree.h (widest2_int_cst): New.
16036 * tree-vrp.c (wide_int_binop_overflow): Rename from
16037 vrp_int_const_binop.
16038 Rewrite to work on trees.
16039 (extract_range_from_multiplicative_op_1): Abstract code to...
16040 (wide_int_range_min_max): ...here.
16041 (wide_int_range_cross_product): ...and here.
16042 (extract_range_from_binary_expr_1): Abstract overflow code to...
16043 (wide_int_range_mult_wrapping): ...here.
16044 * tree-vrp.h (wide_int_range_cross_product): New.
16045 (wide_int_range_mult_wrapping): New.
16046
16047 2018-07-19 Andrew Senkevich <andrew.senkevich@intel.com>
16048 Julia Koval <julia.koval@intel.com>
16049
16050 * config/i386/x86-tune-costs.h (skylake_memcpy,
16051 skylake_memset): Replace rep_prefix with unrolling for size 512.
16052
16053 2018-07-18 Kugan Vivekanandarajah <kuganv@linaro.org>
16054
16055 PR middle-end/86544
16056 * tree-ssa-phiopt.c (cond_removal_in_popcount_pattern): Handle
16057 comparision with EQ_EXPR in last stmt.
16058
16059 2018-07-18 Kelvin Nilsen <kelvin@gcc.gnu.org>
16060
16061 * doc/extend.texi (PowerPC AltiVec Built-in Functions): Rename
16062 this subsection to "PowerPC AltiVec/VSX Built-in Functions".
16063 (PowerPC AltiVec/VSX Built-in Functions): New name for subsection
16064 previously known as "PowerPC AltiVec Built-in Functions". Move
16065 some material to new subsubsections "PowerPC AltiVec Built-in
16066 Functions on ISA 2.06" and "PowerPC AltiVec Built-in Functions on
16067 ISA 2.07".
16068 (PowerPC Altivec Built-in Functions on ISA 2.05): New subsubsection.
16069 (PowerPC Altivec Built-in Functions on ISA 2.06): Likewise.
16070 (PowerPC Altivec Built-in Functions on ISA 2.07): Likewise.
16071 (PowerPC Altivec Built-in Functions on ISA 3.0): Likewise.
16072
16073 2018-07-18 Richard Biener <rguenther@suse.de>
16074
16075 PR tree-optimization/86557
16076 * tree-vect-patterns.c (vect_recog_divmod_pattern): Also handle
16077 EXACT_DIV_EXPR.
16078
16079 2018-07-18 Ilya Leoshkevich <iii@linux.ibm.com>
16080
16081 * config/s390/s390.c (s390_function_profiler): Generate CFI.
16082
16083 2018-07-17 Jeff Law <law@redhat.com>
16084
16085 * config/arm/arm.c (get_label_padding): Update for recent
16086 changes to label_to_alignment.
16087
16088 PR tree-optimization/86010
16089 * tree-ssa-dse.c (compute_trims): Fix typo/thinko.
16090
16091 * config/mips/mips.c (vr4130_align_insns): Update for recent
16092 changes to label_to_alignment.
16093
16094 * config/frv/frv.c (frv_label_align): Update for recent changes
16095 to label_to_alignment.
16096
16097 * config/nios2/nios2.c (nios2_label_align): Update for recent
16098 changes which dropped ALIGN_LABELS_LOG.
16099
16100 2018-07-17 Andreas Schwab <schwab@linux-m68k.org>
16101
16102 * config/m68k/m68k.md (umulsi3_highpart+1, const_umulsi3_highpart)
16103 (smulsi3_highpart+1, const_smulsi3_highpart): Add CC_STATUS_INIT.
16104
16105 2018-07-17 Claudiu Zissulescu <claziss@synopsys.com>
16106
16107 * config/arc/arc.c (arc_label_align): Use align_labels instead of
16108 deprecated align_labels_log.
16109
16110 2018-07-17 Richard Biener <rguenther@suse.de>
16111
16112 PR lto/86456
16113 * dwarf2out.c (init_sections_and_labels): Always generate
16114 a debug_line_str_section for early LTO debug.
16115 (dwarf2out_finish): Reset debug_line_str_hash output early.
16116 Bump counter for extra dwarf5 .debug_loc labels to not conflict
16117 with fat LTO part.
16118 (dwarf2out_early_finish): Output debug_line_str.
16119
16120 2018-07-17 Robin Dapp <rdapp@linux.ibm.com>
16121
16122 * config/s390/s390.c (preferred_la_operand_p): Do not use LA with
16123 index register on z196 or later.
16124
16125 2018-07-17 Robin Dapp <rdapp@linux.ibm.com>
16126
16127 * config/s390/s390.c (s390_default_align): Set default function
16128 alignment to 16.
16129 (s390_override_options_after_change): Call s390_default align.
16130 (s390_option_override_internal): Call s390_default_align.
16131 (TARGET_OVERRIDE_OPTIONS_AFTER_CHANGE): Define.
16132
16133 2018-07-17 Jakub Jelinek <jakub@redhat.com>
16134
16135 PR middle-end/86542
16136 * omp-low.c (create_task_copyfn): Copy over also fields corresponding
16137 to _looptemp_ clauses, other than the first two.
16138
16139 2018-07-17 Martin Liska <mliska@suse.cz>
16140
16141 * opts.c: Do not enable OPT_falign_* for -Os.
16142
16143 2018-07-17 Martin Liska <mliska@suse.cz>
16144
16145 * align.h (MAX_CODE_ALIGN): New.
16146 (MAX_CODE_ALIGN_VALUE): New.
16147 * common/config/i386/i386-common.c (ix86_handle_option):
16148 (MAX_CODE_ALIGN): Moved to align.h.
16149 * final.c (MAX_CODE_ALIGN): Likewise.
16150 * opts.c (parse_and_check_align_values):
16151 (MAX_CODE_ALIGN): Likewise.
16152 (MAX_CODE_ALIGN_VALUE): Likewise.
16153
16154 2018-07-17 Martin Liska <mliska@suse.cz>
16155
16156 * config/i386/att.h (ASM_OUTPUT_ALIGN): Fix spacing
16157 in order to fulfil coding style.
16158 * config/i386/cygming.h (ASM_OUTPUT_ALIGN): Likewise.
16159 * config/i386/gas.h (ASM_OUTPUT_MAX_SKIP_ALIGN): Likewise.
16160 * config/i386/x86-64.h (ASM_OUTPUT_MAX_SKIP_PAD): Likewise.
16161 * config/iq2000/iq2000.h (ASM_OUTPUT_ALIGN): Likewise.
16162 * config/pa/pa.h (ASM_OUTPUT_ALIGN): Likewise.
16163 * config/sparc/sol2.h (ASM_OUTPUT_ALIGN_WITH_NOP): Likewise.
16164 * config/sparc/sparc.h (ASM_OUTPUT_ALIGN): Likewise.
16165 * config/visium/visium.h (ASM_OUTPUT_ALIGN): Likewise.
16166 (ASM_OUTPUT_MAX_SKIP_ALIGN): Likewise.
16167
16168 2018-07-17 Martin Liska <mliska@suse.cz>
16169
16170 * align.h: New file.
16171 * config/alpha/alpha.c (alpha_align_insns_1): Use align_functions
16172 directly.
16173 * config/i386/i386.c (ix86_avoid_jump_mispredicts): Use new return type
16174 align_flags of label_to_alignment.
16175 * config/m32r/m32r.h (LOOP_ALIGN): Wrap returned values into
16176 align_flags class.
16177 * config/m68k/m68k.c: Do not use removed align_labels_value and
16178 align_loops_value.
16179 * config/nds32/nds32.h (JUMP_ALIGN): Wrap result into align_flags class.
16180 (LOOP_ALIGN): Likewise.
16181 (LABEL_ALIGN): Likewise.
16182 * config/powerpcspe/powerpcspe.c (TARGET_ASM_LOOP_ALIGN_MAX_SKIP):
16183 Remove not used macro.
16184 (rs6000_loop_align): Change return type to align_flags.
16185 (rs6000_loop_align_max_skip): Remove.
16186 * config/rs6000/rs6000-protos.h (rs6000_loop_align):
16187 Change return type to align_flags.
16188 * config/rs6000/rs6000.c (TARGET_ASM_LOOP_ALIGN_MAX_SKIP):
16189 Remove not used macro.
16190 (rs6000_loop_align): Change return type to align_flags.
16191 (rs6000_loop_align_max_skip): Remove.
16192 * config/rx/rx.h (JUMP_ALIGN): Wrap integer values
16193 * config/rx/rx-protos.h (rx_align_for_label): Make it
16194 static function.
16195 * config/rx/rx.c (rx_align_for_label): Change return type
16196 to align_flags.
16197 (rx_max_skip_for_label): Remove TARGET_ASM_*_ALIGN_MAX_SKIP
16198 macro definitions.
16199 into align_flags class.
16200 (LABEL_ALIGN): Likewise.
16201 (LOOP_ALIGN): Likewise.
16202 * config/s390/s390.c (s390_label_align): Use align_flags
16203 class member.
16204 (s390_asm_output_function_label): Likewise.
16205 * config/sh/sh.c (sh_override_options_after_change):
16206 Use align_flags class directly without macros.
16207 (find_barrier): Likewise.
16208 (barrier_align): Likewise.
16209 (sh_loop_align): Likewise.
16210 * config/spu/spu.c (spu_option_override):
16211 Use align_flags_tuple::get_value instead of removed macros.
16212 (spu_sched_init): Likewise.
16213 * config/spu/spu.h (GTY): Likewise.
16214 * config/visium/visium.c (visium_option_override):
16215 Set "8" as default secondary alignment.
16216 * config/visium/visium.h (SUBALIGN_LOG): Define to 3
16217 in order to guarantee secondary alignment of 8.
16218 * coretypes.h: Include align.h header file.
16219 * doc/tm.texi: Remove TARGET_ASM_JUMP_ALIGN_MAX_SKIP,
16220 TARGET_ASM_LOOP_ALIGN_MAX_SKIP, TARGET_ASM_LABEL_ALIGN_MAX_SKIP
16221 and TARGET_ASM_LABEL_ALIGN_AFTER_BARRIER_MAX_SKIP macros.
16222 * doc/tm.texi.in: Likewise.
16223 * final.c (struct label_alignment): Remove not used structure.
16224 (LABEL_ALIGN): Change type to align_flags.
16225 (LOOP_ALIGN): Likewise.
16226 (JUMP_ALIGN): Likewise.
16227 (default_loop_align_max_skip): Remove.
16228 (default_label_align_max_skip): Likewise.
16229 (default_jump_align_max_skip): Likewise.
16230 (default_label_align_after_barrier_max_skip):
16231 (LABEL_TO_ALIGNMENT): Change to access label_align vector.
16232 (LABEL_TO_MAX_SKIP): Remove.
16233 (label_to_alignment): Return align_flags type instead of integer.
16234 (label_to_max_skip): Remove.
16235 (align_fuzz): Use align_flags type.
16236 (compute_alignments): Use align_flags type and use align_flags::max
16237 to combine multiple alignments.
16238 (grow_label_align): Grow vec instead of C array.
16239 (update_alignments): Assign just LABEL_TO_ALIGNMENT.
16240 (shorten_branches): Use align_flags type and use align_flags::max
16241 to combine multiple alignments.
16242 (final_scan_insn_1): Remove usage of secondary alignment that comes
16243 from label alignment, but instead use proper secondary alignment
16244 which is computed in grow_label_align.
16245 * flags.h (struct align_flags_tuple): Move to align.h.
16246 (struct align_flags): Likewise.
16247 (state_align_loops): Rename to align_loops.
16248 (state_align_jumps): Rename to align_jumps.
16249 (state_align_labels): Rename to align_labels.
16250 (state_align_functions): Rename to align_functions.
16251 (align_loops_log): Remove.
16252 (align_jumps_log): Remove.
16253 (align_labels_log): Remove.
16254 (align_functions_log): Remove.
16255 (align_loops_max_skip): Remove.
16256 (align_jumps_max_skip): Remove.
16257 (align_labels_max_skip): Remove.
16258 (align_functions_max_skip): Remove.
16259 (align_loops_value): Remove.
16260 (align_jumps_value): Remove.
16261 (align_labels_value): Remove.
16262 (align_functions_value): Remove.
16263 * output.h (label_to_alignment): Change return type to align_flags.
16264 (label_to_max_skip): Remove.
16265 * target.def: Remove loop_align_max_skip, label_align_max_skip,
16266 jump_align_max_skip macros.
16267 * targhooks.h (default_loop_align_max_skip): Remove.
16268 (default_label_align_max_skip): Likewise.
16269 (default_jump_align_max_skip): Likewise.
16270 (default_label_align_after_barrier_max_skip): Remove.
16271 * toplev.c (read_log_maxskip): Use ::normalize function.
16272 (parse_N_M): Remove not used argument and also call ::normalize.
16273 (parse_alignment_opts): Do not pass unused arguments.
16274 * varasm.c (assemble_start_function): Use directly align_functions
16275 instead of removed macros.
16276 * system.h: Do not poison removed macros.
16277
16278 2018-07-17 Jakub Jelinek <jakub@redhat.com>
16279
16280 PR middle-end/86539
16281 * gimplify.c (gimplify_omp_for): Ensure taskloop firstprivatized init
16282 and cond temporaries don't have reference type if iterator has
16283 pointer type. For init use &for_pre_body instead of pre_p if
16284 for_pre_body is non-empty.
16285
16286 2018-07-16 Segher Boessenkool <segher@kernel.crashing.org>
16287
16288 * config/rs6000/rs6000.md (trunc<mode>sf2): Expand truncates of
16289 double-double modes to SFmode directly directly.
16290 (trunc<mode>sf2_fprs): Delete.
16291
16292 2018-07-16 Segher Boessenkool <segher@kernel.crashing.org>
16293
16294 * config/rs6000/rs6000.c (init_float128_ibm): Use the correct names
16295 for conversions between IFmode and the decimal floating point modes.
16296 (init_float128_ieee): Use the correct names for conversions between
16297 KFmode and the decimal floating point modes.
16298
16299 2018-07-16 Segher Boessenkool <segher@kernel.crashing.org>
16300
16301 * config/rs6000/rs6000.c (init_float128_ibm): Use more correct names
16302 for the conversions between TDmode and IFmode.
16303 (init_float128_ieee): Use more correct names for the conversions
16304 between TDmode and KFmode.
16305
16306 2018-07-16 Jakub Jelinek <jakub@redhat.com>
16307
16308 PR tree-optimization/86526
16309 * builtins.c (expand_builtin_memcmp): Formatting fixes.
16310 (inline_expand_builtin_string_cmp): Likewise.
16311 (inline_string_cmp): Likewise. Use c_readstr instead of
16312 builtin_memcpy_read_str. Add unit_mode temporary.
16313
16314 2018-07-16 Bernd Edlinger <bernd.edlinger@hotmail.de>
16315
16316 PR middle-end/86528
16317 * builtins.c (check_access): Bail out if range[0] is no INTEGER_CST.
16318 * expr.c (string_constant): Fix the element size of ARRAY_TYPE.
16319
16320 2018-07-16 Kelvin Nilsen <kelvin@gcc.gnu.org>
16321
16322 * doc/extend.texi (PowerPC AltiVec Built-in Functions):
16323 Alphabetize prototypes of built-in functions, separating out
16324 built-in functions that are listed in this section but should be
16325 described elsewhere.
16326
16327 2018-07-16 Uros Bizjak <ubizjak@gmail.com>
16328
16329 PR target/86511
16330 * expmed.c (emit_store_flag): Do not emit setcc followed by a
16331 conditional move when trapping comparison was split to a
16332 non-trapping one (and vice versa).
16333
16334 2018-07-16 Ilya Leoshkevich <iii@linux.ibm.com>
16335
16336 * config/s390/s390.c (s390_function_profiler): Generate nops
16337 instead of profiler call sequences.
16338 * config/s390/s390.opt: Add the new option.
16339
16340 2018-07-16 Ilya Leoshkevich <iii@linux.ibm.com>
16341
16342 * config/s390/s390.c (s390_function_profiler): Generate
16343 __mcount_loc section.
16344 * config/s390/s390.opt: Add the new option.
16345
16346 2018-07-16 Ilya Leoshkevich <iii@linux.ibm.com>
16347
16348 * common.opt: Add the new warning.
16349 * config/s390/s390.c (s390_function_profiler): Emit "brasl
16350 %r0,__fentry__" when -mfentry is specified.
16351 (s390_option_override_internal): Disallow -mfentry for 31-bit
16352 CPUs.
16353 * config/s390/s390.opt: Add the new option.
16354
16355 2018-07-16 Richard Biener <rguenther@suse.de>
16356
16357 PR lto/86523
16358 * dwarf2out.c (dwarf2out_register_external_die): Assign DIE parents
16359 for function-local FUNCTION_DECL and RESULT_DECL immediately.
16360
16361 2018-07-16 Martin Liska <mliska@suse.cz>
16362
16363 PR ipa/86529
16364 * ipa-pure-const.c (malloc_candidate_p): Revert ::get
16365 to ::get_create.
16366
16367 2017-07-16 Claudiu Zissulescu <claziss@synopsys.com>
16368
16369 * config/arc/arcHS.md: Update ARCHS scheduling rules.
16370
16371 2017-07-16 Claudiu Zissulescu <claziss@synopsys.com>
16372
16373 * config/arc/arc-arch.h (arc_tune_attr): Add new tune parameters
16374 for ARCHS4x.
16375 * config/arc/arc-cpus.def (hs4x): New cpu.
16376 (hs4xd): Likewise.
16377 * config/arc/arc-tables.opt: Regenerate.
16378 * config/arc/arc.c (arc_sched_issue_rate): New function.
16379 (TARGET_SCHED_ISSUE_RATE): Define.
16380 (TARGET_SCHED_EXPOSED_PIPELINE): Likewise.
16381 * config/arc/arc.md (attr type): Add fpu_fuse, fpu_sdiv, fpu_ddiv,
16382 fpu_cvt.
16383 (attr tune): Add ARCHS4x tune values.
16384 (attr tune_dspmpy): Define.
16385 (*tst): Correct instruction type.
16386 * config/arc/arcHS.md: Don't use this automaton for ARCHS4x cpus.
16387 * config/arc/arcHS4x.md: New file.
16388 * config/arc/fpu.md: Update instruction type attributes.
16389 * config/arc/t-multilib: Regenerate.
16390
16391 2018-07-16 Tom de Vries <tdevries@suse.de>
16392
16393 PR debug/86455
16394 * var-tracking.c (vt_initialize): Fix pre_dec handling.
16395
16396 2018-07-16 Ramana Radhakrishnan <ramana.radhakrishnan@arm.com>
16397
16398 * config/aarch64/atomics.md (aarch64_store_execlusive<mode>): Add
16399 early clobber.
16400
16401 2018-07-16 Eric Botcazou <ebotcazou@adacore.com>
16402
16403 PR tree-optimization/86514
16404 * tree-ssa-reassoc.c (init_range_entry) <CASE_CONVERT>: Return for a
16405 conversion to a boolean type from a type with greater precision.
16406
16407 2018-07-16 Tom de Vries <tdevries@suse.de>
16408
16409 * var-tracking.c (vt_initialize): Print adjusted insn slim if
16410 dump_flags request TDF_SLIM.
16411
16412 2018-07-16 Aldy Hernandez <aldyh@redhat.com>
16413
16414 * fold-const.c (int_const_binop_1): Abstract...
16415 (wide_int_binop): ...wide int code here.
16416 (poly_int_binop): ...poly int code here.
16417 Abstract the rest of int_const_binop_1 into int_const_binop.
16418 * fold-const.h (wide_int_binop): New.
16419 * tree-vrp.c (vrp_int_const_binop): Call wide_int_binop.
16420 Remove useless PLUS/MINUS_EXPR case.
16421 (zero_nonzero_bits_from_vr): Move wide int code...
16422 (zero_nonzero_bits_from_bounds): ...here.
16423 (extract_range_from_binary_expr_1): Move mask optimization code...
16424 (range_easy_mask_min_max): ...here.
16425 * tree-vrp.h (zero_nonzero_bits_from_bounds): New.
16426 (range_easy_mask_min_max): New.
16427
16428 2018-07-15 Jeff Law <law@redhat.com>
16429
16430 PR target/85993
16431 * config/sh/sh.c (output_mi_thunk): Remove dead conditional
16432 block.
16433
16434 2018-07-14 Jim Wilson <jimw@sifive.com>
16435
16436 * config/riscv/linux.h (TARGET_ASM_FILE_END): New.
16437
16438 2018-07-14 Paul Koning <ni1d@arrl.net>
16439
16440 * config/pdp11/pdp11.c (pdp11_rtx_costs): Bugfixes.
16441
16442 2018-07-13 Jan Hubicka <hubicka@ucw.cz>
16443
16444 * lto-streamer-out.c (copy_function_or_variable): Dump info about
16445 copying section.
16446
16447 2018-07-13 Bill Schmidt <wschmidt@linux.ibm.com>
16448 Steve Munroe <munroesj52@gmail.com>
16449
16450 * config/rs6000/emmintrin.h (_mm_and_si128): New function.
16451 (_mm_andnot_si128): Likewise.
16452 (_mm_or_si128): Likewise.
16453 (_mm_xor_si128): Likewise.
16454
16455 2018-07-13 Qing Zhao <qing.zhao@oracle.com>
16456
16457 PR middle-end/78809
16458 * builtins.c (expand_builtin_memcmp): Inline the calls first
16459 when result_eq is false.
16460 (expand_builtin_strcmp): Inline the calls first.
16461 (expand_builtin_strncmp): Likewise.
16462 (inline_string_cmp): New routine. Expand a string compare
16463 call by using a sequence of char comparison.
16464 (inline_expand_builtin_string_cmp): New routine. Inline expansion
16465 a call to str(n)cmp/memcmp.
16466 * doc/invoke.texi (--param builtin-string-cmp-inline-length):
16467 New option.
16468 * params.def (BUILTIN_STRING_CMP_INLINE_LENGTH): New.
16469
16470 2018-07-13 Richard Earnshaw <rearnsha@arm.com>
16471
16472 * config/arm/driver-arm.c: Include arm-native.h.
16473 (host_detect_local_cpu): Use auto-generated data tables.
16474 (vendors, arm_cpu_table): Delete. Move part information to ...
16475 * config/arm/arm-cpus.in: ... here.
16476 * config/arm/parsecpu.awk (gen_native): New function.
16477 (vendor, part): New CPU fields.
16478 (END): Add support for building the native CPU detection tables.
16479 * config/arm/t-arm (arm-native.h): Add build rule.
16480 (driver-arm.o): Add dependency on arm-native.h.
16481
16482 2018-07-13 Richard Biener <rguenther@suse.de>
16483
16484 PR middle-end/85974
16485 * match.pd (addr1 - addr2): Allow either of the operand to
16486 have a conversion.
16487
16488 2018-07-13 Tom de Vries <tdevries@suse.de>
16489
16490 * tree-inline.c (remap_ssa_name): Save and reuse debug exprs generated
16491 in remap_ssa_name.
16492
16493 2018-07-13 Jackson Woodruff <jackson.woodruff@arm.com>
16494
16495 * config/aarch64/aarch64.c (aarch64_operands_adjust_ok_for_ldpstp): Use
16496 arrays instead of numbered variables.
16497
16498 2018-07-13 Eric Botcazou <ebotcazou@adacore.com>
16499
16500 * config/sparc/sparc-protos.h (sparc_compute_frame_size): Delete.
16501 * config/sparc/sparc.c (sparc_compute_frame_size): Make static.
16502
16503 2018-07-13 Richard Biener <rguenther@suse.de>
16504
16505 PR debug/86452
16506 * dwarf2out.c (gen_type_die_with_usage): Use scope_die_for
16507 instead of get_context_die.
16508
16509 2018-07-13 Kugan Vivekanandarajah <kuganv@linaro.org>
16510 Richard Biener <rguenther@suse.de>
16511
16512 PR middle-end/86489
16513 * tree-ssa-loop-niter.c (number_of_iterations_popcount): Check
16514 that the loop latch destination where phi is defined.
16515
16516 2018-07-12 Kito Cheng <kito.cheng@gmail.com>
16517
16518 * config/riscv/riscv.c (enum riscv_privilege_levels): Add UNKNOWN_MODE.
16519 (riscv_expand_epilogue): Add assertion to check interrupt mode.
16520 (riscv_set_current_function): Extract getting interrupt type to new
16521 function.
16522 (riscv_get_interrupt_type): New function.
16523 (riscv_merge_decl_attributes): New function, checking interrupt type is
16524 same.
16525 (TARGET_MERGE_DECL_ATTRIBUTES): Define.
16526
16527 2018-07-12 Paul Koning <ni1d@arrl.net>
16528
16529 * config/pdp11/pdp11.c (pdp11_output_def): Fix typo in .set
16530 directive.
16531
16532 2018-07-12 Paul Koning <ni1d@arrl.net>
16533
16534 * doc/rtl.texi (REG_NONNEG): Remove decrement and branch until
16535 zero reference, add doloop_end instead.
16536 * doc/md.texi (decrement_and_branch_until_zero): Remove.
16537 (Looping patterns): Remove decrement_and_branch_until_zero. Add
16538 detail for doloop_end.
16539
16540 2018-07-12 Martin Sebor <msebor@redhat.com>
16541
16542 PR c/86453
16543 * attribs.c (decl_attributes): Reject conflicting attributes before
16544 calling attribute handlers.
16545
16546 2018-07-12 Jan Hubicka <hubicka@ucw.cz>
16547
16548 * dumpfile.c (gcc::dump_manager::get_dump_file_name): Add PART
16549 parameter.
16550 (gcc::dump_manager::get_dump_file_name): likewise.
16551 (dump_begin): Likewise.
16552 * dumpfile.h (dump_begin): Update prototype.
16553 (gcc::dump_manager::get_dump_file_name,
16554 gcc::dump_manager::get_dump_file_name): Update prototype.
16555
16556 2018-07-12 Richard Sandiford <richard.sandiford@linaro.org>
16557
16558 * internal-fn.h (vectorizable_internal_fn_p): New function.
16559 * tree-vect-slp.c (compatible_calls_p): Likewise.
16560 (vect_build_slp_tree_1): Remove nops argument. Handle calls
16561 to internal functions.
16562 (vect_build_slp_tree_2): Update call to vect_build_slp_tree_1.
16563
16564 2018-07-12 Richard Sandiford <richard.sandiford@linaro.org>
16565
16566 * fold-const.h (inverse_conditions_p): Declare.
16567 * fold-const.c (inverse_conditions_p): New function.
16568 * match.pd: Use inverse_conditions_p. Add folds of view_converts
16569 that test the inverse condition of a conditional internal function.
16570 * internal-fn.h (vectorized_internal_fn_supported_p): Declare.
16571 * internal-fn.c (internal_fn_mask_index): Handle conditional
16572 internal functions.
16573 (vectorized_internal_fn_supported_p): New function.
16574 * tree-if-conv.c: Include internal-fn.h and fold-const.h.
16575 (any_pred_load_store): Replace with...
16576 (need_to_predicate): ...this new variable.
16577 (redundant_ssa_names): New variable.
16578 (ifcvt_can_use_mask_load_store): Move initial checks to...
16579 (ifcvt_can_predicate): ...this new function. Handle tree codes
16580 for which a conditional internal function exists.
16581 (if_convertible_gimple_assign_stmt_p): Use ifcvt_can_predicate
16582 instead of ifcvt_can_use_mask_load_store. Update after variable
16583 name change.
16584 (predicate_load_or_store): New function, split out from
16585 predicate_mem_writes.
16586 (check_redundant_cond_expr): New function.
16587 (value_available_p): Likewise.
16588 (predicate_rhs_code): Likewise.
16589 (predicate_mem_writes): Rename to...
16590 (predicate_statements): ...this. Use predicate_load_or_store
16591 and predicate_rhs_code.
16592 (combine_blocks, tree_if_conversion): Update after above name changes.
16593 (ifcvt_local_dce): Handle redundant_ssa_names.
16594 * tree-vect-patterns.c (vect_recog_mask_conversion_pattern): Handle
16595 general conditional functions.
16596 * tree-vect-stmts.c (vectorizable_call): Likewise.
16597
16598 2018-07-12 Richard Sandiford <richard.sandiford@linaro.org>
16599 Alan Hayward <alan.hayward@arm.com>
16600 David Sherwood <david.sherwood@arm.com>
16601
16602 * internal-fn.h (can_interpret_as_conditional_op_p): Declare.
16603 * internal-fn.c (can_interpret_as_conditional_op_p): New function.
16604 * tree-ssa-math-opts.c (convert_mult_to_fma_1): Handle conditional
16605 plus and minus and convert them into IFN_COND_FMA-based sequences.
16606 (convert_mult_to_fma): Handle conditional plus and minus.
16607
16608 2018-07-12 Richard Sandiford <richard.sandiford@linaro.org>
16609
16610 * doc/md.texi (cond_fma, cond_fms, cond_fnma, cond_fnms): Document.
16611 * optabs.def (cond_fma_optab, cond_fms_optab, cond_fnma_optab)
16612 (cond_fnms_optab): New optabs.
16613 * internal-fn.def (COND_FMA, COND_FMS, COND_FNMA, COND_FNMS): New
16614 internal functions.
16615 (FMA): Use DEF_INTERNAL_FLT_FN rather than DEF_INTERNAL_FLT_FLOATN_FN.
16616 * internal-fn.h (get_conditional_internal_fn): Declare.
16617 (get_unconditional_internal_fn): Likewise.
16618 * internal-fn.c (cond_ternary_direct): New macro.
16619 (expand_cond_ternary_optab_fn): Likewise.
16620 (direct_cond_ternary_optab_supported_p): Likewise.
16621 (FOR_EACH_COND_FN_PAIR): Likewise.
16622 (get_conditional_internal_fn): New function.
16623 (get_unconditional_internal_fn): Likewise.
16624 * gimple-match.h (gimple_match_op::MAX_NUM_OPS): Bump to 5.
16625 (gimple_match_op::gimple_match_op): Add a new overload for 5
16626 operands.
16627 (gimple_match_op::set_op): Likewise.
16628 (gimple_resimplify5): Declare.
16629 * genmatch.c (decision_tree::gen): Generate simplifications for
16630 5 operands.
16631 * gimple-match-head.c (gimple_simplify): Define an overload for
16632 5 operands. Handle calls with 5 arguments in the top-level overload.
16633 (convert_conditional_op): Handle conversions from unconditional
16634 internal functions to conditional ones.
16635 (gimple_resimplify5): New function.
16636 (build_call_internal): Pass a fifth operand.
16637 (maybe_push_res_to_seq): Likewise.
16638 (try_conditional_simplification): Try converting conditional
16639 internal functions to unconditional internal functions.
16640 Handle 3-operand unconditional forms.
16641 * match.pd (UNCOND_TERNARY, COND_TERNARY): Operator lists.
16642 Define ternary equivalents of the current rules for binary conditional
16643 internal functions.
16644 * config/aarch64/aarch64.c (aarch64_preferred_else_value): Handle
16645 ternary operations.
16646 * config/aarch64/iterators.md (UNSPEC_COND_FMLA, UNSPEC_COND_FMLS)
16647 (UNSPEC_COND_FNMLA, UNSPEC_COND_FNMLS): New unspecs.
16648 (optab): Handle them.
16649 (SVE_COND_FP_TERNARY): New int iterator.
16650 (sve_fmla_op, sve_fmad_op): New int attributes.
16651 * config/aarch64/aarch64-sve.md (cond_<optab><mode>)
16652 (*cond_<optab><mode>_2, *cond_<optab><mode_4)
16653 (*cond_<optab><mode>_any): New SVE_COND_FP_TERNARY patterns.
16654
16655 2018-07-12 Richard Sandiford <richard.sandiford@linaro.org>
16656
16657 * target.def (preferred_else_value): New target hook.
16658 * doc/tm.texi.in (TARGET_PREFERRED_ELSE_VALUE): New hook.
16659 * doc/tm.texi: Regenerate.
16660 * targhooks.h (default_preferred_else_value): Declare.
16661 * targhooks.c (default_preferred_else_value): New function.
16662 * internal-fn.h (conditional_internal_fn_code): Declare.
16663 * internal-fn.c (FOR_EACH_CODE_MAPPING): New macro.
16664 (get_conditional_internal_fn): Use it.
16665 (conditional_internal_fn_code): New function.
16666 * gimple-match.h (gimple_match_cond): New struct.
16667 (gimple_match_op): Add a cond member function.
16668 (gimple_match_op::gimple_match_op): Update all forms to take a
16669 gimple_match_cond.
16670 * genmatch.c (expr::gen_transform): Use the same condition as res_op
16671 for the suboperation, but don't specify a particular else_value.
16672 * tree-ssa-sccvn.c (vn_nary_simplify, vn_reference_lookup_3)
16673 (visit_nary_op, visit_reference_op_load): Pass
16674 gimple_match_cond::UNCOND to the gimple_match_op constructor.
16675 * gimple-match-head.c: Include tree-eh.h
16676 (convert_conditional_op): New function.
16677 (maybe_resimplify_conditional_op): Likewise.
16678 (gimple_resimplify1): Call maybe_resimplify_conditional_op.
16679 (gimple_resimplify2): Likewise.
16680 (gimple_resimplify3): Likewise.
16681 (gimple_resimplify4): Likewise.
16682 (maybe_push_res_to_seq): Return null for conditional operations.
16683 (try_conditional_simplification): New function.
16684 (gimple_simplify): Call it. Pass conditions to the gimple_match_op
16685 constructor.
16686 * match.pd: Fold VEC_COND_EXPRs of an IFN_COND_* call to a new
16687 IFN_COND_* call.
16688 * config/aarch64/aarch64.c (aarch64_preferred_else_value): New
16689 function.
16690 (TARGET_PREFERRED_ELSE_VALUE): Redefine.
16691
16692 2018-07-12 Jan Hubicka <hubicka@ucw.cz>
16693
16694 * lto-streamer-out.c (DFS::DFS_write_tree_body): Do not stream
16695 DECL_FCONTEXT
16696 (hash_tree): Do not hash DECL_FCONTEXT
16697 * tree-streamer-in.c (lto_input_ts_field_decl_tree_pointers):
16698 Do not stream DECL_FCONTEXT.
16699 * tree-streamer-out.c (write_ts_field_decl_tree_pointers): Likewise.
16700 * tree.c (free_lang_data_in_decl): Free DECL_FCONTEXT.
16701
16702 2018-07-12 Richard Biener <rguenther@suse.de>
16703
16704 PR debug/86462
16705 * dwarf2out.c (gen_block_die): Only output blocks when they have
16706 at least one !DECL_IGNORED_P variable.
16707
16708 2018-07-12 Richard Biener <rguenther@suse.de>
16709
16710 PR target/84829
16711 * config/gnu-user.h (GNU_USER_TARGET_NO_PTHREADS_LIB_SPEC):
16712 Remove -mieee-fp handling.
16713
16714 2018-07-12 Richard Biener <rguenther@suse.de>
16715
16716 * tree-ssa-sccvn.c (vn_lookup_simplify_result): Remove bogus
16717 left-over from last patch.
16718
16719 2018-07-12 Jakub Jelinek <jakub@redhat.com>
16720
16721 PR tree-optimization/86492
16722 * gimple-ssa-store-merging.c
16723 (imm_store_chain_info::coalesce_immediate_stores): Call
16724 check_no_overlap even for the merge_overlapping case. Formatting fix.
16725
16726 2018-07-12 Richard Biener <rguenther@suse.de>
16727
16728 PR middle-end/86479
16729 * fold-const.c (fold_binary_op_with_conditional_arg): Do not
16730 move possibly trapping operations into the conditional.
16731
16732 2018-07-12 Richard Biener <rguenther@suse.de>
16733
16734 * tree-ssa-sccvn.c (mprts_hook_cnt): Remove.
16735 (vn_lookup_simplify_result): Remove recursion limit applied
16736 here.
16737 (vn_nary_build_or_lookup_1): Adjust.
16738 (try_to_simplify): Likewise.
16739 * gimple-match-head.c (gimple_resimplify1): Instead apply one
16740 here.
16741 (gimple_resimplify2): Likewise.
16742 (gimple_resimplify3): Likewise.
16743 (gimple_resimplify4): Likewise.
16744
16745 2018-07-11 Jakub Jelinek <jakub@redhat.com>
16746
16747 * config/i386/avx512bitalgintrin.h (_mm512_mask_bitshuffle_epi64_mask):
16748 Use __mmask64 type instead of __mmask8 for __M argument.
16749 * config/i386/avx512fintrin.h (_mm512_mask_xor_epi64,
16750 _mm512_maskz_xor_epi64): Use __mmask8 type instead of __mmask16 for
16751 __U argument.
16752 (_mm512_mask_cmpneq_epi64_mask): Use __mmask8 type instead of
16753 __mmask16 for __M argument.
16754 (_mm512_maskz_insertf32x4, _mm512_maskz_inserti32x4,
16755 _mm512_mask_insertf32x4, _mm512_mask_inserti32x4): Cast last argument
16756 to __mmask16 instead of __mmask8.
16757 * config/i386/avx512vlintrin.h (_mm_mask_add_ps, _mm_maskz_add_ps,
16758 _mm256_mask_add_ps, _mm256_maskz_add_ps, _mm_mask_sub_ps,
16759 _mm_maskz_sub_ps, _mm256_mask_sub_ps, _mm256_maskz_sub_ps,
16760 _mm256_maskz_cvtepi32_ps, _mm_maskz_cvtepi32_ps): Use __mmask8 type
16761 instead of __mmask16 for __U argument.
16762 * config/i386/avx512vlbwintrin.h (_mm_mask_cmp_epi8_mask): Use
16763 __mmask16 instead of __mmask8 for __U argument.
16764 (_mm256_mask_cmp_epi8_mask): Use __mmask32 instead of __mmask16 for
16765 __U argument.
16766 (_mm256_cmp_epi8_mask): Use __mmask32 return type instead of
16767 __mmask16.
16768 (_mm_mask_cmp_epu8_mask): Use __mmask16 instead of __mmask8 for __U
16769 argument.
16770 (_mm256_mask_cmp_epu8_mask): Use __mmask32 instead of __mmask16 for
16771 __U argument.
16772 (_mm256_cmp_epu8_mask): Use __mmask32 return type instead of
16773 __mmask16.
16774 (_mm_mask_cmp_epi16_mask): Cast last argument to __mmask8 instead
16775 of __mmask16.
16776 (_mm256_mask_cvtepi8_epi16): Use __mmask16 instead of __mmask32 for
16777 __U argument.
16778 (_mm_mask_cvtepi8_epi16): Use __mmask8 instead of __mmask32 for
16779 __U argument.
16780 (_mm256_mask_cvtepu8_epi16): Use __mmask16 instead of __mmask32 for
16781 __U argument.
16782 (_mm_mask_cvtepu8_epi16): Use __mmask8 instead of __mmask32 for
16783 __U argument.
16784 (_mm256_mask_cmpneq_epu8_mask, _mm256_mask_cmplt_epu8_mask,
16785 _mm256_mask_cmpge_epu8_mask, _mm256_mask_cmple_epu8_mask): Change
16786 return type as well as __M argument type and all casts from __mmask8
16787 to __mmask32.
16788 (_mm256_mask_cmpneq_epu16_mask, _mm256_mask_cmplt_epu16_mask,
16789 _mm256_mask_cmpge_epu16_mask, _mm256_mask_cmple_epu16_mask): Change
16790 return type as well as __M argument type and all casts from __mmask8
16791 to __mmask16.
16792 (_mm256_mask_cmpneq_epi8_mask, _mm256_mask_cmplt_epi8_mask,
16793 _mm256_mask_cmpge_epi8_mask, _mm256_mask_cmple_epi8_mask): Change
16794 return type as well as __M argument type and all casts from __mmask8
16795 to __mmask32.
16796 (_mm256_mask_cmpneq_epi16_mask, _mm256_mask_cmplt_epi16_mask,
16797 _mm256_mask_cmpge_epi16_mask, _mm256_mask_cmple_epi16_mask): Change
16798 return type as well as __M argument type and all casts from __mmask8
16799 to __mmask16.
16800 * config/i386/avx512vbmi2vlintrin.h (_mm_mask_shrdi_epi32,
16801 _mm_mask_shldi_epi32): Cast last argument to __mmask8 instead of
16802 __mmask16.
16803
16804 2018-07-11 Grazvydas Ignotas <notasas@gmail.com>
16805
16806 * config/i386/avx512bwintrin.h: (_mm512_mask_cmp_epi8_mask,
16807 _mm512_mask_cmp_epu8_mask): Use __mmask64 type instead of __mmask32
16808 for __U argument.
16809
16810 2018-07-11 Paul Koning <ni1d@arrl.net>
16811
16812 * doc/md.texi (define_subst): Document how multiple occurrences of
16813 the same argument in the replacement pattern are handled.
16814
16815 2018-07-11 Paul Koning <ni1d@arrl.net>
16816
16817 * doc/extend.texi (Common Variable Attributes): Move "mode" into
16818 alphabetical order.
16819 (Common Type Attributes): Add "mode" attribute.
16820
16821 2018-07-11 Jan Hubicka <hubicka@ucw.cz>
16822
16823 * lto-streamer-out.c (DFS::DFS_write_tree_body): Do not
16824 stream DECL_ORIGINAL_TYPE.
16825 (DFS::DFS_write_tree_body): Drop hack handling local external decls.
16826 (hash_tree): Do not walk DECL_ORIGINAL_TYPE.
16827 * tree-streamer-in.c (lto_input_ts_decl_non_common_tree_pointers):
16828 Do not walk original type.
16829 * tree-streamer-out.c (streamer_write_chain): Drop hack handling
16830 external decls.
16831 (write_ts_decl_non_common_tree_pointers): Do not stream
16832 DECL_ORIGINAL_TYPE
16833 * tree.c (free_lang_data_in_decl): Clear DECL_ORIGINAL_TYPE.
16834 (find_decls_types_r): Do not walk DEC_ORIGINAL_TYPE.
16835
16836 2018-07-11 Aldy Hernandez <aldyh@redhat.com>
16837
16838 * tree-ssa-threadupdate.c (thread_through_all_blocks): Do not jump
16839 thread twice from the same starting edge.
16840
16841 2018-07-11 Aldy Hernandez <aldyh@redhat.com>
16842
16843 * vr-values.c (gimple_stmt_nonzero_p): Abstract common code to...
16844 * gimple.c (gimple_call_nonnull_result_p): ...here...
16845 (gimple_call_nonnull_arg): ...and here.
16846 * gimple.h (gimple_call_nonnull_result_p): New.
16847 (gimple_call_nonnull_arg): New.
16848
16849 2018-07-11 Richard Earnshaw <rearnsha@arm.com>
16850
16851 * config/arm/arm-cpus.in: Move information from fpu field of each
16852 cpu definition to the isa field.
16853 * config/arm/parsecpu.awk (fpu): Delete match rule.
16854 (gen_comm_data): Don't add bits from the CPU's FPU entry.
16855
16856 2018-07-11 Richard Biener <rguenther@suse.de>
16857
16858 PR debug/86457
16859 * dwarf2out.c (init_sections_and_labels): Use
16860 output_asm_line_debug_info consistently.
16861 (dwarf2out_early_finish): Likewise.
16862 (dwarf2out_finish): Remove DW_AT_stmt_list from early generated
16863 type units.
16864
16865 2018-07-11 Richard Biener <rguenther@suse.de>
16866
16867 * tree-ssa-loop-ivcanon.c (tree_unroll_loops_completely_1):
16868 Rework father_bb setting in a way to avoid propagating constants
16869 multiple times on a loop body.
16870
16871 2018-07-10 Mark Wielaard <mark@klomp.org>
16872
16873 PR debug/86459
16874 * dwarf2out.c (output_macinfo_op): Fix dwarf_FORM typo in gcc_assert.
16875
16876 2018-07-10 Richard Biener <rguenther@suse.de>
16877
16878 * hash-map.h (hash_map::iterator::operator*): Return
16879 references to key and value.
16880
16881 2018-07-10 Jakub Jelinek <jakub@redhat.com>
16882
16883 PR c++/86443
16884 * gimplify.c (find_combined_omp_for): Add DATA argument, in addition
16885 to finding the inner OMP_FOR/OMP_SIMD stmt find non-trivial wrappers,
16886 BLOCKs with BLOCK_VARs, OMP_PARALLEL in between, OMP_FOR in between.
16887 (gimplify_omp_for): For composite loops, move outer
16888 OMP_{DISTRIBUTE,TASKLOOP,FOR,PARALLEL} right around innermost
16889 OMP_FOR/OMP_SIMD if there are any non-trivial wrappers. For class
16890 iterators add any needed clauses. Allow OMP_FOR_ORIG_DECLS to contain
16891 TREE_LIST for both the original class iterator and the "last" helper
16892 var. Gimplify OMP_FOR_PRE_BODY before the outermost composite
16893 loop, remember has_decl_expr from outer composite loops for the
16894 innermost OMP_SIMD in TREE_PRIVATE bit on OMP_FOR_INIT.
16895
16896 2018-07-09 Martin Sebor <msebor@redhat.com>
16897
16898 PR middle-end/77357
16899 PR middle-end/86428
16900 * builtins.c (c_strlen): Avoid out-of-bounds warnings when
16901 accessing implicitly initialized array elements.
16902 * expr.c (string_constant): Handle string initializers of
16903 character arrays within aggregates.
16904 * gimple-fold.c (fold_array_ctor_reference): Add argument.
16905 Store element offset. As a special case, handle zero size.
16906 (fold_nonarray_ctor_reference): Same.
16907 (fold_ctor_reference): Add argument. Store subobject offset.
16908 * gimple-fold.h (fold_ctor_reference): Add argument.
16909
16910 2018-07-09 Paul Koning <ni1d@arrl.net>
16911
16912 * config/pdp11/pdp11.c (pdp11_addr_cost): New function.
16913 (pdp11_insn_cost): New function.
16914 (pdp11_md_asm_adjust): New function.
16915 (TARGET_INVALID_WITHIN_DOLOOP): Define.
16916 (pdp11_rtx_costs): Update to match machine better.
16917 (output_addr_const_pdp11): Correct format mismatch warnings.
16918 * config/pdp11/pdp11.h (SLOW_BYTE_ACCESS): Correct definition.
16919 * config/pdp11/pdp11.md: General change to add base_cost and/or
16920 length attributes for use by new pdp11_insn_cost function.
16921 (MIN_BRANCH): Correct definition.
16922 (MIN_SOB): Ditto.
16923 (doloop_end): Use standard pattern name for looping pattern.
16924 (doloop_end_nocc): New.
16925 (movsf): Add another constraint alternative.
16926 (zero_extendqihi2): Add constraint alternatives for not in place
16927 extend.
16928 (zero_extendhisi2): Remove.
16929 (shift patterns): Add CC handling variants.
16930 (bswaphi2): New.
16931 (bswapsi2): New.
16932 (rothi3): New.
16933 (define_peephole2): New peephole to recognize mov that sets CC for
16934 subsequent test.
16935
16936 2018-07-09 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
16937
16938 * config/sparc/sparc.c (sparc_fold_builtin) <SPARC_BUILTIN_PDIST,
16939 SPARC_BUILTIN_PDISTN>: Adapt for signature change of wi::neg,
16940 wi::add.
16941
16942 2018-07-09 Jakub Jelinek <jakub@redhat.com>
16943
16944 PR c/86420
16945 * real.c (real_nextafter): Return true if result is denormal.
16946
16947 2018-07-09 Martin Liska <mliska@suse.cz>
16948
16949 * common.opt: Add back wrongly removed attribute.
16950
16951 2018-07-09 Richard Biener <rguenther@suse.de>
16952
16953 PR debug/86413
16954 * dwarf2out.c (gen_block_die): For an early generated DIE
16955 always output high/low PC attributes.
16956
16957 2018-07-09 Tom de Vries <tdevries@suse.de>
16958
16959 * cfgexpand.c (expand_debug_source_expr): Handle VAR_DECL.
16960 * tree-inline.c (remap_ssa_name): Handle default def ssa_name mapping
16961 onto VAR_DECL with abstract origin.
16962
16963 2018-07-07 Jim Wilson <jimw@sifive.com>
16964
16965 * config/riscv/riscv.c (TARGET_CUSTOM_FUNCTION_DESCRIPTORS): New.
16966
16967 2018-07-07 Tom de Vries <tdevries@suse.de>
16968
16969 * tree-dfa.c (dump_enumerated_decls): Handle cfun->cfg == NULL.
16970
16971 2018-07-07 Aldy Hernandez <aldyh@redhat.com>
16972
16973 * tree-vrp.c (vrp_int_const_binop): Change overflow type to
16974 overflow_type.
16975 (combine_bound): Use wide-int overflow calculation instead of
16976 rolling our own.
16977 * calls.c (maybe_warn_alloc_args_overflow): Change overflow type to
16978 overflow_type.
16979 * fold-const.c (int_const_binop_2): Same.
16980 (extract_muldiv_1): Same.
16981 (fold_div_compare): Same.
16982 (fold_abs_const): Same.
16983 * match.pd: Same.
16984 * poly-int.h (add): Same.
16985 (sub): Same.
16986 (neg): Same.
16987 (mul): Same.
16988 * predict.c (predict_iv_comparison): Same.
16989 * profile-count.c (slow_safe_scale_64bit): Same.
16990 * simplify-rtx.c (simplify_const_binary_operation): Same.
16991 * tree-chrec.c (tree_fold_binomial): Same.
16992 * tree-data-ref.c (split_constant_offset_1): Same.
16993 * tree-if-conv.c (idx_within_array_bound): Same.
16994 * tree-scalar-evolution.c (iv_can_overflow_p): Same.
16995 * tree-ssa-phiopt.c (minmax_replacement): Same.
16996 * tree-vect-loop.c (is_nonwrapping_integer_induction): Same.
16997 * tree-vect-stmts.c (vect_truncate_gather_scatter_offset): Same.
16998 * vr-values.c (vr_values::adjust_range_with_scev): Same.
16999 * wide-int.cc (wi::add_large): Same.
17000 (wi::mul_internal): Same.
17001 (wi::sub_large): Same.
17002 (wi::divmod_internal): Same.
17003 * wide-int.h: Change overflow type to overflow_type for neg, add,
17004 mul, smul, umul, div_trunc, div_floor, div_ceil, div_round,
17005 mod_trunc, mod_ceil, mod_round, add_large, sub_large,
17006 mul_internal, divmod_internal.
17007 (overflow_type): New enum.
17008 (accumulate_overflow): New.
17009
17010 2018-07-06 Kugan Vivekanandarajah <kugan.vivekanandarajah@linaro.org>
17011
17012 * tree-ssa-phiopt.c (cond_removal_in_popcount_pattern): New.
17013 (tree_ssa_phiopt_worker): Call cond_removal_in_popcount_pattern.
17014
17015 2018-07-06 Kugan Vivekanandarajah <kuganv@linaro.org>
17016
17017 * tree-ssa-loop-niter.c (number_of_iterations_popcount): If popcount
17018 argument is checked for zero before entering loop, avoid checking again.
17019
17020 2018-07-06 Kugan Vivekanandarajah <kuganv@linaro.org>
17021
17022 * gimplify.h (generic_expr_could_trap_p): Set as global function.
17023 * gimplify.h (generic_expr_could_trap_p): Likwise.
17024 * tree-scalar-evolution.c (expression_expensive_p): Handle COND_EXPR.
17025
17026 2018-07-06 Jakub Jelinek <jakub@redhat.com>
17027
17028 PR tree-optimization/86401
17029 * fold-const.c (fold_binary_loc) <case BIT_AND_EXPR>: Move the
17030 ((A & N) + B) & M -> (A + B) & M etc. optimization into ...
17031 (fold_bit_and_mask): ... here. New helper function for match.pd.
17032 * fold-const.h (fold_bit_and_mask): Declare.
17033 * match.pd (((A & N) + B) & M -> (A + B) & M): New optimization.
17034
17035 2018-07-06 Peter Bergner <bergner@linux.ibm.com>
17036
17037 PR target/86324
17038 * target.def (translate_mode_attribute): New hook.
17039 * targhooks.h (default_translate_mode_attribute): Declare.
17040 * targhooks.c (default_translate_mode_attribute): New function.
17041 * doc/tm.texi.in (TARGET_TRANSLATE_MODE_ATTRIBUTE): New hook.
17042 * doc/tm.texi: Regenerate.
17043 * config/rs6000/rs6000.c (TARGET_TRANSLATE_MODE_ATTRIBUTE): Define.
17044 (rs6000_translate_mode_attribute): New function.
17045
17046 2018-07-06 Paul Koning <ni1d@arrl.net>
17047
17048 * doc/md.texi (define_split): Document DONE and FAIL.
17049 (define_peephole2): Ditto.
17050
17051 2018-07-05 Jeff Law <law@redhat.com>
17052
17053 PR tree-optimization/86010
17054 * tree-ssa-dse.c (compute_trims): More aggressively trim at
17055 both the head and tail of mem* and str* calls.
17056
17057 2018-07-05 Jim Wilson <jimw@sifive.com>
17058
17059 * config.gcc (riscv*-*-*): When setting xlen, handle riscv-*.
17060
17061 2018-07-05 Indu Bhagat <indu.bhagat@oracle.com>
17062
17063 * config/aarch64/aarch64-simd.md: correct flags text for
17064 MIN_EXPR replacement.
17065
17066 2018-07-05 James Clarke <jrtc27@jrtc27.com>
17067
17068 * configure: Regenerated.
17069
17070 2018-07-05 Carl Love <cel@us.ibm.com>
17071
17072 * config/rs6000/rs6000-c.c: Map ALTIVEC_BUILTIN_VEC_UNPACKH for
17073 float argument to VSX_BUILTIN_DOUBLEH_V4SF.
17074 Map ALTIVEC_BUILTIN_VEC_UNPACKL for float argument to
17075 VSX_BUILTIN_DOUBLEL_V4SF.
17076
17077 2018-07-05 Martin Sebor <msebor@redhat.com>
17078
17079 PR c++/86400
17080 * tree-ssa-strlen.c (maybe_set_strlen_range): Use type size rather
17081 than its domain to compute its the upper bound of a char array.
17082
17083 2018-07-05 Nathan Sidwell <nathan@acm.org>
17084
17085 Replace NO_IMPLICIT_EXTERN_C with SYSTEM_IMPLICIT_EXTERN_C.
17086 * doc/cpp.texi: Update comment.
17087 * doc/tm.texi: Rebuilt.
17088 * doc/tm.texi.in (NO_IMPLICIT_EXTERN_C): Replace with ...
17089 (SYSTEM_IMPLICIT_EXTERN_C): ... this, opposite sense.
17090 * doc/extend.texi (Backwards Compatibility): Clarify it is system
17091 headers affected by extern "C".
17092 * system.h: Poison NO_IMPLICIT_EXTERN_C.
17093 * config/alpha/alpha.h, config/arm/uclinux-elf.h,
17094 config/bfin/elf.h, config/cris/cris.h, config/darwin.h,
17095 config/dragonfly.h, config/freebsd.h, config/gnu-user.h,
17096 config/i386/cygming.h, config/i386/djgpp.h, config/i386/nto.h,
17097 config/ia64/hpux.h, config/lm32/lm32.h, config/lm32/uclinux-elf.h,
17098 config/lynx.h, config/mips/elf.h, config/mmix/mmix.h,
17099 config/netbsd.h, config/pa/pa-hpux.h, config/powerpcspe/sysv4.h,
17100 config/riscv/elf.h, config/rs6000/sysv4.h, config/rtems.h,
17101 config/s390/tpf.h, config/sh/newlib.h, config/sol2.h,
17102 config/sparc/openbsd64.h, config/sparc/sp-elf.h,
17103 config/sparc/sp64-elf.h, config/spu/spu.h,
17104 config/stormy16/stormy16.h, config/v850/v850.h,
17105 config/visium/visium.h, config/vx-common.h, config/xtensa/elf.h: Don't
17106 define NO_IMPLICIT_EXTERN_C.
17107 * config/rs6000/aix.h: Set SYSTEM_IMPLICIT_EXTERN_C.
17108
17109 2018-07-05 Tamar Christina <tamar.christina@arm.com>
17110
17111 PR target/84711
17112 * config/arm/arm.c (arm_can_change_mode_class): Use GET_MODE_UNIT_SIZE
17113 instead of GET_MODE_SIZE when comparing Units.
17114
17115 2018-07-05 Tamar Christina <tamar.christina@arm.com>
17116
17117 PR target/84711
17118 * rtlanal.c (set_noop_p): Constrain on mode change,
17119 include hard-reg-set.h
17120
17121 2018-07-05 Tamar Christina <tamar.christina@arm.com>
17122
17123 * config/aarch64/aarch64.c (aarch64_expand_movmem): Fix mode size.
17124
17125 2018-07-05 Jakub Jelinek <jakub@redhat.com>
17126
17127 Revert
17128 2018-07-04 Maxim Ostapenko <m.ostapenko@samsung.com>
17129
17130 PR sanitizer/84250
17131 * config/gnu-user.h (LIBASAN_EARLY_SPEC): Pass -lstdc++ for static
17132 libasan.
17133 * gcc.c: Do not pass LIBUBSAN_SPEC if ASan is enabled with UBSan.
17134
17135 2018-07-04 Maxim Ostapenko <m.ostapenko@samsung.com>
17136
17137 PR sanitizer/84250
17138 * config/gnu-user.h (LIBASAN_EARLY_SPEC): Pass -lstdc++ for static
17139 libasan.
17140 * gcc.c: Do not pass LIBUBSAN_SPEC if ASan is enabled with UBSan.
17141
17142 2018-07-04 Eric Botcazou <ebotcazou@adacore.com>
17143
17144 PR middle-end/86380
17145 * expmed.c (choose_multiplier): Fix incorrect comparison with mask.
17146
17147 2018-07-04 Aldy Hernandez <aldyh@redhat.com>
17148
17149 * tree-vrp.c (extract_range_from_binary_expr_1): Initialize
17150 neg_*_op* variables.
17151
17152 2018-07-04 Martin Liska <mliska@suse.cz>
17153
17154 * tree-switch-conversion.c: Define
17155 max_ratio_for_speed and max_ratio_for_size constants.
17156
17157 2018-07-04 Denys Vlasenko <dvlasenk@redhat.com>
17158 Martin Liska <mliska@suse.cz>
17159
17160 PR middle-end/66240
17161 PR target/45996
17162 PR c/84100
17163 * common.opt: Rename align options with 'str_' prefix.
17164 * common/config/i386/i386-common.c (set_malign_value): New
17165 function.
17166 (ix86_handle_option): Use it to set -falign-* options/
17167 * config/aarch64/aarch64-protos.h (struct tune_params): Change
17168 type from int to string.
17169 * config/aarch64/aarch64.c: Update default values from int
17170 to string.
17171 * config/alpha/alpha.c (alpha_override_options_after_change):
17172 Likewise.
17173 * config/arm/arm.c (arm_override_options_after_change_1): Likewise.
17174 * config/i386/dragonfly.h (ASM_OUTPUT_MAX_SKIP_ALIGN): Print
17175 max skip conditionally.
17176 * config/i386/freebsd.h (SUBALIGN_LOG): New.
17177 (ASM_OUTPUT_MAX_SKIP_ALIGN): Print
17178 max skip conditionally.
17179 * config/i386/gas.h (ASM_OUTPUT_MAX_SKIP_ALIGN): Print
17180 max skip conditionally.
17181 * config/i386/gnu-user.h (SUBALIGN_LOG): New.
17182 (ASM_OUTPUT_MAX_SKIP_ALIGN): Print
17183 max skip conditionally.
17184 * config/i386/i386.c (struct ptt): Change type from int to
17185 string.
17186 (ix86_default_align): Set default values.
17187 * config/i386/i386.h (ASM_OUTPUT_MAX_SKIP_PAD): Print
17188 max skip conditionally.
17189 * config/i386/iamcu.h (SUBALIGN_LOG): New.
17190 (ASM_OUTPUT_MAX_SKIP_ALIGN):
17191 * config/i386/lynx.h (ASM_OUTPUT_MAX_SKIP_ALIGN):
17192 * config/i386/netbsd-elf.h (ASM_OUTPUT_MAX_SKIP_ALIGN): Print
17193 max skip conditionally.
17194 * config/i386/openbsdelf.h (SUBALIGN_LOG): New.
17195 (ASM_OUTPUT_MAX_SKIP_ALIGN) Print max skip conditionally.:
17196 * config/i386/x86-64.h (SUBALIGN_LOG): New.
17197 (ASM_OUTPUT_MAX_SKIP_ALIGN): Print
17198 max skip conditionally.
17199 (ASM_OUTPUT_MAX_SKIP_PAD): Likewise.
17200 * config/ia64/ia64.c (ia64_option_override): Set default values
17201 for alignment options.
17202 * config/m68k/m68k.c: Handle new str_align_* options.
17203 * config/mips/mips.c (mips_set_compression_mode): Change
17204 type of constants.
17205 (mips_option_override): Set default values for options.
17206 * config/powerpcspe/powerpcspe.c (rs6000_option_override_internal):
17207 Likewise.
17208 * config/rs6000/rs6000.c (rs6000_option_override_internal):
17209 Likewise.
17210 * config/rx/rx.c (rx_option_override): Likewise.
17211 * config/rx/rx.h (JUMP_ALIGN): Use align_jumps_log.
17212 (LABEL_ALIGN): Use align_labels_log.
17213 (LOOP_ALIGN): Use align_loops_align.
17214 * config/s390/s390.c (s390_asm_output_function_label): Use new
17215 macros.
17216 * config/sh/sh.c (sh_override_options_after_change):
17217 Change type of constants.
17218 * config/spu/spu.c (spu_sched_init): Likewise.
17219 * config/sparc/sparc.c (sparc_option_override): Set default
17220 values for options.
17221 * config/visium/visium.c (visium_option_override): Likewise.
17222 * config/visium/visium.h (ASM_OUTPUT_MAX_SKIP_ALIGN): Do not
17223 emit p2align format with last argument if it's not needed.
17224 * doc/invoke.texi: Document extended format of -falign-*.
17225 * final.c: Use align_labels alignment.
17226 * flags.h (struct target_flag_state): Change type to use
17227 align_flags.
17228 (struct align_flags_tuple): New.
17229 (struct align_flags): Likewise.
17230 (align_loops_log): Redefine macro to use new types.
17231 (align_loops_max_skip): Redefine macro to use new types.
17232 (align_jumps_log): Redefine macro to use new types.
17233 (align_jumps_max_skip): Redefine macro to use new types.
17234 (align_labels_log): Redefine macro to use new types.
17235 (align_labels_max_skip): Redefine macro to use new types.
17236 (align_functions_log): Redefine macro to use new types.
17237 (align_loops): Redefine macro to use new types.
17238 (align_jumps): Redefine macro to use new types.
17239 (align_labels): Redefine macro to use new types.
17240 (align_functions): Redefine macro to use new types.
17241 (align_functions_max_skip): Redefine macro to use new types.
17242 (align_loops_value): New macro.
17243 (align_jumps_value): New macro.
17244 (align_labels_value): New macro.
17245 (align_functions_value): New macro.
17246 * function.c (invoke_set_current_function_hook): Propagate
17247 alignment values from flags to global variables default in
17248 topleev.h.
17249 * ipa-icf.c (sem_function::equals_wpa): Use
17250 cl_optimization_option_eq instead of memcmp.
17251 * lto-streamer.h (cl_optimization_stream_out): Support streaming
17252 of string types.
17253 (cl_optimization_stream_in): Likewise.
17254 * optc-save-gen.awk: Support strings in cl_optimization.
17255 * opth-gen.awk: Likewise.
17256 * opts.c (finish_options): Remove error checking of invalid
17257 value ranges.
17258 (MAX_CODE_ALIGN): Remove.
17259 (MAX_CODE_ALIGN_VALUE): Likewise.
17260 (parse_and_check_align_values): New function.
17261 (check_alignment_argument): Likewise.
17262 (common_handle_option): Use check_alignment_argument.
17263 * opts.h (parse_and_check_align_values): Declare.
17264 * toplev.c (init_alignments): Remove.
17265 (read_log_maxskip): New.
17266 (parse_N_M): Likewise.
17267 (parse_alignment_opts): Likewise.
17268 (backend_init_target): Remove usage of init_alignments.
17269 * toplev.h (parse_alignment_opts): Declare.
17270 * tree-streamer-in.c (streamer_read_tree_bitfields): Add new
17271 argument.
17272 * tree-streamer-out.c (streamer_write_tree_bitfields): Likewise.
17273 * tree.c (cl_option_hasher::equal): New.
17274 * varasm.c: Use new global macros.
17275
17276 2018-07-04 Denys Vlasenko <dvlasenk@redhat.com>
17277
17278 * config/i386/dragonfly.h: (ASM_OUTPUT_MAX_SKIP_ALIGN):
17279 Use a simpler align directive also if MAXSKIP = ALIGN-1.
17280 * config/i386/gas.h (ASM_OUTPUT_MAX_SKIP_ALIGN): Likewise.
17281 * config/i386/lynx.h (ASM_OUTPUT_MAX_SKIP_ALIGN): Likewise.
17282 * config/i386/netbsd-elf.h (ASM_OUTPUT_MAX_SKIP_ALIGN): Likewise.
17283 * config/i386/i386.h (ASM_OUTPUT_MAX_SKIP_PAD): Likewise.
17284 * config/i386/freebsd.h (ASM_OUTPUT_MAX_SKIP_ALIGN): Remove "If N
17285 is large, do at least 8 byte alignment" code. Add SUBALIGN_LOG
17286 define. Use a simpler align directive also if MAXSKIP = ALIGN-1.
17287 * config/i386/gnu-user.h (ASM_OUTPUT_MAX_SKIP_ALIGN): Likewise.
17288 * config/i386/iamcu.h (ASM_OUTPUT_MAX_SKIP_ALIGN): Likewise.
17289 * config/i386/openbsdelf.h (ASM_OUTPUT_MAX_SKIP_ALIGN): Likewise.
17290 * config/i386/x86-64.h (ASM_OUTPUT_MAX_SKIP_ALIGN): Likewise.
17291
17292 2018-07-04 Martin Liska <mliska@suse.cz>
17293 Jonathan Wakely <jwakely@redhat.com>
17294
17295 * coverage.c: Use correct type.
17296 * doc/invoke.texi: Language correction.
17297
17298 2018-07-03 H.J. Lu <hongjiu.lu@intel.com>
17299
17300 PR target/85620
17301 * config/i386/i386.c (rest_of_insert_endbranch): Also generate
17302 ENDBRANCH for non-tail call which may return via indirect branch.
17303 * doc/extend.texi: Document indirect_return attribute.
17304
17305 2018-07-03 Martin Sebor <msebor@redhat.com>
17306
17307 PR tree-optimization/86274
17308 * gimple-ssa-sprintf.c (fmtresult::type_max_digits): Verify
17309 precondition.
17310 (format_floating): Correct handling of infinities and NaNs.
17311
17312 2018-07-03 Martin Sebor <msebor@redhat.com>
17313
17314 * print-tree.c (print_real_cst): New function.
17315 (print_node_brief): Call it.
17316 (print_node): Ditto.
17317
17318 2018-07-03 Jeff Law <law@redhat.com>
17319
17320 * config/h8300/h8300.md (logical<mode>3_sn, logical<mode>3): Merge
17321 into a single pattern.
17322
17323 * config/h8300/h8300.md (ors code_iterator): New.
17324 (bsetqi_msx, bnotqi_msx patterns and splitters): Consolidate into
17325 a single pattern and single splitter.
17326 (bsethi_msx, bnothi_msx patterns): Consolidate into a single pattern.
17327 (iorqi3_1, xorqi3_1): Likewise.
17328 (iorqi3, xorqi3 expanders): Similarly.
17329
17330 * config/h8300/h8300.md (movmd_internal_normal): Consolidated with
17331 (movmd_internal) into a single pattern using the P mode iterator.
17332 (movmd splitters): Similarly.
17333 (stpcpy_internal_normal, stpcpy_internal): Similarly for thes patterns.
17334 (movsd splitters): Similarly.
17335
17336 * config/h8300/h8300.c (h8300_insn_length_from_table): Consolidate
17337 ADDB, ADDW and ADDL into a single ADD attribute which selects the
17338 right table based on the size of the operand.
17339 * config/h8300/h8300.md (length_table): Corresponding changes. All
17340 references to "addb", "addw" and "addl" changed to "add".
17341 (btst patterns): Merge two variants into a single pattern.
17342 (tstqi, tsthi): Likewise.
17343 (addhi3_incdec, addsi3_incdec): Likewise.
17344 (subhi3_h8300hs, subsi3_h8300hs): Likewise.
17345 (mulhi3, mulsi3): Likewise.
17346 (udivhi3, udivsi3): Likewise.
17347 (divhi3, divsi3): Likewise.
17348 (andorqi3, andorhi3, andorsi3): Likewise.
17349
17350 2018-07-03 Uros Bizjak <ubizjak@gmail.com>
17351
17352 PR target/85694
17353 * config/i386/sse.md (uavg<mode>3_ceil): New expander.
17354 (<sse2_avx2>_uavg<mode>3<mask_name>): Simplify expander.
17355
17356 2018-07-03 Richard Sandiford <richard.sandiford@arm.com>
17357
17358 PR tree-optimization/85694
17359 * config/aarch64/iterators.md (HADD, RHADD): New int iterators.
17360 (u): Handle UNSPEC_SHADD, UNSPEC_UHADD, UNSPEC_SRHADD and
17361 UNSPEC_URHADD.
17362 * config/aarch64/aarch64-simd.md (<u>avg<mode>3_floor)
17363 (<u>avg<mode>3_ceil): New patterns.
17364
17365 2018-07-03 David Malcolm <dmalcolm@redhat.com>
17366
17367 * gcc.dg/vect/slp-perm-1.c: Remove "note: " prefix from
17368 scan-tree-dump directive.
17369 * gcc.dg/vect/slp-perm-2.c: Likewise.
17370 * gcc.dg/vect/slp-perm-3.c: Likewise.
17371 * gcc.dg/vect/slp-perm-5.c: Likewise.
17372 * gcc.dg/vect/slp-perm-6.c: Likewise.
17373 * gcc.dg/vect/slp-perm-7.c: Likewise.
17374 * gcc.dg/vect/slp-perm-8.c: Likewise.
17375
17376 2018-07-03 Marek Polacek <polacek@redhat.com>
17377
17378 PR middle-end/86202
17379 * gimple-fold.c (size_must_be_zero_p): Check the type of the size.
17380
17381 2018-07-03 Richard Biener <rguenther@suse.de>
17382
17383 PR ipa/86389
17384 * tree-ssa-structalias.c (find_func_clobbers): Properly
17385 handle indirect calls.
17386
17387 2018-07-03 Jeff Law <law@redhat.com>
17388
17389 * config/h8300/h8300.md (HSI, QHSI, QHSIF): New mode iterators.
17390 (shifts): New code iterator.
17391 (movqi, movhi, movsi, movsf expanders): Consolidate into a single
17392 expander. Fix HImode handling on H8/SX.
17393 (addqi3, addhi3, addsi3 expanders): Consolidate into a single expander.
17394 (subqi3, subhi3, subsi3 expanders): Likewise.
17395 (andqi3, andhi3, andsi3 expanders): Likewise.
17396 (iorqi3, iorhi3, iorsi3 expanders): Likewise.
17397 (xorqi3, xorhi3, xorsi3 expanders): Likewise.
17398 (negqi2, neghi2, negsi2, negsf2 expanders): Likewise.
17399 (one_cmplqi2, one_cmplhi2, one_cmplsi2): Likewise.
17400 (zero_extendqihi2, zero_extendqisi2): Likewise.
17401 (extendqihi2, extendqisi2): Likewise.
17402 (rotlqi3, rotlhi3, rotlsi3): Likewise.
17403 (neghi2_h8300, negsi2_h8300): Likewise for these patterns.
17404 (rotlqi3_1, rotlhi3_1): Likewise.
17405 (logicalhi3_sn, logicalsi3_sn): Likewise.
17406 (logicalhi3, logicalsi3): Likewise.
17407
17408 2018-07-03 Richard Sandiford <richard.sandiford@arm.com>
17409
17410 * tree-vect-patterns.c (vect_recog_rotate_pattern)
17411 (vect_recog_vector_vector_shift_pattern, vect_recog_divmod_pattern)
17412 (vect_recog_mixed_size_cond_pattern, adjust_bool_pattern_cast)
17413 (adjust_bool_pattern, vect_recog_bool_pattern): Pass the vector
17414 type to append_pattern_def_seq instead of creating a stmt_vec_info
17415 directly.
17416 (build_mask_conversion): Likewise. Remove vinfo argument.
17417 (vect_add_conversion_to_patterm): Likewise, renaming to...
17418 (vect_add_conversion_to_pattern): ...this.
17419 (vect_recog_mask_conversion_pattern): Update call to
17420 build_mask_conversion. Pass the vector type to
17421 append_pattern_def_seq here too.
17422 (vect_recog_gather_scatter_pattern): Update call to
17423 vect_add_conversion_to_pattern.
17424
17425 2018-07-03 Richard Sandiford <richard.sandiford@arm.com>
17426
17427 * tree-vect-patterns.c (new_pattern_def_seq): Delete.
17428 (vect_recog_dot_prod_pattern, vect_recog_sad_pattern)
17429 (vect_recog_widen_op_pattern, vect_recog_over_widening_pattern)
17430 (vect_recog_rotate_pattern, vect_synth_mult_by_constant): Don't set
17431 STMT_VINFO_PATTERN_DEF_SEQ to null here.
17432 (vect_recog_pow_pattern, vect_recog_vector_vector_shift_pattern)
17433 (vect_recog_mixed_size_cond_pattern, vect_recog_bool_pattern): Use
17434 append_pattern_def_seq instead of new_pattern_def_seq.
17435 (vect_recog_divmod_pattern): Do both of the above.
17436 (vect_pattern_recog_1): Assert that STMT_VINO_PATTERN_DEF_SEQ
17437 is null.
17438
17439 2018-07-03 Richard Sandiford <richard.sandiford@arm.com>
17440
17441 * tree-vect-patterns.c (vect_recog_dot_prod_pattern):
17442 (vect_recog_sad_pattern, vect_recog_widen_op_pattern)
17443 (vect_recog_widen_mult_pattern, vect_recog_pow_pattern):
17444 (vect_recog_widen_sum_pattern, vect_recog_over_widening_pattern)
17445 (vect_recog_average_pattern, vect_recog_cast_forwprop_pattern)
17446 (vect_recog_widen_shift_pattern, vect_recog_rotate_pattern)
17447 (vect_recog_vector_vector_shift_pattern, vect_synth_mult_by_constant)
17448 (vect_recog_mult_pattern, vect_recog_divmod_pattern)
17449 (vect_recog_mixed_size_cond_pattern, vect_recog_bool_pattern)
17450 (vect_recog_mask_conversion_pattern): Replace vec<gimple *>
17451 parameter with a single stmt_vec_info.
17452 (vect_recog_func_ptr): Likewise.
17453 (vect_recog_gather_scatter_pattern): Likewise, folding in...
17454 (vect_try_gather_scatter_pattern): ...this.
17455 (vect_pattern_recog_1): Remove stmts_to_replace and just pass
17456 the stmt_vec_info of the statement to be matched. Don't clear
17457 STMT_VINFO_RELATED_STMT.
17458 (vect_pattern_recog): Update call accordingly.
17459
17460 2018-07-03 Richard Sandiford <richard.sandiford@arm.com>
17461
17462 PR tree-optimization/85694
17463 * doc/md.texi (avgM3_floor, uavgM3_floor, avgM3_ceil)
17464 (uavgM3_ceil): Document new optabs.
17465 * doc/sourcebuild.texi (vect_avg_qi): Document new target selector.
17466 * internal-fn.def (IFN_AVG_FLOOR, IFN_AVG_CEIL): New internal
17467 functions.
17468 * optabs.def (savg_floor_optab, uavg_floor_optab, savg_ceil_optab)
17469 (savg_ceil_optab): New optabs.
17470 * tree-vect-patterns.c (vect_recog_average_pattern): New function.
17471 (vect_vect_recog_func_ptrs): Add it.
17472 * tree-vect-stmts.c (vectorizable_call): Get the type of the zero
17473 constant directly from the associated lhs.
17474
17475 2018-07-03 Richard Sandiford <richard.sandiford@arm.com>
17476
17477 * tree-vect-patterns.c (vect_split_statement): New function.
17478 (vect_convert_input): Use it to try to split an existing cast.
17479
17480 2018-07-03 Richard Sandiford <richard.sandiford@arm.com>
17481
17482 * poly-int.h (print_hex): New function.
17483 * dumpfile.h (dump_dec, dump_hex): Declare.
17484 * dumpfile.c (dump_dec, dump_hex): New poly_wide_int functions.
17485 * tree-vectorizer.h (_stmt_vec_info): Add min_output_precision,
17486 min_input_precision, operation_precision and operation_sign.
17487 * tree-vect-patterns.c (vect_get_range_info): New function.
17488 (vect_same_loop_or_bb_p, vect_single_imm_use)
17489 (vect_operation_fits_smaller_type): Delete.
17490 (vect_look_through_possible_promotion): Add an optional
17491 single_use_p parameter.
17492 (vect_recog_over_widening_pattern): Rewrite to use new
17493 stmt_vec_info infomration. Handle one operation at a time.
17494 (vect_recog_cast_forwprop_pattern, vect_narrowable_type_p)
17495 (vect_truncatable_operation_p, vect_set_operation_type)
17496 (vect_set_min_input_precision): New functions.
17497 (vect_determine_min_output_precision_1): Likewise.
17498 (vect_determine_min_output_precision): Likewise.
17499 (vect_determine_precisions_from_range): Likewise.
17500 (vect_determine_precisions_from_users): Likewise.
17501 (vect_determine_stmt_precisions, vect_determine_precisions): Likewise.
17502 (vect_vect_recog_func_ptrs): Put over_widening first.
17503 Add cast_forwprop.
17504 (vect_pattern_recog): Call vect_determine_precisions.
17505
17506 2018-07-03 Richard Sandiford <richard.sandiford@arm.com>
17507
17508 * tree-vect-patterns.c (vect_mark_pattern_stmts): Remove pattern
17509 statements that have been replaced by further pattern statements.
17510 (vect_pattern_recog_1): Clear STMT_VINFO_PATTERN_DEF_SEQ on failure.
17511
17512 2018-07-03 Richard Biener <rguenther@suse.de>
17513
17514 * tree-vect-stmts.c (vect_is_simple_use): Consolidate dumping,
17515 always set *dt. Dump vectype in vectype overload.
17516 * dumpfile.h (dump_gimple_expr): New function.
17517 (dump_gimple_expr_loc): Likewise.
17518 * dumpfile.c (dump_gimple_expr): New function.
17519 (dump_gimple_expr_loc): Likewise.
17520
17521 2018-07-02 Jeff Law <law@redhat.com>
17522
17523 * config/h8300/h8300.md (movqi_h8300, movqi_h8300hs): Consolidate
17524 the H8/300, H8/300H and H8/S variants into a single pattern.
17525 (movhi_h8300, movqi_h8300hs): Similarly.
17526 (pushqi_h8300hs, pushhi_h8300hs): Consolidate into a single pattern.
17527 (QHI mode iterator): New.
17528
17529 * config/h8300/h8300.md: Remove trailing whitespace.
17530
17531 2018-07-02 Jim Wilson <jimw@sifive.com>
17532
17533 * config/riscv/riscv.c (riscv_expand_epilogue): Use emit_jump_insn
17534 instead of emit_insn for interrupt returns.
17535 * config/riscv/riscv.md (riscv_met): Add (return) to rtl.
17536 (riscv_sret, riscv_uret): Likewise.
17537
17538 2018-07-02 David Malcolm <dmalcolm@redhat.com>
17539
17540 * pretty-print.c (selftest::test_pp_format): Move save and restore
17541 of quotes to class auto_fix_quotes, and add an instance.
17542 * selftest.c: Include "intl.h".
17543 (selftest::auto_fix_quotes::auto_fix_quotes): New ctor.
17544 (selftest::auto_fix_quotes::~auto_fix_quotes): New dtor.
17545 * selftest.h (selftest::auto_fix_quotes): New class.
17546
17547 2018-07-02 Richard Henderson <richard.henderson@linaro.org>
17548
17549 * config/aarch64/aarch64-protos.h, config/aarch64/aarch64.c
17550 (aarch64_sve_prepare_conditional_op): Remove.
17551 * config/aarch64/aarch64-sve.md (cond_<SVE_INT_BINARY><SVE_I>):
17552 Allow aarch64_simd_reg_or_zero as select operand; remove
17553 the aarch64_sve_prepare_conditional_op call.
17554 (cond_<SVE_INT_BINARY_SD><SVE_SDI>): Likewise.
17555 (cond_<SVE_COND_FP_BINARY><SVE_F>): Likewise.
17556 (*cond_<SVE_INT_BINARY><SVE_I>_z): New pattern.
17557 (*cond_<SVE_INT_BINARY_SD><SVE_SDI>_z): New pattern.
17558 (*cond_<SVE_COND_FP_BINARY><SVE_F>_z): New pattern.
17559 (*cond_<SVE_INT_BINARY><SVE_I>_any): New pattern.
17560 (*cond_<SVE_INT_BINARY_SD><SVE_SDI>_any): New pattern.
17561 (*cond_<SVE_COND_FP_BINARY><SVE_F>_any): New pattern
17562 and a splitters to match all of the *_any patterns.
17563 * config/aarch64/predicates.md (aarch64_sve_any_binary_operator): New.
17564
17565 * config/aarch64/iterators.md (SVE_INT_BINARY_REV): Remove.
17566 (SVE_COND_FP_BINARY_REV): Remove.
17567 (sve_int_op_rev, sve_fp_op_rev): New.
17568 * config/aarch64/aarch64-sve.md (*cond_<SVE_INT_BINARY><SVE_I>_0): New.
17569 (*cond_<SVE_INT_BINARY_SD><SVE_SDI>_0): New.
17570 (*cond_<SVE_COND_FP_BINARY><SVE_F>_0): New.
17571 (*cond_<SVE_INT_BINARY><SVE_I>_2): Rename, add movprfx alternative.
17572 (*cond_<SVE_INT_BINARY_SD><SVE_SDI>_2): Similarly.
17573 (*cond_<SVE_COND_FP_BINARY><SVE_F>_2): Similarly.
17574 (*cond_<SVE_INT_BINARY><SVE_I>_3): Similarly; use sve_int_op_rev.
17575 (*cond_<SVE_INT_BINARY_SD><SVE_SDI>_3): Similarly.
17576 (*cond_<SVE_COND_FP_BINARY><SVE_F>_3): Similarly; use sve_fp_op_rev.
17577
17578 * config/aarch64/aarch64-sve.md (cond_<SVE_COND_FP_BINARY><SVE_F>):
17579 Remove match_dup 1 from the inner unspec.
17580 (*cond_<SVE_COND_FP_BINARY><SVE_F>): Likewise.
17581
17582 * config/aarch64/aarch64.md (movprfx): New attr.
17583 (length): Default movprfx to 8.
17584 * config/aarch64/aarch64-sve.md (*mul<SVE_I>3): Add movprfx alt.
17585 (*madd<SVE_I>, *msub<SVE_I): Likewise.
17586 (*<su>mul<SVE_I>3_highpart): Likewise.
17587 (*<SVE_INT_BINARY_SD><SVE_SDI>3): Likewise.
17588 (*v<ASHIFT><SVE_I>3): Likewise.
17589 (*<su><MAXMIN><SVE_I>3): Likewise.
17590 (*<su><MAXMIN><SVE_F>3): Likewise.
17591 (*fma<SVE_F>4, *fnma<SVE_F>4): Likewise.
17592 (*fms<SVE_F>4, *fnms<SVE_F>4): Likewise.
17593 (*div<SVE_F>4): Likewise.
17594
17595 2018-07-02 Richard Sandiford <richard.sandiford@arm.com>
17596
17597 * tree-vect-patterns.c (vect_recog_widen_shift_pattern): Fix typo
17598 in dump string.
17599
17600 2018-07-02 Richard Biener <rguenther@suse.de>
17601
17602 PR tree-optimization/86363
17603 * tree-ssa-sccvn.c (vn_reference_lookup_3): Check the
17604 memset argument refers to a non-variable address.
17605
17606 2018-07-02 Aldy Hernandez <aldyh@redhat.com>
17607
17608 * tree-vrp.c (extract_range_from_binary_expr_1): Abstract a lot of the
17609 {PLUS,MINUS}_EXPR code to...
17610 (adjust_symbolic_bound): ...here,
17611 (combine_bound): ...here,
17612 (set_value_range_with_overflow): ...and here.
17613
17614 2018-07-02 Aldy Hernandez <aldyh@redhat.com>
17615
17616 * tree-vrp.c (extract_range_from_unary_expr): Abstract ABS_EXPR
17617 code...
17618 (extract_range_from_abs_expr): ...here.
17619
17620 2018-07-02 Eric Botcazou <ebotcazou@adacore.com>
17621
17622 * config/i386/i386.c (ix86_finalize_stack_frame_flags): Do not overrule
17623 -fno-omit-frame-pointer when not optimizing.
17624
17625 2018-07-02 Martin Liska <mliska@suse.cz>
17626
17627 PR ipa/86279
17628 * ipa-pure-const.c (malloc_candidate_p): Revert usage of ::get.
17629 (propagate_nothrow): Likewise.
17630
17631 2018-07-02 Martin Liska <mliska@suse.cz>
17632
17633 PR ipa/86323
17634 * ipa-inline.c (early_inliner): Revert wrongly added ::get call.
17635
17636 2018-07-02 David Malcolm <dmalcolm@redhat.com>
17637
17638 * dumpfile.c (dump_generic_expr_loc): Undo removal of this
17639 function in r262149, changing "loc" param from source_location to
17640 const dump_location_t &.
17641 * dumpfile.h (dump_generic_expr_loc): Undo removal of this
17642 declaration, as above.
17643
17644 2018-07-01 Paul Koning <ni1d@arrl.net>
17645
17646 * common/config/pdp11/pdp11-common.c (pdp11_handle_option): Handle
17647 -munit-asm, -mgnu-asm, -mdec-asm.
17648 * config/pdp11/pdp11-protos.h (pdp11_gen_int_label): New.
17649 (pdp11_output_labelref): New.
17650 (pdp11_output_def): New.
17651 (pdp11_output_addr_vec_elt): New.
17652 * config/pdp11/pdp11.c: Use tab between opcode and operands. Use
17653 %# and %@ format codes.
17654 (pdp11_option_override): New.
17655 (TARGET_ASM_FILE_START_FILE_DIRECTIVE): Define.
17656 (pdp11_output_ident): New.
17657 (pdp11_asm_named_section): New.
17658 (pdp11_asm_init_sections): New.
17659 (pdp11_file_start): New.
17660 (pdp11_file_end): New.
17661 (output_ascii): Use .ascii/.asciz for -mdec-asm.
17662 (pdp11_asm_print_operand): Update %# and %$ for -mdec-asm. Add
17663 %o, like %c but octal.
17664 (pdp11_option_override): New.
17665 * config/pdp11/pdp11.h (TEXT_SECTION_ASM_OP): Update for
17666 -mdec-asm.
17667 (DATA_SECTION_ASM_OP): Ditto.
17668 (READONLY_DATA_SECTION_ASM_OP): New.
17669 (IS_ASM_LOGICAL_LINE_SEPARATOR): New.
17670 (ASM_GENERATE_INTERNAL_LABEL): Use new function.
17671 (ASM_OUTPUT_LABELREF): Ditto.
17672 (ASM_OUTPUT_DEF): Ditto.
17673 (ASM_OUTPUT_EXTERNAL): New.
17674 (ASM_OUTPUT_SOURCE_FILENAME): New.
17675 (ASM_OUTPUT_ADDR_VEC_ELT): Use new function.
17676 (ASM_OUTPUT_SKIP): Update for -mdec-asm.
17677 * config/pdp11/pdp11.md: Use tab between opcode and operands. Use
17678 %# and %@ format codes.
17679 * config/pdp11/pdp11.opt (mgnu-asm): New.
17680 (mdec-asm): Conflicts with -mgnu-asm and -munix-asm.
17681 (munix-asm): Conflicts with -mdec-asm and -mgnu-asm.
17682 * doc/invoke.txt (PDP-11 Options): Add -mgnu-asm.
17683
17684 2018-07-01 Aldy Hernandez <aldyh@redhat.com>
17685
17686 * tree-ssa-threadupdate.c (mark_threaded_blocks): Avoid
17687 dereferencing path[] beyond its length.
17688 (debug_path): New.
17689 (debug_all_paths): New.
17690 (rewire_first_differing_edge): New.
17691 (adjust_paths_after_duplication): New.
17692 (duplicate_thread_path): Call adjust_paths_after_duplication.
17693 Add new argument.
17694 (thread_through_all_blocks): Add new argument to
17695 duplicate_thread_path.
17696
17697 2018-06-30 Jim Wilson <jimw@sifive.com>
17698
17699 * config/riscv/predicates.md (p2m1_shift_operand): New.
17700 (high_mask_shift_operand): New.
17701 * config/riscv/riscv.md (lshrsi3_zero_extend_3+1): New combiner
17702 pattern using p2m1_shift_operand.
17703 (lshsi3_zero_extend_3+2): New combiner pattern using
17704 high_mask_shift_operand.
17705
17706 2018-06-30 Richard Sandiford <richard.sandiford@arm.com>
17707
17708 * tree-vect-patterns.c (vect_get_external_def_edge): New function,
17709 split out from...
17710 (vect_recog_rotate_pattern): ...here.
17711 (vect_convert_input): Try to insert casts of invariants in the
17712 preheader.
17713 * tree-vect-loop-manip.c (vect_loop_versioning): Don't require the
17714 preheader to be empty.
17715
17716 2018-06-30 Richard Sandiford <richard.sandiford@arm.com>
17717
17718 * tree-vect-patterns.c (append_pattern_def_seq): Take an optional
17719 vector type. If given, install it in the new statement's
17720 STMT_VINFO_VECTYPE.
17721 (vect_element_precision): New function.
17722 (vect_unpromoted_value): New struct.
17723 (vect_unpromoted_value::vect_unpromoted_value): New function.
17724 (vect_unpromoted_value::set_op): Likewise.
17725 (vect_look_through_possible_promotion): Likewise.
17726 (vect_joust_widened_integer, vect_joust_widened_type): Likewise.
17727 (vect_widened_op_tree, vect_convert_input): Likewise.
17728 (vect_convert_inputs, vect_convert_output): Likewise.
17729 (vect_recog_dot_prod_pattern): Use vect_look_through_possible_promotion
17730 to handle the optional cast of the multiplication result and
17731 vect_widened_op_tree to detect the widened multiplication itself.
17732 Do not require the input and output of promotion casts to have
17733 the same sign, but base the signedness of the operation on the
17734 input rather than the result. If the pattern includes two
17735 promotions, check that those promotions have the same sign.
17736 Do not restrict the MULT_EXPR handling to a double-width result;
17737 handle quadruple-width results and wider. Use vect_convert_inputs
17738 to convert the inputs to the common type.
17739 (vect_recog_sad_pattern): Use vect_look_through_possible_promotion
17740 to handle the optional cast of the ABS result. Also allow a sign
17741 change or a sign extension between the ABS and MINUS.
17742 Use vect_widened_op_tree to detect the widened subtraction and use
17743 vect_convert_inputs to convert the inputs to the common type.
17744 (vect_handle_widen_op_by_const): Delete.
17745 (vect_recog_widen_op_pattern): New function.
17746 (vect_recog_widen_mult_pattern): Use it.
17747 (vect_recog_widen_shift_pattern): Likewise.
17748 (vect_recog_widen_sum_pattern): Use
17749 vect_look_through_possible_promotion to handle the promoted
17750 PLUS_EXPR operand.
17751
17752 2018-06-30 Richard Sandiford <richard.sandiford@arm.com>
17753
17754 * gimple-iterator.c (gsi_for_stmt): Add a new overload that takes
17755 the containing gimple_seq *.
17756 * gimple-iterator.h (gsi_for_stmt): Declare it.
17757 * tree-vect-patterns.c (vect_recog_dot_prod_pattern)
17758 (vect_recog_sad_pattern, vect_recog_widen_sum_pattern)
17759 (vect_recog_widen_shift_pattern, vect_recog_rotate_pattern)
17760 (vect_recog_vector_vector_shift_pattern, vect_recog_divmod_pattern)
17761 (vect_recog_mask_conversion_pattern): Remove STMT_VINFO_IN_PATTERN_P
17762 checks.
17763 (vect_init_pattern_stmt, vect_set_pattern_stmt): New functions,
17764 split out from...
17765 (vect_mark_pattern_stmts): ...here. Handle cases in which the
17766 statement being replaced is part of an existing pattern
17767 definition sequence, inserting the new pattern statements before
17768 the original one.
17769 (vect_pattern_recog_1): Don't return a bool. If the statement
17770 is already part of a pattern, instead apply pattern matching
17771 to the pattern definition statements. Don't clear the
17772 STMT_VINFO_RELATED_STMT if is_pattern_stmt_p.
17773 (vect_pattern_recog): Don't break after the first match;
17774 continue processing the pattern definition statements instead.
17775 Don't bail out for STMT_VINFO_IN_PATTERN_P here.
17776
17777 2018-06-30 Richard Sandiford <richard.sandiford@arm.com>
17778
17779 * tree-vect-patterns.c (vect_reassociating_reduction_p): New function.
17780 (vect_recog_dot_prod_pattern, vect_recog_sad_pattern)
17781 (vect_recog_widen_sum_pattern): Use it.
17782
17783 2018-06-30 Richard Sandiford <richard.sandiford@arm.com>
17784
17785 * tree-vect-loop.c (vectorizable_reduction): Assert that the
17786 phi is not a pattern statement and has not been replaced by
17787 a pattern statement.
17788 * tree-vect-patterns.c (type_conversion_p): Don't check
17789 STMT_VINFO_IN_PATTERN_P.
17790 (vect_recog_vector_vector_shift_pattern): Likewise.
17791 (vect_recog_dot_prod_pattern): Expect vect_is_simple_use to return
17792 the pattern statement rather than the original statement; check
17793 directly for a WIDEN_MULT_EXPR here.
17794 * tree-vect-slp.c (vect_get_and_check_slp_defs): Expect
17795 vect_is_simple_use to return the pattern statement rather
17796 than the original statement; use is_pattern_stmt_p to check
17797 for such a pattern statement.
17798 * tree-vect-stmts.c (process_use): Expect vect_is_simple_use
17799 to return the pattern statement rather than the original statement;
17800 don't do the same transformation here.
17801 (vect_is_simple_use): If the defining statement has been replaced
17802 by a pattern statement, return the pattern statement instead.
17803 Remove the corresponding (local) transformation from the vectype
17804 overload.
17805
17806 2018-06-30 Richard Sandiford <richard.sandiford@arm.com>
17807
17808 * tree-vectorizer.h (vect_is_simple_use): Move the gimple ** to the
17809 end and default to null.
17810 * tree-vect-loop.c (vect_create_epilog_for_reduction)
17811 (vectorizable_reduction): Update calls accordingly, dropping the
17812 gimple ** argument if the passed-back statement isn't needed.
17813 * tree-vect-patterns.c (vect_get_internal_def, type_conversion_p)
17814 (vect_recog_rotate_pattern): Likewise.
17815 (vect_recog_mask_conversion_pattern): Likewise.
17816 * tree-vect-slp.c (vect_get_and_check_slp_defs): Likewise.
17817 (vect_mask_constant_operand_p): Likewise.
17818 * tree-vect-stmts.c (is_simple_and_all_uses_invariant, process_use):
17819 (vect_model_simple_cost, vect_get_vec_def_for_operand): Likewise.
17820 (get_group_load_store_type, get_load_store_type): Likewise.
17821 (vect_check_load_store_mask, vect_check_store_rhs): Likewise.
17822 (vectorizable_call, vectorizable_simd_clone_call): Likewise.
17823 (vectorizable_conversion, vectorizable_assignment): Likewise.
17824 (vectorizable_shift, vectorizable_operation): Likewise.
17825 (vectorizable_store, vect_is_simple_cond): Likewise.
17826 (vectorizable_condition, vectorizable_comparison): Likewise.
17827 (get_same_sized_vectype, vect_get_mask_type_for_stmt): Likewise.
17828 (vect_is_simple_use): Rename the def_stmt argument to def_stmt_out
17829 and move it to the end. Cope with null def_stmt_outs.
17830
17831 2018-06-30 Bernd Edlinger <bernd.edlinger@hotmail.de>
17832
17833 * Makefile.in (FLAGS_TO_PASS): Add RANLIB_FOR_TARGET.
17834
17835 2018-06-29 Jeff Law <law@redhat.com>
17836
17837 * config/v850/v850.c (v850_legitimate_address_p): Handle large
17838 displacements for TARGET_V850E2V3 and newer.
17839 (TARGET_LRA_P): Remove. Defaults to LRA now.
17840 * config/v850/v850.md (sign23byte_load): Remove.
17841 (unsign23byte_load, sign23hword_load, unsign23hword_load): Likewise.
17842 (23word_load, 23byte_store, 23hword_store, 23word_store): Likewise.
17843
17844 2018-06-29 Martin Liska <mliska@suse.cz>
17845
17846 PR lto/85759
17847 * coverage.c (coverage_init): Mangle full path name.
17848 * doc/invoke.texi: Document the change.
17849 * gcov-io.c (mangle_path): New.
17850 * gcov-io.h (mangle_path): Likewise.
17851 * gcov.c (mangle_name): Use mangle_path for path mangling.
17852
17853 2018-06-29 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
17854
17855 * config/arm/arm.c (output_move_double): Don't allow STRD instructions
17856 if starting source register is not even.
17857
17858 2018-06-29 Martin Liska <mliska@suse.cz>
17859
17860 PR tree-optimization/86263
17861 * tree-switch-conversion.c (switch_decision_tree::try_switch_expansion):
17862 Make edge redirection.
17863
17864 2018-06-29 David Malcolm <dmalcolm@redhat.com>
17865
17866 * dumpfile.c (dump_loc): Add indentation based on scope depth.
17867 (dump_scope_depth): New variable.
17868 (get_dump_scope_depth): New function.
17869 (dump_begin_scope): New function.
17870 (dump_end_scope): New function.
17871 * dumpfile.h (get_dump_scope_depth): New declaration.
17872 (dump_begin_scope): New declaration.
17873 (dump_end_scope): New declaration.
17874 (class auto_dump_scope): New class.
17875 (AUTO_DUMP_SCOPE): New macro.
17876 * tree-vectorizer.h (DUMP_VECT_SCOPE): Reimplement in terms of
17877 AUTO_DUMP_SCOPE.
17878
17879 2018-06-29 Richard Biener <rguenther@suse.de>
17880
17881 * tree-vect-data-refs.c (vect_analyze_data_ref_dependences): Assert
17882 compute_all_dependences succeeds.
17883 * tree-vect-loop.c (vect_get_datarefs_in_loop): Fail early if we
17884 exceed --param loop-max-datarefs-for-datadeps.
17885
17886 2018-06-29 Jakub Jelinek <jakub@redhat.com>
17887
17888 * config/rs6000/t-rs6000: Append rs6000-modes.h to TM_H.
17889
17890 2018-06-28 Uros Bizjak <ubizjak@gmail.com>
17891
17892 PR target/86348
17893 * config/i386/sse.md (*vec_extractv4si_0_zext_sse4): Use
17894 alternative 0 in preferred_for_speed attribute.
17895
17896 2018-06-28 Paul Koning <ni1d@arrl.net>
17897
17898 * config/pdp11/pdp11-protos.h (pdp11_shift_length): New function.
17899 * config/pdp11/pdp11.c (pdp11_shift_length): New function.
17900 * config/pdp11/pdp11.h (ADJUST_INSN_LENGTH): Remove.
17901 * config/pdp11/pdp11.md: Correct "length" attribute calculation
17902 for shift insn patterns.
17903
17904 2018-06-28 David Malcolm <dmalcolm@redhat.com>
17905
17906 * cgraph.c (cgraph_node::get_body): Replace assignments to
17907 "dump_file" with calls to set_dump_file.
17908 * dumpfile.c (alt_dump_file): Make static, and group with...
17909 (alt_flags): ...this definition.
17910 (dumps_are_enabled): New variable.
17911 (refresh_dumps_are_enabled): New function.
17912 (set_dump_file): New function.
17913 (set_alt_dump_file): New function.
17914 (gcc::dump_manager::dump_start): Replace assignments to
17915 "dump_file" and "alt_dump_file" with calls to set_dump_file and
17916 set_alt_dump_file.
17917 (gcc::dump_manager::dump_finish): Likewise.
17918 * dumpfile.h (alt_dump_file): Delete decl.
17919 (dumps_are_enabled): New variable decl.
17920 (set_dump_file): New function decl.
17921 (dump_enabled_p): Rewrite in terms of new "dumps_are_enabled"
17922 global.
17923 * tree-nested.c (lower_nested_functions): Replace assignments to
17924 "dump_file" with calls to set_dump_file.
17925
17926 2018-06-28 Eric Botcazou <ebotcazou@adacore.com>
17927
17928 * tree-cfg.c (verify_gimple_in_cfg): Call verify_location on the
17929 goto_locus of each outgoing edge of each basic block.
17930
17931 2018-06-28 Richard Biener <rguenther@suse.de>
17932
17933 * dwarf2out.c (decl_scope_table): Remove.
17934 (push_decl_scope): Likewise.
17935 (pop_decl_scope): Likewise.
17936 (gen_type_die_for_member): Do not call push/pop_decl_scope.
17937 (gen_struct_or_union_type_die): Likewise.
17938 (gen_tagged_type_die): Likewise.
17939 (dwarf2out_init): Do not initialize decl_scope_table.
17940 (dwarf2out_c_finalize): Do not free it.
17941
17942 2018-06-28 Richard Biener <rguenther@suse.de>
17943
17944 * dwarf2out.c (gen_subprogram_die): Use is_unit_die when
17945 deciding whether to not re-use a DIE.
17946
17947 2018-06-28 Richard Biener <rguenther@suse.de>
17948
17949 * dwarf2out.c (gen_subprogram_die): Always re-use DIEs with an
17950 DW_AT_abstract_origin attribute.
17951
17952 2018-06-28 Martin Liska <mliska@suse.cz>
17953
17954 * tree-switch-conversion.c (jump_table_cluster::can_be_handled):
17955 Use newly introduced constants.
17956 * tree-switch-conversion.h (struct jump_table_cluster):
17957 Define max_ratio_for_size and max_ratio_for_speed.
17958
17959 2018-06-28 Martin Liska <mliska@suse.cz>
17960
17961 * tree-switch-conversion.c (jump_table_cluster::find_jump_tables):
17962 Add new checking assert to catch invalid state.
17963 (jump_table_cluster::can_be_handled): Handle single case
17964 clusters.
17965 (jump_table_cluster::is_beneficial): Bail out for such case.
17966 (bit_test_cluster::find_bit_tests):
17967 Add new checking assert to catch invalid state.
17968 (bit_test_cluster::can_be_handled): Handle single case
17969 clusters.
17970 (bit_test_cluster::is_beneficial): Bail out for such case.
17971 (switch_decision_tree::analyze_switch_statement):
17972 Fix comment.
17973
17974 2018-06-28 Martin Liska <mliska@suse.cz>
17975
17976 * common.opt: Introduce -completion option.
17977 * gcc.c (driver_handle_option): Handle it.
17978 (driver::main): Print completions if completion
17979 is set.
17980 * opt-suggestions.c (option_proposer::get_completions):
17981 New function.
17982 (option_proposer::suggest_completion): Likewise.
17983 (option_proposer::find_param_completions): Likewise.
17984 (verify_autocompletions): Likewise.
17985 (test_completion_valid_options): Likewise.
17986 (test_completion_valid_params): Likewise.
17987 (in_completion_p): Likewise.
17988 (empty_completion_p): Likewise.
17989 (test_completion_partial_match): Likewise.
17990 (test_completion_garbage): Likewise.
17991 (opt_proposer_c_tests): Likewise.
17992 * opt-suggestions.h: Declare new functions.
17993 * opts.c (common_handle_option): Handle OPT__completion_.
17994 * selftest-run-tests.c (selftest::run_tests): Add
17995 opt_proposer_c_tests.
17996 * selftest.c (assert_str_startswith): New.
17997 * selftest.h (assert_str_startswith): Likewise.
17998 (opt_proposer_c_tests): New.
17999 (ASSERT_STR_STARTSWITH): Likewise.
18000
18001 2018-06-28 Martin Liska <mliska@suse.cz>
18002
18003 * Makefile.in: Add opt-suggestions.o.
18004 * gcc-main.c: Include opt-suggestions.h.
18005 * gcc.c (driver::driver): Likewise.
18006 (driver::~driver): Remove m_option_suggestions.
18007 (driver::build_option_suggestions): Moved to option_proposer.
18008 (driver::suggest_option): Likewise.
18009 (driver::handle_unrecognized_options): Use option_proposer.
18010 * gcc.h (class driver): Add new memver m_option_proposer.
18011 * opt-suggestions.c: New file.
18012 * opt-suggestions.h: New file.
18013
18014 2018-06-28 Martin Liska <mliska@suse.cz>
18015
18016 * vec.h (class auto_string_vec): New (moved from auto_argvec).
18017 (auto_string_vec::~auto_string_vec): Likewise.
18018
18019 2018-06-28 Eric Botcazou <ebotcazou@adacore.com>
18020
18021 * tree-inline.h (struct copy_body_data): Move remapping_type_depth and
18022 prevent_decl_creation_for_types fields up and add reset_location field.
18023 * tree-inline.c (remap_gimple_stmt): Force input_location on the new
18024 statement if id->reset_location is true.
18025 (copy_edges_for_bb): Do not set goto_locus on the new edges if
18026 id->reset_location is true.
18027 (copy_phis_for_bb): Force input_location on the arguments if
18028 id->reset_location is true.
18029 (expand_call_inline): Set id->reset_location if DECL_IGNORED_P
18030 is set on the function to be inlined.
18031
18032 2018-06-27 Stephan Bergmann <sbergman@redhat.com>
18033
18034 * doc/invoke.texi (Debugging Options): Add -gsplit-dwarf.
18035
18036 2018-06-27 Dimitar Dimitrov <dimitar@dinux.eu>
18037
18038 * lra-eliminations.c (update_reg_eliminate): Mark all spanning hard
18039 registers for Pmode.
18040 * lra-lives.c (check_pseudos_live_through_calls): Mark all spanning
18041 hard registers for the clobbered pseudo.
18042
18043 2018-06-27 Paul Koning <ni1d@arrl.net>
18044
18045 * common/config/pdp11/pdp11-common.c (pdp11_handle_option): Handle
18046 mutually exclusive options.
18047 * config/pdp11/constraints.md (h): New constraint.
18048 (O): Update definition to match shift code generation.
18049 (D): New constraint.
18050 * config/pdp11/pdp11-modes.def (CCNZ): Define mode.
18051 (CCFP): Remove.
18052 * config/pdp11/pdp11-protos.h (int_no_side_effect_operand): New
18053 function.
18054 (output_jump): Change arguments.
18055 (pdp11_fixed_cc_regs): New function.
18056 (pdp11_cc_mode): Ditto.
18057 (pdp11_expand_shift): Ditto.
18058 (pdp11_assemble_shift): Ditto.
18059 (pdp11_small_shift): Ditto.
18060 (pdp11_branch_cost): Remove.
18061 * config/pdp11/pdp11.c (pdp11_assemble_integer): Remove comments
18062 from output.
18063 (pdp11_register_move_cost): Update for CC registers.
18064 (pdp11_rtx_costs): Add case for LSHIFTRT.
18065 (pdp11_output_jump): Add CCNZ mode conditional branches.
18066 (notice_update_cc_on_set): Remove.
18067 (pdp11_cc_mode): New function.
18068 (simple_memory_operand): Correct pre/post decrement case.
18069 (no_side_effect_operand): New function.
18070 (pdp11_regno_reg_class): Add CC_REGS class.
18071 (pdp11_fixed_cc_regs): New function.
18072 (pdp11_small_shift): New function.
18073 (pdp11_expand_shift): New function to expand shift insns.
18074 (pdp11_assemble_shift): New function to output shifts.
18075 (pdp11_branch_cost): Remove.
18076 (pdp11_modes_tieable_p): Make QI/HI modes tieable.
18077 * config/pdp11/pdp11.h (SIZE_TYPE): Ensure 16-bit type.
18078 (WCHAR_TYPE): Ditto.
18079 (PTRDIFF_TYPE): Ditto.
18080 (ADJUST_INSN_LENGTH): New macro.
18081 (FIXED_REGISTERS): Add CC registers.
18082 (CALL_USED_REGISTERS): Ditto.
18083 (reg_class): Ditto.
18084 (REG_CLASS_NAMES): Ditto.
18085 (REG_CLASS_CONTENTS): Ditto.
18086 (SELECT_CC_MODE): Use new function.
18087 (TARGET_FLAGS_REGNUM): New macro.
18088 (TARGET_FIXED_CONDITION_CODE_REGS): Ditto.
18089 (cc0_reg_rtx): Remove.
18090 (CC_STATUS_MDEP): Remove.
18091 (CC_STATUS_MDEFP_INIT): Remove.
18092 (CC_IN_FPU): Remove.
18093 (NOTICE_UPDATE_CC): Remove.
18094 (REGISTER_NAMES): Add CC registers.
18095 (BRANCH_COST): Change to constant 1.
18096 * config/pdp11/pdp11.md: Rewrite for CCmode condition code
18097 handling.
18098 * config/pdp11/pdp11.opt (mbcopy): Remove.
18099 (mbcopy-builtin): Remove.
18100 (mbranch-cheap): Remove.
18101 (mbranch-expensive): Remove.
18102 * config/pdp11/predicates.md (expand_shift_operand): Update to
18103 match shift code generation.
18104 (ccnz_operator): New predicate.
18105 * doc/invoke.texi (PDP-11 Options): Remove deleted options
18106 -mbcopy, -mbcopy-builtin, -mbranch-cheap, -mbranch-expensive.
18107 Remove non-existent option -mabshi, -mno-abshi. Document mutually
18108 exclusive options.
18109 * doc/md.texi (PDP-11): Document new D and h constraints. Update
18110 description of O constraint.
18111
18112 2018-06-27 Jeff Law <law@redhat.com>
18113 Austin Law <austinklaw@gmail.com>
18114
18115 * config/v850/v850.md (addsi3_set_flags): New pattern.
18116 (subsi3_set_flags, negsi2_set_flags, andsi3_set_flags): Likewise.
18117 (iorsi3_set_flags, xorsi3_set_flags, one_cmplsi2_set_flags): Likewise.
18118 (zero_extendhisi2_v850_set_flags): Likewise.
18119 (zero_extendqisi2_v850_set_flags): Likewise.
18120 (ashlsi3_set_flags, ashlsi3_v850e2_set_flags): Likewise.
18121 (lshrsi3_set_flags, lshrsi3_v850e2_set_flags): Likewise.
18122 (ashrsi3_set_flags, ashrsi3_v850e2_set_flags): Likewise.
18123
18124 * config/v850/v850-protos.h (notice_update_cc): Remove.
18125 * config/v850/v850.c (v850_compare_op0, v850_compare_op1): Remove.
18126 (v850_print_operand): Handle 'D' and "d".
18127 (v850_select_cc_mode): Remove ATTRIBUTE_UNUSED for last argument.
18128 Add handling of arithmetic/logical operations compared against zero.
18129 (v850_gen_float_compare): Remove ATTRIBUTE_UNUSED for last argument.
18130 Do not look at v850_compare_op, instead get mode from last argument.
18131 (v850_gen_compare): Remove
18132 (increment_stack): Use addsi3_clobber_flags to avoid splitting failure
18133 after reload for prologue insns.
18134 (expand_prologue): Account for CLOBBER of CC_REGNUM in various
18135 patterns.
18136 (construct_save_jarl): Likewise.
18137 (TARGET_FLAGS_REGNUM): Define.
18138 * config/v850/v850.h (v850_compare_op0, v850_compare_op1): Remove.
18139 (NOTICE_UPDATE_CC): Remove.
18140 * config/v850/v850.md (v850_tst1): Use (reg:CCZ CC_REGNUM) rather
18141 than cc0. Conditionalize on reload_completed.
18142 (cmpsi_insn, setfcc_insn): Likewise.
18143 (tst1 splitter): Turn into define_and_split which sets the flags
18144 after reload.
18145 (cstoresi4, cbranchsf4, cbranchdf4, cbranchsi4_insn): Likewise.
18146 (cbranchsi4, branch_normal, branch_invert): Do not expose cc0 here.
18147 (cstoresf4, cstoredf4): Clobber the flags.
18148 (cmpsi, cmpsf, cmpdf): Remove expanders.
18149 (setf_insn): Remove pattern.
18150 (addsi3): Turn into define_and_split which clobbers the flags after
18151 reload and a suitable pattern (addsi3_clobber_flags) for use after
18152 reload.
18153 (subsi3, negsi2, andsi3, iorsi3, xorsi3, one_cmplsi2) Likewise.
18154 (ashlsi3, ashlsi3_v850e2, lshrsi3, lsh4si3_v850e2): Likewise.
18155 (ashrsi3, ashrsi3_v850e2): Likewise.
18156 (bins): Clobber the flags.
18157 (movsicc_normal_cc, movsicc_normal, movsicc_tst1): Likewise.
18158 (movsicc_tst1_revesed, sasf, swap and rotate patterns): Likewise.
18159 (fix_loop_counter, call_internal_short, call_internal_long): Likewise.
18160 (call_value_internal_short, call_value_internal_long): Likewise.
18161 (callt_save_interrupt, callt_return_interrupt): Likewise.
18162 (save_interrupt, return_interrupt): Likewise.
18163 (callt_save_all_interrupt, save_all_interrupt): Likewise.
18164 (_save_all_interrupt, callt_restore_all_interrupt): Likewise.
18165 (restore_all_interrupt, _restore_all_interrupt): Likewise.
18166 (All FP comparisons): Only allow after reload has completed.
18167 (trfsr): Likewise.
18168 (divh, divhu): Tweak output template.
18169 (branch_z_normal, branch_z_invert): Remove
18170 (branch_nz_normal, branch_nz_invert): Likewise.
18171 (extendhisi_insn, extendqisi_insn): Do not clobber flags.
18172
18173 * config/v850/v850-modes.def (CCZ, CCNZ): Add new modes.
18174 * config/v850/v850.c (notice_update_cc): Remove.
18175 * config/v850/v850.h (CC_OVERFLOW_UNUSABLE): Remove
18176 (CC_NO_CARRY): Likewise.
18177 (NOTICE_UPDATE_CC): Define to nothing.
18178 * config/v850/v850.md: Remove block comment on cc0 handling
18179 Remove "cc" attribute from all patterns. Remove cc_status handling
18180 from all patterns. Minor formatting fixes.
18181
18182 2018-06-27 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
18183
18184 * config/aarch64/aarch64-cores.def (cortex-a76): New entry.
18185 (cortex-a76.cortex-a55): Likewise.
18186 * config/aarch64/aarch64-tune.md: Regenerate.
18187 * doc/invoke.texi (AArch64 Options): Document cortex-a76 and
18188 cortex-a76.cortex-a55.
18189
18190 2018-06-27 Jeff Law <law@redhat.com>
18191
18192 * config/v850/t-v850 (MULTILIB_OPTIONS): Remove 8byte-align.
18193 (MULTILIB_DIRNAMES): Similarly.
18194
18195 2018-06-27 Eric Botcazou <ebotcazou@adacore.com>
18196
18197 * gimple.h (gimple_return_retbnd): Delete.
18198 (gimple_return_set_retbnd): Likewise.
18199 * cgraphunit.c (cgraph_node::expand_thunk): Remove call to
18200 gimple_return_set_retbnd.
18201 * gimple-pretty-print.c (dump_gimple_return): Remove call to
18202 gimple_return_retbnd and adjust.
18203 * tree-inline.h (struct copy_body_data): Remove retbnd field.
18204 * tree-inline.c (remap_gimple_stmt): Remove handling of retbnd.
18205 Explicitly return NULL in a couple more cases. Move assertion
18206 on debug statements and remove unreachable code.
18207 (reset_debug_binding): Do not test id->retbnd.
18208 (expand_call_inline): Do not set it.
18209
18210 2018-06-27 Rasmus Villemoes <rv@rasmusvillemoes.dk>
18211
18212 * configure.ac: Add --disable-gcov option.
18213 * configure: Regenerate.
18214 * Makefile.in: Honour @enable_gcov@.
18215 * doc/install.texi: Document --disable-gcov.
18216
18217 2018-06-27 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
18218
18219 * config/arm/arm-cpus.in (cortex-a76): New entry.
18220 (cortex-a76.cortex-a55): Likewise.
18221 * config/arm/arm-tables.opt: Regenerate.
18222 * config/arm/arm-tune.md: Likewise.
18223 * config/arm/driver-arm.c (arm_cpu_table): Add Cortex-A76 entry.
18224 * doc/invoke.texi (ARM Options): Document cortex-a76 and
18225 cortex-a76.cortex-a55.
18226
18227 2018-06-27 Tamar Christina <tamar.christina@arm.com>
18228
18229 PR target/85769
18230 * config/aarch64/aarch64.md (*movhf_aarch64): Add dup v0.4h pattern.
18231
18232 2018-06-27 Siddhesh Poyarekar <siddhesh@sourceware.org>
18233
18234 * config/aarch64/aarch64.h (CALL_USE_REGISTERS): Fix obsolete
18235 comment.
18236 (EPILOGUE_USES): Likewise.
18237
18238 2018-06-26 Eric Botcazou <ebotcazou@adacore.com>
18239
18240 * tree-inline.c (remap_location): New function extracted from...
18241 (copy_edges_for_bb): Add ID parameter. Remap goto_locus.
18242 (copy_phis_for_bb): ...here. Call remap_location.
18243 (copy_cfg_body): Adjust call to copy_edges_for_bb.
18244
18245 2018-06-26 Aaron Sawdey <acsawdey@linux.ibm.com>
18246
18247 * config/rs6000/rs6000-string.c (expand_block_clear): Don't use
18248 unaligned vsx for 16B memset.
18249
18250 2018-06-26 Segher Boessenkool <segher@kernel.crashing.org>
18251
18252 PR target/86285
18253 * config/rs6000/rs6000.c (rs6000_init_builtins): Do not set
18254 ieee128_float_type_node to long_double_type_node unless
18255 TARGET_LONG_DOUBLE_128 is set.
18256
18257 2018-06-26 David Malcolm <dmalcolm@redhat.com>
18258
18259 * cfgloop.c (get_loop_location): Convert return type from
18260 location_t to dump_user_location_t, replacing INSN_LOCATION lookups
18261 by implicit construction from rtx_insn *, and using
18262 dump_user_location_t::from_function_decl for the fallback case.
18263 * cfgloop.h (get_loop_location): Convert return type from
18264 location_t to dump_user_location_t.
18265 * cgraphunit.c (walk_polymorphic_call_targets): Update call to
18266 dump_printf_loc to pass in a dump_location_t rather than a
18267 location_t, via the gimple stmt.
18268 * coverage.c (get_coverage_counts): Update calls to
18269 dump_printf_loc to pass in dump_location_t rather than a
18270 location_t.
18271 * doc/optinfo.texi (Dump types): Convert example of
18272 dump_printf_loc from taking "locus" to taking "insn". Update
18273 description of the "_loc" calls to cover dump_location_t.
18274 * dumpfile.c: Include "backend.h", "gimple.h", "rtl.h", and
18275 "selftest.h".
18276 (dump_user_location_t::dump_user_location_t): New constructors,
18277 from gimple *stmt and rtx_insn *.
18278 (dump_user_location_t::from_function_decl): New function.
18279 (dump_loc): Make static.
18280 (dump_gimple_stmt_loc): Convert param "loc" from location_t to
18281 const dump_location_t &.
18282 (dump_generic_expr_loc): Delete.
18283 (dump_printf_loc): Convert param "loc" from location_t to
18284 const dump_location_t &.
18285 (selftest::test_impl_location): New function.
18286 (selftest::dumpfile_c_tests): New function.
18287 * dumpfile.h: Include "profile-count.h".
18288 (class dump_user_location_t): New class.
18289 (struct dump_impl_location_t): New struct.
18290 (class dump_location_t): New class.
18291 (dump_printf_loc): Convert 2nd param from source_location to
18292 const dump_location_t &.
18293 (dump_generic_expr_loc): Delete.
18294 (dump_gimple_stmt_loc): Convert 2nd param from source_location to
18295 const dump_location_t &.
18296 * gimple-fold.c (fold_gimple_assign): Update call to
18297 dump_printf_loc to pass in a dump_location_t rather than a
18298 location_t, via the gimple stmt.
18299 (gimple_fold_call): Likewise.
18300 * gimple-loop-interchange.cc
18301 (loop_cand::analyze_iloop_reduction_var): Update for change to
18302 check_reduction_path.
18303 (tree_loop_interchange::interchange): Update for change to
18304 find_loop_location.
18305 * graphite-isl-ast-to-gimple.c (scop_to_isl_ast): Update for
18306 change in return-type of find_loop_location.
18307 (graphite_regenerate_ast_isl): Likewise.
18308 * graphite-optimize-isl.c (optimize_isl): Likewise.
18309 * graphite.c (graphite_transform_loops): Likewise.
18310 * ipa-devirt.c (ipa_devirt): Update call to dump_printf_loc to
18311 pass in a dump_location_t rather than a location_t, via the
18312 gimple stmt.
18313 * ipa-prop.c (ipa_make_edge_direct_to_target): Likewise.
18314 * ipa.c (walk_polymorphic_call_targets): Likewise.
18315 * loop-unroll.c (report_unroll): Convert "locus" param from
18316 location_t to dump_location_t.
18317 (decide_unrolling): Update for change to get_loop_location's
18318 return type.
18319 * omp-grid.c (struct grid_prop): Convert field "target_loc" from
18320 location_t to dump_user_location_t.
18321 (grid_find_single_omp_among_assignments_1): Updates calls to
18322 dump_printf_loc to pass in a dump_location_t rather than a
18323 location_t, via the gimple stmt.
18324 (grid_parallel_clauses_gridifiable): Convert "tloc" from
18325 location_t to dump_location_t. Updates calls to dump_printf_loc
18326 to pass in a dump_location_t rather than a location_t, via the
18327 gimple stmt.
18328 (grid_inner_loop_gridifiable_p): Likewise.
18329 (grid_dist_follows_simple_pattern): Likewise.
18330 (grid_gfor_follows_tiling_pattern): Likewise.
18331 (grid_target_follows_gridifiable_pattern): Likewise.
18332 (grid_attempt_target_gridification): Convert initialization
18333 of local "grid" from memset to zero-initialization; FIXME: does
18334 this require C++11? Update call to dump_printf_loc to pass in a
18335 optinfo_location rather than a location_t, via the gimple stmt.
18336 * profile.c (read_profile_edge_counts): Updates call to
18337 dump_printf_loc to pass in a dump_location_t rather than a
18338 location_t
18339 (compute_branch_probabilities): Likewise.
18340 * selftest-run-tests.c (selftest::run_tests): Call
18341 dumpfile_c_tests.
18342 * selftest.h (dumpfile_c_tests): New decl.
18343 * tree-loop-distribution.c (pass_loop_distribution::execute):
18344 Update for change in return type of find_loop_location.
18345 * tree-parloops.c (parallelize_loops): Likewise.
18346 * tree-ssa-loop-ivcanon.c (try_unroll_loop_completely): Convert
18347 "locus" from location_t to dump_user_location_t.
18348 (canonicalize_loop_induction_variables): Likewise.
18349 * tree-ssa-loop-ivopts.c (tree_ssa_iv_optimize_loop): Update
18350 for change in return type of find_loop_location.
18351 * tree-ssa-loop-niter.c (number_of_iterations_exit): Update call
18352 to dump_printf_loc to pass in a dump_location_t rather than a
18353 location_t, via the stmt.
18354 * tree-ssa-sccvn.c (eliminate_dom_walker::before_dom_children):
18355 Likewise.
18356 * tree-vect-loop-manip.c (find_loop_location): Convert return
18357 type from source_location to dump_user_location_t.
18358 (vect_do_peeling): Update for above change.
18359 (vect_loop_versioning): Update for change in type of
18360 vect_location.
18361 * tree-vect-loop.c (check_reduction_path): Convert "loc" param
18362 from location_t to dump_user_location_t.
18363 (vect_estimate_min_profitable_iters): Update for change in type
18364 of vect_location.
18365 * tree-vect-slp.c (vect_print_slp_tree): Convert param "loc" from
18366 location_t to dump_location_t.
18367 (vect_slp_bb): Update for change in type of vect_location.
18368 * tree-vectorizer.c (vect_location): Convert from source_location
18369 to dump_user_location_t.
18370 (try_vectorize_loop_1): Update for change in vect_location's type.
18371 (vectorize_loops): Likewise.
18372 (increase_alignment): Likewise.
18373 * tree-vectorizer.h (vect_location): Convert from source_location
18374 to dump_user_location_t.
18375 (find_loop_location): Convert return type from source_location to
18376 dump_user_location_t.
18377 (check_reduction_path): Convert 1st param from location_t to
18378 dump_user_location_t.
18379 * value-prof.c (check_counter): Update call to dump_printf_loc to
18380 pass in a dump_user_location_t rather than a location_t; update
18381 call to error_at for change in type of "locus".
18382 (check_ic_target): Update call to dump_printf_loc to
18383 pass in a dump_user_location_t rather than a location_t, via the
18384 call_stmt.
18385
18386 2018-06-26 Robin Dapp <rdapp@linux.vnet.ibm.com>
18387
18388 * config/s390/s390.h (enum processor_flags): Do not use
18389 default tune parameter when -march was specified.
18390
18391 2018-06-26 Jakub Jelinek <jakub@redhat.com>
18392
18393 PR target/86314
18394 * config/i386/i386.md (setcc + movzbl to xor + setcc peephole2s):
18395 Check reg_overlap_mentioned_p in addition to reg_set_p with the same
18396 operands.
18397
18398 2018-06-26 Richard Biener <rguenther@suse.de>
18399
18400 PR tree-optimization/86287
18401 PR bootstrap/86316
18402 * tree-vect-loop.c (vect_transform_loop_stmt): Fix read-after-free.
18403 (vect_analyze_loop): Initialize n_stmts.
18404
18405 2018-06-26 Richard Biener <rguenther@suse.de>
18406
18407 PR middle-end/86271
18408 * fold-const.c (fold_convertible_p): Pointer extension
18409 isn't valid.
18410
18411 2018-06-26 Alexandre Oliva <aoliva@redhat.com>
18412
18413 PR debug/86064
18414 * dwarf2out.c (loc_list_has_views): Adjust comments.
18415 (dw_loc_list): Split single cross-partition range with
18416 nonzero locview.
18417
18418 2018-06-25 Jeff Law <law@redhat.com>
18419
18420 * common/config/v850/v850-common.c (TARGET_DEFAULT_TARGET_FLAGS): Turn
18421 on -mbig-switch by default.
18422
18423 * config/v850/predicates.md (const_float_1_operand): Fix match_code
18424 test.
18425 (const_float_0_operand): Remove unused predicate.
18426 * config/v850/v850.md (define_constants): Remove UNSPEC_LOOP.
18427 (define_c_enum unspec): Add LOOP, RCP and RSQRT constants.
18428 (recipsf2): New expander. Original pattern now called
18429 (recipsf2_insn).
18430 (recipdf2, recipdf2_insn): Similarly.
18431 (rsqrtsf2, rsqrtsf2_insn): Similarly
18432 (rsqrtdf2, rsqrtdf2_insn): Similarly
18433
18434 2018-06-26 Gerald Pfeifer <gerald@pfeifer.com>
18435
18436 * ginclude/stddef.h: Remove an obsolete comment on FreeBSD 5.
18437 Simplify logic for FreeBSD (twice).
18438
18439 2018-06-25 Martin Sebor <msebor@redhat.com>
18440
18441 PR tree-optimization/86204
18442 * tree-ssa-strlen.c (handle_builtin_strlen): Avoid storing
18443 a strnlen result if it's less than the length of the string.
18444
18445 2018-06-25 Martin Sebor <msebor@redhat.com>
18446
18447 PR tree-optimization/85700
18448 * gimple-fold.c (gimple_fold_builtin_strncat): Adjust comment.
18449 * tree-ssa-strlen.c (is_strlen_related_p): Handle integer subtraction.
18450 (maybe_diag_stxncpy_trunc): Distinguish strncat from strncpy.
18451
18452 2018-06-25 Martin Sebor <msebor@redhat.com>
18453
18454 * doc/extend.texi (Zero-length arrays): Update and clarify.
18455
18456 2018-06-25 Michael Meissner <meissner@linux.ibm.com>
18457
18458 * config.gcc (powerpc64le*): Revert January 16th, 2018 patch that
18459 added IEEE/IBM long double multilib support on PowerPC little
18460 endian Linux systems.
18461 * config/rs6000/linux64.h (MULTILIB_DEFAULTS_IEEE): Likewise.
18462 (MULTILIB_DEFAULTS): Likewise.
18463 * config/rs6000/rs6000.c (rs6000_option_override_internal):
18464 Likewise.
18465 * config/rs6000/rs6000.h (TARGET_IEEEQUAD_MULTILIB): Likewise.
18466 * config/rs6000/t-ldouble-linux64le-ibm: Delete, no longer used.
18467 * config/rs6000/t-ldouble-linux64le-ieee: Delete, no longer used.
18468
18469 2018-06-25 Alexander Monakov <amonakov@ispras.ru>
18470
18471 PR middle-end/86311
18472 * sort.cc (REORDER_23): Avoid memcpy with same destination and source.
18473 (REORDER_45): Likewise.
18474
18475 2018-06-25 Jeff Law <law@redhat.com>
18476
18477 * config/v850/v850.md (divmodhi4): Make sure to sign extend the
18478 dividend to 32 bits. Adjust length.
18479 (udivmodhi4): Cleanup output template. Fix length.
18480
18481 2018-06-25 Carl Love <cel@us.ibm.com>
18482
18483 * config/rs6000/vsx.md: Change word selector to prefered location.
18484
18485 2018-06-25 Richard Biener <rguenther@suse.de>
18486
18487 PR tree-optimization/86304
18488 * tree-vectorizer.c (vectorize_loops): Walk over new possibly
18489 epilogue-if-converted loops as well.
18490
18491 2018-06-25 Jan Hubicka <hubicka@ucw.cz>
18492
18493 * lto-section-out.c (lto_begin_section): Do not print section
18494 name for noaddr and unnumbered dumps.
18495
18496 2018-06-25 Richard Biener <rguenther@suse.de>
18497
18498 * tree-vectorizer.h (struct vec_info_shared): New structure
18499 with parts split out from struct vec_info and loop_nest from
18500 struct _loop_vec_info.
18501 (struct vec_info): Adjust accordingly.
18502 (struct _loop_vec_info): Likewise.
18503 (LOOP_VINFO_LOOP_NEST): Adjust.
18504 (LOOP_VINFO_DATAREFS): Likewise.
18505 (LOOP_VINFO_DDRS): Likewise.
18506 (struct _bb_vec_info): Likewise.
18507 (BB_VINFO_DATAREFS): Likewise.
18508 (BB_VINFO_DDRS): Likewise.
18509 (struct _stmt_vec_info): Add dr_aux member.
18510 (DR_VECT_AUX): Adjust to refer to member of DR_STMTs vinfo.
18511 (DR_MISALIGNMENT_UNINITIALIZED): New.
18512 (set_dr_misalignment): Adjust.
18513 (dr_misalignment): Assert misalign isn't DR_MISALIGNMENT_UNINITIALIZED.
18514 (vect_analyze_loop): Adjust prototype.
18515 (vect_analyze_loop_form): Likewise.
18516 * tree-vect-data-refs.c (vect_analyze_data_ref_dependences):
18517 Compute dependences lazily.
18518 (vect_record_base_alignments): Use shared datarefs/ddrs.
18519 (vect_verify_datarefs_alignment): Likewise.
18520 (vect_analyze_data_refs_alignment): Likewise.
18521 (vect_analyze_data_ref_accesses): Likewise.
18522 (vect_analyze_data_refs): Likewise.
18523 * tree-vect-loop.c (_loop_vec_info::_loop_vec_info): Add
18524 constructor parameter for shared part.
18525 (vect_analyze_loop_form): Pass in shared part and adjust.
18526 (vect_analyze_loop_2): Pass in storage for the number of
18527 stmts. Move loop nest finding to the caller. Compute
18528 datarefs lazily.
18529 (vect_analyze_loop): Pass in shared part.
18530 (vect_transform_loop): Verify shared datarefs are unchanged.
18531 * tree-vect-slp.c (_bb_vec_info::_bb_vec_info): Add
18532 constructor parameter for shared part.
18533 (vect_slp_analyze_bb_1): Pass in shared part and adjust.
18534 (vect_slp_bb): Verify shared datarefs are unchanged before
18535 transform.
18536 * tree-vect-stmts.c (ensure_base_align): Adjust for DR_AUX
18537 change.
18538 (new_stmt_vec_info): Initialize DR_AUX misalignment to
18539 DR_MISALIGNMENT_UNINITIALIZED.
18540 * tree-vectorizer.c (vec_info::vec_info): Add constructor
18541 parameter for shared part.
18542 (vec_info::~vec_info): Adjust.
18543 (vec_info_shared::vec_info_shared): New.
18544 (vec_info_shared::~vec_info_shared): Likewise.
18545 (vec_info_shared::save_datarefs): Likewise.
18546 (vec_info_shared::check_datarefs): Likewise.
18547 (try_vectorize_loop_1): Construct shared part live for analyses
18548 of a single loop for multiple vector sizes.
18549 * tree-parloops.c (gather_scalar_reductions): Adjust.
18550
18551 2018-06-25 Richard Biener <rguenther@suse.de>
18552
18553 * tree-vect-data-refs.c (vect_find_stmt_data_reference): Modify
18554 DR for SIMD lane accesses here and mark DR with (void *)-1 aux.
18555 (vect_analyze_data_refs): Remove similar code from here and
18556 simplify accordingly.
18557
18558 2018-06-25 Richard Biener <rguenther@suse.de>
18559
18560 * tree-vect-data-refs.c (vect_check_gather_scatter): Fail
18561 for reverse storage order accesses rather than asserting
18562 they cannot happen here.
18563
18564 2018-06-25 Tom de Vries <tdevries@suse.de>
18565
18566 PR debug/86257
18567 * config/i386/i386.md (define_insn "*tls_global_dynamic_64_<mode>"):
18568 Use data16 instead of .byte for insn prefix.
18569
18570 2018-06-25 Andreas Krebbel <krebbel@linux.ibm.com>
18571
18572 PR C++/86082
18573 * parser.c (make_char_string_pack): Pass this literal chars
18574 through cpp_interpret_string.
18575 (cp_parser_userdef_numeric_literal): Check the result of
18576 make_char_string_pack.
18577
18578 2018-06-24 Maya Rashish <coypu@sdf.org>
18579
18580 * ginclude/stddef.h: Simplify conditions around avoiding
18581 re-definition of __size_t.
18582
18583 2018-06-22 Jan Hubicka <hubicka@ucw.cz>
18584
18585 * lto-streamer-out.c (tree_is_indexable): Make LABEL_DECL nonindexable
18586 unless it is forced or nonlocal; assert that we stream no IMPORTED_DECL.
18587
18588 2018-06-22 Maya Rashish <coypu@sdf.org>
18589
18590 * doc/invoke.texi (mno-fancy-math-387): Update for changes
18591 made to OpenBSD and NetBSD through the years.
18592
18593 2018-06-22 Kelvin Nilsen <kelvin@gcc.gnu.org>
18594
18595 * config/rs6000/rs6000-c.c (altivec_overloaded_builtins): Change
18596 behavior of vec_pack (vector double, vector double) to match
18597 behavior of vec_float2 (vector double, vector double).
18598
18599 2018-06-22 Olivier Hainque <hainque@adacore.com>
18600
18601 * gimplify.c (gimplify_function_tree): Prevent creation
18602 of a trampoline for the address of the current function
18603 passed to entry/exit instrumentation hooks.
18604
18605 2018-06-22 Aaron Sawdey <acsawdey@linux.ibm.com>
18606
18607 PR target/86222
18608 * config/rs6000/rs6000-string.c (expand_strn_compare): Handle -m32
18609 correctly.
18610
18611 2018-06-22 Martin Liska <mliska@suse.cz>
18612
18613 PR tree-optimization/86263
18614 * tree-switch-conversion.c (jump_table_cluster::find_jump_tables):
18615 Bail out if is_enabled is false.
18616 * tree-switch-conversion.h (jump_table_cluster::is_enabled):
18617 New declaration.
18618 (jump_table_cluster::is_enabled): New function.
18619
18620 2018-06-22 Jan Hubicka <hubicka@ucw.cz>
18621
18622 * lto-streamer-out.c (DFS::DFS_write_tree_body): Do not stream
18623 BINFO_BASE_ACCESSES and BINFO_VPTR_FIELD.
18624 * tree-streamer-in.c (streamer_read_tree_bitfields): Likewise.
18625 (lto_input_ts_binfo_tree_pointers): Likewise.
18626 * tree-streamer-out.c (streamer_write_tree_bitfields,
18627 write_ts_binfo_tree_pointers): Likewise.
18628 * tree.c (free_lang_data_in_binfo): Clear BINFO_VPTR_FIELD.
18629
18630 2018-06-22 Jan Hubicka <hubicka@ucw.cz>
18631
18632 * tree.c (free_lang_data_in_type): Free all TYPE_VFIELDs.
18633
18634 2018-06-22 Martin Liska <mliska@suse.cz>
18635
18636 * symbol-summary.h (get): Make it pure and inline move
18637 functionality from ::get function.
18638 (get): Remove and inline into ::get and ::get_create.
18639 (get_create): Move code from ::get function.
18640
18641 2018-06-22 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
18642
18643 PR target/85994
18644 * config/i386/sol2.h (CPP_SPEC): Don't pass -P for
18645 -x assembler-with-cpp.
18646
18647 2018-06-22 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
18648
18649 * config/sol2.h (TARGET_OS_CPP_BUILTINS): Define
18650 _FILE_OFFSET_BITS=64 for C++.
18651
18652 2018-06-21 Michael Meissner <meissner@linux.ibm.com>
18653
18654 * config/rs6000/rs6000.md (extendtfif2): Add missing 128-bit
18655 conversion insn that shows up when pr85657-3.c is compiled using
18656 IEEE 128-bit long double.
18657 (neg<mode>2_internal): Use the correct mode to check whether the
18658 mode is IBM extended.
18659 * config/rs6000/rs6000.c (init_float128_ieee): Prevent complex
18660 multiply and divide external functions from being created more
18661 than once.
18662
18663 2018-06-21 Eric Botcazou <ebotcazou@adacore.com>
18664
18665 * cfgrtl.c (fixup_reorder_chain): Do not emit NOPs in DECL_IGNORED_P
18666 functions.
18667 (rtl_merge_blocks): Likewise. Do not emit a NOP if the location of
18668 the edge can be forwarded.
18669 (cfg_layout_merge_blocks): Likewise.
18670
18671 2018-06-21 Eric Botcazou <ebotcazou@adacore.com>
18672
18673 * except.c (finish_eh_generation): Commit edge insertions only after
18674 the EH edges have been redirected from post-landing to landing pads.
18675
18676 2018-06-21 Eric Botcazou <ebotcazou@adacore.com>
18677
18678 * tree-nested.c (get_frame_type): Use create_tmp_var_raw instead of
18679 create_tmp_var_for to create the FRAME decl.
18680 (finalize_nesting_tree_1): Do not unchain the FRAME decl.
18681
18682 2018-06-21 Eric Botcazou <ebotcazou@adacore.com>
18683
18684 * tree-inline.c (copy_edges_for_bb): Minor tweak.
18685 (maybe_move_debug_stmts_to_successors): Also reset the locus of the
18686 debug statement when resetting its value.
18687 (expand_call_inline): Copy the locus of the call onto the assignment
18688 of the return value, if any. Use local variable in more cases.
18689
18690 2018-06-21 Martin Liska <mliska@suse.cz>
18691
18692 * ipa-pure-const.c (propagate_nothrow): Use
18693 funct_state_summaries->get.
18694 (dump_malloc_lattice): Likewise.
18695 (propagate_malloc): Likewise.
18696
18697 2018-06-21 Richard Biener <rguenther@suse.de>
18698
18699 * lto-streamer-out.c (DFS::DFS_write_tree_body): Update outdated
18700 comment. Follow BLOCK_ABSTRACT_ORIGIN unconditionally.
18701 * tree-streamer-in.c (lto_input_ts_block_tree_pointers): Update
18702 comment.
18703 * tree-streamer-out.c (write_ts_block_tree_pointers): Stream
18704 BLOCK_ABSTRACT_ORIGIN unconditionally.
18705
18706 2018-06-21 David Malcolm <dmalcolm@redhat.com>
18707
18708 * ipa-cp.c (ipcp_driver): Set edge_clone_summaries to NULL after
18709 deleting it.
18710 * ipa-reference.c (ipa_reference_c_finalize): Delete
18711 ipa_ref_opt_sum_summaries and set it to NULL.
18712
18713 2018-06-21 Tom de Vries <tdevries@suse.de>
18714
18715 PR tree-optimization/85859
18716 * tree-ssa-tail-merge.c (stmt_local_def): Copy gimple_is_call
18717 test with comment from bb_no_side_effects_p.
18718
18719 2018-06-21 Richard Biener <rguenther@suse.de>
18720
18721 PR tree-optimization/86232
18722 * tree-ssa-loop-niter.c (number_of_iterations_popcount): Adjust
18723 max for constant niter.
18724
18725 2018-06-21 Andre Vieira <andre.simoesdiasvieira@arm.com>
18726
18727 * config/aarch64/aarch64-simd.md
18728 (*aarch64_crypto_aes<aes_op>v16qi_xor_combine): New.
18729
18730 2018-06-21 Andre Vieira <andre.simoesdiasvieira@arm.com>
18731
18732 * config/aarch64/aarch64-simd.md (aarch64_crypto_aes<aes_op>v16qi):
18733 Make opernads of the unspec commutative.
18734
18735 2018-06-21 Richard Biener <rguenther@suse.de>
18736
18737 * tree-data-ref.c (dr_step_indicator): Handle NULL DR_STEP.
18738 * tree-vect-data-refs.c (vect_analyze_possibly_independent_ddr):
18739 Avoid calling vect_mark_for_runtime_alias_test with gathers or scatters.
18740 (vect_analyze_data_ref_dependence): Re-order checks to deal with
18741 NULL DR_STEP.
18742 (vect_record_base_alignments): Do not record base alignment
18743 for gathers or scatters.
18744 (vect_compute_data_ref_alignment): Drop return value that is always
18745 true. Bail out early for gathers or scatters.
18746 (vect_enhance_data_refs_alignment): Bail out early for gathers
18747 or scatters.
18748 (vect_find_same_alignment_drs): Likewise.
18749 (vect_analyze_data_refs_alignment): Remove dead code.
18750 (vect_slp_analyze_and_verify_node_alignment): Likewise.
18751 (vect_analyze_data_refs): For possible gathers or scatters do
18752 not create an alternate DR, just check their possible validity
18753 and mark them. Adjust DECL_NONALIASED handling to not rely
18754 on DR_BASE_ADDRESS.
18755 * tree-vect-loop-manip.c (vect_update_inits_of_drs): Do not
18756 update inits of gathers or scatters.
18757 * tree-vect-patterns.c (vect_recog_mask_conversion_pattern):
18758 Also copy gather/scatter flag to pattern vinfo.
18759
18760 2018-06-20 Kelvin Nilsen <kelvin@gcc.gnu.org>
18761
18762 * config/rs6000/rs6000-c.c (altivec_overloaded_builtins): Change
18763 behavior of vec_packsu (vector unsigned long long, vector unsigned
18764 long long) to match behavior of vec_packs with same signature.
18765
18766 2018-06-20 Chung-Lin Tang <cltang@codesourcery.com>
18767 Thomas Schwinge <thomas@codesourcery.com>
18768 Cesar Philippidis <cesar@codesourcery.com>
18769
18770 * gimplify.c (gimplify_scan_omp_clauses): Add support for
18771 OMP_CLAUSE_{IF_PRESENT,FINALIZE}.
18772 (gimplify_adjust_omp_clauses): Likewise.
18773 (gimplify_oacc_declare_1): Add support for GOMP_MAP_RELEASE, remove
18774 support for GOMP_MAP_FORCE_{ALLOC,TO,FROM,TOFROM}.
18775 (gimplify_omp_target_update): Update handling of acc update and
18776 enter/exit data.
18777 * omp-low.c (install_var_field): Remove unused parameter
18778 base_pointers_restrict.
18779 (scan_sharing_clauses): Remove base_pointers_restrict parameter.
18780 Update call to install_var_field. Handle OMP_CLAUSE_{IF_PRESENT,
18781 FINALIZE}
18782 (omp_target_base_pointers_restrict_p): Delete.
18783 (scan_omp_target): Update call to scan_sharing_clauses.
18784 * tree-core.h (enum omp_clause_code): Add OMP_CLAUSE_{IF_PRESENT,
18785 FINALIZE}.
18786 * tree-nested.c (convert_nonlocal_omp_clauses): Handle
18787 OMP_CLAUSE_{IF_PRESENT,FINALIZE}.
18788 (convert_local_omp_clauses): Likewise.
18789 * tree-pretty-print.c (dump_omp_clause): Likewise.
18790 * tree.c (omp_clause_num_ops): Add entries for OMP_CLAUSE_{IF_PRESENT,
18791 FINALIZE}.
18792 (omp_clause_code_name): Likewise.
18793
18794 2018-06-20 Jakub Jelinek <jakub@redhat.com>
18795
18796 PR debug/86194
18797 * var-tracking.c (use_narrower_mode_test): Check if shift amount can
18798 be narrowed.
18799
18800 PR tree-optimization/86231
18801 * tree-vrp.c (union_ranges): For ( [ ) ] or ( )[ ] range and
18802 anti-range don't overwrite *vr0min before using it to compute *vr0max.
18803
18804 2018-06-20 Tom de Vries <tdevries@suse.de>
18805
18806 PR tree-optimization/86097
18807 * tree-ssa-loop-manip.c (canonicalize_loop_ivs): Also convert *nit to
18808 iv type if signedness of iv type is not the same as that of *nit.
18809
18810 2018-06-20 Jakub Jelinek <jakub@redhat.com>
18811
18812 * cfgrtl.c (rtl_verify_edges): Formatting fix. If bb->preds has any
18813 EDGE_EH edges, verify they are all EDGE_EH.
18814
18815 2018-06-20 Maya Rashish <coypu@sdf.org>
18816
18817 * ginclude/stddef.h: Limit #include <machine/ansi.h> to NetBSD.
18818
18819 2018-06-20 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
18820
18821 * config/aarch64/aarch64-tuning-flags.def (no_ldp_stp_qregs): New.
18822 * config/aarch64/aarch64.c (xgene1_tunings): Add
18823 AARCH64_EXTRA_TUNE_NO_LDP_STP_QREGS to tune_flags.
18824 (aarch64_mode_valid_for_sched_fusion_p):
18825 Allow 16-byte modes.
18826 (aarch64_classify_address): Allow 16-byte modes for load_store_pair_p.
18827 * config/aarch64/aarch64-ldpstp.md: Add peepholes for LDP STP of
18828 128-bit modes.
18829 * config/aarch64/aarch64-simd.md (load_pair<VQ:mode><VQ2:mode>):
18830 New pattern.
18831 (vec_store_pair<VQ:mode><VQ2:mode>): Likewise.
18832 * config/aarch64/iterators.md (VQ2): New mode iterator.
18833
18834 2018-06-20 Martin Liska <mliska@suse.cz>
18835
18836 * tree-switch-conversion.c (jump_table_cluster::can_be_handled):
18837 Change default ratio from 10 to 8.
18838
18839 2018-06-20 Martin Liska <mliska@suse.cz>
18840
18841 * tree-switch-conversion.c (jump_table_cluster::find_jump_tables):
18842 New.
18843 (bit_test_cluster::find_bit_tests): Likewise.
18844 (switch_decision_tree::analyze_switch_statement): Find clusters.
18845 * tree-switch-conversion.h (struct jump_table_cluster): Document
18846 hierarchy.
18847
18848 2018-06-20 Martin Liska <mliska@suse.cz>
18849
18850 * tree-switch-conversion.c (switch_conversion::collect):
18851 Record m_uniq property.
18852 (switch_conversion::expand): Bail out for special conditions.
18853 (group_cluster::~group_cluster): New.
18854 (group_cluster::group_cluster): Likewise.
18855 (group_cluster::dump): Likewise.
18856 (jump_table_cluster::emit): New.
18857 (switch_decision_tree::fix_phi_operands_for_edges): New.
18858 (struct case_node): Remove struct.
18859 (jump_table_cluster::can_be_handled): New.
18860 (case_values_threshold): Moved to header.
18861 (reset_out_edges_aux): Likewise.
18862 (jump_table_cluster::is_beneficial): New.
18863 (bit_test_cluster::can_be_handled): Likewise.
18864 (add_case_node): Remove.
18865 (bit_test_cluster::is_beneficial): New.
18866 (case_bit_test::cmp): New.
18867 (bit_test_cluster::emit): New.
18868 (expand_switch_as_decision_tree_p): Remove.
18869 (bit_test_cluster::hoist_edge_and_branch_if_true): New.
18870 (fix_phi_operands_for_edge): Likewise.
18871 (switch_decision_tree::analyze_switch_statement): New.
18872 (compute_cases_per_edge): Move ...
18873 (switch_decision_tree::compute_cases_per_edge): ... here.
18874 (try_switch_expansion): Likewise.
18875 (switch_decision_tree::try_switch_expansion): Likewise.
18876 (record_phi_operand_mapping): Likewise.
18877 (switch_decision_tree::record_phi_operand_mapping): Likewise.
18878 (emit_case_decision_tree): Likewise.
18879 (switch_decision_tree::emit): Likewise.
18880 (balance_case_nodes): Likewise.
18881 (switch_decision_tree::balance_case_nodes): Likewise.
18882 (dump_case_nodes): Likewise.
18883 (switch_decision_tree::dump_case_nodes): Likewise.
18884 (emit_jump): Likewise.
18885 (switch_decision_tree::emit_jump): Likewise.
18886 (emit_cmp_and_jump_insns): Likewise.
18887 (switch_decision_tree::emit_cmp_and_jump_insns): Likewise.
18888 (emit_case_nodes): Likewise.
18889 (switch_decision_tree::emit_case_nodes): Likewise.
18890 (conditional_probability): Remove.
18891 * tree-switch-conversion.h (enum cluster_type): New.
18892 (PRINT_CASE): New.
18893 (struct cluster): Likewise.
18894 (cluster::cluster): Likewise.
18895 (struct simple_cluster): Likewise.
18896 (simple_cluster::simple_cluster): Likewise.
18897 (struct group_cluster): Likewise.
18898 (struct jump_table_cluster): Likewise.
18899 (struct bit_test_cluster): Likewise.
18900 (struct min_cluster_item): Likewise.
18901 (struct case_tree_node): Likewise.
18902 (case_tree_node::case_tree_node): Likewise.
18903 (jump_table_cluster::case_values_threshold): Likewise.
18904 (struct case_bit_test): Likewise.
18905 (struct switch_decision_tree): Likewise.
18906 (struct switch_conversion): Likewise.
18907 (switch_decision_tree::reset_out_edges_aux): Likewise.
18908
18909 2018-06-20 Martin Liska <mliska@suse.cz>
18910
18911 * tree-switch-conversion.c (MAX_CASE_BIT_TESTS): Remove.
18912 (hoist_edge_and_branch_if_true): Likewise.
18913 (expand_switch_using_bit_tests_p): Likewise.
18914 (struct case_bit_test): Likewise.
18915 (case_bit_test_cmp): Likewise.
18916 (emit_case_bit_tests): Likewise.
18917 (switch_conversion::switch_conversion): New class.
18918 (struct switch_conv_info): Remove old struct.
18919 (collect_switch_conv_info): More to ...
18920 (switch_conversion::collect): ... this.
18921 (check_range): Likewise.
18922 (switch_conversion::check_range): Likewise.
18923 (check_all_empty_except_final): Likewise.
18924 (switch_conversion::check_all_empty_except_final): Likewise.
18925 (check_final_bb): Likewise.
18926 (switch_conversion::check_final_bb): Likewise.
18927 (create_temp_arrays): Likewise.
18928 (switch_conversion::create_temp_arrays): Likewise.
18929 (free_temp_arrays): Likewise.
18930 (gather_default_values): Likewise.
18931 (switch_conversion::gather_default_values): Likewise.
18932 (build_constructors): Likewise.
18933 (switch_conversion::build_constructors): Likewise.
18934 (constructor_contains_same_values_p): Likewise.
18935 (switch_conversion::contains_same_values_p): Likewise.
18936 (array_value_type): Likewise.
18937 (switch_conversion::array_value_type): Likewise.
18938 (build_one_array): Likewise.
18939 (switch_conversion::build_one_array): Likewise.
18940 (build_arrays): Likewise.
18941 (switch_conversion::build_arrays): Likewise.
18942 (gen_def_assigns): Likewise.
18943 (switch_conversion::gen_def_assigns): Likewise.
18944 (prune_bbs): Likewise.
18945 (switch_conversion::prune_bbs): Likewise.
18946 (fix_phi_nodes): Likewise.
18947 (switch_conversion::fix_phi_nodes): Likewise.
18948 (gen_inbound_check): Likewise.
18949 (switch_conversion::gen_inbound_check): Likewise.
18950 (process_switch): Use the newly created class.
18951 (switch_conversion::expand): New.
18952 (switch_conversion::~switch_conversion): New.
18953 * tree-switch-conversion.h: New file.
18954
18955 2018-06-20 Richard Sandiford <richard.sandiford@arm.com>
18956
18957 * tree-vectorizer.h (NUM_PATTERNS, vect_recog_func_ptr): Move to
18958 tree-vect-patterns.c.
18959 * tree-vect-patterns.c (vect_supportable_direct_optab_p): New function.
18960 (vect_recog_dot_prod_pattern): Use it. Remove the type_in argument.
18961 (vect_recog_sad_pattern): Likewise.
18962 (vect_recog_widen_sum_pattern): Likewise.
18963 (vect_recog_pow_pattern): Likewise. Check for a null vectype.
18964 (vect_recog_widen_shift_pattern): Remove the type_in argument.
18965 (vect_recog_rotate_pattern): Likewise.
18966 (vect_recog_mult_pattern): Likewise.
18967 (vect_recog_vector_vector_shift_pattern): Likewise.
18968 (vect_recog_divmod_pattern): Likewise.
18969 (vect_recog_mixed_size_cond_pattern): Likewise.
18970 (vect_recog_bool_pattern): Likewise.
18971 (vect_recog_mask_conversion_pattern): Likewise.
18972 (vect_try_gather_scatter_pattern): Likewise.
18973 (vect_recog_widen_mult_pattern): Likewise. Check for a null vectype.
18974 (vect_recog_over_widening_pattern): Likewise.
18975 (vect_recog_gather_scatter_pattern): Likewise.
18976 (vect_recog_func_ptr): Move from tree-vectorizer.h
18977 (vect_vect_recog_func_ptrs): Move further down the file.
18978 (vect_recog_func): Likewise. Remove the third argument.
18979 (NUM_PATTERNS): Define based on vect_vect_recog_func_ptrs.
18980 (vect_pattern_recog_1): Expect the pattern function to do any
18981 necessary target tests. Also expect it to provide a vector type.
18982 Remove the type_in handling.
18983
18984 2018-06-20 Richard Sandiford <richard.sandiford@arm.com>
18985
18986 * tree-vect-patterns.c (vect_pattern_detected): New function.
18987 (vect_recog_dot_prod_patternm, vect_recog_sad_pattern)
18988 (vect_recog_widen_mult_pattern, vect_recog_widen_sum_pattern)
18989 (vect_recog_over_widening_pattern, vect_recog_widen_shift_pattern
18990 (vect_recog_rotate_pattern, vect_recog_vector_vector_shift_pattern)
18991 (vect_recog_mult_pattern, vect_recog_divmod_pattern)
18992 (vect_recog_mixed_size_cond_pattern, vect_recog_bool_pattern)
18993 (vect_recog_mask_conversion_pattern)
18994 (vect_try_gather_scatter_pattern): Likewise.
18995
18996 2018-06-20 Richard Sandiford <richard.sandiford@arm.com>
18997
18998 * tree-vect-patterns.c (vect_get_internal_def): New function.
18999 (vect_recog_dot_prod_pattern, vect_recog_sad_pattern)
19000 (vect_recog_vector_vector_shift_pattern, check_bool_pattern)
19001 (search_type_for_mask_1): Use it.
19002
19003 2018-06-20 Richard Sandiford <richard.sandiford@arm.com>
19004
19005 * tree-vect-patterns.c (vect_recog_dot_prod_pattern): Remove
19006 redundant WIDEN_SUM_EXPR handling.
19007 (vect_recog_sad_pattern): Likewise.
19008
19009 2018-06-20 Richard Sandiford <richard.sandiford@arm.com>
19010
19011 * tree-vect-patterns.c (vect_recog_dot_prod_pattern): Remove
19012 redundant check that the types of a PLUS_EXPR or MULT_EXPR agree.
19013 (vect_recog_sad_pattern): Likewise PLUS_EXPR, ABS_EXPR and MINUS_EXPR.
19014 (vect_recog_widen_mult_pattern): Likewise MULT_EXPR.
19015 (vect_recog_widen_sum_pattern): Likewise PLUS_EXPR.
19016
19017 2018-06-20 Richard Sandiford <richard.sandiford@arm.com>
19018
19019 * tree-vect-stmts.c (vectorizable_call): Make sure that we
19020 use the stmt_vec_info of the original bb statement for the
19021 new zero assignment, even if the call is part of a pattern.
19022
19023 2018-06-20 Richard Sandiford <richard.sandiford@arm.com>
19024
19025 * tree-vectorizer.h (_stmt_vec_info): Note above pattern_def_seq
19026 that the sequence is attached to the original statement rather
19027 than the pattern statement.
19028 * tree-vect-loop.c (vect_determine_vf_for_stmt): Take the
19029 PATTERN_DEF_SEQ from the original statement rather than
19030 the main pattern statement.
19031 * tree-vect-stmts.c (free_stmt_vec_info): Likewise.
19032 * tree-vect-patterns.c (vect_recog_dot_prod_pattern): Likewise.
19033 (vect_mark_pattern_stmts): Don't copy the PATTERN_DEF_SEQ.
19034
19035 2018-06-20 Richard Sandiford <richard.sandiford@arm.com>
19036
19037 * tree-vect-stmts.c (vect_analyze_stmt): Move the handling of pattern
19038 definition statements before the early exit for statements that aren't
19039 live or relevant.
19040 * tree-vect-loop.c (vect_transform_loop_stmt): New function,
19041 split out from...
19042 (vect_transform_loop): ...here. Process pattern definition
19043 statements without first checking whether the main pattern
19044 statement is live or relevant.
19045
19046 2018-06-19 Eric Botcazou <ebotcazou@adacore.com>
19047
19048 * tree-cfgcleanup.c (tree_forwarder_block_p): Do not return false at
19049 -O0 if the locus represent UNKNOWN_LOCATION but have different values.
19050
19051 2018-06-19 Aaron Sawdey <acsawdey@linux.ibm.com>
19052
19053 * config/rs6000/rs6000-string.c (select_block_compare_mode): Check
19054 TARGET_EFFICIENT_OVERLAPPING_UNALIGNED here instead of in caller.
19055 (do_and3, do_and3_mask, do_compb3, do_rotl3): New functions.
19056 (expand_block_compare): Change select_block_compare_mode call.
19057 (expand_strncmp_align_check): Use new functions, fix comment.
19058 (emit_final_str_compare_gpr): New function.
19059 (expand_strn_compare): Refactor and clean up code.
19060 * config/rs6000/vsx.md (vsx_mov<mode>_64bit): Remove *.
19061
19062 2018-06-19 Tony Reix <tony.reix@atos.com>
19063 Damien Bergamini <damien.bergamini@atos.com>
19064 David Edelsohn <dje.gcc@gmail.com>
19065
19066 * collect2.c (static_obj): New variable.
19067 (static_libs): New variable.
19068 (is_in_list): Uncomment declaration.
19069 (main): Track AIX libraries linked statically.
19070 (is_in_list): Uncomment definition.
19071 (scan_prog_file): Don't add AIX shared libraries initializer
19072 to constructor list if linking statically.
19073
19074 2018-06-19 Max Filippov <jcmvbkbc@gmail.com>
19075
19076 * config/xtensa/xtensa.md (UNSPEC_FRAME_BLOCKAGE): New unspec
19077 constant.
19078 (allocate_stack, frame_blockage, *frame_blockage): New patterns.
19079
19080 2018-06-19 Jan Hubicka <hubicka@ucw.cz>
19081
19082 * tree.c (find_decls_types_r): Remove all non-VAR_DECLs from
19083 blocks.
19084
19085 2018-06-19 Martin Liska <mliska@suse.cz>
19086
19087 * config/i386/i386.c (ix86_can_inline_p): Do not use
19088 ipa_fn_summaries::get_create.
19089 * ipa-cp.c (ipcp_cloning_candidate_p): Replace get_create with
19090 get.
19091 (devirtualization_time_bonus): Likewise.
19092 (ipcp_propagate_stage): Likewise.
19093 * ipa-fnsummary.c (redirect_to_unreachable): Likewise.
19094 (edge_set_predicate): Likewise.
19095 (evaluate_conditions_for_known_args): Likewise.
19096 (evaluate_properties_for_edge): Likewise.
19097 (ipa_call_summary::reset): Tranform to ...
19098 (ipa_call_summary::~ipa_call_summary): ... this.
19099 (ipa_fn_summary::reset): Transform to ...
19100 (ipa_fn_summary::~ipa_fn_summary): ... this.
19101 (ipa_fn_summary_t::remove): Rename to ...
19102 (ipa_fn_summary_t::remove_callees): ... this.
19103 (ipa_fn_summary_t::duplicate): Use placement new
19104 instead of memory copy.
19105 (ipa_call_summary_t::duplicate): Likewise.
19106 (ipa_call_summary_t::remove): Remove.
19107 (dump_ipa_call_summary): Change get_create to get.
19108 (ipa_dump_fn_summary): Dump only when summary exists.
19109 (analyze_function_body): Use symbol_summary::get instead
19110 of get_create.
19111 (compute_fn_summary): Likewise.
19112 (estimate_edge_devirt_benefit): Likewise.
19113 (estimate_edge_size_and_time): Likewise.
19114 (inline_update_callee_summaries): Likewise.
19115 (remap_edge_change_prob): Likewise.
19116 (remap_edge_summaries): Likewise.
19117 (ipa_merge_fn_summary_after_inlining): Likewise.
19118 (write_ipa_call_summary): Likewise.
19119 (ipa_fn_summary_write): Likewise.
19120 (ipa_free_fn_summary): Likewise.
19121 * ipa-fnsummary.h (struct GTY): Add new ctor and copy ctor.
19122 (struct ipa_call_summary): Likewise.
19123 * ipa-icf.c (sem_function::merge): Use symbol_summary::get instead
19124 of get_create.
19125 * ipa-inline-analysis.c (do_estimate_edge_time): Likewise.
19126 (estimate_size_after_inlining): Likewise.
19127 (estimate_growth): Likewise.
19128 (growth_likely_positive): Likewise.
19129 * ipa-inline-transform.c (clone_inlined_nodes): Likewise.
19130 (inline_call): Likewise.
19131 * ipa-inline.c (caller_growth_limits): Likewise.
19132 (can_inline_edge_p): Likewise.
19133 (can_inline_edge_by_limits_p): Likewise.
19134 (compute_uninlined_call_time): Likewise.
19135 (compute_inlined_call_time): Likewise.
19136 (want_inline_small_function_p): Likewise.
19137 (edge_badness): Likewise.
19138 (update_caller_keys): Likewise.
19139 (update_callee_keys): Likewise.
19140 (inline_small_functions): Likewise.
19141 (inline_to_all_callers_1): Likewise.
19142 (dump_overall_stats): Likewise.
19143 (early_inline_small_functions): Likewise.
19144 (early_inliner): Likewise.
19145 * ipa-profile.c (ipa_propagate_frequency_1): Likewise.
19146 * ipa-prop.c (ipa_make_edge_direct_to_target): Likewise.
19147 * ipa-pure-const.c (malloc_candidate_p): Likewise.
19148 * ipa-split.c (execute_split_functions): Likewise.
19149 * symbol-summary.h: Likewise.
19150 * tree-sra.c (ipa_sra_preliminary_function_checks): Likewise.
19151
19152 2018-06-19 Richard Biener <rguenther@suse.de>
19153
19154 * tree-vectorizer.c (try_vectorize_loop_1): Split out of ...
19155 (vectorize_loops): ... here. Fix dbgcnt handling.
19156 (try_vectorize_loop): Wrap try_vectorize_loop_1.
19157
19158 2018-06-19 Segher Boessenkool <segher@kernel.crashing.org>
19159
19160 PR target/86197
19161 * config/rs6000/rs6000.md (rs6000_discover_homogeneous_aggregate): An
19162 ieee128 argument takes up only one (vector) register, not two (floating
19163 point) registers.
19164
19165 2018-06-19 Eric Botcazou <ebotcazou@adacore.com>
19166
19167 * gimplify.c (gimplify_init_constructor): Really never clear for an
19168 incomplete constructor if CONSTRUCTOR_NO_CLEARING is set.
19169
19170 2018-06-19 Richard Biener <rguenther@suse.de>
19171
19172 PR tree-optimization/86179
19173 * tree-vect-patterns.c (vect_pattern_recog_1): Clean up
19174 after failed recognition.
19175
19176 2018-06-18 Martin Sebor <msebor@redhat.com>
19177
19178 PR middle-end/85602
19179 * calls.c (maybe_warn_nonstring_arg): Handle strncat.
19180 * tree-ssa-strlen.c (is_strlen_related_p): Make extern.
19181 Handle integer subtraction.
19182 (maybe_diag_stxncpy_trunc): Handle nonstring source arguments.
19183 * tree-ssa-strlen.h (is_strlen_related_p): Declare.
19184
19185 2018-06-18 David Malcolm <dmalcolm@redhat.com>
19186
19187 * config/frv/frv-protos.h (frv_ifcvt_modify_insn): Strengthen 3rd
19188 param from rtx to rtx_insn *.
19189 * config/frv/frv.c (frv_ifcvt_add_insn): Likewise for "insn"
19190 param.
19191 (frv_ifcvt_modify_insn): Likwise.
19192 (frv_ifcvt_modify_final): Likwise for local "existing_insn",
19193 adding an as_a <rtx_insn *> cast. Likewise for local "insn".
19194 * config/mips/mips.c (r10k_insert_cache_barriers): Add an
19195 as_a <rtx_insn *> cast to local "unprotected_region" once
19196 it's been established that it's not NULL or pc_rtx.
19197 * config/nds32/nds32-relax-opt.c (nds32_group_insns): Strengthen
19198 param "sethi" from rtx to rtx_insn *.
19199 (nds32_group_float_insns): Likewise for param "insn".
19200 * config/vax/vax-protos.h (vax_output_int_add): Likewise for 1st
19201 param.
19202 (vax_output_int_subtract): Likewise.
19203 * config/vax/vax.c (vax_output_int_add): Likewise for param
19204 "insn".
19205 (vax_output_int_subtract): Likewise.
19206 * emit-rtl.c (set_insn_deleted): Likewise, removing cast.
19207 (emit_pattern_after): Likewise for param "after".
19208 (emit_insn_after): Likewise.
19209 (emit_jump_insn_after): Likewise.
19210 (emit_call_insn_after): Likewise.
19211 (emit_debug_insn_after): Likewise.
19212 (emit_pattern_before): Likewise for param "before".
19213 (emit_insn_before): Likewise.
19214 (emit_jump_insn_before): Likewise.
19215 * final.c (get_insn_template): Likewise for param "insn", removing
19216 a cast.
19217 * output.h (get_insn_template): Likewise for 2nd param.
19218 * rtl.h (emit_insn_before): Likewise.
19219 (emit_jump_insn_before): Likewise.
19220 (emit_debug_insn_before_noloc): Likewise.
19221 (emit_insn_after): Likewise.
19222 (emit_jump_insn_after): Likewise.
19223 (emit_call_insn_after): Likewise.
19224 (emit_debug_insn_after): Likewise.
19225 (set_insn_deleted): Likewise for param.
19226
19227 2018-06-18 Michael Meissner <meissner@linux.ibm.com>
19228
19229 PR target/85358
19230 * config/rs6000/rs6000-modes.def (toplevel): Rework the 128-bit
19231 floating point modes, so that IFmode is numerically greater than
19232 TFmode, which is greater than KFmode using FRACTIONAL_FLOAT_MODE
19233 to declare the ordering. This prevents IFmode from being
19234 converted to TFmode when long double is IEEE 128-bit on an ISA 3.0
19235 machine. Include rs6000-modes.h to share the fractional values
19236 between genmodes* and the rest of the compiler.
19237 (IFmode): Likewise.
19238 (KFmode): Likewise.
19239 (TFmode): Likewise.
19240 * config/rs6000/rs6000-modes.h: New file.
19241 * config/rs6000/rs6000.c (rs6000_debug_reg_global): Change the
19242 meaning of rs6000_long_double_size so that 126..128 selects an
19243 appropriate 128-bit floating point type.
19244 (rs6000_option_override_internal): Likewise.
19245 * config/rs6000/rs6000.h (toplevel): Include rs6000-modes.h.
19246 (TARGET_LONG_DOUBLE_128): Change the meaning of
19247 rs6000_long_double_size so that 126..128 selects an appropriate
19248 128-bit floating point type.
19249 (LONG_DOUBLE_TYPE_SIZE): Update comment.
19250 * config/rs6000/rs6000.md (trunciftf2): Correct the modes of the
19251 source and destination to match the standard usage.
19252 (truncifkf2): Likewise.
19253 (copysign<mode>3, IEEE iterator): Rework copysign of float128 on
19254 ISA 2.07 to use an explicit clobber, instead of passing in a
19255 temporary.
19256 (copysign<mode>3_soft): Likewise.
19257
19258 2018-06-18 David Malcolm <dmalcolm@redhat.com>
19259
19260 * tree-vect-data-refs.c (vect_analyze_data_ref_dependences):
19261 Replace dump_printf_loc call with DUMP_VECT_SCOPE.
19262 (vect_slp_analyze_instance_dependence): Likewise.
19263 (vect_enhance_data_refs_alignment): Likewise.
19264 (vect_analyze_data_refs_alignment): Likewise.
19265 (vect_slp_analyze_and_verify_instance_alignment
19266 (vect_analyze_data_ref_accesses): Likewise.
19267 (vect_prune_runtime_alias_test_list): Likewise.
19268 (vect_analyze_data_refs): Likewise.
19269 * tree-vect-loop-manip.c (vect_update_inits_of_drs): Likewise.
19270 * tree-vect-loop.c (vect_determine_vectorization_factor): Likewise.
19271 (vect_analyze_scalar_cycles_1): Likewise.
19272 (vect_get_loop_niters): Likewise.
19273 (vect_analyze_loop_form_1): Likewise.
19274 (vect_update_vf_for_slp): Likewise.
19275 (vect_analyze_loop_operations): Likewise.
19276 (vect_analyze_loop): Likewise.
19277 (vectorizable_induction): Likewise.
19278 (vect_transform_loop): Likewise.
19279 * tree-vect-patterns.c (vect_pattern_recog): Likewise.
19280 * tree-vect-slp.c (vect_analyze_slp): Likewise.
19281 (vect_make_slp_decision): Likewise.
19282 (vect_detect_hybrid_slp): Likewise.
19283 (vect_slp_analyze_operations): Likewise.
19284 (vect_slp_bb): Likewise.
19285 * tree-vect-stmts.c (vect_mark_stmts_to_be_vectorized): Likewise.
19286 (vectorizable_bswap): Likewise.
19287 (vectorizable_call): Likewise.
19288 (vectorizable_simd_clone_call): Likewise.
19289 (vectorizable_conversion): Likewise.
19290 (vectorizable_assignment): Likewise.
19291 (vectorizable_shift): Likewise.
19292 (vectorizable_operation): Likewise.
19293 * tree-vectorizer.h (DUMP_VECT_SCOPE): New macro.
19294
19295 2018-06-18 Martin Sebor <msebor@redhat.com>
19296
19297 PR tree-optimization/81384
19298 * builtin-types.def (BT_FN_SIZE_CONST_STRING_SIZE): New.
19299 * builtins.c (expand_builtin_strnlen): New function.
19300 (expand_builtin): Call it.
19301 (fold_builtin_n): Avoid setting TREE_NO_WARNING.
19302 * builtins.def (BUILT_IN_STRNLEN): New.
19303 * calls.c (maybe_warn_nonstring_arg): Handle BUILT_IN_STRNLEN.
19304 Warn for bounds in excess of maximum object size.
19305 * tree-ssa-strlen.c (maybe_set_strlen_range): Return tree representing
19306 single-value ranges. Handle strnlen.
19307 (handle_builtin_strlen): Handle strnlen.
19308 (strlen_check_and_optimize_stmt): Same.
19309 * doc/extend.texi (Other Builtins): Document strnlen.
19310
19311 2018-06-18 Maya Rashish <coypu@sdf.org>
19312
19313 * config/alpha/openbsd.h (TARGET_DEFAULT): Define.
19314 (LINK_SPEC, STARTFILE_SPEC, ENDFILE_SPEC): Likewise.
19315 (INTMAX_TYPE, UINTMAX_TYPE, WINT_TYPE): Likewise.
19316
19317 * config/alpha/elf.h (STARTFILE_SPEC, ENDFILE_SPEC): Move from
19318 here to ...
19319 * config/alpha/linux.h (STARTFILE_SPEC, ENDFILE_SPEC): Here.
19320
19321 2018-06-18 Prathamesh Kulkarni <prathamesh.kulkarni@linaro.org>
19322
19323 * tree.c (escaped_string::escape): Replace cast to char * by
19324 const_cast<char *> (unescaped).
19325
19326 2018-06-18 Nick Clifton <nickc@redhat.com>
19327
19328 PR 84195
19329 * tree.c (escaped_string): New class. Converts an unescaped
19330 string into its escaped equivalent.
19331 (warn_deprecated_use): Use the new class to convert the
19332 deprecation message, if present.
19333 (test_escaped_strings): New self test.
19334 (test_c_tests): Add test_escaped_strings.
19335 * doc/extend.texi (deprecated): Add a note that the
19336 deprecation message is affected by the -fmessage-length
19337 option, and that control characters will be escaped.
19338 (#pragma GCC error): Document this pragma.
19339 (#pragma GCC warning): Likewise.
19340 * doc/invoke.texi (-fmessage-length): Document this option's
19341 effect on the #warning and #error preprocessor directives and
19342 the deprecated attribute.
19343
19344 2018-06-18 Eric Botcazou <ebotcazou@adacore.com>
19345
19346 * tree.c (decl_value_expr_lookup): Revert latest change.
19347 (decl_value_expr_insert): Likewise.
19348
19349 2018-06-17 Eric Botcazou <ebotcazou@adacore.com>
19350
19351 * gimplify.c (nonlocal_vlas): Delete.
19352 (nonlocal_vla_vars): Likewise.
19353 (gimplify_var_or_parm_decl): Do not add debug VAR_DECLs for non-local
19354 referenced VLAs.
19355 (gimplify_body): Do not create and destroy nonlocal_vlas.
19356 * tree-nested.c: Include diagnostic.h.
19357 (use_pointer_in_frame): Tweak.
19358 (lookup_field_for_decl): Add assertion and declare the transformation.
19359 (convert_nonlocal_reference_op) <PARM_DECL>: Rework and issue an
19360 internal error when the reference is in a wrong context. Do not
19361 create a debug decl by default.
19362 (note_nonlocal_block_vlas): Delete.
19363 (convert_nonlocal_reference_stmt) <GIMPLE_BIND>: Do not call it.
19364 (convert_local_reference_op) <PARM_DECL>: Skip the frame decl. Do not
19365 create a debug decl by default.
19366 (convert_gimple_call) <GIMPLE_CALL>: Issue an internal error when the
19367 call is in a wrong context.
19368 (fixup_vla_decls): New function.
19369 (finalize_nesting_tree_1): Adjust comment. Call fixup_vla_decls if no
19370 debug variables were created.
19371 * tree.c (decl_value_expr_lookup): Add checking assertion.
19372 (decl_value_expr_insert): Likewise.
19373
19374 2018-06-16 Kugan Vivekanandarajah <kuganv@linaro.org>
19375
19376 PR middle-end/82479
19377 * ipa-fnsummary.c (will_be_nonconstant_expr_predicate): Handle CALL_EXPR.
19378 * tree-scalar-evolution.c (interpret_expr): Likewise.
19379 (expression_expensive_p): Likewise.
19380 * tree-ssa-loop-ivopts.c (contains_abnormal_ssa_name_p): Likewise.
19381 * tree-ssa-loop-niter.c (number_of_iterations_popcount): New.
19382 (number_of_iterations_exit_assumptions): Use number_of_iterations_popcount.
19383 (ssa_defined_by_minus_one_stmt_p): New.
19384
19385 2018-06-16 Kugan Vivekanandarajah <kuganv@linaro.org>
19386
19387 PR middle-end/64946
19388 * cfgexpand.c (expand_debug_expr): Hande ABSU_EXPR.
19389 * config/i386/i386.c (ix86_add_stmt_cost): Likewise.
19390 * dojump.c (do_jump): Likewise.
19391 * expr.c (expand_expr_real_2): Check operand type's sign.
19392 * fold-const.c (const_unop): Handle ABSU_EXPR.
19393 (fold_abs_const): Likewise.
19394 * gimple-pretty-print.c (dump_unary_rhs): Likewise.
19395 * gimple-ssa-backprop.c (backprop::process_assign_use): Likesie.
19396 (strip_sign_op_1): Likesise.
19397 * match.pd: Add new pattern to generate ABSU_EXPR.
19398 * optabs-tree.c (optab_for_tree_code): Handle ABSU_EXPR.
19399 * tree-cfg.c (verify_gimple_assign_unary): Likewise.
19400 * tree-eh.c (operation_could_trap_helper_p): Likewise.
19401 * tree-inline.c (estimate_operator_cost): Likewise.
19402 * tree-pretty-print.c (dump_generic_node): Likewise.
19403 * tree-vect-patterns.c (vect_recog_sad_pattern): Likewise.
19404 * tree.def (ABSU_EXPR): New.
19405
19406 2018-06-16 Jakub Jelinek <jakub@redhat.com>
19407
19408 PR middle-end/86095
19409 * common.opt (Wunsafe-loop-optimizations): Add Ignore, remove Var,
19410 documented as preserved for backward compatibility only.
19411 * doc/invoke.texi: Remove -Wunsafe-loop-optimizations documentation.
19412
19413 PR rtl-optimization/86108
19414 * bb-reorder.c (create_forwarder_block): Renamed to ...
19415 (create_eh_forwarder_block): ... this. Split OLD_BB after labels and
19416 jump from new landing pad to the second part.
19417 (sjlj_fix_up_crossing_landing_pad, dw2_fix_up_crossing_landing_pad):
19418 Adjust callers.
19419
19420 2018-06-15 Jakub Jelinek <jakub@redhat.com>
19421
19422 PR middle-end/85878
19423 * expr.c (expand_assignment): Remove now redundant COMPLEX_MODE_P
19424 check from first store_expr, use to_mode instead of GET_MODE (to_rtx).
19425 Only call store_expr for halves if the mode is the same.
19426
19427 PR middle-end/86123
19428 * match.pd ((X / Y) == 0 -> X < Y): Don't transform complex divisions.
19429 Fix up comment formatting.
19430
19431 2018-06-15 Bernd Edlinger <bernd.edlinger@hotmail.de>
19432
19433 * typed-splay-tree.h (typed_splay_tree::remove): New function.
19434 (typed_splay_tree::closure,
19435 typed_splay_tree::inner_foreach_fn, typed_splay_tree::m_inner): Deleted.
19436 (typed_splay_tree::typed_splay_tree,
19437 typed_splay_tree::operator =): Declared private.
19438 (typed_splay_tree::splay_tree_key, typed_splay_tree::splay_tree_value,
19439 typed_splay_tree::splay_tree_node_s, typed_splay_tree::KDEL,
19440 typed_splay_tree::VDEL, typed_splay_tree::splay_tree_delete_helper,
19441 typed_splay_tree::rotate_left, typed_splay_tree::rotate_right,
19442 typed_splay_tree::splay_tree_splay,
19443 typed_splay_tree::splay_tree_foreach_helper,
19444 typed_splay_tree::splay_tree_insert,
19445 typed_splay_tree::splay_tree_remove,
19446 typed_splay_tree::splay_tree_lookup,
19447 typed_splay_tree::splay_tree_predecessor,
19448 typed_splay_tree::splay_tree_successor,
19449 typed_splay_tree::splay_tree_min,
19450 typed_splay_tree::splay_tree_max): Took over from splay-tree.c/.h.
19451 (typed_splay_tree::root, typed_splay_tree::comp,
19452 typed_splay_tree::delete_key,
19453 typed_splay_tree::delete_value): New data members.
19454 * typed-splay-tree.c (selftest::test_str_to_int): Add a test for
19455 typed_splay_tree::remove.
19456
19457 2018-06-15 Matthew Fortune <matthew.fortune@mips.com>
19458
19459 * config/mips/mips.h (ASM_SPEC): Pass through -mcrc, -mno-crc,
19460 -mginv and -mno-ginv to the assembler.
19461 * config/mips/mips.opt (-mcrc): New option.
19462 (-mginv): Likewise.
19463 * doc/invoke.text (-mcrc): Document.
19464 (-mginv): Likewise.
19465
19466 2018-06-15 Nick Clifton <nickc@redhat.com>
19467
19468 PR 84195
19469 * tree.c (escaped_string): New class. Converts an unescaped
19470 string into its escaped equivalent.
19471 (warn_deprecated_use): Use the new class to convert the
19472 deprecation message, if present.
19473 (test_escaped_strings): New self test.
19474 (test_c_tests): Add test_escaped_strings.
19475 * doc/extend.texi (deprecated): Add a note that the
19476 deprecation message is affected by the -fmessage-length
19477 option, and that control characters will be escaped.
19478 (#pragma GCC error): Document this pragma.
19479 (#pragma GCC warning): Likewise.
19480 * doc/invoke.texi (-fmessage-length): Document this option's
19481 effect on the #warning and #error preprocessor directives and
19482 the deprecated attribute.
19483
19484 2018-06-15 Richard Biener <rguenther@suse.de>
19485
19486 * tree-vect-slp.c (vect_slp_bb): Dump MSG_OPTIMIZED_LOCATIONS
19487 here, also noting vector size used.
19488 * tree-vectorizer.c (vectorize_loops): Adjust. Note vector
19489 size used in MSG_OPTIMIZED_LOCATIONS dump.
19490 (pass_slp_vectorize::execute): Adjust.
19491
19492 2018-06-15 Claudiu Zissulescu <claziss@synopsys.com>
19493
19494 PR target/85968
19495 * config/arc/arc.c (arc_return_address_register): Fix
19496 if-condition.
19497
19498 2018-06-15 Richard Biener <rguenther@suse.de>
19499
19500 PR middle-end/86159
19501 * tree-cfg.c (gimplify_build3): Do not strip sign conversions,
19502 leave useless conversion stripping to force_gimple_operand_gsi.
19503 (gimplify_build2): Likewise.
19504 (gimplify_build1): Likewise.
19505
19506 2018-06-15 Richard Biener <rguenther@suse.de>
19507
19508 PR middle-end/86076
19509 * tree-cfg.c (move_stmt_op): unshare invariant addresses
19510 before adjusting their block.
19511
19512 2018-06-15 Sebastian Huber <sebastian.huber@embedded-brains.de>
19513
19514 * config.gcc (riscv*-*-elf* | riscv*-*-rtems*): Use custom
19515 multilibs for *-*-rtems*.
19516 * config/riscv/t-rtems: New file.
19517
19518 2018-06-14 Jakub Jelinek <jakub@redhat.com>
19519
19520 PR middle-end/86122
19521 * match.pd ((A +- CST1) +- CST2): Punt if last resort
19522 unsigned_type_for returns NULL.
19523
19524 PR target/85945
19525 * lower-subreg.c (find_decomposable_subregs): Don't decompose float
19526 subregs of multi-word pseudos unless the float mode has word size.
19527
19528 2018-06-14 Richard Biener <rguenther@suse.de>
19529
19530 PR middle-end/86139
19531 * tree-vect-generic.c (build_word_mode_vector_type): Remove
19532 duplicate and harmful type_hash_canon.
19533 * tree.c (type_hash_canon): Assert we didn't find ourselves.
19534
19535 2018-06-14 Richard Biener <rguenther@suse.de>
19536
19537 PR ipa/86124
19538 * tree-ssa-struct-alias.c (create_variable_info_for): Handle
19539 NULL cgraph_node.
19540
19541 2018-06-14 Sebastian Huber <sebastian.huber@embedded-brains.de>
19542
19543 * config/rtems.h (STDINT_LONG32): Define.
19544
19545 2018-06-13 Matthew Fortune <matthew.fortune@mips.com>
19546 Prachi Godbole <prachi.godbole@imgtec.com>
19547
19548 * config/mips/mips-cpus.def: Define P6600.
19549 * config/mips/mips-tables.opt: Regenerate.
19550 * config/mips/mips.c (mips_ucbranch_type): New enum.
19551 (mips_rtx_cost_data): Add support for P6600.
19552 (mips_issue_rate): Likewise.
19553 (mips_multipass_dfa_lookahead): Likewise.
19554 (mips_avoid_hazard): Likewise.
19555 (mips_reorg_process_insns): Likewise.
19556 (mips_classify_branch_p6600): New function.
19557 * config/mips/mips.h (TUNE_P6600): New define.
19558 (MIPS_ISA_LEVEL_SPEC): Infer mips64r6 from p6600.
19559 (ENABLE_LD_ST_PAIRS): Enable load/store bonding for p6600.
19560 * config/mips/mips.md: Include p6600.md.
19561 (processor): Add p6600.
19562 * config/mips/p6600.md: New file.
19563 * doc/invoke.texi: Add p6600 to supported architectures.
19564
19565 2018-06-13 Martin Sebor <msebor@redhat.com>
19566
19567 PR tree-optimization/86114
19568 * gimple-fold.c (gimple_fold_builtin_strlen): Only handle LHS
19569 of integer types.
19570 * tree-ssa-strlen.c (maybe_set_strlen_range): Same.
19571
19572 2018-06-13 Richard Biener <rguenther@suse.de>
19573
19574 * tree-vect-patterns.c (vect_recog_vector_vector_shift_pattern):
19575 Properly set vector type of the intermediate stmt.
19576 * tree-vect-stmts.c (vectorizable_operation): The destination
19577 var always has vectype_out type.
19578
19579 2018-06-13 Jeff Law <law@redhat.com>
19580
19581 * config/rl78/rl78.c (move_elim_pass): Use TDF_NONE rather than
19582 integer 0 for argument to print_rtl_with_bb.
19583 (rl78_reorg): Likewise.
19584
19585 2018-06-13 David Malcolm <dmalcolm@redhat.com>
19586
19587 * config/arc/arc.c (hwloop_optimize): Strengthen local "end_label"
19588 from rtx to rtx_insn *.
19589 * config/bfin/bfin.c (hwloop_optimize): Likewise for local
19590 "label".
19591 (add_sched_insns_for_speculation): Likewise for local "target",
19592 converting usage of JUMP_LABEL to JUMP_LABEL_AS_INSN.
19593 * config/c6x/c6x.c (reorg_split_calls): Strengthen param "call_labels"
19594 from rtx_insn ** to rtx_code_label **.
19595 (reorg_emit_nops): Likewise.
19596 (c6x_reorg): Likewise for local "call_labels".
19597 * config/sh/sh-protos.h (get_dest_uid): Strengthen 1st param from
19598 rtx to rtx_insn *.
19599 * config/sh/sh.c (dump_table): Strengthen local "lab" from rtx to
19600 rtx_code_label *, adding safe_as_a <rtx_code_label *> casts to
19601 the loops over LABEL_REFS.
19602 (fixup_addr_diff_vecs): Add as_a <rtx_insn *> to usage of
19603 braf_label.
19604 (barrier_align): Convert usage of JUMP_LABEL to JUMP_LABEL_AS_INSN.
19605 (get_dest_uid): Strengthen param "label" from rtx to rtx_insn *.
19606 (split_branches): Strengthen local "olabel" from rtx to
19607 rtx_insn *, adding a safe_as_a cast.
19608 * emit-rtl.c (next_real_insn): Strengthen param from "rtx"
19609 to "rtx_insn *".
19610 (add_insn_after): Likewise for first two params.
19611 (add_insn_before): Likewise.
19612 (remove_insn): Likewise for param.
19613 (emit_pattern_before_noloc): Likewise for second and third params.
19614 (emit_jump_insn_before_noloc): Convert NULL_RTX to NULL.
19615 (emit_call_insn_before_noloc): Likewise.
19616 (emit_debug_insn_before_noloc): Strengthen "before" param from "rtx"
19617 to "rtx_insn *".
19618 (emit_barrier_before): Likewise.
19619 (emit_label_before): Strengthen "label" param from "rtx" to
19620 "rtx_code_label *". Strengthen "before" param from "rtx" to
19621 "rtx_insn *".
19622 (emit_insn_after_1): Strengthen "after" param from "rtx" to
19623 "rtx_insn *".
19624 (emit_pattern_after_noloc): Likewise.
19625 (emit_insn_after_noloc): Likewise.
19626 (emit_jump_insn_after_noloc): Likewise.
19627 (emit_call_insn_after_noloc): Likewise.
19628 (emit_debug_insn_after_noloc): Likewise.
19629 (emit_barrier_after): Likewise.
19630 (emit_label_after): Likewise for both params.
19631 (emit_pattern_after_setloc): Likewise for "after" param. Convert
19632 "loc" param from "int" to "location_t".
19633 (emit_insn_after_setloc): Likewise.
19634 (emit_jump_insn_after_setloc): Likewise.
19635 (emit_call_insn_after_setloc): Likewise.
19636 (emit_debug_insn_after_setloc): Likewise.
19637 (emit_pattern_before_setloc): Likewise for "before" param. Convert
19638 "loc" param from "int" to "location_t".
19639 (emit_pattern_before): Convert NULL_RTX to NULL.
19640 (emit_insn_before_setloc): Convert "loc" param from "int" to
19641 "location_t".
19642 (emit_jump_insn_before_setloc): Likewise.
19643 (emit_call_insn_before_setloc): Likewise.
19644 (emit_debug_insn_before_setloc): Strengthen "before" param from rtx to
19645 rtx_insn *. Convert "loc" param from "int" to "location_t".
19646 * rtl.h (emit_insn_before_setloc, emit_jump_insn_before_setloc,
19647 emit_call_insn_before_setloc, emit_debug_insn_before_setloc):
19648 Convert 3rd param from "int" to "location_t".
19649 (emit_barrier_before, emit_barrier_after, next_real_insn):
19650 Strengthen param from rtx to rtx_insn *.
19651 (emit_label_before): Strengthen 1st param from "rtx" to
19652 "rtx_code_label *". Strengthen 2nd param from "rtx" to
19653 "rtx_insn *".
19654 (emit_insn_after_noloc, emit_jump_insn_after_noloc,
19655 emit_call_insn_after_noloc, emit_debug_insn_after_noloc):
19656 Strengthen 2nd param from "rtx" to "rtx_insn *".
19657 (emit_insn_after_setloc, emit_jump_insn_after_setloc)
19658 emit_call_insn_after_setloc, emit_debug_insn_after_setloc):
19659 Likewise. Convert 3rd param from "int" to "location_t".
19660 (emit_label_after): Strengthen 1st param from "rtx" to
19661 "rtx_code_label *".
19662 (next_real_insn, remove_insn): Strengthen param from "rtx" to
19663 "rtx_insn *".
19664 (add_insn_before, add_insn_after): Strengthen 1st and 2nd params
19665 from "rtx" to "rtx_insn *".
19666
19667 2018-06-13 Jan Hubicka <hubicka@gcc.gnu.org>
19668
19669 * cgraph.c (cgraph_node::get_untransformed_body): Dump function
19670 bodies streamed in with -Q.
19671 * dumpfile.c (dump_files): Add lto-stream-out dump file.
19672 * dumpfile.h (tree_dump_index): Add lto_stream_out.
19673 * gimple-streamer-out.c: Include gimple-pretty-print.h
19674 (output_bb): Dump stmts streamed.
19675 * lto-section-out.c: Include print-tree.h
19676 (lto_begin_section): Dump sections created.
19677 (lto_output_decl_index): Dump decl encoded.
19678 * lto-streamer-out.c: Include print-tree.h
19679 (create_output_block): Dump output block created.
19680 (DFS::DFS_write_tree_body): Dump DFS SCCs streamed.
19681 (output_function): Dump function output.
19682 (output_constructor): Dump constructor streamed.
19683 (write_global_stream): Output indexes encoded.
19684 (produce_asm_for_decls): Dump streams encoded.
19685 * lto-streamer.c (streamer_dump_file): New global var.
19686 * lto-streamer.h (streamer_dump_file): Declare.
19687 * passes.c (ipa_write_summaries): Initialize streamer dump.
19688 * varpool.c (varpool_node::get_constructor): Dump constructors streamed
19689 in.
19690
19691 2018-06-13 Eric Botcazou <ebotcazou@adacore.com>
19692
19693 PR target/86048
19694 * config/i386/winnt.c (i386_pe_seh_cold_init): Do not emit negative
19695 offsets for register save directives. Emit a second batch of save
19696 directives, if need be, when the function accesses prior frames.
19697
19698 2018-06-12 Claudiu Zissulescu <claziss@synopsys.com>
19699
19700 * config/arc/fpu.md (fmasf4): Force operand to register.
19701 (fnmasf4): Likewise.
19702
19703 2018-06-12 Claudiu Zissulescu <claziss@synopsys.com>
19704
19705 * config/arc/arc-protos.h (arc_pad_return): Remove.
19706 * config/arc/arc.c (machine_function): Remove force_short_suffix
19707 and size_reason.
19708 (arc_print_operand): Adjust printing of '&'.
19709 (arc_verify_short): Remove conditional printing of short suffix.
19710 (arc_final_prescan_insn): Remove reference to size_reason.
19711 (pad_return): New function.
19712 (arc_reorg): Call pad_return.
19713 (arc_pad_return): Remove.
19714 (arc_init_machine_status): Remove reference to force_short_suffix.
19715 * config/arc/arc.md (vunspec): Add VUNSPEC_ARC_BLOCKAGE.
19716 (attr length): When attribute iscompact is true force to 2
19717 regardless; in the case of maybe check if we want to force the
19718 instruction to have 4 bytes length.
19719 (nopv): Change it to generate 4 byte long nop as well.
19720 (blockage): New pattern.
19721 (simple_return): Remove call to arc_pad_return.
19722 (p_return_i): Likewise.
19723
19724 2018-06-12 Claudiu Zissulescu <claziss@synopsys.com>
19725
19726 * config/arc/elf.h (LINK_GCC_C_SEQUENCE_SPEC): Define.
19727
19728 2018-06-12 Claudiu Zissulescu <claziss@synopsys.com>
19729
19730 * config/arc/builtins.def (SYNC): SYNC instruction is valid on all
19731 ARC cores.
19732
19733 2018-06-12 Claudiu Zissulescu <claziss@synopsys.com>
19734
19735 * config/arc/arc.c (atomic_exchangesi): EX instruction is default
19736 for ARC700 and ARCv2.
19737
19738 2018-06-13 Chenghua Xu <paul.hua.gm@gmail.com>
19739
19740 PR target/86076
19741 * config/mips/loongson.md (vec_setv4hi): Gen_lowpart for
19742 operands[2] instead of operands[1].
19743
19744
19745 2018-06-12 Richard Sandiford <richard.sandiford@linaro.org>
19746
19747 * lra-constraints.c (simplify_operand_subreg): In the paradoxical
19748 case, check whether the outer register overlaps an unallocatable
19749 register, not just whether it fits the required class.
19750
19751 2018-06-12 Richard Sandiford <richard.sandiford@linaro.org>
19752
19753 * poly-int.h (can_div_trunc_p): Add new overload in which all values
19754 are poly_ints.
19755 * alias.c (get_addr): Extend CONST_INT handling to poly_int_rtx_p.
19756 (memrefs_conflict_p): Likewise.
19757 (init_alias_analysis): Likewise.
19758 * cfgexpand.c (expand_debug_expr): Likewise.
19759 * combine.c (combine_simplify_rtx, force_int_to_mode): Likewise.
19760 * cse.c (fold_rtx): Likewise.
19761 * explow.c (adjust_stack, anti_adjust_stack): Likewise.
19762 * expr.c (emit_block_move_hints): Likewise.
19763 (clear_storage_hints, push_block, emit_push_insn): Likewise.
19764 (store_expr_with_bounds, reduce_to_bit_field_precision): Likewise.
19765 (emit_group_load_1): Use rtx_to_poly_int64 for group offsets.
19766 (emit_group_store): Likewise.
19767 (find_args_size_adjust): Use strip_offset. Use rtx_to_poly_int64
19768 to read the PRE/POST_MODIFY increment.
19769 * calls.c (store_one_arg): Use strip_offset.
19770 * rtlanal.c (rtx_addr_can_trap_p_1): Extend CONST_INT handling to
19771 poly_int_rtx_p.
19772 (set_noop_p): Use rtx_to_poly_int64 for the elements selected
19773 by a VEC_SELECT.
19774 * simplify-rtx.c (avoid_constant_pool_reference): Use strip_offset.
19775 (simplify_binary_operation_1): Extend CONST_INT handling to
19776 poly_int_rtx_p.
19777 * var-tracking.c (compute_cfa_pointer): Take a poly_int64 rather
19778 than a HOST_WIDE_INT.
19779 (hard_frame_pointer_adjustment): Change from HOST_WIDE_INT to
19780 poly_int64.
19781 (adjust_mems, add_stores): Update accodingly.
19782 (vt_canonicalize_addr): Track polynomial offsets.
19783 (emit_note_insn_var_location): Likewise.
19784 (vt_add_function_parameter): Likewise.
19785 (vt_initialize): Likewise.
19786
19787 2018-06-12 Jeff Law <law@redhat.com>
19788
19789 * config.gcc (alpha*-*-freebsd*): Remove.
19790 * config/alpha/freebsd.h: Remove.
19791
19792 2018-06-12 David Malcolm <dmalcolm@redhat.com>
19793
19794 PR other/69968
19795 * spellcheck-tree.c (levenshtein_distance): Rename to...
19796 (get_edit_distance): ...this, and update for underlying renaming.
19797 * spellcheck-tree.h (levenshtein_distance): Rename to...
19798 (get_edit_distance): ...this.
19799 * spellcheck.c (levenshtein_distance): Rename to...
19800 (get_edit_distance): ...this. Convert from Levenshtein distance
19801 to Damerau-Levenshtein distance by supporting transpositions of
19802 adjacent characters. Rename "v1" to "v_next" and "v0" to
19803 "v_one_ago".
19804 (selftest::levenshtein_distance_unit_test_oneway): Rename to...
19805 (selftest::test_edit_distance_unit_test_oneway): ...this, and
19806 update for underlying renaming.
19807 (selftest::levenshtein_distance_unit_test): Rename to...
19808 (selftest::test_get_edit_distance_unit): ...this, and update for
19809 underlying renaming.
19810 (selftest::test_find_closest_string): Add example from PR 69968
19811 where transposition helps
19812 (selftest::test_metric_conditions): Update for renaming.
19813 (selftest::test_metric_conditions): Likewise.
19814 (selftest::spellcheck_c_tests): Likewise.
19815 * spellcheck.h (levenshtein_distance): Rename both overloads to...
19816 (get_edit_distance): ...this.
19817 (best_match::consider): Update for renaming.
19818
19819 2018-06-12 Martin Sebor <msebor@redhat.com>
19820
19821 PR tree-optimization/85259
19822 * builtins.c (compute_objsize): Handle constant offsets.
19823 * gimple-ssa-warn-restrict.c (maybe_diag_offset_bounds): Return
19824 true iff a warning has been issued.
19825 * gimple.h (gimple_nonartificial_location): New function.
19826 * tree-ssa-strlen.c (maybe_diag_stxncpy_trunc): Call
19827 gimple_nonartificial_location and handle -Wno-system-headers.
19828 (handle_builtin_stxncpy): Same.
19829
19830 2018-06-12 Martin Sebor <msebor@redhat.com>
19831
19832 PR c/85931
19833 * fold-const.c (operand_equal_p): Handle SAVE_EXPR.
19834
19835 2018-06-12 Will Schmidt <will_schmidt@vnet.ibm.com>
19836
19837 * config/rs6000/rs6000-c.c (altivec_overloaded_builtins): Add
19838 BUILTIN_VEC_XST entries for pointer to double and long long.
19839
19840 2018-06-12 H.J. Lu <hongjiu.lu@intel.com>
19841
19842 PR target/85990
19843 * config/i386/gnu-user.h (TARGET_THREAD_SPLIT_STACK_OFFSET):
19844 Update comments.
19845 * config/i386/gnu-user64.h (TARGET_THREAD_SPLIT_STACK_OFFSET):
19846 Likewise.
19847
19848 2018-06-12 Martin Liska <mliska@suse.cz>
19849
19850 * doc/options.texi: Document IntegerRange.
19851
19852 2018-06-12 Martin Liska <mliska@suse.cz>
19853
19854 * config/i386/i386.opt: Make MPX-related options as Deprecated.
19855 * opt-functions.awk: Handle Deprecated flag.
19856 * opts-common.c (decode_cmdline_option): Handle cl_deprecated
19857 and report error.
19858 (read_cmdline_option): Report warning for a deprecated option.
19859 * opts.h (struct cl_option): Add new field cl_deprecated.
19860 (CL_ERR_DEPRECATED): New.
19861
19862 2018-06-12 Martin Liska <mliska@suse.cz>
19863
19864 * doc/options.texi: Document Deprecated option flag.
19865
19866 2018-06-12 Claudiu Zissulescu <claziss@synopsys.com>
19867
19868 * config/arc/arc-arch.h (arc_extras): New enum.
19869 (arc_cpu_t):Add field extra.
19870 (arc_cpu_types): Consider the extras.
19871 * config/arc/arc-cpus.def: Add extras info.
19872 * config/arc/arc-opts.h (processor_type): Consider extra field.
19873 * config/arc/arc.c (arc_override_options): Handle extra field.
19874
19875 2018-06-12 Claudiu Zissulescu <claziss@synopsys.com>
19876
19877 * config/arc/arc-arch.h: Update ARC_OPTX macro.
19878 * config/arc/arc-options.def (ARC_OPTX): Introduce a new doc
19879 field.
19880 * config/arc/arc.c (arc_init): Update pic warning.
19881 (irq_range): Update irq range parsing warnings.
19882 (arc_override_options): Update various warning messages.
19883 (arc_handle_aux_attribute): Likewise.
19884
19885 2018-06-12 Robert Suchanek <robert.suchanek@mips.com>
19886
19887 * config/mips/i6400.md (i6400_fpu_fadd): Remove frint.
19888
19889 2018-06-12 Jozef Lawrynowicz <jozef.l@mittosystems.com>
19890
19891 * doc/sourcebuild.texi: Document usage of line number 0 in verify
19892 compiler messages directives.
19893
19894 2018-06-12 Matthew Fortune <mfortune@gmail.com>
19895
19896 * config/mips/mips-cpus.def: New MIPS_CPU for i6500.
19897 * config/mips/mips-tables.opt: Regenerate.
19898 * config/mips/mips.h (MIPS_ISA_LEVEL_SPEC): Mark i6500 as
19899 mips64r6.
19900 * doc/invoke.texi: Document -march=i6500.
19901
19902 2018-06-12 Prachi Godbole <prachi.godbole@imgtec.com>
19903
19904 * config/mips/i6400.md (i6400_gpmuldiv): Remove cpu_unit.
19905 (i6400_gpmul): Add cpu_unit.
19906 (i6400_gpdiv): Likewise.
19907 (i6400_msa_add_d): Update reservations.
19908 (i6400_msa_int_add) Likewise.
19909 (i6400_msa_short_logic3) Likewise.
19910 (i6400_msa_short_logic2) Likewise.
19911 (i6400_msa_short_logic) Likewise.
19912 (i6400_msa_move) Likewise.
19913 (i6400_msa_cmp) Likewise.
19914 (i6400_msa_short_float2) Likewise.
19915 (i6400_msa_div_d) Likewise.
19916 (i6400_msa_long_logic1) Likewise.
19917 (i6400_msa_long_logic2) Likewise.
19918 (i6400_msa_mult) Likewise.
19919 (i6400_msa_long_float2) Likewise.
19920 (i6400_msa_long_float4) Likewise.
19921 (i6400_msa_long_float5) Likewise.
19922 (i6400_msa_long_float8) Likewise.
19923 (i6400_fpu_fadd): Include frint type.
19924 (i6400_fpu_store): New define_insn_reservation.
19925 (i6400_fpu_load): Likewise.
19926 (i6400_fpu_move): Likewise.
19927 (i6400_fpu_fcmp): Likewise.
19928 (i6400_fpu_fmadd): Likewise.
19929 (i6400_int_mult): Include imul3nc type and update reservation.
19930 (i6400_int_div): Include idiv3 type and update reservation.
19931 (i6400_int_load): Update to check type not move_type.
19932 (i6400_int_store): Likewise.
19933 (i6400_int_prefetch): Set zero latency.
19934
19935 2018-06-12 Eric Botcazou <ebotcazou@adacore.com>
19936
19937 * gcc.c: Document new %@{...} sequence.
19938 (LINK_COMMAND_SPEC): Use it for the -L switches.
19939 (cpp_unique_options): Use it for the -I switches.
19940 (at_file_argbuf): New global variable.
19941 (in_at_file): Likewise.
19942 (alloc_args): Create at_file_argbuf.
19943 (clear_args): Truncate at_file_argbuf.
19944 (store_arg): If in_at_file, push the argument onto at_file_argbuf.
19945 (open_at_file): New function.
19946 (close_at_file): Likewise.
19947 (create_at_file): Delete.
19948 (do_spec_1) <'i'>: Use open_at_file/close_at_file.
19949 <'o'>: Likewise.
19950 <'@'>: New case.
19951 (validate_switches_from_spec): Deal with %@{...} sequence.
19952 (validate_switches): Likewise.
19953 (driver::finalize): Call clear_args.
19954
19955 2018-06-11 Rasmus Villemoes <rasmus.villemoes@prevas.dk>
19956
19957 * config/vx-common.h (USE_TM_CLONE_REGISTRY): #define to 0.
19958
19959 2018-06-11 Martin Sebor <msebor@redhat.com>
19960
19961 * doc/invoke.texi (-Wall): List -Wc++17-compat.
19962 (Wno-class-memaccess): Add @opindex.
19963 (Wno-templates, Wno-multiple-inheritance): Same.
19964 (Wno-virtual-inheritance, Wno-namespaces): Same.
19965 (Wno-pedantic, Wno-chkp, Wcoverage-mismatch): Same.
19966 (Wno-format-overflow, Wno-format-truncation): Same.
19967 (Wno-unused-local-typedefs, Walloc-size-larger-than): Same.
19968 (Wno-alloc-size-larger-than, Wframe-larger-than): Same
19969 (Wno-stack-usage, Wno-c++-compat, Wno-c++11-compat): Same.
19970 (Wno-c++14-compat, Wno-c++17-compat, Wno-openmp-simd): Same.
19971 (Wno-unsuffixed-float-constants, Wno-addr-space-convert): Same.
19972 (Wno-misspelled-isr): Same.
19973
19974 2018-06-11 Martin Sebor <msebor@redhat.com>
19975
19976 * PR tree-optimization/86083
19977 * tree-ssa-strlen.c (handle_char_store): Use tree_expr_nonzero_p.
19978
19979 2018-06-11 Zhouyi Zhou <zhouzhouyi@gmail.com>
19980
19981 * tree-eh.c (lower_eh_constructs_2): Add a comma to comment.
19982
19983 2018-06-11 Segher Boessenkool <segher@kernel.crashing.org>
19984
19985 PR target/85755
19986 * config/rs6000/rs6000.md (*movdi_internal32): Put constraint modifiers
19987 on the correct operand.
19988 (*movdi_internal64): Ditto.
19989
19990 2018-06-11 Martin Liska <mliska@suse.cz>
19991
19992 PR tree-optimization/86089
19993 * tree-ssa-strlen.c (get_string_length): Move back removed hunk.
19994
19995 2018-06-11 Julia Koval <julia.koval@intel.com>
19996
19997 * config/i386/vaesintrin.h (_mm_aesdec_epi128, _mm_aesdeclast_epi128)
19998 _mm_aesenc_epi128, _mm_aesenclast_epi128: Remove.
19999 * config/i386/vpclmulqdqintrin.h (_mm_clmulepi64_epi128): Remove.
20000
20001 2018-06-11 Olivier Hainque <hainque@adacore.com>
20002
20003 * dwarf2out.c (gen_compile_unit_die): Fallout to DW_LANG_Ada83
20004 for Ada with strict dwarf2.
20005
20006 2018-06-08 Peter Bergner <bergner@vnet.ibm.com>
20007
20008 PR target/85755
20009 * config/rs6000/rs6000.c (mem_operand_gpr): Enable PRE_INC and PRE_DEC
20010 addresses.
20011
20012 2018-06-08 Jan Hubicka <hubicka@ucw.cz>
20013
20014 * dumpfile.c (FIRST_ME_AUTO_NUMBERED_DUMP): Bump to 4.
20015
20016 2018-06-08 David Edelsohn <dje.gcc@gmail.com>
20017
20018 * config/rs6000/rs6000.c (rs6000_passes_ieee128): Protect with #if
20019 TARGET_ELF.
20020
20021 2018-06-08 Martin Liska <mliska@suse.cz>
20022
20023 * tree-cfg.h (debug_function): Fix argument type to match
20024 implementation.
20025
20026 2018-06-08 Martin Liska <mliska@suse.cz>
20027
20028 * config/powerpcspe/powerpcspe.c (rs6000_xcoff_visibility):
20029 Remove usage of MPX-related (and removed) fields.
20030 * config/rs6000/rs6000.c (rs6000_xcoff_visibility): Likewise.
20031
20032 2018-06-08 David Malcolm <dmalcolm@redhat.com>
20033
20034 * cfg.c (debug): Use TDF_NONE rather than 0.
20035 * cfghooks.c (debug): Likewise.
20036 * dumpfile.c (DUMP_FILE_INFO): Likewise; also for OPTGROUP.
20037 (struct dump_option_value_info): Convert to...
20038 (struct kv_pair): ...this template type.
20039 (dump_options): Convert to kv_pair<dump_flags_t>; use TDF_NONE
20040 rather than 0.
20041 (optinfo_verbosity_options): Likewise.
20042 (optgroup_options): Convert to kv_pair<optgroup_flags_t>; use
20043 OPTGROUP_NONE.
20044 (gcc::dump_manager::dump_register): Use optgroup_flags_t rather
20045 than int for "optgroup_flags" param.
20046 (dump_generic_expr_loc): Use dump_flags_t rather than int for
20047 "dump_kind" param.
20048 (dump_dec): Likewise.
20049 (dump_finish): Use TDF_NONE rather than 0.
20050 (gcc::dump_manager::opt_info_enable_passes): Use optgroup_flags_t
20051 rather than int for "optgroup_flags" param. Use TDF_NONE rather
20052 than 0. Update for change to option_ptr.
20053 (opt_info_switch_p_1): Convert "optgroup_flags" param from int *
20054 to optgroup_flags_t *. Use TDF_NONE and OPTGROUP_NONE rather than
20055 0. Update for changes to optinfo_verbosity_options and
20056 optgroup_options.
20057 (opt_info_switch_p): Convert optgroup_flags from int to
20058 optgroup_flags_t.
20059 (dump_basic_block): Use dump_flags_t rather than int
20060 for "dump_kind" param.
20061 * dumpfile.h (TDF_ADDRESS, TDF_SLIM, TDF_RAW, TDF_DETAILS,
20062 TDF_STATS, TDF_BLOCKS, TDF_VOPS, TDF_LINENO, TDF_UID)
20063 TDF_STMTADDR, TDF_GRAPH, TDF_MEMSYMS, TDF_RHS_ONLY, TDF_ASMNAME,
20064 TDF_EH, TDF_NOUID, TDF_ALIAS, TDF_ENUMERATE_LOCALS, TDF_CSELIB,
20065 TDF_SCEV, TDF_GIMPLE, TDF_FOLDING, MSG_OPTIMIZED_LOCATIONS,
20066 MSG_MISSED_OPTIMIZATION, MSG_NOTE, MSG_ALL, TDF_COMPARE_DEBUG,
20067 TDF_NONE): Convert from macros to...
20068 (enum dump_flag): ...this new enum.
20069 (dump_flags_t): Update to use enum.
20070 (operator|, operator&, operator~, operator|=, operator&=):
20071 Implement for dump_flags_t.
20072 (OPTGROUP_NONE, OPTGROUP_IPA, OPTGROUP_LOOP, OPTGROUP_INLINE,
20073 OPTGROUP_OMP, OPTGROUP_VEC, OPTGROUP_OTHER, OPTGROUP_ALL):
20074 Convert from macros to...
20075 (enum optgroup_flag): ...this new enum.
20076 (optgroup_flags_t): New typedef.
20077 (operator|, operator|=): Implement for optgroup_flags_t.
20078 (struct dump_file_info): Convert field "alt_flags" to
20079 dump_flags_t. Convert field "optgroup_flags" to
20080 optgroup_flags_t.
20081 (dump_basic_block): Use dump_flags_t rather than int for param.
20082 (dump_generic_expr_loc): Likewise.
20083 (dump_dec): Likewise.
20084 (dump_register): Convert param "optgroup_flags" to
20085 optgroup_flags_t.
20086 (opt_info_enable_passes): Likewise.
20087 * early-remat.c (early_remat::dump_edge_list): Use TDF_NONE rather
20088 than 0.
20089 * gimple-pretty-print.c (debug): Likewise.
20090 * gimple-ssa-store-merging.c (bswap_replace): Likewise.
20091 (merged_store_group::apply_stores): Likewise.
20092 * gimple-ssa-strength-reduction.c (insert_initializers): Likewise.
20093 * gimple.c (verify_gimple_pp): Likewise.
20094 * graphite-poly.c (print_pbb_body): Likewise.
20095 * passes.c (pass_manager::register_one_dump_file): Convert
20096 local "optgroup_flags" to optgroup_flags_t.
20097 * print-tree.c (print_node): Use TDF_NONE rather than 0.
20098 (debug): Likewise.
20099 (debug_body): Likewise.
20100 * tree-pass.h (struct pass_data): Convert field "optgroup_flags"
20101 to optgroup_flags_t.
20102 * tree-pretty-print.c (print_struct_decl): Use TDF_NONE rather
20103 than 0.
20104 * tree-ssa-math-opts.c (convert_mult_to_fma_1): Likewise.
20105 (convert_mult_to_fma): Likewise.
20106 * tree-ssa-reassoc.c (undistribute_ops_list): Likewise.
20107 * tree-ssa-sccvn.c (vn_eliminate): Likewise.
20108 * tree-vect-data-refs.c (dump_lower_bound): Convert param
20109 "dump_kind" to dump_flags_t.
20110
20111 2018-06-08 Segher Boessenkool <segher@kernel.crashing.org>
20112
20113 * config/rs6000/rs6000.c (min, max): Delete.
20114
20115 2018-06-08 Segher Boessenkool <segher@kernel.crashing.org>
20116
20117 * doc/invoke.texi (RS/6000 and PowerPC Options): Delete mention of
20118 -mabi=spe and -mabi=no-spe.
20119
20120 2018-06-08 Martin Liska <mliska@suse.cz>
20121
20122 * ipa-pure-const.c (propagate_pure_const): Use ::get at places
20123 where we expect an existing summary.
20124
20125 2018-06-08 Martin Liska <mliska@suse.cz>
20126
20127 * ipa-inline-analysis.c (simple_edge_hints): Use ::get method.
20128 * ipa-inline.h (estimate_edge_growth): Likewise.
20129
20130 2018-06-08 Martin Liska <mliska@suse.cz>
20131
20132 * cgraph.c (function_version_hasher::hash): Use
20133 cgraph_node::get_uid ().
20134 (function_version_hasher::equal):
20135 * cgraph.h (cgraph_node::get_uid): New method.
20136 * ipa-inline.c (update_caller_keys): Use
20137 cgraph_node::get_uid ().
20138 (update_callee_keys): Likewise.
20139 * ipa-utils.c (searchc): Likewise.
20140 (ipa_reduced_postorder): Likewise.
20141 * lto-cgraph.c (input_node): Likewise.
20142 * passes.c (is_pass_explicitly_enabled_or_disabled): Likewise.
20143 * symbol-summary.h (symtab_insertion): Likewise.
20144 (symtab_removal): Likewise.
20145 (symtab_duplication): Likewise.
20146 * tree-pretty-print.c (dump_function_header): Likewise.
20147 * tree-sra.c (convert_callers_for_node): Likewise.
20148
20149 2018-06-08 Martin Liska <mliska@suse.cz>
20150
20151 * cgraph.c (symbol_table::create_edge): Always assign a new
20152 unique number.
20153 (symbol_table::free_edge): Do not recycle numbers.
20154 * cgraph.h (cgraph_edge::get): New method.
20155 * symbol-summary.h (symtab_removal): Use it.
20156 (symtab_duplication): Likewise.
20157 (call_summary::hashable_uid): Remove.
20158
20159 2018-06-08 Martin Liska <mliska@suse.cz>
20160
20161 * ipa-inline-analysis.c (inline_edge_removal_hook): Remove.
20162 (initialize_growth_caches): Remove.
20163 (free_growth_caches): Likewise.
20164 (do_estimate_edge_time): Use edge_growth_cache.
20165 (do_estimate_edge_size): Likewise.
20166 (do_estimate_edge_hints): Likewise.
20167 * ipa-inline.c (reset_edge_caches): Likewise.
20168 (recursive_inlining): Likewise.
20169 (inline_small_functions): Likewise.
20170 * ipa-inline.h (initialize_growth_caches): Remove.
20171 (estimate_edge_size): Likewise.
20172 (estimate_edge_time): Likewise.
20173 (estimate_edge_hints): Likewise.
20174 (reset_edge_growth_cache): Likewise.
20175 * symbol-summary.h (call_summary::remove): New method.
20176
20177 2018-06-08 Martin Liska <mliska@suse.cz>
20178
20179 * ipa-cp.c (class edge_clone_summary): New summary.
20180 (grow_edge_clone_vectors): Remove.
20181 (ipcp_edge_duplication_hook): Remove.
20182 (class edge_clone_summary_t): New call_summary class.
20183 (ipcp_edge_removal_hook): Remove.
20184 (edge_clone_summary_t::duplicate): New function.
20185 (get_next_cgraph_edge_clone): Use edge_clone_summaries.
20186 (create_specialized_node): Likewise.
20187 (ipcp_driver): Initialize edge_clone_summaries and do not
20188 register hooks.
20189
20190 2018-06-08 Martin Liska <mliska@suse.cz>
20191
20192 * symbol-summary.h (get): New function.
20193 (call_summary::m_initialize_when_cloning): New class member.
20194
20195 2018-06-08 Martin Liska <mliska@suse.cz>
20196
20197 * cgraph.c (cgraph_node::remove): Do not recycle uid.
20198 * cgraph.h (symbol_table::release_symbol): Do not pass uid.
20199 (symbol_table::allocate_cgraph_symbol): Do not set uid.
20200 * passes.c (uid_hash_t): Record removed_nodes by their uids.
20201 (remove_cgraph_node_from_order): Use the removed_nodes set.
20202 (do_per_function_toporder): Likwise.
20203 * symbol-summary.h (symtab_insertion): Use cgraph_node::uid
20204 instead of summary_uid.
20205 (symtab_removal): Likewise.
20206 (symtab_duplication): Likewise.
20207
20208 2018-06-08 Martin Liska <mliska@suse.cz>
20209
20210 * ipa-cp.c (ipcp_store_bits_results): Use
20211 ipcp_transformation_sum.
20212 (ipcp_store_vr_results): Likewise.
20213 * ipa-prop.c (ipcp_grow_transformations_if_necessary): Renamed
20214 to ...
20215 (ipcp_transformation_initialize): ... this.
20216 (ipa_set_node_agg_value_chain):
20217 (ipa_node_params_t::duplicate): Use ipcp_transformation_sum.
20218 (write_ipcp_transformation_info): Likewise.
20219 (read_ipcp_transformation_info): Likewise.
20220 (ipcp_update_bits): Likewise.
20221 (ipcp_update_vr): Likewise.
20222 (ipcp_transform_function): Likewise.
20223 * ipa-prop.h: Rename ipcp_transformation_summary to
20224 ipcp_transformation.
20225 (class ipcp_transformation_t): New function summary.
20226 (ipcp_get_transformation_summary): Use ipcp_transformation_sum.
20227 (ipa_get_agg_replacements_for_node): Likewise.
20228
20229 2018-06-08 Martin Liska <mliska@suse.cz>
20230
20231 * ipa-pure-const.c (struct funct_state_d): Do it class instead
20232 of struct.
20233 (class funct_state_summary_t): New function_summary class.
20234 (has_function_state): Remove.
20235 (get_function_state): Likewise.
20236 (set_function_state): Likewise.
20237 (add_new_function): Likewise.
20238 (funct_state_summary_t::insert): New function.
20239 (duplicate_node_data): Remove.
20240 (remove_node_data): Remove.
20241 (funct_state_summary_t::duplicate): New function.
20242 (register_hooks): Create new funct_state_summaries.
20243 (pure_const_generate_summary): Use it.
20244 (pure_const_write_summary): Likewise.
20245 (pure_const_read_summary): Likewise.
20246 (propagate_pure_const): Likewise.
20247 (propagate_nothrow): Likewise.
20248 (dump_malloc_lattice): Likewise.
20249 (propagate_malloc): Likewise.
20250 (execute): Do not register hooks, just remove summary
20251 instead.
20252 (pass_ipa_pure_const::pass_ipa_pure_const): Simplify
20253 constructor.
20254
20255 2018-06-08 Martin Liska <mliska@suse.cz>
20256
20257 * ipa-reference.c (remove_node_data): Remove.
20258 (duplicate_node_data): Likewise.
20259 (class ipa_ref_var_info_summary_t): New class.
20260 (class ipa_ref_opt_summary_t): Likewise.
20261 (get_reference_vars_info): Use ipa_ref_var_info_summaries.
20262 (get_reference_optimization_summary): Use
20263 ipa_ref_opt_sum_summaries.
20264 (set_reference_vars_info): Remove.
20265 (set_reference_optimization_summary): Likewise.
20266 (ipa_init): Create summaries.
20267 (init_function_info): Use function summary.
20268 (ipa_ref_opt_summary_t::duplicate): New function.
20269 (ipa_ref_opt_summary_t::remove): New function.
20270 (get_read_write_all_from_node): Fix GNU coding style.
20271 (propagate): Use function summary.
20272 (write_node_summary_p): Fix GNU coding style.
20273 (stream_out_bitmap): Likewise.
20274 (ipa_reference_read_optimization_summary): Use function summary.
20275 (ipa_reference_c_finalize): Do not release hooks.
20276
20277 2018-06-08 Martin Liska <mliska@suse.cz>
20278
20279 * ipa-fnsummary.c (dump_ipa_call_summary): Use ::get method.
20280 (analyze_function_body): Extract multiple calls of get_create.
20281 * ipa-inline-analysis.c (simple_edge_hints): Likewise.
20282 * ipa-inline.c (recursive_inlining): Use ::get method.
20283 * ipa-inline.h (estimate_edge_growth): Likewise.
20284
20285 2018-06-08 Martin Liska <mliska@suse.cz>
20286
20287 * hsa-common.h (enum hsa_function_kind): Rename HSA_NONE to
20288 HSA_INVALID.
20289 (hsa_function_summary::hsa_function_summary): Use the new enum
20290 value.
20291 (hsa_gpu_implementation_p): Use hsa_summaries::get.
20292 * hsa-gen.c (hsa_get_host_function): Likewise.
20293 (get_brig_function_name): Likewise.
20294 * ipa-hsa.c (process_hsa_functions): Likewise.
20295 (ipa_hsa_write_summary): Likewise.
20296 * symbol-summary.h (symtab_duplication): Use ::get function/
20297 (get): New function.
20298
20299 2018-06-08 Martin Liska <mliska@suse.cz>
20300
20301 * config/i386/i386.c (ix86_can_inline_p): Use get_create instead
20302 of get.
20303 * hsa-common.c (hsa_summary_t::link_functions): Likewise.
20304 (hsa_register_kernel): Likewise.
20305 * hsa-common.h (hsa_gpu_implementation_p): Likewise.
20306 * hsa-gen.c (hsa_get_host_function): Likewise.
20307 (get_brig_function_name): Likewise.
20308 (generate_hsa): Likewise.
20309 (pass_gen_hsail::execute): Likewise.
20310 * ipa-cp.c (ipcp_cloning_candidate_p): Likewise.
20311 (devirtualization_time_bonus): Likewise.
20312 (ipcp_propagate_stage): Likewise.
20313 * ipa-fnsummary.c (redirect_to_unreachable): Likewise.
20314 (edge_set_predicate): Likewise.
20315 (evaluate_conditions_for_known_args): Likewise.
20316 (evaluate_properties_for_edge): Likewise.
20317 (ipa_fn_summary::reset): Likewise.
20318 (ipa_fn_summary_t::duplicate): Likewise.
20319 (dump_ipa_call_summary): Likewise.
20320 (ipa_dump_fn_summary): Likewise.
20321 (analyze_function_body): Likewise.
20322 (compute_fn_summary): Likewise.
20323 (estimate_edge_devirt_benefit): Likewise.
20324 (estimate_edge_size_and_time): Likewise.
20325 (estimate_calls_size_and_time): Likewise.
20326 (estimate_node_size_and_time): Likewise.
20327 (inline_update_callee_summaries): Likewise.
20328 (remap_edge_change_prob): Likewise.
20329 (remap_edge_summaries): Likewise.
20330 (ipa_merge_fn_summary_after_inlining): Likewise.
20331 (ipa_update_overall_fn_summary): Likewise.
20332 (read_ipa_call_summary): Likewise.
20333 (inline_read_section): Likewise.
20334 (write_ipa_call_summary): Likewise.
20335 (ipa_fn_summary_write): Likewise.
20336 (ipa_free_fn_summary): Likewise.
20337 * ipa-hsa.c (process_hsa_functions): Likewise.
20338 (ipa_hsa_write_summary): Likewise.
20339 (ipa_hsa_read_section): Likewise.
20340 * ipa-icf.c (sem_function::merge): Likewise.
20341 * ipa-inline-analysis.c (simple_edge_hints): Likewise.
20342 (do_estimate_edge_time): Likewise.
20343 (estimate_size_after_inlining): Likewise.
20344 (estimate_growth): Likewise.
20345 (growth_likely_positive): Likewise.
20346 * ipa-inline-transform.c (clone_inlined_nodes): Likewise.
20347 (inline_call): Likewise.
20348 * ipa-inline.c (caller_growth_limits): Likewise.
20349 (can_inline_edge_p): Likewise.
20350 (can_inline_edge_by_limits_p): Likewise.
20351 (compute_uninlined_call_time): Likewise.
20352 (compute_inlined_call_time): Likewise.
20353 (want_inline_small_function_p): Likewise.
20354 (edge_badness): Likewise.
20355 (update_caller_keys): Likewise.
20356 (update_callee_keys): Likewise.
20357 (recursive_inlining): Likewise.
20358 (inline_small_functions): Likewise.
20359 (inline_to_all_callers_1): Likewise.
20360 (dump_overall_stats): Likewise.
20361 (early_inline_small_functions): Likewise.
20362 (early_inliner): Likewise.
20363 * ipa-inline.h (estimate_edge_growth): Likewise.
20364 * ipa-profile.c (ipa_propagate_frequency_1): Likewise.
20365 * ipa-prop.c (ipa_make_edge_direct_to_target): Likewise.
20366 * ipa-prop.h (IPA_NODE_REF): Likewise.
20367 (IPA_EDGE_REF): Likewise.
20368 * ipa-pure-const.c (malloc_candidate_p): Likewise.
20369 (propagate_malloc): Likewise.
20370 * ipa-split.c (execute_split_functions): Likewise.
20371 * symbol-summary.h: Rename get to get_create.
20372 (get): Likewise.
20373 (get_create): Likewise.
20374 * tree-sra.c (ipa_sra_preliminary_function_checks): Likewise.
20375
20376 2018-06-08 Martin Liska <mliska@suse.cz>
20377
20378 * symbol-summary.h (release): Move definition out of class
20379 declaration.
20380 (symtab_removal): Likewise.
20381 (symtab_duplication): Likewise.
20382
20383 2018-06-08 Martin Liska <mliska@suse.cz>
20384
20385 * symbol-summary.h (function_summary): Move constructor
20386 implementation out of class declaration.
20387 (release): Likewise.
20388 (symtab_insertion): Likewise.
20389 (symtab_removal): Likewise.
20390 (symtab_duplication): Likewise.
20391 (get): Likewise.
20392
20393 2018-06-08 Martin Liska <mliska@suse.cz>
20394
20395 * Makefile.in: Remove support for MPX (macros, related functions,
20396 fields in cgraph_node, ...).
20397 * builtin-types.def (BT_BND): Likewise.
20398 (BT_FN_BND_CONST_PTR): Likewise.
20399 (BT_FN_CONST_PTR_BND): Likewise.
20400 (BT_FN_VOID_PTR_BND): Likewise.
20401 (BT_FN_BND_CONST_PTR_SIZE): Likewise.
20402 (BT_FN_VOID_CONST_PTR_BND_CONST_PTR): Likewise.
20403 * builtins.c (expand_builtin_memcpy_with_bounds): Likewise.
20404 (expand_builtin_mempcpy_with_bounds): Likewise.
20405 (expand_builtin_memset_with_bounds): Likewise.
20406 (expand_builtin_memset_args): Likewise.
20407 (std_expand_builtin_va_start): Likewise.
20408 (expand_builtin): Likewise.
20409 (expand_builtin_with_bounds): Likewise.
20410 * builtins.def (DEF_BUILTIN_CHKP): Likewise.
20411 (DEF_LIB_BUILTIN_CHKP): Likewise.
20412 (DEF_EXT_LIB_BUILTIN_CHKP): Likewise.
20413 (DEF_CHKP_BUILTIN): Likewise.
20414 (BUILT_IN_MEMCPY): Likewise.
20415 (BUILT_IN_MEMMOVE): Likewise.
20416 (BUILT_IN_MEMPCPY): Likewise.
20417 (BUILT_IN_MEMSET): Likewise.
20418 (BUILT_IN_STPCPY): Likewise.
20419 (BUILT_IN_STRCAT): Likewise.
20420 (BUILT_IN_STRCHR): Likewise.
20421 (BUILT_IN_STRCPY): Likewise.
20422 (BUILT_IN_STRLEN): Likewise.
20423 (BUILT_IN_MEMCPY_CHK): Likewise.
20424 (BUILT_IN_MEMMOVE_CHK): Likewise.
20425 (BUILT_IN_MEMPCPY_CHK): Likewise.
20426 (BUILT_IN_MEMSET_CHK): Likewise.
20427 (BUILT_IN_STPCPY_CHK): Likewise.
20428 (BUILT_IN_STRCAT_CHK): Likewise.
20429 (BUILT_IN_STRCPY_CHK): Likewise.
20430 * calls.c (store_bounds): Likewise.
20431 (emit_call_1): Likewise.
20432 (special_function_p): Likewise.
20433 (maybe_warn_nonstring_arg): Likewise.
20434 (initialize_argument_information): Likewise.
20435 (finalize_must_preallocate): Likewise.
20436 (compute_argument_addresses): Likewise.
20437 (expand_call): Likewise.
20438 * cfgexpand.c (expand_call_stmt): Likewise.
20439 (expand_return): Likewise.
20440 (expand_gimple_stmt_1): Likewise.
20441 (pass_expand::execute): Likewise.
20442 * cgraph.c (cgraph_edge::redirect_call_stmt_to_callee): Likewise.
20443 (cgraph_node::remove): Likewise.
20444 (cgraph_node::dump): Likewise.
20445 (cgraph_node::verify_node): Likewise.
20446 * cgraph.h (chkp_function_instrumented_p): Likewise.
20447 (symtab_node::get_alias_target): Likewise.
20448 (cgraph_node::can_remove_if_no_direct_calls_and_refs_p): Likewise.
20449 (cgraph_local_p): Likewise.
20450 * cgraphbuild.c (cgraph_edge::rebuild_edges): Likewise.
20451 (cgraph_edge::rebuild_references): Likewise.
20452 * cgraphunit.c (varpool_node::finalize_decl): Likewise.
20453 (walk_polymorphic_call_targets): Likewise.
20454 (cgraph_node::expand_thunk): Likewise.
20455 (symbol_table::output_weakrefs): Likewise.
20456 * common/config/i386/i386-common.c (OPTION_MASK_ISA2_GENERAL_REGS_ONLY_UNSET): Likewise.
20457 (ix86_handle_option): Likewise.
20458 * config/i386/constraints.md: Likewise.
20459 * config/i386/i386-builtin-types.def (BND): Likewise.
20460 (VOID): Likewise.
20461 (PVOID): Likewise.
20462 (ULONG): Likewise.
20463 * config/i386/i386-builtin.def (BDESC_END): Likewise.
20464 (BDESC_FIRST): Likewise.
20465 (BDESC): Likewise.
20466 * config/i386/i386-c.c (ix86_target_macros_internal): Likewise.
20467 * config/i386/i386-protos.h (ix86_bnd_prefixed_insn_p): Likewise.
20468 * config/i386/i386.c (enum reg_class): Likewise.
20469 (ix86_target_string): Likewise.
20470 (ix86_option_override_internal): Likewise.
20471 (ix86_conditional_register_usage): Likewise.
20472 (ix86_valid_target_attribute_inner_p): Likewise.
20473 (ix86_set_indirect_branch_type): Likewise.
20474 (ix86_set_current_function): Likewise.
20475 (ix86_function_arg_regno_p): Likewise.
20476 (init_cumulative_args): Likewise.
20477 (ix86_function_arg_advance): Likewise.
20478 (ix86_function_arg): Likewise.
20479 (ix86_pass_by_reference): Likewise.
20480 (ix86_function_value_regno_p): Likewise.
20481 (ix86_function_value_1): Likewise.
20482 (ix86_function_value_bounds): Likewise.
20483 (ix86_return_in_memory): Likewise.
20484 (ix86_setup_incoming_vararg_bounds): Likewise.
20485 (ix86_va_start): Likewise.
20486 (indirect_thunk_need_prefix): Likewise.
20487 (print_reg): Likewise.
20488 (ix86_print_operand): Likewise.
20489 (ix86_expand_call): Likewise.
20490 (ix86_output_function_return): Likewise.
20491 (reg_encoded_number): Likewise.
20492 (BDESC_VERIFYS): Likewise.
20493 (ix86_init_mpx_builtins): Likewise.
20494 (ix86_init_builtins): Likewise.
20495 (ix86_emit_cmove): Likewise.
20496 (ix86_emit_move_max): Likewise.
20497 (ix86_expand_builtin): Likewise.
20498 (ix86_builtin_mpx_function): Likewise.
20499 (ix86_get_arg_address_for_bt): Likewise.
20500 (ix86_load_bounds): Likewise.
20501 (ix86_store_bounds): Likewise.
20502 (ix86_load_returned_bounds): Likewise.
20503 (ix86_store_returned_bounds): Likewise.
20504 (ix86_class_likely_spilled_p): Likewise.
20505 (ix86_hard_regno_mode_ok): Likewise.
20506 (x86_order_regs_for_local_alloc): Likewise.
20507 (ix86_mitigate_rop): Likewise.
20508 (ix86_bnd_prefixed_insn_p): Likewise.
20509 (ix86_mpx_bound_mode): Likewise.
20510 (ix86_make_bounds_constant): Likewise.
20511 (ix86_initialize_bounds): Likewise.
20512 (TARGET_LOAD_BOUNDS_FOR_ARG): Likewise.
20513 (TARGET_STORE_BOUNDS_FOR_ARG): Likewise.
20514 (TARGET_LOAD_RETURNED_BOUNDS): Likewise.
20515 (TARGET_STORE_RETURNED_BOUNDS): Likewise.
20516 (TARGET_CHKP_BOUND_MODE): Likewise.
20517 (TARGET_BUILTIN_CHKP_FUNCTION): Likewise.
20518 (TARGET_CHKP_FUNCTION_VALUE_BOUNDS): Likewise.
20519 (TARGET_CHKP_MAKE_BOUNDS_CONSTANT): Likewise.
20520 (TARGET_CHKP_INITIALIZE_BOUNDS): Likewise.
20521 * config/i386/i386.h (TARGET_MPX): Likewise.
20522 (TARGET_MPX_P): Likewise.
20523 (VALID_BND_REG_MODE): Likewise.
20524 (FIRST_BND_REG): Likewise.
20525 (LAST_BND_REG): Likewise.
20526 (enum reg_class): Likewise.
20527 (BND_REG_P): Likewise.
20528 (BND_REGNO_P): Likewise.
20529 (BNDmode): Likewise.
20530 (ADJUST_INSN_LENGTH): Likewise.
20531 * config/i386/i386.md: Likewise.
20532 * config/i386/i386.opt: Likewise.
20533 * config/i386/linux-common.h (LIBMPX_LIBS): Likewise.
20534 (defined): Likewise.
20535 (LINK_MPX): Likewise.
20536 (MPX_SPEC): Likewise.
20537 (LIBMPX_SPEC): Likewise.
20538 (LIBMPXWRAPPERS_SPEC): Likewise.
20539 (CHKP_SPEC): Likewise.
20540 * config/i386/predicates.md: Likewise.
20541 * dbxout.c (dbxout_type): Likewise.
20542 * doc/extend.texi: Likewise.
20543 * doc/invoke.texi: Likewise.
20544 * doc/md.texi: Likewise.
20545 * doc/tm.texi: Likewise.
20546 * doc/tm.texi.in: Likewise.
20547 * dwarf2out.c (is_base_type): Likewise.
20548 (gen_formal_types_die): Likewise.
20549 (gen_subprogram_die): Likewise.
20550 (gen_type_die_with_usage): Likewise.
20551 (gen_decl_die): Likewise.
20552 (dwarf2out_late_global_decl): Likewise.
20553 * expr.c (expand_assignment): Likewise.
20554 (emit_storent_insn): Likewise.
20555 (store_expr_with_bounds): Likewise.
20556 (store_expr): Likewise.
20557 (expand_expr_real_1): Likewise.
20558 * expr.h (store_expr_with_bounds): Likewise.
20559 * function.c (use_register_for_decl): Likewise.
20560 (struct bounds_parm_data): Likewise.
20561 (assign_parms_augmented_arg_list): Likewise.
20562 (assign_parm_find_entry_rtl): Likewise.
20563 (assign_parm_is_stack_parm): Likewise.
20564 (assign_parm_load_bounds): Likewise.
20565 (assign_bounds): Likewise.
20566 (assign_parms): Likewise.
20567 (expand_function_start): Likewise.
20568 * gcc.c (CHKP_SPEC): Likewise.
20569 * gimple-fold.c (gimple_fold_builtin_memory_op): Likewise.
20570 * gimple-ssa-warn-restrict.c (builtin_access::builtin_access): Likewise.
20571 (wrestrict_dom_walker::check_call): Likewise.
20572 * gimple.c (gimple_build_call_from_tree): Likewise.
20573 * gimple.h (enum gf_mask): Likewise.
20574 (gimple_call_with_bounds_p): Likewise.
20575 (gimple_call_set_with_bounds): Likewise.
20576 * gimplify.c (gimplify_init_constructor): Likewise.
20577 * ipa-cp.c (initialize_node_lattices): Likewise.
20578 (propagate_constants_across_call): Likewise.
20579 (find_more_scalar_values_for_callers_subset): Likewise.
20580 * ipa-hsa.c (process_hsa_functions): Likewise.
20581 * ipa-icf-gimple.c (func_checker::compare_gimple_call): Likewise.
20582 * ipa-icf.c (sem_function::merge): Likewise.
20583 * ipa-inline.c (early_inliner): Likewise.
20584 * ipa-pure-const.c (warn_function_noreturn): Likewise.
20585 (warn_function_cold): Likewise.
20586 (propagate_pure_const): Likewise.
20587 * ipa-ref.h (enum GTY): Likewise.
20588 * ipa-split.c (find_retbnd): Likewise.
20589 (consider_split): Likewise.
20590 (split_function): Likewise.
20591 * ipa-visibility.c (cgraph_externally_visible_p): Likewise.
20592 * ipa.c (walk_polymorphic_call_targets): Likewise.
20593 (symbol_table::remove_unreachable_nodes): Likewise.
20594 (process_references): Likewise.
20595 (cgraph_build_static_cdtor_1): Likewise.
20596 * lto-cgraph.c (lto_output_node): Likewise.
20597 (output_refs): Likewise.
20598 (compute_ltrans_boundary): Likewise.
20599 (input_overwrite_node): Likewise.
20600 (input_node): Likewise.
20601 (input_cgraph_1): Likewise.
20602 * params.def (PARAM_CHKP_MAX_CTOR_SIZE): Likewise.
20603 * passes.c (pass_manager::execute_early_local_passes): Likewise.
20604 (class pass_chkp_instrumentation_passes): Likewise.
20605 (make_pass_chkp_instrumentation_passes): Likewise.
20606 * passes.def: Likewise.
20607 * rtl.h (struct GTY): Likewise.
20608 (CALL_EXPR_WITH_BOUNDS_P): Likewise.
20609 * stor-layout.c (layout_type): Likewise.
20610 * symtab.c: Likewise.
20611 * target.def: Likewise.
20612 * targhooks.c (default_chkp_bound_type): Likewise.
20613 (default_chkp_bound_mode): Likewise.
20614 (default_builtin_chkp_function): Likewise.
20615 (default_chkp_function_value_bounds): Likewise.
20616 (default_chkp_make_bounds_constant): Likewise.
20617 (default_chkp_initialize_bounds): Likewise.
20618 * targhooks.h (default_chkp_bound_type): Likewise.
20619 (default_chkp_bound_mode): Likewise.
20620 (default_builtin_chkp_function): Likewise.
20621 (default_chkp_function_value_bounds): Likewise.
20622 (default_chkp_make_bounds_constant): Likewise.
20623 (default_chkp_initialize_bounds): Likewise.
20624 * toplev.c (compile_file): Likewise.
20625 (process_options): Likewise.
20626 * tree-core.h (DEF_BUILTIN): Likewise.
20627 (DEF_BUILTIN_CHKP): Likewise.
20628 * tree-inline.c (declare_return_variable): Likewise.
20629 (remap_gimple_stmt): Likewise.
20630 (copy_bb): Likewise.
20631 (initialize_inlined_parameters): Likewise.
20632 (expand_call_inline): Likewise.
20633 * tree-pass.h (make_pass_ipa_chkp_versioning): Likewise.
20634 (make_pass_ipa_chkp_early_produce_thunks): Likewise.
20635 (make_pass_ipa_chkp_produce_thunks): Likewise.
20636 (make_pass_chkp): Likewise.
20637 (make_pass_chkp_opt): Likewise.
20638 (make_pass_chkp_instrumentation_passes): Likewise.
20639 * tree-pretty-print.c (dump_generic_node): Likewise.
20640 * tree-ssa-ccp.c (insert_clobber_before_stack_restore): Likewise.
20641 * tree-ssa-dce.c (propagate_necessity): Likewise.
20642 (eliminate_unnecessary_stmts): Likewise.
20643 * tree-ssa-pre.c (create_expression_by_pieces): Likewise.
20644 * tree-ssa-sccvn.c (copy_reference_ops_from_call): Likewise.
20645 * tree-ssa-sccvn.h: Likewise.
20646 * tree-ssa-strlen.c (get_string_length): Likewise.
20647 (valid_builtin_call): Likewise.
20648 (adjust_last_stmt): Likewise.
20649 (handle_builtin_strchr): Likewise.
20650 (handle_builtin_strcpy): Likewise.
20651 (handle_builtin_stxncpy): Likewise.
20652 (handle_builtin_memcpy): Likewise.
20653 (handle_builtin_strcat): Likewise.
20654 (strlen_check_and_optimize_stmt): Likewise.
20655 * tree-stdarg.c (expand_ifn_va_arg_1): Likewise.
20656 * tree-streamer-in.c: Likewise.
20657 * tree-streamer.c (record_common_node): Likewise.
20658 * tree.c (tree_code_size): Likewise.
20659 (wide_int_to_tree_1): Likewise.
20660 (type_contains_placeholder_1): Likewise.
20661 (build_common_tree_nodes): Likewise.
20662 * tree.def (POINTER_BOUNDS_TYPE): Likewise.
20663 * tree.h (POINTER_BOUNDS_TYPE_P): Likewise.
20664 (POINTER_BOUNDS_P): Likewise.
20665 (BOUNDED_TYPE_P): Likewise.
20666 (BOUNDED_P): Likewise.
20667 (CALL_WITH_BOUNDS_P): Likewise.
20668 (pointer_bounds_type_node): Likewise.
20669 * value-prof.c (gimple_ic): Likewise.
20670 * var-tracking.c (vt_add_function_parameters): Likewise.
20671 * varasm.c (make_decl_rtl): Likewise.
20672 (assemble_start_function): Likewise.
20673 (output_constant): Likewise.
20674 (maybe_assemble_visibility): Likewise.
20675 * varpool.c (ctor_for_folding): Likewise.
20676 * chkp-builtins.def: Remove.
20677 * ipa-chkp.c: Remove.
20678 * ipa-chkp.h: Remove.
20679 * rtl-chkp.c: Remove.
20680 * rtl-chkp.h: Remove.
20681 * tree-chkp-opt.c: Remove.
20682 * tree-chkp.c: Remove.
20683 * tree-chkp.h: Remove.
20684
20685 2018-06-07 Carl Love <cel@us.ibm.com>
20686
20687 * config/rs6000/vsx.md (vextract_fp_from_shorth,
20688 vextract_fp_from_shortl): Add BE support.
20689
20690 2018-06-07 Paul Koning <ni1d@arrl.net>
20691
20692 * compare-elim.c (try_merge_compare): Don't merge compare if
20693 address contains a side effect.
20694 (try_eliminate_compare): Likewise.
20695
20696 2018-06-07 Olga Makhotina <olga.makhotina@intel.com>
20697
20698 * config.gcc: Support "tremont".
20699 * config/i386/driver-i386.c (host_detect_local_cpu): Detect "tremont".
20700 * config/i386/i386-c.c (ix86_target_macros_internal): Handle
20701 PROCESSOR_TREMONT.
20702 * config/i386/i386.c (m_TREMONT): Define.
20703 (processor_target_table): Add "tremont".
20704 (PTA_TREMONT): Define.
20705 (ix86_lea_outperforms): Add TARGET_TREMONT.
20706 (get_builtin_code_for_version): Handle PROCESSOR_TREMONT.
20707 (fold_builtin_cpu): Add M_INTEL_TREMONT, replace M_INTEL_GOLDMONT
20708 and M_INTEL_GOLDMONT_PLUS.
20709 (fold_builtin_cpu): Add "tremont".
20710 (ix86_add_stmt_cost): Add TARGET_TREMONT.
20711 (ix86_option_override_internal): Add "tremont".
20712 * config/i386/i386.h (processor_costs): Define TARGET_TREMONT.
20713 (processor_type): Add PROCESSOR_TREMONT.
20714 * config/i386/x86-tune.def: Add m_TREMONT.
20715 * doc/invoke.texi: Add tremont as x86 -march=/-mtune= CPU type.
20716
20717 2018-06-07 Jozef Lawrynowicz <jozef.l@mittosystems.com>
20718
20719 * config/msp430/msp430.c (msp430_mcu_name): Set the "i" in the
20720 symbol defined for msp430i* devices to be lower case.
20721
20722 2018-06-07 Richard Biener <rguenther@suse.de>
20723
20724 * graphite-sese-to-poly.c (extract_affine): Avoid unneded
20725 wrapping. Properly wrap the result of a BIT_NOT_EXPR.
20726 Properly wrap signed arithmetic if overflow wraps.
20727
20728 2018-06-07 Jakub Jelinek <jakub@redhat.com>
20729
20730 PR tree-optimization/69615
20731 * tree-ssa-reassoc.c (optimize_range_tests_var_bound): If rhs2 is lhs
20732 of a cast from a same precision integral SSA_NAME in a bb dominated
20733 by first_bb, retry with rhs2 set to the rhs1 of the cast. Don't emit
20734 cast to utype if rhs2 has already a compatible type.
20735
20736 2018-06-07 Richard Biener <rguenther@suse.de>
20737
20738 PR tree-optimization/85935
20739 * graphite-scop-detection.c (find_params_in_bb): Analyze
20740 condition operands with respect to the correct loop. Assert
20741 the analysis doesn't fail.
20742
20743 2018-06-04 Carl Love <cel@us.ibm.com>
20744
20745 * config/rs6000/vsx.md (first_match_index_<mode>): Calculate index
20746 using natural element order. Use gen_lshrsi3 instead of gen_ashrsi3
20747 as it is slightly cheaper.
20748 (first_match_or_eos_index_<mode>):
20749 Calculate index using natural element order.
20750 (first_match_index_<mode>):
20751 Calculate index using natural element order.
20752 (first_match_or_eos_index_<mode>):
20753 Calculate index using natural order.
20754 (define_insn vclzlsbb): Change to define_insn vclzlsbb_<mode>.
20755 for BE and LE modes.
20756 * config/rs6000/rs6000-c.c: Rename P9V_BUILTIN_VCLZLSBB,
20757 P9V_BUILTIN_VCLZLSBB_V16QI.
20758 * config/rs6000/rs6000-builtin.def: Make VCLZLSBB mode
20759 specific.
20760
20761 2018-06-06 Kelvin Nilsen <kelvin@gcc.gnu.org>
20762
20763 * doc/extend.texi (PowerPC AltiVec Built-in Functions): Adjust
20764 indentation and line wrap for many prototypes. Add missing
20765 @smallexample directives around block of prototypes for vec_xl and
20766 vec_xst.
20767
20768 2018-06-05 Michael Meissner <meissner@linux.ibm.com>
20769
20770 * config/rs6000/rs6000.c (rs6000_passes_ieee128): New boolean to
20771 track if we pass or return IEEE 128-bit floating point.
20772 (ieee128_mangling_gcc_8_1): New boolean to say whether to generate
20773 C++ mangling that is compatible with GCC 8.1.
20774 (TARGET_ASM_GLOBALIZE_DECL_NAME): Override target hook.
20775 (init_cumulative_args): Note if we pass or return IEEE 128-bit
20776 floating point types.
20777 (rs6000_function_arg_advance_1): Likewise.
20778 (rs6000_mangle_type): Optionally generate mangled names that match
20779 what GCC 8.1 generated for IEEE 128-bit floating point types.
20780 (rs6000_globalize_decl_name): If we have an external function that
20781 passes or returns IEEE 128-bit types, generate a weak reference
20782 from the mangled name used in GCC 8.1 to the current mangled
20783 name.
20784 (rs6000_init_builtins): Make __ibm128 use the long double type if
20785 long double is IBM extended double. Make __float128 use the long
20786 double type if long double is IEEE 128-bit.
20787
20788 PR target/85657
20789 * config/rs6000/rs6000-builtin.def (BU_IBM128_2): New helper
20790 macro for __ibm128 built-in functions.
20791 (PACK_IF): Add __ibm128 pack/unpack functions.
20792 (UNPACK_IF): Likewise.
20793 * config/rs6000/rs6000.c (rs6000_builtin_mask_calculate): Do not
20794 enable long double built-in functions if long double is IEEE
20795 128-bit floating point.
20796 (rs6000_invalid_builtin): Update long double built-in function
20797 error message.
20798 (rs6000_expand_builtin): For PACK_IF and UNPACK_IF built-in
20799 functions, adjust the built-in function to use the long double
20800 built-in function if __ibm128 and long double are the same type.
20801 * doc/extend.texi (PowerPC builtins): Update documention for
20802 __builtin_{,un}pack_longdouble. Add documentation for
20803 __builtin_{,un}pack_ibm128.
20804
20805 2018-06-06 Jim Wilson <jimw@sifive.com>
20806
20807 * config/riscv/riscv.c (enum riscv_privilege_levels): New.
20808 (struct machine_function): New field interrupt_mode.
20809 (riscv_handle_type_attribute): New function. Add forward declaration.
20810 (riscv_attribute_table) <interrupt>: Use riscv_handle_type_attribute.
20811 (riscv_expand_epilogue): Check interrupt_mode field.
20812 (riscv_set_current_function): Check interrupt attribute args and
20813 set interrupt_mode field.
20814 * config/riscv/riscv.md (UNSPECV_SRET, UNSPECV_URET): New.
20815 (riscv_sret, riscv_uret): New.
20816 * doc/extend.texi (RISC-V Function Attributes) <interrupt>: Document
20817 new arguments to interrupt attribute.
20818
20819 2018-06-06 Peter Bergner <bergner@vnet.ibm.com>
20820
20821 PR target/63177
20822 * /config/rs6000/rs6000.h (ASM_CPU_SPEC): Add support for -mpower9.
20823 Don't handle -mcpu=power8 if -mpower9-vector is also used.
20824
20825 2018-06-06 Kelvin Nilsen <kelvin@gcc.gnu.org>
20826
20827 * config/rs6000/rs6000-builtin.def (VSX_BUILTIN_VEC_LD,
20828 VSX_BUILTIN_VEC_ST): Add comment to explain non-traditional uses.
20829 * config/rs6000/rs6000-c.c (altivec_overloaded_builtins): Remove
20830 several redundant entries.
20831
20832 2018-06-06 David Malcolm <dmalcolm@redhat.com>
20833
20834 * config/i386/i386-protos.h (ix86_expand_call): Strengthen return
20835 type from "rtx" to "rtx_insn *".
20836 * config/i386/i386.c (ix86_expand_split_stack_prologue): Likewise
20837 for local "call_insn", removing cast.
20838 (ix86_expand_call): Likewise, introducing a "call_insn" local.
20839
20840 2018-06-06 Eric Botcazou <ebotcazou@adacore.com>
20841
20842 PR tree-optimization/86066
20843 * gimple-ssa-store-merging.c (process_store): Do not bypass BIT_NOT_EXPR
20844 for BIT_INSERT_EXPR stores.
20845
20846 2018-06-06 Richard Biener <rguenther@suse.de>
20847
20848 PR tree-optimization/86062
20849 * tree-ssa-sccvn.c (vn_reference_lookup_3): Handle arbitrary
20850 component refs ontop
20851 of to be offsetted base.
20852
20853 2018-06-06 Jozef Lawrynowicz <jozef.l@mittosystems.com>
20854
20855 * config/msp430/msp430.c (msp430_attr): Allow interrupt handlers
20856 to be static and remove check on interrupt attribute name.
20857
20858 2018-06-05 Kelvin Nilsen <kelvin@gcc.gnu.org>
20859
20860 * doc/extend.texi (PowerPC AltiVec Built-in Functions): Remove
20861 volatile qualifier from vec_lvsl and vec_lvsr argument prototypes.
20862
20863 2018-06-05 Steve Ellcey <sellcey@cavium.com>
20864
20865 PR target/79924
20866 * config/aarch64/aarch64-protos.h (aarch64_err_no_fpadvsimd): Remove
20867 second argument.
20868 * config/aarch64/aarch64-protos..c (aarch64_err_no_fpadvsimd):
20869 Remove second argument, change how error is called.
20870 (aarch64_layout_arg): Remove second argument from
20871 aarch64_err_no_fpadvsimd call.
20872 (aarch64_init_cumulative_args): Ditto.
20873 (aarch64_gimplify_va_arg_expr): Ditto.
20874 * config/aarch64/aarch64.md (mov<mode>): Ditto.
20875
20876 2018-06-05 Uros Bizjak <ubizjak@gmail.com>
20877
20878 * config/i386/i386.md (simple_return_indirect_internal): New expander.
20879 (*simple_return_indirect_internal<mode>): Rename from
20880 simple_return_indirect_internal. Use W mode iterator.
20881 (rstorssp): New expander.
20882 (*rstorssp<mode>): Rename from rstorssp. Use P mode iterator.
20883 (clrssbsy): New expander.
20884 (*clrssbsy<mode>): Rename from clrssbsy. Use P mode iterator.
20885
20886 2018-06-05 Andre Vieira <andre.simoesdiasvieira@arm.com>
20887
20888 * config/arm/arm_cmse.h (cmse_nsfptr_create): Change typeof to
20889 __typeof__.
20890 (cmse_check_pointed_object): Likewise.
20891
20892 2018-06-05 Martin Liska <mliska@suse.cz>
20893
20894 PR gcov-profile/47618
20895 * doc/invoke.texi: Document how -fprofile-dir format
20896 is extended.
20897
20898 2018-06-05 Richard Biener <rguenther@suse.de>
20899
20900 * tree-cfgcleanup.c (cleanup_control_flow_pre): For edge
20901 removal pretend DOM info isn't available so we do not update
20902 it and only remove edges, not dominated blocks. Actually free
20903 DOM info in case we removed something. Remove unreachable blocks.
20904 (mfb_keep_latches): Work with either DOM info or marked backedges.
20905 (cleanup_tree_cfg_noloop): Do not remove unreachable blocks
20906 first. Mark backedges if DOM info isn't available.
20907 (Re-)compute DOM info after cleanup_control_flow_pre.
20908
20909 2018-06-05 Richard Biener <rguenther@suse.de>
20910
20911 * tree-cfg.c (struct locus_discrim_map): Store line, not location.
20912 (locus_discrim_hasher::hash): Adjust.
20913 (locus_discrim_hasher::equal): Likewise.
20914 (next_discriminator_for_locus): Work on line directly.
20915 (same_line_p): Pass in expanded locus1 as well.
20916 (assign_discriminators): Avoid redundant location expansions.
20917
20918 2018-06-05 Richard Biener <rguenther@suse.de>
20919
20920 PR tree-optimization/86046
20921 * tree-ssa.c (maybe_optimize_var): Clear DECL_GIMPLE_REG_P
20922 if required after clearing TREE_ADDRESSABLE.
20923
20924 2018-06-05 Richard Biener <rguenther@suse.de>
20925
20926 PR tree-optimization/86047
20927 * tree-ssa-loop.c (for_each_index): Glob handling of all
20928 decls and constants and really handle all of them.
20929
20930 2018-06-05 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
20931
20932 PR target/81497
20933 * config/arm/arm-builtins.c (arm_type_qualifiers): Add
20934 qualifier_void_pointer and qualifier_const_void_pointer.
20935 (arm_ldc_qualifiers, arm_stc_qualifiers): Use the above.
20936 (arm_init_builtins): Handle the above.
20937 * config/arm/arm_acle.h (__arm_cdp, __arm_ldc, __arm_ldcl, __arm_stc,
20938 __arm_stcl, __arm_mcr, __arm_cdp2, __arm_ldc2, __arm_ldcl2, __arm_stc2,
20939 __arm_stcl2,__arm_mcr2, __arm_mcrr, __arm_mcrr2): Remove return for
20940 void intrinsics.
20941
20942 2018-06-05 Martin Liska <mliska@suse.cz>
20943
20944 * auto-profile.c (read_autofdo_file): Do not use
20945 gcov_ctr_summary struct.
20946 (afdo_callsite_hot_enough_for_early_inline): Likewise.
20947 * coverage.c (struct counts_entry): Likewise.
20948 (read_counts_file): Read just single summary entry.
20949 (get_coverage_counts): Use gcov_summary struct.
20950 * coverage.h (get_coverage_counts): Likewise.
20951 * gcov-dump.c (dump_working_sets): Likewise.
20952 (tag_summary): Dump just single summary.
20953 * gcov-io.c (gcov_write_summary): Write just histogram
20954 summary.
20955 (gcov_read_summary): Read just single summary.
20956 (compute_working_sets): Use gcov_summary struct.
20957 * gcov-io.h (GCOV_TAG_SUMMARY_LENGTH): Remove usage
20958 of GCOV_COUNTERS_SUMMABLE.
20959 (GCOV_COUNTERS_SUMMABLE): Remove.
20960 (GCOV_FIRST_VALUE_COUNTER): Replace with
20961 GCOV_COUNTER_V_INTERVAL.
20962 (struct gcov_ctr_summary): Remove.
20963 (struct gcov_summary): Directly use fields of former
20964 gcov_ctr_summary.
20965 (compute_working_sets): Use gcov_summary struct.
20966 * gcov.c (read_count_file): Do not use ctrs fields.
20967 * lto-cgraph.c (merge_profile_summaries): Use gcov_summary
20968 struct.
20969 * lto-streamer.h (struct GTY): Make profile_info gcov_summary
20970 struct.
20971 * profile.c: Likewise.
20972 * profile.h: Likewise.
20973
20974 2018-06-05 Martin Liska <mliska@suse.cz>
20975
20976 PR gcov-profile/84846
20977 * gcov.c (output_lines): Print working directory only
20978 in intermediate format.
20979
20980 2018-06-05 Andreas Krebbel <krebbel@linux.ibm.com>
20981
20982 * config/s390/s390-builtin-types.def: Add void function type.
20983 * config/s390/s390-builtins.def: Use the function type for the
20984 tbeginc builtin.
20985
20986 2018-06-04 Jim Wilson <jimw@sifive.com>
20987
20988 * config/riscv/riscv-protos.h (riscv_expand_epilogue): Change bool arg
20989 to int.
20990 * config/riscv/riscv.c (riscv_for_each_saved_reg): New args epilogue
20991 and maybe_eh_return. Change regno to unsigned int. Use new args to
20992 handle EH_RETURN_DATA_REGNO registers properly.
20993 (riscv_expand_prologue): Pass new args to riscv_for_each_saved_reg.
20994 (riscv_expand_epilogue): Update comment. Change argument name and
20995 type. Update code to use new name and type. Pass new args to
20996 riscv_for_each_saved_reg. Only use EH_RETURN_STACKADJ_RTX when
20997 EXCEPTION_RETURN.
20998 * config/riscv/riscv.md (NORMAL_RETURN): New.
20999 (SIBCALL_RETURN, EXCEPTION_RETURN): New.
21000 (epilogue, sibcall_epilogue): Update riscv_expand_epilogue arg.
21001 (eh_return): Call gen_eh_return_internal and emit barrier.
21002 (eh_return_internal): Call riscv_expand_epilogue.
21003
21004 2018-06-04 Eric Botcazou <ebotcazou@adacore.com>
21005
21006 * gimple-ssa-store-merging.c (struct merged_store_group): Move up
21007 bit_insertion field and declare can_be_merged_into method.
21008 (merged_store_group::can_be_merged_into): New method.
21009 (imm_store_chain_info::coalesce_immediate): Call it to decide whether
21010 consecutive non-overlapping stores can be merged. Turn MEM_REF stores
21011 into BIT_INSERT_EXPR stores if the group contains a non-MEM_REF store.
21012
21013 2018-06-04 Richard Biener <rguenther@suse.de>
21014
21015 PR tree-optimization/85955
21016 * builtins.c (fold_builtin_sincos): Convert pointers to
21017 destination to appropriate type before dereferencing.
21018
21019 2018-06-04 Segher Boessenkool <segher@kernel.crashing.org>
21020
21021 * config/rs6000/rs6000.md (abs<mode>2 for FLOAT128): Handle IFmode.
21022
21023 2018-06-04 Richard Sandiford <richard.sandiford@linaro.org>
21024
21025 * expr.c (expand_expr_real_1): Force the operand into memory if
21026 its TYPE_MODE is BLKmode and if there is no integer mode for
21027 the number of bits being extracted.
21028
21029 2018-06-04 Jakub Jelinek <jakub@redhat.com>
21030
21031 PR target/85832
21032 PR target/86036
21033 * config/i386/sse.md (<avx512>_eq<mode>3<mask_scalar_merge_name>_1):
21034 Use vptestnm rather than vptestm in (=Yc,v,C) variant.
21035
21036 2018-06-04 Richard Biener <rguenther@suse.de>
21037
21038 * tree-cfgcleanup.c (cleanup_tree_cfg_1): Fold into...
21039 (cleanup_tree_cfg_noloop): ... single caller. Do
21040 start_recording_case_labels later.
21041
21042 2018-06-04 Sebastian Peryt <sebastian.peryt@intel.com>
21043
21044 * config/i386/cldemoteintrin.h: Change define from _X86INTRIN_H_INCLUDED
21045 to _IMMINTRIN_H_INCLUDED.
21046 * config/i386/pconfigintrin.h: Ditto.
21047 * config/i386/waitpkgintrin.h: Ditto.
21048 * config/i386/immintrin.h: Add includes for sgxintrin.h,
21049 pconfigintrin.h, waitpkgintrin.h and cldemoteintrin.h.
21050 * config/i386/x86intrin.h: Remove includes for mintrin.h, xmmintrin.h,
21051 emmintrin.h, pmmintrin.h, tmmintrin.h, smmintrin.h, wmmintrin.h,
21052 bmiintrin.h, bmi2intrin.h, lzcntintrin.h, sgxintrin.h, pconfigintrin.h,
21053 waitpkgintrin.h and cldemoteintrin.h.
21054
21055 2018-06-04 Richard Biener <rguenther@suse.de>
21056
21057 PR tree-optimization/86038
21058 * tracer.c (find_best_successor): Check probability for
21059 being initialized, bail out if not.
21060
21061 2018-06-04 Richard Earnshaw <rearnsha@arm.com>
21062
21063 PR target/86003
21064 * config/arm/arm-cpus.in (ALL_QUIRKS): Add xscale feature to the list
21065 of bits to ignore when comparing architectures.
21066
21067 2018-06-04 Jakub Jelinek <jakub@redhat.com>
21068
21069 PR tree-optimization/69615
21070 * fold-const.c (merge_ranges): If range1 is - [x, x] and x is the
21071 maximum or minimum of the type, try to merge it also as if
21072 range1 is + [-, x - 1] or + [x + 1, -].
21073
21074 PR c++/86025
21075 * tree.c (inchash::add_expr): Handle IDENTIFIER_NODE.
21076
21077 2018-06-03 Eric Botcazou <ebotcazou@adacore.com>
21078
21079 PR tree-optimization/86034
21080 * gimple-ssa-store-merging.c (output_merged_store): Convert the RHS to
21081 the unsigned bitfield type in a bit insertion sequence if it does not
21082 have a larger precision than the bitfield size.
21083 (process_store): Also bypass widening conversions for BIT_INSERT_EXPR.
21084
21085 2018-06-03 Kito Cheng <kito.cheng@gmail.com>
21086
21087 * config/nds32/nds32-peephole2.md: Add new patterns for code size.
21088
21089 2018-06-03 Chung-Ju Wu <jasonwucj@gmail.com>
21090
21091 * config/nds32/nds32-opts.h (nds32_arch_type): Add ARCH_V3J.
21092 * config/nds32/nds32.c (nds32_option_override): Consider ARCH_V3J.
21093 * config/nds32/nds32.h (TARGET_ISA_V3): Add ARCH_V3J checking.
21094 * config/nds32/nds32.opt (march): Add enum value Value(ARCH_V3J).
21095
21096 2018-06-03 Chung-Ju Wu <jasonwucj@gmail.com>
21097
21098 * common/config/nds32/nds32-common.c (nds32_option_optimization_table):
21099 Disable -fdelete-null-pointer-checks for ELF toolchain.
21100
21101 2018-06-02 Chung-Ju Wu <jasonwucj@gmail.com>
21102 Kito Cheng <kito.cheng@gmail.com>
21103
21104 * config.gcc (nds32*): Use nds32-linux.opt and nds32-elf.opt.
21105 (nds32le-*-*, nds32be-*-*): Integrate checking process.
21106 (nds32*-*-*): Add glibc and uclibc conditions.
21107 * common/config/nds32/nds32-common.c (nds32_except_unwind_info): New.
21108 (TARGET_EXCEPT_UNWIND_INFO): Define.
21109 * config/nds32/elf.h: New file.
21110 * config/nds32/linux.h: New file.
21111 * config/nds32/nds32-elf.opt: New file.
21112 * config/nds32/nds32-linux.opt: New file.
21113 * config/nds32/nds32-fp-as-gp.c
21114 (pass_nds32_fp_as_gp::gate): Consider TARGET_LINUX_ABI.
21115 * config/nds32/nds32.c (nds32_conditional_register_usage): Consider
21116 TARGET_LINUX_ABI.
21117 (nds32_asm_file_end): Ditto.
21118 (nds32_print_operand): Ditto.
21119 (nds32_insert_attributes): Ditto.
21120 (nds32_init_libfuncs): New function.
21121 (TARGET_HAVE_TLS): Define.
21122 (TARGET_INIT_LIBFUNCS): Define.
21123 * config/nds32/nds32.h (TARGET_DEFAULT_RELAX): Apply different relax
21124 spec content.
21125 (TARGET_ELF): Apply different mcmodel setting.
21126 (LINK_SPEC, LIB_SPEC, STARTFILE_SPEC, ENDFILE_SPEC): The content has
21127 been migrated into elf.h and linux.h files.
21128 * config/nds32/nds32.md (add_pc): Consider TARGET_LINUX_ABI.
21129 * config/nds32/nds32.opt (mvh): Consider TARGET_LINUX_ABI.
21130 (mcmodel): The content has been migrated into nds32-elf.opt and
21131 nds32-linux.opt files.
21132 * config/nds32/t-elf: New file.
21133 * config/nds32/t-linux: New file.
21134
21135 2018-06-02 Chung-Ju Wu <jasonwucj@gmail.com>
21136 Shiva Chen <shiva0217@gmail.com>
21137
21138 * config/nds32/constants.md (unspec_volatile_element): Add
21139 UNSPEC_VOLATILE_OMIT_FP_BEGIN and UNSPEC_VOLATILE_OMIT_FP_END.
21140 * config/nds32/nds32-fp-as-gp.c: New implementation of fp_as_gp
21141 optimization.
21142 * config/nds32/nds32-protos.h (nds32_naked_function_p): Declare.
21143 (make_pass_nds32_fp_as_gp): Declare.
21144 * config/nds32/nds32.c (nds32_register_passes): Add fp_as_gp as one
21145 optmization pass.
21146 (nds32_asm_function_end_prologue): Remove unused asm output.
21147 (nds32_asm_function_begin_epilogue): Remove unused asm output.
21148 (nds32_asm_file_start): Output necessary fp_as_gp information.
21149 (nds32_option_override): Adjust register usage.
21150 (nds32_expand_prologue): Consider fp_as_gp situation.
21151 (nds32_expand_prologue_v3push): Consider fp_as_gp situation.
21152 * config/nds32/nds32.md (prologue): Check fp_as_gp_p and naked_p.
21153 (epilogue): Ditto.
21154 (return): Ditto.
21155 (simple_return): Ditto.
21156 (omit_fp_begin): Output special directive for fp_as_gp.
21157 (omit_fp_end): Output special directive for fp_as_gp.
21158 * config/nds32/nds32.opt (mfp-as-gp, mno-fp-as-gp, mforce-fp-as-gp,
21159 mforbid-fp-as-gp): New options.
21160
21161 2018-06-01 Mark Wielaard <mark@klomp.org>
21162
21163 * dwarf2out.c (dwarf2out_finish): Remove generation of
21164 DW_AT_loclists_base.
21165
21166 2018-06-01 Eric Botcazou <ebotcazou@adacore.com>
21167
21168 * gimple-ssa-store-merging.c: Include gimple-fold.h.
21169 (struct store_immediate_info): Document BIT_INSERT_EXPR stores.
21170 (struct merged_store_group): Add bit_insertion field.
21171 (dump_char_array): Use standard hexadecimal format.
21172 (merged_store_group::merged_store_group): Set bit_insertion to false.
21173 (merged_store_group::apply_stores): Use optimal buffer size. Deal
21174 with BIT_INSERT_EXPR stores. Move up code updating the mask and
21175 also print the mask in the dump file.
21176 (pass_store_merging::gate): Minor tweak.
21177 (imm_store_chain_info::coalesce_immediate): Fix wrong association
21178 of stores with groups in dump. Allow coalescing of BIT_INSERT_EXPR
21179 stores with INTEGER_CST stores.
21180 (count_multiple_uses) <BIT_INSERT_EXPR>: New case.
21181 (imm_store_chain_info::output_merged_store): Add try_bitpos variable
21182 and use it throughout. Generate bit insertion sequences if need be.
21183 (pass_store_merging::process_store): Remove redundant condition.
21184 Record stores from a SSA name to a bit-field with BIT_INSERT_EXPR.
21185
21186 2018-06-01 Segher Boessenkool <segher@kernel.crashing.org>
21187
21188 * config/rs6000/rs6000.c (rs6000_mangle_type): Change the mangling of
21189 the 128-bit floating point types. Fix function comment.
21190
21191 2018-06-01 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
21192
21193 * config/aarch64/aarch64-simd.md
21194 (aarch64_simd_vec_unpack<su>_lo_<mode>): Use UXTL and SXTL assembler
21195 mnemonics.
21196 (aarch64_simd_vec_unpack<su>_hi_<mode>): Use UXTL2 and SXTL2 assembler
21197 mnemonics.
21198
21199 2018-06-01 Richard Sandiford <richard.sandiford@linaro.org>
21200
21201 PR tree-optimization/85989
21202 * gimple-ssa-backprop.c (backprop::m_visited_phis): New member
21203 variable.
21204 (backprop::intersect_uses): Check it when deciding whether this
21205 is a backedge reference.
21206 (backprop::process_block): Add each phi to m_visited_phis
21207 after visiting it, then clear it at the end.
21208
21209 2018-06-01 Richard Biener <rguenther@suse.de>
21210
21211 * tree-vectorizer.h (vect_dr_stmt): New function.
21212 (vect_get_load_cost): Adjust.
21213 (vect_get_store_cost): Likewise.
21214 * tree-vect-data-refs.c (vect_analyze_data_ref_dependence):
21215 Use vect_dr_stmt instead of DR_SMTT.
21216 (vect_record_base_alignments): Likewise.
21217 (vect_calculate_target_alignment): Likewise.
21218 (vect_compute_data_ref_alignment): Likewise and make static.
21219 (vect_update_misalignment_for_peel): Likewise.
21220 (vect_verify_datarefs_alignment): Likewise.
21221 (vector_alignment_reachable_p): Likewise.
21222 (vect_get_data_access_cost): Likewise. Pass down
21223 vinfo to vect_get_load_cost/vect_get_store_cost instead of DR.
21224 (vect_get_peeling_costs_all_drs): Likewise.
21225 (vect_peeling_hash_get_lowest_cost): Likewise.
21226 (vect_enhance_data_refs_alignment): Likewise.
21227 (vect_find_same_alignment_drs): Likewise.
21228 (vect_analyze_data_refs_alignment): Likewise.
21229 (vect_analyze_group_access_1): Likewise.
21230 (vect_analyze_group_access): Likewise.
21231 (vect_analyze_data_ref_access): Likewise.
21232 (vect_analyze_data_ref_accesses): Likewise.
21233 (vect_vfa_segment_size): Likewise.
21234 (vect_small_gap_p): Likewise.
21235 (vectorizable_with_step_bound_p): Likewise.
21236 (vect_prune_runtime_alias_test_list): Likewise.
21237 (vect_analyze_data_refs): Likewise.
21238 (vect_supportable_dr_alignment): Likewise.
21239 * tree-vect-loop-manip.c (get_misalign_in_elems): Likewise.
21240 (vect_gen_prolog_loop_niters): Likewise.
21241 * tree-vect-loop.c (vect_analyze_loop_2): Likewise.
21242 * tree-vect-patterns.c (vect_recog_bool_pattern): Do not
21243 modify DR_STMT.
21244 (vect_recog_mask_conversion_pattern): Likewise.
21245 (vect_try_gather_scatter_pattern): Likewise.
21246 * tree-vect-stmts.c (vect_model_store_cost): Pass stmt_info
21247 to vect_get_store_cost.
21248 (vect_get_store_cost): Get stmt_info instead of DR.
21249 (vect_model_load_cost): Pass stmt_info to vect_get_load_cost.
21250 (vect_get_load_cost): Get stmt_info instead of DR.
21251
21252 2018-06-01 Richard Biener <rguenther@suse.de>
21253
21254 PR middle-end/86017
21255 * gimple-fold.c (var_decl_component_p): Also allow offsetted
21256 vars wrapped in MEM_REFs.
21257
21258 2018-06-01 Richard Sandiford <richard.sandiford@linaro.org>
21259
21260 * config/aarch64/aarch64.c (aarch64_ira_change_pseudo_allocno_class):
21261 Fix subreg tests so that we only return a choice between
21262 GENERAL_REGS and FP_REGS if the original classes included both.
21263
21264 2018-06-01 Richard Biener <rguenther@suse.de>
21265
21266 PR ipa/85960
21267 * tree-ssa-structalias.c (get_function_part_constraint):
21268 Handle NULL fi->decl.
21269 (find_func_aliases_for_call): Properly handle indirect
21270 fi from direct call.
21271 (find_func_clobbers): Likewise.
21272 (ipa_pta_execute): Likewise.
21273 (create_variable_info_for): For functions that are ifunc_resolver
21274 resolve to a varinfo that contains the result of the resolver call.
21275 (associate_varinfo_to_alias): Do not treat ifunc resolvers as
21276 aliases.
21277
21278 2018-05-31 Michael Collison <michael.collison@arm.com>
21279
21280 * config/aarch64/aarch64.md:
21281 (*fix_to_zero_extenddfdi2): New pattern.
21282 * gcc.target/aarch64/fix_extend1.c: New testcase.
21283
21284 2018-05-31 Qing Zhao <qing.zhao@oracle.com>
21285
21286 PR middle-end/78809
21287 PR middle-end/83026
21288 * builtins.c (expand_builtin): Add the handling of BUILT_IN_STRCMP_EQ
21289 and BUILT_IN_STRNCMP_EQ.
21290 * builtins.def: Add new builtins BUILT_IN_STRCMP_EQ and
21291 BUILT_IN_STRNCMP_EQ.
21292 * gimple-fold.c (gimple_fold_builtin_string_compare): Add the
21293 handling of BUILTIN_IN_STRCMP_EQ and BUILT_IN_STRNCMP_EQ.
21294 (gimple_fold_builtin): Likewise.
21295 * tree-ssa-strlen.c (compute_string_length): New function.
21296 (determine_min_obsize): New function.
21297 (handle_builtin_string_cmp): New function to handle calls to
21298 string compare functions.
21299 (strlen_optimize_stmt): Add handling to builtin string compare
21300 calls.
21301 * tree-ssa-structalias.c (find_func_aliases_for_builtin_call):
21302 Add the handling of BUILT_IN_STRCMP_EQ and BUILT_IN_STRNCMP_EQ.
21303 * tree.c (build_common_builtin_nodes): Add new defines of
21304 BUILT_IN_STRNCMP_EQ and BUILT_IN_STRCMP_EQ.
21305
21306 2018-05-31 Jakub Jelinek <jakub@redhat.com>
21307
21308 PR target/85984
21309 * bb-reorder.c (pass_partition_blocks::gate): Return false for
21310 functions with naked attribute.
21311
21312 2018-05-31 Uros Bizjak <ubizjak@gmail.com>
21313
21314 * config/i386/sse.md (avx_vec_concat<mode>):
21315 Substitute concat_tg_mode mode attribute with xtg_mode.
21316 (<mask_codefor>avx512dq_broadcast<mode><mask_name>_1): Ditto.
21317 (concat_tg_mode): Remove mode attribute.
21318
21319 2018-05-31 Martin Sebor <msebor@redhat.com>
21320
21321 PR c/82063
21322 * calls.c (alloc_max_size): Correct a logic error/typo.
21323 Treat excessive arguments as infinite. Warn for invalid arguments.
21324 * doc/invoke.texi (-Walloc-size-larger-than): Update.
21325
21326 2018-05-31 H.J. Lu <hongjiu.lu@intel.com>
21327
21328 PR target/85829
21329 * config/i386/x86-tune.def: Re-enable partial_reg_dependency
21330 and movx for Haswell.
21331
21332 2018-05-31 Chung-Lin Tang <cltang@codesourcery.com>
21333 Cesar Philippidis <cesar@codesourcery.com>
21334
21335 PR middle-end/85879
21336 * gimplify.c (gimplify_adjust_omp_clauses): Add 'remove = true'
21337 when emitting error on private/firstprivate reductions.
21338 * omp-low.c (lower_omp_target): Avoid reference-type processing
21339 on pointers for firstprivate clause.
21340
21341 2018-05-31 Sameera Deshpande <sameera.deshpande@linaro.org>
21342
21343 * config/aarch64/aarch64-simd-builtins.def (ld1x3): New.
21344 (st1x2): Likewise.
21345 (st1x3): Likewise.
21346 * config/aarch64/aarch64-simd.md
21347 (aarch64_ld1x3<VALLDIF:mode>): New pattern.
21348 (aarch64_ld1_x3_<mode>): Likewise
21349 (aarch64_st1x2<VALLDIF:mode>): Likewise
21350 (aarch64_st1_x2_<mode>): Likewise
21351 (aarch64_st1x3<VALLDIF:mode>): Likewise
21352 (aarch64_st1_x3_<mode>): Likewise
21353 * config/aarch64/arm_neon.h (vld1_u8_x3): New function.
21354 (vld1_s8_x3): Likewise.
21355 (vld1_u16_x3): Likewise.
21356 (vld1_s16_x3): Likewise.
21357 (vld1_u32_x3): Likewise.
21358 (vld1_s32_x3): Likewise.
21359 (vld1_u64_x3): Likewise.
21360 (vld1_s64_x3): Likewise.
21361 (vld1_f16_x3): Likewise.
21362 (vld1_f32_x3): Likewise.
21363 (vld1_f64_x3): Likewise.
21364 (vld1_p8_x3): Likewise.
21365 (vld1_p16_x3): Likewise.
21366 (vld1_p64_x3): Likewise.
21367 (vld1q_u8_x3): Likewise.
21368 (vld1q_s8_x3): Likewise.
21369 (vld1q_u16_x3): Likewise.
21370 (vld1q_s16_x3): Likewise.
21371 (vld1q_u32_x3): Likewise.
21372 (vld1q_s32_x3): Likewise.
21373 (vld1q_u64_x3): Likewise.
21374 (vld1q_s64_x3): Likewise.
21375 (vld1q_f16_x3): Likewise.
21376 (vld1q_f32_x3): Likewise.
21377 (vld1q_f64_x3): Likewise.
21378 (vld1q_p8_x3): Likewise.
21379 (vld1q_p16_x3): Likewise.
21380 (vld1q_p64_x3): Likewise.
21381 (vst1_s64_x2): Likewise.
21382 (vst1_u64_x2): Likewise.
21383 (vst1_f64_x2): Likewise.
21384 (vst1_s8_x2): Likewise.
21385 (vst1_p8_x2): Likewise.
21386 (vst1_s16_x2): Likewise.
21387 (vst1_p16_x2): Likewise.
21388 (vst1_s32_x2): Likewise.
21389 (vst1_u8_x2): Likewise.
21390 (vst1_u16_x2): Likewise.
21391 (vst1_u32_x2): Likewise.
21392 (vst1_f16_x2): Likewise.
21393 (vst1_f32_x2): Likewise.
21394 (vst1_p64_x2): Likewise.
21395 (vst1q_s8_x2): Likewise.
21396 (vst1q_p8_x2): Likewise.
21397 (vst1q_s16_x2): Likewise.
21398 (vst1q_p16_x2): Likewise.
21399 (vst1q_s32_x2): Likewise.
21400 (vst1q_s64_x2): Likewise.
21401 (vst1q_u8_x2): Likewise.
21402 (vst1q_u16_x2): Likewise.
21403 (vst1q_u32_x2): Likewise.
21404 (vst1q_u64_x2): Likewise.
21405 (vst1q_f16_x2): Likewise.
21406 (vst1q_f32_x2): Likewise.
21407 (vst1q_f64_x2): Likewise.
21408 (vst1q_p64_x2): Likewise.
21409 (vst1_s64_x3): Likewise.
21410 (vst1_u64_x3): Likewise.
21411 (vst1_f64_x3): Likewise.
21412 (vst1_s8_x3): Likewise.
21413 (vst1_p8_x3): Likewise.
21414 (vst1_s16_x3): Likewise.
21415 (vst1_p16_x3): Likewise.
21416 (vst1_s32_x3): Likewise.
21417 (vst1_u8_x3): Likewise.
21418 (vst1_u16_x3): Likewise.
21419 (vst1_u32_x3): Likewise.
21420 (vst1_f16_x3): Likewise.
21421 (vst1_f32_x3): Likewise.
21422 (vst1_p64_x3): Likewise.
21423 (vst1q_s8_x3): Likewise.
21424 (vst1q_p8_x3): Likewise.
21425 (vst1q_s16_x3): Likewise.
21426 (vst1q_p16_x3): Likewise.
21427 (vst1q_s32_x3): Likewise.
21428 (vst1q_s64_x3): Likewise.
21429 (vst1q_u8_x3): Likewise.
21430 (vst1q_u16_x3): Likewise.
21431 (vst1q_u32_x3): Likewise.
21432 (vst1q_u64_x3): Likewise.
21433 (vst1q_f16_x3): Likewise.
21434 (vst1q_f32_x3): Likewise.
21435 (vst1q_f64_x3): Likewise.
21436 (vst1q_p64_x3): Likewise.
21437
21438 2018-05-30 Jozef Lawrynowicz <jozef.l@mittosystems.com>
21439
21440 * config/msp430/msp430.c (msp430_output_labelref): Prepend
21441 user_label_prefix to name.
21442
21443 * tree-core.h: Update comment about the format of NAME string
21444 passed to handler in attribute_spec.
21445
21446 * config/msp430/msp430.md: Remove erroneous subreg expression from
21447 zero_extendqisi2 insn pattern. Remove msp430x ISA restriction on
21448 zero_extend{q,h}isi2.
21449
21450 2018-05-30 Borislav Petkov <bp@suse.de>
21451
21452 * doc/extend.texi: Document some architecture specific
21453 constraints and sort entries.
21454
21455 2018-05-30 Martin Sebor <msebor@redhat.com>
21456
21457 PR middle-end/85369
21458 * builtins.c (expand_builtin_stpcpy_1): New function.
21459 (expand_builtin_stpcpy): Call it, and call maybe_warn_nonstring_arg
21460 only if the former succeeds.
21461
21462 2018-05-31 Sameera Deshpande <sameera.deshpande@linaro.org>
21463
21464 * config/aarch64/aarch64-cores.def (saphira) : Add support for ARMv8.4
21465 in saphira.
21466
21467 2018-05-30 Jan Hubicka <hubicka@ucw.cz>
21468
21469 * doc/invoke.texi (-flinker-output): Document
21470
21471 2018-05-30 Jan Hubicka <hubicka@ucw.cz>
21472
21473 * passes.c (ipa_write_summaries): Only modify statements if body
21474 is in memory.
21475 * cgraphunit.c (ipa_passes): Also produce intermeidate code when
21476 incrementally linking.
21477 (ipa_passes): Likewise.
21478 * lto-cgraph.c (lto_output_node): When incrementally linking do not
21479 pass down resolution info.
21480 * common.opt (flag_incremental_link): Update info.
21481 * gcc.c (plugin specs): Turn flinker-output=* to
21482 -plugin-opt=-linker-output-known
21483 * toplev.c (compile_file): Also cut compilation when doing incremental
21484 link.
21485 * flag-types. (enum lto_partition_model): Add
21486 LTO_LINKER_OUTPUT_NOLTOREL.
21487 (invoke.texi): Add -flinker-output docs.
21488 * ipa.c (symbol_table::remove_unreachable_nodes): Handle LTO incremental
21489 link same way as WPA; do not stream in dead initializers.
21490
21491 * dwarf2out.c (dwarf2out_die_ref_for_decl,
21492 darf2out_register_external_decl): Support incremental link.
21493
21494 2018-05-30 Jan Hubicka <hubicka@ucw.cz>
21495
21496 * lto-opts.c (lto_write_options): Skip OPT_dumpdir, OPT_fresolution_.
21497
21498 2018-05-30 Jan Hubicka <hubicka@ucw.cz>
21499
21500 * lto-wrapper.c (debug_objcopy): Add rename parameter; pass
21501 it down to simple_object_copy_lto_debug_sections.
21502 (run_gcc): Determine incremental LTO link time and configure
21503 lto1 into non-wpa mode, disable renaming of debug sections.
21504
21505 2018-05-30 Kelvin Nilsen <kelvin@gcc.gnu.org>
21506
21507 * doc/extend.texi (PowerPC AltiVec Built-in Functions): Remove
21508 descriptions of various incorrectly documented functions.
21509
21510 2018-05-30 Andre Vieira <andre.simoesdiasvieira@arm.com>
21511
21512 Revert:
21513 * config/aarch64/predicates.md (aarch64_mem_pair_lanes_operand): Make
21514 address check not strict.
21515
21516 2018-05-30 Richard Biener <rguenther@suse.de>
21517
21518 PR tree-optimization/85964
21519 * tracer.c (better_p): Drop initialized count check, we only
21520 call the function with initialized counts now.
21521 (find_best_successor): Do find a best edge if one
21522 has uninitialized count.
21523 (find_best_predecessor): Likewise. Do BB frequency check only
21524 if count is initialized.
21525
21526 2017-05-30 Jackson Woodruff <jackson.woodruff@arm.com>
21527
21528 * config/aarch64/aarch64.c (aarch64_host_wide_int_compare): New.
21529 (aarch64_ldrstr_offset_compare): New.
21530 (aarch64_operands_adjust_ok_for_ldpstp): Update to consider all
21531 load/store orderings.
21532 (aarch64_gen_adjusted_ldpstp): Likewise.
21533
21534 2018-05-30 Wilco Dijkstra <wdijkstr@arm.com>
21535
21536 * config/aarch64/aarch64.c (aarch64_ira_change_pseudo_allocno_class):
21537 Check for subset of GENERAL_REGS and FP_REGS.
21538 * config/aarch64/aarch64-simd.md (aarch64_get_lane): Increase cost of
21539 r=w alternative.
21540
21541 2018-05-30 Richard Sandiford <richard.sandiford@linaro.org>
21542
21543 * alias.c (adjust_offset_for_component_ref): Use poly_int_tree_p
21544 and wi::to_poly_offset. Add the current offset and then check
21545 whether the sum fits, rather than using an unchecked addition of
21546 a checked term. Check for a shwi rather than a uhwi.
21547 * expr.c (get_bit_range): Use tree_to_poly_uint64.
21548 (store_constructor): Use poly_int_tree_p.
21549 (expand_expr_real_1): Likewise.
21550 * function.c (assign_temp): Likewise.
21551 * fold-const.c (const_binop): Use poly_int_tree_p and
21552 wi::to_poly_offset.
21553 (fold_indirect_ref_1): Likewise. Use multiple_p to attempt an exact
21554 division.
21555 * ipa-icf-gimple.c (func_checker::compare_operand): Use
21556 to_poly_offset for MEM offsets.
21557 * ipa-icf.c (sem_variable::equals): Likewise.
21558 * stor-layout.c (compute_record_mode): Use poly_int_tree_p.
21559 * tree-ssa-sccvn.c (ao_ref_init_from_vn_reference): Use
21560 wi::to_poly_offset for BIT_FIELD_REF offsets.
21561 (vn_reference_maybe_forwprop_address): Use poly_int_tree_p and
21562 wi::to_poly_offset.
21563 * var-tracking.c (emit_note_insn_var_location): Use
21564 tree_to_poly_uint64.
21565
21566 2018-05-29 Jim Wilson <jimw@sifive.com>
21567
21568 * config/riscv/riscv.c (riscv_interrupt_type): Fix comment typo.
21569
21570 2018-05-29 Uros Bizjak <ubizjak@gmail.com>
21571
21572 PR target/85950
21573 * config/i386/i386.md (l<rounding_insn><MODEF:mode><SWI48:mode>2):
21574 Enable for TARGET_SSE4_1 and generate rounds{s,d} and cvtts{s,d}2si{,q}
21575 sequence.
21576 (sse4_1_round<mode>2): Use nonimmediate_operand
21577 for operand 1 predicate.
21578
21579 2018-05-29 Martin Sebor <msebor@redhat.com>
21580 Richard Biener <rguenther@suse.de>
21581
21582 PR testsuite/85888
21583 * calls.c (get_size_range): Call determine_value_range instead
21584 of get_value_range..
21585 * tree-vrp.h (determine_value_range): Declared new function.
21586 * tree-vrp.c (determine_value_range_1, determine_value_range): New.
21587
21588 2018-05-29 Richard Biener <rguenther@suse.de>
21589
21590 * tree-vect-data-refs.c (vect_preserves_scalar_order_p): Make
21591 sure to use non-pattern stmts for get_earlier_stmt arguments.
21592 * tree-vectorizer.h (get_earlier_stmt): Assert we do not get
21593 called on pattern stmts.
21594 (get_later_stmt): Likewise.
21595
21596 2018-05-29 Martin Liska <mliska@suse.cz>
21597
21598 PR gcov-profile/85759
21599 * doc/gcov.texi: Document GCOV_ERROR_FILE and GCOV_EXIT_AT_ERROR
21600 env variables.
21601
21602 2018-05-29 Jakub Jelinek <jakub@redhat.com>
21603
21604 * tree-cfg.c (verify_gimple_assign_unary): Add checking for
21605 VEC_UNPACK_*_EXPR.
21606 (verify_gimple_assign_binary): Check TYPE_VECTOR_SUBPARTS for
21607 VEC_PACK_*_EXPR.
21608
21609 PR target/85918
21610 * tree.def (VEC_UNPACK_FIX_TRUNC_HI_EXPR, VEC_UNPACK_FIX_TRUNC_LO_EXPR,
21611 VEC_PACK_FLOAT_EXPR): New tree codes.
21612 * tree-pretty-print.c (op_code_prio): Handle
21613 VEC_UNPACK_FIX_TRUNC_HI_EXPR and VEC_UNPACK_FIX_TRUNC_LO_EXPR.
21614 (dump_generic_node): Handle VEC_UNPACK_FIX_TRUNC_HI_EXPR,
21615 VEC_UNPACK_FIX_TRUNC_LO_EXPR and VEC_PACK_FLOAT_EXPR.
21616 * tree-inline.c (estimate_operator_cost): Likewise.
21617 * gimple-pretty-print.c (dump_binary_rhs): Handle VEC_PACK_FLOAT_EXPR.
21618 * fold-const.c (const_binop): Likewise.
21619 (const_unop): Handle VEC_UNPACK_FIX_TRUNC_HI_EXPR and
21620 VEC_UNPACK_FIX_TRUNC_LO_EXPR.
21621 * tree-cfg.c (verify_gimple_assign_unary): Likewise.
21622 (verify_gimple_assign_binary): Handle VEC_PACK_FLOAT_EXPR.
21623 * cfgexpand.c (expand_debug_expr): Handle VEC_UNPACK_FIX_TRUNC_HI_EXPR,
21624 VEC_UNPACK_FIX_TRUNC_LO_EXPR and VEC_PACK_FLOAT_EXPR.
21625 * expr.c (expand_expr_real_2): Likewise.
21626 * optabs.def (vec_packs_float_optab, vec_packu_float_optab,
21627 vec_unpack_sfix_trunc_hi_optab, vec_unpack_sfix_trunc_lo_optab,
21628 vec_unpack_ufix_trunc_hi_optab, vec_unpack_ufix_trunc_lo_optab): New
21629 optabs.
21630 * optabs.c (expand_widen_pattern_expr): For
21631 VEC_UNPACK_FIX_TRUNC_HI_EXPR and VEC_UNPACK_FIX_TRUNC_LO_EXPR use
21632 sign from result type rather than operand's type.
21633 (expand_binop_directly): For vec_packu_float_optab and
21634 vec_packs_float_optab allow result type to be different from operand's
21635 type.
21636 * optabs-tree.c (optab_for_tree_code): Handle
21637 VEC_UNPACK_FIX_TRUNC_HI_EXPR, VEC_UNPACK_FIX_TRUNC_LO_EXPR and
21638 VEC_PACK_FLOAT_EXPR. Formatting fixes.
21639 * tree-vect-generic.c (expand_vector_operations_1): Handle
21640 VEC_UNPACK_FIX_TRUNC_HI_EXPR, VEC_UNPACK_FIX_TRUNC_LO_EXPR and
21641 VEC_PACK_FLOAT_EXPR.
21642 * tree-vect-stmts.c (supportable_widening_operation): Handle
21643 FIX_TRUNC_EXPR.
21644 (supportable_narrowing_operation): Handle FLOAT_EXPR.
21645 * config/i386/i386.md (fixprefix, floatprefix): New code attributes.
21646 * config/i386/sse.md (*float<floatunssuffix>v2div2sf2): Rename to ...
21647 (float<floatunssuffix>v2div2sf2): ... this. Formatting fix.
21648 (vpckfloat_concat_mode, vpckfloat_temp_mode, vpckfloat_op_mode): New
21649 mode attributes.
21650 (vec_pack<floatprefix>_float_<mode>): New expander.
21651 (vunpckfixt_mode, vunpckfixt_model, vunpckfixt_extract_mode): New mode
21652 attributes.
21653 (vec_unpack_<fixprefix>fix_trunc_lo_<mode>,
21654 vec_unpack_<fixprefix>fix_trunc_hi_<mode>): New expanders.
21655 * doc/md.texi (vec_packs_float_@var{m}, vec_packu_float_@var{m},
21656 vec_unpack_sfix_trunc_hi_@var{m}, vec_unpack_sfix_trunc_lo_@var{m},
21657 vec_unpack_ufix_trunc_hi_@var{m}, vec_unpack_ufix_trunc_lo_@var{m}):
21658 Document.
21659 * doc/generic.texi (VEC_UNPACK_FLOAT_HI_EXPR,
21660 VEC_UNPACK_FLOAT_LO_EXPR): Fix pasto in description.
21661 (VEC_UNPACK_FIX_TRUNC_HI_EXPR, VEC_UNPACK_FIX_TRUNC_LO_EXPR,
21662 VEC_PACK_FLOAT_EXPR): Document.
21663
21664 2018-05-29 Richard Biener <rguenther@suse.de>
21665
21666 * tree-vectorizer.h (struct vec_info): Add stmt_vec_infos
21667 member.
21668 (stmt_vec_info_vec): Make pointer.
21669 (init_stmt_vec_info_vec): Remove.
21670 (free_stmt_vec_info_vec): Likewise.
21671 (set_stmt_vec_info_vec): New function.
21672 (free_stmt_vec_infos): Likewise.
21673 (vinfo_for_stmt): Adjust for stmt_vec_info_vec indirection.
21674 (set_vinfo_for_stmt): Likewise.
21675 (get_earlier_stmt): Likewise.
21676 (get_later_stmt): Likewise.
21677 * tree-vectorizer.c (stmt_vec_info_vec): Make pointer.
21678 (vec_info::vec_info): Allocate stmt_vec_infos and set the global.
21679 (vec_info::~vec_info): Free stmt_vec_infos.
21680 (vectorize_loops): Set the global stmt_vec_info_vec to NULL.
21681 Remove old init_stmt_vec_info_vec/free_stmt_vec_info_vec calls.
21682 (pass_slp_vectorize::execute): Likewise.
21683 * tree-vect-stmts.c (init_stmt_vec_info_vec): Remove.
21684 (free_stmt_vec_info_vec): Likewise.
21685 (set_stmt_vec_info_vec): New function.
21686 (free_stmt_vec_infos): Likewise.
21687 * tree-vect-loop.c (_loop_vec_info::~_loop_vec_info): Set
21688 the global stmt_vec_info_vec.
21689 * tree-parloops.c (gather_scalar_reductions): Use
21690 set_stmt_vec_info_vec/free_stmt_vec_infos and maintain a local
21691 vector.
21692
21693 2018-05-29 Richard Biener <rguenther@suse.de>
21694
21695 * dominance.c (iterate_fix_dominators): Push/pop TV_DOMINANCE.
21696
21697 2018-05-29 Martin Liska <mliska@suse.cz>
21698 David Malcolm <dmalcolm@redhat.com>
21699
21700 * vec.c (test_reverse): New.
21701 (vec_c_tests): Add new test.
21702 * vec.h (vl_ptr>::reverse): New function.
21703
21704 2018-05-29 Gerald Pfeifer <gerald@pfeifer.com>
21705
21706 * config.gcc: Identify FreeBSD 3.x and 4.x as unsupported.
21707
21708 * config/freebsd-spec.h (FBSD_LIB_SPEC): Only consider FreeBSD 5
21709 and later.
21710
21711 2018-05-28 Bernd Edlinger <bernd.edlinger@hotmail.de>
21712
21713 * tree-dump.c (dump_node): Use splay_tree_delete_pointers.
21714
21715 2018-05-28 Richard Biener <rguenther@suse.de>
21716
21717 PR tree-optimization/85933
21718 * tree-vect-data-refs.c (vect_record_base_alignments): Only
21719 look at stmts marked as vectorizable.
21720
21721 2018-05-28 Richard Biener <rguenther@suse.de>
21722
21723 PR tree-optimization/85934
21724 * tree-vect-generic.c (expand_vector_operations_1): Hoist
21725 vector boolean check before scalar optimization.
21726
21727 2018-05-28 Jakub Jelinek <jakub@redhat.com>
21728
21729 * doc/invoke.texi (ARM Options): Use @item instead of @itemx
21730 for armv5te.
21731
21732 2018-05-28 Mark Wielaard <mark@klomp.org>
21733
21734 * dwarf2asm.c (dw2_asm_output_delta_uleb128): Add brackets around lab2
21735 if it is an expression containing a minus sign.
21736
21737 2018-05-27 John David Anglin <danglin@gcc.gnu.org>
21738
21739 * config/pa/pa-linux.h (NEED_INDICATE_EXEC_STACK): Define to 0.
21740
21741 2018-05-27 Paul Koning <ni1d@arrl.net>
21742
21743 * config/pdp11/pdp11.md (truncsihi2): Remove.
21744
21745 2018-05-27 Monk Chiang <sh.chiang04@gmail.com>
21746 Chung-Ju Wu <jasonwucj@gmail.com>
21747
21748 * config/nds32/nds32-intrinsic.md (unaligned_storedi): Modify patterns
21749 implementation.
21750 (unaligned_store_dw): Ditto.
21751 * config/nds32/nds32-memory-manipulation.c
21752 (nds32_expand_movmemsi_loop_known_size): Refactoring implementation.
21753 (nds32_gen_dup_4_byte_to_word_value): Rename to ...
21754 (nds32_gen_dup_4_byte_to_word_value_aux): ... this.
21755 (emit_setmem_word_loop): Rename to ...
21756 (emit_setmem_doubleword_loop): ... this.
21757 (nds32_gen_dup_4_byte_to_word_value): New function.
21758 (nds32_gen_dup_8_byte_to_double_word_value): New function.
21759 (nds32_expand_setmem_loop): Refine implementation.
21760 (nds32_expand_setmem_loop_v3m): Ditto.
21761 * config/nds32/nds32-multiple.md (unaligned_store_update_base_dw): New
21762 pattern.
21763
21764 2018-05-27 Chung-Ju Wu <jasonwucj@gmail.com>
21765
21766 * config/nds32/nds32.md (bswapsi2, bswaphi2): New patterns.
21767
21768 2018-05-27 Chung-Ju Wu <jasonwucj@gmail.com>
21769
21770 * config/nds32/nds32.c (nds32_attribute_table): Add "no_prologue".
21771 (nds32_init_machine_status): Initialize machine->attr_naked_p and
21772 machine->attr_no_prologue_p.
21773 (nds32_compute_stack_frame): Check "naked" and "no_prologue" attributes.
21774 (nds32_naked_function_p): Handle "naked" and "no_prologue" attributes.
21775 (nds32_expand_epilogue): Consider attr_naked_p.
21776 (nds32_expand_epilogue_v3pop): Likewise.
21777 (nds32_can_use_return_insn): Likewise.
21778 * config/nds32/nds32.h (machine_function): Add attr_naked_p and
21779 attr_no_prologue_p fields.
21780 * config/nds32/nds32.opt (mret-in-naked-func): New option.
21781
21782 2018-05-27 Jakub Jelinek <jakub@redhat.com>
21783
21784 PR target/85918
21785 * config/i386/i386.md (fixunssuffix, floatunssuffix): New code
21786 attributes.
21787 * config/i386/sse.md
21788 (<floatsuffix>float<sseintvecmodelower><mode>2<mask_name><round_name>):
21789 Rename to ...
21790 (float<floatunssuffix><sseintvecmodelower><mode>2<mask_name><round_name>):
21791 ... this.
21792 (<floatsuffix>float<sselongvecmodelower><mode>2<mask_name><round_name>):
21793 Rename to ...
21794 (float<floatunssuffix><sselongvecmodelower><mode>2<mask_name><round_name>):
21795 ... this.
21796 (*<floatsuffix>floatv2div2sf2): Rename to ...
21797 (*float<floatunssuffix>v2div2sf2): ... this.
21798 (<floatsuffix>floatv2div2sf2_mask): Rename to ...
21799 (float<floatunssuffix>v2div2sf2_mask): ... this.
21800 (*<floatsuffix>floatv2div2sf2_mask_1): Rename to ...
21801 (*float<floatunssuffix>v2div2sf2_mask_1): ... this.
21802 (<fixsuffix>fix_truncv8dfv8si2<mask_name><round_saeonly_name>): Rename
21803 to ...
21804 (fix<fixunssuffix>_truncv8dfv8si2<mask_name><round_saeonly_name>):
21805 ... this.
21806 (<fixsuffix>fix_trunc<mode><sseintvecmodelower>2<mask_name><round_saeonly_name>):
21807 Rename to ...
21808 (fix<fixunssuffix>_trunc<mode><sseintvecmodelower>2<mask_name><round_saeonly_name>):
21809 ... this.
21810 (<fixsuffix>fix_trunc<mode><sselongvecmodelower>2<mask_name><round_saeonly_name>):
21811 Rename to ...
21812 (fix<fixunssuffix>_trunc<mode><sselongvecmodelower>2<mask_name><round_saeonly_name>):
21813 ... this.
21814 (<fixsuffix>fix_truncv2sfv2di2<mask_name>): Rename to ...
21815 (fix<fixunssuffix>_truncv2sfv2di2<mask_name>): ... this.
21816 (vec_pack_ufix_trunc_<mode>): Use gen_fixuns_truncv8dfv8si2 instead of
21817 gen_ufix_truncv8dfv8si2.
21818 * config/i386/i386-builtin.def (__builtin_ia32_cvttpd2uqq256_mask,
21819 __builtin_ia32_cvttpd2uqq128_mask, __builtin_ia32_cvttps2uqq256_mask,
21820 __builtin_ia32_cvttps2uqq128_mask, __builtin_ia32_cvtuqq2ps256_mask,
21821 __builtin_ia32_cvtuqq2ps128_mask, __builtin_ia32_cvtuqq2pd256_mask,
21822 __builtin_ia32_cvtuqq2pd128_mask, __builtin_ia32_cvttpd2udq512_mask,
21823 __builtin_ia32_cvtuqq2ps512_mask, __builtin_ia32_cvtuqq2pd512_mask,
21824 __builtin_ia32_cvttps2uqq512_mask, __builtin_ia32_cvttpd2uqq512_mask):
21825 Use fixuns instead ufix or floatuns instead ufloat in CODE_FOR_ names.
21826
21827 2018-05-24 H.J. Lu <hongjiu.lu@intel.com>
21828
21829 PR target/85900
21830 PR target/85345
21831 * varasm.c (assemble_alias): Lookup ifunc attribute on error.
21832
21833 2018-05-25 Jim Wilson <jimw@sifive.com>
21834
21835 * config/riscv/riscv-protos.h (riscv_epilogue_uses): New.
21836 * config/riscv/riscv.c (struct machine_function): Add
21837 interrupt_handler_p and attribute_checked_p fields.
21838 (riscv_attribute_table): Add interrupt.
21839 (riscv_interrupt_type_p): New.
21840 (riscv_save_reg_p): Save extra regs for interrupt handler.
21841 (riscv_use_save_libcall): Return false for interrupt handler.
21842 (riscv_first_stack_step): Add forward declaration.
21843 (riscv_compute_frame_info): New local interrupt_save_t1. Set it
21844 for interrupt handler with large frame. Use it for saved reg list.
21845 (riscv_expand_prologue): Move flag_stack_usage_info support to
21846 eliminate duplication.
21847 (riscv_expand_epilogue): Generate mret for interrupt handler.
21848 (riscv_epilogue_uses): New.
21849 (riscv_can_use_return_insn): Return false for interrupt handler.
21850 (riscv_function_ok_for_sibcall): Likewise.
21851 (riscv_set_current_function): Add interrupt handler support.
21852 * config/riscv/riscv.h (EPILOGUE_USES): Call riscv_epilogue_uses.
21853 * config/riscv/riscv.md (UNSPECV_MRET): New.
21854 (GP_REGNUM): New.
21855 (riscv_frflags, riscv_fsflags): Use tab after opcode.
21856 (riscv_mret): New.
21857 * doc/extend.texi (RISC-V Function Attributes) <interrupt>: New.
21858
21859 2018-05-25 Bill Schmidt <wschmidt@linux.ibm.com>
21860
21861 PR tree-optimization/85712
21862 * gimple-ssa-strength-reduction.c (replace_one_candidate): Skip if
21863 this candidate has already been replaced in-situ by a copy.
21864
21865 2018-05-25 Jason Merrill <jason@redhat.com>
21866
21867 PR c++/80485 - inline function non-zero address.
21868 * symtab.c (nonzero_address): Check DECL_COMDAT.
21869
21870 2018-05-25 Uros Bizjak <ubizjak@gmail.com>
21871
21872 PR target/83628
21873 * config/alpha/alpha.md (ashlsi3): New insn pattern.
21874 (*ashlsi_se): Rename from *ashldi_se. Define as sign
21875 extension of SImode operation. Use const123_operand predicate.
21876 (*saddsi_1): Remove.
21877 (*saddl_se_1): Ditto.
21878 (*ssubsi_1): Ditto.
21879 (*ssubl_se_1): Ditto.
21880 * config/alpha/predicates.md (const123_operand): New predicate.
21881 * config/alpha/constraints.md (P): Use IN_RANGE.
21882
21883 2018-05-25 Richard Biener <rguenther@suse.de>
21884
21885 * tree-ssa-alias.h (refs_may_alias_p): Add tbaa_p bool parameter,
21886 defaulted to true.
21887 (ref_maybe_used_by_stmt_p): Likewise.
21888 (stmt_may_clobber_ref_p): Likewise.
21889 (stmt_may_clobber_ref_p_1): Likewise.
21890 * tree-ssa-alias.c (refs_may_alias_p): Add tbaa_p bool parameter
21891 and pass it along.
21892 (ref_maybe_used_by_stmt_p): Likewise.
21893 (stmt_may_clobber_ref_p): Likewise.
21894 (stmt_may_clobber_ref_p_1): Likewise.
21895 * tree-vect-data-refs.c (vect_slp_analyze_node_dependences): Use
21896 the alias oracle to disambiguate DRs with stmts DR analysis
21897 couldn't handle.
21898 (vect_analyze_data_refs): Do not give up on not analyzable
21899 DRs for BB vectorization. Remove code truncating the dataref
21900 vector.
21901
21902 2018-05-25 Jakub Jelinek <jakub@redhat.com>
21903
21904 PR target/85832
21905 * config/i386/sse.md (<avx512>_eq<mode>3<mask_scalar_merge_name>_1):
21906 Add (=Yk,v,C) variant using vptestm insn. Use TARGET_AVX512BW
21907 in test instead of TARGET_AVX512F for VI12_AVX512VL iterator.
21908
21909 2018-05-25 Richard Biener <rguenther@suse.de>
21910
21911 * tree-vect-data-refs.c (vect_find_stmt_data_reference): New
21912 function, combining stmt data ref gathering and fatal analysis
21913 parts.
21914 (vect_analyze_data_refs): Remove now redudnant code and simplify.
21915 * tree-vect-loop.c (vect_get_datarefs_in_loop): Factor out from
21916 vect_analyze_loop_2 and use vect_find_stmt_data_reference.
21917 * tree-vect-slp.c (vect_slp_bb): Use vect_find_stmt_data_reference.
21918 * tree-vectorizer.h (vect_find_stmt_data_reference): Declare.
21919
21920 2018-05-25 Bin Cheng <bin.cheng@arm.com>
21921
21922 PR tree-optimization/85720
21923 * tree-loop-distribution.c (break_alias_scc_partitions): Don't merge
21924 SCC if all partitions are builtins.
21925 (version_loop_by_alias_check): New parameter. Generate cancelable
21926 runtime alias check if all partitions are builtins.
21927 (distribute_loop): Update call to above function.
21928
21929 2018-05-25 Bin Cheng <bin.cheng@arm.com>
21930
21931 * tree-outof-ssa.c (tree-ssa.h, tree-dfa.h): Include header files.
21932 (create_default_def, for_all_parms): Moved from tree-ssa-coalesce.c.
21933 (parm_default_def_partition_arg): Ditto.
21934 (set_parm_default_def_partition): Ditto.
21935 (get_parm_default_def_partitions): Ditto and make it static.
21936 (get_undefined_value_partitions): Ditto and make it static.
21937 (remove_ssa_form): Refactor call to init_var_map here.
21938 * tree-ssa-coalesce.c (build_ssa_conflict_graph): Support live range
21939 computation for loop region.
21940 (coalesce_partitions, compute_optimized_partition_bases): Ditto.
21941 (register_default_def): Delete.
21942 (for_all_parms, create_default_def): Move to tree-outof-ssa.c.
21943 (parm_default_def_partition_arg): Ditto.
21944 (set_parm_default_def_partition): Ditto.
21945 (get_parm_default_def_partitions): Ditto and make it static.
21946 (get_undefined_value_partitions): Ditto and make it static.
21947 (coalesce_with_default, coalesce_with_default): Update comment.
21948 (create_coalesce_list_for_region): New func factored out from
21949 create_outofssa_var_map.
21950 (populate_coalesce_list_for_outofssa): New func factored out from
21951 create_outofssa_var_map and coalesce_ssa_name.
21952 (create_outofssa_var_map): Delete.
21953 (coalesce_ssa_name): Refactor to support live range computation.
21954 * tree-ssa-coalesce.h (coalesce_ssa_name): Change decl.
21955 (get_parm_default_def_partitions): Delete.
21956 (get_undefined_value_partitions): Ditto.
21957 * tree-ssa-live.c (init_var_map, delete_var_map): Support live range
21958 computation for loop region.
21959 (new_tree_live_info, loe_visit_block): Ditto.
21960 (live_worklist, set_var_live_on_entry): Ditto.
21961 (calculate_live_on_exit, verify_live_on_entry): Ditto.
21962 * tree-ssa-live.h (struct _var_map): New fields.
21963 (init_var_map): Change decl.
21964 (region_contains_p): New.
21965
21966 2018-05-25 Bin Cheng <bin.cheng@arm.com>
21967
21968 * tree-ssa-live.h (live_merge_and_clear): Delete.
21969
21970 2018-05-25 Richard Biener <rguenther@suse.de>
21971
21972 PR c++/85912
21973 * tree-dump.c (dequeue_and_dump): Remove access to removed
21974 operand 2 of a SWITCH_EXPR.
21975
21976 2018-05-25 Richard Sandiford <richard.sandiford@linaro.org>
21977
21978 * doc/sourcebuild.texi (vect_double_cond_arith): Include
21979 multiplication and division.
21980 * doc/md.texi (cond_mul@var{m}, cond_div@var{m}, cond_mod@var{m})
21981 (cond_udiv@var{m}, cond_umod@var{m}): Document.
21982 * optabs.def (cond_smul_optab, cond_sdiv_optab, cond_smod_optab)
21983 (cond_udiv_optab, cond_umod_optab): New optabs.
21984 * internal-fn.def (IFN_COND_MUL, IFN_COND_DIV, IFN_COND_MOD)
21985 (IFN_COND_RDIV): New internal functions.
21986 * internal-fn.c (get_conditional_internal_fn): Handle TRUNC_DIV_EXPR,
21987 TRUNC_MOD_EXPR and RDIV_EXPR.
21988 * match.pd (UNCOND_BINARY, COND_BINARY): Handle them.
21989 * config/aarch64/iterators.md (UNSPEC_COND_MUL, UNSPEC_COND_DIV):
21990 New unspecs.
21991 (SVE_INT_BINARY): Include mult.
21992 (SVE_COND_FP_BINARY): Include UNSPEC_MUL and UNSPEC_DIV.
21993 (optab, sve_int_op): Handle mult.
21994 (optab, sve_fp_op, commutative): Handle UNSPEC_COND_MUL and
21995 UNSPEC_COND_DIV.
21996 * config/aarch64/aarch64-sve.md (cond_<optab><mode>): New pattern
21997 for SVE_INT_BINARY_SD.
21998
21999 2018-05-25 Richard Sandiford <richard.sandiford@linaro.org>
22000
22001 * config/aarch64/iterators.md (SVE_INT_BINARY_SD): New code iterator.
22002 (optab, sve_int_op): Handle div and udiv.
22003 * config/aarch64/aarch64-sve.md (<optab><mode>3): New expander
22004 for SVE_INT_BINARY_SD.
22005 (*<optab><mode>3): New insn for the same.
22006
22007 2018-05-25 Richard Sandiford <richard.sandiford@linaro.org>
22008
22009 * tree-vect-patterns.c: Include predict.h.
22010 (vect_recog_divmod_pattern): Restrict check for division support
22011 to when optimizing for size.
22012
22013 2018-05-25 Richard Sandiford <richard.sandiford@linaro.org>
22014
22015 * doc/sourcebuild.texi (vect_double_cond_arith: Document.
22016 * gimple-match.h (gimple_match_op::MAX_NUM_OPS): Bump to 4.
22017 (gimple_match_op::gimple_match_op): Add an overload for 4 operands.
22018 (gimple_match_op::set_op): Likewise.
22019 (gimple_resimplify4): Declare.
22020 * genmatch.c (get_operand_type): Handle CFN_COND_* functions.
22021 (expr::gen_transform): Likewise.
22022 (decision_tree::gen): Generate a simplification routine for 4 operands.
22023 * gimple-match-head.c (gimple_simplify): Add an overload for
22024 4 operands. In the top-level function, handle up to 4 call
22025 arguments and call gimple_resimplify4.
22026 (gimple_resimplify4): New function.
22027 (build_call_internal): Pass a fourth operand.
22028 (maybe_push_to_seq): Likewise.
22029 * match.pd (UNCOND_BINARY, COND_BINARY): New operator lists.
22030 Fold VEC_COND_EXPRs of an operation and a default value into
22031 an IFN_COND_* function if possible.
22032 * config/aarch64/iterators.md (UNSPEC_COND_MAX, UNSPEC_COND_MIN):
22033 New unspecs.
22034 (SVE_COND_FP_BINARY): Include them.
22035 (optab, sve_fp_op): Handle them.
22036 (SVE_INT_BINARY_REV): New code iterator.
22037 (SVE_COND_FP_BINARY_REV): New int iterator.
22038 (commutative): New int attribute.
22039 * config/aarch64/aarch64-protos.h (aarch64_sve_prepare_conditional_op):
22040 Declare.
22041 * config/aarch64/aarch64.c (aarch64_sve_prepare_conditional_op): New
22042 function.
22043 * config/aarch64/aarch64-sve.md (cond_<optab><mode>): Use it.
22044 (*cond_<optab><mode>): New patterns for reversed operands.
22045
22046 2018-05-25 Richard Biener <rguenther@suse.de>
22047
22048 * tree-vectorizer.h (STMT_VINFO_GROUP_*, GROUP_*): Remove.
22049 (DR_GROUP_*): New, assert we have non-NULL ->data_ref_info.
22050 (REDUC_GROUP_*): New, assert we have NULL ->data_ref_info.
22051 (STMT_VINFO_GROUPED_ACCESS): Adjust.
22052 * tree-vect-data-refs.c (everywhere): Adjust users.
22053 * tree-vect-loop.c (everywhere): Likewise.
22054 * tree-vect-slp.c (everywhere): Likewise.
22055 * tree-vect-stmts.c (everywhere): Likewise.
22056 * tree-vect-patterns.c (vect_reassociating_reduction_p): Likewise.
22057
22058 2018-05-25 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
22059
22060 * configure.ac (gcc_cv_as_section_has_e): Move to common section.
22061 Rename to...
22062 (gcc_cv_as_section_exclude): ... this.
22063 Try Solaris as #exclude syntax.
22064 * configure: Regenerate.
22065 * config.in: Regenerate.
22066 * config/i386/i386.c (i386_solaris_elf_named_section): Handle
22067 SECTION_EXCLUDE.
22068 * config/sparc/sparc.c (sparc_solaris_elf_asm_named_section)
22069 [HAVE_GAS_SECTION_EXCLUDE]: Handle SECTION_EXCLUDE.
22070
22071 * varasm.c (default_elf_asm_named_section): Don't check if
22072 HAVE_GAS_SECTION_EXCLUDE is defined.
22073
22074 2018-05-25 Richard Sandiford <richard.sandiford@linaro.org>
22075
22076 * doc/md.texi: Update the documentation of the cond_* optabs
22077 to mention the new final operand. Fix GET_MODE_NUNITS call.
22078 Describe the scalar case too.
22079 * internal-fn.def (IFN_EXTRACT_LAST): Change type to fold_left.
22080 * internal-fn.c (expand_cond_unary_optab_fn): Expect 3 operands
22081 instead of 2.
22082 (expand_cond_binary_optab_fn): Expect 4 operands instead of 3.
22083 (get_conditional_internal_fn): Update comment.
22084 * tree-vect-loop.c (vectorizable_reduction): Pass the original
22085 accumulator value as a final argument to conditional functions.
22086 * config/aarch64/aarch64-sve.md (cond_<optab><mode>): Turn into
22087 a define_expand and add an "else" operand. Assert for now that
22088 the else operand is equal to operand 2. Use SVE_INT_BINARY and
22089 SVE_COND_FP_BINARY instead of SVE_COND_INT_OP and SVE_COND_FP_OP.
22090 (*cond_<optab><mode>): New patterns.
22091 * config/aarch64/iterators.md (UNSPEC_COND_SMAX, UNSPEC_COND_UMAX)
22092 (UNSPEC_COND_SMIN, UNSPEC_COND_UMIN, UNSPEC_COND_AND, UNSPEC_COND_ORR)
22093 (UNSPEC_COND_EOR): Delete.
22094 (optab): Remove associated mappings.
22095 (SVE_INT_BINARY): New code iterator.
22096 (sve_int_op): Remove int attribute and add "minus" to the code
22097 attribute.
22098 (SVE_COND_INT_OP): Delete.
22099 (SVE_COND_FP_OP): Rename to...
22100 (SVE_COND_FP_BINARY): ...this.
22101
22102 2018-05-25 Richard Sandiford <richard.sandiford@linaro.org>
22103
22104 * optabs.c (can_reuse_operands_p): New function.
22105 (maybe_legitimize_operands): Try to reuse the results for
22106 earlier operands.
22107
22108 2018-05-24 Uros Bizjak <ubizjak@gmail.com>
22109
22110 * config/i386/sse.md (cvtusi2<ssescalarmodesuffix>64<round_name>):
22111 Add {q} suffix to insn mnemonic.
22112
22113 2018-05-23 Jozef Lawrynowicz <jozef.l@mittosystems.com>
22114
22115 * config/msp430/msp430.c (TARGET_WARN_FUNC_RETURN): Define.
22116 (msp430_warn_func_return): New.
22117
22118 2018-05-24 Roger Sayle <roger@nextmovesoftware.com>
22119
22120 * fold-const.c (tree_nonzero_bits): New function.
22121 * fold-const.h (tree_nonzero_bits): Likewise.
22122 * match.pd (POPCOUNT): New patterns to fold BUILTIN_POPCOUNT and
22123 friends. POPCOUNT(x&1) => x&1, POPCOUNT(x)==0 => x==0, etc.
22124
22125 2018-05-24 H.J. Lu <hongjiu.lu@intel.com>
22126
22127 PR target/85900
22128 PR target/85345
22129 * varasm.c (assemble_alias): Check ifunc_resolver only on
22130 FUNCTION_DECL.
22131
22132 2018-05-24 Uros Bizjak <ubizjak@gmail.com>
22133
22134 PR target/85903
22135 * config/i386/sse.md (movdi_to_sse): Do not generate pseudo
22136 when memory input operand is handled.
22137
22138 2018-05-24 Luis Machado <luis.machado@linaro.org>
22139
22140 * config/aarch64/aarch64.c (qdf24xx_addrcost_table): New static
22141 global.
22142 (qdf24xx_tunings) <addr_costs>: Set to qdf24xx_addrcost_table.
22143
22144 2018-05-24 Richard Sandiford <richard.sandiford@linaro.org>
22145
22146 * match.pd: Delay FMA folds until after vectorization.
22147
22148 2018-05-24 Andre Vieira <andre.simoesdiasvieira@arm.com>
22149
22150 PR target/83009
22151 * config/aarch64/predicates.md (aarch64_mem_pair_lanes_operand): Make
22152 address check not strict.
22153
22154 2018-05-24 Richard Sandiford <richard.sandiford@linaro.org>
22155
22156 * gimple-match.h (gimple_match_op): New class.
22157 (mprts_hook): Replace parameters with a gimple_match_op *.
22158 (maybe_build_generic_op): Likewise.
22159 (gimple_simplified_result_is_gimple_val): Replace parameters with
22160 a const gimple_match_op *.
22161 (gimple_simplify): Replace code_helper * and tree * parameters with
22162 a gimple_match_op * parameter.
22163 (gimple_resimplify1): Replace code_helper *, tree and tree *
22164 parameters with a gimple_match_op * parameter.
22165 (gimple_resimplify2): Likewise.
22166 (gimple_resimplify3): Likewise.
22167 (maybe_push_res_to_seq): Replace code_helper, tree and tree *
22168 parameters with a gimple_match_op * parameter.
22169 * gimple-match-head.c (gimple_simplify): Change prototypes of
22170 auto-generated functions to take a gimple_match_op * instead of
22171 separate code_helper * and tree * parameters. Make the same
22172 change in the top-level overload and update calls to the
22173 gimple_resimplify routines. Update calls to the auto-generated
22174 functions and to maybe_push_res_to_seq in the publicly-facing
22175 operation-specific gimple_simplify overloads.
22176 (gimple_match_op::MAX_NUM_OPS): Define.
22177 (gimple_resimplify1): Replace rcode and ops with a single res_op
22178 parameter. Update call to gimple_simplify.
22179 (gimple_resimplify2): Likewise.
22180 (gimple_resimplify3): Likewise.
22181 (mprts_hook): Replace parameters with a gimple_match_op *.
22182 (maybe_build_generic_op): Likewise.
22183 (build_call_internal): Replace type, nargs and ops with
22184 a gimple_match_op *.
22185 (maybe_push_res_to_seq): Replace res_code, type and ops parameters
22186 with a single gimple_match_op *. Update calls to mprts_hook,
22187 build_call_internal and gimple_simplified_result_is_gimple_val.
22188 Factor out code that is common to the tree_code and combined_fn cases.
22189 * genmatch.c (expr::gen_transform): Replace tem_code and
22190 tem_ops with a gimple_match_op called tem_op. Update calls
22191 to the gimple_resimplify functions and maybe_push_res_to_seq.
22192 (dt_simplify::gen_1): Manipulate res_op instead of res_code and
22193 res_ops. Update call to the gimple_resimplify functions.
22194 (dt_simplify::gen): Pass res_op instead of res_code and res_ops.
22195 (decision_tree::gen): Make the functions take a gimple_match_op *
22196 called res_op instead of separate res_code and res_ops parameters.
22197 Update call accordingly.
22198 * gimple-fold.c (replace_stmt_with_simplification): Replace rcode
22199 and ops with a single res_op parameter. Update calls to
22200 maybe_build_generic_op and maybe_push_res_to_seq.
22201 (fold_stmt_1): Update calls to gimple_simplify and
22202 replace_stmt_with_simplification.
22203 (gimple_fold_stmt_to_constant_1): Update calls to gimple_simplify
22204 and gimple_simplified_result_is_gimple_val.
22205 * tree-cfgcleanup.c (cleanup_control_expr_graph): Update call to
22206 gimple_simplify.
22207 * tree-ssa-sccvn.c (vn_lookup_simplify_result): Replace parameters
22208 with a gimple_match_op *.
22209 (vn_nary_build_or_lookup): Likewise. Update call to
22210 vn_nary_build_or_lookup_1.
22211 (vn_nary_build_or_lookup_1): Replace rcode, type and ops with a
22212 gimple_match_op *. Update calls to the gimple_resimplify routines
22213 and to gimple_simplified_result_is_gimple_val.
22214 (vn_nary_simplify): Update call to vn_nary_build_or_lookup_1.
22215 Use gimple_match_op::MAX_NUM_OPS instead of a hard-coded 3.
22216 (vn_reference_lookup_3): Update call to vn_nary_build_or_lookup.
22217 (visit_nary_op): Likewise.
22218 (visit_reference_op_load): Likewise.
22219
22220 2018-05-23 Luis Machado <luis.machado@linaro.org>
22221
22222 * tree-ssa-loop-prefetch.c (should_issue_prefetch_p): Use correct type
22223 modifier for printing the step amount.
22224
22225 2018-05-23 Jozef Lawrynowicz <jozef.l@somniumtech.com>
22226
22227 PR target/78849
22228 * tree.c (build_common_tree_nodes): Dont set TYPE_SIZE for __intN
22229 types.
22230
22231 2018-05-23 Segher Boessenkool <segher@kernel.crashing.org>
22232
22233 * doc/sourcebuild.texi (Endianness): New subsubsection.
22234
22235 2018-05-23 Luis Machado <luis.machado@linaro.org>
22236
22237 * config/aarch64/aarch64-protos.h (cpu_prefetch_tune)
22238 <prefetch_dynamic_strides>: New const bool field.
22239 * config/aarch64/aarch64.c (generic_prefetch_tune): Update to include
22240 prefetch_dynamic_strides.
22241 (exynosm1_prefetch_tune): Likewise.
22242 (thunderxt88_prefetch_tune): Likewise.
22243 (thunderx_prefetch_tune): Likewise.
22244 (thunderx2t99_prefetch_tune): Likewise.
22245 (qdf24xx_prefetch_tune): Likewise. Set prefetch_dynamic_strides to
22246 false.
22247 (aarch64_override_options_internal): Update to set
22248 PARAM_PREFETCH_DYNAMIC_STRIDES.
22249 * doc/invoke.texi (prefetch-dynamic-strides): Document new option.
22250 * params.def (PARAM_PREFETCH_DYNAMIC_STRIDES): New.
22251 * params.h (PARAM_PREFETCH_DYNAMIC_STRIDES): Define.
22252 * tree-ssa-loop-prefetch.c (should_issue_prefetch_p): Account for
22253 prefetch-dynamic-strides setting.
22254
22255 2018-05-23 Luis Machado <luis.machado@linaro.org>
22256
22257 * config/aarch64/aarch64-protos.h (cpu_prefetch_tune)
22258 <minimum_stride>: New const int field.
22259 * config/aarch64/aarch64.c (generic_prefetch_tune): Update to include
22260 minimum_stride field defaulting to -1.
22261 (exynosm1_prefetch_tune): Likewise.
22262 (thunderxt88_prefetch_tune): Likewise.
22263 (thunderx_prefetch_tune): Likewise.
22264 (thunderx2t99_prefetch_tune): Likewise.
22265 (qdf24xx_prefetch_tune) <minimum_stride>: Set to 2048.
22266 <default_opt_level>: Set to 3.
22267 (aarch64_override_options_internal): Update to set
22268 PARAM_PREFETCH_MINIMUM_STRIDE.
22269 * doc/invoke.texi (prefetch-minimum-stride): Document new option.
22270 * params.def (PARAM_PREFETCH_MINIMUM_STRIDE): New.
22271 * params.h (PARAM_PREFETCH_MINIMUM_STRIDE): Define.
22272 * tree-ssa-loop-prefetch.c (should_issue_prefetch_p): Return false if
22273 stride is constant and is below the minimum stride threshold.
22274
22275 2018-05-23 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
22276
22277 * config/arm/arm-cpus.in (mode26): Delete.
22278 (armv4): Delete mode26 reference.
22279 * config/arm/arm.c (arm_configure_build_target): Delete use of
22280 isa_bit_mode26.
22281
22282 2018-05-23 Uros Bizjak <ubizjak@gmail.com>
22283
22284 * config/i386/i386.md (*floatuns<SWI48:mode><MODEF:mode>2_avx512):
22285 New insn pattern.
22286 (floatunssi<mode>2): Also enable for AVX512F and TARGET_SSE_MATH.
22287 Rewrite expander pattern. Emit gen_floatunssi<mode>2_i387_with_xmm
22288 for non-SSE modes.
22289 (floatunsdisf2): Rewrite expander pattern. Hanlde TARGET_AVX512F.
22290 (floatunsdidf2): Ditto.
22291
22292 2018-05-23 Uros Bizjak <ubizjak@gmail.com>
22293
22294 * config/i386/i386.md (fixuns_trunc<mode>di2): New insn pattern.
22295 (fixuns_trunc<mode>si2_avx512f): Ditto.
22296 (*fixuns_trunc<mode>si2_avx512f_zext): Ditto.
22297 (fixuns_trunc<mode>si2): Also enable for AVX512F and TARGET_SSE_MATH.
22298 Emit fixuns_trunc<mode>si2_avx512f for AVX512F targets.
22299
22300 2018-05-23 Alexander Monakov <amonakov@ispras.ru>
22301
22302 PR rtl-optimization/79985
22303 * df-scan.c (df_insn_refs_collect): Remove special case for
22304 global registers and asm statements.
22305
22306 2018-05-23 Alexander Monakov <amonakov@ispras.ru>
22307
22308 * extend.texi (Global Register Variables): Rewrite the bullet list.
22309 Note that the register is available for allocation. Note that access
22310 via inline asm must use constraints. Add note about async-signal
22311 handlers. Remove paragraph about automagic register selection.
22312
22313 2018-05-23 Richard Biener <rguenther@suse.de>
22314
22315 * tree-ssa-sccvn.c (vn_reference_lookup_3): Remove restriction
22316 of fixed offset from memset VN.
22317
22318 2018-05-23 Bill Schmidt <wschmidt@linux.ibm.com>
22319
22320 * gimple-ssa-strength-reduction.c (struct slsr_cand_d): Add
22321 first_interp field.
22322 (alloc_cand_and_find_basis): Initialize first_interp field.
22323 (slsr_process_mul): Modify first_interp field.
22324 (slsr_process_add): Likewise.
22325 (slsr_process_cast): Modify first_interp field for each new
22326 interpretation.
22327 (slsr_process_copy): Likewise.
22328 (dump_candidate): Dump first_interp field.
22329 (replace_mult_candidate): Process all interpretations, not just
22330 subsequent ones.
22331 (replace_rhs_if_not_dup): Likewise.
22332 (replace_one_candidate): Likewise.
22333
22334 2018-05-23 Wilco Dijkstra <wdijkstr@arm.com>
22335
22336 * config/aarch64/aarch64.c (aarch64_use_frame_pointer):
22337 Add new boolean.
22338 (aarch64_needs_frame_chain): New function.
22339 (aarch64_parse_override_string): Set aarch64_use_frame_pointer.
22340
22341 2018-05-23 Sudakshina Das <sudi.das@arm.com>
22342
22343 PR target/84882
22344 * common/config/aarch64/aarch64-common.c (aarch64_handle_option):
22345 Check val before adding MASK_STRICT_ALIGN to opts->x_target_flags.
22346 * config/aarch64/aarch64.opt (mstrict-align): Remove RejectNegative.
22347 * config/aarch64/aarch64.c (aarch64_attributes): Mark allow_neg
22348 as true for strict-align.
22349 (aarch64_can_inline_p): Perform checks even when callee has no
22350 attributes to check for strict alignment.
22351 * doc/extend.texi (AArch64 Function Attributes): Document
22352 no-strict-align.
22353 * doc/invoke.texi: (AArch64 Options): Likewise.
22354
22355 2018-05-23 Richard Sandiford <richard.sandiford@linaro.org>
22356
22357 PR tree-optimization/85853
22358 * tree-vect-slp.c (vect_slp_analyze_node_operations): Split out
22359 the handling of the root of the node to...
22360 (vect_slp_analyze_node_operations_1): ...this new function,
22361 and run the whole thing with the child nodes' def types
22362 set according to their SLP node's def type.
22363
22364 2018-05-23 Richard Biener <rguenther@suse.de>
22365
22366 PR middle-end/85874
22367 * tree-data-ref.c (create_runtime_alias_checks): Defer
22368 and ignore overflow warnings.
22369
22370 2018-05-23 Yury Gribov <tetra2005@gmail.com>
22371
22372 PR tree-optimization/85822
22373 * tree-vrp.c (is_masked_range_test): Fix handling of negative
22374 constants.
22375
22376 2018-05-23 Richard Biener <rguenther@suse.de>
22377
22378 * tree-ssa-sccvn.c (vn_reference_lookup_3): Handle arbitrary
22379 memset constants via native_interpret_expr.
22380
22381 2018-05-22 H.J. Lu <hongjiu.lu@intel.com>
22382
22383 PR target/85345
22384 * cgraph.h (cgraph_node::create): Set ifunc_resolver for ifunc
22385 attribute.
22386 (cgraph_node::create_alias): Likewise.
22387 (cgraph_node::get_availability): Check ifunc_resolver instead
22388 of looking up ifunc attribute.
22389 * cgraphunit.c (maybe_diag_incompatible_alias): Likewise.
22390 * varasm.c (do_assemble_alias): Likewise.
22391 (assemble_alias): Likewise.
22392 (default_binds_local_p_3): Likewise.
22393 * cgraph.h (cgraph_node): Add ifunc_resolver.
22394 (cgraph_node::only_called_directly_or_aliased_p): Return false
22395 for IFUNC resolver.
22396 * lto-cgraph.c (input_node): Set ifunc_resolver for ifunc
22397 attribute.
22398 * symtab.c (symtab_node::verify_base): Verify that ifunc_resolver
22399 is equivalent to lookup_attribute ("ifunc", DECL_ATTRIBUTES (decl)).
22400 (symtab_node::binds_to_current_def_p): Check ifunc_resolver
22401 instead of looking up ifunc attribute.
22402
22403 2018-05-22 Luis Machado <luis.machado@linaro.org>
22404
22405 * config/aarch64/aarch64.md (*ashift<mode>_extv_bfiz): New pattern.
22406
22407 2018-05-22 Martin Sebor <msebor@redhat.com>
22408
22409 PR middle-end/85359
22410 * builtins.c (expand_builtin_strcpy): Call maybe_warn_nonstring_arg
22411 only when expasion succeeds.
22412 (expand_builtin_strcmp): Same.
22413 (expand_builtin_strncmp): Same.
22414
22415 2018-05-22 Martin Sebor <msebor@redhat.com>
22416
22417 * calls.c (maybe_warn_nonstring_arg): Fix a typo in a comment.
22418
22419 2018-05-22 Jackson Woodruff <jackson.woodruff@arm.com>
22420 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
22421
22422 * config/aarch64/aarch64-ldpstp.md: Replace uses of
22423 aarch64_mem_pair_operand with memory_operand and delete operand swapping
22424 code.
22425 * config/aarch64/aarch64.c (aarch64_operands_ok_for_ldpstp):
22426 Add check for legitimate_address.
22427 (aarch64_gen_adjusted_ldpstp): Swap operands where appropriate.
22428 (aarch64_swap_ldrstr_operands): New.
22429 * config/aarch64/aarch64-protos.h (aarch64_swap_ldrstr_operands):
22430 Define prototype.
22431
22432 2018-05-22 Jackson Woodruff <jackson.woodruff@arm.com>
22433 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
22434
22435 * config/aarch64/aarch64.md: New patterns to generate stp
22436 and ldp.
22437 (store_pair_sw, store_pair_dw): New patterns to generate stp for
22438 single words and double words.
22439 (load_pair_sw, load_pair_dw): Likewise.
22440 (store_pair_sf, store_pair_df, store_pair_si, store_pair_di):
22441 Delete.
22442 (load_pair_sf, load_pair_df, load_pair_si, load_pair_di):
22443 Delete.
22444 * config/aarch64/aarch64-ldpstp.md: Modify peephole
22445 for different mode ldpstp and add peephole for merged zero stores.
22446 Likewise for loads.
22447 * config/aarch64/aarch64.c (aarch64_operands_ok_for_ldpstp):
22448 Add size check.
22449 (aarch64_gen_store_pair): Rename calls to match new patterns.
22450 (aarch64_gen_load_pair): Rename calls to match new patterns.
22451 * config/aarch64/aarch64-simd.md (load_pair<mode>): Rename to...
22452 (load_pair<DREG:mode><DREG2:mode>): ... This.
22453 (store_pair<mode>): Rename to...
22454 (vec_store_pair<DREG:mode><DREG2:mode>): ... This.
22455 * config/aarch64/iterators.md (DREG, DREG2, DX2, SX, SX2, DSX):
22456 New mode iterators.
22457 (V_INT_EQUIV): Handle SImode.
22458 * config/aarch64/predicates.md (aarch64_reg_zero_or_fp_zero):
22459 New predicate.
22460
22461 2018-05-22 Martin Sebor <msebor@redhat.com>
22462
22463 PR c/85623
22464 * calls.c (maybe_warn_nonstring_arg): Use string length to set
22465 or ajust the presumed bound on an operation to avoid unnecessary
22466 warnings.
22467
22468 2018-05-22 Martin Sebor <msebor@redhat.com>
22469
22470 PR tree-optimization/85826
22471 * gimple-ssa-warn-restrict.c (builtin_memref::builtin_memref): Avoid
22472 assuming that a DECL necesarily has a constant size.
22473
22474 2018-05-22 Richard Sandiford <richard.sandiford@linaro.org>
22475
22476 PR middle-end/85862
22477 * internal-fn.c (expand_direct_optab_fn): Cope with a null lhs.
22478
22479 2018-05-22 Richard Biener <rguenther@suse.de>
22480
22481 PR tree-optimization/85834
22482 * tree-ssa-sccvn.c (vn_reference_lookup_3): Properly handle
22483 non-constant and non-zero memset arguments.
22484
22485 2018-05-22 Martin Liska <mliska@suse.cz>
22486
22487 PR ipa/85607
22488 * ipa-icf.c (sem_item::add_type): Do not ICE for incomplete types.
22489
22490 2018-05-22 Richard Biener <rguenther@suse.de>
22491
22492 PR tree-optimization/85863
22493 * tree-vect-stmts.c (vect_is_simple_cond): Only widen invariant
22494 comparisons when vectype is specified.
22495 (vectorizable_condition): Do not specify vectype for
22496 vect_is_simple_cond when SLP vectorizing.
22497
22498 2018-05-21 Michael Meissner <meissner@linux.ibm.com>
22499
22500 PR target/85657
22501 * config/rs6000/rs6000-c.c (rs6000_cpu_cpp_builtins): Do not
22502 define __ibm128 as long double.
22503 * config/rs6000/rs6000.c (rs6000_init_builtins): Create __ibm128
22504 as a distinct type when IEEE 128-bit support is enabled.
22505 (init_float128_ieee): Fix up conversions between IFmode and IEEE
22506 128-bit types to use the correct functions.
22507 (rs6000_expand_float128_convert): Use explicit FLOAT_EXTEND to
22508 convert between 128-bit floating point types that have different
22509 modes but the same representation, instead of using gen_lowpart to
22510 makean alias.
22511 * config/rs6000/rs6000.md (IFKF): New iterator for IFmode and
22512 KFmode.
22513 (IFKF_reg): New attributes to give the register constraints for
22514 IFmode and KFmode.
22515 (extend<mode>tf2_internal): New insns to mark an explicit
22516 conversion between 128-bit floating point types that have a
22517 different mode but share the same representation.
22518
22519 2018-05-21 Richard Sandiford <richard.sandiford@linaro.org>
22520
22521 PR tree-optimization/85814
22522 * tree-ssa-strlen.c (get_stridx_plus_constant): Cope with
22523 a null return from get_strinfo when unsharing the next
22524 strinfo in the chain.
22525
22526 2018-05-21 Vladimir Mezentsev <vladimir.mezentsev@oracle.com>
22527
22528 PR gcc/84923
22529 * varasm.c (weak_finish): Clean up weak_decls.
22530
22531 2018-05-21 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
22532
22533 * config/aarch64/aarch64.md ("unspec"): Define UNSPEC_SABAL,
22534 UNSPEC_SABDL2, UNSPEC_SADALP, UNSPEC_UABAL, UNSPEC_UABDL2,
22535 UNSPEC_UADALP values.
22536 * config/aarch64/iterators.md (ABAL): New int iterator.
22537 (ABDL2): Likewise.
22538 (ADALP): Likewise.
22539 (sur): Add mappings for the above.
22540 * config/aarch64/aarch64-simd.md (aarch64_<sur>abdl2<mode>_3):
22541 New define_insn.
22542 (aarch64_<sur>abal<mode>_4): Likewise.
22543 (aarch64_<sur>adalp<mode>_3): Likewise.
22544 (<sur>sadv16qi): New define_expand.
22545
22546 2018-05-21 Alexander Nesterovskiy <alexander.nesterovskiy@intel.com>
22547
22548 * config/i386/i386.md (*movsf_internal): AVX falsedep fix.
22549 (*movdf_internal): Ditto.
22550 (*rcpsf2_sse): Ditto.
22551 (*rsqrtsf2_sse): Ditto.
22552 (*sqrt<mode>2_sse): Ditto.
22553
22554 2018-05-21 Tamar Christina <tamar.christina@arm.com>
22555
22556 * config/aarch64/aarch64-simd.md (aarch64_eor3qv8hi): Change to
22557 eor3q<mode>4.
22558 (aarch64_bcaxqv8hi): Change to bcaxq<mode>4.
22559 * config/aarch64/aarch64-simd-builtins.def (veor3q_u8, veor3q_u32,
22560 veor3q_u64, veor3q_s8, veor3q_s16, veor3q_s32, veor3q_s64, vbcaxq_u8,
22561 vbcaxq_u32, vbcaxq_u64, vbcaxq_s8, vbcaxq_s16, vbcaxq_s32,
22562 vbcaxq_s64): New.
22563 * config/aarch64/arm_neon.h: Likewise.
22564 * config/aarch64/iterators.md (VQ_I): New.
22565
22566 2018-05-21 Alexey Brodkin <abrodkin@synopsys.com>
22567
22568 * config.gcc: Add arc/t-multilib-linux to tmake_file for
22569 arc*-*-linux*.
22570 * config/arc/t-multilib-linux: Specify MULTILIB_OPTIONS and
22571 MULTILIB_DIRNAMES
22572
22573 2018-05-20 Chung-Ju Wu <jasonwucj@gmail.com>
22574
22575 * config/nds32/constraints.md (S): New constraint.
22576 * config/nds32/nds32.md (call_internal): Use constraint S.
22577 (call_value_internal): Likewise.
22578 (sibcall_internal): Likewise.
22579 (sibcall_value_internal): Likewise.
22580
22581 2018-05-20 Kito Cheng <kito.cheng@gmail.com>
22582 Chung-Ju Wu <jasonwucj@gmail.com>
22583
22584 * config/nds32/nds32.c (nds32_register_move_cost): Take garywolf cpu
22585 into consideration.
22586
22587 2018-05-20 Kito Cheng <kito.cheng@gmail.com>
22588 Chung-Ju Wu <jasonwucj@gmail.com>
22589
22590 * config/nds32/nds32-cost.c (rtx_cost_model_t): New structure.
22591 (insn_size_16bit, insn_size_32bit): New variables for cost evaluation.
22592 (nds32_rtx_costs_impl): Simplify.
22593 (nds32_address_cost_impl): Simplify.
22594 (nds32_init_rtx_costs): New function.
22595 (nds32_rtx_costs_speed_prefer): Likewise.
22596 (nds32_rtx_costs_size_prefer): Likewise.
22597 (nds32_address_cost_speed_prefer): Likewise.
22598 (nds32_address_cost_speed_fwprop): Likewise.
22599 (nds32_address_cost_size_prefer): Likewise.
22600 * config/nds32/nds32-protos.h (nds32_init_rtx_costs): Declare.
22601 * config/nds32/nds32.c (nds32_option_override): Use
22602 nds32_init_rtx_costs function.
22603
22604 2018-05-20 Chung-Ju Wu <jasonwucj@gmail.com>
22605
22606 * config/nds32/nds32.c (nds32_asm_file_start): Output pipeline model.
22607 * config/nds32/nds32.h (TARGET_PIPELINE_N7): Define.
22608 (TARGET_PIPELINE_N8): Likewise.
22609 (TARGET_PIPELINE_N10): Likewise.
22610 (TARGET_PIPELINE_N13): Likewise.
22611 (TARGET_PIPELINE_GRAYWOLF): Likewise.
22612
22613 2018-05-19 Monk Chiang <sh.chiang04@gmail.com>
22614
22615 * config/nds32/nds32-fpu.md: Update copyright year.
22616
22617 2018-05-19 Chung-Ju Wu <jasonwucj@gmail.com>
22618
22619 * config/nds32/nds32.h (ASM_SPEC): Adjust spec rule.
22620
22621 2018-05-19 Chung-Ju Wu <jasonwucj@gmail.com>
22622
22623 * config/nds32/nds32.c
22624 (nds32_md_asm_adjust): Consider flag_inline_asm_r15 variable.
22625 * config/nds32/nds32.opt (minline-asm-r15): New option.
22626
22627 2018-05-19 Chung-Ju Wu <jasonwucj@gmail.com>
22628
22629 * common/config/nds32/nds32-common.c (TARGET_DEFAULT_TARGET_FLAGS): Add
22630 MASK_HW_ABS.
22631 * config/nds32/nds32.md (abssi2): New pattern.
22632
22633 2018-05-19 Uros Bizjak <ubizjak@gmail.com>
22634
22635 * config/i386/i386.md (rex64namesuffix): New mode attribute.
22636 * config/i386/sse.md (sse_cvtsi2ss<rex64namesuffix><round_name>):
22637 Merge insn pattern from sse_cvtsi2ss<round_name> and
22638 sse_cvtsi2ssq<round_name> using SWI48 mode iterator.
22639 (sse_cvtss2si<rex64namesuffix><round_name>): Merge insn pattern
22640 from sse_cvtss2si<round_name> and sse_cvtss2siq<round_name>
22641 using SWI48 mode iterator.
22642 (sse_cvtss2si<rex64namesuffix>_2): Merge insn pattern from
22643 sse_cvtss2si_2 and sse_cvtss2siq_2 using SWI48 mode iterator.
22644 (sse_cvttss2si<rex64namesuffix><round_saeonly_name>): Merge insn
22645 pattern from sse_cvttss2si<round_saeonly_name>
22646 and sse_cvttss2siq<round_saeonly_name> using SWI48 mode iterator.
22647 (avx512f_vcvtss2usi<rex64namesuffix><round_name>): Merge insn pattern
22648 from avx512f_vcvtss2usi<round_name> and avx512f_vcvtss2usiq<round_name>
22649 using SWI48 mode iterator.
22650 (avx512f_vcvttss2usi<rex64namesuffix><round_saeonly_name>): Merge
22651 insn pattern from avx512f_vcvttss2usi<round_saeonly_name> and
22652 avx512f_vcvttss2usiq<round_saeonly_name> using SWI48 mode iterator.
22653 (avx512f_vcvtsd2usi<rex64namesuffix><round_name>): Merge insn pattern
22654 from avx512f_vcvtsd2usi<round_name> and avx512f_vcvtsd2usiq<round_name>
22655 using SWI48 mode iterator.
22656 (avx512f_vcvttsd2usi<rex64namesuffix><round_saeonly_name>): Merge
22657 insn pattern from avx512f_vcvttsd2usi<round_saeonly_name> and
22658 avx512f_vcvttsd2usiq<round_saeonly_name> using SWI48 mode iterator.
22659 (sse2_cvtsd2si<rex64namesuffix><round_name>): Merge insn pattern from
22660 sse2_cvtsd2si<round_name> and sse2_cvtsd2siq<round_name> using
22661 SWI48 mode iterator.
22662 (sse2_cvtsd2si<rex64namesuffix>_2): Merge insn pattern from
22663 sse2_cvtsd2si_2 and sse2_cvtsd2siq_2 using SWI48 mode iterator.
22664 (sse_cvttsd2si<rex64namesuffix><round_saeonly_name>): Merge insn
22665 pattern from sse_cvttsd2si<round_saeonly_name>
22666 and sse_cvttsd2siq<round_saeonly_name> using SWI48 mode iterator.
22667
22668 2018-05-19 Chung-Ju Wu <jasonwucj@gmail.com>
22669
22670 * config/nds32/nds32-md-auxiliary.c
22671 (nds32_valid_smw_lwm_base_p): Refine.
22672 (nds32_output_smw_single_word): Refine.
22673 (nds32_output_smw_double_word): New.
22674 * config/nds32/nds32-protos.h (nds32_output_smw_double_word): New.
22675
22676 2018-05-19 Chung-Ju Wu <jasonwucj@gmail.com>
22677
22678 * config/nds32/nds32-md-auxiliary.c (nds32_output_stack_push): Refine.
22679 (nds32_output_stack_pop): Refine.
22680 (nds32_expand_unaligned_load): Refine.
22681 (nds32_expand_unaligned_store): Refine.
22682
22683 2018-05-19 Kuan-Lin Chen <kuanlinchentw@gmail.com>
22684 Chung-Ju Wu <jasonwucj@gmail.com>
22685
22686 * config/nds32/constants.md: Add TP_REGNUM constant.
22687 (unspec_element): Add UNSPEC_GOTINIT, UNSPEC_GOT, UNSPEC_GOTOFF,
22688 UNSPEC_PLT, UNSPEC_TLSGD, UNSPEC_TLSLD, UNSPEC_TLSIE, UNSPEC_TLSLE and
22689 UNSPEC_ADD32.
22690 * config/nds32/nds32-doubleword.md: Consider flag_pic.
22691 * config/nds32/nds32-dspext.md (mov<mode>): Expand TLS and PIC cases.
22692 * config/nds32/nds32-predicates.c (nds32_const_unspec_p): New.
22693 * config/nds32/nds32-md-auxiliary.c: Implementation that support TLS
22694 and PIC code generation.
22695 * config/nds32/nds32-protos.h: Declarations that support TLS and PIC
22696 code generation.
22697 * config/nds32/nds32-relax-opt.c: Consider TLS and PIC for relax
22698 optimization.
22699 * config/nds32/nds32.md: Support TLS and PIC.
22700 * config/nds32/nds32.c: Support TLS and PIC.
22701 * config/nds32/nds32.h (nds32_relax_insn_type): New enum type.
22702 * config/nds32/predicates.md (nds32_nonunspec_symbolic_operand): New
22703 predicate.
22704
22705 2018-05-19 Chung-Ju Wu <jasonwucj@gmail.com>
22706
22707 * config/nds32/nds32-predicates.c (const_vector_to_hwint): Use machine
22708 mode with E_ prefix.
22709
22710 2018-05-19 Kuan-Lin Chen <kuanlinchentw@gmail.com>
22711 Chung-Ju Wu <jasonwucj@gmail.com>
22712
22713 * config/nds32/constants.md (unspec_element): Add UNSPEC_ICT.
22714 * config/nds32/nds32-md-auxiliary.c
22715 (symbolic_reference_mentioned_p): New.
22716 (nds32_legitimize_ict_address): New.
22717 (nds32_expand_ict_move): New.
22718 (nds32_indirect_call_referenced_p): New.
22719 (nds32_symbol_binds_local_p): Delete.
22720 (nds32_long_call_p): Modify.
22721 * config/nds32/nds32-opts.h (nds32_ict_model_type): New enum type.
22722 * config/nds32/nds32-protos.h
22723 (symbolic_reference_mentioned_p): Declare.
22724 (nds32_legitimize_ict_address): Declare.
22725 (nds32_expand_ict_move): Declare.
22726 (nds32_indirect_call_referenced_p): Declare.
22727 * config/nds32/nds32-relax-opt.c (nds32_ict_const_p): New.
22728 (nds32_relax_group): Use nds32_ict_const_p as condition.
22729 * config/nds32/nds32.c (nds32_attribute_table): Add "indirect_call".
22730 (nds32_asm_file_start): Output ict_model directive in asm code.
22731 (nds32_legitimate_address_p): Consider indirect call.
22732 (nds32_print_operand): Consider indirect call.
22733 (nds32_print_operand_address): Consider indirect call.
22734 (nds32_insert_attributes): Handle "indirect_call" attribute.
22735 (TARGET_LEGITIMATE_ADDRESS_P): Define.
22736 (TARGET_LEGITIMATE_CONSTANT_P): Define.
22737 (TARGET_CANNOT_FORCE_CONST_MEM): Define.
22738 (TARGET_DELEGITIMIZE_ADDRESS): Define.
22739 (TARGET_ASM_OUTPUT_ADDR_CONST_EXTRA): Define.
22740 * config/nds32/nds32.h (SYMBOLIC_CONST_P): Define.
22741 (TARGET_ICT_MODEL_SMALL): Define.
22742 (TARGET_ICT_MODEL_LARGE): Define.
22743 * config/nds32/nds32.md (movsi): Consider ict model.
22744 (call, call_value): Consider ict model.
22745 (sibcall, sibcall_value): Consider ict model.
22746 * config/nds32/nds32.opt (mict-model): New option.
22747 * config/nds32/predicates.md (nds32_symbolic_operand): Consider ict
22748 model.
22749
22750 2018-05-18 Kito Cheng <kito.cheng@gmail.com>
22751 Monk Chiang <sh.chiang04@gmail.com>
22752 Jim Wilson <jimw@sifive.com>
22753
22754 * common/config/riscv/riscv-common.c (riscv_parse_arch_string):
22755 Add support to parse rv32e*. Clear MASK_RVE for rv32i and rv64i.
22756 * config.gcc (riscv*-*-*): Add support for rv32e* and ilp32e.
22757 * config/riscv/riscv-c.c (riscv_cpu_cpp_builtins): Define
22758 __riscv_32e when TARGET_RVE. Handle ABI_ILP32E as soft-float ABI.
22759 * config/riscv/riscv-opts.h (riscv_abi_type): Add ABI_ILP32E.
22760 * config/riscv/riscv.c (riscv_compute_frame_info): When TARGET_RVE,
22761 compute save_libcall_adjustment properly.
22762 (riscv_option_override): Call error if TARGET_RVE and not ABI_ILP32E.
22763 (riscv_conditional_register_usage): Handle TARGET_RVE and ABI_ILP32E.
22764 * config/riscv/riscv.h (UNITS_PER_FP_ARG): Handle ABI_ILP32E.
22765 (STACK_BOUNDARY, ABI_STACK_BOUNDARY): Handle TARGET_RVE.
22766 (GP_REG_LAST, MAX_ARGS_IN_REGISTERS): Likewise.
22767 (ABI_SPEC): Handle mabi=ilp32e.
22768 * config/riscv/riscv.opt (abi_type): Add ABI_ILP32E.
22769 (RVE): Add RVE mask.
22770 * doc/invoke.texi (RISC-V options) <-mabi>: Add ilp32e info.
22771 <-march>: Add rv32e as an example.
22772
22773 2018-05-18 Marc Glisse <marc.glisse@inria.fr>
22774
22775 PR c++/82899
22776 * tree-ssa-structalias.c (create_variable_info_for_1): Extra argument.
22777 (intra_create_variable_infos): Handle C++ constructors.
22778
22779 2018-05-18 Martin Liska <mliska@suse.cz>
22780
22781 * passes.def: Remove a redundant pass.
22782
22783 2018-05-18 Eric Botcazou <ebotcazou@adacore.com>
22784
22785 PR bootstrap/85838
22786 * config/sparc/sparc.c (sparc_expand_builtin): Always initialize op[0].
22787
22788 2018-05-18 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
22789
22790 * config/arm/arm-cpus.in (armv3m, mode32): Delete features.
22791 (ARMv4): Update.
22792 (ARMv2, ARMv3, ARMv3m): Delete fgroups.
22793 (ARMv6m): Update.
22794 (armv2, armv2a, armv3, armv3m): Delete architectures.
22795 (arm2, arm250, arm3, arm6, arm60, arm600, arm610, arm620,
22796 arm7, arm7d, arm7di, arm70, arm700, arm700i, arm710, arm720,
22797 arm710c, arm7100, arm7500, arm7500fe, arm7m, arm7dm, arm7dmi):
22798 Delete cpus.
22799 * config/arm/arm.md (maddsidi4): Remove check for arm_arch3m.
22800 (*mulsidi3adddi): Likewise.
22801 (mulsidi3): Likewise.
22802 (*mulsidi3_nov6): Likewise.
22803 (umulsidi3): Likewise.
22804 (umulsidi3_nov6): Likewise.
22805 (umaddsidi4): Likewise.
22806 (*umulsidi3adddi): Likewise.
22807 (smulsi3_highpart): Likewise.
22808 (*smulsi3_highpart_nov6): Likewise.
22809 (umulsi3_highpart): Likewise.
22810 (*umulsi3_highpart_nov6): Likewise.
22811 * config/arm/arm.h (arm_arch3m): Delete.
22812 * config/arm/arm.c (arm_arch3m): Delete.
22813 (arm_option_override_internal): Update armv3-related comment.
22814 (arm_configure_build_target): Delete use of isa_bit_mode32.
22815 (arm_option_reconfigure_globals): Delete set of arm_ach3m.
22816 (arm_rtx_costs_internal): Delete check of arm_arch3m.
22817 * config/arm/arm-fixed.md (mulsq3): Delete check for arm_arch3m.
22818 (mulsa3): Likewise.
22819 (mulusa3): Likewise.
22820 * config/arm/arm-protos.h (arm_arch3m): Delete.
22821 * config/arm/arm-tables.opt: Regenerate.
22822 * config/arm/arm-tune.md: Likewise.
22823 * config/arm/t-arm-elf (all_early_nofp): Delete mentions of
22824 deleted architectures.
22825
22826 2018-05-18 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
22827
22828 * config/arm/arm-cpus.in (armv5, armv5e): Delete features.
22829 (armv5t, armv5te): New features.
22830 (ARMv5, ARMv5e): Delete fgroups.
22831 (ARMv5t, ARMv5te): Adjust for above changes.
22832 (ARMv6m): Likewise.
22833 (armv5, armv5e): Delete arches.
22834 * config/arm/arm.md (*call_reg_armv5): Use arm_arch5t instead of
22835 arm_arch5.
22836 (*call_reg_arm): Likewise.
22837 (*call_value_reg_armv5): Likewise.
22838 (*call_value_reg_arm): Likewise.
22839 (*call_symbol): Likewise.
22840 (*call_value_symbol): Likewise.
22841 (*sibcall_insn): Likewise.
22842 (*sibcall_value_insn): Likewise.
22843 (clzsi2): Likewise.
22844 (prefetch): Likewise.
22845 (define_split and define_peephole2 dependent on arm_arch5):
22846 Likewise.
22847 * config/arm/arm.h (TARGET_LDRD): Use arm_arch5te instead of
22848 arm_arch5e.
22849 (TARGET_ARM_QBIT): Likewise.
22850 (TARGET_DSP_MULTIPLY): Likewise.
22851 (enum base_architecture): Delete BASE_ARCH_5, BASE_ARCH_5E.
22852 (arm_arch5, arm_arch5e): Delete.
22853 (arm_arch5t, arm_arch5te): Declare.
22854 * config/arm/arm.c (arm_arch5, arm_arch5e): Delete.
22855 (arm_arch5t): Declare.
22856 (arm_option_reconfigure_globals): Update for the above.
22857 (arm_options_perform_arch_sanity_checks): Update comment, replace
22858 use of arm_arch5 with arm_arch5t.
22859 (use_return_insn): Likewise.
22860 (arm_emit_call_insn): Likewise.
22861 (output_return_instruction): Likewise.
22862 (arm_final_prescan_insn): Likewise.
22863 (arm_coproc_builtin_available): Likewise.
22864 * config/arm/arm-c.c (arm_cpu_builtins): Replace arm_arch5 and
22865 arm_arch5e with arm_arch5t and arm_arch5te.
22866 * config/arm/arm-protos.h (arm_arch5, arm_arch5e): Delete.
22867 (arm_arch5t, arm_arch5te): Declare.
22868 * config/arm/arm-tables.opt: Regenerate.
22869 * config/arm/t-arm-elf: Remove references to armv5, armv5e.
22870 * config/arm/t-multilib: Likewise.
22871 * config/arm/thumb1.md (*call_reg_thumb1_v5): Check arm_arch5t
22872 instead of arm_arch5.
22873 (*call_reg_thumb1): Likewise.
22874 (*call_value_reg_thumb1_v5): Likewise.
22875 (*call_value_reg_thumb1): Likewise.
22876 * config/arm/vxworks.h (TARGET_OS_CPP_BUILTINS): Remove now
22877 unreachable path.
22878 * doc/invoke.texi (ARM Options): Remove references to armv5, armv5e.
22879
22880 2018-05-18 Martin Liska <mliska@suse.cz>
22881
22882 PR gcov-profile/84846
22883 * doc/gcov.texi: Document -t option of gcov tool.
22884
22885 2018-05-18 Martin Liska <mliska@suse.cz>
22886
22887 PR gcov-profile/84846
22888 * gcov.c (print_usage): Add new -t option.
22889 (process_args): Handle the option.
22890 (generate_results): Use stdout as output when requested by
22891 the option.
22892
22893 2018-05-18 Martin Liska <mliska@suse.cz>
22894
22895 PR gcov-profile/84846
22896 * coverage.c (coverage_init): Write PWD to .gcno file.
22897 * doc/gcov.texi: Document how working directory is printed.
22898 * gcov-dump.c (dump_gcov_file): Print PWD.
22899 * gcov.c (output_intermediate_file): Likewise.
22900 (read_graph_file): Read PWD string.
22901 (output_lines): Print PWD.
22902
22903 2018-05-18 Prathamesh Kulkarni <prathamesh.kulkarni@linaro.org>
22904
22905 PR middle-end/85817
22906 * ipa-pure-const.c (malloc_candidate_p): Remove the check integer_zerop
22907 for retval and return false if all args to phi are zero.
22908
22909 2018-05-18 Richard Biener <rguenther@suse.de>
22910
22911 * gimple-ssa-evrp.c (class evrp_folder): Add simplify_stmt_using_ranges
22912 method.
22913 (evrp_dom_walker::before_dom_children): Call it.
22914
22915 2018-05-18 Richard Biener <rguenther@suse.de>
22916
22917 * tree-dfa.c (get_ref_base_and_extent): Use range-info to refine
22918 results when processing array refs with variable index.
22919
22920 2018-05-18 Toon Moene <toon@moene.org>
22921
22922 * doc/invoke.texi: Move -floop-unroll-and-jam documentation
22923 directly after that of -floop-interchange. Indicate that both
22924 options are enabled by default when specifying -O3.
22925
22926 2018-05-18 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
22927
22928 * config/aarch64/aarch64-simd.md (vec_set<mode>): Use VALL_F16 mode
22929 iterator. Delete separate integer-mode vec_set<mode> expander.
22930 (aarch64_simd_vec_setv2di): Delete.
22931 (vec_setv2di): Delete.
22932 (aarch64_simd_vec_set<mode>): Delete all other patterns with that name.
22933 Use VALL_F16 mode iterator. Add LD1 alternative and use vwcore for
22934 the "w, r" alternative.
22935
22936 2018-05-18 Martin Liska <mliska@suse.cz>
22937
22938 * passes.def: Add pass_lower_switch and pass_lower_switch_O0.
22939 * tree-pass.h (make_pass_lower_switch_O0): New function.
22940 * tree-switch-conversion.c (node_has_low_bound): Remove.
22941 (node_has_high_bound): Likewise.
22942 (node_is_bounded): Likewise.
22943 (class pass_lower_switch): Make it a template type and create
22944 two instances.
22945 (pass_lower_switch::execute): Add template argument.
22946 (make_pass_lower_switch): New function.
22947 (make_pass_lower_switch_O0): New function.
22948 (do_jump_if_equal): Remove.
22949 (emit_case_nodes): Simplify to just handle all 3 cases and leave
22950 all the hard work to tree optimization passes.
22951
22952 2018-05-18 Martin Liska <mliska@suse.cz>
22953
22954 * dbgcnt.c (limit_low): Renamed from limit.
22955 (limit_high): New variable.
22956 (dbg_cnt_is_enabled): Check for upper limit.
22957 (dbg_cnt): Adjust dumping.
22958 (dbg_cnt_set_limit_by_index): Add new argument for high
22959 value.
22960 (dbg_cnt_set_limit_by_name): Likewise.
22961 (dbg_cnt_process_single_pair): Parse new format.
22962 (dbg_cnt_process_opt): Use strtok.
22963 (dbg_cnt_list_all_counters): Remove 'value' and add
22964 'limit_high'.
22965 * doc/invoke.texi: Document changes.
22966
22967 2018-05-18 Richard Sandiford <richard.sandiford@linaro.org>
22968
22969 * doc/sourcebuild.texi (scalar_all_fma): Document.
22970 * tree.def (FMA_EXPR): Delete.
22971 * internal-fn.def (FMA, FMS, FNMA, FNMS): New internal functions.
22972 * internal-fn.c (ternary_direct): New macro.
22973 (expand_ternary_optab_fn): Likewise.
22974 (direct_ternary_optab_supported_p): Likewise.
22975 * Makefile.in (build/genmatch.o): Depend on case-fn-macros.h.
22976 * builtins.c (fold_builtin_fma): Delete.
22977 (fold_builtin_3): Don't call it.
22978 * cfgexpand.c (expand_debug_expr): Remove FMA_EXPR handling.
22979 * expr.c (expand_expr_real_2): Likewise.
22980 * fold-const.c (operand_equal_p): Likewise.
22981 (fold_ternary_loc): Likewise.
22982 * gimple-pretty-print.c (dump_ternary_rhs): Likewise.
22983 * gimple.c (DEFTREECODE): Likewise.
22984 * gimplify.c (gimplify_expr): Likewise.
22985 * optabs-tree.c (optab_for_tree_code): Likewise.
22986 * tree-cfg.c (verify_gimple_assign_ternary): Likewise.
22987 * tree-eh.c (operation_could_trap_p): Likewise.
22988 (stmt_could_throw_1_p): Likewise.
22989 * tree-inline.c (estimate_operator_cost): Likewise.
22990 * tree-pretty-print.c (dump_generic_node): Likewise.
22991 (op_code_prio): Likewise.
22992 * tree-ssa-loop-im.c (stmt_cost): Likewise.
22993 * tree-ssa-operands.c (get_expr_operands): Likewise.
22994 * tree.c (commutative_ternary_tree_code, add_expr): Likewise.
22995 * fold-const-call.h (fold_fma): Delete.
22996 * fold-const-call.c (fold_const_call_ssss): Handle CFN_FMS,
22997 CFN_FNMA and CFN_FNMS.
22998 (fold_fma): Delete.
22999 * genmatch.c (combined_fn): New enum.
23000 (commutative_ternary_tree_code): Remove FMA_EXPR handling.
23001 (commutative_op): New function.
23002 (commutate): Use it. Handle more than 2 operands.
23003 (dt_operand::gen_gimple_expr): Use commutative_op.
23004 (parser::parse_expr): Allow :c to be used with non-binary
23005 operators if the commutative operand is known.
23006 * gimple-ssa-backprop.c (backprop::process_builtin_call_use): Handle
23007 CFN_FMS, CFN_FNMA and CFN_FNMS.
23008 (backprop::process_assign_use): Remove FMA_EXPR handling.
23009 * hsa-gen.c (gen_hsa_insns_for_operation_assignment): Likewise.
23010 (gen_hsa_fma): New function.
23011 (gen_hsa_insn_for_internal_fn_call): Use it for IFN_FMA, IFN_FMS,
23012 IFN_FNMA and IFN_FNMS.
23013 * match.pd: Add folds for IFN_FMS, IFN_FNMA and IFN_FNMS.
23014 * gimple-fold.h (follow_all_ssa_edges): Declare.
23015 * gimple-fold.c (follow_all_ssa_edges): New function.
23016 * tree-ssa-math-opts.c (convert_mult_to_fma_1): Use the
23017 gimple_build interface and use follow_all_ssa_edges to fold the result.
23018 (convert_mult_to_fma): Use direct_internal_fn_suppoerted_p
23019 instead of checking for optabs directly.
23020 * config/i386/i386.c (ix86_add_stmt_cost): Recognize FMAs as calls
23021 rather than FMA_EXPRs.
23022 * config/rs6000/rs6000.c (rs6000_gimple_fold_builtin): Create a
23023 call to IFN_FMA instead of an FMA_EXPR.
23024
23025 2018-05-17 Jim Wilson <jimw@sifive.com>
23026
23027 * expr.c (do_tablejump): When converting index to Pmode, if we have a
23028 sign extended promoted subreg, and the range does not have the sign bit
23029 set, then do a sign extend.
23030
23031 * config/riscv/riscv.c (riscv_extend_comparands): In unsigned QImode
23032 test, check for sign extended subreg and/or constant operands, and
23033 do a sign extend in that case.
23034
23035 2018-05-17 Steve Ellcey <sellcey@cavium.com>
23036
23037 * config/aarch64/thunderx2t99.md (thunderx2t99_ls_both): Delete.
23038 (thunderx2t99_multiple): Delete psuedo-units from used cpus.
23039 Add untyped.
23040 (thunderx2t99_alu_shift): Remove alu_shift_reg, alus_shift_reg.
23041 Change logics_shift_reg to logics_shift_imm.
23042 (thunderx2t99_fp_loadpair_basic): Delete.
23043 (thunderx2t99_fp_storepair_basic): Delete.
23044 (thunderx2t99_asimd_int): Add neon_sub and neon_sub_q types.
23045 (thunderx2t99_asimd_polynomial): Delete.
23046 (thunderx2t99_asimd_fp_simple): Add neon_fp_mul_s_scalar_q
23047 and neon_fp_mul_d_scalar_q.
23048 (thunderx2t99_asimd_fp_conv): Add *int_to_fp* types.
23049 (thunderx2t99_asimd_misc): Delete neon_dup and neon_dup_q.
23050 (thunderx2t99_asimd_recip_step): Add missing *sqrt* types.
23051 (thunderx2t99_asimd_lut): Add missing tbl types.
23052 (thunderx2t99_asimd_ext): Delete.
23053 (thunderx2t99_asimd_load1_1_mult): Delete.
23054 (thunderx2t99_asimd_load1_2_mult): Delete.
23055 (thunderx2t99_asimd_load1_ldp): New.
23056 (thunderx2t99_asimd_load1): New.
23057 (thunderx2t99_asimd_load2): Add missing *load2* types.
23058 (thunderx2t99_asimd_load3): New.
23059 (thunderx2t99_asimd_load4): New.
23060 (thunderx2t99_asimd_store1_1_mult): Delete.
23061 (thunderx2t99_asimd_store1_2_mult): Delete.
23062 (thunderx2t99_asimd_store2_mult): Delete.
23063 (thunderx2t99_asimd_store2_onelane): Delete.
23064 (thunderx2t99_asimd_store_stp): New.
23065 (thunderx2t99_asimd_store1): New.
23066 (thunderx2t99_asimd_store2): New.
23067 (thunderx2t99_asimd_store3): New.
23068 (thunderx2t99_asimd_store4): New.
23069
23070 2018-05-17 Jerome Lambourg <lambourg@adacore.com>
23071
23072 * config/arm/arm_cmse.h (cmse_nsfptr_create, cmse_is_nsfptr): Remove
23073 #include <stdint.h>. Replace intptr_t with __INTPTR_TYPE__.
23074
23075 2018-05-17 Pat Haugen <pthaugen@us.ibm.com>
23076 Segher Boessenkool <segher@kernel.crashing.org>
23077
23078 PR target/85698
23079 * config/rs6000/rs6000.c (rs6000_output_move_128bit): Check dest
23080 operand.
23081
23082 2018-05-17 Richard Biener <rguenther@suse.de>
23083
23084 * tree-ssa-dse.c (dse_classify_store): Fix iterator increment
23085 for pruning loop and prune defs feeding only already visited PHIs.
23086
23087 2018-05-17 Richard Biener <rguenther@suse.de>
23088
23089 * tree-ssa-sccvn.c (vn_reference_lookup_3): Improve memset handling.
23090
23091 2018-05-17 Bin Cheng <bin.cheng@arm.com>
23092 Richard Biener <rguenther@suse.de>
23093
23094 PR tree-optimization/85793
23095 * tree-vect-stmts.c (vectorizable_load): Handle 1 element-wise load
23096 for VMAT_ELEMENTWISE.
23097
23098 2018-05-17 Richard Sandiford <richard.sandiford@linaro.org>
23099
23100 * internal-fn.h (lookup_internal_fn): Declare
23101 * internal-fn.c (lookup_internal_fn): New function.
23102 * gimple.c (gimple_build_call_from_tree): Handle calls to
23103 internal functions.
23104 * gimple-pretty-print.c (dump_gimple_call): Print "." before
23105 internal function names.
23106 * tree-pretty-print.c (dump_generic_node): Likewise.
23107 * tree-ssa-scopedtables.c (expr_hash_elt::print): Likewise.
23108
23109 2018-05-17 Richard Sandiford <richard.sandiford@linaro.org>
23110
23111 * gimple-fold.h (gimple_build): Make the function forms take
23112 combined_fn rather than built_in_function.
23113 (gimple_simplify): Likewise.
23114 * gimple-match-head.c (gimple_simplify): Likewise.
23115 * gimple-fold.c (gimple_build): Likewise.
23116 * tree-vect-loop.c (get_initial_def_for_reduction): Use gimple_build
23117 rather than gimple_build_call_internal.
23118 (get_initial_defs_for_reduction): Likewise.
23119 (vect_create_epilog_for_reduction): Likewise.
23120 (vectorizable_live_operation): Likewise.
23121
23122 2018-05-17 Martin Liska <mliska@suse.cz>
23123
23124 * gimple-ssa-sprintf.c (format_directive): Do not use
23125 space in between 'G_' and '('.
23126
23127 2018-05-17 Jakub Jelinek <jakub@redhat.com>
23128
23129 PR target/85323
23130 * config/i386/i386.c (ix86_fold_builtin): Handle masked shifts
23131 even if the mask is not all ones.
23132
23133 PR target/85323
23134 * config/i386/i386.c (ix86_fold_builtin): Fold shift builtins by
23135 vector.
23136 (ix86_gimple_fold_builtin): Likewise.
23137
23138 PR target/85323
23139 * config/i386/i386.c: Include tree-vector-builder.h.
23140 (ix86_vector_shift_count): New function.
23141 (ix86_fold_builtin): Fold shift builtins by scalar count.
23142 (ix86_gimple_fold_builtin): Likewise.
23143
23144 * config/i386/avx512fintrin.h (_mm512_set_epi16, _mm512_set_epi8,
23145 _mm512_setzero): New intrinsics.
23146
23147 2018-05-17 James Greenhalgh <james.greenhalgh@arm.com>
23148 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
23149
23150 * config/aarch64/aarch64.c (aarch64_expand_vector_init): Modify
23151 code generation for cases where splatting a value is not useful.
23152 * simplify-rtx.c (simplify_ternary_operation): Simplify
23153 vec_merge across a vec_duplicate and a paradoxical subreg forming
23154 a vector mode to a vec_concat.
23155
23156 2018-05-17 Olga Makhotina <olga.makhotina@intel.com>
23157
23158 * config.gcc: Support "goldmont-plus".
23159 * config/i386/driver-i386.c (host_detect_local_cpu): Detect
23160 "goldmont-plus".
23161 * config/i386/i386-c.c (ix86_target_macros_internal): Handle
23162 PROCESSOR_GOLDMONT_PLUS.
23163 * config/i386/i386.c (m_GOLDMONT_PLUS): Define.
23164 (processor_target_table): Add "goldmont-plus".
23165 (PTA_GOLDMONT_PLUS): Define.
23166 (ix86_lea_outperforms): Add TARGET_GOLDMONT_PLUS.
23167 (get_builtin_code_for_version): Handle PROCESSOR_GOLDMONT_PLUS.
23168 (fold_builtin_cpu): Add M_INTEL_GOLDMONT_PLUS.
23169 (fold_builtin_cpu): Add "goldmont-plus".
23170 (ix86_add_stmt_cost): Add TARGET_GOLDMONT_PLUS.
23171 (ix86_option_override_internal): Add "goldmont-plus".
23172 * config/i386/i386.h (processor_costs): Define TARGET_GOLDMONT_PLUS.
23173 (processor_type): Add PROCESSOR_GOLDMONT_PLUS.
23174 * config/i386/x86-tune.def: Add m_GOLDMONT_PLUS.
23175 * doc/invoke.texi: Add goldmont-plus as x86 -march=/-mtune= CPU type.
23176
23177 2018-05-17 Richard Biener <rguenther@suse.de>
23178
23179 PR tree-optimization/85757
23180 * tree-ssa-dse.c (dse_classify_store): Record a PHI def and
23181 remove defs that only feed that PHI from further processing.
23182
23183 2018-05-16 Jim Wilson <jimw@sifive.com>
23184
23185 * config/riscv/riscv.md (<optab>si3_mask, <optab>si3_mask_1): Prepend
23186 asterisk to name.
23187 (<optab>di3_mask, <optab>di3_mask_1): Likewise.
23188
23189 2018-05-16 Mark Wielaard <mark@klomp.org>
23190
23191 * dwarf2out.c (count_index_strings): New function.
23192 (output_indirect_strings): Call count_index_strings and generate
23193 header for dwarf_version >= 5.
23194
23195 2018-05-16 Mark Wielaard <mark@klomp.org>
23196
23197 * dwarf2out.c (dwarf_FORM): New function.
23198 (set_indirect_string): Use dwarf_FORM.
23199 (reset_indirect_string): Likewise.
23200 (size_of_die): Likewise.
23201 (value_format): Likewise.
23202 (output_die): Likewise.
23203 (add_skeleton_AT_string): Likewise.
23204 (output_macinfo_op): Likewise.
23205 (index_string): Likewise.
23206 (output_index_string_offset): Likewise.
23207 (output_index_string): Likewise.
23208 (count_index_strings): Likewise.
23209
23210 2018-05-16 Carl Love <cel@us.ibm.com>
23211
23212 * config/rs6000/rs6000.md (prefetch): Generate ISA 2.06 instructions
23213 dcbt and dcbtstt with TH=16 if operands[2] is 0 and Power 8 or newer.
23214
23215 2018-05-16 Martin Jambor <mjambor@suse.cz>
23216
23217 * ipa-prop.c (ipa_free_all_edge_args): Remove.
23218 * ipa-prop.h (ipa_free_all_edge_args): Likewise.
23219
23220 2018-05-16 Wilco Dijkstra <wdijkstr@arm.com>
23221
23222 * config/aarch64/aarch64.md (fma<mode>4): Change into expand pattern.
23223 (fnma<mode>4): Likewise.
23224 (fms<mode>4): Likewise.
23225 (fnms<mode>4): Likewise.
23226 (aarch64_fma<mode>4): Rename insn, reorder accumulator operand.
23227 (aarch64_fnma<mode>4): Likewise.
23228 (aarch64_fms<mode>4): Likewise.
23229 (aarch64_fnms<mode>4): Likewise.
23230 (aarch64_fnmadd<mode>4): Likewise.
23231
23232 2018-05-16 Jason Merrill <jason@redhat.com>
23233
23234 * tree.c (warn_deprecated_use): Return bool. Simplify logic.
23235
23236 2018-05-16 Richard Biener <rguenther@suse.de>
23237
23238 * tree-vectorizer.h (struct stmt_info_for_cost): Add where member.
23239 (dump_stmt_cost): Declare.
23240 (add_stmt_cost): Dump cost we add.
23241 (add_stmt_costs): New function.
23242 (vect_model_simple_cost, vect_model_store_cost, vect_model_load_cost):
23243 No longer exported.
23244 (vect_analyze_stmt): Adjust prototype.
23245 (vectorizable_condition): Likewise.
23246 (vectorizable_live_operation): Likewise.
23247 (vectorizable_reduction): Likewise.
23248 (vectorizable_induction): Likewise.
23249 * tree-vect-loop.c (vect_analyze_loop_operations): Create local
23250 cost vector to pass to vectorizable_ and record afterwards.
23251 (vect_model_reduction_cost): Take cost vector argument and adjust.
23252 (vect_model_induction_cost): Likewise.
23253 (vectorizable_reduction): Likewise.
23254 (vectorizable_induction): Likewise.
23255 (vectorizable_live_operation): Likewise.
23256 * tree-vect-slp.c (vect_create_new_slp_node): Initialize
23257 SLP_TREE_NUMBER_OF_VEC_STMTS.
23258 (vect_analyze_slp_cost_1): Remove.
23259 (vect_analyze_slp_cost): Likewise.
23260 (vect_slp_analyze_node_operations): Take visited args and
23261 a target cost vector. Avoid processing already visited stmt sets.
23262 (vect_slp_analyze_operations): Use a local cost vector to gather
23263 costs and register those of non-discarded instances.
23264 (vect_bb_vectorization_profitable_p): Use add_stmt_costs.
23265 (vect_schedule_slp_instance): Remove copying of
23266 SLP_TREE_NUMBER_OF_VEC_STMTS. Instead assert that it is not
23267 zero.
23268 * tree-vect-stmts.c (record_stmt_cost): Remove path directly
23269 adding cost. Record cost entry location.
23270 (vect_prologue_cost_for_slp_op): Function to compute cost of
23271 a constant or invariant generated for SLP vect in the prologue,
23272 split out from vect_analyze_slp_cost_1.
23273 (vect_model_simple_cost): Make static. Adjust for SLP costing.
23274 (vect_model_promotion_demotion_cost): Likewise.
23275 (vect_model_store_cost): Likewise, make static.
23276 (vect_model_load_cost): Likewise.
23277 (vectorizable_bswap): Add cost vector arg and adjust.
23278 (vectorizable_call): Likewise.
23279 (vectorizable_simd_clone_call): Likewise.
23280 (vectorizable_conversion): Likewise.
23281 (vectorizable_assignment): Likewise.
23282 (vectorizable_shift): Likewise.
23283 (vectorizable_operation): Likewise.
23284 (vectorizable_store): Likewise.
23285 (vectorizable_load): Likewise.
23286 (vectorizable_condition): Likewise.
23287 (vectorizable_comparison): Likewise.
23288 (can_vectorize_live_stmts): Likewise.
23289 (vect_analyze_stmt): Likewise.
23290 (vect_transform_stmt): Adjust calls to vectorizable_*.
23291 * tree-vectorizer.c: Include gimple-pretty-print.h.
23292 (dump_stmt_cost): New function.
23293
23294 2018-05-16 Richard Biener <rguenther@suse.de>
23295
23296 * params.def (PARAM_DSE_MAX_ALIAS_QUERIES_PER_STORE): New param.
23297 * doc/invoke.texi (dse-max-alias-queries-per-store): Document.
23298 * tree-ssa-dse.c: Include tree-ssa-loop.h.
23299 (check_name): New callback.
23300 (dse_classify_store): Track cycles via a visited bitmap of PHI
23301 defs and simplify handling of in-loop and across loop dead stores
23302 and properly fail for loop-variant refs. Handle byte-tracking with
23303 multiple defs. Use PARAM_DSE_MAX_ALIAS_QUERIES_PER_STORE for
23304 limiting the walk.
23305
23306 2018-05-16 Richard Sandiford <richard.sandiford@linaro.org>
23307
23308 * tree-vectorizer.h (vect_get_vector_types_for_stmt): Declare.
23309 (vect_get_mask_type_for_stmt): Likewise.
23310 * tree-vect-slp.c (vect_two_operations_perm_ok_p): New function,
23311 split out from...
23312 (vect_build_slp_tree_1): ...here. Use vect_get_vector_types_for_stmt
23313 to determine the statement's vector type and the vector type that
23314 should be used for calculating nunits. Deal with cases in which
23315 the type has to be deferred.
23316 (vect_slp_analyze_node_operations): Use vect_get_vector_types_for_stmt
23317 and vect_get_mask_type_for_stmt to calculate STMT_VINFO_VECTYPE.
23318 * tree-vect-loop.c (vect_determine_vf_for_stmt_1)
23319 (vect_determine_vf_for_stmt): New functions, split out from...
23320 (vect_determine_vectorization_factor): ...here.
23321 * tree-vect-stmts.c (vect_get_vector_types_for_stmt)
23322 (vect_get_mask_type_for_stmt): New functions, split out from
23323 vect_determine_vectorization_factor.
23324
23325 2018-05-16 Richard Biener <rguenther@suse.de>
23326
23327 * tree-cfg.c (verify_gimple_assign_ternary): Properly
23328 verify the [VEC_]COND_EXPR embedded comparison.
23329
23330 2018-05-15 Martin Sebor <msebor@redhat.com>
23331
23332 PR tree-optimization/85753
23333 * gimple-ssa-warn-restrict.c (builtin_memref::builtin_memref): Handle
23334 RECORD_TYPE in addition to ARRAY_TYPE.
23335
23336 2018-05-15 Martin Sebor <msebor@redhat.com>
23337
23338 PR middle-end/85643
23339 * calls.c (get_attr_nonstring_decl): Handle MEM_REF.
23340
23341 2018-05-15 Richard Biener <rguenther@suse.de>
23342
23343 * tree-ssa-dse.c (dse_classify_store): Remove use_stmt parameter,
23344 add by_clobber_p one. Change algorithm to collect all defs
23345 representing uses we need to walk and try reducing them to
23346 a single one before failing.
23347 (dse_dom_walker::dse_optimize_stmt): Adjust.
23348
23349 2018-05-13 Mark Wielaard <mark@klomp.org>
23350
23351 * dwarf2out.c (dwarf_OP): Handle DW_OP_addrx and DW_OP_constx.
23352 (size_of_loc_descr): Likewise.
23353 (output_loc_operands): Likewise.
23354 (output_loc_operands_raw): Likewise.
23355 (dw_addr_op): Use dwarf_OP () for DW_OP_constx and DW_OP_addrx.
23356 (resolve_addr_in_expr): Handle DW_OP_addrx and DW_OP_constx.
23357 (hash_loc_operands): Likewise.
23358 (compare_loc_operands): Likewise.
23359
23360 2018-05-14 Mark Wielaard <mark@klomp.org>
23361
23362 * dwarf2out.c (count_index_addrs): New function.
23363 (dwarf2out_finish): Use count_index_addrs to calculate addrs_length.
23364
23365 2018-05-15 Prathamesh Kulkarni <prathamesh.kulkarni@linaro.org>
23366
23367 PR tree-optimization/83648
23368 * ipa-pure-const.c (malloc_candidate_p): Allow function with NULL
23369 return value as malloc candidate.
23370
23371 2018-05-15 Prathamesh Kulkarni <prathamesh.kulkarni@linaro.org>
23372
23373 PR ipa/85734
23374 * ipa-pure-const.c (warn_function_malloc): Pass value of known_finite
23375 param as true in call to suggest_attribute.
23376
23377 2018-05-14 Segher Boessenkool <segher@kernel.crashing.org>
23378
23379 * doc/invoke.texi (RS/6000 and PowerPC Options): Delete @itemx for
23380 -mreadonly-in-sdata.
23381
23382 2018-05-14 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
23383
23384 * config/aarch64/aarch64-simd.md (*aarch64_crypto_aese_fused):
23385 New pattern.
23386 (aarch64_crypto_aesd_fused): Likewise.
23387
23388 2018-05-14 Wilco Dijkstra <wdijkstr@arm.com>
23389
23390 * config/aarch64/aarch64.md (mov<mode>): Remove '*' in alternatives.
23391 (movsi_aarch64): Likewise.
23392 (load_pairsi): Likewise.
23393 (load_pairdi): Likewise.
23394 (store_pairsi): Likewise.
23395 (store_pairdi): Likewise.
23396 (load_pairsf): Likewise.
23397 (load_pairdf): Likewise.
23398 (store_pairsf): Likewise.
23399 (store_pairdf): Likewise.
23400 (zero_extend): Likewise.
23401 (trunc): Swap alternatives.
23402 (fcvt_target): Add '?' to prefer w over r.
23403
23404 2018-05-14 Jakub Jelinek <jakub@redhat.com>
23405
23406 PR target/85756
23407 * config/i386/i386.md: Disallow non-commutative arithmetics in
23408 last twpeephole for mem {+,-,&,|,^}= x; mem != 0 after cmpelim
23409 optimization. Use COMMUTATIVE_ARITH_P test rather than != MINUS
23410 in the peephole2 before it.
23411
23412 2018-05-14 Sebastian Peryt <sebastian.peryt@intel.com>
23413
23414 * common/config/i386/i386-common.c (OPTION_MASK_ISA_CLDEMOTE_SET,
23415 OPTION_MASK_ISA_CLDEMOTE_UNSET): New defines.
23416 (ix86_handle_option): Handle -mcldemote.
23417 * config.gcc: New header.
23418 * config/i386/cldemoteintrin.h: New file.
23419 * config/i386/cpuid.h (bit_CLDEMOTE): New bit.
23420 * config/i386/driver-i386.c (host_detect_local_cpu): Detect
23421 -mcldemote.
23422 * config/i386/i386-c.c (ix86_target_macros_internal): Handle
23423 OPTION_MASK_ISA_CLDEMOTE.
23424 * config/i386/i386.c (ix86_target_string): Add -mcldemote.
23425 (ix86_valid_target_attribute_inner_p): Ditto.
23426 (enum ix86_builtins): Add IX86_BUILTIN_CLDEMOTE.
23427 (ix86_init_mmx_sse_builtins): Define __builtin_ia32_cldemote.
23428 (ix86_expand_builtin): Expand IX86_BUILTIN_CLDEMOTE.
23429 * config/i386/i386.h (TARGET_CLDEMOTE, TARGET_CLDEMOTE_P): New.
23430 * config/i386/i386.md (UNSPECV_CLDEMOTE): New.
23431 (cldemote): New.
23432 * config/i386/i386.opt: Add -mcldemote.
23433 * config/i386/x86intrin.h: New header.
23434 * doc/invoke.texi: Add -mcldemote.
23435
23436 2018-05-14 Richard Biener <rguenther@suse.de>
23437
23438 * doc/match-and-simplify.texi: Adjust :s documentation.
23439
23440 2018-05-14 Alexander Monakov <amonakov@ispras.ru>
23441
23442 * sort.cc (REORDER_23): Pass the type for the temporaries instead of
23443 intended memcpy size.
23444 (REORDER_45): Likewise.
23445
23446 2018-05-13 Alexander Monakov <amonakov@ispras.ru>
23447
23448 * sort.cc: New file.
23449 * system.h [!CHECKING_P] (qsort): Redirect to gcc_qsort.
23450 * vec.c (qsort_chk): Use gcc_qsort.
23451 * Makefile.in (OBJS-libcommon): Add sort.o.
23452 (build/sort.o): New target. Use it...
23453 (BUILD_RTL): ... here, and...
23454 (build/gencfn-macros): ... here, and...
23455 (build/genmatch): ... here.
23456
23457 2018-05-13 Kito Cheng <kito.cheng@gmail.com>
23458 Chung-Ju Wu <jasonwucj@gmail.com>
23459
23460 * config.gcc (nds32*-*-*): Check that n15 is valid to --with-cpu.
23461 * config/nds32/nds32-graywolf.md: New file.
23462 * config/nds32/nds32-opts.h (nds32_cpu_type): Add CPU_GRAYWOLF.
23463 * config/nds32/nds32-pipelines-auxiliary.c: Implementation for n15
23464 pipeline.
23465 * config/nds32/nds32-protos.h: More declarations for n15 pipeline.
23466 * config/nds32/nds32-utils.c: More implementations for n15 pipeline.
23467 * config/nds32/nds32.md (pipeline_model): Add graywolf.
23468 * config/nds32/nds32.opt (mcpu): Support n15 pipeline cpus.
23469 * config/nds32/pipelines.md: Include n15 settings.
23470
23471 2018-05-13 Kito Cheng <kito.cheng@gmail.com>
23472 Chung-Ju Wu <jasonwucj@gmail.com>
23473
23474 * config.gcc (nds32*-*-*): Check that n12/n13 are valid to --with-cpu.
23475 * config/nds32/nds32-n13.md: New file.
23476 * config/nds32/nds32-opts.h (nds32_cpu_type): Add CPU_N12 and CPU_N13.
23477 * config/nds32/nds32-pipelines-auxiliary.c: Implementation for n12/n13
23478 pipeline.
23479 * config/nds32/nds32-protos.h: More declarations for n12/n13 pipeline.
23480 * config/nds32/nds32.md (pipeline_model): Add n13.
23481 * config/nds32/nds32.opt (mcpu): Support n12/n13 pipeline cpus.
23482 * config/nds32/pipelines.md: Include n13 settings.
23483
23484 2018-05-13 Kito Cheng <kito.cheng@gmail.com>
23485 Chung-Ju Wu <jasonwucj@gmail.com>
23486
23487 * config.gcc (nds32*-*-*): Check that n10/d10 are valid to --with-cpu.
23488 * config/nds32/nds32-n10.md: New file.
23489 * config/nds32/nds32-opts.h (nds32_cpu_type): Add CPU_N10.
23490 * config/nds32/nds32-pipelines-auxiliary.c: Implementation for n10
23491 pipeline.
23492 * config/nds32/nds32-protos.h: More declarations for n10 pipeline.
23493 * config/nds32/nds32-utils.c: More implementations for n10 pipeline.
23494 * config/nds32/nds32.md (pipeline_model): Add n10.
23495 * config/nds32/nds32.opt (mcpu): Support n10 pipeline cpus.
23496 * config/nds32/pipelines.md: Include n10 settings.
23497
23498 2018-05-13 Monk Chiang <sh.chiang04@gmail.com>
23499 Kito Cheng <kito.cheng@gmail.com>
23500 Chung-Ju Wu <jasonwucj@gmail.com>
23501
23502 * config.gcc (nds32be-*-*): Handle --with-ext-dsp.
23503 * config/nds32/constants.md (unspec_element, unspec_volatile_element):
23504 Add enum values for DSP extension instructions.
23505 * config/nds32/constraints.md (Iu06, IU06, CVp5, CVs5, CVs2, CVhi):
23506 New constraints.
23507 * config/nds32/iterators.md (shifts, shiftrt, sat_plus, all_plus,
23508 sat_minus, all_minus, plus_minus, extend, sumax, sumin, sumin_max):
23509 New code iterators.
23510 (su, zs, uk, opcode, add_rsub, add_sub): New code attributes.
23511 * config/nds32/nds32-dspext.md: New file for DSP implementation.
23512 * config/nds32/nds32-intrinsic.c: Implementation of DSP extension.
23513 * config/nds32/nds32-intrinsic.md: Likewise.
23514 * config/nds32/nds32_intrinsic.h: Likewise.
23515 * config/nds32/nds32-md-auxiliary.c: Likewise.
23516 * config/nds32/nds32-memory-manipulation.c: Consider DSP extension.
23517 * config/nds32/nds32-predicates.c (const_vector_to_hwint): New.
23518 (nds32_valid_CVp5_p, nds32_valid_CVs5_p): New.
23519 (nds32_valid_CVs2_p, nds32_valid_CVhi_p): New.
23520 * config/nds32/nds32-protos.h: New declarations for DSP extension.
23521 * config/nds32/nds32-utils.c (extract_mac_non_acc_rtx): New case
23522 TYPE_DMAC in switch statement.
23523 * config/nds32/nds32.c: New checking and implementation for DSP
23524 extension instructions.
23525 * config/nds32/nds32.h: Likewise.
23526 * config/nds32/nds32.md: Likewise.
23527 * config/nds32/nds32.opt (mhw-abs, mext-dsp): New options.
23528 * config/nds32/predicates.md: Implement new predicates for DSP
23529 extension.
23530
23531 2018-05-11 Michael Meissner <meissner@linux.vnet.ibm.com>
23532
23533 * config/rs6000/rs6000.md (mov<mode>_softfloat, FMOVE32):
23534 Reformat alternatives and attributes so it is easier to identify
23535 which constraints/attributes go with which instruction.
23536 (mov<mode>_hardfloat32, FMOVE64): Likewise.
23537 (mov<mode>_softfloat32, FMOVE64): Likewise.
23538 (mov<mode>_hardfloat64, FMOVE64): Likewise.
23539 (mov<mode>_softfloat64, FMOVE64): Likewise.
23540
23541 2018-05-11 Kelvin Nilsen <kelvin@gcc.gnu.org>
23542
23543 * doc/extend.texi (PowerPC Built-in Functions): Rename this
23544 subsection.
23545 (Basic PowerPC Built-in Functions): The new name of the
23546 subsection previously known as "PowerPC Built-in Functions".
23547 (Basic PowerPC Built-in Functions Available on all Configurations):
23548 New subsubsection.
23549 (Basic PowerPC Built-in Functions Available on ISA 2.05): Likewise.
23550 (Basic PowerPC Built-in Functions Available on ISA 2.06): Likewise.
23551 (Basic PowerPC Built-in Functions Available on ISA 2.07): Likewise.
23552 (Basic PowerPC Built-in Functions Available on ISA 3.0): Likewise.
23553
23554 2018-05-11 Martin Jambor <mjambor@suse.cz>
23555
23556 PR ipa/85655
23557 * ipa-cp.c (intersect_with_plats): Check that the lattice contains
23558 single const.
23559
23560 2018-05-11 Richard Earnshaw <rearnsha@arm.com>
23561
23562 PR target/85733
23563 * config/arm/arm-cpus.in (fgroup ARMv6m): Add be8 feature.
23564
23565 2018-05-11 Sebastian Peryt <sebastian.peryt@intel.com>
23566
23567 * common/config/i386/i386-common.c (OPTION_MASK_ISA_WAITPKG_SET,
23568 OPTION_MASK_ISA_WAITPKG_UNSET): New defines.
23569 (ix86_handle_option): Handle -mwaitpkg.
23570 * config.gcc: New header.
23571 * config/i386/cpuid.h (bit_WAITPKG): New bit.
23572 * config/i386/driver-i386.c (host_detect_local_cpu): Detect -mwaitpkg.
23573 * config/i386/i386-builtin-types.def ((UINT8, UNSIGNED, UINT64)): New
23574 function type.
23575 * config/i386/i386-c.c (ix86_target_macros_internal): Handle
23576 OPTION_MASK_ISA_WAITPKG.
23577 * config/i386/i386.c (ix86_target_string): Add -mwaitpkg.
23578 (ix86_option_override_internal): Add PTA_WAITPKG.
23579 (ix86_valid_target_attribute_inner_p): Add -mwaitpkg.
23580 (enum ix86_builtins): Add IX86_BUILTIN_UMONITOR, IX86_BUILTIN_UMWAIT,
23581 IX86_BUILTIN_TPAUSE.
23582 (ix86_init_mmx_sse_builtins): Define __builtin_ia32_umonitor,
23583 __builtin_ia32_umwait and __builtin_ia32_tpause.
23584 (ix86_expand_builtin): Expand IX86_BUILTIN_UMONITOR,
23585 IX86_BUILTIN_UMWAIT, IX86_BUILTIN_TPAUSE.
23586 * config/i386/i386.h (TARGET_WAITPKG, TARGET_WAITPKG_P): New.
23587 * config/i386/i386.md (UNSPECV_UMWAIT, UNSPECV_UMONITOR,
23588 UNSPECV_TPAUSE): New.
23589 (umwait, umwait_rex64, umonitor_<mode>, tpause, tpause_rex64): New.
23590 * config/i386/i386.opt: Add -mwaitpkg.
23591 * config/i386/waitpkgintrin.h: New file.
23592 * config/i386/x86intrin.h: New header.
23593 * doc/invoke.texi: Add -mwaitpkg.
23594
23595 2018-05-11 Richard Earnshaw <rearnsha@arm.com>
23596
23597 PR target/85606
23598 * config/arm/arm-cpus.in: Add comment that ARMv6-m and ARMv6S-m are now
23599 equivalent.
23600 (cortex-m0): Use armv6s-m isa.
23601 (cortex-m0plus): Likewise.
23602 (cortex-m1): Likewise.
23603 (cortex-m0.small-multiply): Likewise.
23604 (cortex-m0plus.small-multiply): Likewise.
23605 (cortex-m1.small-multiply): Likewise.
23606
23607 2018-05-11 Allan Sandfeld Jensen <allan.jensen@qt.io>
23608 Jakub Jelinek <jakub@redhat.com>
23609
23610 PR tree-optimization/85692
23611 * tree-ssa-forwprop.c (simplify_vector_constructor): Try two
23612 source permute as well.
23613
23614 2018-05-11 Martin Liska <mliska@suse.cz>
23615
23616 PR sanitizer/85556
23617 * doc/extend.texi: Document LLVM style format for no_sanitize
23618 attribute.
23619
23620 2018-05-10 Michael Meissner <meissner@linux.vnet.ibm.com>
23621
23622 * config/rs6000/rs6000.c (mode_supports_dq_form): Rename
23623 mode_supports_vsx_dform_quad to mode_supports_dq_form.
23624 (mode_supports_vsx_dform_quad): Likewise.
23625 (mode_supports_vmx_dform): Move these functions to be next to the
23626 other mode_supports functions.
23627 (mode_supports_dq_form): Likewise.
23628 (quad_address_p): Change calls of mode_supports_vsx_dform_quad to
23629 mode_supports_dq_form.
23630 (reg_offset_addressing_ok_p): Likewise.
23631 (offsettable_ok_by_alignment): Likewise.
23632 (rs6000_legitimate_offset_address_p): Likewise.
23633 (legitimate_lo_sum_address_p): Likewise.
23634 (rs6000_legitimize_address): Likewise.
23635 (rs6000_legitimize_reload_address): Likewise.
23636 (rs6000_secondary_reload_inner): Likewise.
23637 (rs6000_preferred_reload_class): Likewise.
23638 (rs6000_output_move_128bit): Likewise.
23639
23640 2018-05-10 Uros Bizjak <ubizjak@gmail.com>
23641
23642 * config/i386/i386.c (ix86_expand_builtin) <case IX86_BUILTIN_RDPID>:
23643 Generate SImode target register for null target.
23644 <case IX86_BUILTIN_XGETBV>: Ditto.
23645 <case IX86_BUILTIN_XSETBV>: Optimize LSHIFTRT generation.
23646 * config/i386/xsaveintrin.h (_xgetbv): Add missing return.
23647
23648 2018-05-10 Carl Love <cel@us.ibm.com>
23649
23650 * config/rs6000/rs6000.md (prefetch): Generate ISA 2.06 instructions
23651 dcbtt and dcbtstt if operands[2] is 0.
23652
23653 2018-05-10 Uros Bizjak <ubizjak@gmail.com>
23654
23655 PR target/85693
23656 * config/i386/sse.md (usadv64qi): New expander.
23657
23658 2018-05-10 Segher Boessenkool <segher@kernel.crashing.org>
23659
23660 * config/rs6000/altivec.md (altivec_vmrghb, altivec_vmrghh,
23661 altivec_vmrghw, altivec_vmrglb, altivec_vmrglh, altivec_vmrglw): Remove
23662 -maltivec=be support.
23663 (vec_widen_umult_even_v16qi, vec_widen_smult_even_v16qi,
23664 vec_widen_umult_even_v8hi, vec_widen_smult_even_v8hi,
23665 vec_widen_umult_even_v4si, vec_widen_smult_even_v4si,
23666 vec_widen_umult_odd_v16qi, vec_widen_smult_odd_v16qi,
23667 vec_widen_umult_odd_v8hi, vec_widen_smult_odd_v8hi,
23668 vec_widen_umult_odd_v4si, vec_widen_smult_odd_v4si, altivec_vpkpx,
23669 altivec_vpks<VI_char>ss, altivec_vpks<VI_char>us,
23670 altivec_vpku<VI_char>us, altivec_vpku<VI_char>um, altivec_vsum2sws,
23671 altivec_vsumsws): Adjust.
23672 (altivec_vspltb *altivec_vspltb_internal, altivec_vsplth,
23673 *altivec_vsplth_internal, altivec_vspltw, *altivec_vspltw_internal,
23674 altivec_vspltsf, *altivec_vspltsf_internal): Remove -maltivec=be
23675 support.
23676 (altivec_vperm_<mode>, altivec_vperm_<mode>_uns,
23677 altivec_vupkhs<VU_char>, altivec_vupkls<VU_char>, altivec_vupkhpx,
23678 altivec_vupklpx, altivec_lvsl, altivec_lvsr): Adjust.
23679 (altivec_lve<VI_char>x): Delete expand.
23680 (*altivec_lve<VI_char>x_internal): Rename to...
23681 (altivec_lve<VI_char>x): ... this.
23682 (altivec_lvxl_<mode>): Delete expand.
23683 (*altivec_lvxl_<mode>_internal): Rename to ...
23684 (altivec_lvxl_<mode>): ... this.
23685 (altivec_stvxl_<mode>): Delete expand.
23686 (*altivec_stvxl_<mode>_internal): Rename to ...
23687 (altivec_stvxl_<mode>): ... this.
23688 (altivec_stve<VI_char>x): Delete expand.
23689 (*altivec_stve<VI_char>x_internal): Rename to ...
23690 (altivec_stve<VI_char>x): ... this.
23691 (doublee<mode>2, unsdoubleev4si2, doubleo<mode>2, unsdoubleov4si2,
23692 doubleh<mode>2, unsdoublehv4si2, doublel<mode>2, unsdoublelv4si2,
23693 reduc_plus_scal_<mode>): Adjust.
23694 * config/rs6000/rs6000-c.c (rs6000_target_modify_macros): Adjust
23695 comment.
23696 (rs6000_cpu_cpp_builtins): Adjust.
23697 (altivec_resolve_overloaded_builtin): Remove -maltivec=be support.
23698 * config/rs6000/rs6000-protos.h (altivec_expand_lvx_be,
23699 altivec_expand_stvx_be, altivec_expand_stvex_be): Delete.
23700 * config/rs6000/rs6000.c (rs6000_option_override_internal): Remove
23701 -maltivec=be support.
23702 (rs6000_split_vec_extract_var): Adjust.
23703 (rs6000_split_v4si_init): Adjust.
23704 (swap_selector_for_mode): Delete.
23705 (altivec_expand_lvx_be, altivec_expand_stvx_be,
23706 altivec_expand_stvex_be): Delete.
23707 (altivec_expand_lv_builtin, altivec_expand_stv_builtin): Remove
23708 -maltivec=be support.
23709 (rs6000_gimple_fold_builtin): Ditto.
23710 (rs6000_generate_float2_double_code, rs6000_generate_float2_code):
23711 Adjust.
23712 * config/rs6000/rs6000.h (VECTOR_ELT_ORDER_BIG): Delete.
23713 (TARGET_DIRECT_MOVE_64BIT): Adjust.
23714 * config/rs6000/rs6000.md (split for extendsidi2 for vectors): Adjust.
23715 * config/rs6000/rs6000.opt (maltivec=le, maltivec=be): Delete.
23716 * config/rs6000/vsx.md (floate<mode>, unsfloatev2di, floato<mode>,
23717 unsfloatov2di, vsignedo_v2df, vsignede_v2df, vunsignedo_v2df,
23718 vunsignede_v2df, vsx_extract_<mode>_p9, *vsx_extract_si,
23719 *vsx_extract_<mode>_p8, *vsx_extract_si_<uns>float_df,
23720 *vsx_extract_si_<uns>float_<mode>, vsx_set_<mode>_p9, vsx_set_v4sf_p9,
23721 *vsx_insert_extract_v4sf_p9, *vsx_insert_extract_v4sf_p9_2, and an
23722 anonymous split): Adjust.
23723 (vsx_mergel_<mode>, vsx_mergeh_<mode>): Remove -maltivec=be support.
23724 (vsx_xxspltd_<mode>, extract4b, insert4b): Adjust.
23725
23726 2018-05-10 Eric Botcazou <ebotcazou@adacore.com>
23727
23728 * configure.ac (gcc_gxx_include_dir_add_sysroot): Set it to 1 only
23729 when --with-gxx-include-dir is also specified.
23730 * configure: Regenerate.
23731
23732 2018-05-09 Jim Wilson <jimw@sifive.com>
23733
23734 PR target/84797
23735 * config.gcc (riscv*-*-*): Handle --with-multilib-list.
23736 * config/riscv/t-withmultilib: New.
23737 * config/riscv/withmultilib.h: New.
23738 * doc/install.texi: Document RISC-V --with-multilib-list support.
23739
23740 2018-05-09 Richard Biener <rguenther@suse.de>
23741
23742 * tree-vect-slp.c (vect_bb_slp_scalar_cost): Fill a cost
23743 vector.
23744 (vect_bb_vectorization_profitable_p): Adjust. Compute
23745 actual scalar cost using the cost vector and the add_stmt_cost
23746 machinery.
23747
23748 2018-05-09 Segher Boessenkool <segher@kernel.crashing.org>
23749
23750 PR rtl-optimization/85645
23751 * config/rs6000/rs6000.c (rs6000_emit_prologue_components): Put a SET
23752 in the REG_CFA_REGISTER note for LR, don't leave it empty.
23753
23754 2018-05-09 Segher Boessenkool <segher@kernel.crashing.org>
23755
23756 PR rtl-optimization/85645
23757 * shrink-wrap.c (spread_components): Return a boolean saying if
23758 anything was changed.
23759 (try_shrink_wrapping_separate): Iterate spread_components until
23760 nothing changes anymore.
23761
23762 2018-05-09 Segher Boessenkool <segher@kernel.crashing.org>
23763
23764 PR rtl-optimization/85645
23765 * regrename.c (build_def_use): Also kill the chains that include the
23766 destination of a REG_CFA_REGISTER note.
23767
23768 2018-05-09 Segher Boessenkool <segher@kernel.crashing.org>
23769
23770 PR rtl-optimization/85645
23771 * regcprop.c (copyprop_hardreg_forward_1): Don't propagate into an
23772 insn that has a REG_CFA_REGISTER note.
23773
23774 2018-05-09 Richard Sandiford <richard.sandiford@linaro.org>
23775
23776 * cfgexpand.c (expand_clobber): New function.
23777 (expand_gimple_stmt_1): Use it.
23778 * tree-vect-stmts.c (vect_clobber_variable): New function,
23779 split out from...
23780 (vectorizable_simd_clone_call): ...here.
23781 (vectorizable_store): Emit a clobber either side of an
23782 IFN_STORE_LANES sequence.
23783 (vectorizable_load): Emit a clobber after an IFN_LOAD_LANES sequence.
23784
23785 2018-05-09 Tom de Vries <tom@codesourcery.com>
23786
23787 PR target/85626
23788 * config/nvptx/nvptx.md (define_insn "trap", define_insn "trap_if_true")
23789 (define_insn "trap_if_false"): Add exit after trap.
23790
23791 2018-05-09 Eric Botcazou <ebotcazou@adacore.com>
23792
23793 PR rtl-optimization/85638
23794 * bb-reorder.c: Include common/common-target.h.
23795 (create_forwarder_block): New function extracted from...
23796 (fix_up_crossing_landing_pad): ...here. Rename into...
23797 (dw2_fix_up_crossing_landing_pad): ...this.
23798 (sjlj_fix_up_crossing_landing_pad): New function.
23799 (find_rarely_executed_basic_blocks_and_crossing_edges): In SJLJ mode,
23800 call sjlj_fix_up_crossing_landing_pad if there are incoming EH edges
23801 from both partitions and exit the loop after one iteration.
23802
23803 2018-05-08 Kelvin Nilsen <kelvin@gcc.gnu.org>
23804
23805 Revert:
23806 * doc/extend.texi (PowerPC Built-in Functions): Rename this
23807 subsection.
23808 (Basic PowerPC Built-in Functions): The new name of the
23809 subsection previously known as "PowerPC Built-in Functions".
23810 (Basic PowerPC Built-in Functions Available on all Configurations):
23811 New subsubsection.
23812 (Basic PowerPC Built-in Functions Available on ISA 2.05): New
23813 subsubsection.
23814 (Basic PowerPC Built-in Functions Available on ISA 2.06): New
23815 subsubsection.
23816 (Basic PowerPC Built-in Functions Available on ISA 2.07): New
23817 subsubsection.
23818 (Basic PowerPC Built-in Functions Available on ISA 3.0): New
23819 subsubsection.
23820
23821 2018-05-08 Jim Wilson <jimw@sifive.com>
23822
23823 * config/riscv/linux.h (MUSL_ABI_SUFFIX): Delete unnecessary backslash.
23824 (LD_EMUL_SUFFIX): New.
23825 (LINK_SPEC): Use it.
23826
23827 2018-05-08 Kelvin Nilsen <kelvin@gcc.gnu.org>
23828
23829 * doc/extend.texi (PowerPC Built-in Functions): Rename this
23830 subsection.
23831 (Basic PowerPC Built-in Functions): The new name of the
23832 subsection previously known as "PowerPC Built-in Functions".
23833 (Basic PowerPC Built-in Functions Available on all Configurations):
23834 New subsubsection.
23835 (Basic PowerPC Built-in Functions Available on ISA 2.05): New
23836 subsubsection.
23837 (Basic PowerPC Built-in Functions Available on ISA 2.06): New
23838 subsubsection.
23839 (Basic PowerPC Built-in Functions Available on ISA 2.07): New
23840 subsubsection.
23841 (Basic PowerPC Built-in Functions Available on ISA 3.0): New
23842 subsubsection.
23843
23844 2018-05-08 Jakub Jelinek <jakub@redhat.com>
23845
23846 PR target/85683
23847 * config/i386/i386.md: Add peepholes for mem {+,-,&,|,^}= x; mem != 0
23848 after cmpelim optimization.
23849
23850 2018-05-08 Olga Makhotina <olga.makhotina@intel.com>
23851
23852 * config.gcc: Support "goldmont".
23853 * config/i386/driver-i386.c (host_detect_local_cpu): Detect "goldmont".
23854 * config/i386/i386-c.c (ix86_target_macros_internal): Handle
23855 PROCESSOR_GOLDMONT.
23856 * config/i386/i386.c (m_GOLDMONT): Define.
23857 (processor_target_table): Add "goldmont".
23858 (PTA_GOLDMONT): Define.
23859 (ix86_lea_outperforms): Add TARGET_GOLDMONT.
23860 (get_builtin_code_for_version): Handle PROCESSOR_GOLDMONT.
23861 (fold_builtin_cpu): Add M_INTEL_GOLDMONT.
23862 (fold_builtin_cpu): Add "goldmont".
23863 (ix86_add_stmt_cost): Add TARGET_GOLDMONT.
23864 (ix86_option_override_internal): Add "goldmont".
23865 * config/i386/i386.h (processor_costs): Define TARGET_GOLDMONT.
23866 (processor_type): Add PROCESSOR_GOLDMONT.
23867 * config/i386/i386.md: Add CPU "glm".
23868 * config/i386/glm.md: New file.
23869 * config/i386/x86-tune.def: Add m_GOLDMONT.
23870 * doc/invoke.texi: Add goldmont as x86 -march=/-mtune= CPU type.
23871
23872 2018-05-08 Jakub Jelinek <jakub@redhat.com>
23873
23874 PR target/85572
23875 * config/i386/i386.c (ix86_expand_sse2_abs): Handle E_V2DImode and
23876 E_V4DImode.
23877 * config/i386/sse.md (abs<mode>2): Use VI_AVX2 iterator instead of
23878 VI1248_AVX512VL_AVX512BW. Handle V2DImode and V4DImode if not
23879 TARGET_AVX512VL using ix86_expand_sse2_abs. Formatting fixes.
23880
23881 PR target/85317
23882 * config/i386/i386.c (ix86_fold_builtin): Handle
23883 IX86_BUILTIN_{,P}MOVMSK{PS,PD,B}{,128,256}.
23884
23885 PR target/85480
23886 * config/i386/sse.md (ssequaterinsnmode): New mode attribute.
23887 (*<extract_type>_vinsert<shuffletype><extract_suf>_0): New pattern.
23888
23889 2018-05-08 Richard Earnshaw <rearnsha@arm.com>
23890
23891 PR target/85658
23892 * config/arm/parsecpu.awk (check_cpu): Fix operator precedence.
23893 (check_arch): Likewise.
23894 (check_fpu): Return the result rather than printing it.
23895 (end arch): Fix operator precedence.
23896 (end cpu): Likewise.
23897 (END): Print the result from check_fpu.
23898
23899 2018-05-08 Richard Sandiford <richard.sandiford@linaro.org>
23900 Alan Hayward <alan.hayward@arm.com>
23901 David Sherwood <david.sherwood@arm.com>
23902
23903 * config/aarch64/aarch64-sve.md (*pred_cmp<cmp_op><mode>_combine)
23904 (*pred_cmp<cmp_op><mode>, *fcm<cmp_op><mode>_and_combine)
23905 (*fcmuo<mode>_and_combine, *fcm<cmp_op><mode>_and)
23906 (*fcmuo<mode>_and): New patterns.
23907
23908 2018-05-08 Richard Sandiford <richard.sandiford@linaro.org>
23909
23910 * config/aarch64/iterators.md (UNSPEC_COND_LO, UNSPEC_COND_LS)
23911 (UNSPEC_COND_HI, UNSPEC_COND_HS, UNSPEC_COND_UO): Delete.
23912 (SVE_INT_CMP, SVE_FP_CMP): New code iterators.
23913 (cmp_op, sve_imm_con): New code attributes.
23914 (SVE_COND_INT_CMP, imm_con): Delete.
23915 (cmp_op): Remove above unspecs from int attribute.
23916 * config/aarch64/aarch64-sve.md (*vec_cmp<cmp_op>_<mode>): Rename
23917 to...
23918 (*cmp<cmp_op><mode>): ...this. Use UNSPEC_MERGE_PTRUE instead of
23919 comparison-specific unspecs.
23920 (*vec_cmp<cmp_op>_<mode>_ptest): Rename to...
23921 (*cmp<cmp_op><mode>_ptest): ...this and adjust likewise.
23922 (*vec_cmp<cmp_op>_<mode>_cc): Rename to...
23923 (*cmp<cmp_op><mode>_cc): ...this and adjust likewise.
23924 (*vec_fcm<cmp_op><mode>): Rename to...
23925 (*fcm<cmp_op><mode>): ...this and adjust likewise.
23926 (*vec_fcmuo<mode>): Rename to...
23927 (*fcmuo<mode>): ...this and adjust likewise.
23928 (*pred_fcm<cmp_op><mode>): New pattern.
23929 * config/aarch64/aarch64.c (aarch64_emit_unop, aarch64_emit_binop)
23930 (aarch64_emit_sve_ptrue_op, aarch64_emit_sve_ptrue_op_cc): New
23931 functions.
23932 (aarch64_unspec_cond_code): Remove handling of LTU, GTU, LEU, GEU
23933 and UNORDERED.
23934 (aarch64_gen_unspec_cond, aarch64_emit_unspec_cond): Delete.
23935 (aarch64_emit_sve_predicated_cond): New function.
23936 (aarch64_expand_sve_vec_cmp_int): Use aarch64_emit_sve_ptrue_op_cc.
23937 (aarch64_emit_unspec_cond_or): Replace with...
23938 (aarch64_emit_sve_or_conds): ...this new function. Use
23939 aarch64_emit_sve_ptrue_op for the individual comparisons and
23940 aarch64_emit_binop to OR them together.
23941 (aarch64_emit_inverted_unspec_cond): Replace with...
23942 (aarch64_emit_sve_inverted_cond): ...this new function. Use
23943 aarch64_emit_sve_ptrue_op for the comparison and
23944 aarch64_emit_unop to invert the result.
23945 (aarch64_expand_sve_vec_cmp_float): Update after the above
23946 changes. Use aarch64_emit_sve_ptrue_op for native comparisons.
23947
23948 2018-05-07 Nathan Sidwell <nathan@acm.org>
23949
23950 * doc/invoke.texi (C++ Dialect Options): Remove -ffor-scope.
23951 * doc/extend.texi (Deprecated Features): Remove -fno-for-scope
23952 (Backwards Compatibility): Likewise.
23953
23954 2018-05-07 Luis Machado <luis.machado@linaro.org>
23955
23956 PR bootstrap/85681
23957 Revert:
23958 2018-05-07 Luis Machado <luis.machado@linaro.org>
23959
23960 * config/aarch64/aarch64-protos.h (cpu_prefetch_tune)
23961 <prefetch_dynamic_strides>: New const bool field.
23962 * config/aarch64/aarch64.c (generic_prefetch_tune): Update to include
23963 prefetch_dynamic_strides.
23964 (exynosm1_prefetch_tune): Likewise.
23965 (thunderxt88_prefetch_tune): Likewise.
23966 (thunderx_prefetch_tune): Likewise.
23967 (thunderx2t99_prefetch_tune): Likewise.
23968 (qdf24xx_prefetch_tune): Likewise. Set prefetch_dynamic_strides
23969 to false.
23970 (aarch64_override_options_internal): Update to set
23971 PARAM_PREFETCH_DYNAMIC_STRIDES.
23972 * doc/invoke.texi (prefetch-dynamic-strides): Document new option.
23973 * params.def (PARAM_PREFETCH_DYNAMIC_STRIDES): New.
23974 * params.h (PARAM_PREFETCH_DYNAMIC_STRIDES): Define.
23975 * tree-ssa-loop-prefetch.c (should_issue_prefetch_p): Account for
23976 prefetch-dynamic-strides setting.
23977
23978 2018-05-07 Luis Machado <luis.machado@linaro.org>
23979
23980 * config/aarch64/aarch64-protos.h (cpu_prefetch_tune)
23981 <minimum_stride>: New const int field.
23982 * config/aarch64/aarch64.c (generic_prefetch_tune): Update to include
23983 minimum_stride field.
23984 (exynosm1_prefetch_tune): Likewise.
23985 (thunderxt88_prefetch_tune): Likewise.
23986 (thunderx_prefetch_tune): Likewise.
23987 (thunderx2t99_prefetch_tune): Likewise.
23988 (qdf24xx_prefetch_tune): Likewise. Set minimum_stride to 2048.
23989 (aarch64_override_options_internal): Update to set
23990 PARAM_PREFETCH_MINIMUM_STRIDE.
23991 * doc/invoke.texi (prefetch-minimum-stride): Document new option.
23992 * params.def (PARAM_PREFETCH_MINIMUM_STRIDE): New.
23993 * params.h (PARAM_PREFETCH_MINIMUM_STRIDE): Define.
23994 * tree-ssa-loop-prefetch.c (should_issue_prefetch_p): Return false if
23995 stride is constant and is below the minimum stride threshold.
23996
23997 2018-05-07 Luis Machado <luis.machado@linaro.org>
23998
23999 * config/aarch64/aarch64.c (qdf24xx_prefetch_tune) <l2_cache_size>: Set
24000 to 512.
24001
24002 2018-05-07 Luis Machado <luis.machado@linaro.org>
24003
24004 * config/aarch64/aarch64-protos.h (cpu_prefetch_tune)
24005 <prefetch_dynamic_strides>: New const bool field.
24006 * config/aarch64/aarch64.c (generic_prefetch_tune): Update to include
24007 prefetch_dynamic_strides.
24008 (exynosm1_prefetch_tune): Likewise.
24009 (thunderxt88_prefetch_tune): Likewise.
24010 (thunderx_prefetch_tune): Likewise.
24011 (thunderx2t99_prefetch_tune): Likewise.
24012 (qdf24xx_prefetch_tune): Likewise. Set prefetch_dynamic_strides
24013 to false.
24014 (aarch64_override_options_internal): Update to set
24015 PARAM_PREFETCH_DYNAMIC_STRIDES.
24016 * doc/invoke.texi (prefetch-dynamic-strides): Document new option.
24017 * params.def (PARAM_PREFETCH_DYNAMIC_STRIDES): New.
24018 * params.h (PARAM_PREFETCH_DYNAMIC_STRIDES): Define.
24019 * tree-ssa-loop-prefetch.c (should_issue_prefetch_p): Account for
24020 prefetch-dynamic-strides setting.
24021
24022 2018-05-07 Luis Machado <luis.machado@linaro.org>
24023
24024 * config/aarch64/aarch64-protos.h (cpu_prefetch_tune)
24025 <minimum_stride>: New const int field.
24026 * config/aarch64/aarch64.c (generic_prefetch_tune): Update to include
24027 minimum_stride field.
24028 (exynosm1_prefetch_tune): Likewise.
24029 (thunderxt88_prefetch_tune): Likewise.
24030 (thunderx_prefetch_tune): Likewise.
24031 (thunderx2t99_prefetch_tune): Likewise.
24032 (qdf24xx_prefetch_tune): Likewise. Set minimum_stride to 2048.
24033 (aarch64_override_options_internal): Update to set
24034 PARAM_PREFETCH_MINIMUM_STRIDE.
24035 * doc/invoke.texi (prefetch-minimum-stride): Document new option.
24036 * params.def (PARAM_PREFETCH_MINIMUM_STRIDE): New.
24037 * params.h (PARAM_PREFETCH_MINIMUM_STRIDE): Define.
24038 * tree-ssa-loop-prefetch.c (should_issue_prefetch_p): Return false if
24039 stride is constant and is below the minimum stride threshold.
24040
24041 2018-05-06 Jakub Jelinek <jakub@redhat.com>
24042
24043 PR c++/85659
24044 * cfgexpand.c (expand_asm_stmt): Don't create a temporary if
24045 the type is addressable. Don't force op into register if it has
24046 BLKmode.
24047
24048 2018-05-05 Roland McGrath <mcgrathr@google.com>
24049
24050 PR other/77609
24051 * varasm.c (default_section_type_flags): Set SECTION_NOTYPE for
24052 any section for which we don't know a specific type it should have,
24053 regardless of name. Previously this was done only for the exact
24054 names ".init_array", ".fini_array", and ".preinit_array".
24055 (default_elf_asm_named_section): Add comment about
24056 relationship with default_section_type_flags and SECTION_NOTYPE.
24057 (get_section): Don't consider it a type conflict if one side has
24058 SECTION_NOTYPE and the other doesn't, as long as neither has the
24059 SECTION_BSS et al used in the default_section_type_flags logic.
24060
24061 2018-05-05 Tom de Vries <tom@codesourcery.com>
24062
24063 PR target/85653
24064 * config/nvptx/nvptx.c (WORKAROUND_PTXJIT_BUG_3): Define.
24065 (workaround_barsyncs): New function.
24066 (nvptx_reorg): Use workaround_barsyncs.
24067 * config/nvptx/nvptx.md (define_c_enum "unspecv"): Add UNSPECV_MEMBAR.
24068 (define_expand "nvptx_membar_cta"): New define_expand.
24069 (define_insn "*nvptx_membar_cta"): New insn.
24070
24071 2018-05-04 Pekka Jääskeläinen <pekka.jaaskelainen@parmance.com>
24072
24073 * brig-builtins.def: Add consts to ptrs etc. in BRIG builtin defs.
24074 To improve optimization opportunities.
24075 * builtin-types.def: The new needed builtin types for the above.
24076
24077 2018-05-04 Richard Biener <rguenther@suse.de>
24078
24079 * bb-reorder.c (sanitize_hot_paths): Release hot_bbs_to_check.
24080 * gimple-ssa-store-merging.c
24081 (imm_store_chain_info::output_merged_store): Remove redundant create,
24082 release split_store vector contents on failure.
24083 * tree-vect-slp.c (vect_schedule_slp_instance): Avoid leaking
24084 scalar stmt vector on cache hit.
24085
24086 2018-05-04 Segher Boessenkool <segher@kernel.crashing.org>
24087
24088 * common/config/rs6000/rs6000-common.c (rs6000_handle_option): Remove
24089 Xilinx FP support.
24090 * config.gcc (powerpc-xilinx-eabi*): Remove.
24091 * config/rs6000/predicates.md (easy_fp_constant): Remove Xilinx FP
24092 support.
24093 (fusion_addis_mem_combo_load): Ditto.
24094 * config/rs6000/rs6000-c.c (rs6000_target_modify_macros): Remove Xilinx
24095 FP support.
24096 (rs6000_cpu_cpp_builtins): Ditto.
24097 * config/rs6000/rs6000-linux.c
24098 (rs6000_linux_float_exceptions_rounding_supported_p): Ditto.
24099 * config/rs6000/rs6000-opts.h (enum fpu_type_t): Delete.
24100 * config/rs6000/rs6000.c (rs6000_debug_reg_global): Remove Xilinx FP
24101 support.
24102 (rs6000_setup_reg_addr_masks): Ditto.
24103 (rs6000_init_hard_regno_mode_ok): Ditto.
24104 (rs6000_option_override_internal): Ditto.
24105 (legitimate_lo_sum_address_p): Ditto.
24106 (rs6000_legitimize_address): Ditto.
24107 (rs6000_legitimize_reload_address): Ditto.
24108 (rs6000_legitimate_address_p): Ditto.
24109 (abi_v4_pass_in_fpr): Ditto.
24110 (setup_incoming_varargs): Ditto.
24111 (rs6000_gimplify_va_arg): Ditto.
24112 (rs6000_split_multireg_move): Ditto.
24113 (rs6000_savres_strategy): Ditto.
24114 (rs6000_emit_prologue_components): Ditto.
24115 (rs6000_emit_epilogue_components): Ditto.
24116 (rs6000_emit_prologue): Ditto.
24117 (rs6000_emit_epilogue): Ditto.
24118 (rs6000_elf_file_end): Ditto.
24119 (rs6000_function_value): Ditto.
24120 (rs6000_libcall_value): Ditto.
24121 * config/rs6000/rs6000.h: Ditto.
24122 (TARGET_MINMAX_SF, TARGET_MINMAX_DF): Delete, merge to ...
24123 (TARGET_MINMAX): ... this. New.
24124 (TARGET_SF_FPR, TARGET_DF_FPR, TARGET_SF_INSN, TARGET_DF_INSN): Delete.
24125 * config/rs6000/rs6000.md: Remove Xilinx FP support.
24126 (*movsi_internal1_single): Delete.
24127 * config/rs6000/rs6000.opt (msingle-float, mdouble-float, msimple-fpu,
24128 mfpu=, mxilinx-fpu): Delete.
24129 * config/rs6000/singlefp.h: Delete.
24130 * config/rs6000/sysv4.h: Remove Xilinx FP support.
24131 * config/rs6000/t-rs6000: Ditto.
24132 * config/rs6000/t-xilinx: Delete.
24133 * config/rs6000/titan.md: Adjust for fp_type removal.
24134 * config/rs6000/vsx.md: Remove Xilinx FP support.
24135 (VStype_simple): Delete.
24136 (VSfptype_simple, VSfptype_mul, VSfptype_div, VSfptype_sqrt): Delete.
24137 * config/rs6000/xfpu.h: Delete.
24138 * config/rs6000/xfpu.md: Delete.
24139 * config/rs6000/xilinx.h: Delete.
24140 * config/rs6000/xilinx.opt: Delete.
24141 * doc/invoke.texi (RS/6000 and PowerPC Options): Remove
24142 -msingle-float, -mdouble-float, -msimple-fpu, -mfpu=, and -mxilinx-fpu.
24143
24144 2018-05-04 Tom de Vries <tom@codesourcery.com>
24145
24146 PR libgomp/85639
24147 * builtins.c (expand_builtin_goacc_parlevel_id_size): Handle null target
24148 if ignore == 0.
24149
24150 2018-05-04 Richard Biener <rguenther@suse.de>
24151
24152 PR middle-end/85627
24153 * tree-complex.c (update_complex_assignment): We are always in SSA form.
24154 (expand_complex_div_wide): Likewise.
24155 (expand_complex_operations_1): Likewise.
24156 (expand_complex_libcall): Preserve EH info of the original stmt.
24157 (tree_lower_complex): Handle removed blocks.
24158 * tree.c (build_common_builtin_nodes): Do not set ECF_NOTRHOW
24159 on complex multiplication and division libcall builtins.
24160
24161 2018-05-04 Richard Biener <rguenther@suse.de>
24162
24163 PR middle-end/85574
24164 * fold-const.c (negate_expr_p): Restrict negation of operand
24165 zero of a division to when we know that can happen without
24166 overflow.
24167 (fold_negate_expr_1): Likewise.
24168
24169 2018-05-04 Jakub Jelinek <jakub@redhat.com>
24170
24171 PR libstdc++/85466
24172 * real.h (real_nextafter): Declare.
24173 * real.c (real_nextafter): New function.
24174 * fold-const-call.c (fold_const_nextafter): New function.
24175 (fold_const_call_sss): Call it for CASE_CFN_NEXTAFTER and
24176 CASE_CFN_NEXTTOWARD.
24177 (fold_const_call_1): For CASE_CFN_NEXTTOWARD call fold_const_call_sss
24178 even when arg1_mode is different from arg0_mode.
24179
24180 2018-05-03 Nathan Sidwell <nathan@acm.org>
24181
24182 * doc/extend.texi (Deprecated Features): Remove
24183 -ffriend-injection.
24184 (Backwards Compatibility): Likewise.
24185 * doc/invoke.texi (C++ Language Options): Likewise.
24186 (C++ Dialect Options): Likewise.
24187
24188 2018-05-03 Jakub Jelinek <jakub@redhat.com>
24189
24190 PR target/85530
24191 * config/i386/avx512fintrin.h (_mm512_mullox_epi64,
24192 _mm512_mask_mullox_epi64): New intrinsics.
24193
24194 2018-05-03 Tom de Vries <tom@codesourcery.com>
24195
24196 PR testsuite/85106
24197 * doc/sourcebuild.texi (Commands for use in dg-final, Scan optimization
24198 dump files): Add offload-tree.
24199
24200 2018-05-03 Richard Biener <rguenther@suse.de>
24201
24202 PR tree-optimization/85615
24203 * tree-ssa-threadupdate.c (thread_block_1): Only allow exits
24204 to loops not nested in BBs loop father to avoid creating multi-entry
24205 loops.
24206
24207 2018-05-03 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
24208
24209 PR tree-optimization/70291
24210 * tree-complex.c (expand_complex_libcall): Add type, inplace_p
24211 arguments. Change return type to tree. Emit libcall as a new
24212 statement rather than replacing existing one when inplace_p is true.
24213 (expand_complex_multiplication_components): New function.
24214 (expand_complex_multiplication): Expand floating-point complex
24215 multiplication using the above.
24216 (expand_complex_division): Rename inner_type parameter to type.
24217 Update expand_complex_libcall call-site.
24218 (expand_complex_operations_1): Update expand_complex_multiplication
24219 and expand_complex_division call-sites.
24220
24221 2018-05-02 Jakub Jelinek <jakub@redhat.com>
24222
24223 PR target/85582
24224 * config/i386/i386.md (*ashl<dwi>3_doubleword_mask,
24225 *ashl<dwi>3_doubleword_mask_1, *<shift_insn><dwi>3_doubleword_mask,
24226 *<shift_insn><dwi>3_doubleword_mask_1): In condition require that
24227 the highest significant bit of the shift count mask is clear. In
24228 check whether and[sq]i3 is needed verify that all significant bits
24229 of the shift count other than the highest are set.
24230
24231 2018-05-02 Tom de Vries <tom@codesourcery.com>
24232
24233 PR libgomp/82428
24234 * builtins.def (DEF_GOACC_BUILTIN_ONLY): Define.
24235 * omp-builtins.def (BUILT_IN_GOACC_PARLEVEL_ID)
24236 (BUILT_IN_GOACC_PARLEVEL_SIZE): New builtin.
24237 * builtins.c (expand_builtin_goacc_parlevel_id_size): New function.
24238 (expand_builtin): Call expand_builtin_goacc_parlevel_id_size.
24239 * doc/extend.texi (Other Builtins): Add __builtin_goacc_parlevel_id and
24240 __builtin_goacc_parlevel_size.
24241
24242 2018-05-02 Richard Biener <rguenther@suse.de>
24243
24244 PR tree-optimization/85597
24245 * tree-vect-stmts.c (vectorizable_operation): For ternary SLP
24246 do not use split vect_get_vec_defs call but call vect_get_slp_defs
24247 directly.
24248
24249 2018-05-02 Tom de Vries <tom@codesourcery.com>
24250
24251 PR testsuite/85106
24252 * doc/sourcebuild.texi (Commands for use in dg-final, Scan optimization
24253 dump files): Add ltrans-tree.
24254
24255 2018-05-02 Tom de Vries <tom@codesourcery.com>
24256
24257 PR testsuite/85106
24258 * doc/sourcebuild.texi (Commands for use in dg-final, Scan optimization
24259 dump files): Add wpa-ipa.
24260
24261 2018-05-02 Segher Boessenkool <segher@kernel.crashing.org>
24262
24263 * config.gcc (powerpc*-*-*): Remove paired.h. Unsupport the
24264 powerpc*-*-linux*paired* target.
24265 * config/rs6000/750cl.h: Delete.
24266 * config/rs6000/paired.h: Delete.
24267 * config/rs6000/paired.md: Delete.
24268 * config/rs6000/predicates.md (easy_vector_constant): Remove paired
24269 float support.
24270 * config/rs6000/rs6000-builtin.def: Remove paired float support.
24271 * config/rs6000/rs6000-c.c (rs6000_target_modify_macros): Update
24272 comment. Remove paired float support.
24273 * config/rs6000/rs6000-modes.def: Remove V2SF and V2SI.
24274 * config/rs6000/rs6000-opts.h (enum rs6000_vector): Delete
24275 VECTOR_PAIRED.
24276 * config/rs6000/rs6000-protos.h (paired_expand_vector_init,
24277 paired_emit_vector_cond_expr, paired_expand_vector_move): Delete
24278 declarations.
24279 * config/rs6000/rs6000.c: Remove paired float support.
24280 (paired_expand_vector_init, paired_expand_vector_move,
24281 paired_emit_vector_compare, paired_emit_vector_cond_expr,
24282 (paired_expand_lv_builtin, paired_expand_stv_builtin,
24283 paired_expand_builtin, paired_expand_predicate_builtin,
24284 paired_init_builtins): Delete.
24285 * config/rs6000/rs6000.h: Remove paired float support.
24286 * config/rs6000/rs6000.md: Remove paired float support.
24287 (move_from_CR_ov_bit): Delete.
24288 * config/rs6000/rs6000.opt (mpaired): Delete.
24289 * config/rs6000/t-rs6000: Remove paired.md from MD_INCLUDES.
24290 * doc/invoke.texi (RS/6000 and PowerPC Options): Delete -mpaired.
24291
24292 2018-05-02 Richard Biener <rguenther@suse.de>
24293
24294 PR middle-end/85567
24295 * gimplify.c (gimplify_save_expr): When in SSA form allow
24296 SAVE_EXPRs to compute to SSA vars.
24297
24298 2018-05-02 Jakub Jelinek <jakub@redhat.com>
24299
24300 PR target/85582
24301 * config/i386/i386.md (*ashl<dwi>3_doubleword_mask,
24302 *ashl<dwi>3_doubleword_mask_1, *<shift_insn><dwi>3_doubleword_mask,
24303 *<shift_insn><dwi>3_doubleword_mask_1): If and[sq]i3 is needed, don't
24304 clobber operands[2], instead use a new pseudo. Formatting fixes.
24305
24306 2018-05-02 Richard Sandiford <richard.sandiford@linaro.org>
24307
24308 PR tree-optimization/85586
24309 * tree-vect-data-refs.c (vect_analyze_data_ref_dependence): Only
24310 exit early for statements in the same group if the accesses are
24311 not strided.
24312
24313 2018-05-02 Tom de Vries <tom@codesourcery.com>
24314
24315 PR lto/85451
24316 * lto-wrapper.c (compile_offload_image): Add "could not find mkoffload"
24317 error message.
24318
24319 2018-05-01 Marc Glisse <marc.glisse@inria.fr>
24320
24321 PR tree-optimization/85143
24322 * match.pd (A<B&A<C): Extend to BIT_IOR_EXPR.
24323
24324 2018-05-01 Tom de Vries <tom@codesourcery.com>
24325
24326 PR lto/85451
24327 * config/nvptx/mkoffload.c (main): Suggest using -B in "offload compiler
24328 not found" error message.
24329
24330 2018-05-01 Tom de Vries <tom@codesourcery.com>
24331
24332 PR other/83786
24333 * vec.h (VEC_ORDERED_REMOVE_IF, VEC_ORDERED_REMOVE_IF_FROM_TO): Define.
24334 * vec.c (test_ordered_remove_if): New function.
24335 (vec_c_tests): Call test_ordered_remove_if.
24336 * dwarf2cfi.c (connect_traces): Use VEC_ORDERED_REMOVE_IF_FROM_TO.
24337 * lto-streamer-out.c (prune_offload_funcs): Use VEC_ORDERED_REMOVE_IF.
24338 * tree-vect-patterns.c (vect_pattern_recog_1): Use
24339 VEC_ORDERED_REMOVE_IF.
24340
24341 2018-05-01 Prathamesh Kulkarni <prathamesh.kulkarni@linaro.org>
24342
24343 PR tree-optimization/82665
24344 * vr-values.c (vr_values::extract_range_from_binary_expr): Handle
24345 pointer subtraction where arguments come from a memchr call.
24346
24347 2018-05-01 Jakub Jelinek <jakub@redhat.com>
24348
24349 * configure.ac (LD_AS_NEEDED_OPTION, LD_NO_AS_NEEDED_OPTION): Use
24350 --push-state --as-needed and --pop-state instead of --as-needed and
24351 --no-as-needed if ld supports it.
24352 * configure: Regenerated.
24353
24354 PR web/85578
24355 * doc/install.texi2html: Replace _002d with - and _002a with * in
24356 generated html files using sed.
24357
24358 2018-04-30 David Malcolm <dmalcolm@redhat.com>
24359
24360 PR c++/85523
24361 * gcc-rich-location.c (blank_line_before_p): New function.
24362 (use_new_line): New function.
24363 (gcc_rich_location::add_fixit_insert_formatted): New function.
24364 * gcc-rich-location.h
24365 (gcc_rich_location::add_fixit_insert_formatted): New function.
24366
24367 2018-04-30 David Malcolm <dmalcolm@redhat.com>
24368
24369 * selftest.c (assert_streq): Rename "expected" and "actual" to
24370 "val1" and "val2". Extend NULL-handling to cover both inputs
24371 symmetrically, while still requiring both to be non-NULL for a pass.
24372 * selftest.h (assert_streq): Rename "expected" and "actual" to
24373 "val1" and "val2".
24374 (ASSERT_EQ): Likewise.
24375 (ASSERT_EQ_AT): Likewise.
24376 (ASSERT_KNOWN_EQ): Likewise.
24377 (ASSERT_KNOWN_EQ_AT): Likewise.
24378 (ASSERT_NE): Likewise.
24379 (ASSERT_MAYBE_NE): Likewise.
24380 (ASSERT_MAYBE_NE_AT): Likewise.
24381 (ASSERT_STREQ): Likewise. Clarify that both must be non-NULL for
24382 the assertion to pass.
24383 (ASSERT_STREQ_AT): Likewise.
24384
24385 2018-04-30 Jonathan Wakely <jwakely@redhat.com>
24386
24387 * doc/invoke.texi (-fpie, -fPIE): Fix grammar and clarify
24388 interaction with -pie.
24389
24390 2018-04-30 David Malcolm <dmalcolm@redhat.com>
24391
24392 * selftest.h: Fix alphabetization of per-source-file selftest
24393 declarations.
24394
24395 2018-04-30 Jason Merrill <jason@redhat.com>
24396
24397 PR c++/61982 - dead stores to destroyed objects.
24398 * gimplify.c (gimplify_modify_expr): Simplify complex lvalue on LHS
24399 of clobber.
24400
24401 2018-04-30 Jason Merrill <jason@redhat.com>
24402
24403 * tree.c (build_clobber): New.
24404 * tree.h: Declare it.
24405 * gimplify.c (gimplify_bind_expr, gimplify_target_expr): Use it.
24406
24407 2018-04-30 David Malcolm <dmalcolm@redhat.com>
24408
24409 * diagnostic-show-locus.c (layout::layout): Update for
24410 location_get_source_line returning a char_span.
24411 (struct char_span): Move to input.h.
24412 (struct correction): Update for fields in char_span becoming
24413 private.
24414 (struct source_line): Update for location_get_source_line
24415 returning a char_span.
24416 (layout::print_line): Likewise.
24417 * edit-context.c (edited_file::print_content): Likewise.
24418 (edited_file::print_diff_hunk): Likewise.
24419 (edited_file::print_run_of_changed_lines): Likewise.
24420 (edited_file::get_num_lines): Likewise.
24421 (edited_line::edited_line): Likewise.
24422 * final.c (asm_show_source): Likewise.
24423 * input.c (location_get_source_line): Convert return type
24424 from const char * to char_span, losing the final "line_len"
24425 param.
24426 (dump_location_info): Update for the above.
24427 (get_substring_ranges_for_loc): Likewise. Use a char_span
24428 when handling the literal within the line.
24429 (test_reading_source_line): Update for location_get_source_line
24430 returning a char_span.
24431 * input.h (class char_span): Move here from
24432 diagnostic-show-locus.c, converting from a struct to a class.
24433 Make data members private.
24434 (char_span::operator bool): New.
24435 (char_span::length): New.
24436 (char_span::get_buffer): New.
24437 (char_span::operator[]): New.
24438 (char_span::subspan): Make const.
24439 (char_span::xstrdup): New.
24440 (location_get_source_line): Convert return type from const char *
24441 to char_span, losing the final "line_size" param.
24442
24443 2018-04-30 Jan Hubicka <jh@suse.cz>
24444
24445 * lto-wrapper.c (ltrans_priorities): New static var.
24446 (cmp_priority): New.
24447 (run_gcc): Read priorities and if doing parallel build order
24448 the Makefile by them.
24449
24450 2018-04-30 David Malcolm <dmalcolm@redhat.com>
24451
24452 * input.h (builtins_location_check): Convert to a STATIC_ASSERT.
24453
24454 2018-04-30 Richard Biener <rguenther@suse.de>
24455
24456 * tree-cfg.c (verify_address): Remove base argument, add
24457 flag whether to check TREE_ADDRESSABLE and do that.
24458 (verify_expr): Remove.
24459 (verify_types_in_gimple_reference): Add pieces from verify_expr.
24460 (verify_gimple_assign_single): Likewise.
24461 (verify_gimple_switch): Likewise.
24462 (verify_expr_location_1): Dereference tp once. Add (disabled)
24463 piece from verify_expr.
24464 (verify_gimple_in_cfg): Do not call verify_expr on all ops.
24465
24466 2018-04-30 Claudiu Zissulescu <claziss@synopsys.com>
24467
24468 * config/arc/linux.h (CLEAR_INSN_CACHE): Define.
24469
24470 2018-04-30 Claudiu Zissulescu <claziss@synopsys.com>
24471
24472 * config/arc/arc-protos.h (prepare_extend_operands): Remove.
24473 (small_data_pattern): Likewise.
24474 (arc_rewrite_small_data): Likewise.
24475 * config/arc/arc.c (LEGITIMATE_SMALL_DATA_OFFSET_P): Remove.
24476 (LEGITIMATE_SMALL_DATA_ADDRESS_P): Likewise.
24477 (get_symbol_alignment): New function.
24478 (legitimate_small_data_address_p): Likewise.
24479 (legitimate_scaled_address): Update, call
24480 legitimate_small_data_address_p.
24481 (output_sdata): New static variable.
24482 (arc_print_operand): Update how we handle small data operands.
24483 (arc_print_operand_address): Likewise.
24484 (arc_legitimate_address_p): Update, use
24485 legitimate_small_data_address_p.
24486 (arc_rewrite_small_data_p): Remove.
24487 (arc_rewrite_small_data_1): Likewise.
24488 (arc_rewrite_small_data): Likewise.
24489 (small_data_pattern): Likewise.
24490 (compact_sda_memory_operand): Update to use
24491 legitimate_small_data_address_p and get_symbol_alignment.
24492 (prepare_move_operands): Don't rewite sdata pattern.
24493 (prepare_extend_operands): Remove.
24494 * config/arc/arc.md (zero_extendqihi2): Don't rewrite sdata
24495 pattern.
24496 (zero_extendqisi2): Likewise.
24497 (zero_extendhisi2): Likewise.
24498 (extendqihi2): Likewise.
24499 (extendqisi2): Likewise.
24500 (extendhisi2): Likewise.
24501 (addsi3): Likewise.
24502 (subsi3): Likewise.
24503 (andsi3): Likewise.
24504 * config/arc/constraints.md (Usd): Change it to memory constraint.
24505
24506 2018-04-30 Claudiu Zissulescu <claziss@synopsys.com>
24507
24508 * config/arc/arc.c (arc_split_move): Allow signed 6-bit constants
24509 as source of std instructions.
24510 * config/arc/arc.md (movsi_insn): Update pattern predicate to
24511 allow 6-bit constants as source for store instructions.
24512 (movdi_insn): Update instruction pattern to allow 6-bit constants
24513 as source for store instructions.
24514
24515 2018-04-30 Jonathan Wakely <jwakely@redhat.com>
24516
24517 * doc/invoke.texi (-fdebug-types-section): Fix grammar.
24518
24519 2018-04-30 Nathan Sidwell <nathan@acm.org>
24520 Sandra Loosemore <sandra@codesourcery.com>
24521
24522 * dumpfile.c (dump_open): Allow '-' for stdout.
24523 * doc/invoke.texi (Developer Options): Document dump filename
24524 determination early. Document stdin/stdout selection.
24525
24526 2018-04-30 Andrew Sadek <andrew.sadek.se@gmail.com>
24527
24528 Microblaze Target: PIC data text relative
24529
24530 * config/microblaze/microblaze.opt: add new option -mpic-data-text-rel.
24531 * config/microblaze/microblaze-protos.h (microblaze_constant_address_p):
24532 Add declaration.
24533 * config/microblaze/microblaze.h (microblaze_constant_address_p):
24534 CONSTANT_ADDRESS_P definition to microblaze_constant_address_p.
24535 * config/microblaze/microblaze.c (TARGET_PIC_DATA_TEXT_REL):
24536 New addressing mode for data-text relative position indepenedent code.
24537 (microblaze_classify_unspec): add 'UNSPEC_TEXT' case ->
24538 'ADDRESS_SYMBOLIC_TXT_REL'.
24539 (microblaze_classify_address): Add handling for UNSPEC + CONST_INT.
24540 (microblaze_legitimate_pic_operand): Exclude function calls from
24541 pic operands in case of TARGET_PIC_DATA_TEXT_REL option.
24542 (microblaze_legitimize_address): Generate 'UNSPEC_TEXT' for all possible
24543 addresses cases.
24544 (microblaze_address_insns): Add 'ADDRESS_SYMBOLIC_TXT_REL' case.
24545 (print_operand): Add 'ADDRESS_SYMBOLIC_TXT_REL' case.
24546 (print_operand_address): Add 'ADDRESS_SYMBOLIC_TXT_REL' case + handling
24547 for 'address + offset'.
24548 (microblaze_expand_prologue): Add new function prologue call for
24549 'r20' assignation.
24550 (microblaze_asm_generate_pic_addr_dif_vec): Override new target hook
24551 'TARGET_ASM_GENERATE_PIC_ADDR_DIFF_VEC' to disable address diff vector
24552 table in case of TARGET_PIC_DATA_TEXT_REL.
24553 (expand_pic_symbol_ref): Add handling for 'UNSPEC_TEXT'.
24554 * config/microblaze/microblaze.md (TARGET_PIC_DATA_TEXT_REL):
24555 Add new macros 'UNSPEC_TEXT',
24556 'UNSPEC_SET_TEXT' + add rule for setting r20 in function prologue
24557 + exclude function calls from 'UNSPEC_PLT' in case of data text
24558 relative mode.
24559 * doc/tm.texi.in (TARGET_ASM_GENERATE_PIC_ADDR_DIFF_VEC): Add
24560 new target hook for generating address diff vector tables in case of
24561 flag_pic.
24562 * doc/tm.texi : Regenerate.
24563 * stmt.c (TARGET_ASM_GENERATE_PIC_ADDR_DIFF_VEC): Append new condition
24564 'targetm.asm_out.generate_pic_addr_diff_vec' to flag_pic in case
24565 of addr diff vector generation.
24566 * target.def (TARGET_ASM_GENERATE_PIC_ADDR_DIFF_VEC): Add
24567 target hook definition.
24568 * targhooks.h, targhooks.c (TARGET_ASM_GENERATE_PIC_ADDR_DIFF_VEC):
24569 Add default function for generate_pic_addr_diff_vec -> flag_pic.
24570 * doc/invoke.texi (Add new pic option): Add new microblaze pic
24571 option for data text relative.
24572
24573 2018-04-30 Richard Biener <rguenther@suse.de>
24574
24575 * tree-chrec.h (evolution_function_is_constant_p): Remove
24576 redundant check.
24577 * tree-cfg.c (tree_node_can_be_shared): Re-order checks.
24578
24579 2018-04-30 Richard Biener <rguenther@suse.de>
24580
24581 PR bootstrap/85571
24582 * dwarf2out.c (gen_producer_string): Ignore -fchecking[=].
24583
24584 2018-04-30 Richard Biener <rguenther@suse.de>
24585
24586 PR tree-optimization/28364
24587 PR tree-optimization/85275
24588 * tree-ssa-loop-ch.c (ch_base::copy_headers): Stop after
24589 copying first exit test.
24590
24591 2018-04-28 Mark Wielaard <mark@klomp.org>
24592
24593 * dwarf2out.c (dwarf2out_finish): Add .debug_addr table header for
24594 dwarf_version >= 5.
24595 (dwarf_AT): Handle DW_AT_addr_base.
24596 (add_top_level_skeleton_die_attrs): Use dwarf_AT for DW_AT_addr_base.
24597
24598 2018-04-28 Uros Bizjak <ubizjak@gmail.com>
24599
24600 PR target/84431
24601 * config/i386/i386.md (*ashl<dwi>3_doubleword_mask): New pattern.
24602 (*ashl<dwi>3_doubleword_mask_1): Ditto.
24603 (*<shift_insn><dwi>3_doubleword_mask): Ditto.
24604 (*<shift_insn><dwi>3_doubleword_mask_1): Ditto.
24605
24606 2018-04-28 Richard Biener <rguenther@suse.de>
24607
24608 * tree-cfg.c (verify_gimple_phi): Take a gphi * argument.
24609 (verify_gimple_in_cfg): Rename visited_stmts to visited_throwing_stmts
24610 to reflect use. Only add interesting stmts.
24611
24612 2018-04-27 Martin Jambor <mjambor@suse.cz>
24613
24614 PR ipa/85549
24615 * ipa-cp.c (find_aggregate_values_for_callers_subset): Make sure
24616 the jump function allows for passing through aggregate values.
24617
24618 2018-04-27 David Malcolm <dmalcolm@redhat.com>
24619
24620 * input.h (in_system_header_at): Convert from macro to inline
24621 function.
24622 (from_macro_expansion_at): Likewise.
24623 (from_macro_definition_at): Likewise.
24624
24625 2018-04-27 Jeff Law <law@redhat.com>
24626
24627 * config.gcc: Mark tile* targets as deprecated/obsolete.
24628
24629 2018-04-27 Richard Biener <rguenther@suse.de>
24630
24631 * config/aarch64/aarch64.c: Simplify ap.__stack advance and
24632 fix for ILP32.
24633
24634 2018-04-27 Richard Biener <rguenther@suse.de>
24635
24636 * tree-cfg.c (verify_expr): Make dead code hit gcc_unreachable.
24637
24638 2018-04-27 Uros Bizjak <ubizjak@gmail.com>
24639
24640 * config/i386/i386.md (*movti_internal): Substitute Ye constraint
24641 with Yd constraint. Set "preferred_for_speed" attribute from
24642 TARGET_INTER_UNIT_MOVES_{FROM,TO}_VEC for alternatives
24643 with Yd constraint.
24644 (*movdi_internal): Ditto.
24645 (movti_interunit splitters): Remove
24646 TARGET_INTER_UNIT_MOVES_{FROM,TO}_VEC from insn condition.
24647 (movdi_interunit splitters): Ditto.
24648 * config/i386/constraints.md (Ye): Remove.
24649 (Yd): Do not depend on TARGET_INTER_UNIT_MOVES_{FROM,TO}_VEC.
24650
24651 2018-04-27 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
24652
24653 PR target/85512
24654 * config/aarch64/constraints.md (Usg): Limit to 31.
24655 (Usj): Limit to 63.
24656
24657 2018-04-27 Jakub Jelinek <jakub@redhat.com>
24658
24659 PR tree-optimization/85529
24660 * tree-ssa-reassoc.c (optimize_range_tests_var_bound): Add FIRST_BB
24661 argument. Don't call get_nonzero_bits if opcode is ERROR_MARK_NODE,
24662 rhs2 def stmt's bb is dominated by first_bb and it isn't an obvious
24663 zero extension or masking of the MSB bit.
24664 (optimize_range_tests): Add FIRST_BB argument, pass it through
24665 to optimize_range_tests_var_bound.
24666 (maybe_optimize_range_tests, reassociate_bb): Adjust
24667 optimize_range_tests callers.
24668
24669 2018-04-26 Richard Biener <rguenther@suse.de>
24670 Jakub Jelinek <jakub@redhat.com>
24671
24672 * cgraph.h (symbol_table): Just declare debug method here.
24673 * symtab.c (symbol_table::debug): Define.
24674
24675 2018-04-26 Eric Botcazou <ebotcazou@adacore.com>
24676
24677 * loop-invariant.c (may_assign_reg_p): Return false for frame pointer.
24678
24679 2018-04-26 Uros Bizjak <ubizjak@gmail.com>
24680
24681 * config/i386/i386.md ("isa" attribute): Add x64_sse2.
24682 ("enabled" attribute): Handle x64_sse2 "isa" attribute.
24683 (*movdi_internal): Substitute Yi and Yj constraint with x
24684 and Ym and Yn constraint with y constraint. Update "isa"
24685 attribute and set "preferred_for_speed" attribute from
24686 TARGET_INTER_UNIT_MOVES_{FROM,TO}_VEC for updated alternatives.
24687 (*movsi_internal): Ditto.
24688 (*movdf_internal): Ditto.
24689 (*movsf_internal): Ditto.
24690 (*zero_extendsidi2): Ditto.
24691 * config/i386/sse.md (vec_set<mode>_0): Ditto.
24692 (sse2_loadld): Ditto.
24693 (*vec_extract<ssevecmodelower>_0): Ditto.
24694 (*vec_extractv4si_0_zext_sse4): Ditto.
24695 (vec_concatv2di): Ditto.
24696 (*vec_dup<mode>): Ditto.
24697 * config/i386/mmx.md (*mov<mode>_internal): Ditto.
24698 * config/i386/constraints.md (Yi): Remove.
24699 (Yj): Remove.
24700 (Ym): Remove.
24701 (Yn): Remove.
24702
24703 2018-04-26 Nathan Sidwell <nathan@acm.org>
24704
24705 * dumpfile.c (dump_open): New.
24706 (dump_open_alternate_stream, dump_start, dump_begin): Call it.
24707 (dump_finish): Detect stdio/stderr by value not name.
24708
24709 2018-04-26 Jonathan Wakely <jwakely@redhat.com>
24710
24711 * doc/invoke.texi (-Wreturn-type): Document default status for C++.
24712
24713 2018-04-26 Tom de Vries <tom@codesourcery.com>
24714
24715 PR target/84952
24716 * config/nvptx/nvptx.c (verify_neutering_jumps)
24717 (verify_neutering_labels): New function
24718 (nvptx_single): Use verify_neutering_jumps and verify_neutering_labels.
24719
24720 2018-04-26 Tom de Vries <tom@codesourcery.com>
24721
24722 PR target/84025
24723 * config/nvptx/nvptx.c (needs_neutering_p): New function.
24724 (nvptx_single): Use needs_neutering_p to skip over insns that do not
24725 need neutering.
24726
24727 2018-04-26 Richard Biener <rguenther@suse.de>
24728 Tom de Vries <tom@codesourcery.com>
24729
24730 PR lto/85422
24731 * lto-streamer-out.c (output_function): Fixup loops if required to match
24732 discovery done in the reader.
24733
24734 2018-04-26 Richard Biener <rguenther@suse.de>
24735
24736 PR tree-optimization/85116
24737 * tree-ssa-loop-ch.c (do_while_loop_p): A do-while loop should
24738 have a loop exit from the single latch predecessor. Remove
24739 case of header with just condition.
24740 (ch_base::copy_headers): Exclude infinite loops from any
24741 processing.
24742 (pass_ch::execute): Record exits.
24743
24744 2018-04-26 Richard Biener <rguenther@suse.de>
24745
24746 * tree-vect-data-refs.c (vect_get_data_access_cost): Get
24747 prologue cost vector and pass it to vect_get_load_cost.
24748 (vect_get_peeling_costs_all_drs): Likewise.
24749 (vect_peeling_hash_get_lowest_cost): Likewise.
24750 (vect_enhance_data_refs_alignment): Likewise.
24751
24752 2018-04-26 Richard Biener <rguenther@suse.de>
24753
24754 PR middle-end/85450
24755 * tree-cfg.c (verify_gimple_assign_unary): Restore proper
24756 checking of integer<->pointer conversions.
24757 * omp-expand.c (expand_omp_for_static_nochunk): Avoid
24758 sign-/zero-extending pointer types.
24759 (expand_omp_for_static_chunk): Likewise.
24760
24761 2018-03-22 Hans-Peter Nilsson <hp@axis.com>
24762 Jean Lee <xiaoyur347@gmail.com>
24763
24764 * config/mips/mips.c (mips_asan_shadow_offset): New function.
24765 (TARGET_ASAN_SHADOW_OFFSET): Define.
24766 * config/mips/mips.h (FRAME_GROWS_DOWNWARD): Augment to also be
24767 true for -fsanitize=address.
24768
24769 2018-04-25 Mark Wielaard <mark@klomp.org>
24770
24771 * dwarf2out.c (file_info_cmp): Sort longer dir prefixes before
24772 shorter ones.
24773
24774 2018-04-25 Jakub Jelinek <jakub@redhat.com>
24775
24776 * config/i386/i386.md (*x86_mov<mode>cc_0_m1): Use type "alu1" rather
24777 than "alu", remove explicit "memory" and "imm_disp" attributes.
24778 (*x86_mov<mode>cc_0_m1_se, *x86_mov<mode>cc_0_m1_neg): Likewise.
24779
24780 PR middle-end/85414
24781 * simplify-rtx.c (simplify_unary_operation_1) <case SIGN_EXTEND,
24782 case ZERO_EXTEND>: Pass SUBREG_REG (op) rather than op to
24783 gen_lowpart_no_emit.
24784
24785 2018-04-25 Sebastian Peryt <sebastian.peryt@intel.com>
24786
24787 PR target/85473
24788 * config/i386/i386.c (ix86_expand_builtin): Change memory
24789 operand to XI, extend p0 to Pmode.
24790 * config/i386/i386.md: Change unspec volatile and operand
24791 1 mode to XI, change operand 0 mode to P.
24792
24793 2018-04-25 Chung-Ju Wu <jasonwucj@gmail.com>
24794
24795 * config/nds32/nds32-predicates.c (nds32_can_use_bclr_p): Mask with
24796 GET_MODE_MASK before any checking.
24797 (nds32_can_use_bset_p): Likewise.
24798 (nds32_can_use_btgl_p): Likewise.
24799
24800 2018-04-25 Chung-Ju Wu <jasonwucj@gmail.com>
24801
24802 * config/nds32/nds32-doubleword.md: New define_split pattern for
24803 illegal register number.
24804
24805 2018-04-25 Chung-Ju Wu <jasonwucj@gmail.com>
24806
24807 * config/nds32/nds32.c (nds32_print_operand): Set op_value ealier.
24808
24809 2018-04-25 Chung-Ju Wu <jasonwucj@gmail.com>
24810
24811 * config/nds32/nds32.h (ASM_APP_ON): Add missing newline character.
24812
24813 2018-04-25 Richard Biener <rguenther@suse.de>
24814
24815 * lto-streamer.h (LTO_major_version): Bump to 8.
24816
24817 2018-04-25 Jakub Jelinek <jakub@redhat.com>
24818
24819 * BASE-VER: Set to 9.0.0.
24820
24821 2018-04-24 Segher Boessenkool <segher@kernel.crashing.org>
24822
24823 * config/rs6000/rs6000.c (init_float128_ieee): Fix spelling mistakes
24824 in __abskf2 and __powikf2.
24825
24826 2018-04-24 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
24827
24828 PR target/85512
24829 * config/aarch64/constraints.md (Usg, Usj): New constraints.
24830 * config/aarch64/iterators.md (cmode_simd): New mode attribute.
24831 * config/aarch64/aarch64.md (*aarch64_ashr_sisd_or_int_<mode>3):
24832 Use the above on operand 2. Reindent.
24833 (*aarch64_lshr_sisd_or_int_<mode>3): Likewise.
24834
24835 2018-04-24 H.J. Lu <hongjiu.lu@intel.com>
24836
24837 PR target/85485
24838 * common/config/i386/i386-common.c (ix86_handle_option): Don't
24839 handle OPT_mcet.
24840 * config/i386/i386.opt (mcet): Removed.
24841 * doc/install.texi: Remove -mcet documentation.
24842 * doc/invoke.texi: Likewise.
24843
24844 2018-04-24 H.J. Lu <hongjiu.lu@intel.com>
24845
24846 PR target/85485
24847 * doc/install.texi: Remove -mcet from bootstrap-cet.
24848
24849 2018-04-24 Jakub Jelinek <jakub@redhat.com>
24850
24851 PR target/85511
24852 * config/i386/i386.c (ix86_init_mmx_sse_builtins): Don't define
24853 __builtin_ia32_readeflags_u32 and __builtin_ia32_writeeflags_u32
24854 if TARGET_64BIT.
24855
24856 PR target/85503
24857 * config/rs6000/rs6000-p8swap.c (const_load_sequence_p): Punt if
24858 const_vector is not CONST_VECTOR or SYMBOL_REF for a constant pool
24859 containing a CONST_VECTOR.
24860
24861 2018-04-24 Cesar Philippidis <cesar@codesourcery.com>
24862
24863 * doc/install.texi: Update newlib dependency for nvptx.
24864
24865 2018-04-24 Jakub Jelinek <jakub@redhat.com>
24866
24867 PR target/85508
24868 * config/i386/i386.c (ix86_expand_vector_init_one_var): Use UINTVAL
24869 instead of INTVAL when shifting x left.
24870
24871 2018-04-24 Andreas Krebbel <krebbel@linux.ibm.com>
24872
24873 PR tree-optimization/85478
24874 * tree-vect-loop.c (vect_analyze_loop_2): Do not call
24875 vect_grouped_store_supported for single element vectors.
24876
24877 2018-04-24 Richard Biener <rguenther@suse.de>
24878
24879 PR target/85491
24880 * config/i386/i386.c (ix86_add_stmt_cost): Restrict strided
24881 load cost increase to the case of non-constant step.
24882
24883 2018-04-24 Jakub Jelinek <jakub@redhat.com>
24884
24885 PR target/84828
24886 * reg-stack.c (move_for_stack_reg): Don't fail assertion about dead
24887 destination if any_malformed_asm.
24888
24889 2018-04-23 Eric Botcazou <ebotcazou@adacore.com>
24890
24891 PR middle-end/85496
24892 * expr.c (store_field): In the bitfield case, if the value comes from
24893 a function call and is returned in registers by means of a PARALLEL,
24894 do not change the mode of the temporary unless BLKmode and VOIDmode.
24895
24896 2018-04-23 Andrey Belevantsev <abel@ispras.ru>
24897
24898 PR rtl-optimization/85423
24899 * sel-sched-ir.c (has_dependence_note_mem_dep): Only discard
24900 dependencies to debug insns when the previous insn is non-debug.
24901
24902 2018-04-23 Claudiu Zissulescu <claziss@synopsys.com>
24903
24904 * config/arc/arc.md ("vunspec"): Delete it, unify all the unspec
24905 enums into a single definition.
24906 (fls): Fix predicates and printing.
24907 (seti): Likewise.
24908
24909 2018-04-23 Claudiu Zissulescu <claziss@synopsys.com>
24910
24911 * config/arc/arc-protos.h (check_if_valid_sleep_operand): Remove.
24912 * config/arc/arc.c (arc_expand_builtin): Sleep accepts registers
24913 and short u6 immediate.
24914 (check_if_valid_sleep_operand): Remove.
24915 * config/arc/arc.md (Sleep): Accepts registers and u6 immediates.
24916
24917 2018-04-22 Chung-Ju Wu <jasonwucj@gmail.com>
24918
24919 * config/nds32/nds32.c (nds32_compute_stack_frame): Consider
24920 flag_always_save_lp condition.
24921 * config/nds32/nds32.opt (malways-save-lp): New option.
24922
24923 2018-04-22 Shiva Chen <shiva0217@gmail.com>
24924
24925 * config/nds32/nds32-protos.h (nds32_use_load_post_increment): Declare.
24926 * config/nds32/nds32.c (nds32_use_load_post_increment): New.
24927 * config/nds32/nds32.h
24928 (USE_LOAD_POST_INCREMENT, USE_LOAD_POST_DECREMENT): Define.
24929 (USE_STORE_POST_INCREMENT, USE_STORE_POST_DECREMENT): Define.
24930
24931 2018-04-22 Shiva Chen <shiva0217@gmail.com>
24932
24933 * config/nds32/nds32-protos.h (nds32_ls_333_p): Remove.
24934 * config/nds32/nds32.c (nds32_ls_333_p): Remove.
24935
24936 2018-04-22 Shiva Chen <shiva0217@gmail.com>
24937 Chung-Ju Wu <jasonwucj@gmail.com>
24938
24939 * config/nds32/nds32-protos.h (nds32_case_vector_shorten_mode):
24940 Declare.
24941 * config/nds32/nds32.c (nds32_case_vector_shorten_mode): New function.
24942 * config/nds32/nds32.h (CASE_VECTOR_SHORTEN_MODE): Modify.
24943
24944 2018-04-22 Chung-Ju Wu <jasonwucj@gmail.com>
24945
24946 * config/nds32/nds32.c (nds32_compute_stack_frame): Fix wrong value.
24947
24948 2018-04-22 Chung-Ju Wu <jasonwucj@gmail.com>
24949
24950 * config/nds32/nds32-protos.h (nds32_data_alignment,
24951 nds32_local_alignment): Declare.
24952 * config/nds32/nds32.c (nds32_data_alignment, nds32_constant_alignment,
24953 nds32_local_alignment): New functions.
24954 (TARGET_CONSTANT_ALIGNMENT): Define.
24955 * config/nds32/nds32.h (DATA_ALIGNMENT, LOCAL_ALIGNMENT): Define.
24956
24957 2018-04-22 Chung-Ju Wu <jasonwucj@gmail.com>
24958
24959 * config/nds32/nds32.c
24960 (TARGET_HARD_REGNO_MODE_OK): Move to the bottom of file.
24961 (TARGET_MODES_TIEABLE_P): Likewise.
24962
24963 2018-04-22 Chung-Ju Wu <jasonwucj@gmail.com>
24964
24965 * config/nds32/nds32.c (nds32_asm_file_start): Display optimization
24966 level Ofast and Og.
24967
24968 2018-04-22 Monk Chiang <sh.chiang04@gmail.com>
24969 Chung-Ju Wu <jasonwucj@gmail.com>
24970
24971 * config/nds32/constants.md (unspec_volatile_element): Add enum values
24972 for unaligned access.
24973 * config/nds32/nds32-intrinsic.c: Implementation of expanding
24974 unaligned access.
24975 * config/nds32/nds32-intrinsic.md: Likewise.
24976 * config/nds32/nds32_intrinsic.h: Likewise.
24977 * config/nds32/nds32.h (nds32_builtins): Likewise.
24978 * config/nds32/nds32.opt (munaligned-access): New option.
24979 * config/nds32/nds32.c (nds32_asm_file_start): Display
24980 flag_unaligned_access status.
24981
24982 2018-04-20 Kito Cheng <kito.cheng@gmail.com>
24983
24984 * config/riscv/elf.h (LINK_SPEC): Pass --no-relax if
24985 -mno-relax is present.
24986 * config/riscv/linux.h (LINK_SPEC): Ditto.
24987
24988 2018-04-20 Martin Sebor <msebor@redhat.com>
24989
24990 PR c/85365
24991 * gimple-fold.c (gimple_fold_builtin_strcpy): Suppress -Wrestrict
24992 for null pointers.
24993 (gimple_fold_builtin_stxcpy_chk): Same.
24994 * gimple-ssa-warn-restrict.c (check_bounds_or_overlap): Same.
24995
24996 2018-04-20 Michael Meissner <meissner@linux.ibm.com>
24997
24998 PR target/85456
24999 * config/rs6000/rs6000.c (init_float128_ieee): Add support to call
25000 __powikf2 when long double is IEEE 128-bit.
25001
25002 2018-04-20 Kito Cheng <kito.cheng@gmail.com>
25003
25004 * config/riscv/riscv.c (riscv_first_stack_step): Round up min
25005 step to make sure stack always aligned.
25006
25007 2018-04-20 Carl Love <cel@us.ibm.com>
25008
25009 PR target/83402
25010 * config/rs6000/rs6000-c.c (rs6000_gimple_fold_builtin): Add
25011 size check for arg0.
25012
25013 2018-04-20 Nathan Sidwell <nathan@codesourcery.com>
25014 Tom de Vries <tom@codesourcery.com>
25015
25016 PR target/85445
25017 * config/nvptx/nvptx.c (nvptx_emit_forking, nvptx_emit_joining):
25018 Emit insns for calls too.
25019 (nvptx_find_par): Always look for worker-level predecessor insn.
25020 (nvptx_propagate): Add is_call parm, return bool. Copy frame for
25021 calls.
25022 (nvptx_vpropagate, nvptx_wpropagate): Adjust.
25023 (nvptx_process_pars): Propagate frames for calls.
25024
25025 2018-04-20 H.J. Lu <hongjiu.lu@intel.com>
25026
25027 PR target/85469
25028 * common/config/i386/i386-common.c (OPTION_MASK_ISA_IBT_SET):
25029 Removed.
25030 (OPTION_MASK_ISA_IBT_UNSET): Likewise.
25031 (ix86_handle_option): Don't handle OPT_mibt.
25032 * config/i386/cet.h: Check __CET__ instead of __IBT__ and
25033 __SHSTK__.
25034 * config/i386/driver-i386.c (host_detect_local_cpu): Remove
25035 has_ibt and ibt.
25036 * config/i386/i386-c.c (ix86_target_macros_internal): Don't
25037 check OPTION_MASK_ISA_IBT nor flag_cf_protection.
25038 (ix86_target_macros): Define __CET__ with flag_cf_protection
25039 for -fcf-protection.
25040 * config/i386/i386.c (isa2_opts): Remove -mibt.
25041 * config/i386/i386.h (TARGET_IBT): Removed.
25042 (TARGET_IBT_P): Likewise.
25043 (ix86_valid_target_attribute_inner_p): Don't check OPT_mibt.
25044 * config/i386/i386.md (nop_endbr): Don't check TARGET_IBT.
25045 * config/i386/i386.opt (mcet): Update help message.
25046 (mshstk): Likewise.
25047 (mibt): Removed.
25048 * doc/invoke.texi: Remove -mibt. Document __CET__. Document
25049 -mcet as an alias for -mshstk.
25050
25051 2018-04-20 Richard Biener <rguenther@suse.de>
25052
25053 PR middle-end/85475
25054 * match.pd ((X * CST) * Y -> (X * Y) * CST): Avoid exponential
25055 complexity by forcing a single use of the multiply operand.
25056
25057 2018-04-20 Martin Jambor <mjambor@suse.cz>
25058
25059 ipa/85449
25060 * ipa-cp.c (cgraph_edge_brings_value_p): Move check for self-feeding
25061 recursion dependency to only apply to non-clones.
25062
25063 2018-04-20 Martin Jambor <mjambor@suse.cz>
25064
25065 ipa/85447
25066 * ipa-cp.c (create_specialized_node): Check that clones of
25067 self-recursive edges exist during IPA-CP.
25068
25069 2018-04-19 Toon Moene <toon@moene.org>
25070
25071 * doc/invoke.texi: Add -floop-unroll-and-jam to options enabled
25072 by -O3.
25073
25074 2018-04-19 Jakub Jelinek <jakub@redhat.com>
25075
25076 PR tree-optimization/85467
25077 * fold-const.c (fold_ternary_loc) <case BIT_FIELD_REF>: Use
25078 VECTOR_TYPE_P macro. If type is vector type, VIEW_CONVERT_EXPR the
25079 VECTOR_CST element to type.
25080
25081 2018-04-19 H.J. Lu <hongjiu.lu@intel.com>
25082
25083 PR target/85397
25084 * config/i386/i386.h (STACK_SAVEAREA_MODE): New.
25085 * config/i386/i386.md (builtin_setjmp_setup): Removed.
25086 (builtin_longjmp): Likewise.
25087 (save_stack_nonlocal): New pattern.
25088 (restore_stack_nonlocal): Likewise.
25089
25090 2018-04-19 H.J. Lu <hongjiu.lu@intel.com>
25091
25092 PR target/85404
25093 * config/i386/cet.c (file_end_indicate_exec_stack_and_cet):
25094 Replace ASM_OUTPUT_LABEL with fprintf.
25095
25096 2018-04-19 H.J. Lu <hongjiu.lu@intel.com>
25097
25098 PR target/85417
25099 * config/i386/cet.c (file_end_indicate_exec_stack_and_cet):
25100 Check flag_cf_protection instead of TARGET_IBT and TARGET_SHSTK.
25101 * config/i386/i386-c.c (ix86_target_macros_internal): Also
25102 define __IBT__ and __SHSTK__ for -fcf-protection.
25103 * config/i386/i386.c (pass_insert_endbranch::gate): Don't check
25104 TARGET_IBT.
25105 (ix86_trampoline_init): Likewise.
25106 (x86_output_mi_thunk): Likewise.
25107 (ix86_notrack_prefixed_insn_p): Likewise.
25108 (ix86_option_override_internal): Don't disallow -fcf-protection.
25109 * config/i386/i386.md (rdssp<mode>): Also enable for
25110 -fcf-protection.
25111 (incssp<mode>): Likewise.
25112 (nop_endbr): Likewise.
25113 * config/i386/i386.opt (mcet): Change help message to built-in
25114 functions only.
25115 (mibt): Likewise.
25116 (mshstk): Likewise.
25117 * doc/invoke.texi: Remove -mcet, -mibt and -mshstk condition
25118 on -fcf-protection. Change -mcet, -mibt and -mshstk to only
25119 enable CET built-in functions.
25120
25121 2018-04-19 Sebastian Peryt <sebastian.peryt@intel.com>
25122
25123 * common/config/i386/i386-common.c
25124 (OPTION_MASK_ISA_MOVDIRI_SET, OPTION_MASK_ISA_MOVDIR64B_SET,
25125 OPTION_MASK_ISA_MOVDIRI_UNSET,
25126 OPTION_MASK_ISA_MOVDIR64B_UNSET): New defines.
25127 (ix86_handle_option): Handle -mmovdiri and -mmovdir64b.
25128 * config.gcc (movdirintrin.h): New header.
25129 * config/i386/cpuid.h (bit_MOVDIRI,
25130 bit_MOVDIR64B): New bits.
25131 * config/i386/driver-i386.c (host_detect_local_cpu): Detect -mmovdiri
25132 and -mmvodir64b.
25133 * config/i386/i386-builtin-types.def ((VOID, PUNSIGNED, UNSIGNED),
25134 (VOID, PVOID, PCVOID)): New function types.
25135 * config/i386/i386-builtin.def (__builtin_ia32_directstoreu_u32,
25136 __builtin_ia32_directstoreu_u64,
25137 __builtin_ia32_movdir64b): New builtins.
25138 * config/i386/i386-c.c (__MOVDIRI__, __MOVDIR64B__): New.
25139 * config/i386/i386.c (ix86_target_string): Added -mmovdir64b
25140 and -mmovdiri.
25141 (ix86_valid_target_attribute_inner_p): Ditto.
25142 (ix86_expand_special_args_builtin): Added VOID_FTYPE_PUNSIGNED_UNSIGNED
25143 and VOID_FTYPE_PUNSIGNED_UNSIGNED.
25144 (ix86_expand_builtin): Expand IX86_BUILTIN_MOVDIR64B.
25145 * config/i386/i386.h (TARGET_MOVDIRI, TARGET_MOVDIRI_P,
25146 TARGET_MOVDIR64B, TARGET_MOVDIR64B_P): New.
25147 * config/i386/i386.md (UNSPECV_MOVDIRI, UNSPECV_MOVDIR64B): New.
25148 (movdiri<mode>, movdir64b_<mode>): New.
25149 * config/i386/i386.opt: Add -mmovdiri and -mmovdir64b.
25150 * config/i386/immintrin.h: Include movdirintrin.h.
25151 * config/i386/movdirintrin.h: New file.
25152 * doc/invoke.texi: Added -mmovdiri and -mmovdir64b.
25153
25154 2018-04-19 Richard Biener <rguenther@suse.de>
25155
25156 PR middle-end/85455
25157 * cfg.c (clear_bb_flags): When loop state says we have
25158 marked irreducible regions also preserve BB_IRREDUCIBLE_LOOP.
25159
25160 2018-04-19 Richard Biener <rguenther@suse.de>
25161
25162 PR tree-optimization/84737
25163 * tree-vect-data-refs.c (vect_copy_ref_info): New function
25164 copying restrict info.
25165 (vect_setup_realignment): Use it.
25166 * tree-vectorizer.h (vect_copy_ref_info): Declare.
25167 * tree-vect-stmts.c (vectorizable_store): Copy ref info from
25168 the first DR to all generated stores.
25169 (vectorizable_load): Likewise for loads.
25170
25171 2018-04-19 Jakub Jelinek <jakub@redhat.com>
25172
25173 PR tree-optimization/85446
25174 * match.pd ((intptr_t) x eq/ne CST to x eq/ne (typeof x) cst): Require
25175 the integral and pointer types to have the same precision.
25176
25177 * doc/install.texi: Document --disable-cet being the default and
25178 --enable-cet=auto.
25179
25180 2018-04-18 Martin Liska <mliska@suse.cz>
25181
25182 * ipa-devirt.c (odr_subtypes_equivalent_p): Fix GNU coding
25183 style.
25184
25185 2018-04-18 Martin Liska <mliska@suse.cz>
25186
25187 Revert
25188 2018-03-02 Eric Botcazou <ebotcazou@adacore.com>
25189
25190 PR ipa/83983
25191 * ipa-devirt.c (odr_subtypes_equivalent_p): Get the ODR type of both
25192 arguments if they are comparable.
25193
25194 2018-04-18 Martin Liska <mliska@suse.cz>
25195
25196 Revert
25197 2018-03-13 Eric Botcazou <ebotcazou@adacore.com>
25198
25199 PR lto/84805
25200 * ipa-devirt.c (odr_subtypes_equivalent_p): Do not get the ODR type of
25201 incomplete types.
25202
25203 2018-04-18 H.J. Lu <hongjiu.lu@intel.com>
25204
25205 PR target/85388
25206 * config/i386/i386.c (ix86_expand_split_stack_prologue): Insert
25207 ENDBR after calling __morestack.
25208
25209 2018-04-18 David Malcolm <dmalcolm@redhat.com>
25210
25211 PR jit/85384
25212 * configure.ac (gcc-driver-name.h): Honor --with-gcc-major-version
25213 by using gcc_base_ver to generate a gcc_driver_version, and use
25214 it when generating GCC_DRIVER_NAME.
25215 * configure: Regenerate.
25216
25217 2018-04-18 Jakub Jelinek <jakub@redhat.com>
25218
25219 PR target/81084
25220 * config.gcc: Obsolete powerpc*-*-*spe*.
25221
25222 2018-04-17 Jakub Jelinek <jakub@redhat.com>
25223
25224 PR debug/84637
25225 * dbxout.c (dbxout_int): Perform negation in unsigned int type.
25226 (stabstr_D): Change type of unum from unsigned int to
25227 unsigned HOST_WIDE_INT. Perform negation in unsigned HOST_WIDE_INT
25228 type.
25229
25230 2018-04-17 Jim Wilson <jimw@sifive.com>
25231
25232 PR 84856
25233 * config/riscv/riscv.c (riscv_compute_frame_info): Add calls to
25234 RISCV_STACK_ALIGN when using outgoing_args_size and pretend_args_size.
25235 Set arg_pointer_offset after using pretend_args_size.
25236
25237 2018-04-17 Jakub Jelinek <jakub@redhat.com>
25238
25239 PR rtl-optimization/85431
25240 * dse.c (record_store): Ignore zero width stores.
25241
25242 PR sanitizer/85230
25243 * asan.c (handle_builtin_stack_restore): Adjust comment. Emit
25244 __asan_allocas_unpoison call and last_alloca_addr = new_sp before
25245 __builtin_stack_restore rather than after it.
25246 * builtins.c (expand_asan_emit_allocas_unpoison): Pass
25247 arg1 + (virtual_dynamic_stack_rtx - stack_pointer_rtx) as second
25248 argument instead of virtual_dynamic_stack_rtx.
25249
25250 2018-04-17 Kelvin Nilsen <kelvin@gcc.gnu.org>
25251
25252 * config/rs6000/rs6000-protos.h (rs6000_builtin_is_supported_p):
25253 New prototype.
25254 * config/rs6000/rs6000-c.c (altivec_resolve_overloaded_builtin):
25255 Add note to error message to explain internal mapping of overloaded
25256 built-in function name to non-overloaded built-in function name.
25257 * config/rs6000/rs6000.c (rs6000_builtin_is_supported_p): New
25258 function.
25259
25260 2018-04-17 Michael Meissner <meissner@linux.vnet.ibm.com>
25261
25262 PR target/85424
25263 * config/rs6000/rs6000.md (pack<mode>): Do not try handle a pack
25264 where the inputs overlap with the output.
25265
25266 2018-04-17 Jakub Jelinek <jakub@redhat.com>
25267
25268 * config/i386/sse.md (vec_extract_lo_<mode><mask_name>): Add
25269 (=v, v) alternative and explicit "memory" attribute.
25270 (vec_extract_lo_<mode><mask_name>): Likewise. Also add
25271 "type", "prefix", "prefix_extra", "length_immediate" and "mode"
25272 attributes.
25273 (vec_extract_lo_<mode><mask_name>): Add (=v, v) alternative and use
25274 "sselog1" type instead of "sselog".
25275 (vec_extract_hi_<mode><mask_name>): Use "sselog1" type instead of
25276 "sselog". Remove explicit "memory" attribute.
25277 (vec_extract_lo_v32hi): Add (=v, v) alternative and explicit "memory",
25278 "type", "prefix", "prefix_extra", "length_immediate" and "mode"
25279 attributes.
25280 (vec_extract_hi_v32hi): Merge all alternatives into one, use
25281 "sselog1" type instead of "sselog". Remove explicit "memory"
25282 attribute.
25283 (vec_extract_hi_v16hi): Merge each pair of alternatives into one,
25284 use "sselog1" type instead of "sselog". Remove explicit "memory"
25285 attribute.
25286 (vec_extract_lo_v64qi): Add (=v, v) alternative and explicit "memory",
25287 "type", "prefix", "prefix_extra", "length_immediate" and "mode"
25288 attributes.
25289 (vec_extract_hi_v64qi): Merge all alternatives into one, use
25290 "sselog1" type instead of "sselog". Remove explicit "memory"
25291 attribute.
25292 (vec_extract_hi_v32qi): Merge each pair of alternatives into one,
25293 use "sselog1" type instead of "sselog". Remove explicit "memory"
25294 attribute.
25295
25296 PR target/85430
25297 * config/i386/i386.md (*ashlqi3_1_slp): Use alu1 type instead of alu.
25298
25299 PR middle-end/85414
25300 * rtlhooks.c (gen_lowpart_if_possible): Don't call gen_lowpart_SUBREG
25301 on a SUBREG.
25302
25303 2018-04-17 Martin Jambor <mjambor@suse.cz>
25304
25305 PR ipa/85421
25306 * ipa-cp.c (create_specialized_node): Call
25307 expand_all_artificial_thunks if necessary.
25308
25309 2018-04-17 Martin Liska <mliska@suse.cz>
25310
25311 PR lto/85405
25312 * ipa-devirt.c (odr_types_equivalent_p): Remove trailing
25313 in message, remote space in between '_G' and '('.
25314
25315 2018-04-17 Jakub Jelinek <jakub@redhat.com>
25316
25317 PR target/85281
25318 * config/i386/sse.md (reduces<mode><mask_scalar_name>,
25319 avx512f_vmcmp<mode>3<round_saeonly_name>,
25320 avx512f_vmcmp<mode>3_mask<round_saeonly_name>,
25321 avx512f_sgetexp<mode><mask_scalar_name><round_saeonly_scalar_name>,
25322 avx512f_rndscale<mode><round_saeonly_name>,
25323 avx512dq_ranges<mode><mask_scalar_name><round_saeonly_scalar_name>,
25324 avx512f_vgetmant<mode><mask_scalar_name><round_saeonly_scalar_name>):
25325 Use %<iptr>2 instead of %2 for -masm=intel.
25326 (avx512f_vcvtss2usi<round_name>, avx512f_vcvtss2usiq<round_name>,
25327 avx512f_vcvttss2usi<round_saeonly_name>,
25328 avx512f_vcvttss2usiq<round_saeonly_name>): Use %k1 instead of %1 for
25329 -masm=intel.
25330 (avx512f_vcvtsd2usi<round_name>, avx512f_vcvtsd2usiq<round_name>,
25331 avx512f_vcvttsd2usi<round_saeonly_name>,
25332 avx512f_vcvttsd2usiq<round_saeonly_name>, ufloatv2siv2df2<mask_name>):
25333 Use %q1 instead of %1 for -masm=intel.
25334 (avx512f_sfixupimm<mode><sd_maskz_name><round_saeonly_name>,
25335 avx512f_sfixupimm<mode>_mask<round_saeonly_name>): Use %<iptr>3 instead
25336 of %3 for -masm=intel.
25337 (sse2_shufpd_v2df_mask): Fix a typo, change %{6%} to %{%6%} for
25338 -masm=intel.
25339 (*avx512vl_<code>v2div2qi2_store): Use %w0 instead of %0 for
25340 -masm=intel.
25341 (*avx512vl_<code><mode>v4qi2_store): Use %k0 instead of %0 for
25342 -masm=intel.
25343 (avx512vl_<code><mode>v4qi2_mask_store): Use a single pattern with
25344 %k0 and %1 for -masm=intel rather than two patterns, one with %0 and
25345 %g1.
25346 (*avx512vl_<code><mode>v8qi2_store): Use %q0 instead of %0 for
25347 -masm=intel.
25348 (avx512vl_<code><mode>v8qi2_mask_store): Use a single pattern with
25349 %q0 and %1 for -masm=intel rather than two patterns, one with %0 and
25350 %g1 and one with %0 and %1.
25351 (avx512er_vmrcp28<mode><round_saeonly_name>,
25352 avx512er_vmrsqrt28<mode><round_saeonly_name>): Use %<iptr>1 instead of
25353 %1 for -masm=intel.
25354 (avx5124fmaddps_4fmaddps_mask, avx5124fmaddps_4fmaddss_mask,
25355 avx5124fmaddps_4fnmaddps_mask, avx5124fmaddps_4fnmaddss_mask,
25356 avx5124vnniw_vp4dpwssd_mask, avx5124vnniw_vp4dpwssds_mask): Swap order
25357 of %0 and %{%4%} for -masm=intel.
25358 (avx5124fmaddps_4fmaddps_maskz, avx5124fmaddps_4fmaddss_maskz,
25359 avx5124fmaddps_4fnmaddps_maskz, avx5124fmaddps_4fnmaddss_maskz,
25360 avx5124vnniw_vp4dpwssd_maskz, avx5124vnniw_vp4dpwssds_maskz): Swap
25361 order of %0 and %{%5%}%{z%} for -masm=intel.
25362
25363 2018-04-17 Jan Hubicka <jh@suse.cz>
25364
25365 PR lto/85405
25366 * ipa-devirt.c (odr_types_equivalent_p): Handle bit fields.
25367
25368 2018-04-17 Martin Liska <mliska@suse.cz>
25369
25370 PR ipa/85329
25371 * multiple_target.c (create_dispatcher_calls): Set apostrophes
25372 for target_clone error message. Make default implementation
25373 clone to be a local declaration.
25374 (separate_attrs): Add new argument and check for an empty
25375 string.
25376 (expand_target_clones): Handle it.
25377 (ipa_target_clone): Make redirection just for target_clones
25378 functions.
25379
25380 2018-04-16 Cesar Philippidis <cesar@codesourcery.com>
25381 Tom de Vries <tom@codesourcery.com>
25382
25383 PR middle-end/84955
25384 * omp-expand.c (expand_oacc_for): Add dummy false branch for
25385 tiled basic blocks without omp continue statements.
25386
25387 2018-04-16 Aaron Sawdey <acsawdey@linux.ibm.com>
25388
25389 PR target/83660
25390 * config/rs6000/rs6000-c.c (altivec_resolve_overloaded_builtin): Mark
25391 vec_extract expression as having side effects to make sure it gets
25392 a cleanup point.
25393
25394 2018-04-16 H.J. Lu <hongjiu.lu@intel.com>
25395
25396 PR target/85403
25397 * config/i386/i386.c (get_builtin_code_for_version): Check
25398 error_mark_node.
25399
25400 2018-04-16 Olga Makhotina <olga.makhotina@intel.com>
25401
25402 PR target/84331
25403 * config.gcc: Support "skylake".
25404 * config/i386/i386-c.c (ix86_target_macros_internal): Handle
25405 PROCESSOR_SKYLAKE.
25406 * config/i386/i386.c (m_SKYLAKE): Define.
25407 (processor_target_table): Add "skylake".
25408 (ix86_option_override_internal): Add "skylake".
25409 (get_builtin_code_for_version): Handle PROCESSOR_SKYLAKE,
25410 PROCESSOR_CANNONLAKE.
25411 (get_builtin_code_for_version): Fix priority for
25412 PROCESSOR_ICELAKE_CLIENT, PROCESSOR_ICELAKE_SERVER,
25413 PROCESSOR_SKYLAKE-AVX512.
25414 * config/i386/i386.h (processor_costs): Define TARGET_SKYLAKE.
25415 (processor_type): Add PROCESSOR_SKYLAKE.
25416
25417 2018-04-16 Paolo Carlini <paolo.carlini@oracle.com>
25418 Jason Merrill <jason@redhat.com>
25419
25420 PR c++/85112
25421 * convert.c (convert_to_integer_1): Use direct recursion for
25422 enumeral types and types with a precision less than the number
25423 of bits in their mode.
25424
25425 2018-04-16 Julia Koval <julia.koval@intel.com>
25426
25427 PR target/84413
25428 * config/i386/x86-tune.def (X86_TUNE_SSE_UNALIGNED_LOAD_OPTIMAL,
25429 X86_TUNE_SSE_UNALIGNED_STORE_OPTIMAL): Add m_SKYLAKE_AVX512
25430
25431 2018-04-14 Segher Boessenkool <segher@kernel.crashing.org>
25432
25433 PR target/85293
25434 * config/rs6000/rs6000.opt (mdirect-move): Make deprecated.
25435 * doc/invoke.texi (RS/6000 and PowerPC Options): Remove -mdirect-move
25436 and -mno-direct-move.
25437
25438 2018-04-13 Paul A. Clarke <pc@us.ibm.com>
25439
25440 PR target/83402
25441 * config/rs6000/emmintrin.h (_mm_slli_epi{16,32,64}):
25442 Ensure that vec_splat_s32 is only called with 0 <= shift < 16.
25443 Ensure negative shifts result in {0}.
25444
25445 2018-04-13 Vladimir Makarov <vmakarov@redhat.com>
25446
25447 PR rtl-optimization/79916
25448 * config/rs6000/rs6000.c (rs6000_emit_move): Use assigned hard
25449 regs (if any) to define how to gnerate SD moves when LRA is in
25450 progress.
25451
25452 2018-04-13 Jakub Jelinek <jakub@redhat.com>
25453
25454 PR rtl-optimization/85393
25455 * except.h (expand_dw2_landing_pad_for_region): Remove declaration.
25456 * except.c (expand_dw2_landing_pad_for_region): Make static.
25457 * bb-reorder.c (fix_up_crossing_landing_pad): In new_bb emit just
25458 a label and unconditional jump to old_bb, rather than
25459 expand_dw2_landing_pad_for_region insn(s) and jump to single_succ
25460 basic block.
25461
25462 PR rtl-optimization/85376
25463 * simplify-rtx.c (simplify_const_unary_operation): For CLZ and CTZ and
25464 zero op0, if C?Z_DEFINED_VALUE_AT_ZERO is false, return NULL_RTX
25465 instead of a specific value.
25466
25467 2018-04-13 Jan Hubicka <hubicka@ucw.cz>
25468 Bin Cheng <bin.cheng@arm.com>
25469
25470 PR tree-optimization/82965
25471 PR tree-optimization/83991
25472 * cfgloopanal.c (expected_loop_iterations_unbounded): Add
25473 by_profile_only parameter.
25474 * cfgloopmanip.c (scale_loop_profile): Further scale loop's profile
25475 information if the loop was predicted to iterate too many times.
25476 * cfgloop.h (expected_loop_iterations_unbounded): Update prototype
25477
25478 2018-04-13 Jan Hubicka <hubicka@ucw.cz>
25479
25480 PR lto/71991
25481 * config/i386/i386.c (ix86_can_inline_p): Allow safe transitions for
25482 always inline.
25483
25484 2018-04-13 Martin Liska <mliska@suse.cz>
25485 Jakub Jelinek <jakub@redhat.com>
25486
25487 PR middle-end/81657
25488 * expr.h (enum block_op_methods): Add BLOCK_OP_NO_LIBCALL_RET.
25489 * expr.c (emit_block_move_hints): Handle BLOCK_OP_NO_LIBCALL_RET.
25490 * builtins.c (expand_builtin_memory_copy_args): Use
25491 BLOCK_OP_NO_LIBCALL_RET method for mempcpy with non-ignored target,
25492 handle dest_addr == pc_rtx.
25493
25494 2018-04-12 Segher Boessenkool <segher@kernel.crashing.org>
25495
25496 PR target/85291
25497 * config/rs6000/rs6000.md (fix_trunc<mode>si2): Use legacy code if
25498 asked to not generate direct moves.
25499 (fix_trunc<mode>si2_stfiwx): Similar.
25500 (fix_trunc<mode>si2_internal): Similar.
25501
25502 2018-04-12 Jakub Jelinek <jakub@redhat.com>
25503
25504 PR debug/83157
25505 * var-tracking.c (add_stores): Handle STRICT_LOW_PART SET_DEST.
25506 * cselib.c (cselib_record_sets): For STRICT_LOW_PART dest,
25507 lookup if dest in some wider mode is known to be const0_rtx and
25508 if so, record permanent equivalence for it to be ZERO_EXTEND of
25509 the narrower mode destination.
25510
25511 2018-04-12 Cesar Philippidis <cesar@codesourcery.com>
25512
25513 * lto-streamer-out.c (output_function): Revert 259346.
25514 * omp-expand.c (expand_oacc_for): Likewise.
25515
25516 2018-04-12 Alexander Monakov <amonakov@ispras.ru>
25517
25518 PR rtl-optimization/85354
25519 * sel-sched-ir.c (sel_init_pipelining): Move cfg_cleanup call...
25520 * sel-sched.c (sel_global_init): ... here.
25521
25522 2018-04-12 Eric Botcazou <ebotcazou@adacore.com>
25523
25524 PR target/85238
25525 * lto-wrapper.c (debug_objcopy): Open the files in binary mode.
25526 * dwarf2out.c (dwarf2out_early_finish): Do not generate assembly in LTO
25527 mode for PE-COFF targets.
25528 * config/i386/i386-protos.h (i386_pe_asm_lto_start): Declare.
25529 (i386_pe_asm_lto_end): Likewise.
25530 * config/i386/cygming.h (TARGET_ASM_LTO_START): Define.
25531 (TARGET_ASM_LTO_END): Likewise.
25532 * config/i386/winnt.c (saved_debug_info_level): New static variable.
25533 (i386_pe_asm_lto_start): New function.
25534 (i386_pe_asm_lto_end): Likewise.
25535
25536 2018-04-12 Cesar Philippidis <cesar@codesourcery.com>
25537 Richard Biener <rguenther@suse.de>
25538
25539 PR middle-end/84955
25540 * lto-streamer-out.c (output_function): Fix CFG loop state before
25541 streaming out.
25542 * omp-expand.c (expand_oacc_for): Handle calls to internal
25543 functions like regular functions.
25544
25545 2018-04-12 Richard Biener <rguenther@suse.de>
25546
25547 PR lto/85371
25548 * dwarf2out.c (init_sections_and_labels): Use debug_line_section[_label]
25549 for the early LTO debug to properly generate references to it
25550 during DIE emission. Do not re-use that for the skeleton for
25551 split-dwarf.
25552 (dwarf2out_early_finish): Likewise.
25553
25554 2018-04-12 Jakub Jelinek <jakub@redhat.com>
25555
25556 PR target/85328
25557 * config/i386/sse.md
25558 (<mask_codefor>avx512dq_vextract<shuffletype>64x2_1<mask_name> split,
25559 <mask_codefor>avx512f_vextract<shuffletype>32x4_1<mask_name> split,
25560 vec_extract_lo_<mode><mask_name> split, vec_extract_lo_v32hi,
25561 vec_extract_lo_v64qi): For non-AVX512VL if input is xmm16+ reg
25562 and output is a reg, avoid creating invalid lowpart subreg, but
25563 instead split into a 512-bit move. Don't split if not AVX512VL,
25564 input is xmm16+ reg and output is a mem.
25565 (vec_extract_lo_<mode><mask_name>, vec_extract_lo_v32hi,
25566 vec_extract_lo_v64qi): Don't require split if not AVX512VL, input is
25567 xmm16+ reg and output is a mem.
25568
25569 2018-04-12 Andreas Krebbel <krebbel@linux.vnet.ibm.com>
25570
25571 * config/s390/s390.c (s390_output_indirect_thunk_function): Check
25572 also for flag_dwarf2_cfi_asm.
25573
25574 2018-04-12 Jakub Jelinek <jakub@redhat.com>
25575
25576 PR rtl-optimization/85342
25577 * regcprop.c (copyprop_hardreg_forward_1): Remove replaced array, use
25578 a bool scalar var inside of the loop instead. Don't try to update
25579 recog_data.operand after failed apply_change_group.
25580
25581 2018-04-12 Tom de Vries <tom@codesourcery.com>
25582
25583 PR target/85296
25584 * config/nvptx/nvptx.c (flexible_array_member_type_p): New function.
25585 (nvptx_assemble_decl_begin): Add undefined param. Declare undefined
25586 array with flexible array member as array without given dimension.
25587 (nvptx_assemble_undefined_decl): Set nvptx_assemble_decl_begin call
25588 argument for undefined param to true.
25589
25590 2018-04-11 Aaron Sawdey <acsawdey@linux.ibm.com>
25591
25592 PR target/85321
25593 * doc/invoke.texi (RS/6000 and PowerPC Options): Document options
25594 -mcall- and -mtraceback=. Remove options -mabi=spe and -mabi=no-spe
25595 from PowerPC section.
25596 * config/rs6000/sysv4.opt (mcall-): Improve help text.
25597 * config/rs6000/rs6000.opt (mblock-compare-inline-limit=): Trim
25598 help text that is too long.
25599 * config/rs6000/rs6000.opt (mblock-compare-inline-loop-limit=): Trim
25600 help text that is too long.
25601 * config/rs6000/rs6000.opt (mstring-compare-inline-limit=): Trim
25602 help text that is too long.
25603
25604 2018-04-11 Uros Bizjak <ubizjak@gmail.com>
25605
25606 * config/alpha/alpha.md (stack_probe_internal): Rename
25607 from "probe_stack". Update all callers.
25608
25609 2018-04-11 Alexander Monakov <amonakov@ispras.ru>
25610
25611 PR rtl-optimization/84566
25612 * sched-deps.c (sched_analyze_insn): Check deps->readonly when invoking
25613 sched_macro_fuse_insns.
25614
25615 2018-04-11 Alexander Monakov <amonakov@ispras.ru>
25616
25617 PR target/84301
25618 * sched-rgn.c (add_branch_dependences): Move sel_sched_p check here...
25619 (compute_block_dependences): ... from here.
25620
25621 2018-04-11 Jakub Jelinek <jakub@redhat.com>
25622
25623 PR tree-optimization/85331
25624 * vec-perm-indices.h (vec_perm_indices::clamp): Change input type
25625 from int to HOST_WIDE_INT.
25626
25627 2018-04-11 Martin Jambor <mjambor@suse.cz>
25628
25629 PR ipa/84149
25630 * ipa-cp.c (propagate_vals_across_pass_through): Expand comment.
25631 (cgraph_edge_brings_value_p): New parameter dest_val, check if it is
25632 not the same as the source val.
25633 (cgraph_edge_brings_value_p): New parameter.
25634 (gather_edges_for_value): Pass destination value to
25635 cgraph_edge_brings_value_p.
25636 (perhaps_add_new_callers): Likewise.
25637 (get_info_about_necessary_edges): Likewise and exclude values brought
25638 only by self-recursive edges.
25639 (create_specialized_node): Redirect only clones of self-calling edges.
25640 (+self_recursive_pass_through_p): New function.
25641 (find_more_scalar_values_for_callers_subset): Use it.
25642 (find_aggregate_values_for_callers_subset): Likewise.
25643 (known_aggs_to_agg_replacement_list): Removed.
25644 (decide_whether_version_node): Re-calculate known constants for all
25645 remaining context clones.
25646
25647 2018-04-11 Richard Biener <rguenther@suse.de>
25648
25649 PR lto/85339
25650 * dwarf2out.c (dwarf2out_finish): Remove DW_AT_stmt_list attribute
25651 from early DWARF output.
25652 (dwarf2out_early_finish): Output line info unconditionally into
25653 early DWARF and add reference to it.
25654
25655 2018-04-11 Jakub Jelinek <jakub@redhat.com>
25656
25657 PR target/85281
25658 * config/i386/sse.md (iptr): Add V16SFmode and V8DFmode cases.
25659 (<avx512>_vec_dup<mode><mask_name>): Use a single pattern for modes
25660 other than V2DFmode using iptr mode attribute.
25661 (<avx512>_vec_dup<mode><mask_name>): Use iptr mode attribute.
25662
25663 2018-04-11 Alexander Monakov <amonakov@ispras.ru>
25664
25665 PR rtl-optimization/84659
25666 * sel-sched-ir.c (sel_init_pipelining): Invoke cleanup_cfg.
25667
25668 2018-04-11 Jakub Jelinek <jakub@redhat.com>
25669
25670 PR debug/85302
25671 * dwarf2out.c (skip_loc_list_entry): Don't call size_of_locs if
25672 SIZEP is NULL.
25673 (output_loc_list): Pass address of a dummy size variable even in the
25674 locview handling loop.
25675 (index_location_lists): Add comment on why skip_loc_list_entry can't
25676 call size_of_locs.
25677
25678 2018-04-11 Thomas Preud'homme <thomas.preudhomme@arm.com>
25679
25680 PR target/85261
25681 * config/arm/arm-builtins.c (arm_expand_builtin): Force input operand
25682 into register.
25683
25684 2018-04-10 Aaron Sawdey <acsawdey@linux.ibm.com>
25685
25686 PR target/85321
25687 * doc/invoke.texi (RS/6000 and PowerPC Options): Document options
25688 -mblock-compare-inline-limit, -mblock-compare-inline-loop-limit,
25689 and -mstring-compare-inline-limit.
25690
25691 2018-04-10 Segher Boessenkool <segher@kernel.crashing.org>
25692
25693 PR target/85287
25694 * config/rs6000/rs6000.md (allocate_stack): Put the residual size
25695 for stack clash protection in a register whenever we need it to be in
25696 a register.
25697
25698 2018-04-10 Segher Boessenkool <segher@kernel.crashing.org>
25699
25700 * common/config/rs6000/rs6000-common.c (rs6000_option_init_struct):
25701 Enable -fasynchronous-unwind-tables by default if OBJECT_FORMAT_ELF.
25702
25703 2018-04-10 Segher Boessenkool <segher@kernel.crashing.org>
25704
25705 PR target/85321
25706 * config/rs6000/rs6000.opt (mtraceback=): Show the allowed values in
25707 the help text.
25708 (mlong-double-): Ditto.
25709 * config/rs6000/sysv4.opt (msdata=): Ditto.
25710 (mtls-size=): Ditto.
25711
25712 2018-04-10 Kelvin Nilsen <kelvin@gcc.gnu.org>
25713
25714 * config/rs6000/rs6000-c.c (altivec_overloaded_builtins): Remove
25715 erroneous entries for
25716 "vector int vec_ldl (int, long int *)", and
25717 "vector unsigned int vec_ldl (int, unsigned long int *)".
25718 Add comments and entries for
25719 "vector bool char vec_ldl (int, bool char *)",
25720 "vector bool short vec_ldl (int, bool short *)",
25721 "vector bool int vec_ldl (int, bool int *)",
25722 "vector bool long long vec_ldl (int, bool long long *)",
25723 "vector pixel vec_ldl (int, pixel *)",
25724 "vector long long vec_ldl (int, long long *)",
25725 "vector unsigned long long vec_ldl (int, unsigned long long *)".
25726 * config/rs6000/rs6000.c (rs6000_init_builtins): Initialize new
25727 type tree bool_long_long_type_node and correct definition of
25728 bool_V2DI_type_node to make reference to this new type tree.
25729 (rs6000_mangle_type): Replace erroneous reference to
25730 bool_long_type_node with bool_long_long_type_node.
25731 * config/rs6000/rs6000.h (enum rs6000_builtin_type_index): Add
25732 comments to emphasize sign distinctions for char and int types and
25733 replace RS6000_BTI_bool_long constant with
25734 RS6000_BTI_bool_long_long constant. Also add comment to restrict
25735 use of RS6000_BTI_pixel.
25736 (bool_long_type_node): Remove this macro definition.
25737 (bool_long_long_type_node): New macro definition
25738
25739 2018-04-10 Jakub Jelinek <jakub@redhat.com>
25740
25741 PR rtl-optimization/85300
25742 * combine.c (subst): Handle subst of CONST_SCALAR_INT_P new_rtx also
25743 into FLOAT and UNSIGNED_FLOAT like ZERO_EXTEND, return a CLOBBER if
25744 simplify_unary_operation fails.
25745
25746 2018-04-10 Martin Liska <mliska@suse.cz>
25747
25748 * gdbhooks.py: Add pretty-printers for varpool_node, symtab_node,
25749 cgraph_edge and ipa_ref.
25750
25751 2018-04-10 Jakub Jelinek <jakub@redhat.com>
25752
25753 PR target/85177
25754 PR target/85255
25755 * config/i386/sse.md
25756 (<extract_type>_vinsert<shuffletype><extract_suf>_mask): Fix
25757 computation of the VEC_MERGE selector from mask.
25758 (<extract_type>_vinsert<shuffletype><extract_suf>_1<mask_name>):
25759 Fix decoding of the VEC_MERGE selector into mask.
25760
25761 2018-04-10 Richard Sandiford <richard.sandiford@linaro.org>
25762
25763 PR tree-optimization/85286
25764 * tree-vect-data-refs.c (vect_get_smallest_scalar_type):
25765
25766 2018-04-10 Richard Sandiford <richard.sandiford@linaro.org>
25767
25768 * final.c (final_1): Set insn_last_address as well as
25769 insn_current_address.
25770
25771 2018-04-10 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
25772
25773 PR target/85173
25774 * explow.c (emit_stack_probe): Call validize_mem on memory location
25775 before passing it to gen_probe_stack. Create address operand and
25776 legitimize it for the probe_stack_address case.
25777
25778 2018-04-09 Jan Hubicka <jh@suse.cz>
25779
25780 PR lto/85078
25781 * ipa-devirt.c (rebuild_type_inheritance-hash): New.
25782 * ipa-utils.h (rebuild_type_inheritance-hash): Declare.
25783 * tree.c (free_lang_data_in_type): Fix handling of binfos;
25784 walk basetypes.
25785 (free_lang_data): Rebuild type inheritance graph.
25786
25787 2018-04-09 Martin Sebor <msebor@redhat.com>
25788
25789 * invoke.texi (-finline-small-functions): Mention other optimization
25790 options.
25791 (-findirect-inlining, -fpartial-inlining): Same.
25792 (-finline-functions-called-once): Same.
25793 (-freorder-blocks-and-partition): Same.
25794
25795 2018-04-09 Jan Hubicka <jh@suse.cz>
25796
25797 PR rtl/84058
25798 * cfgcleanup.c (try_forward_edges): Do not give up on crossing
25799 jumps; choose last target that matches the criteria (i.e.
25800 no partition changes for non-crossing jumps).
25801 * cfgrtl.c (cfg_layout_redirect_edge_and_branch): Add basic
25802 support for redirecting crossing jumps to non-crossing.
25803
25804 2018-04-09 Alexey Brodkin <abrodkin@synopsys.com>
25805
25806 * config/arc/arc.c (arc_expand_prologue): Set stack usage info
25807 also for naked functions.
25808
25809 2018-04-09 Claudiu Zissulescu <claziss@synopsys.com>
25810
25811 * config/arc/arc.md (add_shift): New pattern.
25812 (add_shift2): Likewise.
25813 (sub_shift): Likewise.
25814 (sub_shift_cmp0_noout): Likewise.
25815 (compare_si_ashiftsi): Likewise.
25816 (xbfu_cmp0_noout): New combine pattern.
25817 (xbfu_cmp0"): Likewise.
25818 (movsi_set_cc_insn): Place the predicable variant first.
25819 (commutative_binary_cmp0_noout): Remove clobber.
25820 (commutative_binary_cmp0): New pattern.
25821 (noncommutative_binary_cmp0): Likewise.
25822 (noncommutative_binary_cmp0_noout): Likewise.
25823 (noncommutative_binary_comparison_result_used): Removed.
25824 (rsub_cmp0): New pattern.
25825 (rsub_cmp0_noout): Likewise.
25826 (extzvsi): Changed, keep only meaningful variants.
25827 (SQH, SEZ): New iterators.
25828 (SQH_postfix): New mode attribute.
25829 (SEZ_prefix): New code attribute.
25830 (<SEZ_prefix>xt<SQH_postfix>_cmp0_noout): New instruction pattern.
25831 (<SEZ_prefix>xt<SQH_postfix>_cmp0): Likewise.
25832 * config/arc/predicates.md (cc_set_register): Use CC_REG instead
25833 of numerical value.
25834 (noncommutative_operator): Check the availability of barrel
25835 shifter option.
25836
25837 2018-04-09 Richard Biener <rguenther@suse.de>
25838
25839 PR tree-optimization/85284
25840 * tree-ssa-loop-niter.c (number_of_iterations_exit_assumptions):
25841 Only use the niter constraining form of simple_iv when the exit
25842 is always executed.
25843
25844 2018-04-09 Tom de Vries <tom@codesourcery.com>
25845
25846 PR target/84041
25847 * config/nvptx/nvptx.md (define_c_enum "unspecv"): Add UNSPECV_MEMBAR.
25848 (define_expand "*memory_barrier"): New define_expand.
25849 (define_insn "memory_barrier"): New insn.
25850
25851 2018-04-09 Andrey Belevantsev <abel@ispras.ru>
25852
25853 PR rtl-optimization/80463
25854 PR rtl-optimization/83972
25855 PR rtl-optimization/83480
25856
25857 * sel-sched-ir.c (has_dependence_note_mem_dep): Take into account the
25858 correct producer for the insn.
25859 (tidy_control_flow): Fixup seqnos in case of debug insns.
25860
25861 2018-04-09 Andrey Belevantsev <abel@ispras.ru>
25862
25863 PR rtl-optimization/83913
25864
25865 * sel-sched-ir.c (merge_expr_data): Choose the middle between two
25866 different sched-times when merging exprs.
25867
25868 2018-04-09 Andrey Belevantsev <abel@ispras.ru>
25869
25870 PR rtl-optimization/83962
25871
25872 * sel-sched-ir.c (tidy_control_flow): Correct the order in which we call
25873 tidy_fallthru_edge and tidy_control_flow.
25874
25875 2018-04-09 Andrey Belevantsev <abel@ispras.ru>
25876
25877 PR rtl-optimization/83530
25878
25879 * sel-sched.c (force_next_insn): New global variable.
25880 (remove_insn_for_debug): When force_next_insn is true, also leave only
25881 next insn in the ready list.
25882 (sel_sched_region): When the region wasn't scheduled, make another pass
25883 over it with force_next_insn set to 1.
25884
25885 2018-04-08 Monk Chiang <sh.chiang04@gmail.com>
25886
25887 * config.gcc (nds32le-*-*, nds32be-*-*): Add nds32/nds32_intrinsic.h
25888 into tm_file.
25889 * config/nds32/constants.md (unspec_volatile_element): Add enum values
25890 for interrupt control.
25891 * config/nds32/nds32-intrinsic.c: Implementation of intrinsic
25892 functions for interrupt control.
25893 * config/nds32/nds32-intrinsic.md: Likewise.
25894 * config/nds32/nds32_intrinsic.h: Likewise.
25895 * config/nds32/nds32.h (nds32_builtins): Likewise.
25896
25897 2018-04-08 Chung-Ju Wu <jasonwucj@gmail.com>
25898
25899 * config/nds32/nds32.c (nds32_init_machine_status,
25900 nds32_legitimate_index_p, nds32_legitimate_address_p): Consider
25901 strict_aligned_p field.
25902 (nds32_expand_to_rtl_hook): New function.
25903 (TARGET_EXPAND_TO_RTL_HOOK): Define.
25904 * config/nds32/nds32.h (machine_function): Add strict_aligned_p field.
25905
25906 2018-04-08 Kito Cheng <kito.cheng@gmail.com>
25907 Chung-Ju Wu <jasonwucj@gmail.com>
25908
25909 * config.gcc (nds32*-*-*): Check that n7 is valid to --with-cpu.
25910 * config/nds32/nds32-n7.md: New file.
25911 * config/nds32/nds32-opts.h (nds32_cpu_type): Add CPU_N7.
25912 * config/nds32/nds32-pipelines-auxiliary.c: Implementation for n7
25913 pipeline.
25914 * config/nds32/nds32-protos.h: More declarations for n7 pipeline.
25915 * config/nds32/nds32.md (pipeline_model): Add n7.
25916 * config/nds32/nds32.opt (mcpu): Support n7 pipeline cpus.
25917 * config/nds32/pipelines.md: Include n7 settings.
25918
25919 2018-04-08 Kito Cheng <kito.cheng@gmail.com>
25920 Chung-Ju Wu <jasonwucj@gmail.com>
25921
25922 * config.gcc (nds32*-*-*): Check that e8 is valid to --with-cpu.
25923 * config/nds32/nds32-e8.md: New file.
25924 * config/nds32/nds32-opts.h (nds32-cpu_type): Add CPU_E8.
25925 * config/nds32/nds32-pipelines-auxiliary.c: Implementation for e8
25926 pipeline.
25927 * config/nds32/nds32-protos.h: More declarations for e8 pipeline.
25928 * config/nds32/nds32.md (pipeline_model): Add e8.
25929 * config/nds32/nds32.opt (mcpu): Support e8 pipeline cpus.
25930 * config/nds32/pipelines.md: Include e8 settings.
25931
25932 2018-04-08 Kito Cheng <kito.cheng@gmail.com>
25933 Chung-Ju Wu <jasonwucj@gmail.com>
25934
25935 * config.gcc (nds32*-*-*): Check that n6/n8/s8 are valid to --with-cpu.
25936 * config/nds32/nds32-n8.md: New file.
25937 * config/nds32/nds32-opts.h (nds32_cpu_type): Add CPU_N6 and CPU_N8.
25938 * config/nds32/nds32-pipelines-auxiliary.c: Implementation for n8
25939 pipeline.
25940 * config/nds32/nds32-protos.h: More declarations for n8 pipeline.
25941 * config/nds32/nds32-utils.c: More implementations for n8 pipeline.
25942 * config/nds32/nds32.md (pipeline_model): Add n8.
25943 * config/nds32/nds32.opt (mcpu): Support n8 pipeline cpus.
25944 * config/nds32/pipelines.md: Include n8 settings.
25945
25946 2018-04-08 Kito Cheng <kito.cheng@gmail.com>
25947 Chung-Ju Wu <jasonwucj@gmail.com>
25948
25949 * config.gcc (nds32*): Add nds32-utils.o into extra_objs.
25950 * config/nds32/nds32-n9-2r1w.md: New file.
25951 * config/nds32/nds32-n9-3r2w.md: New file.
25952 * config/nds32/nds32-opts.h (nds32_cpu_type, nds32_mul_type,
25953 nds32_register_ports): New or modify for cpu n9.
25954 * config/nds32/nds32-pipelines-auxiliary.c: Implementation for n9
25955 pipeline.
25956 * config/nds32/nds32-protos.h: More declarations for n9 pipeline.
25957 * config/nds32/nds32-utils.c: New file.
25958 * config/nds32/nds32.h (TARGET_PIPELINE_N9, TARGET_PIPELINE_SIMPLE,
25959 TARGET_MUL_SLOW): Define.
25960 * config/nds32/nds32.md (pipeline_model): New attribute.
25961 * config/nds32/nds32.opt (mcpu, mconfig-mul, mconfig-register-ports):
25962 New options that support cpu n9.
25963 * config/nds32/pipelines.md: Include n9 settings.
25964 * config/nds32/t-nds32 (nds32-utils.o): Add dependency.
25965
25966 2018-04-08 Chung-Ju Wu <jasonwucj@gmail.com>
25967
25968 * config/nds32/nds32-md-auxiliary.c (output_cond_branch): Output align
25969 information if necessary.
25970 (output_cond_branch_compare_zero): Likewise.
25971 * config/nds32/nds32.c (nds32_adjust_insn_length): Consider align case.
25972 (nds32_target_alignment): Refine for alignment.
25973 * config/nds32/nds32.h (NDS32_ALIGN_P): Define.
25974 (FUNCTION_BOUNDARY): Modify.
25975 * config/nds32/nds32.md (call_internal, call_value_internal): Consider
25976 align case.
25977 * config/nds32/nds32.opt (malways-align, malign-functions): New.
25978
25979 2018-04-08 Monk Chiang <sh.chiang04@gmail.com>
25980
25981 * config/nds32/constants.md (unspec_volatile_element): Add values for
25982 TLB operation and data prefetch.
25983 * config/nds32/nds32-intrinsic.c: Implementation of intrinsic
25984 functions for TLB operation and data prefetch.
25985 * config/nds32/nds32-intrinsic.md: Likewise.
25986 * config/nds32/nds32_intrinsic.h: Likewise.
25987 * config/nds32/nds32.c (nds32_dpref_names): Likewise.
25988 (nds32_print_operand): Likewise.
25989 * config/nds32/nds32.h (nds32_builtins): Likewise.
25990
25991 2018-04-07 Thomas Koenig <tkoenig@gcc.gnu.org>
25992 Andrew Pinski <pinsika@gcc.gnu.org>
25993
25994 PR middle-end/82976
25995 * match.pd: Use constant_boolean_node of correct type instead of
25996 boolean_true_node or boolean_false_node for simplifying
25997 pointer comparisons to zero.
25998
25999 2018-04-07 Jakub Jelinek <jakub@redhat.com>
26000
26001 PR tree-optimization/80021
26002 * tree.c (verify_type_variant): Make error call in verify_variant_match
26003 translatable and remove final full stop.
26004
26005 2018-04-07 Chung-Ju Wu <jasonwucj@gmail.com>
26006
26007 * config/nds32/constants.md (unspec_volatile_element): Add
26008 UNSPEC_VOLATILE_EH_RETURN.
26009 * config/nds32/nds32-md-auxiliary.c (nds32_output_stack_push,
26010 nds32_output_stack_pop): Support dwarf exception handling process.
26011 * config/nds32/nds32-protos.h (nds32_dynamic_chain_address): Declare.
26012 * config/nds32/nds32.c (nds32_init_machine_status): Support dwarf
26013 exception handling process.
26014 (nds32_compute_stack_frame): Likewise.
26015 (nds32_return_addr_rtx): Likewise.
26016 (nds32_initial_elimination_offset): Likewise.
26017 (nds32_expand_prologue): Likewise.
26018 (nds32_expand_epilogue): Likewise.
26019 (nds32_dynamic_chain_address): New function.
26020 * config/nds32/nds32.h (machine_function): Add fields for dwarf
26021 exception handling.
26022 (DYNAMIC_CHAIN_ADDRESS): Define.
26023 (EH_RETURN_DATA_REGNO): Define.
26024 (EH_RETURN_STACKADJ_RTX): Define.
26025 * config/nds32/nds32.md (eh_return, nds32_eh_return): Implement
26026 patterns for dwarf exception handling.
26027
26028 2018-04-07 Chung-Ju Wu <jasonwucj@gmail.com>
26029
26030 * config/nds32/nds32.h: Clean up obsolete macros.
26031
26032 2018-04-07 Monk Chiang <sh.chiang04@gmail.com>
26033
26034 * config/nds32/constants.md (unspec_element, unspec_volatile_element):
26035 Add enum values for particular instructions.
26036 * config/nds32/nds32-intrinsic.c: Implementation of expanding
26037 particular intrinsic functions.
26038 * config/nds32/nds32-intrinsic.md: Likewise.
26039 * config/nds32/nds32_intrinsic.h: Likewise.
26040 * config/nds32/nds32.h (nds32_builtins): Likewise.
26041 * config/nds32/nds32.md (type): Add pbsad and pbsada.
26042 (btst, ave): New patterns for particular instructions.
26043
26044 2018-04-07 Monk Chiang <sh.chiang04@gmail.com>
26045
26046 * config/nds32/constants.md (unspec_element, unspec_volatile_element):
26047 Add enum values for atomic load/store and memory sync.
26048 * config/nds32/nds32-intrinsic.c: Implementation for atomic load/store
26049 and memory sync.
26050 * config/nds32/nds32-intrinsic.md: Likewise.
26051 * config/nds32/nds32_intrinsic.h: Likewise.
26052 * config/nds32/nds32.h (nds32_builtins): Likewise.
26053
26054 2018-04-07 Jakub Jelinek <jakub@redhat.com>
26055
26056 PR tree-optimization/85257
26057 * fold-const.c (native_encode_vector): If not all elts could fit
26058 and off is -1, return 0 rather than offset.
26059 * tree-ssa-sccvn.c (vn_reference_lookup_3): Pass
26060 (offseti - offset2) / BITS_PER_UNIT as 4th argument to
26061 native_encode_expr. Verify len * BITS_PER_UNIT >= maxsizei. Don't
26062 adjust buffer in native_interpret_expr call.
26063
26064 2018-04-07 Monk Chiang <sh.chiang04@gmail.com>
26065
26066 * config/nds32/constants.md (unspec_volatile_element): Add cache
26067 control enum values.
26068 * config/nds32/nds32-intrinsic.c: Add cache control expand functions.
26069 * config/nds32/nds32-intrinsic.md: Add cache control patterns.
26070 * config/nds32/nds32.c (nds32_cctl_names): New.
26071 (nds32_print_operand): Handle cache control register names.
26072 * config/nds32/nds32.h (nds32_builtins): New enum values.
26073 * config/nds32/nds32_intrinsic.h: Add cache control enum types and
26074 macros.
26075 * config/nds32/nds32.md (type): Add mmu.
26076 * config/nds32/pipelines.md (simple_insn): Add mmu.
26077
26078 2018-04-07 Chung-Ju Wu <jasonwucj@gmail.com>
26079
26080 * config/nds32/nds32.md (type): Remove call.
26081 * config/nds32/pipelines.md (simple_insn): Likewise.
26082
26083 2018-04-07 Monk Chiang <sh.chiang04@gmail.com>
26084
26085 * config/nds32/constants.md (unspec_volatile_element): Add
26086 UNSPEC_VOLATILE_FMFCSR, UNSPEC_VOLATILE_FMTCSR and
26087 UNSPEC_VOLATILE_FMFCFG.
26088 * config/nds32/nds32-intrinsic.c (bdesc_noarg): New builtin
26089 description for fmfcfg and fmfcsr.
26090 (bdesc_1arg): Add fmtcsr.
26091 (bdesc_2arg): Add fcpynss, fcpyss, fcpynsd and fcpysd.
26092 (nds32_expand_builtin_impl): Deal with FPU intrinsic functions.
26093 * config/nds32/nds32-intrinsic.md (unspec_fcpynsd, unspec_fcpysd,
26094 unspec_fcpynss, unspec_fcpysd, unspec_fcpyss, unspec_fmfcsr,
26095 unspec_fmfcfg): New patterns.
26096 * config/nds32/nds32.h (nds32_builtins): Add NDS32_BUILTIN_FMFCFG,
26097 NDS32_BUILTIN_FMFCSR, NDS32_BUILTIN_FMTCSR, NDS32_BUILTIN_FCPYNSS,
26098 NDS32_BUILTIN_FCPYSS,NDS32_BUILTIN_FCPYNSD and NDS32_BUILTIN_FCPYSD.
26099 * config/nds32/nds32_intrinsic.h (__nds32__fcpynsd, __nds32__fcpynss,
26100 __nds32__fcpysd, __nds32__fcpyss, __nds32__fmfcsr, __nds32__fmtcsr,
26101 __nds32__fmfcfg): Define.
26102
26103 2018-04-07 Monk Chiang <sh.chiang04@gmail.com>
26104
26105 * config/nds32/nds32.c (nds32_intrinsic_register_names): Add more
26106 intrinsic register names.
26107 * config/nds32/nds32_intrinsic.h (nds32_intrinsic_registers): Add more
26108 intrinsic register enum values and macros.
26109
26110 2018-04-07 Chung-Ju Wu <jasonwucj@gmail.com>
26111
26112 * config/nds32/nds32.c (nds32_legitimate_index_p): Modify condition
26113 for load/store addressing form.
26114 (nds32_print_operand_address): Likewise.
26115
26116 2018-04-06 Eric Botcazou <ebotcazou@adacore.com>
26117
26118 PR target/85196
26119 * config/sparc/sparc.c (sparc_expand_move): Deal with symbolic operands
26120 based on LABEL_REF. Remove useless assertion.
26121 (pic_address_needs_scratch): Fix formatting.
26122 (sparc_legitimize_pic_address): Minor tweaks.
26123 (sparc_delegitimize_address): Adjust assertion accordingly.
26124 * config/sparc/sparc.md (movsi_pic_label_ref): Change label_ref_operand
26125 into symbolic_operand.
26126 (movsi_high_pic_label_ref): Likewise.
26127 (movsi_lo_sum_pic_label_ref): Likewise.
26128 (movdi_pic_label_ref): Likewise.
26129 (movdi_high_pic_label_ref): Likewise.
26130 (movdi_lo_sum_pic_label_ref): Likewise.
26131
26132 2018-04-06 Amaan Cheval <amaan.cheval@gmail.com>
26133
26134 * config.gcc (x86_64-*-rtems*): Add rtems.h to tm_file for
26135 custom LIB_SPEC setup.
26136
26137 2018-04-06 Ruslan Bukin <br@bsdpad.com>
26138 Kito Cheng <kito.cheng@gmail.com>
26139
26140 * config.gcc (riscv*-*-freebsd*): Add RISC-V FreeBSD support.
26141 * config/riscv/freebsd.h: New.
26142
26143 2018-04-06 Chung-Ju Wu <jasonwucj@gmail.com>
26144
26145 * config/nds32/nds32.c (nds32_adjust_insn_length): Refine.
26146 * config/nds32/nds32.h (ADJUST_INSN_LENGTH): Change the location in
26147 file.
26148
26149 2018-04-06 Chung-Ju Wu <jasonwucj@gmail.com>
26150 Kito Cheng <kito.cheng@gmail.com>
26151
26152 * config/nds32/nds32-md-auxiliary.c (nds32_output_return,
26153 nds32_output_call, nds32_symbol_binds_local_p): New functions.
26154 * config/nds32/nds32-protos.h (nds32_output_call,
26155 nds32_output_return): Declare.
26156 * config/nds32/nds32.md: Refine all the call and return patterns.
26157
26158 2018-04-06 Jakub Jelinek <jakub@redhat.com>
26159
26160 PR debug/85252
26161 * dwarf2out.c (rtl_for_decl_init): For STRING_CST initializer only
26162 build CONST_STRING if TYPE_MAX_VALUE is non-NULL and is INTEGER_CST.
26163
26164 PR rtl-optimization/84872
26165 * cfgloopmanip.c (create_preheader): Use make_forwarder_block even if
26166 nentry == 1 when CP_FALLTHRU_PREHEADERS and single_entry is
26167 EDGE_CROSSING edge.
26168
26169 2018-04-06 Tamar Christina <tamar.christina@arm.com>
26170
26171 * expr.c (copy_blkmode_to_reg): Revert 254862.
26172 * doc/sourcebuild.texi (word_mode_no_slow_unalign): Likewise.
26173
26174 2018-04-06 Richard Biener <rguenther@suse.de>
26175
26176 PR middle-end/85244
26177 * tree-dfa.c (get_ref_base_and_extent): Reset seen_variable_array_ref
26178 after seeing a component reference with an adjacent field. Treat
26179 refs to arrays at struct end of external decls similar to
26180 refs to unconstrained commons.
26181
26182 2018-04-06 Jakub Jelinek <jakub@redhat.com>
26183
26184 PR sanitizer/85213
26185 * fold-const.c (twoval_comparison_p): Remove SAVE_P argument and don't
26186 look through SAVE_EXPRs with non-side-effects argument. Adjust
26187 recursive calls.
26188 (fold_comparison): Adjust twoval_comparison_p caller, don't handle
26189 save_p here.
26190
26191 2018-04-06 Richard Biener <rguenther@suse.de>
26192
26193 PR middle-end/85180
26194 * alias.c (find_base_term): New wrapper around find_base_term
26195 unwinding CSELIB_VAL_PTR changes.
26196 (find_base_term): Do not restore CSELIB_VAL_PTR during the
26197 recursion.
26198
26199 2018-04-06 Andreas Krebbel <krebbel@linux.vnet.ibm.com>
26200
26201 * config/s390/s390.c (s390_z10_optimize_cmp): Expand dedicated NOP
26202 instructions.
26203 * config/s390/s390.md (UNSPECV_NOP_LR_0, UNSPECV_NOP_LR_1): New
26204 constant definitions.
26205 ("nop"): lr 0,0 -> nopr r0
26206 ("nop_lr0", "nop_lr1"): New insn definitions.
26207
26208 2018-04-06 Chung-Ju Wu <jasonwucj@gmail.com>
26209
26210 * config/nds32/nds32.md (*stack_push, *stack_pop): Use
26211 NDS32_V3PUSH_AVAILABLE_P macro.
26212
26213 2018-04-06 Monk Chiang <sh.chiang04@gmail.com>
26214 Chung-Ju Wu <jasonwucj@gmail.com>
26215
26216 * config.gcc (nds32*-*-*): Add v2j v3f v3s checking.
26217 (nds32*-*-*): Add float and fpu_config into supported_defaults.
26218 * common/config/nds32/nds32-common.c (TARGET_DEFAULT_TARGET_FLAGS):
26219 Include TARGET_DEFAULT_FPU_ISA and TARGET_DEFAULT_FPU_FMA.
26220 * config/nds32/constants.md (unspec_element): Add UNSPEC_COPYSIGN,
26221 UNSPEC_FCPYNSD, UNSPEC_FCPYNSS, UNSPEC_FCPYSD and UNSPEC_FCPYSS.
26222 * config/nds32/constraints.md: New constraints and checking for hard
26223 float configuration.
26224 * config/nds32/iterators.md: New mode iterator and attribute for hard
26225 float configuration.
26226 * config/nds32/nds32-doubleword.md: Use hard float alternatives and
26227 patterns.
26228 * config/nds32/nds32-fpu.md: New file.
26229 * config/nds32/nds32-md-auxiliary.c: New functions and checkings to
26230 deal with hard float code generation.
26231 * config/nds32/nds32-opts.h (nds32_arch_type): Add ARCH_V3F and
26232 ARCH_V3S.
26233 (abi_type, float_reg_number): New enum type.
26234 * config/nds32/nds32-predicates.c: New predicates for hard float.
26235 * config/nds32/nds32-protos.h: Declare functions for hard float.
26236 * config/nds32/nds32.c: Implementation for hard float configuration.
26237 * config/nds32/nds32.h: Definitions for hard float configuration.
26238 * config/nds32/nds32.md: Include hard float machine description and
26239 modify patterns for hard float configuration.
26240 * config/nds32/nds32.opt: New options for hard float configuration.
26241 * config/nds32/predicates.md: New predicates for hard float
26242 configuration.
26243
26244 2018-04-06 Kuan-Lin Chen <kuanlinchentw@gmail.com>
26245
26246 * common/config/nds32/nds32-common.c
26247 (nds32_option_optimization_table): Enable -mreleax-hint by default.
26248
26249 2018-04-05 Jakub Jelinek <jakub@redhat.com>
26250
26251 PR middle-end/85195
26252 * match.pd (BIT_FIELD_REF CONSTRUCTOR@0 @1 @2): Use view_convert around
26253 CONSTRUCTOR_ELT (ctor, ...)->value.
26254
26255 2018-04-05 Uros Bizjak <ubizjak@gmail.com>
26256
26257 PR target/85193
26258 * config/i386/i386.md (define_attr "memory"): Handle rotate1 type.
26259
26260 2018-04-05 Tom de Vries <tom@codesourcery.com>
26261
26262 PR target/85204
26263 * config/nvptx/nvptx.c (nvptx_single): Fix neutering of bb with only
26264 cond jump.
26265
26266 2018-04-05 Shiva Chen <shiva0217@gmail.com>
26267 Kito Cheng <kito.cheng@gmail.com>
26268
26269 * config/nds32/constraints.md (U33): Fine-tune checking condition.
26270 * config/nds32/nds32-md-auxiliary.c (nds32_mem_format): Ditto.
26271 * config/nds32/nds32.h (nds32_16bit_address_type): Add
26272 ADDRESS_POST_MODIFY_LO_REG_IMM3U.
26273
26274 2018-04-05 Shiva Chen <shiva0217@gmail.com>
26275 Kito Cheng <kito.cheng@gmail.com>
26276
26277 * config/nds32/constraints.md (Ufe): New memory constraint.
26278 * config/nds32/nds32-md-auxiliary.c (nds32_mem_format,
26279 nds32_output_16bit_load): Consider r8 register for lwi45.fe format.
26280 * config/nds32/nds32.c (nds32_print_operand): Output lwi45.fe
26281 operands.
26282 * config/nds32/nds32.h (nds32_16bit_address_type): Add ADDRESS_R8_IMM7U.
26283 * config/nds32/nds32.md (*mov<mode>): Adjust pattern.
26284
26285 2018-04-05 Chung-Ju Wu <jasonwucj@gmail.com>
26286
26287 * config/nds32/nds32.md: Use optimize_size in the condition for
26288 alu-shift instructions.
26289
26290 2018-04-05 Chung-Ju Wu <jasonwucj@gmail.com>
26291
26292 * config/nds32/nds32.md (divsi4, udivsi4): New patterns.
26293
26294 2018-04-05 Chung-Ju Wu <jasonwucj@gmail.com>
26295
26296 * config/nds32/nds32.md (negsi2): Refine pattern.
26297
26298 2018-04-05 Kito Cheng <kito.cheng@gmail.com>
26299 Chung-Ju Wu <jasonwucj@gmail.com>
26300
26301 * config/nds32/iterators.md (shift_rotate): New code iterator.
26302 (shift): New code attribute.
26303 * config/nds32/nds32-md-auxiliary.c (nds32_expand_constant): New.
26304 * config/nds32/nds32-protos.h (nds32_expand_constant): Declare.
26305 * config/nds32/nds32.c (nds32_print_operand): Deal with more cases.
26306 * config/nds32/nds32.md (addsi3, *add_srli): Refine implementation for
26307 bit-wise operations.
26308 (andsi3, *andsi3): Ditto.
26309 (iorsi3, *iorsi3, *or_slli, *or_srli): Ditto.
26310 (xorsi3, *xorsi3, *xor_slli, *xor_srli): Ditto.
26311 (<shift>si3, *ashlsi3, *ashrsi3, *lshrsi3, *rotrsi3): Ditto.
26312 * config/nds32/predicates.md (nds32_rimm5u_operand, nds32_and_operand,
26313 nds32_ior_operand, nds32_xor_operand): New predicates.
26314
26315 2018-04-05 Chung-Ju Wu <jasonwucj@gmail.com>
26316
26317 * config/nds32/nds32.md (add<mode>3, sub<mode>3): Rename to ...
26318 (addsi3, subsi3): ... this.
26319
26320 2018-04-05 Chung-Ju Wu <jasonwucj@gmail.com>
26321
26322 * config/nds32/nds32.md (*sub_srli, *and_slli): Fine-tune predicator.
26323
26324 2018-04-05 Chung-Ju Wu <jasonwucj@gmail.com>
26325
26326 * config/nds32/nds32.md: Adjust indention.
26327
26328 2018-04-05 Kito Cheng <kito.cheng@gmail.com>
26329
26330 * config/nds32/nds32.md (feature): New attribute.
26331
26332 2018-04-05 Chung-Ju Wu <jasonwucj@gmail.com>
26333
26334 * config/nds32/nds32.md (subtype): New attribute.
26335
26336 2018-04-04 Thomas Preud'homme <thomas.preudhomme@arm.com>
26337
26338 PR target/85203
26339 * config/arm/arm-builtins.c (arm_expand_builtin): Change
26340 expansion to perform a bitwise AND of the argument followed by a
26341 boolean negation of the result.
26342
26343 2018-04-04 Peter Bergner <bergner@vnet.ibm.com>
26344
26345 PR rtl-optimization/84878
26346 * ddg.c (add_cross_iteration_register_deps): Use DF_REF_BB to determine
26347 the basic block. Assert the use reference is not artificial and that
26348 it has an associated insn.
26349
26350 2018-04-04 Michael Matz <matz@suse.de>
26351
26352 * builtins.c (compute_objsize): Pass correct operand
26353 to array_at_struct_end_p.
26354
26355 2018-04-04 Richard Biener <rguenther@suse.de>
26356
26357 PR lto/85176
26358 * dwarf2out.c (dwarf2out_register_external_die): Peel namespaces
26359 from contexts for DINFO_LEVEL_TERSE and below.
26360
26361 2018-04-04 Kito Cheng <kito.cheng@gmail.com>
26362
26363 * config/nds32/nds32-doubleword.md (move_<mode>): Require
26364 resiter_operand condition.
26365 * config/nds32/nds32.md (*move<mode>): Ditto.
26366
26367 2018-04-04 Kito Cheng <kito.cheng@gmail.com>
26368 Monk Chiang <sh.chiang04@gmail.com>
26369
26370 * config/nds32/nds32.md (movmisalign<mode>): New pattern.
26371
26372 2018-04-04 Chung-Ju Wu <jasonwucj@gmail.com>
26373
26374 * config/nds32/nds32.md (movqi, movhi): Merge into mov<mode>.
26375
26376 2018-04-04 Chung-Ju Wu <jasonwucj@gmail.com>
26377 Kito Cheng <kito.cheng@gmail.com>
26378
26379 * config/nds32/nds32-md-auxiliary.c (nds32_inverse_cond_code,
26380 nds32_cond_code_str, output_cond_branch,
26381 output_cond_branch_compare_zero, nds32_expand_cbranch,
26382 nds32_expand_cstore, nds32_expand_movcc,
26383 nds32_output_cbranchsi4_equality_zero,
26384 nds32_output_cbranchsi4_equality_reg,
26385 nds32_output_cbranchsi4_equality_reg_or_const_int,
26386 nds32_output_cbranchsi4_greater_less_zero: New functions.
26387 * config/nds32/nds32-protos.h (nds32_expand_cbranch,
26388 nds32_expand_cstore, nds32_expand_movcc,
26389 nds32_output_cbranchsi4_equality_zero,
26390 nds32_output_cbranchsi4_equality_reg,
26391 nds32_output_cbranchsi4_equality_reg_or_const_int,
26392 nds32_output_cbranchsi4_greater_less_zero): Declare.
26393 * config/nds32/predicates.md (nds32_movecc_comparison_operator,
26394 nds32_rimm11s_operand): New predicates.
26395 * config/nds32/nds32.h (nds32_expand_result_type): New enum type.
26396 * config/nds32/nds32.md: Rewrite all the branch and conditional move
26397 patterns.
26398
26399 2018-04-04 Kito Cheng <kito.cheng@gmail.com>
26400
26401 * config/nds32/nds32-doubleword.md: Refine all the instruction type.
26402 * config/nds32/nds32.md: Ditto.
26403 * config/nds32/pipelines.md: Ditto.
26404
26405 2018-04-04 Richard Biener <rguenther@suse.de>
26406
26407 PR tree-optimization/85168
26408 * tree-ssa-sccvn.c (vn_reference_maybe_forwprop_address): Avoid
26409 propagating abnormals.
26410
26411 2018-04-04 Chung-Ju Wu <jasonwucj@gmail.com>
26412
26413 * config/nds32/nds32.md (enabled): Use yes/no for this attribute.
26414
26415 2018-04-04 Chung-Ju Wu <jasonwucj@gmail.com>
26416 Kito Cheng <kito.cheng@gmail.com>
26417
26418 * config/nds32/nds32-md-auxiliary.c (nds32_long_call_p): New function.
26419 * config/nds32/nds32-protos.h (nds32_long_call_p): Declare.
26420 * config/nds32/nds32.c (nds32_function_ok_for_sibcall): New function.
26421 (TARGET_FUNCTION_OK_FOR_SIBCALL): Define.
26422 * config/nds32/nds32.md (sibcall_internal): New.
26423 (sibcall_register): Remove.
26424 (sibcall_immediate): Remove.
26425 (sibcall_value_internal): New.
26426 (sibcall_value_register): Remove.
26427 (sibcall_value_immediate): Remove.
26428 * config/nds32/predicates.md (nds32_general_register_operand): New.
26429 (nds32_call_address_operand): New.
26430
26431 2018-04-03 Jakub Jelinek <jakub@redhat.com>
26432
26433 PR rtl-optimization/85167
26434 * shrink-wrap.c (move_insn_for_shrink_wrap): Don't set bb_uses and
26435 bb_defs if *split_p, instead preinitialize it to NULL.
26436
26437 PR tree-optimization/85156
26438 * builtins.c (fold_builtin_expect): Use save_expr on arg1 to avoid
26439 evaluating the argument multiple times.
26440
26441 2018-04-03 Bill Schmidt <wschmidt@linux.ibm.com>
26442
26443 * config/rs6000/emmintrin.h (_mm_cvtpd_epi32): Use __vector rather
26444 than vector.
26445 (_mm_cvtpd_ps): Likewise.
26446 (_mm_cvttpd_epi32): Likewise.
26447 * config/rs6000/mmintrin.h (_mm_unpacklo_pi8): Likewise.
26448 * config/rs6000/xmmintrin.h: For strict-ANSI C++ or C11, undefine
26449 vector, pixel, and bool following altivec.h include.
26450
26451 2018-04-03 Martin Sebor <msebor@redhat.com>
26452
26453 * doc/extend.texi (Common Function Attributes): Clarify.
26454 (const attribute): Likewise.
26455 (pure attribute): Likewise.
26456
26457 2018-04-03 Jakub Jelinek <jakub@redhat.com>
26458
26459 PR target/85169
26460 * config/i386/i386.c (ix86_expand_vector_set): Use
26461 HOST_WIDE_INT_1U << elt instead of 1 << elt. Formatting fix.
26462
26463 2018-04-03 Uros Bizjak <ubizjak@gmail.com>
26464
26465 * config/i386/i386.c (emit_i387_cw_initialization): Always use logic
26466 instructions when changing rounding bits to preserve precision bits
26467 in the x87 control word.
26468
26469 2018-04-03 Martin Liska <mliska@suse.cz>
26470
26471 PR tree-optimization/82491
26472 * rtl.h (strip_offset_and_add): Replace += suboffset with
26473 poly_uint64 () + suboffset.
26474
26475 2018-03-29 Martin Liska <mliska@suse.cz>
26476 Martin Jambor <mjambor@suse.cz>
26477
26478 PR ipa/84947
26479 * ipa-cp.c (propagate_bits_across_jump_function): Bail out if
26480 param_type is not an integral or pointer type.
26481
26482 2018-04-03 Richard Biener <rguenther@suse.de>
26483
26484 * sese.h (recompute_all_dominators): Remove.
26485
26486 2018-04-02 Martin Sebor <msebor@redhat.com>
26487
26488 * doc/invoke.texi (-Wrestrict): Fix typos.
26489
26490 2018-04-02 Jim Wilson <jimw@sifive.com>
26491
26492 * config/riscv/riscv.h (SHIFT_COUNT_TRUNCATED): Set to zero.
26493 * config/riscv/riscv.md (<optab>si3): Use QImode shift count.
26494 (<optab>di3, <optab>si3_extend): Likewise.
26495 (<optab>si3_mask, <optab>si3_mask_1): New.
26496 (<optab>di3_mask, <optab>di3_mask_1): New.
26497 (<optab>si3_extend_mask, <optab>si3_extend_mask_1): New.
26498 (lshrsi3_zero_extend_1): Use VOIDmode shift count.
26499 * config/riscv/sync.md (atomic_test_and_set): Emit QImode shift count.
26500
26501 2018-04-02 Gerald Pfeifer <gerald@pfeifer.com>
26502
26503 * doc/cpp.texi (Variadic Macros): Fix line continuation in an
26504 example.
26505
26506 2018-04-02 Chung-Ju Wu <jasonwucj@gmail.com>
26507
26508 * config/nds32/nds32.c (TARGET_CANONICALIZE_COMPARISON): Define.
26509 (nds32_canonicalize_comparison): New function.
26510
26511 2018-04-01 Chung-Ju Wu <jasonwucj@gmail.com>
26512 Kito Cheng <kito.cheng@gmail.com>
26513 Kuan-Lin Chen <kuanlinchentw@gmail.com>
26514
26515 * config.gcc (nds32): Add nds32-relax-opt.o into extra_objs.
26516 * config/nds32/constants.md (unspec_volatile_element): Add
26517 UNSPEC_VOLATILE_RELAX_GROUP.
26518 * config/nds32/nds32-relax-opt.c: New file.
26519 * config/nds32/nds32-predicates.c
26520 (nds32_symbol_load_store_p): New function.
26521 * config/nds32/nds32-protos.h
26522 (nds32_symbol_load_store_p): Declare function.
26523 (make_pass_nds32_relax_opt): Declare new rtl pass function.
26524 * config/nds32/nds32.c
26525 (nds32_register_pass): New function to register pass.
26526 (nds32_register_passes): New function to register passes.
26527 * config/nds32/nds32.md (relax_group): New pattern.
26528 * config/nds32/nds32.opt (mrelax-hint): New option.
26529 * config/nds32/t-nds32 (nds32-relax-opt.o): New dependency.
26530
26531 2018-04-01 Kito Cheng <kito.cheng@gmail.com>
26532
26533 * config/nds32/t-nds32: Modify files dependency.
26534
26535 2018-04-01 Chung-Ju Wu <jasonwucj@gmail.com>
26536
26537 * config/nds32/nds32.h (FUNCTION_PROFILER): Output newline character.
26538 (PROFILE_HOOK): Define its implementation.
26539
26540 2018-04-01 Chung-Ju Wu <jasonwucj@gmail.com>
26541
26542 * config/nds32/nds32.h (WCHAR_TYPE, WCHAR_TYPE_SIZE): Use unsigned int
26543 type and 32-bit size.
26544
26545 2018-04-01 Jakub Jelinek <jakub@redhat.com>
26546
26547 PR middle-end/85090
26548 * config/i386/sse.md (V): Add V64QI and V32HI for TARGET_AVX512F.
26549 (V_128_256): New mode iterator.
26550 (*avx512dq_vextract<shuffletype>64x2_1 splitter): New define_split.
26551 (*avx512f_vextract<shuffletype>32x4_1 splitter): Likewise.
26552 (xop_pcmov_<mode><avxsizesuffix>): Use V_128_256 mode iterator instead
26553 of V.
26554 * config/i386/i386.c (ix86_expand_vector_set): Improve V32HImode and
26555 V64QImode expansion for !TARGET_AVX512BW && TARGET_AVX512F.
26556
26557 2018-03-31 Segher Boessenkool <segher@kernel.crashing.org>
26558
26559 PR target/83315
26560 * config/rs6000/xmmintrin.h (_mm_set_ps, _mm_max_ps): Handle (quiet)
26561 NaN inputs correctly.
26562
26563 2018-03-30 Peter Bergner <bergner@vnet.ibm.com>
26564
26565 PR target/80546
26566 * config/rs6000/vsx.md (??r): New mode attribute.
26567 (*vsx_mov<mode>_64bit): Use it.
26568 (*vsx_mov<mode>_32bit): Likewise.
26569
26570 2018-03-30 Martin Sebor <msebor@redhat.com>
26571
26572 PR tree-optimization/84818
26573 * builtins.c (check_access): Use warning_n.
26574
26575 2018-03-30 Aaron Sawdey <acsawdey@linux.vnet.ibm.com>
26576
26577 PR target/83822
26578 * config/rs6000/rs6000-string.c (expand_compare_loop): Fix redundant
26579 condition.
26580 * config/rs6000/rs6000-c.c (rs6000_cpu_cpp_builtins): Fix redundant
26581 condition.
26582
26583 2018-03-30 Julia Koval <julia.koval@intel.com>
26584
26585 PR target/84413
26586 * x86-tune.def (movx, partial_reg_dependency): Enable for
26587 m_SKYLAKE_AVX512.
26588
26589 2018-03-29 Vladimir Makarov <vmakarov@redhat.com>
26590
26591 PR inline-asm/84985
26592 * lra-constraints.c (process_alt_operands): Move setting
26593 this_alternative_matches below.
26594
26595 2018-03-29 Martin Liska <mliska@suse.cz>
26596
26597 PR lto/84995.
26598 * doc/invoke.texi: Document how LTO works with debug info.
26599 Describe auto-load support of binutils. Mention 'x86-64'
26600 as valid option value of -march option.
26601
26602 2018-03-29 Jakub Jelinek <jakub@redhat.com>
26603
26604 * config/i386/sse.md (<avx512>_blendm<mode>): Use <sseintprefix>.
26605
26606 PR c/85094
26607 * fold-const.c (operand_equal_p): Handle DEBUG_BEGIN_STMT.
26608 For STATEMENT_LIST, pass down OEP_LEXICOGRAPHIC and maybe
26609 OEP_NO_HASH_CHECK for recursive call, to avoid exponential
26610 checking.
26611
26612 2018-03-28 Peter Bergner <bergner@vnet.ibm.com>
26613
26614 PR target/84912
26615 * config/rs6000/rs6000.h (RS6000_BTM_POWERPC64): New define.
26616 (RS6000_BTM_COMMON): Add RS6000_BTM_POWERPC64.
26617 * config/rs6000/rs6000.c (rs6000_builtin_mask_calculate): Add support
26618 for RS6000_BTM_POWERPC64.
26619 (rs6000_invalid_builtin): Add handling for RS6000_BTM_POWERPC64
26620 (rs6000_builtin_mask_names): Add RS6000_BTM_POWERPC64.
26621 * config/rs6000/rs6000-builtin.def (BU_P7_POWERPC64_MISC_2): New macro
26622 definition.
26623 (DIVDE): Use it.
26624 (DIVDEU): Likewise.
26625
26626 2018-03-28 Carl Love <cel@us.ibm.com>
26627
26628 Revert
26629 2017-09-27 Carl Love <cel@us.ibm.com>
26630
26631 * config/rs6000/rs6000-builtin.def (BU_FP_1MISC_1): Add define macro.
26632 (FCTID, FCTIW): Add BU_FP_MISC_1 macro expansion for builtins.
26633 * config/rs6000/rs6000.md (lrintsfsi2): Add define_insn for the
26634 fctiw instruction.
26635
26636 2018-03-28 Bill Schmidt <wschmidt@linux.vnet.ibm.com>
26637
26638 * config/rs6000/xmmintrin.h (_mm_max_pi16): Use __vector __bool
26639 instead of __vector bool.
26640 (_mm_max_pu8): Likewise.
26641 (_mm_min_pi16): Likewise.
26642
26643 2018-03-28 Peter Bergner <bergner@vnet.ibm.com>
26644
26645 PR target/84912
26646 * config/rs6000/rs6000-builtin.def (DIVWEO): Delete macro expansion.
26647 (DIVWEUO): Likewise.
26648 (DIVDEO): Likewise.
26649 (DIVDEUO): Likewise.
26650 * config/rs6000/rs6000.c (builtin_function_type): Remove support for
26651 DIVWEUO and DIVDEUO.
26652 * config/rs6000/rs6000.md (UNSPEC_DIVEO, UNSPEC_DIVEUO): Delete unspecs.
26653 (UNSPEC_DIV_EXTEND): Remove deleted unspecs.
26654 (div_extend): Likewise.
26655 * doc/extend.texi (__builtin_divweo): Remove documentation for deleted
26656 builtin function.
26657 (__builtin_divweuo): Likewise.
26658 (__builtin_divdeo): Likewise.
26659 (__builtin_divdeuo): Likewise.
26660
26661 2018-03-28 Jakub Jelinek <jakub@redhat.com>
26662
26663 PR target/85095
26664 * config/i386/i386.md (*add<mode>3_carry_0, *addsi3_carry_zext_0,
26665 *sub<mode>3_carry_0, *subsi3_carry_zext_0): New patterns.
26666
26667 PR tree-optimization/82004
26668 * gimple-match-head.c (optimize_pow_to_exp): New function.
26669 * match.pd (pow(C,x) -> exp(log(C)*x)): Wrap with #if GIMPLE.
26670 Don't fold to exp if optimize_pow_to_exp is false.
26671
26672 2018-03-28 Martin Liska <mliska@suse.cz>
26673
26674 PR other/84819
26675 * calls.c (initialize_argument_information): Fix trailing space.
26676 * common.opt: Fix typo and provide better explanation for
26677 -fsanitize-coverage option.
26678 * config/i386/i386.opt: Fix typo.
26679
26680 2018-03-28 Jakub Jelinek <jakub@redhat.com>
26681 Martin Liska <mliska@suse.cz>
26682
26683 PR sanitizer/85081
26684 * gimplify.c (asan_poison_variable): Don't do the check for
26685 gimplify_omp_ctxp here.
26686 (gimplify_decl_expr): Do it here.
26687 (gimplify_target_expr): Likewise.
26688
26689 2018-03-28 Martin Liska <mliska@suse.cz>
26690
26691 PR target/84988
26692 * config/i386/i386.c (ix86_function_arg_advance): Do not call
26693 chkp_type_bounds_count if MPX is not enabled.
26694
26695 2018-03-27 Chung-Ju Wu <jasonwucj@gmail.com>
26696
26697 * config/nds32/nds32.h (BRANCH_COST): Adjust cost.
26698
26699 2018-03-27 Michael Meissner <meissner@linux.vnet.ibm.com>
26700
26701 PR target/84914
26702 * config/rs6000/rs6000.c (create_complex_muldiv): New helper
26703 function to create the function decl for complex long double
26704 multiply and divide for -mabi=ieeelongdouble.
26705 (init_float128_ieee): Call it.
26706
26707 2018-03-27 H.J. Lu <hongjiu.lu@intel.com>
26708
26709 PR target/85044
26710 * config/i386/i386.c (ix86_trampoline_init): Insert ENDBR for
26711 -fcf-protection=branch -mibt.
26712 * config/i386/i386.h (TRAMPOLINE_SIZE): Increased by 4 bytes.
26713
26714 2018-03-27 Ramana Radhakrishnan <ramana.radhakrishnan@arm.com>
26715
26716 PR target/81863
26717 * config/arm/arm.c (arm_valid_symbolic_address): Handle
26718 arm_word_relocations.
26719
26720 2018-03-27 Cesar Philippidis <cesar@codesourcery.com>
26721
26722 PR target/85056
26723 * config/nvptx/nvptx.c (nvptx_assemble_decl_begin): Add '[]' to
26724 extern array declarations.
26725
26726 2018-03-27 Richard Biener <rguenther@suse.de>
26727
26728 PR middle-end/84067
26729 * match.pd ((A * C) +- (B * C) -> (A+-B) * C): Guard with
26730 explicit single_use checks.
26731
26732 2018-03-27 Richard Biener <rguenther@suse.de>
26733
26734 PR tree-optimization/85082
26735 * tree-ssa-sccvn.c (vn_reference_lookup_or_insert_for_pieces):
26736 Valueize the VUSE.
26737
26738 2018-03-27 Ramana Radhakrishnan <ramana.radhakrishnan@arm.com>
26739
26740 * config.gcc (aarch64*-*-linux*): New TARGET_DEFAULT_ASYNC_UNWIND_TABLES
26741 * common/config/aarch64/aarch64-common.c (aarch64_optimization_table[]):
26742 Turn on fasynchronous-unwind-tables and funwind-tables.
26743
26744 2018-03-26 Uros Bizjak <ubizjak@gmail.com>
26745
26746 PR target/85073
26747 * config/i386/i386.md (*bmi_blsr_<mode>_cmp): New insn pattern.
26748 (*bmi_blsr_<mode>_ccz): Ditto.
26749
26750 2018-03-26 Tom de Vries <tom@codesourcery.com>
26751
26752 PR tree-optimization/85063
26753 * omp-general.c (offloading_function_p): New function. Factor out
26754 of ...
26755 * omp-offload.c (pass_omp_target_link::gate): ... here.
26756 * omp-general.h (offloading_function_p): Declare.
26757 * tree-switch-conversion.c (build_one_array): Mark CSWTCH.x variable
26758 with attribute omp declare target for offloading functions.
26759
26760 2018-03-24 Richard Sandiford <richard.sandiford@linaro.org>
26761
26762 PR tree-optimization/84005
26763 * tree-data-ref.h (get_base_for_alignment): Declare.
26764 * tree-data-ref.c (get_base_for_alignment_1): New function.
26765 (get_base_for_alignment): Likewise.
26766 * tree-vect-data-refs.c (vect_compute_data_ref_alignment): Use
26767 get_base_for_alignment to find a suitable base object, instead
26768 of always using drb->base_address.
26769
26770 2018-03-23 Jakub Jelinek <jakub@redhat.com>
26771
26772 PR inline-asm/85022
26773 * emit-rtl.c (init_emit_regs): Indicate that VOIDmode MEMs don't have
26774 known size by default.
26775
26776 2018-03-23 Vladimir Makarov <vmakarov@redhat.com>
26777
26778 PR inline-asm/85030
26779 * lra-constraints.c (process_alt_operands): Don't match BLKmode
26780 and non BLKmode operands.
26781
26782 2018-03-23 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
26783
26784 PR target/85026
26785 * config/arm/arm.md (unaligned_loadhis): Remove first alternative.
26786 Clean up attributes.
26787
26788 2018-03-23 Richard Biener <rguenther@suse.de>
26789
26790 PR debug/85020
26791 * dwarf2out.c (rtl_for_decl_location): Do not generate RTL early when
26792 we are going to emit early debug for LTO.
26793
26794 2018-03-23 Jakub Jelinek <jakub@redhat.com>
26795
26796 PR inline-asm/85034
26797 * function.c (match_asm_constraints_1): Don't optimize if input
26798 doesn't satisfy general_operand predicate for output's mode.
26799
26800 PR inline-asm/85022
26801 * alias.c (write_dependence_p): Don't require for x_canonicalized
26802 non-VOIDmode if x has VOIDmode.
26803
26804 PR sanitizer/85029
26805 * sanopt.c (maybe_optimize_ubsan_ptr_ifn): If DECL_REGISTER (base),
26806 just don't try to optimize it rather than assert it never happens.
26807
26808 2018-03-22 Kelvin Nilsen <kelvin@gcc.gnu.org>
26809
26810 * config/rs6000/rs6000-builtin.def: Remove various BU_ALTIVEC_X
26811 macro expansions for definition of ST_INTERNAL_<mode> and
26812 LD_INTERNAL_<mode> builtins.
26813 * config/rs6000/rs6000-protos.h (rs6000_address_for_altivec):
26814 Remove prototype.
26815 * config/rs6000/rs6000.c (altivec_expand_ld_builtin): Delete this
26816 function.
26817 (altivec_expand_st_builtin): Likewise.
26818 (altivec_expand_builtin): Remove calls to deleted functions.
26819 (rs6000_address_for_altivec): Delete this function.
26820 * config/rs6000/vector.md: Remove expands for
26821 vector_altivec_load_<mode> and vector_altivec_store_<mode>.
26822
26823 2018-03-22 Sudakshina Das <sudi.das@arm.com>
26824
26825 PR target/84826
26826 * config/arm/arm.h (machine_function): Add static_chain_stack_bytes.
26827 * config/arm/arm.c (arm_compute_static_chain_stack_bytes): Avoid
26828 re-computing once computed.
26829 (arm_expand_prologue): Compute machine->static_chain_stack_bytes.
26830 (arm_init_machine_status): Initialize
26831 machine->static_chain_stack_bytes.
26832
26833 2018-03-22 Kelvin Nilsen <kelvin@gcc.gnu.org>
26834
26835 PR target/84760
26836 * doc/extend.texi: Add four new prototypes for vec_ld.
26837 * config/rs6000/rs6000-builtin.def (LVX_V1TI): Reorder symbol
26838 definitions for more logical presentation.
26839 * config/rs6000/rs6000-c.c: (altivec_overloaded_builtins): Add
26840 entries for V1TI variants of __builtin_altivec_ld builtin.
26841 * config/rs6000/rs6000.c: (altivec_expand_lv_builtin): Add test and
26842 handling of V1TI variant of LVX icode pattern.
26843 (altivec_expand_builtin): Add case for ALTIVEC_BUILTIN_LVX_V1TI.
26844 (rs6000_gimple_fold_builtin): Likewise.
26845 (altivec_init_builtins): Add code to define
26846 __builtin_altivec_lvx_v1ti function.
26847
26848 2018-03-22 Jakub Jelinek <jakub@redhat.com>
26849
26850 PR inline-asm/84941
26851 * function.c (match_asm_constraints_1): Don't do the optimization
26852 if input isn't a REG, SUBREG, MEM or constant.
26853
26854 2018-03-22 Tom de Vries <tom@codesourcery.com>
26855
26856 PR tree-optimization/84956
26857 * tree-ssa-tail-merge.c (find_clusters_1): Skip bbs with
26858 bb_has_abnormal_pred.
26859
26860 2018-03-22 Jakub Jelinek <jakub@redhat.com>
26861
26862 PR sanitizer/85018
26863 * dwarf2asm.c (dw2_output_indirect_constant_1): Set
26864 DECL_INITIAL (decl) to decl at the end.
26865 * varasm.c (use_blocks_for_decl_p): Revert the 2018-03-20 change,
26866 adjust the comment.
26867
26868 2018-03-21 Joseph Myers <joseph@codesourcery.com>
26869
26870 * doc/extend.texi (__builtin_tgmath): Document when complex
26871 integer types are treated as _Complex _Float64.
26872
26873 2018-03-21 Tom de Vries <tom@codesourcery.com>
26874
26875 * doc/extend.texi (__builtin_extend_pointer): Remove pasto.
26876
26877 2018-03-21 Jakub Jelinek <jakub@redhat.com>
26878
26879 PR tree-optimization/84960
26880 * tree-cfg.c (remove_bb): Don't move forced labels into bb->prev_bb
26881 if it is ENTRY block, move them into single succ of ENTRY in that case.
26882
26883 2018-03-21 Richard Sandiford <richard.sandiford@linaro.org>
26884
26885 PR tree-optimization/84811
26886 * poly-int.h (poly_span_traits): Remove the T3 parameter and
26887 promote HOST_WIDE_INT T2 - T1 results to unsigned HOST_WIDE_INT.
26888 (maybe_in_range_p, known_in_range_p, ranges_known_overlap_p):
26889 (known_subrange_p): Update accordingly. Cast each value involved
26890 in the size comparison, rather than casting the result of the
26891 subtraction.
26892
26893 2018-03-21 Jakub Jelinek <jakub@redhat.com>
26894
26895 PR tree-optimization/84982
26896 * gimple-ssa-store-merging.c (invert_op): Handle boolean inversion
26897 by flipping the least significant bit rather than all bits from
26898 bitpos to bitpos + bitsize - 1.
26899
26900 2018-03-21 Nathan Sidwell <nathan@acm.org>
26901
26902 * doc/extend.texi (Deprecated Features): Remove mention of
26903 long-deleted deprecations.
26904
26905 2018-03-21 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
26906
26907 PR jit/84288
26908 * configure.ac (gcc_cv_ld_soname) <*-*-solaris2*>: Set.
26909 * configure: Regenerate.
26910
26911 2018-03-21 Tom de Vries <tom@codesourcery.com>
26912
26913 PR tree-optimization/83126
26914 * tree-parloops.c (num_phis): New function.
26915 (gen_parallel_loop): Detect and handle canonicalize_loop_ivs failure.
26916
26917 2018-03-21 Nathan Sidwell <nathan@acm.org>
26918
26919 * doc/extend.texi (Deprecated Features): Update deprecated flags,
26920 mention anon-struct/union members and trailing attributes.
26921
26922 2018-03-21 Bin Cheng <bin.cheng@arm.com>
26923
26924 PR tree-optimization/84969
26925 * tree-loop-distribution.c (fuse_memset_builtins): Don't reorder
26926 builtin memset partitions if they set different rhs values.
26927
26928 2018-03-21 Jakub Jelinek <jakub@redhat.com>
26929
26930 PR rtl-optimization/84989
26931 * simplify-rtx.c (simplify_unary_operation_1): Don't try to simplify
26932 VEC_DUPLICATE with scalar result mode.
26933
26934 2018-03-21 Martin Liska <mliska@suse.cz>
26935
26936 PR ipa/84963
26937 * ipa-icf.c (sem_item_optimizer::fixup_points_to_sets): Remove
26938 not intended return statement.
26939
26940 2018-03-21 Martin Liska <mliska@suse.cz>
26941
26942 PR target/84988
26943 * tree-chkp.c (CHKP_ARRAY_MAX_CHECK_STEPS): Define a new macro.
26944 (chkp_find_bound_slots_1): Limit number of iterations.
26945
26946 2018-03-20 David H. Gutteridge <dhgutteridge@sympatico.ca>
26947
26948 PR target/84838
26949 * Minor grammar fixes for x86 options.
26950
26951 2018-03-20 Jakub Jelinek <jakub@redhat.com>
26952
26953 PR debug/84875
26954 * dce.c (delete_unmarked_insns): Don't remove frame related noop moves
26955 holding REG_CFA_RESTORE notes, instead turn them into a USE.
26956
26957 2018-03-20 Peter Bergner <bergner@vnet.ibm.com>
26958
26959 PR target/83789
26960 * config/rs6000/altivec.md (altivec_lvx_<mode>_2op): Delete define_insn.
26961 (altivec_lvx_<mode>_1op): Likewise.
26962 (altivec_stvx_<mode>_2op): Likewise.
26963 (altivec_stvx_<mode>_1op): Likewise.
26964 (altivec_lvx_<VM2:mode>): New define_expand.
26965 (altivec_stvx_<VM2:mode>): Likewise.
26966 (altivec_lvx_<VM2:mode>_2op_<P:mptrsize>): New define_insn.
26967 (altivec_lvx_<VM2:mode>_1op_<P:mptrsize>): Likewise.
26968 (altivec_stvx_<VM2:mode>_2op_<P:mptrsize>): Likewise.
26969 (altivec_stvx_<VM2:mode>_1op_<P:mptrsize>): Likewise.
26970 * config/rs6000/rs6000-p8swap.c (rs6000_gen_stvx): Use new expanders.
26971 (rs6000_gen_lvx): Likewise.
26972 * config/rs6000/rs6000.c (altivec_expand_lv_builtin): Likewise.
26973 (altivec_expand_stv_builtin): Likewise.
26974 (altivec_expand_builtin): Likewise.
26975 * config/rs6000/vector.md: Likewise.
26976
26977 2018-03-20 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
26978
26979 PR target/82518
26980 * config/arm/arm.c (arm_array_mode_supported_p): Return false for
26981 BYTES_BIG_ENDIAN.
26982
26983 2018-03-20 Richard Biener <rguenther@suse.de>
26984
26985 PR target/84986
26986 * config/i386/i386.c (ix86_add_stmt_cost): Only cost
26987 sign-conversions as zero, fall back to standard scalar_stmt
26988 cost for the rest.
26989
26990 2018-03-20 Martin Liska <mliska@suse.cz>
26991
26992 PR ipa/84825
26993 * predict.c (rebuild_frequencies): Handle case when we have
26994 PROFILE_ABSENT, but flag_guess_branch_prob is false.
26995
26996 2018-03-20 Jakub Jelinek <jakub@redhat.com>
26997
26998 PR target/84990
26999 * dwarf2asm.c (dw2_output_indirect_constant_1): Temporarily turn off
27000 flag_section_anchors.
27001 * varasm.c (use_blocks_for_decl_p): Remove hack for
27002 dw2_force_const_mem.
27003
27004 PR target/84845
27005 * config/aarch64/aarch64.md (*aarch64_reg_<mode>3_neg_mask2): Rename
27006 to ...
27007 (*aarch64_<optab>_reg_<mode>3_neg_mask2): ... this. If pseudos can't
27008 be created, use lowpart_subreg of operands[0] rather than operands[0]
27009 itself.
27010 (*aarch64_reg_<mode>3_minus_mask): Rename to ...
27011 (*aarch64_ashl_reg_<mode>3_minus_mask): ... this.
27012 (*aarch64_<optab>_reg_di3_mask2): Use const_int_operand predicate
27013 and n constraint instead of aarch64_shift_imm_di and Usd.
27014 (*aarch64_reg_<optab>_minus<mode>3): Rename to ...
27015 (*aarch64_<optab>_reg_minus<mode>3): ... this.
27016
27017 2018-03-20 Sudakshina Das <sudi.das@arm.com>
27018
27019 PR target/82989
27020 * config/arm/neon.md (ashldi3_neon): Update ?s for constraints
27021 to favor GPR over NEON registers.
27022 (<shift>di3_neon): Likewise.
27023
27024 2018-03-20 Tom de Vries <tom@codesourcery.com>
27025
27026 PR target/84952
27027 * config/nvptx/nvptx.c (nvptx_single): Don't neuter bar.sync.
27028 (nvptx_process_pars): Emit bar.sync asap and alap.
27029
27030 2018-03-20 Tom de Vries <tom@codesourcery.com>
27031
27032 PR target/84954
27033 * config/nvptx/nvptx.c (prevent_branch_around_nothing): Also update
27034 seen_label if seen_label is already set.
27035
27036 2018-03-20 Jakub Jelinek <jakub@redhat.com>
27037
27038 PR target/84945
27039 * config/i386/i386.c (fold_builtin_cpu): For features above 31
27040 use __cpu_features2 variable instead of __cpu_model.__cpu_features[0].
27041 Use 1U instead of 1. Formatting fixes.
27042
27043 PR c/84953
27044 * builtins.c (fold_builtin_strpbrk): For strpbrk(x, "") use type
27045 instead of TREE_TYPE (s1) for the return value.
27046
27047 2018-03-19 Jakub Jelinek <jakub@redhat.com>
27048
27049 PR tree-optimization/84946
27050 * gimple-ssa-store-merging.c (mem_valid_for_store_merging): Compute
27051 bitsize + bitsize in poly_uint64 rather than poly_int64.
27052
27053 PR sanitizer/78651
27054 * dwarf2asm.c: Include fold-const.c.
27055 (dw2_output_indirect_constant_1): Set DECL_INITIAL (decl) to ADDR_EXPR
27056 of decl rather than decl itself.
27057
27058 PR rtl-optimization/84643
27059 * memmodel.h (enum memmodel): Add MEMMODEL_MAX enumerator.
27060
27061 2018-03-19 Maxim Ostapenko <m.ostapenko@samsung.com>
27062
27063 PR sanitizer/78651
27064 * dwarf2asm.c (dw2_output_indirect_constant_1): Disable ASan before
27065 calling assemble_variable.
27066
27067 2018-03-19 Sudakshina Das <sudi.das@arm.com>
27068
27069 PR target/81647
27070 * config/aarch64/aarch64-simd.md (vec_cmp<mode><v_int_equiv>): Modify
27071 instructions for UNLT, UNLE, UNGT, UNGE, UNEQ, UNORDERED and ORDERED.
27072
27073 2018-03-19 Jim Wilson <jimw@sifive.com>
27074
27075 PR bootstrap/84856
27076 * config/riscv/riscv.c (riscv_function_arg_boundary): Use
27077 PREFERRED_STACK_BOUNDARY instead of STACK_BOUNDARY.
27078 (riscv_first_stack_step): Likewise.
27079 (riscv_option_override): Use STACK_BOUNDARY instead of
27080 MIN_STACK_BOUNDARY.
27081 * config/riscv/riscv.h (STACK_BOUNDARY): Renamed from
27082 MIN_STACK_BOUNDARY.
27083 (BIGGEST_ALIGNMENT): Set to 128.
27084 (PREFERRED_STACK_BOUNDARY): Renamed from STACK_BOUNDARY.
27085 (RISCV_STACK_ALIGN): Use PREFERRED_STACK_BOUNDARY instead of
27086 STACK_BOUNDARY.
27087
27088 2018-03-19 Richard Biener <rguenther@suse.de>
27089
27090 PR tree-optimization/84933
27091 * tree-vrp.c (set_and_canonicalize_value_range): Treat out-of-bound
27092 values as -INF/INF when canonicalizing an ANTI_RANGE to a RANGE.
27093
27094 2018-03-19 Richard Biener <rguenther@suse.de>
27095
27096 PR tree-optimization/84859
27097 * tree-ssa-phiopt.c (single_trailing_store_in_bb): New function.
27098 (cond_if_else_store_replacement): Perform sinking operation on
27099 single-store BBs regardless of MAX_STORES_TO_SINK setting.
27100 Generalize what a BB with a single eligible store is.
27101
27102 2018-03-19 Richard Biener <rguenther@suse.de>
27103
27104 PR tree-optimization/84929
27105 * tree-data-ref.c (analyze_siv_subscript_cst_affine): Guard
27106 chrec_is_positive against non-chrec arg.
27107
27108 2018-03-19 Tamar Christina <tamar.christina@arm.com>
27109
27110 PR target/84711
27111 * config/arm/arm.c (arm_can_change_mode_class): revert r258554.
27112
27113 2018-03-18 Martin Liska <mliska@suse.cz>
27114
27115 PR rtl-optimization/84635
27116 * regrename.c (build_def_use): Use matches_mode only when
27117 matches >= 0.
27118
27119 2018-03-18 Richard Sandiford <richard.sandiford@linaro.org>
27120
27121 PR tree-optimization/84913
27122 * tree-vect-loop.c (vectorizable_reduction): Don't try to
27123 vectorize chains of COND_EXPRs.
27124
27125 2018-03-18 Chung-Ju Wu <jasonwucj@gmail.com>
27126
27127 * config/nds32/nds32.h (MAX_REGS_PER_ADDRESS): Fix the value.
27128
27129 2018-03-18 Chung-Ju Wu <jasonwucj@gmail.com>
27130
27131 * config/nds32/nds32.h (LOGICAL_OP_NON_SHORT_CIRCUIT): Define.
27132
27133 2018-03-18 Chung-Ju Wu <jasonwucj@gmail.com>
27134
27135 * config/nds32/nds32.h (CLZ_DEFINED_VALUE_AT_ZERO): Define.
27136
27137 2018-03-17 Chung-Ju Wu <jasonwucj@gmail.com>
27138 Kito Cheng <kito.cheng@gmail.com>
27139
27140 * config/nds32/nds32-protos.h (nds32_adjust_reg_alloc_order): Declare.
27141 * config/nds32/nds32.c (nds32_reg_alloc_order_for_speed): New array.
27142 (nds32_adjust_reg_alloc_order): New function.
27143 * config/nds32/nds32.h (ADJUST_REG_ALLOC_ORDER): Define.
27144
27145 2018-03-17 Kito Cheng <kito.cheng@gmail.com>
27146
27147 * config/nds32/nds32.c (nds32_asm_output_mi_thunk,
27148 nds32_print_operand, nds32_print_operand_address): Use
27149 HOST_WIDE_INT_PRINT_DEC instead.
27150
27151 2018-03-17 Chung-Ju Wu <jasonwucj@gmail.com>
27152
27153 * config/nds32/nds32.c (nds32_register_priority): Modify cost.
27154
27155 2018-03-17 Jakub Jelinek <jakub@redhat.com>
27156
27157 PR target/84902
27158 * config/i386/i386.c (initial_ix86_tune_features,
27159 initial_ix86_arch_features): Use unsigned HOST_WIDE_INT rather than
27160 unsigned long long.
27161 (set_ix86_tune_features): Change ix86_tune_mask from unsigned int
27162 to unsigned HOST_WIDE_INT, initialize to HOST_WIDE_INT_1U << ix86_tune
27163 rather than 1u << ix86_tune. Formatting fix.
27164 (ix86_option_override_internal): Change ix86_arch_mask from
27165 unsigned int to unsigned HOST_WIDE_INT, initialize to
27166 HOST_WIDE_INT_1U << ix86_arch rather than 1u << ix86_arch.
27167 (ix86_function_specific_restore): Likewise.
27168
27169 2018-03-16 Jakub Jelinek <jakub@redhat.com>
27170
27171 PR target/84899
27172 * postreload.c (reload_combine_recognize_pattern): Perform
27173 INTVAL addition in unsigned HOST_WIDE_INT type to avoid UB and
27174 truncate_int_for_mode the result for the destination's mode.
27175
27176 PR c/84909
27177 * hsa-gen.c (mem_type_for_type): Fix comment typo.
27178 * tree-vect-loop-manip.c (vect_create_cond_for_niters_checks):
27179 Likewise.
27180 * gimple-ssa-warn-restrict.c (builtin_memref::set_base_and_offset):
27181 Likewise.
27182
27183 2018-03-16 Vladimir Makarov <vmakarov@redhat.com>
27184
27185 PR target/84876
27186 * lra-assigns.c (lra_split_hard_reg_for): Don't use
27187 regno_allocno_class_array and sorted_pseudos.
27188 * lra-constraints.c (spill_hard_reg_in_range): Ignore hard regs in
27189 insns where regno is used.
27190
27191 2018-03-16 Martin Liska <mliska@suse.cz>
27192
27193 PR ipa/84833
27194 * multiple_target.c (create_dispatcher_calls): Redirect
27195 reference in the symbol table.
27196
27197 2018-03-16 Martin Liska <mliska@suse.cz>
27198
27199 PR ipa/84722
27200 * multiple_target.c (create_dispatcher_calls): Redirect also
27201 an alias.
27202
27203 2018-03-16 Jakub Jelinek <jakub@redhat.com>
27204
27205 PR c++/79937
27206 PR c++/82410
27207 * tree.h (TARGET_EXPR_NO_ELIDE): Define.
27208 * gimplify.c (gimplify_modify_expr_rhs): Don't elide TARGET_EXPRs with
27209 TARGET_EXPR_NO_ELIDE flag set unless *expr_p is INIT_EXPR.
27210
27211 2018-03-16 Julia Koval <julia.koval@intel.com>
27212
27213 * doc/invoke.texi (Skylake Server): Add CLWB.
27214 Cannonlake): Remove CLWB.
27215
27216 2018-03-16 Jakub Jelinek <jakub@redhat.com>
27217
27218 PR tree-optimization/84841
27219 * tree-ssa-reassoc.c (INTEGER_CONST_TYPE): Change to 1 << 4 from
27220 1 << 3.
27221 (FLOAT_ONE_CONST_TYPE): Define.
27222 (constant_type): Return FLOAT_ONE_CONST_TYPE for -1.0 and 1.0.
27223 (sort_by_operand_rank): Put entries with higher constant_type last
27224 rather than first to match comments.
27225
27226 2018-03-15 Sandra Loosemore <sandra@codesourcery.com>
27227
27228 * config/nios2/nios2.md (movsi_internal): Fix thinko in
27229 split predicate.
27230
27231 2018-03-15 Jakub Jelinek <jakub@redhat.com>
27232
27233 PR c++/79085
27234 * calls.c (expand_call): For TREE_ADDRESSABLE rettype ignore alignment
27235 check and use address of target always.
27236
27237 2018-03-15 H.J. Lu <hongjiu.lu@intel.com>
27238
27239 PR target/84574
27240 * config/i386/i386.c (indirect_thunk_needed): Update comments.
27241 (indirect_thunk_bnd_needed): Likewise.
27242 (indirect_thunks_used): Likewise.
27243 (indirect_thunks_bnd_used): Likewise.
27244 (indirect_return_needed): New.
27245 (indirect_return_bnd_needed): Likewise.
27246 (output_indirect_thunk_function): Add a bool argument for
27247 function return.
27248 (output_indirect_thunk_function): Don't generate alias for
27249 function return thunk.
27250 (ix86_code_end): Call output_indirect_thunk_function to generate
27251 function return thunks.
27252 (ix86_output_function_return): Set indirect_return_bnd_needed
27253 and indirect_return_needed instead of indirect_thunk_bnd_needed
27254 and indirect_thunk_needed.
27255
27256 2018-03-15 Olga Makhotina <olga.makhotina@intel.com>
27257
27258 * config/i386/sgxintrin.h (_enclv_u32): New intrinsic.
27259 (__enclv_bc, __enclv_cd, __enclv_generic): New definitions.
27260 (ERDINFO, ETRACKC, ELDBC, ELDUC): New leaves.
27261
27262 2018-03-15 David Malcolm <dmalcolm@redhat.com>
27263 Paul Hua <paul.hua.gm@gmail.com>
27264
27265 PR c/84852
27266 * gcc.dg/fixits-pr84852-1.c: Fix filename in dg-regexp.
27267
27268 2018-03-15 Segher Boessenkool <segher@kernel.crashing.org>
27269
27270 * config/rs6000/rs6000.c (abi_v4_pass_in_fpr): Add back the
27271 TARGET_DOUBLE_FLOAT and TARGET_SINGLE_FLOAT conditions on the DFmode
27272 resp. SFmode cases.
27273
27274 2018-03-15 Tamar Christina <tamar.christina@arm.com>
27275
27276 PR target/84711
27277 * config/arm/arm.c (arm_can_change_mode_class): Use GET_MODE_UNIT_SIZE
27278 instead of GET_MODE_SIZE when comparing Units.
27279
27280 2018-03-15 Vladimir Mezentsev <vladimir.mezentsev@oracle.com>
27281
27282 PR target/68256
27283 * varasm.c (hash_section): Return an unchangeble hash value
27284 * config/aarch64/aarch64.c (aarch64_use_blocks_for_constant_p):
27285 Return !aarch64_can_use_per_function_literal_pools_p ().
27286
27287 2018-03-15 Jakub Jelinek <jakub@redhat.com>
27288
27289 PR target/84860
27290 * optabs.c (emit_conditional_move): Pass address of cmode's copy
27291 rather than address of cmode as last argument to prepare_cmp_insn.
27292
27293 2018-03-15 Julia Koval <julia.koval@intel.com>
27294
27295 * config/i386/i386.c (F_AVX512VBMI2, F_GFNI, F_VPCLMULQDQ,
27296 F_AVX512VNNI, F_AVX512BITALG): New.
27297
27298 2018-03-14 John David Anglin <danglin@gcc.gnu.org>
27299
27300 PR target/83451
27301 * config/pa/pa.c (pa_emit_move_sequence): Always emit secondary reload
27302 insn for floating-point loads and stores.
27303
27304 2018-03-14 Carl Love <cel@us.ibm.com>
27305
27306 * config/rs6000/rs6000-c.c: Add macro definitions for
27307 ALTIVEC_BUILTIN_VEC_PERMXOR.
27308 * config/rs6000/rs6000.h: Add #define for vec_permxor builtin.
27309 * config/rs6000/rs6000-builtin.def: Add macro expansions for VPERMXOR.
27310 * config/rs6000/altivec.md (altivec_vpermxor): New define expand.
27311 * config/rs6000/rs6000-p8swap.c (rtx_is_swappable_p): Add case
27312 UNSPEC_VPERMXOR.
27313 * config/doc/extend.texi: Add prototypes for vec_permxor.
27314
27315 2018-03-14 David Malcolm <dmalcolm@redhat.com>
27316
27317 PR c/84852
27318 * diagnostic-show-locus.c (class layout_point): Convert m_line
27319 from int to linenum_type.
27320 (line_span::comparator): Use linenum "compare" function when
27321 comparing line numbers.
27322 (test_line_span): New function.
27323 (layout_range::contains_point): Convert param "row" from int to
27324 linenum_type.
27325 (layout_range::intersects_line_p): Likewise.
27326 (layout::will_show_line_p): Likewise.
27327 (layout::print_source_line): Likewise.
27328 (layout::should_print_annotation_line_p): Likewise.
27329 (layout::print_annotation_line): Likewise.
27330 (layout::print_leading_fixits): Likewise.
27331 (layout::annotation_line_showed_range_p): Likewise.
27332 (struct line_corrections): Likewise for field m_row.
27333 (line_corrections::line_corrections): Likewise for param "row".
27334 (layout::print_trailing_fixits): Likewise.
27335 (layout::get_state_at_point): Likewise.
27336 (layout::get_x_bound_for_row): Likewise.
27337 (layout::print_line): Likewise.
27338 (diagnostic_show_locus): Likewise for locals "last_line" and "row".
27339 (selftest::diagnostic_show_locus_c_tests): Call test_line_span.
27340 * input.c (selftest::test_linenum_comparisons): New function.
27341 (selftest::input_c_tests): Call it.
27342 * selftest.c (selftest::test_assertions): Test ASSERT_GT,
27343 ASSERT_GT_AT, ASSERT_LT, and ASSERT_LT_AT.
27344 * selftest.h (ASSERT_GT): New macro.
27345 (ASSERT_GT_AT): New macro.
27346 (ASSERT_LT): New macro.
27347 (ASSERT_LT_AT): New macro.
27348
27349 2018-03-14 Segher Boessenkool <segher@kernel.crashing.org>
27350
27351 PR rtl-optimization/84780
27352 * combine.c (distribute_links): Don't make a link based on pc_rtx.
27353
27354 2018-03-14 Martin Liska <mliska@suse.cz>
27355
27356 * tree.c (record_node_allocation_statistics): Use
27357 get_stats_node_kind.
27358 (get_stats_node_kind): New function extracted from
27359 record_node_allocation_statistics.
27360 (free_node): Use get_stats_node_kind.
27361
27362 2018-03-14 Richard Biener <rguenther@suse.de>
27363
27364 * tree-ssa-pre.c (compute_antic_aux): Remove code that asserts
27365 that the value-set of ANTIC_IN doesn't grow.
27366
27367 Revert
27368 * tree-ssa-pre.c (struct bb_bitmap_sets): Add visited_with_visited_succs
27369 member.
27370 (BB_VISITED_WITH_VISITED_SUCCS): New define.
27371 (compute_antic): Initialize BB_VISITED_WITH_VISITED_SUCCS.
27372
27373 2018-03-14 Julia Koval <julia.koval@intel.com>
27374
27375 * config.gcc (icelake-client, icelake-server): New.
27376 (icelake): Remove.
27377 * config/i386/i386.c (initial_ix86_tune_features): Extend to 64 bit.
27378 (initial_ix86_arch_features): Ditto.
27379 (PTA_SKYLAKE): Add SGX.
27380 (PTA_ICELAKE): Remove.
27381 (PTA_ICELAKE_CLIENT): New.
27382 (PTA_ICELAKE_SERVER): New.
27383 (ix86_option_override_internal): Split up icelake on icelake client and
27384 icelake server.
27385 (get_builtin_code_for_version): Ditto.
27386 (fold_builtin_cpu): Ditto.
27387 * config/i386/driver-i386.c (config/i386/driver-i386.c): Ditto.
27388 * config/i386/i386-c.c (ix86_target_macros_internal): Ditto
27389 * config/i386/i386.h (processor_type): Ditto.
27390 * doc/invoke.texi: Ditto.
27391
27392 2018-03-14 Jakub Jelinek <jakub@redhat.com>
27393
27394 PR sanitizer/83392
27395 * sanopt.c (maybe_optimize_ubsan_ptr_ifn): Handle also
27396 INTEGER_CST offset, add it together with bitpos / 8 and
27397 sign extend based on POINTER_SIZE.
27398
27399 PR target/84844
27400 Revert
27401 2017-04-20 Uros Bizjak <ubizjak@gmail.com>
27402
27403 PR target/78090
27404 * config/i386/constraints.md (Yc): New register constraint.
27405 * config/i386/i386.md (*float<SWI48:mode><MODEF:mode>2_mixed):
27406 Use Yc constraint for alternative 2 of operand 0. Remove
27407 preferred_for_speed attribute.
27408
27409 2018-03-14 Richard Biener <rguenther@suse.de>
27410
27411 PR tree-optimization/84830
27412 * tree-ssa-pre.c (compute_antic_aux): Intersect the new ANTIC_IN
27413 with the old one to avoid oscillations.
27414
27415 2018-03-13 Vladimir Makarov <vmakarov@redhat.com>
27416
27417 PR target/83712
27418 * lra-assigns.c (find_all_spills_for): Ignore uninteresting
27419 pseudos.
27420 (assign_by_spills): Return a flag of reload assignment failure.
27421 Do not process the reload assignment failures. Do not spill other
27422 reload pseudos if they has the same reg class. Update n if
27423 necessary.
27424 (lra_assign): Add a return arg. Set up from the result of
27425 assign_by_spills call.
27426 (find_reload_regno_insns, lra_split_hard_reg_for): New functions.
27427 * lra-constraints.c (split_reg): Add a new arg. Use it instead of
27428 usage_insns if it is not NULL.
27429 (spill_hard_reg_in_range): New function.
27430 (split_if_necessary, inherit_in_ebb): Pass a new arg to split_reg.
27431 * lra-int.h (spill_hard_reg_in_range, lra_split_hard_reg_for): New
27432 function prototypes.
27433 (lra_assign): Change prototype.
27434 * lra.c (lra): Add code to deal with fails by splitting hard reg
27435 live ranges.
27436
27437 2018-03-01 Palmer Dabbelt <palmer@sifive.com>
27438
27439 * config/riscv/riscv.opt (mrelax): New option.
27440 * config/riscv/riscv.c (riscv_file_start): Emit ".option
27441 "norelax" when riscv_mrelax is disabled.
27442 * doc/invoke.texi (RISC-V): Document "-mrelax" and "-mno-relax".
27443
27444 2018-03-13 Aaron Sawdey <acsawdey@linux.vnet.ibm.com>
27445
27446 PR target/84743
27447 * config/rs6000/rs6000.c (rs6000_reassociation_width): Disable parallel
27448 reassociation for int modes.
27449
27450 2018-03-13 Richard Sandiford <richard.sandiford@linaro.org>
27451
27452 * tree-vect-loop-manip.c (vect_maybe_permute_loop_masks):
27453 Reverse the choice between VEC_UNPACK_LO_EXPR and VEC_UNPACK_HI_EXPR
27454 for big-endian.
27455 * config/aarch64/iterators.md (hi_lanes_optab): New int attribute.
27456 * config/aarch64/aarch64-sve.md
27457 (*aarch64_sve_<perm_insn><perm_hilo><mode>): Rename to...
27458 (aarch64_sve_<perm_insn><perm_hilo><mode>): ...this.
27459 (*extend<mode><Vwide>2): Rename to...
27460 (aarch64_sve_extend<mode><Vwide>2): ...this.
27461 (vec_unpack<su>_<perm_hilo>_<mode>): Turn into a define_expand,
27462 renaming the old pattern to...
27463 (aarch64_sve_punpk<perm_hilo>_<mode>): ...this. Only define
27464 unsigned packs.
27465 (vec_unpack<su>_<perm_hilo>_<SVE_BHSI:mode>): Turn into a
27466 define_expand, renaming the old pattern to...
27467 (aarch64_sve_<su>unpk<perm_hilo>_<SVE_BHSI:mode>): ...this.
27468 (*vec_unpacku_<perm_hilo>_<mode>_no_convert): Delete.
27469 (vec_unpacks_<perm_hilo>_<mode>): Take BYTES_BIG_ENDIAN into
27470 account when deciding which SVE instruction the optab should use.
27471 (vec_unpack<su_optab>_float_<perm_hilo>_vnx4si): Likewise.
27472
27473 2018-03-13 Richard Sandiford <richard.sandiford@linaro.org>
27474
27475 * config/aarch64/aarch64.md (V4_REGNUM, V8_REGNUM, V12_REGNUM)
27476 (V20_REGNUM, V24_REGNUM, V28_REGNUM, P1_REGNUM, P2_REGNUM, P3_REGNUM)
27477 (P4_REGNUM, P5_REGNUM, P6_REGNUM, P8_REGNUM, P9_REGNUM, P10_REGNUM)
27478 (P11_REGNUM, P12_REGNUM, P13_REGNUM, P14_REGNUM): New define_constants.
27479 (tlsdesc_small_<mode>): Turn a define_expand and use
27480 tlsdesc_small_sve_<mode> for SVE. Rename original define_insn to...
27481 (tlsdesc_small_advsimd_<mode>): ...this.
27482 (tlsdesc_small_sve_<mode>): New pattern.
27483
27484 2018-03-13 Richard Sandiford <richard.sandiford@linaro.org>
27485
27486 * config/aarch64/iterators.md (UNSPEC_SMUL_HIGHPART)
27487 (UNSPEC_UMUL_HIGHPART): New constants.
27488 (MUL_HIGHPART): New int iteraor.
27489 (su): Handle UNSPEC_SMUL_HIGHPART and UNSPEC_UMUL_HIGHPART.
27490 * config/aarch64/aarch64-sve.md (<su>mul<mode>3_highpart): New
27491 define_expand.
27492 (*<su>mul<mode>3_highpart): New define_insn.
27493
27494 2018-03-13 Eric Botcazou <ebotcazou@adacore.com>
27495
27496 PR lto/84805
27497 * ipa-devirt.c (odr_subtypes_equivalent_p): Do not get the ODR type of
27498 incomplete types.
27499
27500 2018-03-13 Martin Liska <mliska@suse.cz>
27501
27502 PR ipa/84658.
27503 * (sem_item_optimizer::sem_item_optimizer): Initialize new
27504 vector.
27505 (sem_item_optimizer::~sem_item_optimizer): Release it.
27506 (sem_item_optimizer::merge_classes): Register variable aliases.
27507 (sem_item_optimizer::fixup_pt_set): New function.
27508 (sem_item_optimizer::fixup_points_to_sets): Likewise.
27509 * ipa-icf.h: Declare new variables and functions.
27510
27511 2018-03-13 Jakub Jelinek <jakub@redhat.com>
27512
27513 PR middle-end/84834
27514 * match.pd ((A & C) != 0 ? D : 0): Use INTEGER_CST@2 instead of
27515 integer_pow2p@2 and test integer_pow2p in condition.
27516 (A < 0 ? C : 0): Similarly for @1.
27517
27518 PR middle-end/84831
27519 * stmt.c (parse_output_constraint): If the CONSTRAINT_LEN (*p, p)
27520 characters starting at p contain '\0' character, don't look beyond
27521 that.
27522
27523 PR target/84827
27524 * config/i386/i386.md (round<mode>2): For 387 fancy math, disable
27525 pattern if -ftrapping-math -fno-fp-int-builtin-inexact.
27526
27527 PR target/84828
27528 * reg-stack.c (change_stack): Change update_end var from int to
27529 rtx_insn *, if non-NULL don't update just BB_END (current_block), but
27530 also call set_block_for_insn on the newly added insns and rescan.
27531
27532 PR target/84786
27533 * config/i386/sse.md (sse2_loadhpd): Use Yv constraint rather than v
27534 on the last operand.
27535
27536 PR c++/84704
27537 * tree.c (stabilize_reference_1): Return save_expr (e) for
27538 STATEMENT_LIST even if it doesn't have side-effects.
27539
27540 2018-03-12 Jonathan Wakely <jwakely@redhat.com>
27541
27542 * doc/invoke.texi (-mclflushopt): Fix spelling of option.
27543
27544 2018-03-12 Renlin Li <renlin.li@arm.com>
27545
27546 * config/aarch64/aarch64.md (movhf_aarch64): Fix mode argument to
27547 aarch64_output_scalar_simd_mov_immediate.
27548
27549 2018-03-12 Martin Sebor <msebor@redhat.com>
27550
27551 PR tree-optimization/83456
27552 * gimple-fold.c (gimple_fold_builtin_memory_op): Avoid warning
27553 for perfectly overlapping calls to memcpy.
27554 (gimple_fold_builtin_memory_chk): Same.
27555 (gimple_fold_builtin_strcpy): Handle no-warning.
27556 (gimple_fold_builtin_stxcpy_chk): Same.
27557 * tree-ssa-strlen.c (maybe_diag_stxncpy_trunc): Handle no-warning.
27558
27559 2018-03-12 Segher Boessenkool <segher@kernel.crashing.org>
27560
27561 * config/rs6000/rs6000.c (abi_v4_pass_in_fpr): Add bool "named"
27562 parameter. Use it for SFmode.
27563 (rs6000_function_arg_advance_1): Adjust.
27564 (rs6000_function_arg): Adjust.
27565 (rs6000_gimplify_va_arg): Pass false for that new parameter.
27566
27567 2018-03-12 Segher Boessenkool <segher@kernel.crashing.org>
27568
27569 PR rtl-optimization/84169
27570 PR rtl-optimization/84780
27571 * combine.c (can_combine_p): Check for a 2-insn combination whether
27572 the destination register is used between the two insns, too.
27573
27574 2018-03-12 Richard Biener <rguenther@suse.de>
27575
27576 PR tree-optimization/84803
27577 * tree-if-conv.c (ifcvt_memrefs_wont_trap): Don't do anything
27578 for refs DR analysis didn't process.
27579
27580 2018-03-12 Richard Biener <rguenther@suse.de>
27581
27582 PR tree-optimization/84777
27583 * tree-ssa-loop-ch.c (should_duplicate_loop_header_p): For
27584 force-vectorize loops ignore whether we are optimizing for size.
27585
27586 2018-03-12 Chung-Ju Wu <jasonwucj@gmail.com>
27587
27588 * config/nds32/nds32.c (nds32_md_asm_adjust): New function.
27589 (TARGET_MD_ASM_ADJUST): Define.
27590
27591 2018-03-12 Monk Chiang <sh.chiang04@gmail.com>
27592 Kito Cheng <kito.cheng@gmail.com>
27593 Chung-Ju Wu <jasonwucj@gmail.com>
27594
27595 * config/nds32/nds32.c (nds32_compute_stack_frame,
27596 nds32_emit_stack_push_multiple, nds32_emit_stack_pop_multiple,
27597 nds32_emit_stack_v3push, nds32_emit_stack_v3pop,
27598 nds32_emit_adjust_frame, nds32_expand_prologue, nds32_expand_epilogue,
27599 nds32_expand_prologue_v3push, nds32_expand_epilogue_v3pop): Refine.
27600 * config/nds32/nds32.h (NDS32_FIRST_CALLEE_SAVE_GPR_REGNUM,
27601 NDS32_LAST_CALLEE_SAVE_GPR_REGNUM, NDS32_V3PUSH_AVAILABLE_P): New.
27602 * config/nds32/nds32.md (prologue, epilogue): Use macro
27603 NDS32_V3PUSH_AVAILABLE_P to do checking.
27604
27605 2018-03-11 Jakub Jelinek <jakub@redhat.com>
27606
27607 PR debug/58150
27608 * dwarf2out.c (gen_enumeration_type_die): Don't guard adding
27609 DW_AT_declaration for ENUM_IS_OPAQUE on -gdwarf-4 or -gno-strict-dwarf,
27610 but on TYPE_SIZE. Don't do anything for ENUM_IS_OPAQUE if not creating
27611 a new die. Don't set TREE_ASM_WRITTEN if ENUM_IS_OPAQUE. Guard
27612 addition of most attributes on !orig_type_die or the attribute not
27613 being present already. Assert TYPE_VALUES is NULL for ENUM_IS_OPAQUE.
27614
27615 2018-03-11 Kito Cheng <kito.cheng@gmail.com>
27616 Chung-Ju Wu <jasonwucj@gmail.com>
27617
27618 * config/nds32/nds32.c (nds32_cpu_cpp_builtins): Modify to define
27619 __NDS32_VH__ macro.
27620 * config/nds32/nds32.opt (mvh): New option.
27621
27622 2018-03-11 Kito Cheng <kito.cheng@gmail.com>
27623 Chung-Ju Wu <jasonwucj@gmail.com>
27624
27625 * config/nds32/nds32-protos.h (nds32_cpu_cpp_builtins): Declare
27626 function.
27627 * config/nds32/nds32.c (nds32_cpu_cpp_builtins): New function.
27628 * config/nds32/nds32.h (TARGET_CPU_CPP_BUILTINS): Modify its
27629 definition.
27630
27631 2018-03-11 Kito Cheng <kito.cheng@gmail.com>
27632 Chung-Ju Wu <jasonwucj@gmail.com>
27633
27634 * config/nds32/nds32-memory-manipulation.c (nds32_expand_strlen): New
27635 function.
27636 * config/nds32/nds32-multiple.md (strlensi): New pattern.
27637 * config/nds32/nds32-protos.h (nds32_expand_strlen): Declare function.
27638
27639 2018-03-11 Monk Chiang <sh.chiang04@gmail.com>
27640 Kito Cheng <kito.cheng@gmail.com>
27641 Chung-Ju Wu <jasonwucj@gmail.com>
27642
27643 * config/nds32/constants.md (unspec_element): Add UNSPEC_FFB,
27644 UNSPEC_FFMISM and UNSPEC_FLMISM.
27645 * config/nds32/nds32-intrinsic.c (bdesc_2arg): Add builtin description
27646 for ffb, ffmism and flmism.
27647 * config/nds32/nds32-intrinsic.md (unspec_ffb): Define new pattern.
27648 (unspec_ffmism): Ditto.
27649 (unspec_flmism): Ditto.
27650 (nds32_expand_builtin_impl): Check if string extension is available.
27651 * config/nds32/nds32.h (nds32_builtins): Add NDS32_BUILTIN_FFB,
27652 NDS32_BUILTIN_FFMISM and NDS32_BUILTIN_FLMISM.
27653
27654 2018-03-10 Vladimir Makarov <vmakarov@redhat.com>
27655
27656 Reverting patch:
27657 2018-03-09 Vladimir Makarov <vmakarov@redhat.com>
27658
27659 PR target/83712
27660 * lra-assigns.c (assign_by_spills): Return a flag of reload
27661 assignment failure. Do not process the reload assignment
27662 failures. Do not spill other reload pseudos if they has the same
27663 reg class.
27664 (lra_assign): Add a return arg. Set up from the result of
27665 assign_by_spills call.
27666 (find_reload_regno_insns, lra_split_hard_reg_for): New functions.
27667 * lra-constraints.c (split_reg): Add a new arg. Use it instead of
27668 usage_insns if it is not NULL.
27669 (spill_hard_reg_in_range): New function.
27670 (split_if_necessary, inherit_in_ebb): Pass a new arg to split_reg.
27671 * lra-int.h (spill_hard_reg_in_range, lra_split_hard_reg_for): New
27672 function prototypes.
27673 (lra_assign): Change prototype.
27674 * lra.c (lra): Add code to deal with fails by splitting hard reg
27675 live ranges.
27676
27677 2018-03-10 H.J. Lu <hongjiu.lu@intel.com>
27678
27679 PR target/84807
27680 * config/i386/i386.opt: Replace Enforcment with Enforcement.
27681
27682 2018-03-10 Alexandre Oliva <aoliva@redhat.com>
27683
27684 PR debug/84620
27685 * dwarf2out.h (dw_val_class): Add dw_val_class_symview.
27686 (dw_val_node): Add val_symbolic_view.
27687 * dwarf2out.c (dw_line_info_table): Add symviews_since_reset.
27688 (symview_upper_bound): New.
27689 (new_line_info_table): Initialize symviews_since_reset.
27690 (dwarf2out_source_line): Count symviews_since_reset and set
27691 symview_upper_bound.
27692 (dw_val_equal_p): Handle symview.
27693 (add_AT_symview): New.
27694 (print_dw_val): Handle symview.
27695 (attr_checksum, attr_checksum_ordered): Likewise.
27696 (same_dw_val_p, size_of_die): Likewise.
27697 (value_format, output_die): Likewise.
27698 (add_high_low_attributes): Use add_AT_symview for entry_view.
27699 (dwarf2out_finish): Reset symview_upper_bound, clear
27700 zero_view_p.
27701
27702 2018-03-09 Peter Bergner <bergner@vnet.ibm.com>
27703
27704 PR target/83969
27705 * config/rs6000/rs6000.c (rs6000_offsettable_memref_p): New prototype.
27706 Add strict argument and use it.
27707 (rs6000_split_multireg_move): Update for new strict argument.
27708 (mem_operand_gpr): Disallow all non-offsettable addresses.
27709 * config/rs6000/rs6000.md (*movdi_internal64): Use YZ constraint.
27710
27711 2018-03-09 Jakub Jelinek <jakub@redhat.com>
27712
27713 PR target/84772
27714 * config/rs6000/rs6000.c (rs6000_gimplify_va_arg): Mark va_arg_tmp
27715 temporary TREE_ADDRESSABLE before gimplification of BUILT_IN_MEMCPY.
27716 * config/powerpcspe/powerpcspe.c (rs6000_gimplify_va_arg): Likewise.
27717
27718 PR c++/84767
27719 * tree-inline.c (copy_tree_body_r): For INDIRECT_REF of a remapped
27720 decl, use remap_type if we want to use the type.
27721
27722 2018-03-09 Martin Sebor <msebor@redhat.com>
27723
27724 PR tree-optimization/84526
27725 * gimple-ssa-warn-restrict.c (builtin_memref::set_base_and_offset):
27726 Remove dead code.
27727 (builtin_access::generic_overlap): Be prepared to handle non-array
27728 base objects.
27729
27730 2018-03-09 Alexandre Oliva <aoliva@redhat.com>
27731
27732 PR rtl-optimization/84682
27733 * lra-constraints.c (process_address_1): Check is_address flag
27734 for address constraints.
27735 (process_alt_operands): Likewise.
27736 * lra.c (lra_set_insn_recog_data): Pass asm operand locs to
27737 preprocess_constraints.
27738 * recog.h (preprocess_constraints): Add oploc parameter.
27739 Adjust callers.
27740 * recog.c (preprocess_constraints): Test address_operand for
27741 CT_ADDRESS constraints.
27742
27743 2018-03-09 Vladimir Makarov <vmakarov@redhat.com>
27744
27745 PR target/83712
27746 * lra-assigns.c (assign_by_spills): Return a flag of reload
27747 assignment failure. Do not process the reload assignment
27748 failures. Do not spill other reload pseudos if they has the same
27749 reg class.
27750 (lra_assign): Add a return arg. Set up from the result of
27751 assign_by_spills call.
27752 (find_reload_regno_insns, lra_split_hard_reg_for): New functions.
27753 * lra-constraints.c (split_reg): Add a new arg. Use it instead of
27754 usage_insns if it is not NULL.
27755 (spill_hard_reg_in_range): New function.
27756 (split_if_necessary, inherit_in_ebb): Pass a new arg to split_reg.
27757 * lra-int.h (spill_hard_reg_in_range, lra_split_hard_reg_for): New
27758 function prototypes.
27759 (lra_assign): Change prototype.
27760 * lra.c (lra): Add code to deal with fails by splitting hard reg
27761 live ranges.
27762
27763 2018-03-09 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
27764
27765 PR target/83193
27766 * common/config/arm/arm-common.c (arm_parse_arch_option_name):
27767 Accept complain bool parameter. Only emit errors if it is true.
27768 (arm_parse_cpu_option_name): Likewise.
27769 (arm_target_thumb_only): Adjust callers of the above.
27770 * config/arm/arm-protos.h (arm_parse_cpu_option_name): Adjust
27771 prototype to take a default true bool parameter.
27772 (arm_parse_arch_option_name): Likewise.
27773
27774 2018-03-09 David Malcolm <dmalcolm@redhat.com>
27775 Francois-Xavier Coudert <fxcoudert@gcc.gnu.org>
27776
27777 PR jit/64089
27778 PR jit/84288
27779 * Makefile.in (LD_VERSION_SCRIPT_OPTION, LD_SONAME_OPTION): New.
27780 * configure: Regenerate.
27781 * configure.ac ("linker --version-script option"): New.
27782 ("linker soname option"): New.
27783
27784 2018-03-09 Richard Biener <rguenther@suse.de>
27785
27786 PR tree-optimization/84775
27787 * tree-if-conv.c (add_bb_predicate_gimplified_stmts): Delink
27788 immediate uses of predicate stmts and mark them modified.
27789
27790 Revert
27791 PR tree-optimization/84178
27792 * tree-if-conv.c (combine_blocks): Move insert_gimplified_predicates
27793 to caller.
27794 (version_loop_for_if_conversion): Delay update_ssa call.
27795 (tree_if_conversion): Delay update_ssa until after predicate
27796 insertion.
27797
27798 2018-03-09 Eric Botcazou <ebotcazou@adacore.com>
27799
27800 PR target/84763
27801 * config/i386/winnt.c (i386_pe_seh_cold_init): Use small pre-allocation
27802 when the function accesses prior frames.
27803
27804 2018-03-08 Jakub Jelinek <jakub@redhat.com>
27805
27806 PR debug/84456
27807 * dwarf2out.c (dw_loc_list): If list && loc_list->first->next, call
27808 gen_llsym, otherwise call maybe_gen_llsym.
27809
27810 PR inline-asm/84742
27811 * recog.c (asm_operand_ok): Return 0 if multi-character constraint
27812 has ',' character inside of it.
27813
27814 2018-03-08 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
27815
27816 PR target/84748
27817 * config/aarch64/aarch64.md (*compare_cstore<mode>_insn): Mark pattern
27818 as clobbering CC_REGNUM.
27819
27820 2018-03-08 Richard Biener <rguenther@suse.de>
27821
27822 PR middle-end/84552
27823 * tree-scalar-evolution.c: Include tree-into-ssa.h.
27824 (follow_copies_to_constant): Do not follow SSA names registered
27825 for update.
27826
27827 2018-03-08 Richard Biener <rguenther@suse.de>
27828
27829 PR tree-optimization/84178
27830 * tree-if-conv.c (combine_blocks): Move insert_gimplified_predicates
27831 to caller.
27832 (version_loop_for_if_conversion): Delay update_ssa call.
27833 (tree_if_conversion): Delay update_ssa until after predicate
27834 insertion.
27835
27836 2018-03-08 David Malcolm <dmalcolm@redhat.com>
27837
27838 PR tree-optimization/84178
27839 * tree-if-conv.c (release_bb_predicate): Remove the
27840 the assertion that the stmts have NULL use_ops.
27841 Discard the statements, asserting that they haven't
27842 yet been added to a BB.
27843
27844 2018-03-08 Richard Biener <rguenther@suse.de>
27845
27846 PR tree-optimization/84746
27847 * tree-ssa-pre.c (find_leader_in_sets): Deal with SET1 being NULL.
27848 (phi_translate): Pass in destination ANTIC_OUT set.
27849 (phi_translate_1): Likewise. For a simplified result lookup
27850 a leader in ANTIC_OUT and AVAIL_OUT, not the ANTIC_IN sets.
27851 (phi_translate_set): Adjust.
27852 (do_pre_regular_insertion): Likewise.
27853 (do_pre_partial_partial_insertion): Likewise.
27854
27855 2018-03-08 Martin Liska <mliska@suse.cz>
27856
27857 PR gcov-profile/84735
27858 * doc/gcov.texi: Document usage of profile files.
27859 * gcov-io.h: Document changes in the format.
27860
27861 2018-03-08 Alexandre Oliva <aoliva@redhat.com>
27862
27863 PR debug/84404
27864 PR debug/84408
27865 * dwarf2out.c (struct dw_line_info_table): Update comments for
27866 view == -1.
27867 (FORCE_RESET_NEXT_VIEW): New.
27868 (FORCE_RESETTING_VIEW_P): New.
27869 (RESETTING_VIEW_P): Check for -1 too.
27870 (ZERO_VIEW_P): Likewise.
27871 (new_line_info_table): Force-reset next view.
27872 (dwarf2out_begin_function): Likewise.
27873 (dwarf2out_source_line): Simplify zero_view_p initialization.
27874 Test FORCE_RESETTING_VIEW_P and RESETTING_VIEW_P instead of
27875 view directly. Omit view when omitting .loc at line 0.
27876
27877 2018-03-08 Jakub Jelinek <jakub@redhat.com>
27878
27879 PR tree-optimization/84740
27880 * tree-switch-conversion.c (process_switch): Call build_constructors
27881 only if info.phi_count is non-zero.
27882
27883 PR tree-optimization/84739
27884 * tree-tailcall.c (find_tail_calls): Check call arguments against
27885 DECL_ARGUMENTS (current_function_decl) rather than
27886 DECL_ARGUMENTS (func) when checking for tail recursion.
27887
27888 2018-03-07 Jakub Jelinek <jakub@redhat.com>
27889
27890 * doc/contrib.texi: Add entries for Martin Liska, David Malcolm,
27891 Marek Polacek, extend Vladimir Makarov's, Jonathan Wakely's and
27892 Volker Reichelt's entry and add entries for people that perform
27893 GCC fuzzy testing and report numerous bugs.
27894
27895 2018-03-07 Segher Boessenkool <segher@kernel.crashing.org>
27896
27897 PR target/82411
27898 * config/rs6000/rs6000.c (rs6000_elf_in_small_data_p): Don't put
27899 readonly data in sdata, if that is disabled.
27900 * config/rs6000/sysv4.opt (mreadonly-in-sdata): New option.
27901 * doc/invoke.texi (RS/6000 and PowerPC Options): Document
27902 -mreadonly-in-sdata option.
27903
27904 2018-03-07 Martin Sebor <msebor@redhat.com>
27905
27906 PR tree-optimization/84468
27907 * tree-ssa-strlen.c (maybe_diag_stxncpy_trunc): Consider successor
27908 basic block when looking for nul assignment.
27909
27910 2018-03-07 Eric Botcazou <ebotcazou@adacore.com>
27911
27912 PR target/84277
27913 * except.h (output_function_exception_table): Adjust prototype.
27914 * except.c (output_function_exception_table): Remove FNNAME parameter
27915 and add SECTION parameter. Ouput one part of the table at a time.
27916 * final.c (final_scan_insn_1) <NOTE_INSN_SWITCH_TEXT_SECTIONS>: Output
27917 the first part of the exception table and emit unwind directives.
27918 * config/i386/i386-protos.h (i386_pe_end_cold_function): Declare.
27919 (i386_pe_seh_cold_init): Likewise.
27920 * config/i386/cygming.h (ASM_DECLARE_COLD_FUNCTION_NAME): New macro.
27921 (ASM_DECLARE_COLD_FUNCTION_SIZE): Likewise.
27922 * config/i386/i386.c (x86_expand_epilogue): Fix wording in comment.
27923 (ix86_output_call_insn): Emit a nop in one more case for SEH.
27924 * config/i386/winnt.c: Include except.h.
27925 (struct seh_frame_state): Add reg_offset, after_prologue and
27926 in_cold_section fields.
27927 (i386_pe_seh_end_prologue): Set seh->after_prologue.
27928 (i386_pe_seh_cold_init): New function.
27929 (i386_pe_seh_fini): Add COLD parameter and bail out if it is not equal
27930 to seh->in_cold_section.
27931 (seh_emit_push): Record the offset of the push.
27932 (seh_emit_save): Record the offet of the save.
27933 (i386_pe_seh_unwind_emit): Deal with NOTE_INSN_SWITCH_TEXT_SECTIONS.
27934 Test seh->after_prologue to disregard the epilogue.
27935 (i386_pe_end_function): Pass FALSE to i386_pe_seh_fini.
27936 (i386_pe_end_cold_function): New function.
27937
27938 2018-03-07 Jakub Jelinek <jakub@redhat.com>
27939
27940 PR fortran/84565
27941 * config/aarch64/predicates.md (aarch64_simd_reg_or_zero): Use
27942 aarch64_simd_or_scalar_imm_zero rather than aarch64_simd_imm_zero.
27943
27944 PR c++/84704
27945 * gimple-expr.c (create_tmp_var_raw): Set DECL_NAMELESS flag
27946 on tmp_var.
27947 * tree-pretty-print.c (dump_decl_name): For TDF_COMPARE_DEBUG,
27948 don't print names of DECL_NAMELESS DECL_IGNORED_P decls.
27949
27950 PR middle-end/84723
27951 * multiple_target.c: Include tree-inline.h and intl.h.
27952 (expand_target_clones): Diagnose and fail if node->definition and
27953 !tree_versionable_function_p (node->decl).
27954
27955 2018-03-06 John David Anglin <danglin@gcc.gnu.org>
27956
27957 * config/pa/pa.h (ASM_GENERATE_INTERNAL_LABEL): Revise to use
27958 sprint_ul.
27959 (ASM_OUTPUT_ADDR_VEC_ELT): Revise for above change.
27960 (ASM_OUTPUT_ADDR_DIFF_ELT): Likewise.
27961 * config/pa/pa64-hpux.h (ASM_GENERATE_INTERNAL_LABEL): Revise as above.
27962
27963 2018-03-06 Jakub Jelinek <jakub@redhat.com>
27964
27965 PR target/84710
27966 * combine.c (try_combine): Use reg_or_subregno instead of handling
27967 just paradoxical SUBREGs and REGs.
27968
27969 2018-03-06 Claudiu Zissulescu <claziss@synopsys.com>
27970
27971 * config/arc/arc.c (arc_finalize_pic): Remove function.
27972 (arc_must_save_register): We use single base PIC register, remove
27973 checks to save/restore the PIC register.
27974 (arc_expand_prologue): Likewise.
27975 * config/arc/arc-protos.h (arc_set_default_type_attributes):
27976 Remove.
27977 (arc_verify_short): Likewise.
27978 (arc_attr_type): Likewise.
27979 * config/arc/arc.c (arc_set_default_type_attributes): Remove.
27980 (walk_stores): Likewise.
27981 (arc_address_cost): Make it static.
27982 (arc_verify_short): Likewise.
27983 (branch_dest): Likewise.
27984 (arc_attr_type): Likewise.
27985 * config/arc/arc.c (TARGET_ADJUST_INSN_LENGTH): Remove.
27986 (TARGET_INSN_LENGTH_PARAMETERS): Likewise.
27987 (arc_final_prescan_insn): Remove inserting the nops due to
27988 hardware hazards. It is done in reorg step.
27989 (insn_length_variant_t): Remove.
27990 (insn_length_parameters_t): Likewise.
27991 (arc_insn_length_parameters): Likewise.
27992 (arc_get_insn_variants): Likewise.
27993 * config/arc/arc.h (TARGET_UPSIZE_DBR): Remove.
27994
27995 2018-03-06 Jakub Jelinek <jakub@redhat.com>
27996
27997 PR inline-asm/84683
27998 * reg-stack.c (move_for_stack_reg): If any_malformed_asm, avoid
27999 assertion failure.
28000
28001 PR tree-optimization/84687
28002 * omp-simd-clone.c (simd_clone_create): Clear DECL_BUILT_IN_CLASS
28003 on new_node->decl.
28004 * match.pd (pow(C,x)*expN(y) -> expN(logN(C)*x+y)): New optimization.
28005
28006 2018-03-05 Bill Schmidt <wschmidt@linux.vnet.ibm.com>
28007
28008 * config/rs6000/rs6000-builtin.def (rs6000_speculation_barrier):
28009 Rename to ppc_speculation_barrier.
28010 * config/rs6000/rs6000.c (rs6000_init_builtins): Rename builtin to
28011 __builtin_ppc_speculation_barrier.
28012
28013 2018-03-05 Jakub Jelinek <jakub@redhat.com>
28014
28015 PR target/84700
28016 * combine.c (combine_simplify_rtx): Don't try to simplify if
28017 if_then_else_cond returned non-NULL, but either true_rtx or false_rtx
28018 are equal to x.
28019
28020 2018-03-05 Segher Boessenkool <segher@kernel.crashing.org>
28021
28022 * config/rs6000/rs6000.c (rs6000_loop_align): Don't align tiny loops
28023 to 32 bytes when compiling for POWER9.
28024
28025 2018-03-05 Jakub Jelinek <jakub@redhat.com>
28026
28027 PR target/84564
28028 * config/i386/i386.c (ix86_function_ok_for_sibcall): Check for
28029 regparm >= 3 with no arg reg available also for calls with
28030 flag_force_indirect_call. Pass decl to ix86_function_regparm.
28031
28032 PR target/84524
28033 * config/i386/sse.md (*<code><mode>3): Replace <mask_prefix3> with
28034 orig,vex.
28035 (*<plusminus_insn><mode>3): Likewise. Remove <mask_operand3> uses.
28036
28037 2018-03-05 Peter Bergner <bergner@vnet.ibm.com>
28038
28039 PR target/84264
28040 * config/rs6000/vector.md (mov<mode>): Disallow altivec memory operands.
28041
28042 2018-03-05 Richard Biener <rguenther@suse.de>
28043
28044 PR tree-optimization/84486
28045 * tree-ssa-pre.c (create_expression_by_pieces): Remove dead code.
28046 When inserting a __builtin_assume_aligned call set the LHS
28047 SSA name alignment info accordingly.
28048
28049 2018-03-05 Wilco Dijkstra <wdijkstr@arm.com>
28050
28051 PR tree-optimization/84114
28052 * config/aarch64/aarch64.c (aarch64_reassociation_width)
28053 Avoid reassociation of FLOAT_MODE addition.
28054
28055 2018-03-05 Olga Makhotina <olga.makhotina@intel.com>
28056
28057 * common/config/i386/i386-common.c (OPTION_MASK_ISA_PCONFIG_SET,
28058 OPTION_MASK_ISA_PCONFIG_UNSET, OPTION_MASK_ISA_WBNOINVD_SET,
28059 OPTION_MASK_ISA_WBNOINVD_UNSET): New definitions.
28060 (ix86_handle_option): Handle -mpconfig and -mwbnoinvd.
28061 * config.gcc (pconfigintrin.h, wbnoinvdintrin.h) : Add headers.
28062 * config/i386/cpuid.h (bit_PCONFIG, bit_WBNOINVD): New.
28063 * config/i386/driver-i386.c (host_detect_local_cpu): Detect -mpconfig
28064 and -mwbnoinvd.
28065 * config/i386/i386-builtin.def (__builtin_ia32_wbnoinvd,
28066 __builtin_ia32_wbinvd): New builtins.
28067 (SPECIAL_ARGS2): New.
28068 * config/i386/i386-c.c (__WBNOINVD__, __PCONFIG__): New.
28069 (SPECIAL_ARGS2): New.
28070 * config/i386/i386.c (ix86_target_string): Add -mpconfig and -mwbnoinvd.
28071 (ix86_valid_target_attribute_inner_p): Ditto.
28072 (ix86_init_mmx_sse_builtins): Add special_args2.
28073 * config/i386/i386.h (TARGET_PCONFIG, TARGET_PCONFIG_P, TARGET_WBNOINVD,
28074 TARGET_WBNOINVD_P): New.
28075 * config/i386/i386.md (UNSPECV_WBINVD, UNSPECV_WBNOINVD): New.
28076 (define_insn "wbinvd", define_insn "wbnoinvd"): New.
28077 * config/i386/i386.opt: Add -mpconfig and -mwbnoinvd.
28078 * config/i386/immintrin.h (_wbinvd): New intrinsic.
28079 * config/i386/pconfigintrin.h: New file.
28080 * config/i386/wbnoinvdintrin.h: Ditto.
28081 * config/i386/x86intrin.h: Add headers pconfigintrin.h and
28082 wbnoinvdintrin.h.
28083 * doc/invoke.texi (-mpconfig, -mwbnoinvd): New.
28084
28085 2018-03-05 Richard Biener <rguenther@suse.de>
28086
28087 PR tree-optimization/84670
28088 * tree-ssa-pre.c (struct bb_bitmap_sets): Add visited_with_visited_succs
28089 member.
28090 (BB_VISITED_WITH_VISITED_SUCCS): New define.
28091 (compute_antic): Initialize BB_VISITED_WITH_VISITED_SUCCS.
28092 (compute_antic_aux): Only assert the number of values in ANTIC_IN
28093 doesn't grow if all successors (recursively) were visited at least
28094 once.
28095
28096 2018-03-05 Richard Biener <rguenther@suse.de>
28097
28098 PR tree-optimization/84650
28099 * tree-ssa-loop-im.c (pass_lim::execute): Reset the SCEV cache
28100 if executed in the loop pipeline.
28101
28102 2018-03-05 Sandra Loosemore <sandra@codesourcery.com>
28103
28104 * doc/configfiles.texi (Configuration Files): Move info about
28105 conditionalizing $target-protos.h to...
28106 * doc/sourcebuild.texi (Back End): Here. Explain how $target.h
28107 differs from $target-protos.h.
28108
28109 2018-03-05 Kito Cheng <kito.cheng@gmail.com>
28110 Chung-Ju Wu <jasonwucj@gmail.com>
28111
28112 * config/nds32/nds32-protos.h (nds32_expand_setmem): Declare.
28113 * config/nds32/nds32-multiple.md (setmemsi): Define.
28114 * config/nds32/nds32-memory-manipulation.c
28115 (nds32_gen_dup_4_byte_to_word_value): New.
28116 (emit_setmem_word_loop): New.
28117 (emit_setmem_byte_loop): New.
28118 (nds32_expand_setmem_loop): New.
28119 (nds32_expand_setmem_loop_v3m): New.
28120 (nds32_expand_setmem_unroll): New.
28121 (nds32_expand_setmem): New.
28122
28123 2018-03-04 Kito Cheng <kito.cheng@gmail.com>
28124 Chung-Ju Wu <jasonwucj@gmail.com>
28125
28126 * config/nds32/nds32-memory-manipulation.c
28127 (nds32_emit_load_store): New.
28128 (nds32_emit_post_inc_load_store): New.
28129 (nds32_emit_mem_move): New.
28130 (nds32_emit_mem_move_block): New.
28131 (nds32_expand_movmemsi_loop_unknown_size): New.
28132 (nds32_expand_movmemsi_loop_known_size): New.
28133 (nds32_expand_movmemsi_loop): New.
28134 (nds32_expand_movmemsi_unroll): New.
28135 (nds32_expand_movmemqi): Rename ...
28136 (nds32_expand_movmemsi): ... to this.
28137 * config/nds32/nds32-multiple.md (movmemqi): Rename ...
28138 (movmemsi): ... to this.
28139 * config/nds32/nds32-protos.h (nds32_expand_movmemqi): Rename ...
28140 (nds32_expand_movmemsi): ... to this.
28141
28142 2018-03-04 Kito Cheng <kito.cheng@gmail.com>
28143 Monk Chiang <sh.chiang04@gmail.com>
28144 Chung-Ju Wu <jasonwucj@gmail.com>
28145
28146 * config/nds32/nds32-protos.h
28147 (nds32_expand_load_multiple): New arguments.
28148 (nds32_expand_store_multiple): Ditto.
28149 (nds32_valid_multiple_load_store): Rename ...
28150 (nds32_valid_multiple_load_store_p): ... to this.
28151 * config/nds32/nds32-memory-manipulation.c
28152 (nds32_expand_load_multiple): Refine implementation.
28153 (nds32_expand_store_multiple): Ditto.
28154 * config/nds32/nds32-multiple.md
28155 (load_multiple): Update nds32_expand_load_multiple interface.
28156 (store_multiple): Update nds32_expand_store_multiple interface.
28157 * config/nds32/nds32-predicates.c
28158 (nds32_valid_multiple_load_store): Rename ...
28159 (nds32_valid_multiple_load_store_p): ... to this and refine
28160 implementation.
28161 * config/nds32/predicates.md
28162 (nds32_load_multiple_and_update_address_operation): New predicate.
28163 (nds32_store_multiple_and_update_address_operation): New predicate.
28164
28165 2018-03-04 Kito Cheng <kito.cheng@gmail.com>
28166 Chung-Ju Wu <jasonwucj@gmail.com>
28167
28168 * config/nds32/nds32.md (type): Add load_multiple and store_multiple.
28169 (combo): New attribute.
28170 * config/nds32/nds32-multiple.md: Refine patterns with new attributes.
28171
28172 2018-03-03 Chung-Ju Wu <jasonwucj@gmail.com>
28173
28174 * config/nds32/nds32.opt: Change -mcmodel= default value.
28175
28176 2018-03-03 Kito Cheng <kito.cheng@gmail.com>
28177 Monk Chiang <sh.chiang04@gmail.com>
28178 Chung-Ju Wu <jasonwucj@gmail.com>
28179
28180 * config/nds32/constants.md (unspec_element): New enum.
28181 * config/nds32/constraints.md (Umw): New constraint.
28182 * config/nds32/nds32-intrinsic.c: Add more builtin functions.
28183 * config/nds32/nds32-intrinsic.md: Likewise.
28184 * config/nds32/nds32-md-auxiliary.c (nds32_regno_to_enable4): New.
28185 (nds32_valid_smw_lwm_base_p): New.
28186 (nds32_output_smw_single_word): New.
28187 (nds32_output_lmw_single_word): New.
28188 (nds32_expand_unaligned_load): New.
28189 (nds32_expand_unaligned_store): New.
28190 * config/nds32/nds32-protos.h (nds32_valid_smw_lwm_base_p): Declare.
28191 (nds32_output_smw_single_word): Declare.
28192 (nds32_output_lmw_single_word): Declare.
28193 (nds32_expand_unaligned_load): Declare.
28194 (nds32_expand_unaligned_store): Declare.
28195 * config/nds32/nds32.h (nds32_builtins): Add NDS32_BUILTIN_UALOAD_HW,
28196 NDS32_BUILTIN_UALOAD_W, NDS32_BUILTIN_UALOAD_DW,
28197 NDS32_BUILTIN_UASTORE_HW, NDS32_BUILTIN_UASTORE_W,
28198 NDS32_BUILTIN_UASTORE_DW.
28199 * config/nds32/predicates.md (nds32_lmw_smw_base_operand): New
28200 predicate.
28201
28202 2018-03-03 Monk Chiang <sh.chiang04@gmail.com>
28203 Kito Cheng <kito.cheng@gmail.com>
28204 Chung-Ju Wu <jasonwucj@gmail.com>
28205
28206 * config/nds32/nds32-intrinsic.c
28207 (nds32_expand_builtin_null_ftype_reg): Delete.
28208 (nds32_expand_builtin_reg_ftype_imm): Ditto.
28209 (nds32_expand_builtin_null_ftype_reg_imm): Ditto.
28210 (nds32_read_argument): New.
28211 (nds32_legitimize_target): Ditto.
28212 (nds32_legitimize_argument): Ditto.
28213 (nds32_check_constant_argument): Ditto.
28214 (nds32_expand_unop_builtin): Ditto.
28215 (nds32_expand_unopimm_builtin): Ditto.
28216 (nds32_expand_binop_builtin): Ditto.
28217 (nds32_builtin_decl_impl): Ditto.
28218 (builtin_description): Ditto.
28219 (nds32_expand_builtin_impl): Rewrite with new infrastructure.
28220 (nds32_init_builtins_impl): Ditto.
28221 * config/nds32/nds32.c (TARGET_BUILTIN_DECL): Define.
28222 (nds32_builtin_decl): New.
28223 * config/nds32/nds32.h (nds32_builtins): Add NDS32_BUILTIN_COUNT.
28224 * config/nds32/nds32-protos.h (nds32_builtin_decl_impl): Declare.
28225
28226 2018-03-02 Jeff Law <law@redhat.com>
28227
28228 * reorg.c (stop_search_p): Handle DEBUG_INSN.
28229 (redundant_insn, fill_simple_delay_slots): Likewise.
28230 (fill_slots_from_thread): Likewise.
28231 * resource.c (mark_referenced_resources): Likewise.
28232 (mark_set_resources, find_dead_or_set_registers): Likewise.
28233
28234 2018-03-02 Jakub Jelinek <jakub@redhat.com>
28235
28236 * substring-locations.h (format_warning_va): Formatting fix for
28237 ATTRIBUTE_GCC_DIAG.
28238 (format_warning_at_substring): Fix up ATTRIBUTE_GCC_DIAG second
28239 argument.
28240 (format_warning_n_va, format_warning_at_substring_n): New prototypes.
28241 * substring-locations.c: Include intl.h.
28242 (format_warning_va): Turned into small wrapper around
28243 format_warning_n_va, renamed to ...
28244 (format_warning_n_va): ... this, add N and PLURAL_GMSGID arguments,
28245 rename GMSGID to SINGULAR_GMSGID, if SINGULAR_GMSGID != PLURAL_GMSGID,
28246 use ngettext.
28247 (format_warning_at_substring_n): New function.
28248 * gimple-ssa-sprintf.c: Remove GCC diagnostic ignored pragma.
28249 (fmtwarn): Add ATTRIBUTE_GCC_DIAG. Turn into a copy of
28250 format_warning_at_substring with just a shorter name instead of
28251 const function pointer.
28252 (fmtwarn_n): New function.
28253 (maybe_warn, format_directive, parse_directive): Use fmtwarn_n where
28254 appropriate, get rid of all the fmtstr temporaries, move conditionals
28255 with G_() wrapped string literals directly into fmtwarn arguments,
28256 cast dir.len to (int), formatting fixes.
28257
28258 2018-03-02 Thomas Schwinge <thomas@codesourcery.com>
28259
28260 * doc/invoke.texi: Remove "Cilk Plus" references.
28261
28262 2018-03-02 Jakub Jelinek <jakub@redhat.com>
28263 Richard Biener <rguenther@suse.de>
28264
28265 PR ipa/84628
28266 * expr.c (expand_expr_real_1) <case CALL_EXPR>: Don't emit diagnostics
28267 for error or warning attributes if CALL_FROM_THUNK_P is set.
28268 Formatting fixes.
28269
28270 2018-03-02 Jakub Jelinek <jakub@redhat.com>
28271
28272 PR target/56540
28273 * config/pa/pa.h (TARGET_CPU_CPP_BUILTINS): Predefine
28274 __SIZEOF_128__ macro if HPUX_LONG_DOUBLE_LIBRARY.
28275
28276 PR target/56540
28277 * config/ia64/ia64.h (TARGET_CPU_CPP_BUILTINS): Predefine
28278 __SIZEOF_{FPREG,FLOAT{80,128}}__ macros.
28279
28280 * predict.c (test_prediction_value_range): Use PROB_UNINITIALIZED
28281 instead of -1U in last predictors element's probability member.
28282
28283 2018-03-02 Eric Botcazou <ebotcazou@adacore.com>
28284
28285 PR ipa/83983
28286 * ipa-devirt.c (odr_subtypes_equivalent_p): Get the ODR type of both
28287 arguments if they are comparable.
28288
28289 2018-03-02 Richard Sandiford <richard.sandiford@linaro.org>
28290
28291 PR tree-optimization/84634
28292 * tree-vect-stmts.c (vectorizable_store, vectorizable_load): Replace
28293 masks and masked_loop_p with a single loop_masks, making sure it's
28294 null for bb vectorization.
28295
28296 2018-03-02 Richard Sandiford <richard.sandiford@linaro.org>
28297
28298 * tree-vect-data-refs.c (vect_analyze_data_ref_dependence)
28299 (vect_analyze_data_ref_access): Use loop->safe_len rather than
28300 loop->force_vectorize to check whether there is no alias.
28301
28302 2018-03-02 Jakub Jelinek <jakub@redhat.com>
28303
28304 PR target/84614
28305 * rtl.h (prev_real_nondebug_insn, next_real_nondebug_insn): New
28306 prototypes.
28307 * emit-rtl.c (next_real_insn, prev_real_insn): Fix up function
28308 comments.
28309 (next_real_nondebug_insn, prev_real_nondebug_insn): New functions.
28310 * cfgcleanup.c (try_head_merge_bb): Use prev_real_nondebug_insn
28311 instead of a loop around prev_real_insn.
28312 * combine.c (move_deaths): Use prev_real_nondebug_insn instead of
28313 prev_real_insn.
28314
28315 PR inline-asm/84625
28316 * config/i386/i386.c (ix86_print_operand): Use conditional
28317 output_operand_lossage instead of gcc_assert if CONST_VECTOR is not
28318 zero vector.
28319
28320 2018-03-02 Richard Biener <rguenther@suse.de>
28321
28322 PR tree-optimization/84427
28323 * tree-ssa-pre.c (bitmap_remove_expr_from_set): Remove.
28324 (bitmap_set_subtract_values): Rewrite to handle multiple
28325 exprs per value.
28326 (clean): Likewise.
28327 (prune_clobbered_mems): Likewise.
28328 (phi_translate): Take edge instead of pred/phiblock.
28329 (phi_translate_1): Likewise.
28330 (phi_translate_set): Likewise. Insert all translated
28331 exprs for a value into the set, keeping possibly multiple
28332 expressions per value.
28333 (compute_antic_aux): Adjust for phi_translate changes.
28334 When intersecting union the expressions and prune those
28335 not in the final value set, keeping possibly multiple
28336 expressions per value. Do not use value-insertion
28337 for unioning ANTIC_OUT U EXP_GEN - TMP_GEN but merge
28338 all expressions. Add verification that the value-sets
28339 only shrink during iteration.
28340 (compute_partial_antic_aux): Adjust for the phi_translate changes.
28341 (do_pre_regular_insertion): Likewise.
28342 (do_pre_partial_partial_insertion): Likewise.
28343
28344 2018-03-02 Richard Biener <rguenther@suse.de>
28345
28346 PR target/82005
28347 * config/darwin.c (saved_debug_info_level): New static global.
28348 (darwin_asm_lto_start): Disable debug info generation for LTO out.
28349 (darwin_asm_lto_end): Restore debug info generation settings.
28350
28351 2018-03-01 Martin Liska <mliska@suse.cz>
28352
28353 PR sanitizer/82484
28354 * sanopt.c (sanitize_rewrite_addressable_params): Do not handle
28355 volatile arguments.
28356
28357 2018-03-01 Richard Biener <rguenther@suse.de>
28358
28359 PR debug/84645
28360 * dwarf2out.c (gen_variable_die): Properly handle late VLA
28361 type annotation with LTO when debug was disabled at compile-time.
28362
28363 2018-03-01 Matthew Fortune <mfortune@gmail.com>
28364
28365 * config/mips/mips.c (mips_final_prescan_insn): Fix incorrect
28366 XINT with INTVAL.
28367 (mips_final_postscan_insn): Likewise.
28368
28369 2018-03-01 Richard Sandiford <richard.sandiford@linaro.org>
28370
28371 PR rtl-optimization/84528
28372 * alias.c (init_alias_target): Add commentary.
28373 (init_alias_analysis): Only give HARD_FRAME_POINTER_REGNUM
28374 a unique base value if the frame pointer is not eliminated
28375 to the stack pointer.
28376
28377 2018-03-01 Tom de Vries <tom@codesourcery.com>
28378
28379 PR rtl-optimization/83327
28380 * lra-int.h (hard_regs_spilled_into): Declare.
28381 * lra.c (hard_regs_spilled_into): Define.
28382 (init_reg_info): Init hard_regs_spilled_into.
28383 * lra-spills.c (assign_spill_hard_regs): Update hard_regs_spilled_into.
28384 * lra-lives.c (make_hard_regno_born, make_hard_regno_dead)
28385 (process_bb_lives): Handle hard_regs_spilled_into.
28386 (lra_create_live_ranges_1): Before doing liveness propagation, clear
28387 regs in all_hard_regs_bitmap if set in hard_regs_spilled_into.
28388
28389 2018-02-28 David Edelsohn <dje.gcc@gmail.com>
28390
28391 * config.gcc (powerpc-ibm-aix7.1.*): New stanza.
28392 (powerpc-ibm-aix[789]*): Default to AIX 7.2.
28393 * config/rs6000/aix71.h (TARGET_DEFAULT): Revert to Power4 ISA.
28394 * config/rs6000/aix72.h: New file.
28395
28396 2018-02-28 Jakub Jelinek <jakub@redhat.com>
28397
28398 * gimple-ssa-warn-restrict.c (maybe_diag_overlap): Use warning_n
28399 instead of warning_at with conditional singular and plural messages
28400 where possible.
28401
28402 PR target/52991
28403 * stor-layout.c (update_alignment_for_field): For
28404 targetm.ms_bitfield_layout_p (rli->t), if !is_bitfield
28405 && !DECL_PACKED (field), do the alignment update, just use
28406 only desired_align instead of MAX (type_align, desired_align)
28407 as the alignment.
28408 (place_field): Don't do known_align < desired_align handling
28409 early if targetm.ms_bitfield_layout_p (rli->t) and rli->prev_field
28410 is non-NULL, instead do it after rli->prev_field handling and
28411 only if not within a bitfield word. For DECL_PACKED (field)
28412 use type_align of BITS_PER_UNIT.
28413
28414 2018-02-28 Eric Botcazou <ebotcazou@adacore.com>
28415
28416 * config/aarch64/aarch64.c (aarch64_emit_probe_stack_range): Remove
28417 superfluous parentheses and trailing spaces.
28418
28419 2018-02-28 Richard Biener <rguenther@suse.de>
28420
28421 PR tree-optimization/84584
28422 * graphite-scop-detection.c (scop_detection::add_scop): Discard
28423 SCoPs with fake exit edge.
28424
28425 2018-02-28 Martin Liska <mliska@suse.cz>
28426
28427 PR testsuite/84597
28428 * timevar.c (timer::print): Fix format to properly print 100%
28429 values.
28430
28431 2018-02-28 Richard Biener <rguenther@suse.de>
28432
28433 PR middle-end/84607
28434 * genmatch.c (capture_info::walk_match): Do not mark
28435 captured expressions without operands as expr_p given
28436 they act more like predicates and should be subject to
28437 "lost tail" side-effect preserving.
28438
28439 2018-02-28 Alexandre Oliva <aoliva@redhat.com>
28440
28441 PR rtl-optimization/81611
28442 * auto-inc-dec.c (attempt_change): Move dead note from
28443 mem_insn if it's the next use of regno
28444 (find_address): Take address use of reg holding
28445 non-incremented value. Add parm to limit search to the named
28446 reg only.
28447 (merge_in_block): Attempt to use a mem insn that is the next
28448 use of the original regno.
28449
28450 2018-02-27 Martin Sebor <msebor@redhat.com>
28451
28452 PR c++/83871
28453 * doc/invoke.texi (-Wmissing-attributes): New option.
28454 * print-tree.c (print_node): Handle DECL_UNINLINABLE.
28455
28456 2018-02-27 Martin Sebor <msebor@redhat.com>
28457
28458 PR translation/84207
28459 * diagnostic-core.h (warning_n, error_n, inform_n): Change
28460 n argument to unsigned HOST_WIDE_INT.
28461 * diagnostic.c (warning_n, error_n, inform_n): Ditto.
28462 (diagnostic_n_impl): Ditto. Handle arguments in excess of LONG_MAX.
28463 * gimple-ssa-sprintf.c (format_directive): Simplify inform_n call.
28464 * tree-ssa-strlen.c (maybe_diag_stxncpy_trunc): Use warning_n.
28465
28466 2018-02-27 Richard Biener <rguenther@suse.de>
28467
28468 PR tree-optimization/84512
28469 * tree-vect-loop.c (vect_compute_single_scalar_iteration_cost):
28470 Do not use the estimate returned from record_stmt_cost for
28471 the scalar iteration cost but sum properly using add_stmt_cost.
28472
28473 2018-02-27 Richard Biener <rguenther@suse.de>
28474
28475 PR tree-optimization/84466
28476 * graphite-scop-detection.c (scop_detection::stmt_simple_for_scop_p):
28477 Adjust last change to less strictly validate use operands.
28478
28479 2018-02-27 Martin Liska <mliska@suse.cz>
28480
28481 PR gcov-profile/84548
28482 * gcov.c (process_file): Allow partial overlap and consider it
28483 also as group functions.
28484 (output_lines): Properly calculate range of lines for a group.
28485
28486 2018-02-27 Martin Liska <mliska@suse.cz>
28487
28488 * timevar.c (timer::print_row): Remove 'usr', 'sys', 'wall' and
28489 'ggc' suffixes. Change first column width.
28490 (timer::print): Fix formatting of the column.
28491
28492 2018-02-27 Alexandre Oliva <aoliva@redhat.com>
28493
28494 * tree-ssa-live.c (remove_unused_scope_block_p): Do not
28495 preserve inline entry blocks for the sake of debug inline
28496 entry point markers alone.
28497 (remove_unused_locals): Suggest in comments a better place to
28498 force the preservation of inline entry blocks that are
28499 otherwise unused, but do not preserve them.
28500
28501 2018-02-26 H.J. Lu <hongjiu.lu@intel.com>
28502
28503 * config/i386/i386.c (ix86_output_indirect_jmp): Update comments.
28504
28505 2018-02-26 H.J. Lu <hongjiu.lu@intel.com>
28506
28507 PR target/84039
28508 * config/i386/constraints.md (Bs): Replace
28509 ix86_indirect_branch_register with
28510 TARGET_INDIRECT_BRANCH_REGISTER.
28511 (Bw): Likewise.
28512 * config/i386/i386.md (indirect_jump): Likewise.
28513 (tablejump): Likewise.
28514 (*sibcall_memory): Likewise.
28515 (*sibcall_value_memory): Likewise.
28516 Peepholes of indirect call and jump via memory: Likewise.
28517 (*sibcall_GOT_32): Disallowed for TARGET_INDIRECT_BRANCH_REGISTER.
28518 (*sibcall_value_GOT_32): Likewise.
28519 * config/i386/predicates.md (indirect_branch_operand): Likewise.
28520 (GOT_memory_operand): Likewise.
28521 (call_insn_operand): Likewise.
28522 (sibcall_insn_operand): Likewise.
28523 (GOT32_symbol_operand): Likewise.
28524 * config/i386/i386.h (TARGET_INDIRECT_BRANCH_REGISTER): New.
28525
28526 2018-02-26 Eric Botcazou <ebotcazou@adacore.com>
28527
28528 PR rtl-optimization/83496
28529 * reorg.c (steal_delay_list_from_target): Change REDUNDANT array from
28530 booleans to RTXes. Call fix_reg_dead_note on every non-null element.
28531 (steal_delay_list_from_fallthrough): Call fix_reg_dead_note on a
28532 redundant insn, if any.
28533 (relax_delay_slots): Likewise.
28534 (update_reg_unused_notes): Rename REDUNDANT_INSN to OTHER_INSN.
28535
28536 2018-02-26 Richard Sandiford <richard.sandiford@linaro.org>
28537
28538 PR tree-optimization/83965
28539 * tree-vect-patterns.c (vect_reassociating_reduction_p): Assume
28540 that grouped statements are part of a reduction chain. Return
28541 true if the statement is not marked as a reduction itself but
28542 is part of a group.
28543 (vect_recog_dot_prod_pattern): Don't check whether the statement
28544 is part of a group here.
28545 (vect_recog_sad_pattern): Likewise.
28546 (vect_recog_widen_sum_pattern): Likewise.
28547
28548 2018-02-26 Eric Botcazou <ebotcazou@adacore.com>
28549
28550 PR debug/84545
28551 * final.c (rest_of_clean_state): Also look for calls inside sequences.
28552
28553 2018-02-26 H.J. Lu <hongjiu.lu@intel.com>
28554
28555 PR target/84530
28556 * config/i386/i386-protos.h (ix86_output_indirect_jmp): Remove
28557 the bool argument.
28558 (ix86_output_indirect_function_return): New prototype.
28559 (ix86_split_simple_return_pop_internal): Likewise.
28560 * config/i386/i386.c (indirect_return_via_cx): New.
28561 (indirect_return_via_cx_bnd): Likewise.
28562 (indirect_thunk_name): Handle return va CX_REG.
28563 (output_indirect_thunk_function): Create alias for
28564 __x86_return_thunk_[re]cx and __x86_return_thunk_[re]cx_bnd.
28565 (ix86_output_indirect_jmp): Remove the bool argument.
28566 (ix86_output_indirect_function_return): New function.
28567 (ix86_split_simple_return_pop_internal): Likewise.
28568 * config/i386/i386.md (*indirect_jump): Don't pass false
28569 to ix86_output_indirect_jmp.
28570 (*tablejump_1): Likewise.
28571 (simple_return_pop_internal): Change it to define_insn_and_split.
28572 Call ix86_split_simple_return_pop_internal to split it for
28573 -mfunction-return=.
28574 (simple_return_indirect_internal): Call
28575 ix86_output_indirect_function_return instead of
28576 ix86_output_indirect_jmp.
28577
28578 2018-02-26 Jakub Jelinek <jakub@redhat.com>
28579
28580 PR bootstrap/84405
28581 * vec.h (vec_default_construct): For BROKEN_VALUE_INITIALIZATION use
28582 memset and value initialization afterwards.
28583
28584 2018-02-26 Christophe Lyon <christophe.lyon@linaro.org>
28585
28586 * Makefile.in (lto-wrapper): Use ALL_LINKERFLAGS.
28587
28588 2018-02-26 Ramana Radhakrishnan <ramana.radhakrishnan@arm.com>
28589
28590 PR target/84521
28591 * common/config/aarch64/aarch64-common.c
28592 (aarch_option_optimization_table[]): Switch
28593 off fomit-frame-pointer
28594
28595 2018-02-26 Kito Cheng <kito.cheng@gmail.com>
28596 Chung-Ju Wu <jasonwucj@gmail.com>
28597
28598 * config/nds32/nds32-multiple.md (load_multiple): Disallow
28599 volatile memory.
28600 (store_multiple): Ditto.
28601
28602 2018-02-26 Kito Cheng <kito.cheng@gmail.com>
28603
28604 * config.gcc: Add --with-cpu support for nds32 target.
28605 * config/nds32/nds32-opts.h (nds32_cpu_type): New.
28606 * config/nds32/nds32.opt: Add -mcpu= option.
28607
28608 2018-02-25 Segher Boessenkool <segher@kernel.crashing.org>
28609
28610 * config/rs6000/rs6000.opt (mvrsave=no, mvrsave=yes, isel=no,
28611 isel=yes): Warn for these deprecated options.
28612
28613 2018-02-23 David Edelsohn <dje.gcc@gmail.com>
28614
28615 * config/rs6000/aix71.h (TARGET_DEFAULT): Change to
28616 ISA_2_5_MASKS_EMBEDDED.
28617
28618 2018-02-23 Jakub Jelinek <jakub@redhat.com>
28619
28620 * ipa-prop.c (ipa_vr_ggc_hash_traits::hash): Hash p->min and
28621 p->max as pointers rather than using iterative_hash_expr.
28622
28623 2018-02-23 Carl Love <cel@us.ibm.com>
28624
28625 * config/rs6000/rs6000-builtin.def: Change VSIGNED2 and VUNSIGNED2
28626 macro expansions from BU_VSX_2 to BU_P8V_VSX_2 and BU_VSX_OVERLOAD_2 to
28627 BU_P8V_OVERLOAD_2.
28628 * config/rs6000/rs6000-c.c: Change VSX_BUILTIN_VEC_VSIGNED2 to
28629 P8V_BUILTIN_VEC_VSIGNED2. Change VSX_BUILTIN_VEC_VUNSIGNED2 to
28630 P8V_BUILTIN_VEC_VUNSIGNED2.
28631
28632 2018-02-22 Vladimir Makarov <vmakarov@redhat.com>
28633
28634 PR target/81572
28635 * lra-int.h (LRA_UNKNOWN_ALT, LRA_NON_CLOBBERED_ALT): New macros.
28636 * lra.c (lra_set_insn_recog_data, lra_update_insn_recog_data): Use
28637 LRA_UNKNOWN_ALT.
28638 * lra-constraints.c (curr_insn_transform): Set up
28639 LRA_NON_CLOBBERED_ALT for moves processed on the fast path. Use
28640 LRA_UNKNOWN_ALT.
28641 (remove_inheritance_pseudos): Use LRA_UNKNOWN_ALT.
28642 * lra-eliminations.c (spill_pseudos): Ditto.
28643 (process_insn_for_elimination): Ditto.
28644 * lra-lives.c (reg_early_clobber_p): Use the new macros.
28645 * lra-spills.c (spill_pseudos): Use LRA_UNKNOWN_ALT and
28646 LRA_NON_CLOBBERED_ALT.
28647
28648 2018-02-22 Martin Sebor <msebor@redhat.com>
28649
28650 PR tree-optimization/84480
28651 * gimple-fold.c (gimple_fold_builtin_strcpy): Move warnings
28652 to maybe_diag_stxncpy_trunc. Call it.
28653 * tree-ssa-strlen.c (maybe_diag_stxncpy_trunc): Integrate warnings
28654 from gimple_fold_builtin_strcpy. Print inlining stack.
28655 (handle_builtin_stxncpy): Print inlining stack.
28656 * tree-ssa-strlen.h (maybe_diag_stxncpy_trunc): Declare.
28657
28658 2018-02-22 H.J. Lu <hongjiu.lu@intel.com>
28659
28660 PR target/84176
28661 * config/i386/i386.c (ix86_set_indirect_branch_type): Issue an
28662 error when -mindirect-branch=thunk-extern, -fcf-protection=branch
28663 and -fcheck-pointer-bounds are used together.
28664 (indirect_thunk_prefix): New enum.
28665 (indirect_thunk_need_prefix): New function.
28666 (indirect_thunk_name): Replace need_bnd_p with need_prefix. Use
28667 "_nt" instead of "_bnd" for NOTRACK prefix.
28668 (output_indirect_thunk): Replace need_bnd_p with need_prefix.
28669 (output_indirect_thunk_function): Likewise.
28670 (): Likewise.
28671 (ix86_code_end): Update output_indirect_thunk_function calls.
28672 (ix86_output_indirect_branch_via_reg): Replace
28673 ix86_bnd_prefixed_insn_p with indirect_thunk_need_prefix.
28674 (ix86_output_indirect_branch_via_push): Likewise.
28675 (ix86_output_function_return): Likewise.
28676 * doc/invoke.texi: Document -mindirect-branch=thunk-extern is
28677 incompatible with -fcf-protection=branch and
28678 -fcheck-pointer-bounds.
28679
28680 2018-02-22 Steve Ellcey <sellcey@cavium.com>
28681
28682 PR target/83335
28683 * config/aarch64/aarch64.c (aarch64_print_address_internal):
28684 Change gcc_assert call to output_operand_lossage.
28685
28686 2018-02-22 Steve Ellcey <sellcey@cavium.com>
28687
28688 * doc/extend.texi (__builtin_extend_pointer): Document builtin.
28689
28690 2018-02-22 DJ Delorie <dj@redhat.com>
28691 Sebastian Perta <sebastian.perta@renesas.com>
28692 Oleg Endo <olegendo@gcc.gnu.org>
28693
28694 * config/rx/rx.c (rx_rtx_costs): New function.
28695 (TARGET_RTX_COSTS): Override to use rx_rtx_costs.
28696
28697 2018-02-22 Thomas Preud'homme <thomas.preudhomme@arm.com>
28698
28699 * config/arm/t-multilib: Map Armv8-R to Armv7 multilibs.
28700
28701 2018-02-22 Martin Liska <mliska@suse.cz>
28702
28703 PR driver/83193
28704 * common/config/arm/arm-common.c (arm_print_hint_for_cpu_option):
28705 Add "native" as a possible value.
28706
28707 2018-02-22 Martin Liska <mliska@suse.cz>
28708
28709 PR driver/83193
28710 * config/i386/i386.c (ix86_option_override_internal):
28711 Add "native" as a possible value for -march and -mtune.
28712
28713 2018-02-22 Jakub Jelinek <jakub@redhat.com>
28714
28715 PR target/84502
28716 * stor-layout.c (finalize_type_size): Propagate TYPE_EMPTY_P flag
28717 to all type variants.
28718
28719 PR tree-optimization/84503
28720 * gimple-ssa-store-merging.c (merged_store_group::merge_into): Compute
28721 width as info->bitpos + info->bitsize - start.
28722 (merged_store_group::merge_overlapping): Simplify width computation.
28723 (check_no_overlap): New function.
28724 (imm_store_chain_info::try_coalesce_bswap): Compute expected
28725 start + width and last_order of the group, fail if check_no_overlap
28726 fails.
28727 (imm_store_chain_info::coalesce_immediate_stores): Don't merge info
28728 to group if check_no_overlap fails.
28729
28730 2018-02-21 Segher Boessenkool <segher@kernel.crashing.org>
28731
28732 * config/rs6000/altivec.md: Delete contraint arguments to
28733 define_expand, define_split, and define_peephole2, and in
28734 define_insn_and_split if always unused.
28735 * config/rs6000/darwin.md: Ditto.
28736 * config/rs6000/dfp.md: Ditto.
28737 * config/rs6000/rs6000.md: Ditto.
28738 * config/rs6000/sync.md: Ditto.
28739 * config/rs6000/vector.md: Ditto.
28740 * config/rs6000/vsx.md: Ditto.
28741
28742 2018-02-21 Segher Boessenkool <segher@kernel.crashing.org>
28743
28744 * config/rs6000/altivec.md: Write output control strings as braced
28745 blocks instead of double-quoted strings.
28746 * config/rs6000/darwin.md: Ditto.
28747 * config/rs6000/rs6000.md: Ditto.
28748 * config/rs6000/vector.md: Ditto.
28749 * config/rs6000/vsx.md: Ditto.
28750
28751 2018-02-21 Jason Merrill <jason@redhat.com>
28752
28753 PR c++/84314 - ICE with templates and fastcall attribute.
28754 * attribs.c (build_type_attribute_qual_variant): Remove assert.
28755
28756 2018-02-21 Jan Hubicka <hubicka@ucw.cz>
28757
28758 * ipa-cp.c (determine_versionability): Fix comment typos.
28759
28760 2018-02-21 Jan Hubicka <hubicka@ucw.cz>
28761
28762 PR c/84229
28763 * ipa-cp.c (determine_versionability): Do not version functions caling
28764 va_arg_pack.
28765
28766 2018-02-21 Martin Liska <mliska@suse.cz>
28767
28768 PR driver/83193
28769 * config/aarch64/aarch64.c (aarch64_print_hint_for_core_or_arch):
28770 Add "native" as a possible value.
28771 * config/aarch64/aarch64.h (HAVE_LOCAL_CPU_DETECT): Define
28772 the macro when native cpu detection is available.
28773
28774 2018-02-21 Martin Liska <mliska@suse.cz>
28775
28776 PR driver/83193
28777 * common/config/arm/arm-common.c (arm_print_hint_for_arch_option):
28778 Add "native" as a possible value.
28779 * config/arm/arm.h (HAVE_LOCAL_CPU_DETECT): Define the macro
28780 when native cpu detection is available.
28781
28782 2018-02-21 Jakub Jelinek <jakub@redhat.com>
28783 Martin Sebor <msebor@redhat.com>
28784
28785 PR tree-optimization/84478
28786 * gimple-fold.h (get_range_strlen): Add a bool argument defaulted to
28787 false.
28788 * gimple-fold.c (get_range_strlen): Make minlen const and assume it
28789 can't be NULL. Change FUZZY from bool to int, for 1 add PHI/COND_EXPR
28790 support which is conservatively correct, for 2 only stay conservative
28791 for maxlen. Formatting and comment capitalization fixes. Add STRICT
28792 argument to the 2 argument get_range_strlen, adjust 6 arg
28793 get_range_strlen caller and clear minmaxlen[0] and [1] if it returned
28794 false.
28795 (get_maxval_strlen): Adjust 6 arg get_range_strlen caller.
28796 (gimple_fold_builtin_strlen): Pass true as last argument to
28797 get_range_strlen.
28798
28799 2018-02-20 Martin Sebor <msebor@redhat.com>
28800
28801 PR middle-end/84095
28802 * gimple-ssa-warn-restrict.c (builtin_memref::extend_offset_range): New.
28803 (builtin_memref::set_base_and_offset): Same. Handle inner references.
28804 (builtin_memref::builtin_memref): Factor out parts into
28805 set_base_and_offset and call it.
28806
28807 2018-02-20 Richard Sandiford <richard.sandiford@linaro.org>
28808
28809 PR middle-end/84406
28810 * optabs-query.c (find_widening_optab_handler_and_mode): If from_mode
28811 is a scalar_int_mode, assert that to_mode is a scalar_int_mode with
28812 greater precision. If to_mode is a MODE_PARTIAL_INT, stop the
28813 search at the associated MODE_INT.
28814
28815 2018-02-20 Jeff Law <law@redhat.com>
28816
28817 PR middle-end/82123
28818 PR tree-optimization/81592
28819 PR middle-end/79257
28820 * gimple-ssa-sprintf.c (format_integer): Query EVRP range analyzer
28821 for range data rather than using global data.
28822 * gimple-ssa-sprintf.c (get_int_range): Query EVRP range analyzer for
28823 range data rather than using global data.
28824 * gimple-ssa-sprintf.c (get_int_range): Accept vr_values parameter
28825 pass it to children as needed.
28826 (struct directive::fmtresult): Similarly.
28827 (struct directive::set_width): Similarly.
28828 (struct directive::set_precision): Similarly.
28829 (format_integer, format_directive, parse_directive): Similarly.
28830 (format_none): Accept unnamed vr_values parameter.
28831 (format_percent, format_floating, format_character): Similarly.
28832 (format_string, format_plain): Similarly.
28833 * gimple-ssa-sprintf.c (sprintf_dom_walker::handle_gimple_call): Query
28834 the EVRP range analyzer for range data rather than using global data.
28835 * gimple-ssa-sprintf.c: Include alloc-pool.h, vr-values.h and
28836 gimple-ssa-evrp-analyze.h
28837 (class sprintf_dom_walker): Add after_dom_children member function.
28838 Add evrp_range_analyzer member.
28839 (sprintf_dom_walker::before_dom_children): Call into the EVRP
28840 range analyzer as needed.
28841 (sprintf_dom_walker::after_dom_children): New member function.
28842 * gimple-ssa-evrp-analyze.c (evrp_range_analyzer::enter): Do nothing
28843 if not optimizing.
28844 (evrp_range_analyzer::record_ranges_from_stmt): Likewise.
28845 (evrp_range_analyzer::pop_to_marker): Likewise.
28846
28847 2018-02-20 Richard Sandiford <richard.sandiford@linaro.org>
28848
28849 PR tree-optimization/84419
28850 * internal-fn.c (expand_call_mem_ref): Create a TARGET_MEM_REF
28851 with the required type if its current type is compatible but
28852 different.
28853
28854 2018-02-20 Jakub Jelinek <jakub@redhat.com>
28855
28856 PR middle-end/82004
28857 * match.pd (pow(C,x) -> exp(log(C)*x)): Delay all folding until
28858 after vectorization.
28859
28860 2018-02-20 Martin Liska <mliska@suse.cz>
28861
28862 PR driver/83193
28863 * config/aarch64/aarch64.c (aarch64_print_hint_for_core_or_arch): Print
28864 possible values if we don't have a hint.
28865
28866 2018-02-20 Martin Liska <mliska@suse.cz>
28867
28868 PR c/84310
28869 PR target/79747
28870 * final.c (shorten_branches): Build align_tab array with one
28871 more element.
28872 * opts.c (finish_options): Add alignment option limit check.
28873 (MAX_CODE_ALIGN): Likewise.
28874 (MAX_CODE_ALIGN_VALUE): Likewise.
28875 * doc/invoke.texi: Document maximum allowed option value for
28876 all -falign-* options.
28877
28878 2018-02-19 Jakub Jelinek <jakub@redhat.com>
28879
28880 PR target/84146
28881 * reg-notes.def (REG_CALL_ARG_LOCATION): New reg note.
28882 * insn-notes.def (NOTE_INSN_CALL_ARG_LOCATION): Remove.
28883 * var-tracking.c (emit_note_insn_var_location): Remove all references
28884 to NOTE_INSN_CALL_ARG_LOCATION.
28885 (emit_notes_in_bb): Emit arguments as REG_CALL_ARG_LOCATION note on
28886 the CALL_INSN rather than separate NOTE_INSN_CALL_ARG_LOCATION note.
28887 Use copy_rtx_if_shared.
28888 * dwarf2out.c (gen_subprogram_die): Use XEXP with 0 instead of
28889 NOTE_VAR_LOCATION on ca_loc->call_arg_loc_note.
28890 (dwarf2out_var_location): Remove handling of
28891 NOTE_INSN_CALL_ARG_LOCATION, instead handle REG_CALL_ARG_LOCATION note
28892 on call_insn.
28893 * final.c (final_scan_insn): Remove all references to
28894 NOTE_INSN_CALL_ARG_LOCATION.
28895 (rest_of_clean_state): Likewise. Remove REG_CALL_ARG_LOCATION notes
28896 before dumping final insns.
28897 * except.c (emit_note_eh_region_end): Remove all references to
28898 NOTE_INSN_CALL_ARG_LOCATION.
28899 * config/alpha/alpha.c (alpha_pad_function_end): Likewise.
28900 * config/c6x/c6x.c (c6x_gen_bundles): Likewise.
28901 * config/arc/arc.c (hwloop_optimize): Likewise.
28902 * config/arm/arm.c (create_fix_barrier): Likewise.
28903 * config/s390/s390.c (s390_chunkify_start): Likewise.
28904 * config/sh/sh.c (find_barrier): Likewise.
28905 * config/i386/i386.c (rest_of_insert_endbranch,
28906 ix86_seh_fixup_eh_fallthru): Likewise.
28907 * config/xtensa/xtensa.c (hwloop_optimize): Likewise.
28908 * config/iq2000/iq2000.c (final_prescan_insn): Likewise.
28909 * config/frv/frv.c (frv_function_prologue): Likewise.
28910 * emit-rtl.c (try_split): Likewise. Copy over REG_CALL_ARG_LOCATION
28911 reg note.
28912 (note_outside_basic_block_p): Remove all references to
28913 NOTE_INSN_CALL_ARG_LOCATION.
28914 * gengtype.c (adjust_field_rtx_def): Likewise.
28915 * print-rtl.c (rtx_writer::print_rtx_operand_code_0, print_insn):
28916 Likewise.
28917 * jump.c (cleanup_barriers, delete_related_insns): Likewise.
28918 * cfgrtl.c (force_nonfallthru_and_redirect): Likewise.
28919
28920 PR c++/84444
28921 * builtins.c (builtin_mathfn_code): Don't check if CALL_EXPR_FN (t)
28922 is ADDR_EXPR.
28923
28924 PR tree-optimization/84452
28925 * tree-vect-patterns.c (vect_recog_pow_pattern): Don't call
28926 expand_simd_clones if targetm.simd_clone.compute_vecsize_and_simdlen
28927 is NULL.
28928
28929 2018-02-19 Martin Liska <mliska@suse.cz>
28930
28931 PR sanitizer/82183
28932 * passes.def: Put pass_sancov_O0 before pass_lower_switch with -O0.
28933
28934 2018-02-19 Martin Liska <mliska@suse.cz>
28935 Richard Sandiford <richard.sandiford@linaro.org>
28936
28937 PR tree-optimization/82491
28938 * gimple-fold.c (get_base_constructor): Make earlier bail out
28939 to prevent ubsan.
28940
28941 2018-02-19 Carl Love <cel@us.ibm.com>
28942
28943 * config/rs6000/rs6000-builtin.def: Change NEG macro expansions from
28944 BU_ALTIVEC_A to BU_P8V_AV_1 and BU_ALTIVEC_OVERLOAD_1 to
28945 BU_P8V_OVERLOAD_1.
28946 * config/rs6000/rs6000-c.c: Change ALTIVEC_BUILTIN_VEC_NEG to
28947 P8V_BUILTIN_VEC_NEG.
28948
28949 2018-02-19 Sebastian Perta <sebastian.perta@renesas.com>
28950
28951 * config/rl78/rl78.md (movdf): New define expand.
28952
28953 2018-02-19 Martin Liska <mliska@suse.cz>
28954
28955 PR other/80589
28956 * doc/invoke.texi: Fix typo.
28957 * params.def (PARAM_MAX_LOOP_HEADER_INSNS): Likewise.
28958
28959 2018-02-18 Segher Boessenkool <segher@kernel.crashing.org>
28960
28961 * config/rs6000/rs6000.c (rs6000_option_override_internal): Don't
28962 handle rs6000_single_float and rs6000_double_float specially for
28963 e500 family CPUs.
28964
28965 2018-02-16 Jeff Law <law@redhat.com>
28966
28967 * config/rx/rx.c (add_pop_cfi_notes): New function.;
28968 (pop_regs): Use it.
28969
28970 2018-02-16 Jakub Jelinek <jakub@redhat.com>
28971
28972 PR ipa/84425
28973 * ipa-inline.c (inline_small_functions): Fix a typo.
28974
28975 2018-02-16 Nathan Sidwell <nathan@acm.org>
28976
28977 * doc/extend.texi (Backwards Compatibility): Americanize 'behaviour'.
28978
28979 2018-02-16 Carl Love <cel@us.ibm.com>
28980
28981 * config/rs6000/rs6000-builtin.def: Add BU_P8V_VSX_2 macro definition.
28982 Change FLOAT2 expansions from BU_VSX_2 to BU_P8V_VSX_2 and
28983 from BU_VSX_OVERLOAD_2 to BU_P8V_OVERLOAD_2.
28984 * config/rs6000/rs6000-c.c: Changed macro VSX_BUILTIN_VEC_FLOAT2
28985 expansion to P8V_BUILTIN_VEC_FLOAT2.
28986
28987 2018-02-16 Vladimir Makarov <vmakarov@redhat.com>
28988
28989 PR rtl-optimization/70023
28990 * lra-constraints.c (inherit_in_ebb): Take hard reg mode of
28991 src_regno into account.
28992
28993 2018-02-16 Carl Love <cel@us.ibm.com>
28994
28995 * config/rs6000/altivec.h: Remove vec_vextract4b and vec_vinsert4b.
28996 * config/rs6000/rs6000-builtin.def: Remove macro expansion for
28997 VEXTRACT4B, VINSERT4B, VINSERT4B_DI and VEXTRACT4B.
28998 * config/rs6000/rs6000.c: Remove case statements for
28999 P9V_BUILTIN_VEXTRACT4B, P9V_BUILTIN_VEC_VEXTRACT4B,
29000 P9V_BUILTIN_VINSERT4B, P9V_BUILTIN_VINSERT4B_DI,
29001 and P9V_BUILTIN_VEC_VINSERT4B.
29002 * config/rs6000/rs6000-c.c (altivec_expand_builtin): Remove entries for
29003 P9V_BUILTIN_VEC_VEXTRACT4B and P9V_BUILTIN_VEC_VINSERT4B.
29004 * config/rs6000/vsx.md:
29005 * doc/extend.texi: Remove vec_vextract4b, non ABI definitions for
29006 vec_insert4b.
29007
29008 2018-02-16 Carl Love <cel@us.ibm.com>
29009
29010 * config/rs6000/altivec.h: Add builtin names vec_extract4b
29011 vec_insert4b.
29012 * config/rs6000/rs6000-builtin.def: Add INSERT4B and EXTRACT4B
29013 definitions.
29014 * config/rs6000/rs6000-c.c: Add the definitions for
29015 P9V_BUILTIN_VEC_EXTRACT4B and P9V_BUILTIN_VEC_INSERT4B.
29016 * config/rs6000/rs6000.c (altivec_expand_builtin): Add
29017 P9V_BUILTIN_EXTRACT4B and P9V_BUILTIN_INSERT4B case statements.
29018 * config/rs6000/vsx.md: Add define_insn extract4b. Add define_expand
29019 definition for insert4b and define insn *insert3b_internal.
29020 * doc/extend.texi: Add documentation for vec_extract4b.
29021
29022 2018-02-16 Nathan Sidwell <nathan@acm.org>
29023
29024 * doc/extend.texi (Backwards Compatibility): Mention friend
29025 injection. Note for-scope is deprecated.
29026 * doc/invoke.texi (-ffriend-injection): Deprecate.
29027
29028 2018-02-16 Segher Boessenkool <segher@kernel.crashing.org>
29029
29030 * combine.c (try_combine): When adjusting LOG_LINKS for the destination
29031 that moved to I2, also allow destinations that are a paradoxical
29032 subreg (instead of a normal reg).
29033
29034 2018-02-16 Oleg Endo <olegendo@gcc.gnu.org>
29035
29036 PR target/83831
29037 * config/rx/rx.c (rx_fuse_in_memory_bitop): Convert shift operand
29038 to QImode.
29039
29040 2018-02-16 Richard Biener <rguenther@suse.de>
29041
29042 PR tree-optimization/84037
29043 PR tree-optimization/84016
29044 PR target/82862
29045 * config/i386/i386.c (ix86_builtin_vectorization_cost):
29046 Adjust vec_construct for the fact we need additional higher latency
29047 128bit inserts for AVX256 and AVX512 vector builds.
29048 (ix86_add_stmt_cost): Scale vector construction cost for
29049 elementwise loads.
29050
29051 2018-02-16 Richard Biener <rguenther@suse.de>
29052
29053 PR tree-optimization/84417
29054 * tree-ssa.c (non_rewritable_mem_ref_base): Properly constrain
29055 the MEM_REF offset when conversion to BIT_FIELD_REF is desired.
29056 (non_rewritable_lvalue_p): Likewise, use poly-ints.
29057
29058 2018-02-16 Martin Liska <mliska@suse.cz>
29059
29060 PR sanitizer/84307
29061 * internal-fn.def (ASAN_CHECK): Set proper flags.
29062 (ASAN_MARK): Likewise.
29063
29064 2018-02-16 Julia Koval <julia.koval@intel.com>
29065
29066 * config/i386/i386.c (ix86_option_override_internal): Remove PTA_CLWB
29067 from PTA_CANNONLAKE.
29068
29069 2018-02-16 Jakub Jelinek <jakub@redhat.com>
29070
29071 PR target/84272
29072 * config/aarch64/cortex-a57-fma-steering.c (fma_forest::merge_forest):
29073 Use ++iter rather than iter++ for std::list iterators.
29074 (func_fma_steering::dfs): Likewise. Don't delete nodes right away,
29075 defer deleting them until all nodes in the forest are processed. Do
29076 free even leaf nodes. Change to_process into auto_vec.
29077
29078 PR bootstrap/84405
29079 * system.h (BROKEN_VALUE_INITIALIZATION): Define for GCC < 4.3.
29080 * vec.h (vec_default_construct): Use memset instead of placement new
29081 if BROKEN_VALUE_INITIALIZATION is defined.
29082 * hash-table.h (hash_table<Descriptor, Allocator>::empty_slow): Use
29083 memset instead of value initialization if BROKEN_VALUE_INITIALIZATION
29084 is defined.
29085
29086 PR rtl-optimization/83723
29087 * lra-int.h (lra_substitute_pseudo): Add DEBUG_P argument.
29088 * lra.c (lra_substitute_pseudo): Likewise. If true, use
29089 gen_rtx_raw_SUBREG instead of gen_rtx_SUBREG. Pass DEBUG_P to
29090 recursive calls.
29091 (lra_substitute_pseudo_within_insn): Adjust lra_substitute_pseudo
29092 callers.
29093 * lra-constraints.c (inherit_reload_reg, split_reg): Likewise.
29094
29095 2018-02-16 Eric Botcazou <ebotcazou@adacore.com>
29096
29097 PR rtl-optimization/81443
29098 * rtlanal.c (num_sign_bit_copies1) <SUBREG>: Do not propagate results
29099 from inner REGs to paradoxical SUBREGs.
29100
29101 2018-02-16 Richard Biener <rguenther@suse.de>
29102
29103 PR tree-optimization/84399
29104 * graphite-scop-detection.c (scop_detection::stmt_simple_for_scop_p):
29105 For operands we can analyze at their definition make sure we can
29106 analyze them at each use as well.
29107
29108 2018-02-16 Richard Biener <rguenther@suse.de>
29109
29110 PR tree-optimization/84190
29111 * tree-ssa.c (non_rewritable_mem_ref_base): Do not touch
29112 volatile accesses if the decl isn't volatile.
29113
29114 2018-02-15 Jason Merrill <jason@redhat.com>
29115
29116 PR c++/84314 - ICE with templates and fastcall attribute.
29117 * attribs.c (build_type_attribute_qual_variant): Don't clobber
29118 TYPE_CANONICAL on an existing type.
29119
29120 2018-02-15 Jakub Jelinek <jakub@redhat.com>
29121
29122 PR tree-optimization/84383
29123 * tree-ssa-strlen.c (maybe_diag_stxncpy_trunc): Don't look at
29124 dstoff nor call operand_equal_p if dstbase is NULL.
29125
29126 PR tree-optimization/84334
29127 * match.pd ((A +- CST1) +- CST2 -> A + CST3): If A is
29128 also a CONSTANT_CLASS_P, punt.
29129
29130 2018-02-14 Jim Wilson <jimw@sifive.com>
29131
29132 * config/riscv/riscv.c (riscv_first_stack_step): Move locals after
29133 first SMALL_OPERAND check. New local min_second_step. Move assert
29134 to where locals are set. Add TARGET_RVC support.
29135 * config/riscv/riscv.h (C_SxSP_BITS, SWSP_REACH, SDSP_REACH): New.
29136
29137 2018-02-14 Indu Bhagat <indu.bhagat@oracle.com>
29138
29139 * doc/invoke.texi: Correct -Wformat-overflow code sample.
29140
29141 2018-02-14 Martin Sebor <msebor@redhat.com>
29142
29143 PR tree-optimization/83698
29144 * gimple-ssa-warn-restrict.c (builtin_memref::builtin_memref): For
29145 arrays constrain the offset range to their bounds.
29146 (builtin_access::strcat_overlap): Adjust the bounds of overlap offset.
29147 (builtin_access::overlap): Avoid setting the size of overlap if it's
29148 already been set.
29149 (maybe_diag_overlap): Also consider arrays when deciding what values
29150 of offsets to include in diagnostics.
29151
29152 2018-02-14 Martin Sebor <msebor@redhat.com>
29153
29154 PR c/84108
29155 * attribs.c (diag_attr_exclusions): Consider the exclusion(s)
29156 that correspond to the kind of a declaration.
29157
29158 2018-02-14 John David Anglin <danglin@gcc.gnu.org>
29159
29160 PR target/83984
29161 * config/pa/pa.md: Load address of PIC label using the linkage table
29162 if the label is nonlocal.
29163
29164 2018-02-14 Kelvin Nilsen <kelvin@gcc.gnu.org>
29165
29166 * config/rs6000/rs6000.c (rs6000_option_override_internal): Issue
29167 warning message if user requests -maltivec=be.
29168 * doc/invoke.texi: Document deprecation of -maltivec=be.
29169
29170 2018-02-14 Will Schmidt <will_schmidt@vnet.ibm.com>
29171
29172 PR target/84220
29173 * config/rs6000/rs6000-c.c: Update definitions for
29174 ALTIVEC_BUILTIN_VEC_SLD, ALTIVEC_BUILTIN_VEC_SLDW,
29175 VEC_XXSLDWI and ALTIVEC_BUILTIN_VEC_XXPERMDI builtins.
29176
29177 2018-02-14 Igor Tsimbalist <igor.v.tsimbalist@intel.com>
29178
29179 PR target/84239
29180 * config/i386/cetintrin.h: Remove _rdssp[d|q] and
29181 add _get_ssp intrinsics. Remove argument from
29182 __builtin_ia32_rdssp[d|q].
29183 * config/i386/i386-builtin-types.def: Add UINT_FTYPE_VOID.
29184 * config/i386/i386-builtin.def: Remove argument from
29185 __builtin_ia32_rdssp[d|q].
29186 * config/i386/i386.c: Use UINT_FTYPE_VOID. Use
29187 ix86_expand_special_args_builtin for _rdssp[d|q].
29188 * config/i386/i386.md: Remove argument from rdssp[si|di] insn.
29189 Clear register before usage.
29190 * doc/extend.texi: Remove argument from __builtin_ia32_rdssp[d|q].
29191 Add documentation for new _get_ssp and _inc_ssp intrinsics.
29192
29193 2018-02-14 Richard Sandiford <richard.sandiford@linaro.org>
29194
29195 PR tree-optimization/84357
29196 * tree-data-ref.c (object_address_invariant_in_loop_p): Check
29197 operand 1 of an ARRAY_REF too.
29198
29199 2018-02-14 Oleg Endo <olegendo@gcc.gnu.org>
29200
29201 PR target/83831
29202 * config/rx/rx-protos.h (rx_reg_dead_or_unused_after_insn,
29203 rx_copy_reg_dead_or_unused_notes, rx_fuse_in_memory_bitop): New
29204 declarations.
29205 (set_of_reg): New struct.
29206 (rx_find_set_of_reg, rx_find_use_of_reg): New functions.
29207 * config/rx/rx.c (rx_reg_dead_or_unused_after_insn,
29208 rx_copy_reg_dead_or_unused_notes, rx_fuse_in_memory_bitop): New
29209 functions.
29210 * config/rx/rx.md (andsi3, iorsi3, xorsi3): Convert to insn_and_split.
29211 Split into bitclr, bitset, bitinvert patterns if appropriate.
29212 (*bitset, *bitinvert, *bitclr): Convert to named insn_and_split and
29213 use rx_fuse_in_memory_bitop.
29214 (*bitset_in_memory, *bitinvert_in_memory, *bitclr_in_memory): Convert
29215 to named insn, correct maximum insn length.
29216
29217 2018-02-14 Jozef Lawrynowicz <jozefl.gcc@gmail.com>
29218
29219 PR target/79242
29220 * machmode.def: Define a complex mode for PARTIAL_INT.
29221 * genmodes.c (complex_class): Return MODE_COMPLEX_INT for
29222 MODE_PARTIAL_INT.
29223 * doc/rtl.texi: Document CSPImode.
29224 * config/msp430/msp430.c (msp430_hard_regno_nregs): Add CPSImode
29225 handling.
29226 (msp430_hard_regno_nregs_with_padding): Likewise.
29227
29228 2018-02-13 Peter Bergner <bergner@vnet.ibm.com>
29229
29230 PR target/84279
29231 * config/rs6000/rs6000.c (mem_operand_gpr): Disallow altivec addresses.
29232
29233 2018-02-13 Segher Boessenkool <segher@kernel.crashing.org>
29234
29235 PR rtl-optimization/84169
29236 * combine.c (try_combine): New variable split_i2i3. Set it to true if
29237 we generated a parallel as new i3 and we split that to new i2 and i3
29238 instructions. Handle split_i2i3 similar to swap_i2i3: scan the
29239 LOG_LINKs of i3 to see which of those need to link to i2 now. Link
29240 those to i2, not i1. Partially rewrite this scan code.
29241
29242 2018-02-13 Jakub Jelinek <jakub@redhat.com>
29243
29244 PR c/82210
29245 * stor-layout.c (place_field): For variable length fields, adjust
29246 offset_align afterwards not just based on the field's alignment,
29247 but also on the size.
29248
29249 PR middle-end/84309
29250 * match.pd (pow(C,x) -> exp(log(C)*x)): Use exp2s and log2s instead
29251 of exps and logs in the use_exp2 case.
29252
29253 2018-02-13 Jeff Law <law@redhat.com>
29254
29255 * config/rl/rl78.c (rl78_attribute_table): Fix terminator and
29256 entry for "vector".
29257
29258 * config/rl78/rl78.c (rl78_handle_func_attribute): Mark
29259 ARGS as unused.
29260
29261 2018-02-13 Alexandre Oliva <aoliva@redhat.com>
29262
29263 PR debug/84342
29264 PR debug/84319
29265 * common.opt (gas-loc-support, gas-locview-support): New.
29266 (ginline-points, ginternal-reset-location-views): New.
29267 * doc/invoke.texi: Document them. Use @itemx where intended.
29268 (gvariable-location-views): Adjust.
29269 * target.def (reset_location_view): New.
29270 * doc/tm.texi.in (DWARF2_ASM_VIEW_DEBUG_INFO): New.
29271 (TARGET_RESET_LOCATION_VIEW): New.
29272 * doc/tm.texi: Rebuilt.
29273 * dwarf2out.c (dwarf2out_default_as_loc_support): New.
29274 (dwarf2out_default_as_locview_support): New.
29275 (output_asm_line_debug_info): Use option variables.
29276 (dwarf2out_maybe_output_loclist_view_pair): Likewise.
29277 (output_loc_list): Likewise.
29278 (add_high_low_attributes): Check option variables.
29279 Don't output entry view attribute in strict mode.
29280 (gen_inlined_subroutine_die): Check option variables.
29281 (dwarf2out_inline_entry): Likewise.
29282 (init_sections_and_labels): Likewise.
29283 (dwarf2out_early_finish): Likewise.
29284 (maybe_reset_location_view): New, from...
29285 (dwarf2out_var_location): ... here. Call it.
29286 * debug.h (dwarf2out_default_as_loc_support): Declare.
29287 (dwarf2out_default_as_locview_support): Declare.
29288 * hooks.c (hook_int_rtx_insn_0): New.
29289 * hooks.h (hook_int_rtx_insn_0): Declare.
29290 * toplev.c (process_options): Take -gas-loc-support and
29291 -gas-locview-support from dwarf2out. Enable
29292 -gvariable-location-views by default only with locview
29293 assembler support. Enable -ginternal-reset-location-views by
29294 default only if the target defines the corresponding hook.
29295 Enable -ginline-points by default if location views are
29296 enabled; force it disabled if statement frontiers are
29297 disabled.
29298 * tree-inline.c (expand_call_inline): Check option variables.
29299 * tree-ssa-live.c (remove_unused_scope_block_p): Likewise.
29300
29301 2018-02-13 Richard Sandiford <richard.sandiford@linaro.org>
29302
29303 PR tree-optimization/84321
29304 * tree-vrp.c (intersect_range_with_nonzero_bits): Fix VR_ANTI_RANGE
29305 handling. Also check whether the anti-range contains any values
29306 that satisfy the mask; switch to a VR_RANGE if not.
29307
29308 2018-02-13 Paolo Bonzini <bonzini@gnu.org>
29309
29310 PR sanitizer/84340
29311 * internal-fn.def (ASAN_CHECK, ASAN_MARK): Revert changes to fnspec.
29312
29313 2018-02-13 Martin Jambor <mjambor@suse.cz>
29314
29315 PR c++/83990
29316 * ipa-param-manipulation.c (ipa_modify_call_arguments): Use location
29317 of call statements, also set location of a load to a temporary.
29318
29319 2018-02-13 Sebastian Perta <sebastian.perta@renesas.com>
29320
29321 * config/rl78/rl78.c (add_vector_labels): New function.
29322 * config/rl78/rl78.c (rl78_handle_vector_attribute): New function.
29323 * config/rl78/rl78.c (rl78_start_function): Call add_vector_labels.
29324 * config/rl78/rl78.c (rl78_handle_func_attribute): Removed the assert
29325 which checks that no arguments are passed.
29326 * config/rl78/rl78.c (rl78_attribute_table): Add "vector" attribute.
29327 * doc/extend.texi: Documentation for the new attribute.
29328
29329 2018-02-13 Andreas Schwab <schwab@suse.de>
29330
29331 * config/riscv/linux.h (CPP_SPEC): Define.
29332
29333 2018-02-13 Jakub Jelinek <jakub@redhat.com>
29334
29335 PR target/84335
29336 * config/i386/i386.c (ix86_init_mmx_sse_builtins): Pass
29337 OPTION_MASK_ISA_AES | OPTION_MASK_ISA_SSE2 instead of
29338 OPTION_MASK_ISA_AES as first argument to def_builtin_const
29339 for AES builtins. Pass OPTION_MASK_ISA_PCLMUL | OPTION_MASK_ISA_SSE2
29340 instead of OPTION_MASK_ISA_PCLMUL as first argument to
29341 def_builtin_const for __builtin_ia32_pclmulqdq128 builtin.
29342 * config/i386/wmmintrin.h: If __SSE2__ is not defined, enable it
29343 temporarily for AES and PCLMUL builtins.
29344
29345 PR tree-optimization/84339
29346 * gimple-fold.c (get_range_strlen): Set *FLEXP to true when handling
29347 ARRAY_REF where first operand is array_at_struct_end_p COMPONENT_REF.
29348 Formatting fixes.
29349
29350 PR middle-end/84309
29351 * match.pd (pow(C,x) -> exp(log(C)*x)): Optimize instead into
29352 exp2(log2(C)*x) if C is a power of 2 and c99 runtime is available.
29353 * generic-match-head.c (canonicalize_math_after_vectorization_p): New
29354 inline function.
29355 * gimple-match-head.c (canonicalize_math_after_vectorization_p): New
29356 inline function.
29357 * omp-simd-clone.h: New file.
29358 * omp-simd-clone.c: Include omp-simd-clone.h.
29359 (expand_simd_clones): No longer static.
29360 * tree-vect-patterns.c: Include fold-const-call.h, attribs.h,
29361 cgraph.h and omp-simd-clone.h.
29362 (vect_recog_pow_pattern): Optimize pow(C,x) to exp(log(C)*x).
29363 (vect_recog_widen_shift_pattern): Formatting fix.
29364 (vect_pattern_recog_1): Don't check optab for calls.
29365
29366 PR target/84336
29367 * config/i386/sse.md (<avx512>_vpermi2var<mode>3_mask): Force
29368 operands[2] into a REG before using gen_lowpart on it.
29369
29370 2018-02-12 Jeff Law <law@redhat.com>
29371
29372 PR target/83760
29373 * config/sh/sh.c (find_barrier): Consider a sibling call
29374 a barrier as well.
29375
29376 * cse.c (try_back_substitute_reg): Move any REG_ARGS_SIZE note when
29377 successfully back substituting a reg.
29378
29379 2018-02-12 Richard Biener <rguenther@suse.de>
29380
29381 PR tree-optimization/84037
29382 * tree-vect-slp.c (vect_analyze_slp_cost): Add visited
29383 parameter, move visited init to caller.
29384 (vect_slp_analyze_operations): Separate cost from validity
29385 check, initialize visited once for all instances.
29386 (vect_schedule_slp): Analyze map to CSE vectorized nodes once
29387 for all instances.
29388 * tree-vect-stmts.c (vect_model_simple_cost): Make early
29389 out an assert.
29390 (vect_model_promotion_demotion_cost): Likewise.
29391 (vectorizable_bswap): Guard cost modeling with !slp_node
29392 instead of !PURE_SLP_STMT to avoid double-counting on hybrid
29393 SLP stmts.
29394 (vectorizable_call): Likewise.
29395 (vectorizable_conversion): Likewise.
29396 (vectorizable_assignment): Likewise.
29397 (vectorizable_shift): Likewise.
29398 (vectorizable_operation): Likewise.
29399 (vectorizable_store): Likewise.
29400 (vectorizable_load): Likewise.
29401 (vectorizable_condition): Likewise.
29402 (vectorizable_comparison): Likewise.
29403
29404 2018-02-12 Paolo Bonzini <bonzini@gnu.org>
29405
29406 PR sanitizer/84307
29407 * internal-fn.def (ASAN_CHECK): Fix fnspec to account for return value.
29408 (ASAN_MARK): Fix fnspec to account for return value, change pointer
29409 argument from 'R' to 'W' so that the pointed-to datum is clobbered.
29410
29411 2018-02-08 Jan Hubicka <hubicka@ucw.cz>
29412
29413 PR middle-end/83665
29414 * params.def (inline-min-speedup): Increase from 8 to 15.
29415 (max-inline-insns-auto): Decrease from 40 to 30.
29416 * ipa-split.c (consider_split): Add some buffer for function to
29417 be considered inlining candidate.
29418 * invoke.texi (max-inline-insns-auto, inline-min-speedup): UPdate
29419 default values.
29420
29421 2018-02-12 Richard Biener <rguenther@suse.de>
29422
29423 PR tree-optimization/84037
29424 * tree-vect-slp.c (vect_build_slp_tree_2): Try swapping the
29425 matched stmts if we cannot swap the non-matched ones.
29426
29427 2018-02-12 Olga Makhotina <olga.makhotina@intel.com>
29428
29429 * config/i386/avx512fintrin.h (_mm_mask_scalef_round_sd,
29430 _mm_maskz_scalef_round_sd, _mm_mask_scalef_round_ss,
29431 _mm_maskz_scalef_round_ss): New intrinsics.
29432 (__builtin_ia32_scalefsd_round, __builtin_ia32_scalefss_round): Fix.
29433 * config/i386/i386-builtin.def (__builtin_ia32_scalefsd_round,
29434 __builtin_ia32_scalefss_round): Remove.
29435 (__builtin_ia32_scalefsd_mask_round,
29436 __builtin_ia32_scalefss_mask_round): New intrinsics.
29437 * config/i386/sse.md (vmscalef<mode><round_name>): Renamed to ...
29438 (vmscalef<mode><mask_scalar_name><round_scalar_name>): ... this.
29439 ((match_operand:VF_128 2 "<round_nimm_predicate>"
29440 "<round_constraint>")): Changed to ...
29441 ((match_operand:VF_128 2 "<round_scalar_nimm_predicate>"
29442 "<round_scalar_constraint>")): ... this.
29443 ("vscalef<ssescalarmodesuffix>\t{<round_op3>%2, %1, %0|
29444 %0, %1, %2<round_op3>}"): Changed to ...
29445 ("vscalef<ssescalarmodesuffix>\t{<round_scalar_mask_op3>%2, %1,
29446 %0<mask_scalar_operand3>|%0<mask_scalar_operand3>, %1,
29447 %2<round_scalar_mask_op3>}"): ... this.
29448 * config/i386/subst.md (round_scalar_nimm_predicate): New.
29449
29450 2018-02-12 Olga Makhotina <olga.makhotina@intel.com>
29451
29452 * config/i386/avx512fintrin.h (_mm_mask_sqrt_round_sd)
29453 (_mm_maskz_sqrt_round_sd, _mm_mask_sqrt_round_ss)
29454 (_mm_maskz_sqrt_round_ss): New intrinsics.
29455 (__builtin_ia32_sqrtsd_round, __builtin_ia32_sqrtss_round): Remove.
29456 (__builtin_ia32_sqrtsd_mask_round)
29457 (__builtin_ia32_sqrtss_mask_round): New builtins.
29458 * config/i386/i386-builtin.def (__builtin_ia32_sqrtsd_round)
29459 (__builtin_ia32_sqrtss_round): Remove.
29460 (__builtin_ia32_sqrtsd_mask_round)
29461 (__builtin_ia32_sqrtss_mask_round): New builtins.
29462 * config/i386/sse.md (vmsqrt<mode>2<round_name>): Renamed to ...
29463 (vmsqrt<mode>2<mask_scalar_name><round_scalar_name>): ... this.
29464 ((match_operand:VF_128 1 "vector_operand"
29465 "xBm,<round_constraint>")): Changed to ...
29466 ((match_operand:VF_128 1 "vector_operand"
29467 "xBm,<round_scalar_constraint>")): ... this.
29468 (vsqrt<ssescalarmodesuffix>\t{<round_op3>%1, %2, %0|
29469 %0, %2, %<iptr>1<round_op3>}): Changed to ...
29470 (vsqrt<ssescalarmodesuffix>\t{<round_scalar_mask_op3>%1, %2,
29471 %0<mask_scalar_operand3>|%0<mask_scalar_operand3>, %2,
29472 %<iptr>1<round_scalar_mask_op3>}): ... this.
29473 ((set_attr "prefix" "<round_prefix>")): Changed to ...
29474 ((set_attr "prefix" "<round_scalar_prefix>")): ... this.
29475
29476 2018-02-11 Steven Munroe <munroesj@gcc.gnu.org>
29477
29478 PR target/84266
29479 * config/rs6000/mmintrin.h (_mm_cmpeq_pi32 [_ARCH_PWR9]):
29480 Cast vec_cmpeq result to correct type.
29481 * config/rs6000/mmintrin.h (_mm_cmpgt_pi32 [_ARCH_PWR9]):
29482 Cast vec_cmpgt result to correct type.
29483
29484 2018-02-11 Alexandre Oliva <aoliva@redhat.com>
29485
29486 * final.c (final_scan_insn_1): Renamed from...
29487 (final_scan_insn): ... this. New wrapper, to recover
29488 seen from the outermost call in recursive ones.
29489 * config/sparc/sparc.c (output_return): Drop seen from call.
29490 (output_sibcall): Likewise.
29491 * config/visium/visium.c (output_branch): Likewise.
29492
29493 2018-02-10 John David Anglin <danglin@gcc.gnu.org>
29494
29495 * config/pa/pa.c (hppa_profile_hook): Mark SYMBOL_REF for _mcount as
29496 function label.
29497
29498 2018-02-10 Alan Modra <amodra@gmail.com>
29499
29500 PR target/84300
29501 * config/rs6000/rs6000.md (split_stack_return): Remove (use ..).
29502 Specify LR as an input.
29503
29504 2018-02-10 Jakub Jelinek <jakub@redhat.com>
29505
29506 PR sanitizer/83987
29507 * omp-low.c (maybe_remove_omp_member_access_dummy_vars,
29508 remove_member_access_dummy_vars): New functions.
29509 (lower_omp_for, lower_omp_taskreg, lower_omp_target,
29510 lower_omp_1, execute_lower_omp): Use them.
29511
29512 PR rtl-optimization/84308
29513 * shrink-wrap.c (spread_components): Release todo vector.
29514
29515 2018-02-09 Vladimir Makarov <vmakarov@redhat.com>
29516
29517 PR rtl-optimization/57193
29518 * ira-color.c (struct allocno_color_data): Add member
29519 conflict_allocno_hard_prefs.
29520 (update_conflict_allocno_hard_prefs): New.
29521 (bucket_allocno_compare_func): Add a preference based on
29522 conflict_allocno_hard_prefs.
29523 (push_allocno_to_stack): Update conflict_allocno_hard_prefs.
29524 (color_allocnos): Remove a dead code. Initiate
29525 conflict_allocno_hard_prefs. Call update_costs_from_prefs.
29526
29527 2018-02-09 Jakub Jelinek <jakub@redhat.com>
29528
29529 PR target/84226
29530 * config/rs6000/vsx.md (p9_xxbrq_v16qi): Change input operand
29531 constraint from =wa to wa. Avoid a subreg on the output operand,
29532 instead use a pseudo and subreg it in a move.
29533 (p9_xxbrd_<mode>): Changed to ...
29534 (p9_xxbrd_v2di): ... this insn, without VSX_D iterator.
29535 (p9_xxbrd_v2df): New expander.
29536 (p9_xxbrw_<mode>): Changed to ...
29537 (p9_xxbrw_v4si): ... this insn, without VSX_W iterator.
29538 (p9_xxbrw_v4sf): New expander.
29539
29540 2018-02-09 Sebastian Perta <sebastian.perta@renesas.com>
29541
29542 * config/rx/rx.md (movsicc): Update expander to be matched by GCC.
29543
29544 2018-02-09 Peter Bergner <bergner@vnet.ibm.com>
29545
29546 PR target/83926
29547 * config/rs6000/vsx.md (vsx_mul_v2di): Handle generating a 64-bit
29548 multiply in 32-bit mode.
29549 (vsx_div_v2di): Handle generating a 64-bit signed divide in 32-bit mode.
29550 (vsx_udiv_v2di): Handle generating a 64-bit unsigned divide in 32-bit
29551 mode.
29552
29553 2018-02-09 Sebastian Perta <sebastian.perta@renesas.com>
29554
29555 * config/rx/constraints.md (CALL_OP_SYMBOL_REF): Added new constraint
29556 to allow or block "symbol_ref" depending on the value of TARGET_JSR.
29557 * config/rx/rx.md (call_internal): Use CALL_OP_SYMBOL_REF.
29558 * config/rx/rx.md (call_value_internal): Use CALL_OP_SYMBOL_REF.
29559
29560 2018-02-09 Pierre-Marie de Rodat <derodat@adacore.com>
29561
29562 PR lto/84213
29563 * dwarf2out.c (is_trivial_indirect_ref): New function.
29564 (dwarf2out_late_global_decl): Do not generate a location
29565 attribute for variables that have a non-trivial DECL_VALUE_EXPR
29566 and that are not defined in the current unit.
29567
29568 2018-02-09 Eric Botcazou <ebotcazou@adacore.com>
29569
29570 * optabs.c (prepare_cmp_insn): Try harder to emit a direct comparison
29571 instead of a libcall for UNORDERED.
29572
29573 2018-02-09 Tamar Christina <tamar.christina@arm.com>
29574
29575 PR target/82641
29576 * config/arm/arm-c.c (arm_cpu_builtins): Un-define __ARM_FEATURE_LDREX,
29577 __ARM_ARCH_PROFILE, __ARM_ARCH_ISA_THUMB, __ARM_FP and __ARM_NEON_FP.
29578
29579 2018-02-09 Andreas Krebbel <krebbel@linux.vnet.ibm.com>
29580
29581 PR target/PR84295
29582 * config/s390/s390.c (s390_set_current_function): Invoke
29583 s390_indirect_branch_settings also if fndecl didn't change.
29584
29585 2018-02-09 Alexandre Oliva <aoliva@redhat.com>
29586
29587 * config/rs6000/rs6000.md (blockage): Set length to zero.
29588
29589 2018-02-09 Eric Botcazou <ebotcazou@adacore.com>
29590
29591 * expr.c (optimize_bitfield_assignment_op): Remove obsolete assertion.
29592
29593 2018-02-09 Jakub Jelinek <jakub@redhat.com>
29594
29595 PR sanitizer/84285
29596 * gcc.c (STATIC_LIBASAN_LIBS, STATIC_LIBTSAN_LIBS,
29597 STATIC_LIBLSAN_LIBS, STATIC_LIBUBSAN_LIBS): Handle -static like
29598 -static-lib*san.
29599
29600 PR debug/84252
29601 * var-tracking.c (vt_add_function_parameter): Punt for non-onepart
29602 PARALLEL incoming that failed vt_get_decl_and_offset check.
29603
29604 PR middle-end/84237
29605 * output.h (bss_initializer_p): Add NAMED argument, defaulted to false.
29606 * varasm.c (bss_initializer_p): Add NAMED argument, if true, ignore
29607 TREE_READONLY bit.
29608 (get_variable_section): For decls in named .bss* sections pass true as
29609 second argument to bss_initializer_p.
29610
29611 2018-02-09 Marek Polacek <polacek@redhat.com>
29612 Jakub Jelinek <jakub@redhat.com>
29613
29614 PR c++/83659
29615 * fold-const.c (fold_indirect_ref_1): Use VECTOR_TYPE_P macro.
29616 Formatting fixes. Verify first that tree_fits_poly_int64_p (op01).
29617 Sync some changes from cxx_fold_indirect_ref.
29618
29619 2018-02-09 Alexandre Oliva <aoliva@redhat.com>
29620
29621 * cfgexpand.c (expand_gimple_basic_block): Handle inline entry
29622 markers.
29623 * dwarf2out.c (dwarf2_debug_hooks): Enable inline_entry hook.
29624 (BLOCK_INLINE_ENTRY_LABEL): New.
29625 (dwarf2out_var_location): Disregard inline entry markers.
29626 (inline_entry_data): New struct.
29627 (inline_entry_data_hasher): New hashtable type.
29628 (inline_entry_data_hasher::hash): New.
29629 (inline_entry_data_hasher::equal): New.
29630 (inline_entry_data_table): New variable.
29631 (add_high_low_attributes): Add DW_AT_entry_pc and
29632 DW_AT_GNU_entry_view attributes if a pending entry is found
29633 in inline_entry_data_table. Add old entry_pc attribute only
29634 if debug nonbinding markers are disabled.
29635 (gen_inlined_subroutine_die): Set BLOCK_DIE if nonbinding
29636 markers are enabled.
29637 (block_within_block_p, dwarf2out_inline_entry): New.
29638 (dwarf2out_finish): Check that no entries remained in
29639 inline_entry_data_table.
29640 * final.c (reemit_insn_block_notes): Handle inline entry notes.
29641 (final_scan_insn, notice_source_line): Likewise.
29642 (rest_of_clean_state): Skip inline entry markers.
29643 * gimple-pretty-print.c (dump_gimple_debug): Handle inline entry
29644 markers.
29645 * gimple.c (gimple_build_debug_inline_entry): New.
29646 * gimple.h (enum gimple_debug_subcode): Add
29647 GIMPLE_DEBUG_INLINE_ENTRY.
29648 (gimple_build_debug_inline_entry): Declare.
29649 (gimple_debug_inline_entry_p): New.
29650 (gimple_debug_nonbind_marker_p): Adjust.
29651 * insn-notes.def (INLINE_ENTRY): New.
29652 * print-rtl.c (rtx_writer::print_rtx_operand_code_0): Handle
29653 inline entry marker notes.
29654 (print_insn): Likewise.
29655 * rtl.h (NOTE_MARKER_P): Add INLINE_ENTRY support.
29656 (INSN_DEBUG_MARKER_KIND): Likewise.
29657 (GEN_RTX_DEBUG_MARKER_INLINE_ENTRY_PAT): New.
29658 * tree-inline.c (expand_call_inline): Build and insert
29659 debug_inline_entry stmt.
29660 * tree-ssa-live.c (remove_unused_scope_block_p): Preserve
29661 inline entry blocks early, if nonbind markers are enabled.
29662 (dump_scope_block): Dump fragment info.
29663 * var-tracking.c (reemit_marker_as_note): Handle inline entry note.
29664 * doc/gimple.texi (gimple_debug_inline_entry_p): New.
29665 (gimple_build_debug_inline_entry): New.
29666 * doc/invoke.texi (gstatement-frontiers, gno-statement-frontiers):
29667 Enable/disable inline entry points too.
29668 * doc/rtl.texi (NOTE_INSN_INLINE_ENTRY): New.
29669 (DEBUG_INSN): Describe inline entry markers.
29670
29671 * common.opt (gvariable-location-views): New.
29672 (gvariable-location-views=incompat5): New.
29673 * config.in: Rebuilt.
29674 * configure: Rebuilt.
29675 * configure.ac: Test assembler for view support.
29676 * dwarf2asm.c (dw2_asm_output_symname_uleb128): New.
29677 * dwarf2asm.h (dw2_asm_output_symname_uleb128): Declare.
29678 * dwarf2out.c (var_loc_view): New typedef.
29679 (struct dw_loc_list_struct): Add vl_symbol, vbegin, vend.
29680 (dwarf2out_locviews_in_attribute): New.
29681 (dwarf2out_locviews_in_loclist): New.
29682 (dw_val_equal_p): Compare val_view_list of dw_val_class_view_lists.
29683 (enum dw_line_info_opcode): Add LI_adv_address.
29684 (struct dw_line_info_table): Add view.
29685 (RESET_NEXT_VIEW, RESETTING_VIEW_P): New macros.
29686 (DWARF2_ASM_VIEW_DEBUG_INFO): Define default.
29687 (zero_view_p): New variable.
29688 (ZERO_VIEW_P): New macro.
29689 (output_asm_line_debug_info): New.
29690 (struct var_loc_node): Add view.
29691 (add_AT_view_list, AT_loc_list): New.
29692 (add_var_loc_to_decl): Add view param. Test it against last.
29693 (new_loc_list): Add view params. Record them.
29694 (AT_loc_list_ptr): Handle loc and view lists.
29695 (view_list_to_loc_list_val_node): New.
29696 (print_dw_val): Handle dw_val_class_view_list.
29697 (size_of_die): Likewise.
29698 (value_format): Likewise.
29699 (loc_list_has_views): New.
29700 (gen_llsym): Set vl_symbol too.
29701 (maybe_gen_llsym, skip_loc_list_entry): New.
29702 (dwarf2out_maybe_output_loclist_view_pair): New.
29703 (output_loc_list): Output view list or entries too.
29704 (output_view_list_offset): New.
29705 (output_die): Handle dw_val_class_view_list.
29706 (output_dwarf_version): New.
29707 (output_compilation_unit_header): Use it.
29708 (output_skeleton_debug_sections): Likewise.
29709 (output_rnglists, output_line_info): Likewise.
29710 (output_pubnames, output_aranges): Update version comments.
29711 (output_one_line_info_table): Output view numbers in asm comments.
29712 (dw_loc_list): Determine current endview, pass it to new_loc_list.
29713 Call maybe_gen_llsym.
29714 (loc_list_from_tree_1): Adjust.
29715 (add_AT_location_description): Create view list attribute if
29716 needed, check it's absent otherwise.
29717 (convert_cfa_to_fb_loc_list): Adjust.
29718 (maybe_emit_file): Call output_asm_line_debug_info for test.
29719 (dwarf2out_var_location): Reset views as needed. Precompute
29720 add_var_loc_to_decl args. Call get_attr_min_length only if we have the
29721 attribute. Set view.
29722 (new_line_info_table): Reset next view.
29723 (set_cur_line_info_table): Call output_asm_line_debug_info for test.
29724 (dwarf2out_source_line): Likewise. Output view resets and labels to
29725 the assembler, or select appropriate line info opcodes.
29726 (prune_unused_types_walk_attribs): Handle dw_val_class_view_list.
29727 (optimize_string_length): Catch it. Adjust.
29728 (resolve_addr): Copy vl_symbol along with ll_symbol. Handle
29729 dw_val_class_view_list, and remove it if no longer needed.
29730 (hash_loc_list): Hash view numbers.
29731 (loc_list_hasher::equal): Compare them.
29732 (optimize_location_lists): Check whether a view list symbol is
29733 needed, and whether the locview attribute is present, and
29734 whether they match. Remove the locview attribute if no longer
29735 needed.
29736 (index_location_lists): Call skip_loc_list_entry for test.
29737 (dwarf2out_finish): Call output_asm_line_debug_info for test.
29738 Use output_dwarf_version.
29739 * dwarf2out.h (enum dw_val_class): Add dw_val_class_view_list.
29740 (struct dw_val_node): Add val_view_list.
29741 * final.c (SEEN_NEXT_VIEW): New.
29742 (set_next_view_needed): New.
29743 (clear_next_view_needed): New.
29744 (maybe_output_next_view): New.
29745 (final_start_function): Rename to...
29746 (final_start_function_1): ... this. Take pointer to FIRST,
29747 add SEEN parameter. Emit param bindings in the initial view.
29748 (final_start_function): Reintroduce SEEN-less interface.
29749 (final): Rename to...
29750 (final_1): ... this. Take SEEN parameter. Output final pending
29751 next view at the end.
29752 (final): Reintroduce seen-less interface.
29753 (final_scan_insn): Output pending next view before switching
29754 sections or ending a block. Mark the next view as needed when
29755 outputting variable locations. Notify debug backend of section
29756 changes, and of location view changes.
29757 (rest_of_handle_final): Adjust.
29758 * toplev.c (process_options): Autodetect value for debug variable
29759 location views option. Warn on incompat5 without -gdwarf-5.
29760 * doc/invoke.texi (gvariable-location-views): New.
29761 (gvariable-location-views=incompat5): New.
29762 (gno-variable-location-views): New.
29763
29764 2018-02-08 David Malcolm <dmalcolm@redhat.com>
29765
29766 PR tree-optimization/84136
29767 * tree-cfg.c (find_taken_edge_computed_goto): Remove assertion
29768 that the result of find_edge is non-NULL.
29769
29770 2018-02-08 Sergey Shalnov <sergey.shalnov@intel.com>
29771
29772 PR target/83008
29773 * config/i386/x86-tune-costs.h (skylake_cost): Fix cost of
29774 storing integer register in SImode. Fix cost of 256 and 512
29775 byte aligned SSE register store.
29776
29777 2018-02-08 Sergey Shalnov <sergey.shalnov@intel.com>
29778
29779 * config/i386/i386.c (ix86_multiplication_cost): Fix
29780 multiplication cost for TARGET_AVX512DQ.
29781
29782 2018-02-08 Marek Polacek <polacek@redhat.com>
29783
29784 PR tree-optimization/84238
29785 * tree-ssa-strlen.c (maybe_diag_stxncpy_trunc): Verify the result of
29786 get_range_strlen.
29787
29788 2018-02-08 Richard Sandiford <richard.sandiford@linaro.org>
29789
29790 PR tree-optimization/84265
29791 * tree-vect-stmts.c (vectorizable_store): Don't treat
29792 VMAT_CONTIGUOUS accesses as grouped.
29793 (vectorizable_load): Likewise.
29794
29795 2018-02-08 Richard Sandiford <richard.sandiford@linaro.org>
29796
29797 PR tree-optimization/81635
29798 * wide-int.h (wi::round_down_for_mask, wi::round_up_for_mask): Declare.
29799 * wide-int.cc (wi::round_down_for_mask, wi::round_up_for_mask)
29800 (test_round_for_mask): New functions.
29801 (wide_int_cc_tests): Call test_round_for_mask.
29802 * tree-vrp.h (intersect_range_with_nonzero_bits): Declare.
29803 * tree-vrp.c (intersect_range_with_nonzero_bits): New function.
29804 * tree-data-ref.c (split_constant_offset_1): Use it to refine the
29805 range returned by get_range_info.
29806
29807 2018-02-08 Jan Hubicka <hubicka@ucw.cz>
29808
29809 PR ipa/81360
29810 * cgraph.h (symtab_node::output_to_lto_symbol_table_p): Declare
29811 * symtab.c: Include builtins.h
29812 (symtab_node::output_to_lto_symbol_table_p): Move here
29813 from lto-streamer-out.c:output_symbol_p.
29814 * lto-streamer-out.c (write_symbol): Turn early exit to assert.
29815 (output_symbol_p): Move all logic to symtab.c
29816 (produce_symtab): Update.
29817
29818 2018-02-08 Andreas Krebbel <krebbel@linux.vnet.ibm.com>
29819
29820 * config/s390/s390-opts.h (enum indirect_branch): Define.
29821 * config/s390/s390-protos.h (s390_return_addr_from_memory)
29822 (s390_indirect_branch_via_thunk)
29823 (s390_indirect_branch_via_inline_thunk): Add function prototypes.
29824 (enum s390_indirect_branch_type): Define.
29825 * config/s390/s390.c (struct s390_frame_layout, struct
29826 machine_function): Remove.
29827 (indirect_branch_prez10thunk_mask, indirect_branch_z10thunk_mask)
29828 (indirect_branch_table_label_no, indirect_branch_table_name):
29829 Define variables.
29830 (INDIRECT_BRANCH_NUM_OPTIONS): Define macro.
29831 (enum s390_indirect_branch_option): Define.
29832 (s390_return_addr_from_memory): New function.
29833 (s390_handle_string_attribute): New function.
29834 (s390_attribute_table): Add new attribute handler.
29835 (s390_execute_label): Handle UNSPEC_EXECUTE_JUMP patterns.
29836 (s390_indirect_branch_via_thunk): New function.
29837 (s390_indirect_branch_via_inline_thunk): New function.
29838 (s390_function_ok_for_sibcall): When jumping via thunk disallow
29839 sibling call optimization for non z10 compiles.
29840 (s390_emit_call): Force indirect branch target to be a single
29841 register. Add r1 clobber for non-z10 compiles.
29842 (s390_emit_epilogue): Emit return jump via return_use expander.
29843 (s390_reorg): Handle JUMP_INSNs as execute targets.
29844 (s390_option_override_internal): Perform validity checks for the
29845 new command line options.
29846 (s390_indirect_branch_attrvalue): New function.
29847 (s390_indirect_branch_settings): New function.
29848 (s390_set_current_function): Invoke s390_indirect_branch_settings.
29849 (s390_output_indirect_thunk_function): New function.
29850 (s390_code_end): Implement target hook.
29851 (s390_case_values_threshold): Implement target hook.
29852 (TARGET_ASM_CODE_END, TARGET_CASE_VALUES_THRESHOLD): Define target
29853 macros.
29854 * config/s390/s390.h (struct s390_frame_layout)
29855 (struct machine_function): Move here from s390.c.
29856 (TARGET_INDIRECT_BRANCH_NOBP_RET)
29857 (TARGET_INDIRECT_BRANCH_NOBP_JUMP)
29858 (TARGET_INDIRECT_BRANCH_NOBP_JUMP_THUNK)
29859 (TARGET_INDIRECT_BRANCH_NOBP_JUMP_INLINE_THUNK)
29860 (TARGET_INDIRECT_BRANCH_NOBP_CALL)
29861 (TARGET_DEFAULT_INDIRECT_BRANCH_TABLE)
29862 (TARGET_INDIRECT_BRANCH_THUNK_NAME_EXRL)
29863 (TARGET_INDIRECT_BRANCH_THUNK_NAME_EX)
29864 (TARGET_INDIRECT_BRANCH_TABLE): Define macros.
29865 * config/s390/s390.md (UNSPEC_EXECUTE_JUMP)
29866 (INDIRECT_BRANCH_THUNK_REGNUM): Define constants.
29867 (mnemonic attribute): Add values which aren't recognized
29868 automatically.
29869 ("*cjump_long", "*icjump_long", "*basr", "*basr_r"): Disable
29870 pattern for branch conversion. Fix mnemonic attribute.
29871 ("*c<code>", "*sibcall_br", "*sibcall_value_br", "*return"): Emit
29872 indirect branch via thunk if requested.
29873 ("indirect_jump", "<code>"): Expand patterns for branch conversion.
29874 ("*indirect_jump"): Disable for branch conversion using out of
29875 line thunks.
29876 ("indirect_jump_via_thunk<mode>_z10")
29877 ("indirect_jump_via_thunk<mode>")
29878 ("indirect_jump_via_inlinethunk<mode>_z10")
29879 ("indirect_jump_via_inlinethunk<mode>", "*casesi_jump")
29880 ("casesi_jump_via_thunk<mode>_z10", "casesi_jump_via_thunk<mode>")
29881 ("casesi_jump_via_inlinethunk<mode>_z10")
29882 ("casesi_jump_via_inlinethunk<mode>", "*basr_via_thunk<mode>_z10")
29883 ("*basr_via_thunk<mode>", "*basr_r_via_thunk_z10")
29884 ("*basr_r_via_thunk", "return<mode>_prez10"): New pattern.
29885 ("*indirect2_jump"): Disable for branch conversion.
29886 ("casesi_jump"): Turn into expander and expand patterns for branch
29887 conversion.
29888 ("return_use"): New expander.
29889 ("*return"): Emit return via thunk and rename it to ...
29890 ("*return<mode>"): ... this one.
29891 * config/s390/s390.opt: Add new options and and enum for the
29892 option values.
29893
29894 2018-02-08 Richard Sandiford <richard.sandiford@linaro.org>
29895
29896 * lra-constraints.c (match_reload): Unconditionally use
29897 gen_lowpart_SUBREG, rather than selecting between that
29898 and equivalent gen_rtx_SUBREG code.
29899
29900 2018-02-08 Richard Biener <rguenther@suse.de>
29901
29902 PR tree-optimization/84233
29903 * tree-ssa-phiprop.c (propagate_with_phi): Use separate
29904 changed flag instead of boguously re-using phi_inserted.
29905
29906 2018-02-08 Martin Jambor <mjambor@suse.cz>
29907
29908 * hsa-gen.c (get_symbol_for_decl): Set program allocation for
29909 static local variables.
29910
29911 2018-02-08 Richard Biener <rguenther@suse.de>
29912
29913 PR tree-optimization/84278
29914 * tree-vect-stmts.c (vectorizable_store): When looking for
29915 smaller vector types to perform grouped strided loads/stores
29916 make sure the mode is supported by the target.
29917 (vectorizable_load): Likewise.
29918
29919 2018-02-08 Wilco Dijkstra <wdijkstr@arm.com>
29920
29921 * config/aarch64/aarch64.c (aarch64_components_for_bb):
29922 Increase LDP/STP opportunities by adding adjacent callee-saves.
29923
29924 2018-02-08 Wilco Dijkstra <wdijkstr@arm.com>
29925
29926 PR rtl-optimization/84068
29927 PR rtl-optimization/83459
29928 * haifa-sched.c (rank_for_schedule): Fix SCHED_PRESSURE_MODEL sorting.
29929
29930 2018-02-08 Aldy Hernandez <aldyh@redhat.com>
29931
29932 PR tree-optimization/84224
29933 * gimple-ssa-warn-alloca.c (pass_walloca::execute): Remove assert.
29934 * calls.c (gimple_alloca_call_p): Only return TRUE when we have
29935 non-zero arguments.
29936
29937 2018-02-07 Iain Sandoe <iain@codesourcery.com>
29938
29939 PR target/84113
29940 * config/rs6000/altivec.md (*restore_world): Remove LR use.
29941 * config/rs6000/predicates.md (restore_world_operation): Adjust op
29942 count, remove one USE.
29943
29944 2018-02-07 Michael Meissner <meissner@linux.vnet.ibm.com>
29945
29946 * doc/install.texi (Configuration): Document the
29947 --with-long-double-format={ibm,ieee} PowerPC configuration
29948 options.
29949
29950 PR target/84154
29951 * config/rs6000/rs6000.md (fix_trunc<SFDF:mode><QHI:mode>2):
29952 Convert from define_expand to be define_insn_and_split. Rework
29953 float/double/_Float128 conversions to QI/HI/SImode to work with
29954 both ISA 2.07 (power8) or ISA 3.0 (power9). Fix regression where
29955 conversions to QI/HImode types did a store and then a load to
29956 truncate the value. For conversions to VSX registers, don't split
29957 the insn, instead emit the code directly. Use the code iterator
29958 any_fix to combine signed and unsigned conversions.
29959 (fix<uns>_trunc<SFDF:mode>si2_p8): Likewise.
29960 (fixuns_trunc<SFDF:mode><QHI:mode>2): Likewise.
29961 (fix_trunc<IEEE128:mode><QHI:mode>2): Likewise.
29962 (fix<uns>_trunc<SFDF:mode><QHI:mode>2): Likewise.
29963 (fix_<mode>di2_hw): Likewise.
29964 (fixuns_<mode>di2_hw): Likewise.
29965 (fix_<mode>si2_hw): Likewise.
29966 (fixuns_<mode>si2_hw): Likewise.
29967 (fix<uns>_<IEEE128:mode><SDI:mode>2_hw): Likewise.
29968 (fix<uns>_trunc<IEEE128:mode><QHI:mode>2): Likewise.
29969 (fctiw<u>z_<mode>_smallint): Rename fctiw<u>z_<mode>_smallint to
29970 fix<uns>_trunc<SFDF:mode>si2_p8.
29971 (fix_trunc<SFDF:mode><QHI:mode>2_internal): Delete, no longer used.
29972 (fixuns_trunc<SFDF:mode><QHI:mode>2_internal): Likewise.
29973 (fix<uns>_<mode>_mem): Likewise.
29974 (fctiw<u>z_<mode>_mem): Likewise.
29975 (fix<uns>_<mode>_mem): Likewise.
29976 (fix<uns>_trunc<SFDF:mode><QHSI:mode>2_mem): On ISA 3.0, prevent
29977 the register allocator from doing a direct move to the GPRs to do
29978 a store, and instead use the ISA 3.0 store byte/half-word from
29979 vector register instruction. For IEEE 128-bit floating point,
29980 also optimize stores of 32-bit ints.
29981 (fix<uns>_trunc<IEEE128:mode><QHSI:mode>2_mem): Likewise.
29982
29983 2018-02-07 Alan Hayward <alan.hayward@arm.com>
29984
29985 * genextract.c (push_pathstr_operand): New function to support
29986 [a-zA-Z].
29987 (walk_rtx): Call push_pathstr_operand.
29988 (print_path): Support [a-zA-Z].
29989
29990 2018-02-07 Richard Biener <rguenther@suse.de>
29991
29992 PR tree-optimization/84037
29993 * tree-vectorizer.h (struct _loop_vec_info): Add ivexpr_map member.
29994 (cse_and_gimplify_to_preheader): Declare.
29995 (vect_get_place_in_interleaving_chain): Likewise.
29996 * tree-vect-loop.c (_loop_vec_info::_loop_vec_info): Initialize
29997 ivexpr_map.
29998 (_loop_vec_info::~_loop_vec_info): Delete it.
29999 (cse_and_gimplify_to_preheader): New function.
30000 * tree-vect-slp.c (vect_get_place_in_interleaving_chain): Export.
30001 * tree-vect-stmts.c (vectorizable_store): CSE base and steps.
30002 (vectorizable_load): Likewise. For grouped stores always base
30003 the IV on the first element.
30004 * tree-vect-loop-manip.c (vect_loop_versioning): Unshare versioning
30005 condition before gimplifying.
30006
30007 2018-02-07 Jakub Jelinek <jakub@redhat.com>
30008
30009 * tree-eh.c (operation_could_trap_helper_p): Ignore honor_trapv for
30010 *DIV_EXPR and *MOD_EXPR.
30011
30012 2018-02-07 H.J. Lu <hongjiu.lu@intel.com>
30013
30014 PR target/84248
30015 * config/i386/i386.c (ix86_option_override_internal): Mask out
30016 the CF_SET bit when checking -fcf-protection.
30017
30018 2018-02-07 Tom de Vries <tom@codesourcery.com>
30019
30020 PR libgomp/84217
30021 * omp-expand.c (expand_oacc_collapse_init): Ensure diff_type is large
30022 enough.
30023
30024 2018-02-07 Richard Biener <rguenther@suse.de>
30025
30026 PR tree-optimization/84204
30027 * tree-chrec.c (chrec_fold_plus_1): Remove size limiting in
30028 this place.
30029
30030 PR tree-optimization/84205
30031 * graphite-isl-ast-to-gimple.c (binary_op_to_tree): Also
30032 special-case isl_ast_op_zdiv_r.
30033
30034 PR tree-optimization/84223
30035 * graphite-scop-detection.c (gather_bbs::before_dom_children):
30036 Only add conditions from within the region.
30037 (gather_bbs::after_dom_children): Adjust.
30038
30039 2018-02-07 Georg-Johann Lay <avr@gjlay.de>
30040
30041 PR target/84209
30042 * config/avr/avr.h (GENERAL_REGNO_P, GENERAL_REG_P): New macros.
30043 * config/avr/avr.md: Only post-reload split REG-REG moves if
30044 either register is GENERAL_REG_P.
30045
30046 2018-02-07 Jakub Jelinek <jakub@redhat.com>
30047
30048 PR tree-optimization/84235
30049 * tree-ssa-scopedtables.c
30050 (avail_exprs_stack::simplify_binary_operation): Fir MINUS_EXPR, punt
30051 if the subtraction is performed in floating point type where NaNs are
30052 honored. For *DIV_EXPR, punt for ALL_FRACT_MODE_Ps where we can't
30053 build 1. Formatting fix.
30054
30055 2018-02-06 Jakub Jelinek <jakub@redhat.com>
30056
30057 PR target/84146
30058 * config/i386/i386.c (rest_of_insert_endbranch): Only skip
30059 NOTE_INSN_CALL_ARG_LOCATION after a call, not anything else,
30060 and skip it regardless of bb boundaries. Use CALL_P macro,
30061 don't test INSN_P (insn) together with CALL_P or JUMP_P check
30062 unnecessarily, formatting fix.
30063
30064 2018-02-06 Michael Collison <michael.collison@arm.com>
30065
30066 * config/arm/thumb2.md:
30067 (*thumb2_mov_negscc): Split only if TARGET_THUMB2 && !arm_restrict_it.
30068 (*thumb_mov_notscc): Ditto.
30069
30070 2018-02-06 Michael Meissner <meissner@linux.vnet.ibm.com>
30071
30072 PR target/84154
30073 * config/rs6000/rs6000.md (su code attribute): Use "u" for
30074 unsigned_fix, not "s".
30075
30076 2018-02-06 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
30077
30078 * configure.ac (gcc_fn_eh_frame_ro): New function.
30079 (gcc_cv_as_cfi_directive): Check both 32 and 64-bit assembler for
30080 correct .eh_frame permissions.
30081 * configure: Regenerate.
30082
30083 2018-02-06 Andrew Jenner <andrew@codeourcery.com>
30084
30085 * doc/invoke.texi: Add section for the PowerPC SPE backend. Remove
30086 irrelevant options.
30087
30088 2018-02-06 Bill Schmidt <wschmidt@linux.vnet.ibm.com>
30089
30090 * config/rs6000/rs6000.c (rs6000_option_override_internal):
30091 Display warning message for -mno-speculate-indirect-jumps.
30092
30093 2018-02-06 Andrew Jenner <andrew@codesourcery.com>
30094
30095 * config/powerpcspe/powerpcspe.opt: (msimple-fpu, mfpu) Add
30096 Undocumented.
30097 * config/powerpcspe/sysv4.opt (mbit-align): Likewise.
30098
30099 2018-02-06 Aldy Hernandez <aldyh@redhat.com>
30100
30101 PR tree-optimization/84225
30102 * tree-eh.c (find_trapping_overflow): Only call
30103 operation_no_trapping_overflow when ANY_INTEGRAL_TYPE_P.
30104
30105 2018-02-06 Igor Tsimbalist <igor.v.tsimbalist@intel.com>
30106
30107 PR target/84145
30108 * config/i386/i386.c: Reimplement the check of possible options
30109 -mibt/-mshstk conbination. Change error messages.
30110 * doc/invoke.texi: Fix a typo: remove extra '='.
30111
30112 2018-02-06 Marek Polacek <polacek@redhat.com>
30113
30114 PR tree-optimization/84228
30115 * tree-ssa-strlen.c (maybe_diag_stxncpy_trunc): Skip debug statements.
30116
30117 2018-02-06 Tamar Christina <tamar.christina@arm.com>
30118
30119 PR target/82641
30120 * config/arm/arm.c (arm_print_asm_arch_directives): Record already
30121 emitted arch directives.
30122 * config/arm/arm-c.c (arm_cpu_builtins): Undefine __ARM_ARCH and
30123 __ARM_FEATURE_COPROC before changing architectures.
30124
30125 2018-02-06 Richard Biener <rguenther@suse.de>
30126
30127 * config/i386/i386.c (print_reg): Fix typo.
30128 (ix86_loop_unroll_adjust): Do not unroll beyond the original nunroll.
30129
30130 2018-02-06 Eric Botcazou <ebotcazou@adacore.com>
30131
30132 * configure: Regenerate.
30133
30134 2018-02-05 Martin Sebor <msebor@redhat.com>
30135
30136 PR tree-optimization/83369
30137 * tree-ssa-ccp.c (pass_post_ipa_warn::execute): Use %G to print
30138 inlining context.
30139
30140 2018-02-05 Martin Liska <mliska@suse.cz>
30141
30142 * doc/invoke.texi: Cherry-pick upstream r323995.
30143
30144 2018-02-05 Richard Sandiford <richard.sandiford@linaro.org>
30145
30146 * ira.c (ira_init_register_move_cost): Adjust comment.
30147
30148 2018-02-05 Martin Liska <mliska@suse.cz>
30149
30150 PR gcov-profile/84137
30151 * doc/gcov.texi: Fix typo in documentation.
30152
30153 2018-02-05 Martin Liska <mliska@suse.cz>
30154
30155 PR gcov-profile/83879
30156 * doc/gcov.texi: Document necessity of --dynamic-list-data when
30157 using dlopen functionality.
30158
30159 2018-02-05 Olga Makhotina <olga.makhotina@intel.com>
30160
30161 * config/i386/avx512dqintrin.h (_mm_mask_range_sd, _mm_maskz_range_sd,
30162 _mm_mask_range_round_sd, _mm_maskz_range_round_sd, _mm_mask_range_ss,
30163 _mm_maskz_range_ss, _mm_mask_range_round_ss,
30164 _mm_maskz_range_round_ss): New intrinsics.
30165 (__builtin_ia32_rangesd128_round)
30166 (__builtin_ia32_rangess128_round): Remove.
30167 (__builtin_ia32_rangesd128_mask_round,
30168 __builtin_ia32_rangess128_mask_round): New builtins.
30169 * config/i386/i386-builtin.def (__builtin_ia32_rangesd128_round,
30170 __builtin_ia32_rangess128_round): Remove.
30171 (__builtin_ia32_rangesd128_mask_round,
30172 __builtin_ia32_rangess128_mask_round): New builtins.
30173 * config/i386/sse.md (ranges<mode><round_saeonly_name>): Renamed to ...
30174 (ranges<mode><mask_scalar_name><round_saeonly_scalar_name>): ... this.
30175 ((match_operand:VF_128 2 "<round_saeonly_nimm_predicate>"
30176 "<round_saeonly_constraint>")): Changed to ...
30177 ((match_operand:VF_128 2 "<round_saeonly_scalar_nimm_predicate>"
30178 "<round_saeonly_scalar_constraint>")): ... this.
30179 ("vrange<ssescalarmodesuffix>\t{%3, <round_saeonly_op4>%2, %1, %0|
30180 %0, %1, %2<round_saeonly_op4>, %3}"): Changed to ...
30181 ("vrange<ssescalarmodesuffix>\t{%3, <round_saeonly_scalar_mask_op4>%2,
30182 %1, %0<mask_scalar_operand4>|%0<mask_scalar_operand4>, %1,
30183 %2<round_saeonly_scalar_mask_op4>, %3}"): ... this.
30184
30185 2018-02-02 Andrew Jenner <andrew@codesourcery.com>
30186
30187 * config/powerpcspe/powerpcspe.opt: Add Undocumented to irrelevant
30188 options.
30189 * config/powerpcspe/powerpcspe-tables.opt (rs6000_cpu_opt_value):
30190 Remove all values except native, 8540 and 8548.
30191
30192 2018-02-02 H.J. Lu <hongjiu.lu@intel.com>
30193
30194 * config/i386/i386.c (ix86_output_function_return): Pass
30195 INVALID_REGNUM, instead of -1, as invalid register number to
30196 indirect_thunk_name and output_indirect_thunk.
30197
30198 2018-02-02 Julia Koval <julia.koval@intel.com>
30199
30200 * config.gcc: Add -march=icelake.
30201 * config/i386/driver-i386.c (host_detect_local_cpu): Detect icelake.
30202 * config/i386/i386-c.c (ix86_target_macros_internal): Handle icelake.
30203 * config/i386/i386.c (processor_costs): Add m_ICELAKE.
30204 (PTA_ICELAKE, PTA_AVX512VNNI, PTA_GFNI, PTA_VAES, PTA_AVX512VBMI2,
30205 PTA_VPCLMULQDQ, PTA_RDPID, PTA_AVX512BITALG): New.
30206 (processor_target_table): Add icelake.
30207 (ix86_option_override_internal): Handle new PTAs.
30208 (get_builtin_code_for_version): Handle icelake.
30209 (M_INTEL_COREI7_ICELAKE): New.
30210 (fold_builtin_cpu): Handle icelake.
30211 * config/i386/i386.h (TARGET_ICELAKE, PROCESSOR_ICELAKE): New.
30212 * doc/invoke.texi: Add -march=icelake.
30213
30214 2018-02-02 Julia Koval <julia.koval@intel.com>
30215
30216 * config/i386/i386.c (ix86_option_override_internal): Change flags type
30217 to wide_int_bitmask.
30218 * wide-int-bitmask.h: New.
30219
30220 2018-02-02 Igor Tsimbalist <igor.v.tsimbalist@intel.com>
30221
30222 PR target/84066
30223 * config/i386/i386.md: Replace Pmode with word_mode in
30224 builtin_setjmp_setup and builtin_longjmp to support x32.
30225
30226 2018-02-01 Peter Bergner <bergner@vnet.ibm.com>
30227
30228 PR target/56010
30229 PR target/83743
30230 * config/rs6000/driver-rs6000.c: #include "diagnostic.h".
30231 #include "opts.h".
30232 (rs6000_supported_cpu_names): New static variable.
30233 (linux_cpu_translation_table): Likewise.
30234 (elf_platform) <cpu>: Define new static variable and use it.
30235 Translate kernel AT_PLATFORM name to canonical name if needed.
30236 Error if platform name is unknown.
30237
30238 2018-02-01 Aldy Hernandez <aldyh@redhat.com>
30239
30240 PR target/84089
30241 * config/pa/predicates.md (base14_operand): Handle E_VOIDmode.
30242
30243 2018-02-01 Jeff Law <law@redhat.com>
30244
30245 PR target/84128
30246 * config/i386/i386.c (release_scratch_register_on_entry): Add new
30247 OFFSET and RELEASE_VIA_POP arguments. Use SP+OFFSET to restore
30248 the scratch if RELEASE_VIA_POP is false.
30249 (ix86_adjust_stack_and_probe_stack_clash): Un-constify SIZE.
30250 If we have to save a temporary register, decrement SIZE appropriately.
30251 Pass new arguments to release_scratch_register_on_entry.
30252 (ix86_adjust_stack_and_probe): Likewise.
30253 (ix86_emit_probe_stack_range): Pass new arguments to
30254 release_scratch_register_on_entry.
30255
30256 2018-02-01 Uros Bizjak <ubizjak@gmail.com>
30257
30258 PR rtl-optimization/84157
30259 * combine.c (change_zero_ext): Use REG_P predicate in
30260 front of HARD_REGISTER_P predicate.
30261
30262 2018-02-01 Georg-Johann Lay <avr@gjlay.de>
30263
30264 * config/avr/avr.c (avr_option_override): Move disabling of
30265 -fdelete-null-pointer-checks to...
30266 * common/config/avr/avr-common.c (avr_option_optimization_table):
30267 ...here.
30268
30269 2018-02-01 Richard Sandiford <richard.sandiford@linaro.org>
30270
30271 PR tree-optimization/81635
30272 * tree-data-ref.c (split_constant_offset_1): For types that
30273 wrap on overflow, try to use range info to prove that wrapping
30274 cannot occur.
30275
30276 2018-02-01 Renlin Li <renlin.li@arm.com>
30277
30278 PR target/83370
30279 * config/aarch64/aarch64.c (aarch64_class_max_nregs): Handle
30280 TAILCALL_ADDR_REGS.
30281 (aarch64_register_move_cost): Likewise.
30282 * config/aarch64/aarch64.h (reg_class): Rename CALLER_SAVE_REGS to
30283 TAILCALL_ADDR_REGS.
30284 (REG_CLASS_NAMES): Likewise.
30285 (REG_CLASS_CONTENTS): Rename CALLER_SAVE_REGS to
30286 TAILCALL_ADDR_REGS. Remove IP registers.
30287 * config/aarch64/aarch64.md (Ucs): Update register constraint.
30288
30289 2018-02-01 Richard Biener <rguenther@suse.de>
30290
30291 * domwalk.h (dom_walker::dom_walker): Add additional constructor
30292 for specifying RPO order and allow NULL for that.
30293 * domwalk.c (dom_walker::dom_walker): Likewise.
30294 (dom_walker::walk): Handle NULL RPO order.
30295 * tree-into-ssa.c (rewrite_dom_walker): Do not walk dom children
30296 in RPO order.
30297 (rewrite_update_dom_walker): Likewise.
30298 (mark_def_dom_walker): Likewise.
30299
30300 2018-02-01 Richard Sandiford <richard.sandiford@linaro.org>
30301
30302 * config/aarch64/aarch64-protos.h (aarch64_split_sve_subreg_move)
30303 (aarch64_maybe_expand_sve_subreg_move): Declare.
30304 * config/aarch64/aarch64.md (UNSPEC_REV_SUBREG): New unspec.
30305 * config/aarch64/predicates.md (aarch64_any_register_operand): New
30306 predicate.
30307 * config/aarch64/aarch64-sve.md (mov<mode>): Optimize subreg moves
30308 that are semantically a reverse operation.
30309 (*aarch64_sve_mov<mode>_subreg_be): New pattern.
30310 * config/aarch64/aarch64.c (aarch64_maybe_expand_sve_subreg_move):
30311 (aarch64_replace_reg_mode, aarch64_split_sve_subreg_move): New
30312 functions.
30313 (aarch64_can_change_mode_class): For big-endian, forbid changes
30314 between two SVE modes if they have different element sizes.
30315
30316 2018-02-01 Richard Sandiford <richard.sandiford@linaro.org>
30317
30318 * config/aarch64/aarch64.c (aarch64_expand_sve_const_vector): Prefer
30319 the TImode handling for big-endian targets.
30320
30321 2018-02-01 Richard Sandiford <richard.sandiford@linaro.org>
30322
30323 * config/aarch64/aarch64-sve.md (sve_ld1rq): Replace with...
30324 (*sve_ld1rq<Vesize>): ... this new pattern. Handle all element sizes,
30325 not just bytes.
30326 * config/aarch64/aarch64.c (aarch64_expand_sve_widened_duplicate):
30327 Remove BSWAP handing for big-endian targets and use the form of
30328 LD1RQ appropariate for the mode.
30329
30330 2018-02-01 Richard Sandiford <richard.sandiford@linaro.org>
30331
30332 * config/aarch64/aarch64.c (aarch64_simd_valid_immediate): Handle
30333 all CONST_VECTOR_DUPLICATE_P vectors, not just those with a single
30334 duplicated element.
30335
30336 2018-02-01 Richard Sandiford <richard.sandiford@linaro.org>
30337
30338 PR tearget/83845
30339 * config/aarch64/aarch64.c (aarch64_secondary_reload): Tighten
30340 check for operands that need to go through aarch64_sve_reload_be.
30341
30342 2018-02-01 Jakub Jelinek <jakub@redhat.com>
30343
30344 PR tree-optimization/81661
30345 PR tree-optimization/84117
30346 * tree-eh.h (rewrite_to_non_trapping_overflow): Declare.
30347 * tree-eh.c: Include gimplify.h.
30348 (find_trapping_overflow, replace_trapping_overflow,
30349 rewrite_to_non_trapping_overflow): New functions.
30350 * tree-vect-loop.c: Include tree-eh.h.
30351 (vect_get_loop_niters): Use rewrite_to_non_trapping_overflow.
30352 * tree-data-ref.c: Include tree-eh.h.
30353 (get_segment_min_max): Use rewrite_to_non_trapping_overflow.
30354
30355 2018-01-31 Uros Bizjak <ubizjak@gmail.com>
30356
30357 PR rtl-optimization/84123
30358 * combine.c (change_zero_ext): Check if hard register satisfies
30359 can_change_dest_mode before calling gen_lowpart_SUBREG.
30360
30361 2018-01-31 Vladimir Makarov <vmakarov@redhat.com>
30362
30363 PR target/82444
30364 * ira.c (ira_init_register_move_cost): Remove assert.
30365
30366 2018-01-31 Eric Botcazou <ebotcazou@adacore.com>
30367
30368 PR rtl-optimization/84071
30369 * doc/tm.texi.in (WORD_REGISTER_OPERATIONS): Add explicit case.
30370 * doc/tm.texi: Regenerate.
30371
30372 2018-01-31 Richard Biener <rguenther@suse.de>
30373
30374 PR tree-optimization/84132
30375 * tree-data-ref.c (analyze_miv_subscript): Properly
30376 check whether evolution_function_is_affine_multivariate_p
30377 before calling gcd_of_steps_may_divide_p.
30378
30379 2018-01-31 Julia Koval <julia.koval@intel.com>
30380
30381 PR target/83618
30382 * config/i386/i386.c (ix86_expand_builtin): Handle IX86_BUILTIN_RDPID.
30383 * config/i386/i386.md (rdpid_rex64) New.
30384 (rdpid): Make 32bit only.
30385
30386 2018-01-29 Aldy Hernandez <aldyh@redhat.com>
30387
30388 PR lto/84105
30389 * tree-pretty-print.c (dump_generic_node): Handle a TYPE_NAME with
30390 an IDENTIFIER_NODE for FUNCTION_TYPE's.
30391
30392 2018-01-31 Eric Botcazou <ebotcazou@adacore.com>
30393
30394 Revert
30395 2018-01-12 Eric Botcazou <ebotcazou@adacore.com>
30396
30397 * config/sparc/sparc.md (vxworks_load_got): Set the GOT register.
30398
30399 2018-01-31 Eric Botcazou <ebotcazou@adacore.com>
30400
30401 PR rtl-optimization/84071
30402 * combine.c (record_dead_and_set_regs_1): Record the source unmodified
30403 for a paradoxical SUBREG on a WORD_REGISTER_OPERATIONS target.
30404
30405 2018-01-31 Claudiu Zissulescu <claziss@synopsys.com>
30406
30407 * config/arc/arc.c (arc_handle_aux_attribute): New function.
30408 (arc_attribute_table): Add 'aux' attribute.
30409 (arc_in_small_data_p): Consider aux like variables.
30410 (arc_is_aux_reg_p): New function.
30411 (arc_asm_output_aligned_decl_local): Ignore 'aux' like variables.
30412 (arc_get_aux_arg): New function.
30413 (prepare_move_operands): Handle aux-register access.
30414 (arc_handle_aux_attribute): New function.
30415 * doc/extend.texi (ARC Variable attributes): Add subsection.
30416
30417 2018-01-31 Claudiu Zissulescu <claziss@synopsys.com>
30418
30419 * config/arc/arc-protos.h (arc_is_uncached_mem_p): Function proto.
30420 * config/arc/arc.c (arc_handle_uncached_attribute): New function.
30421 (arc_attribute_table): Add 'uncached' attribute.
30422 (arc_print_operand): Print '.di' flag for uncached memory
30423 accesses.
30424 (arc_in_small_data_p): Do not consider for small data the uncached
30425 types.
30426 (arc_is_uncached_mem_p): New function.
30427 * config/arc/predicates.md (compact_store_memory_operand): Check
30428 for uncached memory accesses.
30429 (nonvol_nonimm_operand): Likewise.
30430 * doc/extend.texi (ARC Type Attribute): New subsection.
30431
30432 2018-01-31 Jakub Jelinek <jakub@redhat.com>
30433
30434 PR c/84100
30435 * common.opt (falign-functions=, falign-jumps=, falign-labels=,
30436 falign-loops=): Add Optimization flag.
30437
30438 2018-01-30 Jeff Law <law@redhat.com>
30439
30440 PR target/84064
30441 * i386.c (ix86_adjust_stack_and_probe_stack_clash): New argument
30442 INT_REGISTERS_SAVED. Check it prior to calling
30443 get_scratch_register_on_entry.
30444 (ix86_adjust_stack_and_probe): Similarly.
30445 (ix86_emit_probe_stack_range): Similarly.
30446 (ix86_expand_prologue): Corresponding changes.
30447
30448 2018-01-30 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
30449
30450 PR target/40411
30451 * config/sol2.h (STARTFILE_ARCH_SPEC): Use -std=c*,
30452 -std=iso9899:199409 instead of -pedantic to select values-Xc.o.
30453
30454 2018-01-30 Vladimir Makarov <vmakarov@redhat.com>
30455
30456 PR target/84112
30457 * lra-constraints.c (curr_insn_transform): Process AND in the
30458 address.
30459
30460 2018-01-30 Jakub Jelinek <jakub@redhat.com>
30461
30462 PR rtl-optimization/83986
30463 * sched-deps.c (sched_analyze_insn): For frame related insns, add anti
30464 dependence against last_pending_memory_flush in addition to
30465 pending_jump_insns.
30466
30467 2018-01-30 Alexandre Oliva <aoliva@redhat.com>
30468
30469 PR tree-optimization/81611
30470 * tree-ssa-dom.c (simple_iv_increment_p): Skip intervening
30471 copies.
30472
30473 2018-01-30 Aaron Sawdey <acsawdey@linux.vnet.ibm.com>
30474
30475 PR target/83758
30476 * config/rs6000/rs6000.c (rs6000_internal_arg_pointer): Only return
30477 a reg rtx.
30478
30479 2018-01-30 Richard Biener <rguenther@suse.de>
30480 Jakub Jelinek <jakub@redhat.com>
30481
30482 PR tree-optimization/84111
30483 * tree-ssa-loop-ivcanon.c (tree_unroll_loops_completely_1): Skip
30484 inner loops added during recursion, as they don't have up-to-date
30485 SSA form.
30486
30487 2018-01-30 Jan Hubicka <hubicka@ucw.cz>
30488
30489 PR ipa/81360
30490 * ipa-inline.c (can_inline_edge_p): Break out late tests to...
30491 (can_inline_edge_by_limits_p): ... here.
30492 (can_early_inline_edge_p, check_callers,
30493 update_caller_keys, update_callee_keys, recursive_inlining,
30494 add_new_edges_to_heap, speculation_useful_p,
30495 inline_small_functions,
30496 inline_small_functions, flatten_function,
30497 inline_to_all_callers_1): Update.
30498
30499 2018-01-30 Jan Hubicka <hubicka@ucw.cz>
30500
30501 * profile-count.c (profile_count::combine_with_ipa_count): Handle
30502 zeros correctly.
30503
30504 2018-01-30 Richard Biener <rguenther@suse.de>
30505
30506 PR tree-optimization/83008
30507 * tree-vect-slp.c (vect_analyze_slp_cost_1): Properly cost
30508 invariant and constant vector uses in stmts when they need
30509 more than one stmt.
30510
30511 2018-01-30 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
30512
30513 PR bootstrap/84017
30514 * configure.ac (gcc_cv_as_shf_merge): Disable on Solaris 10/x86.
30515 * configure: Regenerate.
30516
30517 2018-01-30 Richard Sandiford <richard.sandiford@linaro.org>
30518
30519 * config/aarch64/aarch64-sve.md (*vec_extract<mode><Vel>_0): New
30520 pattern.
30521 (*vec_extract<mode><Vel>_v128): Require a nonzero lane number.
30522 Use gen_rtx_REG rather than gen_lowpart.
30523
30524 2018-01-30 Richard Sandiford <richard.sandiford@linaro.org>
30525
30526 * lra-constraints.c (match_reload): Use subreg_lowpart_offset
30527 rather than 0 when creating partial subregs.
30528
30529 2018-01-30 Richard Sandiford <richard.sandiford@linaro.org>
30530
30531 * vec-perm-indices.c (vec_perm_indices::series_p): Give examples
30532 of usage.
30533
30534 2018-01-29 Michael Meissner <meissner@linux.vnet.ibm.com>
30535
30536 PR target/81550
30537 * config/rs6000/rs6000.c (rs6000_setup_reg_addr_masks): If DFmode
30538 and SFmode can go in Altivec registers (-mcpu=power7 for DFmode,
30539 -mcpu=power8 for SFmode) don't set the PRE_INCDEC or PRE_MODIFY
30540 flags. This restores the settings used before the 2017-07-24.
30541 Turning off pre increment/decrement/modify allows IVOPTS to
30542 optimize DF/SF loops where the index is an int.
30543
30544 2018-01-29 Richard Biener <rguenther@suse.de>
30545 Kelvin Nilsen <kelvin@gcc.gnu.org>
30546
30547 PR bootstrap/80867
30548 * tree-vect-stmts.c (vectorizable_call): Don't call
30549 targetm.vectorize_builtin_md_vectorized_function if callee is
30550 NULL.
30551
30552 2018-01-22 Carl Love <cel@us.ibm.com>
30553
30554 * doc/extend.tex: Fix typo in second arg in
30555 __builtin_bcdadd_{lt|eq|gt|ov} and __builtin_bcdsub_{lt|eq|gt|ov}.
30556
30557 2018-01-29 Richard Biener <rguenther@suse.de>
30558
30559 PR tree-optimization/84086
30560 * tree-ssanames.c: Include cfgloop.h and tree-scalar-evolution.h.
30561 (flush_ssaname_freelist): When SSA names were released reset
30562 the SCEV hash table.
30563
30564 2018-01-29 Richard Biener <rguenther@suse.de>
30565
30566 PR tree-optimization/84057
30567 * tree-ssa-loop-ivcanon.c (unloop_loops): Deal with already
30568 removed paths when removing edges.
30569
30570 2018-01-27 H.J. Lu <hongjiu.lu@intel.com>
30571
30572 * doc/invoke.texi: Replace -mfunction-return==@var{choice} with
30573 -mfunction-return=@var{choice}.
30574
30575 2018-01-27 Bernd Edlinger <bernd.edlinger@hotmail.de>
30576
30577 PR diagnostic/84034
30578 * diagnostic-show-locus.c (get_line_width_without_trailing_whitespace):
30579 Handle CR like TAB.
30580 (layout::print_source_line): Likewise.
30581 (test_get_line_width_without_trailing_whitespace): Add test cases.
30582
30583 2018-01-27 Jakub Jelinek <jakub@redhat.com>
30584
30585 PR middle-end/84040
30586 * sched-deps.c (sched_macro_fuse_insns): Return immediately for
30587 debug insns.
30588
30589 2018-01-26 Jim Wilson <jimw@sifive.com>
30590
30591 * config/riscv/riscv.h (MAX_FIXED_MODE_SIZE): New.
30592
30593 * config/riscv/elf.h (LIB_SPEC): Don't include -lgloss when nosys.specs
30594 specified.
30595
30596 2018-01-26 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
30597
30598 * config/aarch64/aarch64.md: Add peepholes for CMP + SUB -> SUBS
30599 and CMP + SUB-immediate -> SUBS.
30600
30601 2018-01-26 Martin Sebor <msebor@redhat.com>
30602
30603 PR tree-optimization/83896
30604 * tree-ssa-strlen.c (get_string_len): Rename...
30605 (get_string_cst_length): ...to this. Return HOST_WIDE_INT.
30606 Avoid assuming length is constant.
30607 (handle_char_store): Use HOST_WIDE_INT for string length.
30608
30609 2018-01-26 Uros Bizjak <ubizjak@gmail.com>
30610
30611 PR target/81763
30612 * config/i386/i386.md (*andndi3_doubleword): Add earlyclobber
30613 to (=&r,r,rm) alternative. Add (=r,0,rm) and (=r,r,0) alternatives.
30614
30615 2018-01-26 Richard Biener <rguenther@suse.de>
30616
30617 PR rtl-optimization/84003
30618 * dse.c (record_store): Only record redundant stores when
30619 the earlier store aliases at least all accesses the later one does.
30620
30621 2018-01-26 Jakub Jelinek <jakub@redhat.com>
30622
30623 PR rtl-optimization/83985
30624 * dce.c (deletable_insn_p): Return false for separate shrink wrapping
30625 REG_CFA_RESTORE insns.
30626 (delete_unmarked_insns): Don't ignore separate shrink wrapping
30627 REG_CFA_RESTORE insns here.
30628
30629 PR c/83989
30630 * gimple-ssa-warn-restrict.c (builtin_memref::builtin_memref): Don't
30631 use SSA_NAME_VAR as base for SSA_NAMEs with non-NULL SSA_NAME_VAR.
30632
30633 2018-01-26 Claudiu Zissulescu <claziss@synopsys.com>
30634
30635 * config/arc/arc-arch.h (arc_tune_attr): Add ARC_TUNE_CORE_3.
30636 * config/arc/arc.c (arc_sched_issue_rate): Use ARC_TUNE_... .
30637 (arc_init): Likewise.
30638 (arc_override_options): Likewise.
30639 (arc_file_start): Choose Tag_ARC_CPU_variation based on arc_tune
30640 value.
30641 (hwloop_fail): Use TARGET_DBNZ when we want to check for dbnz insn
30642 support.
30643 * config/arc/arc.h (TARGET_DBNZ): Define.
30644 * config/arc/arc.md (attr tune): Add core_3, use ARC_TUNE_... to
30645 properly set the tune attribute.
30646 (dbnz): Use TARGET_DBNZ guard.
30647 * config/arc/arc.opt (mtune): Add core3 option.
30648
30649 2018-01-26 Claudiu Zissulescu <claziss@synopsys.com>
30650
30651 * config/arc/arc.c (arc_delegitimize_address_0): Refactored to
30652 recognize new pic like addresses.
30653 (arc_delegitimize_address): Clean up.
30654
30655 2018-01-26 Claudiu Zissulescu <claziss@synopsys.com>
30656
30657 * config/arc/arc-arches.def: Option mrf16 valid for all
30658 architectures.
30659 * config/arc/arc-c.def (__ARC_RF16__): New predefined macro.
30660 * config/arc/arc-cpus.def (em_mini): New cpu with rf16 on.
30661 * config/arc/arc-options.def (FL_RF16): Add mrf16 option.
30662 * config/arc/arc-tables.opt: Regenerate.
30663 * config/arc/arc.c (arc_conditional_register_usage): Handle
30664 reduced register file case.
30665 (arc_file_start): Set must have build attributes.
30666 * config/arc/arc.h (MAX_ARC_PARM_REGS): Conditional define using
30667 mrf16 option value.
30668 * config/arc/arc.opt (mrf16): Add new option.
30669 * config/arc/elf.h (ATTRIBUTE_PCS): Define.
30670 * config/arc/genmultilib.awk: Handle new mrf16 option.
30671 * config/arc/linux.h (ATTRIBUTE_PCS): Define.
30672 * config/arc/t-multilib: Regenerate.
30673 * doc/invoke.texi (ARC Options): Document mrf16 option.
30674
30675 2018-01-26 Claudiu Zissulescu <claziss@synopsys.com>
30676
30677 * config/arc/arc-protos.h: Add arc_is_secure_call_p proto.
30678 * config/arc/arc.c (arc_handle_secure_attribute): New function.
30679 (arc_attribute_table): Add 'secure_call' attribute.
30680 (arc_print_operand): Print secure call operand.
30681 (arc_function_ok_for_sibcall): Don't optimize tail calls when
30682 secure.
30683 (arc_is_secure_call_p): New function. * config/arc/arc.md
30684 (call_i): Add support for sjli instruction.
30685 (call_value_i): Likewise.
30686 * config/arc/constraints.md (Csc): New constraint.
30687
30688 2018-01-26 Claudiu Zissulescu <claziss@synopsys.com>
30689 John Eric Martin <John.Martin@emmicro-us.com>
30690
30691 * config/arc/arc-protos.h: Add arc_is_jli_call_p proto.
30692 * config/arc/arc.c (_arc_jli_section): New struct.
30693 (arc_jli_section): New type.
30694 (rc_jli_sections): New static variable.
30695 (arc_handle_jli_attribute): New function.
30696 (arc_attribute_table): Add jli_always and jli_fixed attribute.
30697 (arc_file_end): New function.
30698 (TARGET_ASM_FILE_END): Define.
30699 (arc_print_operand): Reuse 'S' letter for JLI output instruction.
30700 (arc_add_jli_section): New function.
30701 (jli_call_scan): Likewise.
30702 (arc_reorg): Call jli_call_scan.
30703 (arc_output_addsi): Remove 'S' from printing asm operand.
30704 (arc_is_jli_call_p): New function.
30705 * config/arc/arc.md (movqi_insn): Remove 'S' from printing asm
30706 operand.
30707 (movhi_insn): Likewise.
30708 (movsi_insn): Likewise.
30709 (movsi_set_cc_insn): Likewise.
30710 (loadqi_update): Likewise.
30711 (load_zeroextendqisi_update): Likewise.
30712 (load_signextendqisi_update): Likewise.
30713 (loadhi_update): Likewise.
30714 (load_zeroextendhisi_update): Likewise.
30715 (load_signextendhisi_update): Likewise.
30716 (loadsi_update): Likewise.
30717 (loadsf_update): Likewise.
30718 (movsicc_insn): Likewise.
30719 (bset_insn): Likewise.
30720 (bxor_insn): Likewise.
30721 (bclr_insn): Likewise.
30722 (bmsk_insn): Likewise.
30723 (bicsi3_insn): Likewise.
30724 (cmpsi_cc_c_insn): Likewise.
30725 (movsi_ne): Likewise.
30726 (movsi_cond_exec): Likewise.
30727 (clrsbsi2): Likewise.
30728 (norm_f): Likewise.
30729 (normw): Likewise.
30730 (swap): Likewise.
30731 (divaw): Likewise.
30732 (flag): Likewise.
30733 (sr): Likewise.
30734 (kflag): Likewise.
30735 (ffs): Likewise.
30736 (ffs_f): Likewise.
30737 (fls): Likewise.
30738 (call_i): Remove 'S' asm letter, add jli instruction.
30739 (call_value_i): Likewise.
30740 * config/arc/arc.op (mjli-always): New option.
30741 * config/arc/constraints.md (Cji): New constraint.
30742 * config/arc/fpx.md (addsf3_fpx): Remove 'S' from printing asm
30743 operand.
30744 (subsf3_fpx): Likewise.
30745 (mulsf3_fpx): Likewise.
30746 * config/arc/simdext.md (vendrec_insn): Remove 'S' from printing
30747 asm operand.
30748 * doc/extend.texi (ARC): Document 'jli-always' and 'jli-fixed'
30749 function attrbutes.
30750 * doc/invoke.texi (ARC): Document mjli-always option.
30751
30752 2018-01-26 Sebastian Perta <sebastian.perta@renesas.com>
30753
30754 * config/rl78/rl78.c (rl78_addsi3_internal): If operand 2 is const
30755 avoid addition with 0 and use incw and decw where possible.
30756
30757 2018-01-26 Richard Biener <rguenther@suse.de>
30758
30759 PR tree-optimization/81082
30760 * fold-const.c (fold_plusminus_mult_expr): Do not perform the
30761 association if it requires casting to unsigned.
30762 * match.pd ((A * C) +- (B * C) -> (A+-B)): New patterns derived
30763 from fold_plusminus_mult_expr to catch important cases late when
30764 range info is available.
30765
30766 2018-01-26 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
30767
30768 * config/i386/sol2.h (USE_HIDDEN_LINKONCE): Remove.
30769 * configure.ac (hidden_linkonce): New test.
30770 * configure: Regenerate.
30771 * config.in: Regenerate.
30772
30773 2018-01-26 Julia Koval <julia.koval@intel.com>
30774
30775 * config/i386/avx512bitalgintrin.h (_mm512_bitshuffle_epi64_mask,
30776 _mm512_mask_bitshuffle_epi64_mask, _mm256_bitshuffle_epi64_mask,
30777 _mm256_mask_bitshuffle_epi64_mask, _mm_bitshuffle_epi64_mask,
30778 _mm_mask_bitshuffle_epi64_mask): Fix type.
30779 * config/i386/i386-builtin-types.def (UHI_FTYPE_V2DI_V2DI_UHI,
30780 USI_FTYPE_V4DI_V4DI_USI): Remove.
30781 * config/i386/i386-builtin.def (__builtin_ia32_vpshufbitqmb512_mask,
30782 __builtin_ia32_vpshufbitqmb256_mask,
30783 __builtin_ia32_vpshufbitqmb128_mask): Fix types.
30784 * config/i386/i386.c (ix86_expand_args_builtin): Remove old types.
30785 * config/i386/sse.md (VI1_AVX512VLBW): Change types.
30786
30787 2018-01-26 Alan Modra <amodra@gmail.com>
30788
30789 PR target/84033
30790 * config/rs6000/rs6000-p8swap.c (rtx_is_swappable_p): Exclude
30791 UNSPEC_VBPERMQ. Sort other unspecs.
30792
30793 2018-01-25 David Edelsohn <dje.gcc@gmail.com>
30794
30795 * doc/invoke.texi (PowerPC Options): Document 'native' cpu type.
30796
30797 2018-01-25 Jan Hubicka <hubicka@ucw.cz>
30798
30799 PR middle-end/83055
30800 * predict.c (drop_profile): Do not push/pop cfun; update also
30801 node->count.
30802 (handle_missing_profiles): Fix logic looking for zero profiles.
30803
30804 2018-01-25 Jakub Jelinek <jakub@redhat.com>
30805
30806 PR middle-end/83977
30807 * ipa-fnsummary.c (compute_fn_summary): Clear can_change_signature
30808 on functions with #pragma omp declare simd or functions with simd
30809 attribute.
30810 * omp-simd-clone.c (expand_simd_clones): Revert 2018-01-24 change.
30811 * config/i386/i386.c (ix86_simd_clone_compute_vecsize_and_simdlen):
30812 Remove trailing \n from warning_at calls.
30813
30814 2018-01-25 Tom de Vries <tom@codesourcery.com>
30815
30816 PR target/84028
30817 * config/nvptx/nvptx.c (nvptx_single): Add exit insn after noreturn call
30818 for neutered workers.
30819
30820 2018-01-24 Joseph Myers <joseph@codesourcery.com>
30821
30822 PR target/68467
30823 * config/m68k/m68k.c (m68k_promote_function_mode): New function.
30824 (TARGET_PROMOTE_FUNCTION_MODE): New macro.
30825
30826 2018-01-24 Jeff Law <law@redhat.com>
30827
30828 PR target/83994
30829 * i386.c (get_probe_interval): Move to earlier point.
30830 (ix86_compute_frame_layout): If -fstack-clash-protection and
30831 the frame is larger than the probe interval, then use pushes
30832 to save registers rather than reg->mem moves.
30833 (ix86_expand_prologue): Remove conditional for int_registers_saved
30834 assertion.
30835
30836 2018-01-24 Vladimir Makarov <vmakarov@redhat.com>
30837
30838 PR target/84014
30839 * ira-build.c (setup_min_max_allocno_live_range_point): Set up
30840 min/max for never referenced object.
30841
30842 2018-01-24 Jakub Jelinek <jakub@redhat.com>
30843
30844 PR middle-end/83977
30845 * tree.c (free_lang_data_in_decl): Don't clear DECL_ABSTRACT_ORIGIN
30846 here.
30847 * omp-low.c (create_omp_child_function): Remove "omp declare simd"
30848 attributes from DECL_ATTRIBUTES (decl) without affecting
30849 DECL_ATTRIBUTES (current_function_decl).
30850 * omp-simd-clone.c (expand_simd_clones): Ignore DECL_ARTIFICIAL
30851 functions with non-NULL DECL_ABSTRACT_ORIGIN.
30852
30853 2018-01-24 Richard Sandiford <richard.sandiford@linaro.org>
30854
30855 PR tree-optimization/83979
30856 * fold-const.c (fold_comparison): Use constant_boolean_node
30857 instead of boolean_{true,false}_node.
30858
30859 2018-01-24 Jan Hubicka <hubicka@ucw.cz>
30860
30861 * ipa-profile.c (ipa_propagate_frequency_1): Fix logic skipping calls
30862 with zero counts.
30863
30864 2018-01-24 Bill Schmidt <wschmidt@linux.vnet.ibm.com>
30865
30866 * config/rs6000/rs6000.md (*call_indirect_nonlocal_sysv<mode>):
30867 Simplify the clause that sets the length attribute.
30868 (*call_value_indirect_nonlocal_sysv<mode>): Likewise.
30869 (*sibcall_nonlocal_sysv<mode>): Clean up code block; simplify the
30870 clause that sets the length attribute.
30871 (*sibcall_value_nonlocal_sysv<mode>): Likewise.
30872
30873 2018-01-24 Tom de Vries <tom@codesourcery.com>
30874
30875 PR target/83589
30876 * config/nvptx/nvptx.c (WORKAROUND_PTXJIT_BUG_2): Define to 1.
30877 (nvptx_pc_set, nvptx_condjump_label): New function. Copy from jump.c.
30878 Add strict parameter.
30879 (prevent_branch_around_nothing): Insert dummy insn between branch to
30880 label and label with no ptx insn inbetween.
30881 * config/nvptx/nvptx.md (define_insn "fake_nop"): New insn.
30882
30883 2018-01-24 Tom de Vries <tom@codesourcery.com>
30884
30885 PR target/81352
30886 * config/nvptx/nvptx.c (nvptx_single): Add exit insn after noreturn call
30887 for neutered threads in warp.
30888 * config/nvptx/nvptx.md (define_insn "exit"): New insn.
30889
30890 2018-01-24 Richard Biener <rguenther@suse.de>
30891
30892 PR tree-optimization/83176
30893 * tree-chrec.c (chrec_fold_plus_1): Handle (signed T){(T) .. }
30894 operands.
30895
30896 2018-01-24 Richard Biener <rguenther@suse.de>
30897
30898 PR tree-optimization/82819
30899 * graphite-isl-ast-to-gimple.c (binary_op_to_tree): Avoid
30900 code generating pluses that are no-ops in the target precision.
30901
30902 2018-01-24 Richard Biener <rguenther@suse.de>
30903
30904 PR middle-end/84000
30905 * tree-cfg.c (replace_loop_annotate): Handle annot_expr_parallel_kind.
30906
30907 2018-01-23 Jan Hubicka <hubicka@ucw.cz>
30908
30909 * cfgcleanup.c (try_crossjump_to_edge): Use combine_with_count
30910 to merge probabilities.
30911 * predict.c (probably_never_executed): Also mark as cold functions
30912 with global 0 profile and guessed local profile.
30913 * profile-count.c (profile_probability::combine_with_count): New
30914 member function.
30915 * profile-count.h (profile_probability::operator*,
30916 profile_probability::operator*=, profile_probability::operator/,
30917 profile_probability::operator/=): Reduce precision to adjusted
30918 and set value to guessed on contradictory divisions.
30919 (profile_probability::combine_with_freq): Remove.
30920 (profile_probability::combine_wiht_count): Declare.
30921 (profile_count::force_nonzero):: Set to adjusted.
30922 (profile_count::probability_in):: Set quality to adjusted.
30923 * tree-ssa-tail-merge.c (replace_block_by): Use
30924 combine_with_count.
30925
30926 2018-01-23 Andrew Waterman <andrew@sifive.com>
30927 Jim Wilson <jimw@sifive.com>
30928
30929 * config/riscv/riscv.c (riscv_stack_boundary): New.
30930 (riscv_option_override): Set riscv_stack_boundary. Handle
30931 riscv_preferred_stack_boundary_arg.
30932 * config/riscv/riscv.h (MIN_STACK_BOUNDARY, ABI_STACK_BOUNDARY): New.
30933 (BIGGEST_ALIGNMENT): Set to STACK_BOUNDARY.
30934 (STACK_BOUNDARY): Set to riscv_stack_boundary.
30935 (RISCV_STACK_ALIGN): Use STACK_BOUNDARY.
30936 * config/riscv/riscv.opt (mpreferred-stack-boundary): New.
30937 * doc/invoke.tex (RISC-V Options): Add -mpreferred-stack-boundary.
30938
30939 2018-01-23 H.J. Lu <hongjiu.lu@intel.com>
30940
30941 PR target/83905
30942 * config/i386/i386.c (ix86_expand_prologue): Use cost reference
30943 of struct ix86_frame.
30944 (ix86_expand_epilogue): Likewise. Add a local variable for
30945 the reg_save_offset field in struct ix86_frame.
30946
30947 2018-01-23 Bin Cheng <bin.cheng@arm.com>
30948
30949 PR tree-optimization/82604
30950 * tree-loop-distribution.c (enum partition_kind): New enum item
30951 PKIND_PARTIAL_MEMSET.
30952 (partition_builtin_p): Support above new enum item.
30953 (generate_code_for_partition): Ditto.
30954 (compute_access_range): Differentiate cases that equality can be
30955 proven at all loops, the innermost loops or no loops.
30956 (classify_builtin_st, classify_builtin_ldst): Adjust call to above
30957 function. Set PKIND_PARTIAL_MEMSET for partition appropriately.
30958 (finalize_partitions, distribute_loop): Don't fuse partition of
30959 PKIND_PARTIAL_MEMSET kind when distributing 3-level loop nest.
30960 (prepare_perfect_loop_nest): Distribute 3-level loop nest only if
30961 parloop is enabled.
30962
30963 2018-01-23 Martin Liska <mliska@suse.cz>
30964
30965 * predict.def (PRED_INDIR_CALL): Set probability to PROB_EVEN in
30966 order to ignore the predictor.
30967 (PRED_POLYMORPHIC_CALL): Likewise.
30968 (PRED_RECURSIVE_CALL): Likewise.
30969
30970 2018-01-23 Martin Liska <mliska@suse.cz>
30971
30972 * tree-profile.c (tree_profiling): Print function header to
30973 aware reader which function we are working on.
30974 * value-prof.c (gimple_find_values_to_profile): Do not print
30975 not interesting value histograms.
30976
30977 2018-01-23 Martin Liska <mliska@suse.cz>
30978
30979 * profile-count.h (enum profile_quality): Add
30980 profile_uninitialized as the first value. Do not number values
30981 as they are zero based.
30982 (profile_count::verify): Update sanity check.
30983 (profile_probability::verify): Likewise.
30984
30985 2018-01-23 Nathan Sidwell <nathan@acm.org>
30986
30987 * doc/invoke.texi (ffor-scope): Deprecate.
30988
30989 2018-01-23 David Malcolm <dmalcolm@redhat.com>
30990
30991 PR tree-optimization/83510
30992 * domwalk.c (set_all_edges_as_executable): New function.
30993 (dom_walker::dom_walker): Convert bool param
30994 "skip_unreachable_blocks" to enum reachability. Move setup of
30995 edge flags to set_all_edges_as_executable and only do it when
30996 reachability is REACHABLE_BLOCKS.
30997 * domwalk.h (enum dom_walker::reachability): New enum.
30998 (dom_walker::dom_walker): Convert bool param
30999 "skip_unreachable_blocks" to enum reachability.
31000 (set_all_edges_as_executable): New decl.
31001 * graphite-scop-detection.c (gather_bbs::gather_bbs): Convert
31002 from false for "skip_unreachable_blocks" to ALL_BLOCKS for
31003 "reachability".
31004 * tree-ssa-dom.c (dom_opt_dom_walker::dom_opt_dom_walker): Likewise,
31005 but converting true to REACHABLE_BLOCKS.
31006 * tree-ssa-sccvn.c (sccvn_dom_walker::sccvn_dom_walker): Likewise.
31007 * tree-vrp.c
31008 (check_array_bounds_dom_walker::check_array_bounds_dom_walker):
31009 Likewise, but converting it to REACHABLE_BLOCKS_PRESERVING_FLAGS.
31010 (vrp_dom_walker::vrp_dom_walker): Likewise, but converting it to
31011 REACHABLE_BLOCKS.
31012 (vrp_prop::vrp_finalize): Call set_all_edges_as_executable
31013 if check_all_array_refs will be called.
31014
31015 2018-01-23 David Malcolm <dmalcolm@redhat.com>
31016
31017 * tree.c (selftest::test_location_wrappers): Add more test
31018 coverage.
31019
31020 2018-01-23 David Malcolm <dmalcolm@redhat.com>
31021
31022 * sbitmap.c (selftest::test_set_range): Fix memory leaks.
31023 (selftest::test_bit_in_range): Likewise.
31024
31025 2018-01-23 Richard Sandiford <richard.sandiford@linaro.org>
31026
31027 PR testsuite/83888
31028 * doc/sourcebuild.texi (vect_float): Say that the selector
31029 only describes the situation when -funsafe-math-optimizations is on.
31030 (vect_float_strict): Document.
31031
31032 2018-01-23 Richard Sandiford <richard.sandiford@linaro.org>
31033
31034 PR tree-optimization/83965
31035 * tree-vect-patterns.c (vect_reassociating_reduction_p): New function.
31036 (vect_recog_dot_prod_pattern, vect_recog_sad_pattern): Use it
31037 instead of checking only for a reduction.
31038 (vect_recog_widen_sum_pattern): Likewise.
31039
31040 2018-01-23 Jan Hubicka <hubicka@ucw.cz>
31041
31042 * predict.c (probably_never_executed): Only use precise profile info.
31043 (compute_function_frequency): Skip after inlining hack since we now
31044 have quality checking.
31045
31046 2018-01-23 Jan Hubicka <hubicka@ucw.cz>
31047
31048 * profile-count.h (profile_probability::very_unlikely,
31049 profile_probability::unlikely, profile_probability::even): Set
31050 precision to guessed.
31051
31052 2018-01-23 Richard Biener <rguenther@suse.de>
31053
31054 PR tree-optimization/83963
31055 * graphite-scop-detection.c (scop_detection::harmful_loop_in_region):
31056 Properly terminate dominator walk when crossing the exit edge not
31057 when visiting its source block.
31058
31059 2018-01-23 Jakub Jelinek <jakub@redhat.com>
31060
31061 PR c++/83918
31062 * tree.c (maybe_wrap_with_location): Use NON_LVALUE_EXPR rather than
31063 VIEW_CONVERT_EXPR to wrap CONST_DECLs.
31064
31065 2018-01-22 Jakub Jelinek <jakub@redhat.com>
31066
31067 PR tree-optimization/83957
31068 * omp-expand.c (expand_omp_for_generic): Ignore virtual PHIs. Remove
31069 semicolon after for body surrounded by braces.
31070
31071 PR tree-optimization/83081
31072 * profile-count.h (profile_probability::split): New method.
31073 * dojump.c (do_jump_1) <case TRUTH_ANDIF_EXPR, case TRUTH_ORIF_EXPR>:
31074 Use profile_probability::split.
31075 (do_compare_rtx_and_jump): Fix adjustment of probabilities
31076 when splitting a single conditional jump into 2.
31077
31078 2018-01-22 David Malcolm <dmalcolm@redhat.com>
31079
31080 PR tree-optimization/69452
31081 * tree-ssa-loop-im.c (class move_computations_dom_walker): Remove
31082 decl.
31083
31084 2018-01-22 Sebastian Perta <sebastian.perta@renesas.com>
31085
31086 * config/rl78/rl78-expand.md (bswaphi2): New define_expand.
31087 * config/rl78/rl78-virt.md (*bswaphi2_virt): New define_insn.
31088 * config/rl78/rl78-real.md (*bswaphi2_real): New define_insn.
31089
31090 2018-01-22 Sebastian Perta <sebastian.perta@renesas.com>
31091
31092 * config/rl78/rl78-protos.h (rl78_split_movdi): New function
31093 declaration.
31094 * config/rl78/rl78.md (movdi): New define_expand.
31095 * config/rl78/rl78.c (rl78_split_movdi): New function.
31096
31097 2018-01-22 Michael Meissner <meissner@linux.vnet.ibm.com>
31098
31099 PR target/83862
31100 * config/rs6000/rs6000-protos.h (rs6000_split_signbit): Delete,
31101 no longer used.
31102 * config/rs6000/rs6000.c (rs6000_split_signbit): Likewise.
31103 * config/rs6000/rs6000.md (signbit<mode>2): Change code for IEEE
31104 128-bit to produce an UNSPEC move to get the double word with the
31105 signbit and then a shift directly to do signbit.
31106 (signbit<mode>2_dm): Replace old IEEE 128-bit signbit
31107 implementation with a new version that just does either a direct
31108 move or a regular move. Move memory interface to separate insns.
31109 Move insns so they are next to the expander.
31110 (signbit<mode>2_dm_mem_be): New combiner insns to combine load
31111 with signbit move. Split big and little endian case.
31112 (signbit<mode>2_dm_mem_le): Likewise.
31113 (signbit<mode>2_dm_<su>ext): Delete, no longer used.
31114 (signbit<mode>2_dm2): Likewise.
31115
31116 2018-01-22 Sebastian Perta <sebastian.perta@renesas.com>
31117
31118 * config/rl78/rl78.md (anddi3): New define_expand.
31119
31120 2018-01-22 Sebastian Perta <sebastian.perta@renesas.com>
31121
31122 * config/rl78/rl78.md (umindi3): New define_expand.
31123
31124 2018-01-22 Sebastian Perta <sebastian.perta@renesas.com>
31125
31126 * config/rl78/rl78.md (smindi3): New define_expand.
31127
31128 2018-01-22 Sebastian Perta <sebastian.perta@renesas.com>
31129
31130 * config/rl78/rl78.md (smaxdi3): New define_expand.
31131
31132 2018-01-22 Carl Love <cel@us.ibm.com>
31133
31134 * config/rs6000/rs6000-builtin.def (ST_ELEMREV_V1TI, LD_ELEMREV_V1TI,
31135 LVX_V1TI): Add macro expansion.
31136 * config/rs6000/rs6000-c.c (altivec_builtin_types): Add argument
31137 definitions for VSX_BUILTIN_VEC_XST_BE, VSX_BUILTIN_VEC_ST,
31138 VSX_BUILTIN_VEC_XL, LD_ELEMREV_V1TI builtins.
31139 * config/rs6000/rs6000-p8swap.c (insn_is_swappable_p);
31140 Change check to determine if the instruction is a byte reversing
31141 entry. Fix typo in comment.
31142 * config/rs6000/rs6000.c (altivec_expand_builtin): Add case entry
31143 for VSX_BUILTIN_ST_ELEMREV_V1TI and VSX_BUILTIN_LD_ELEMREV_V1TI.
31144 Add def_builtin calls for new builtins.
31145 * config/rs6000/vsx.md (vsx_st_elemrev_v1ti, vsx_ld_elemrev_v1ti):
31146 Add define_insn expansion.
31147
31148 2018-01-22 Sebastian Perta <sebastian.perta@renesas.com>
31149
31150 * config/rl78/rl78.md (umaxdi3): New define_expand.
31151
31152 2018-01-22 Sebastian Perta <sebastian.perta@renesas.com>
31153
31154 * config/rl78/rl78.c (rl78_note_reg_set): Fixed dead reg check
31155 for non-QImode registers.
31156
31157 2018-01-22 Richard Biener <rguenther@suse.de>
31158
31159 PR tree-optimization/83963
31160 * graphite-scop-detection.c (scop_detection::get_sese): Delay
31161 including the loop exit block.
31162 (scop_detection::merge_sese): Likewise.
31163 (scop_detection::add_scop): Do it here instead.
31164
31165 2018-01-22 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
31166
31167 * doc/sourcebuild.texi (arm_softfloat): Document.
31168
31169 2018-01-21 John David Anglin <danglin@gcc.gnu.org>
31170
31171 PR gcc/77734
31172 * config/pa/pa.c (pa_function_ok_for_sibcall): Use
31173 targetm.binds_local_p instead of TREE_PUBLIC to check local binding.
31174 Move TARGET_PORTABLE_RUNTIME check after TARGET_64BIT check.
31175
31176 2018-01-21 Bill Schmidt <wschmidt@linux.vnet.ibm.com>
31177 David Edelsohn <dje.gcc@gmail.com>
31178
31179 PR target/83946
31180 * config/rs6000/rs6000.md (*call_indirect_nonlocal_sysv<mode>):
31181 Change "crset eq" to "crset 2".
31182 (*call_value_indirect_nonlocal_sysv<mode>): Likewise.
31183 (*call_indirect_aix<mode>_nospec): Likewise.
31184 (*call_value_indirect_aix<mode>_nospec): Likewise.
31185 (*call_indirect_elfv2<mode>_nospec): Likewise.
31186 (*call_value_indirect_elfv2<mode>_nospec): Likewise.
31187 (*sibcall_nonlocal_sysv<mode>): Change "crset eq" to "crset 2";
31188 change assembly output from . to $.
31189 (*sibcall_value_nonlocal_sysv<mode>): Likewise.
31190 (indirect_jump<mode>_nospec): Change assembly output from . to $.
31191 (*tablejump<mode>_internal1_nospec): Likewise.
31192
31193 2018-01-21 Oleg Endo <olegendo@gcc.gnu.org>
31194
31195 PR target/80870
31196 * config/sh/sh_optimize_sett_clrt.cc:
31197 Use INCLUDE_ALGORITHM and INCLUDE_VECTOR instead of direct includes.
31198
31199 2018-01-20 Richard Sandiford <richard.sandiford@linaro.org>
31200
31201 PR tree-optimization/83940
31202 * tree-vect-stmts.c (vect_truncate_gather_scatter_offset): Set
31203 offset_dt to vect_constant_def rather than vect_unknown_def_type.
31204 (vect_check_load_store_mask): Add a mask_dt_out parameter and
31205 use it to pass back the definition type.
31206 (vect_check_store_rhs): Likewise rhs_dt_out.
31207 (vect_build_gather_load_calls): Add a mask_dt argument and use
31208 it instead of a call to vect_is_simple_use.
31209 (vectorizable_store): Update calls to vect_check_load_store_mask
31210 and vect_check_store_rhs. Use the dt returned by the latter instead
31211 of scatter_src_dt. Use the cached mask_dt and gs_info.offset_dt
31212 instead of calls to vect_is_simple_use. Pass the scalar rather
31213 than the vector operand to vect_is_simple_use when handling
31214 second and subsequent copies of an rhs value.
31215 (vectorizable_load): Update calls to vect_check_load_store_mask
31216 and vect_build_gather_load_calls. Use the cached mask_dt and
31217 gs_info.offset_dt instead of calls to vect_is_simple_use.
31218
31219 2018-01-20 Jakub Jelinek <jakub@redhat.com>
31220
31221 PR middle-end/83945
31222 * tree-emutls.c: Include gimplify.h.
31223 (lower_emutls_2): New function.
31224 (lower_emutls_1): If ADDR_EXPR is a gimple invariant and walk_tree
31225 with lower_emutls_2 callback finds some TLS decl in it, unshare_expr
31226 it before further processing.
31227
31228 PR target/83930
31229 * simplify-rtx.c (simplify_binary_operation_1) <case UMOD>: Use
31230 UINTVAL (trueop1) instead of INTVAL (op1).
31231
31232 2018-01-19 Jakub Jelinek <jakub@redhat.com>
31233
31234 PR debug/81570
31235 PR debug/83728
31236 * dwarf2cfi.c (DEFAULT_INCOMING_FRAME_SP_OFFSET): Define to
31237 INCOMING_FRAME_SP_OFFSET if not defined.
31238 (scan_trace): Add ENTRY argument. If true and
31239 DEFAULT_INCOMING_FRAME_SP_OFFSET != INCOMING_FRAME_SP_OFFSET,
31240 emit a note to adjust the CFA offset.
31241 (create_cfi_notes): Adjust scan_trace callers.
31242 (create_cie_data): Use DEFAULT_INCOMING_FRAME_SP_OFFSET rather than
31243 INCOMING_FRAME_SP_OFFSET in the CIE.
31244 * config/i386/i386.h (DEFAULT_INCOMING_FRAME_SP_OFFSET): Define.
31245 * config/stormy16/stormy16.h (DEFAULT_INCOMING_FRAME_SP_OFFSET):
31246 Likewise.
31247 * doc/tm.texi.in (DEFAULT_INCOMING_FRAME_SP_OFFSET): Document.
31248 * doc/tm.texi: Regenerated.
31249
31250 2018-01-19 Andreas Krebbel <krebbel@linux.vnet.ibm.com>
31251
31252 PR rtl-optimization/83147
31253 * lra-constraints.c (remove_inheritance_pseudos): Use
31254 lra_substitute_pseudo_within_insn.
31255
31256 2018-01-19 Tom de Vries <tom@codesourcery.com>
31257 Cesar Philippidis <cesar@codesourcery.com>
31258
31259 PR target/83920
31260 * config/nvptx/nvptx.c (nvptx_single): Fix jit workaround.
31261
31262 2018-01-19 Cesar Philippidis <cesar@codesourcery.com>
31263
31264 PR target/83790
31265 * config/nvptx/nvptx.c (output_init_frag): Don't use generic address
31266 spaces for function labels.
31267
31268 2018-01-19 Martin Liska <mliska@suse.cz>
31269
31270 * predict.def (PRED_LOOP_EXIT): Change from 85 to 89.
31271 (PRED_LOOP_EXIT_WITH_RECURSION): Change from 72 to 78.
31272 (PRED_LOOP_EXTRA_EXIT): Change from 83 to 67.
31273 (PRED_OPCODE_POSITIVE): Change from 64 to 59.
31274 (PRED_TREE_OPCODE_POSITIVE): Change from 64 to 59.
31275 (PRED_CONST_RETURN): Change from 69 to 65.
31276 (PRED_NULL_RETURN): Change from 91 to 71.
31277 (PRED_LOOP_IV_COMPARE_GUESS): Change from 98 to 64.
31278 (PRED_LOOP_GUARD): Change from 66 to 73.
31279
31280 2018-01-19 Martin Liska <mliska@suse.cz>
31281
31282 * predict.c (predict_insn_def): Add new assert.
31283 (struct branch_predictor): Change type to signed integer.
31284 (test_prediction_value_range): Amend test to cover
31285 PROB_UNINITIALIZED.
31286 * predict.def (PRED_LOOP_ITERATIONS): Use the new constant.
31287 (PRED_LOOP_ITERATIONS_GUESSED): Likewise.
31288 (PRED_LOOP_ITERATIONS_MAX): Likewise.
31289 (PRED_LOOP_IV_COMPARE): Likewise.
31290 * predict.h (PROB_UNINITIALIZED): Define new constant.
31291
31292 2018-01-19 Martin Liska <mliska@suse.cz>
31293
31294 * predict.c (dump_prediction): Add new format for
31295 analyze_brprob.py script which is enabled with -details
31296 suboption.
31297 * profile-count.h (precise_p): New function.
31298
31299 2018-01-19 Richard Sandiford <richard.sandiford@linaro.org>
31300
31301 PR tree-optimization/83922
31302 * tree-vect-loop.c (vect_verify_full_masking): Return false if
31303 there are no statements that need masking.
31304 (vect_active_double_reduction_p): New function.
31305 (vect_analyze_loop_operations): Use it when handling phis that
31306 are not in the loop header.
31307
31308 2018-01-19 Richard Sandiford <richard.sandiford@linaro.org>
31309
31310 PR tree-optimization/83914
31311 * tree-vect-loop.c (vectorizable_induction): Don't convert
31312 init_expr or apply the peeling adjustment for inductions
31313 that are nested within the vectorized loop.
31314
31315 2018-01-19 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
31316
31317 * config/arm/thumb2.md (*thumb2_negsi2_short): Use RSB mnemonic
31318 instead of NEG.
31319
31320 2018-01-18 Jakub Jelinek <jakub@redhat.com>
31321
31322 PR sanitizer/81715
31323 PR testsuite/83882
31324 * function.h (gimplify_parameters): Add gimple_seq * argument.
31325 * function.c: Include gimple.h and options.h.
31326 (gimplify_parameters): Add cleanup argument, add CLOBBER stmts
31327 for the added local temporaries if needed.
31328 * gimplify.c (gimplify_body): Adjust gimplify_parameters caller,
31329 if there are any parameter cleanups, wrap whole body into a
31330 try/finally with the cleanups.
31331
31332 2018-01-18 Wilco Dijkstra <wdijkstr@arm.com>
31333
31334 PR target/82964
31335 * config/aarch64/aarch64.c (aarch64_legitimate_constant_p):
31336 Use GET_MODE_CLASS for scalar floating point.
31337
31338 2018-01-18 Jan Hubicka <hubicka@ucw.cz>
31339
31340 PR ipa/82256
31341 patch by PaX Team
31342 * cgraphclones.c (cgraph_node::create_version_clone_with_body):
31343 Fix call of call_cgraph_insertion_hooks.
31344
31345 2018-01-18 Martin Sebor <msebor@redhat.com>
31346
31347 * doc/invoke.texi (-Wclass-memaccess): Tweak text.
31348
31349 2018-01-18 Jan Hubicka <hubicka@ucw.cz>
31350
31351 PR ipa/83619
31352 * cgraph.c (cgraph_edge::redirect_call_stmt_to_callee): Update edge
31353 frequencies.
31354
31355 2018-01-18 Boris Kolpackov <boris@codesynthesis.com>
31356
31357 PR other/70268
31358 * common.opt: (-ffile-prefix-map): New option.
31359 * opts.c (common_handle_option): Defer it.
31360 * opts-global.c (handle_common_deferred_options): Handle it.
31361 * debug.h (remap_debug_filename, add_debug_prefix_map): Move to...
31362 * file-prefix-map.h: New file.
31363 (remap_debug_filename, add_debug_prefix_map): ...here.
31364 (add_macro_prefix_map, add_file_prefix_map, remap_macro_filename): New.
31365 * final.c (debug_prefix_map, add_debug_prefix_map
31366 remap_debug_filename): Move to...
31367 * file-prefix-map.c: New file.
31368 (file_prefix_map, add_prefix_map, remap_filename) ...here and rename,
31369 generalize, get rid of alloca(), use strrchr() instead of strchr().
31370 (add_macro_prefix_map, add_debug_prefix_map, add_file_prefix_map):
31371 Implement in terms of add_prefix_map().
31372 (remap_macro_filename, remap_debug_filename): Implement in term of
31373 remap_filename().
31374 * Makefile.in (OBJS, PLUGIN_HEADERS): Add new files.
31375 * builtins.c (fold_builtin_FILE): Call remap_macro_filename().
31376 * dbxout.c: Include file-prefix-map.h.
31377 * varasm.c: Likewise.
31378 * vmsdbgout.c: Likewise.
31379 * xcoffout.c: Likewise.
31380 * dwarf2out.c: Likewise plus omit new options from DW_AT_producer.
31381 * doc/cppopts.texi (-fmacro-prefix-map): Document.
31382 * doc/invoke.texi (-ffile-prefix-map): Document.
31383 (-fdebug-prefix-map): Update description.
31384
31385 2018-01-18 Martin Liska <mliska@suse.cz>
31386
31387 * config/i386/i386.c (indirect_thunk_name): Document that also
31388 lfence is emitted.
31389 (output_indirect_thunk): Document why both instructions
31390 (pause and lfence) are generated.
31391
31392 2018-01-18 Richard Biener <rguenther@suse.de>
31393
31394 PR tree-optimization/83887
31395 * graphite-scop-detection.c
31396 (scop_detection::get_nearest_dom_with_single_entry): Remove.
31397 (scop_detection::get_nearest_pdom_with_single_exit): Likewise.
31398 (scop_detection::merge_sese): Re-implement with a flood-fill
31399 algorithm that properly finds a SESE region if it exists.
31400
31401 2018-01-18 Jakub Jelinek <jakub@redhat.com>
31402
31403 PR c/61240
31404 * match.pd ((P + A) - P, P - (P + A), (P + A) - (P + B)): For
31405 pointer_diff optimizations use view_convert instead of convert.
31406
31407 2018-01-17 Bill Schmidt <wschmidt@linux.vnet.ibm.com>
31408
31409 * config/rs6000/rs6000.md (*call_indirect_nonlocal_sysv<mode>):
31410 Generate different code for -mno-speculate-indirect-jumps.
31411 (*call_value_indirect_nonlocal_sysv<mode>): Likewise.
31412 (*call_indirect_aix<mode>): Disable for
31413 -mno-speculate-indirect-jumps.
31414 (*call_indirect_aix<mode>_nospec): New define_insn.
31415 (*call_value_indirect_aix<mode>): Disable for
31416 -mno-speculate-indirect-jumps.
31417 (*call_value_indirect_aix<mode>_nospec): New define_insn.
31418 (*sibcall_nonlocal_sysv<mode>): Generate different code for
31419 -mno-speculate-indirect-jumps.
31420 (*sibcall_value_nonlocal_sysv<mode>): Likewise.
31421
31422 2018-01-17 Michael Meissner <meissner@linux.vnet.ibm.com>
31423
31424 * config/rs6000/rs6000.c (rs6000_emit_move): If we load or store a
31425 long double type, set the flags for noting the default long double
31426 type, even if we don't pass or return a long double type.
31427
31428 2018-01-17 Jan Hubicka <hubicka@ucw.cz>
31429
31430 PR ipa/83051
31431 * ipa-inline.c (flatten_function): Do not overwrite final inlining
31432 failure.
31433
31434 2018-01-17 Will Schmidt <will_schmidt@vnet.ibm.com>
31435
31436 * config/rs6000/rs6000.c (rs6000_gimple_builtin): Add gimple folding
31437 support for merge[hl].
31438 (fold_mergehl_helper): New helper function.
31439 (tree-vector-builder.h): New #include for tree_vector_builder usage.
31440 * config/rs6000/altivec.md (altivec_vmrghw_direct): Add xxmrghw insn.
31441 (altivec_vmrglw_direct): Add xxmrglw insn.
31442
31443 2018-01-17 Andrew Waterman <andrew@sifive.com>
31444
31445 * config/riscv/riscv.c (riscv_conditional_register_usage): If
31446 UNITS_PER_FP_ARG is 0, set call_used_regs to 1 for all FP regs.
31447
31448 2018-01-17 David Malcolm <dmalcolm@redhat.com>
31449
31450 PR lto/83121
31451 * ipa-devirt.c (add_type_duplicate): When comparing memory layout,
31452 call the lto_location_cache before reading the
31453 DECL_SOURCE_LOCATION of the types.
31454
31455 2018-01-17 Wilco Dijkstra <wdijkstr@arm.com>
31456 Richard Sandiford <richard.sandiford@linaro.org>
31457
31458 * config/aarch64/aarch64.md (movti_aarch64): Use Uti constraint.
31459 * config/aarch64/aarch64.c (aarch64_mov128_immediate): New function.
31460 (aarch64_legitimate_constant_p): Just support CONST_DOUBLE
31461 SF/DF/TF mode to avoid creating illegal CONST_WIDE_INT immediates.
31462 * config/aarch64/aarch64-protos.h (aarch64_mov128_immediate):
31463 Add declaration.
31464 * config/aarch64/constraints.md (aarch64_movti_operand):
31465 Limit immediates.
31466 * config/aarch64/predicates.md (Uti): Add new constraint.
31467
31468 2018-01-17 Carl Love <cel@us.ibm.com>
31469
31470 * config/rs6000/vsx.md (define_expand xl_len_r,
31471 define_expand stxvl, define_expand *stxvl): Add match_dup argument.
31472 (define_insn): Add, match_dup 1 argument to define_insn stxvll and
31473 lxvll.
31474 (define_expand, define_insn): Move the shift left from the
31475 define_insn to the define_expand for lxvl and stxvl instructions.
31476 * config/rs6000/rs6000-builtin.def (BU_P9V_64BIT_VSX_2): Change LXVL
31477 and XL_LEN_R definitions to PURE.
31478
31479 2018-01-17 Uros Bizjak <ubizjak@gmail.com>
31480
31481 * config/i386/i386.c (indirect_thunk_name): Declare regno
31482 as unsigned int. Compare regno with INVALID_REGNUM.
31483 (output_indirect_thunk): Ditto.
31484 (output_indirect_thunk_function): Ditto.
31485 (ix86_code_end): Declare regno as unsigned int. Use INVALID_REGNUM
31486 in the call to output_indirect_thunk_function.
31487
31488 2018-01-17 Richard Sandiford <richard.sandiford@linaro.org>
31489
31490 PR middle-end/83884
31491 * expr.c (expand_expr_real_1): Use the size of GET_MODE (op0)
31492 rather than the size of inner_type to determine the stack slot size
31493 when handling VIEW_CONVERT_EXPRs on strict-alignment targets.
31494
31495 2018-01-16 Sebastian Peryt <sebastian.peryt@intel.com>
31496
31497 PR target/83546
31498 * config/i386/i386.c (ix86_option_override_internal): Add PTA_RDRND
31499 to PTA_SILVERMONT.
31500
31501 2018-01-16 Michael Meissner <meissner@linux.vnet.ibm.com>
31502
31503 * config.gcc (powerpc*-linux*-*): Add support for 64-bit little
31504 endian Linux systems to optionally enable multilibs for selecting
31505 the long double type if the user configured an explicit type.
31506 * config/rs6000/rs6000.h (TARGET_IEEEQUAD_MULTILIB): Indicate we
31507 have no long double multilibs if not defined.
31508 * config/rs6000/rs6000.c (rs6000_option_override_internal): Do not
31509 warn if the user used -mabi={ieee,ibm}longdouble and we built
31510 multilibs for long double.
31511 * config/rs6000/linux64.h (MULTILIB_DEFAULTS_IEEE): Define as the
31512 appropriate multilib option.
31513 (MULTILIB_DEFAULTS): Add MULTILIB_DEFAULTS_IEEE to the default
31514 multilib options.
31515 * config/rs6000/t-ldouble-linux64le-ibm: New configuration files
31516 for building long double multilibs.
31517 * config/rs6000/t-ldouble-linux64le-ieee: Likewise.
31518
31519 2018-01-16 John David Anglin <danglin@gcc.gnu.org>
31520
31521 * config.gcc (hppa*-*-linux*): Change callee copies ABI to caller
31522 copies.
31523
31524 * config/pa.h (MALLOC_ABI_ALIGNMENT): Set 32-bit alignment default to
31525 64 bits.
31526 * config/pa/pa32-linux.h (MALLOC_ABI_ALIGNMENT): Set alignment to
31527 128 bits.
31528
31529 * config/pa/som.h (ASM_DECLARE_FUNCTION_NAME): Cleanup type and mode
31530 variables.
31531
31532 * config/pa/pa.c (pa_function_arg_size): Apply CEIL to GET_MODE_SIZE
31533 return value.
31534
31535 2018-01-16 Eric Botcazou <ebotcazou@adacore.com>
31536
31537 * gimple-ssa-warn-restrict.c (builtin_memref::builtin_memref): For an
31538 ADDR_EXPR, do not count the offset of a COMPONENT_REF twice.
31539
31540 2018-01-16 Kelvin Nilsen <kelvin@gcc.gnu.org>
31541
31542 * config/rs6000/rs6000-p8swap.c (rs6000_gen_stvx): Generate
31543 different rtl trees depending on TARGET_64BIT.
31544 (rs6000_gen_lvx): Likewise.
31545
31546 2018-01-16 Eric Botcazou <ebotcazou@adacore.com>
31547
31548 * config/visium/visium.md (nop): Tweak comment.
31549 (hazard_nop): Likewise.
31550
31551 2018-01-16 Bill Schmidt <wschmidt@linux.vnet.ibm.com>
31552
31553 * config/rs6000/rs6000.c (rs6000_opt_vars): Add entry for
31554 -mspeculate-indirect-jumps.
31555 * config/rs6000/rs6000.md (*call_indirect_elfv2<mode>): Disable
31556 for -mno-speculate-indirect-jumps.
31557 (*call_indirect_elfv2<mode>_nospec): New define_insn.
31558 (*call_value_indirect_elfv2<mode>): Disable for
31559 -mno-speculate-indirect-jumps.
31560 (*call_value_indirect_elfv2<mode>_nospec): New define_insn.
31561 (indirect_jump): Emit different RTL for
31562 -mno-speculate-indirect-jumps.
31563 (*indirect_jump<mode>): Disable for
31564 -mno-speculate-indirect-jumps.
31565 (*indirect_jump<mode>_nospec): New define_insn.
31566 (tablejump): Emit different RTL for
31567 -mno-speculate-indirect-jumps.
31568 (tablejumpsi): Disable for -mno-speculate-indirect-jumps.
31569 (tablejumpsi_nospec): New define_expand.
31570 (tablejumpdi): Disable for -mno-speculate-indirect-jumps.
31571 (tablejumpdi_nospec): New define_expand.
31572 (*tablejump<mode>_internal1): Disable for
31573 -mno-speculate-indirect-jumps.
31574 (*tablejump<mode>_internal1_nospec): New define_insn.
31575 * config/rs6000/rs6000.opt (mspeculate-indirect-jumps): New
31576 option.
31577
31578 2018-01-16 Artyom Skrobov tyomitch@gmail.com
31579
31580 * caller-save.c (insert_save): Drop unnecessary parameter. All
31581 callers updated.
31582
31583 2018-01-16 Jakub Jelinek <jakub@redhat.com>
31584 Richard Biener <rguenth@suse.de>
31585
31586 PR libgomp/83590
31587 * gimplify.c (gimplify_one_sizepos): For is_gimple_constant (expr)
31588 return early, inline manually is_gimple_sizepos. Make sure if we
31589 call gimplify_expr we don't end up with a gimple constant.
31590 * tree.c (variably_modified_type_p): Don't return true for
31591 is_gimple_constant (_t). Inline manually is_gimple_sizepos.
31592 * gimplify.h (is_gimple_sizepos): Remove.
31593
31594 2018-01-16 Richard Sandiford <richard.sandiford@linaro.org>
31595
31596 PR tree-optimization/83857
31597 * tree-vect-loop.c (vect_analyze_loop_operations): Don't call
31598 vectorizable_live_operation for pure SLP statements.
31599 (vectorizable_live_operation): Handle PHIs.
31600
31601 2018-01-16 Richard Biener <rguenther@suse.de>
31602
31603 PR tree-optimization/83867
31604 * tree-vect-stmts.c (vect_transform_stmt): Precompute
31605 nested_in_vect_loop_p since the scalar stmt may get invalidated.
31606
31607 2018-01-16 Jakub Jelinek <jakub@redhat.com>
31608
31609 PR c/83844
31610 * stor-layout.c (handle_warn_if_not_align): Use byte_position and
31611 multiple_of_p instead of unchecked tree_to_uhwi and UHWI check.
31612 If off is not INTEGER_CST, issue a may not be aligned warning
31613 rather than isn't aligned. Use isn%'t rather than isn't.
31614 * fold-const.c (multiple_of_p) <case BIT_AND_EXPR>: Don't fall through
31615 into MULT_EXPR.
31616 <case MULT_EXPR>: Improve the case when bottom and one of the
31617 MULT_EXPR operands are INTEGER_CSTs and bottom is multiple of that
31618 operand, in that case check if the other operand is multiple of
31619 bottom divided by the INTEGER_CST operand.
31620
31621 2018-01-16 Richard Sandiford <richard.sandiford@linaro.org>
31622
31623 PR target/83858
31624 * config/pa/pa.h (FUNCTION_ARG_SIZE): Delete.
31625 * config/pa/pa-protos.h (pa_function_arg_size): Declare.
31626 * config/pa/som.h (ASM_DECLARE_FUNCTION_NAME): Use
31627 pa_function_arg_size instead of FUNCTION_ARG_SIZE.
31628 * config/pa/pa.c (pa_function_arg_advance): Likewise.
31629 (pa_function_arg, pa_arg_partial_bytes): Likewise.
31630 (pa_function_arg_size): New function.
31631
31632 2018-01-16 Richard Sandiford <richard.sandiford@linaro.org>
31633
31634 * fold-const.c (fold_ternary_loc): Construct the vec_perm_indices
31635 in a separate statement.
31636
31637 2018-01-16 Richard Sandiford <richard.sandiford@linaro.org>
31638
31639 PR tree-optimization/83847
31640 * tree-vect-data-refs.c (vect_analyze_data_ref_accesses): Don't
31641 group gathers and scatters.
31642
31643 2018-01-16 Jakub Jelinek <jakub@redhat.com>
31644
31645 PR rtl-optimization/86620
31646 * params.def (max-sched-ready-insns): Bump minimum value to 1.
31647
31648 PR rtl-optimization/83213
31649 * recog.c (peep2_attempt): Copy over CROSSING_JUMP_P from peepinsn
31650 to last if both are JUMP_INSNs.
31651
31652 PR tree-optimization/83843
31653 * gimple-ssa-store-merging.c
31654 (imm_store_chain_info::output_merged_store): Handle bit_not_p on
31655 store_immediate_info for bswap/nop orig_stores.
31656
31657 2018-01-15 Andrew Waterman <andrew@sifive.com>
31658
31659 * config/riscv/riscv.c (riscv_rtx_costs) <MULT>: Increase cost if
31660 !TARGET_MUL.
31661 <UDIV>: Increase cost if !TARGET_DIV.
31662
31663 2018-01-15 Segher Boessenkool <segher@kernel.crashing.org>
31664
31665 * config/rs6000/rs6000.md (define_attr "type"): Remove delayed_cr.
31666 (define_attr "cr_logical_3op"): New.
31667 (cceq_ior_compare): Adjust.
31668 (cceq_ior_compare_complement): Adjust.
31669 (*cceq_rev_compare): Adjust.
31670 * config/rs6000/rs6000.c (rs6000_adjust_cost): Adjust.
31671 (is_cracked_insn): Adjust.
31672 (insn_must_be_first_in_group): Adjust.
31673 * config/rs6000/40x.md: Adjust.
31674 * config/rs6000/440.md: Adjust.
31675 * config/rs6000/476.md: Adjust.
31676 * config/rs6000/601.md: Adjust.
31677 * config/rs6000/603.md: Adjust.
31678 * config/rs6000/6xx.md: Adjust.
31679 * config/rs6000/7450.md: Adjust.
31680 * config/rs6000/7xx.md: Adjust.
31681 * config/rs6000/8540.md: Adjust.
31682 * config/rs6000/cell.md: Adjust.
31683 * config/rs6000/e300c2c3.md: Adjust.
31684 * config/rs6000/e500mc.md: Adjust.
31685 * config/rs6000/e500mc64.md: Adjust.
31686 * config/rs6000/e5500.md: Adjust.
31687 * config/rs6000/e6500.md: Adjust.
31688 * config/rs6000/mpc.md: Adjust.
31689 * config/rs6000/power4.md: Adjust.
31690 * config/rs6000/power5.md: Adjust.
31691 * config/rs6000/power6.md: Adjust.
31692 * config/rs6000/power7.md: Adjust.
31693 * config/rs6000/power8.md: Adjust.
31694 * config/rs6000/power9.md: Adjust.
31695 * config/rs6000/rs64.md: Adjust.
31696 * config/rs6000/titan.md: Adjust.
31697
31698 2018-01-15 H.J. Lu <hongjiu.lu@intel.com>
31699
31700 * config/i386/predicates.md (indirect_branch_operand): Rewrite
31701 ix86_indirect_branch_register logic.
31702
31703 2018-01-15 H.J. Lu <hongjiu.lu@intel.com>
31704
31705 * config/i386/constraints.md (Bs): Update
31706 ix86_indirect_branch_register check. Don't check
31707 ix86_indirect_branch_register with GOT_memory_operand.
31708 (Bw): Likewise.
31709 * config/i386/predicates.md (GOT_memory_operand): Don't check
31710 ix86_indirect_branch_register here.
31711 (GOT32_symbol_operand): Likewise.
31712
31713 2018-01-15 H.J. Lu <hongjiu.lu@intel.com>
31714
31715 * config/i386/predicates.md (constant_call_address_operand):
31716 Rewrite ix86_indirect_branch_register logic.
31717 (sibcall_insn_operand): Likewise.
31718
31719 2018-01-15 H.J. Lu <hongjiu.lu@intel.com>
31720
31721 * config/i386/constraints.md (Bs): Replace
31722 ix86_indirect_branch_thunk_register with
31723 ix86_indirect_branch_register.
31724 (Bw): Likewise.
31725 * config/i386/i386.md (indirect_jump): Likewise.
31726 (tablejump): Likewise.
31727 (*sibcall_memory): Likewise.
31728 (*sibcall_value_memory): Likewise.
31729 Peepholes of indirect call and jump via memory: Likewise.
31730 * config/i386/i386.opt: Likewise.
31731 * config/i386/predicates.md (indirect_branch_operand): Likewise.
31732 (GOT_memory_operand): Likewise.
31733 (call_insn_operand): Likewise.
31734 (sibcall_insn_operand): Likewise.
31735 (GOT32_symbol_operand): Likewise.
31736
31737 2018-01-15 Jakub Jelinek <jakub@redhat.com>
31738
31739 PR middle-end/83837
31740 * omp-expand.c (expand_omp_atomic_pipeline): Use loaded_val
31741 type rather than type addr's type points to.
31742 (expand_omp_atomic_mutex): Likewise.
31743 (expand_omp_atomic): Likewise.
31744
31745 2018-01-15 H.J. Lu <hongjiu.lu@intel.com>
31746
31747 PR target/83839
31748 * config/i386/i386.c (output_indirect_thunk_function): Use
31749 ASM_OUTPUT_LABEL, instead of ASM_OUTPUT_DEF, for TARGET_MACHO
31750 for __x86_return_thunk.
31751
31752 2018-01-15 Richard Biener <rguenther@suse.de>
31753
31754 PR middle-end/83850
31755 * expmed.c (extract_bit_field_1): Fix typo.
31756
31757 2018-01-15 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
31758
31759 PR target/83687
31760 * config/arm/iterators.md (VF): New mode iterator.
31761 * config/arm/neon.md (neon_vabd<mode>_2): Use the above.
31762 Remove integer-related logic from pattern.
31763 (neon_vabd<mode>_3): Likewise.
31764
31765 2018-01-15 Jakub Jelinek <jakub@redhat.com>
31766
31767 PR middle-end/82694
31768 * common.opt (fstrict-overflow): No longer an alias.
31769 (fwrapv-pointer): New option.
31770 * tree.h (TYPE_OVERFLOW_WRAPS, TYPE_OVERFLOW_UNDEFINED): Define
31771 also for pointer types based on flag_wrapv_pointer.
31772 * opts.c (common_handle_option) <case OPT_fstrict_overflow>: Set
31773 opts->x_flag_wrap[pv] to !value, clear opts->x_flag_trapv if
31774 opts->x_flag_wrapv got set.
31775 * fold-const.c (fold_comparison, fold_binary_loc): Revert 2017-08-01
31776 changes, just use TYPE_OVERFLOW_UNDEFINED on pointer type instead of
31777 POINTER_TYPE_OVERFLOW_UNDEFINED.
31778 * match.pd: Likewise in address comparison pattern.
31779 * doc/invoke.texi: Document -fwrapv and -fstrict-overflow.
31780
31781 2018-01-15 Richard Biener <rguenther@suse.de>
31782
31783 PR lto/83804
31784 * tree.c (free_lang_data_in_type): Always unlink TYPE_DECLs
31785 from TYPE_FIELDS. Free TYPE_BINFO if not used by devirtualization.
31786 Reset type names to their identifier if their TYPE_DECL doesn't
31787 have linkage (and thus is used for ODR and devirt).
31788 (save_debug_info_for_decl): Remove.
31789 (save_debug_info_for_type): Likewise.
31790 (add_tree_to_fld_list): Adjust.
31791 * tree-pretty-print.c (dump_generic_node): Make dumping of
31792 type names more robust.
31793
31794 2018-01-15 Richard Biener <rguenther@suse.de>
31795
31796 * BASE-VER: Bump to 8.0.1.
31797
31798 2018-01-14 Martin Sebor <msebor@redhat.com>
31799
31800 PR other/83508
31801 * builtins.c (check_access): Avoid warning when the no-warning bit
31802 is set.
31803
31804 2018-01-14 Cory Fields <cory-nospam-@coryfields.com>
31805
31806 * tree-ssa-loop-im.c (sort_bbs_in_loop_postorder_cmp): Stabilize sort.
31807 * ira-color (allocno_hard_regs_compare): Likewise.
31808
31809 2018-01-14 Nathan Rossi <nathan@nathanrossi.com>
31810
31811 PR target/83013
31812 * config/microblaze/microblaze.c (microblaze_asm_output_ident):
31813 Use .pushsection/.popsection.
31814
31815 2018-01-14 Martin Sebor <msebor@redhat.com>
31816
31817 PR c++/81327
31818 * doc/invoke.texi (-Wlass-memaccess): Document suppression by casting.
31819
31820 2018-01-14 Jakub Jelinek <jakub@redhat.com>
31821
31822 * config.gcc (i[34567]86-*-*): Remove one duplicate gfniintrin.h
31823 entry from extra_headers.
31824 (x86_64-*-*): Remove two duplicate gfniintrin.h entries from
31825 extra_headers, make the list bitwise identical to the i?86-*-* one.
31826
31827 2018-01-14 H.J. Lu <hongjiu.lu@intel.com>
31828
31829 * config/i386/i386.c (ix86_set_indirect_branch_type): Disallow
31830 -mcmodel=large with -mindirect-branch=thunk,
31831 -mindirect-branch=thunk-extern, -mfunction-return=thunk and
31832 -mfunction-return=thunk-extern.
31833 * doc/invoke.texi: Document -mcmodel=large is incompatible with
31834 -mindirect-branch=thunk, -mindirect-branch=thunk-extern,
31835 -mfunction-return=thunk and -mfunction-return=thunk-extern.
31836
31837 2018-01-14 H.J. Lu <hongjiu.lu@intel.com>
31838
31839 * config/i386/i386.c (print_reg): Print the name of the full
31840 integer register without '%'.
31841 (ix86_print_operand): Handle 'V'.
31842 * doc/extend.texi: Document 'V' modifier.
31843
31844 2018-01-14 H.J. Lu <hongjiu.lu@intel.com>
31845
31846 * config/i386/constraints.md (Bs): Disallow memory operand for
31847 -mindirect-branch-register.
31848 (Bw): Likewise.
31849 * config/i386/predicates.md (indirect_branch_operand): Likewise.
31850 (GOT_memory_operand): Likewise.
31851 (call_insn_operand): Likewise.
31852 (sibcall_insn_operand): Likewise.
31853 (GOT32_symbol_operand): Likewise.
31854 * config/i386/i386.md (indirect_jump): Call convert_memory_address
31855 for -mindirect-branch-register.
31856 (tablejump): Likewise.
31857 (*sibcall_memory): Likewise.
31858 (*sibcall_value_memory): Likewise.
31859 Disallow peepholes of indirect call and jump via memory for
31860 -mindirect-branch-register.
31861 (*call_pop): Replace m with Bw.
31862 (*call_value_pop): Likewise.
31863 (*sibcall_pop_memory): Replace m with Bs.
31864 * config/i386/i386.opt (mindirect-branch-register): New option.
31865 * doc/invoke.texi: Document -mindirect-branch-register option.
31866
31867 2018-01-14 H.J. Lu <hongjiu.lu@intel.com>
31868
31869 * config/i386/i386-protos.h (ix86_output_function_return): New.
31870 * config/i386/i386.c (ix86_set_indirect_branch_type): Also
31871 set function_return_type.
31872 (indirect_thunk_name): Add ret_p to indicate thunk for function
31873 return.
31874 (output_indirect_thunk_function): Pass false to
31875 indirect_thunk_name.
31876 (ix86_output_indirect_branch_via_reg): Likewise.
31877 (ix86_output_indirect_branch_via_push): Likewise.
31878 (output_indirect_thunk_function): Create alias for function
31879 return thunk if regno < 0.
31880 (ix86_output_function_return): New function.
31881 (ix86_handle_fndecl_attribute): Handle function_return.
31882 (ix86_attribute_table): Add function_return.
31883 * config/i386/i386.h (machine_function): Add
31884 function_return_type.
31885 * config/i386/i386.md (simple_return_internal): Use
31886 ix86_output_function_return.
31887 (simple_return_internal_long): Likewise.
31888 * config/i386/i386.opt (mfunction-return=): New option.
31889 (indirect_branch): Mention -mfunction-return=.
31890 * doc/extend.texi: Document function_return function attribute.
31891 * doc/invoke.texi: Document -mfunction-return= option.
31892
31893 2018-01-14 H.J. Lu <hongjiu.lu@intel.com>
31894
31895 * config/i386/i386-opts.h (indirect_branch): New.
31896 * config/i386/i386-protos.h (ix86_output_indirect_jmp): Likewise.
31897 * config/i386/i386.c (ix86_using_red_zone): Disallow red-zone
31898 with local indirect jump when converting indirect call and jump.
31899 (ix86_set_indirect_branch_type): New.
31900 (ix86_set_current_function): Call ix86_set_indirect_branch_type.
31901 (indirectlabelno): New.
31902 (indirect_thunk_needed): Likewise.
31903 (indirect_thunk_bnd_needed): Likewise.
31904 (indirect_thunks_used): Likewise.
31905 (indirect_thunks_bnd_used): Likewise.
31906 (INDIRECT_LABEL): Likewise.
31907 (indirect_thunk_name): Likewise.
31908 (output_indirect_thunk): Likewise.
31909 (output_indirect_thunk_function): Likewise.
31910 (ix86_output_indirect_branch_via_reg): Likewise.
31911 (ix86_output_indirect_branch_via_push): Likewise.
31912 (ix86_output_indirect_branch): Likewise.
31913 (ix86_output_indirect_jmp): Likewise.
31914 (ix86_code_end): Call output_indirect_thunk_function if needed.
31915 (ix86_output_call_insn): Call ix86_output_indirect_branch if
31916 needed.
31917 (ix86_handle_fndecl_attribute): Handle indirect_branch.
31918 (ix86_attribute_table): Add indirect_branch.
31919 * config/i386/i386.h (machine_function): Add indirect_branch_type
31920 and has_local_indirect_jump.
31921 * config/i386/i386.md (indirect_jump): Set has_local_indirect_jump
31922 to true.
31923 (tablejump): Likewise.
31924 (*indirect_jump): Use ix86_output_indirect_jmp.
31925 (*tablejump_1): Likewise.
31926 (simple_return_indirect_internal): Likewise.
31927 * config/i386/i386.opt (mindirect-branch=): New option.
31928 (indirect_branch): New.
31929 (keep): Likewise.
31930 (thunk): Likewise.
31931 (thunk-inline): Likewise.
31932 (thunk-extern): Likewise.
31933 * doc/extend.texi: Document indirect_branch function attribute.
31934 * doc/invoke.texi: Document -mindirect-branch= option.
31935
31936 2018-01-14 Jan Hubicka <hubicka@ucw.cz>
31937
31938 PR ipa/83051
31939 * ipa-inline.c (edge_badness): Tolerate roundoff errors.
31940
31941 2018-01-14 Richard Sandiford <richard.sandiford@linaro.org>
31942
31943 * ipa-inline.c (want_inline_small_function_p): Return false if
31944 inlining has already failed with CIF_FINAL_ERROR.
31945 (update_caller_keys): Call want_inline_small_function_p before
31946 can_inline_edge_p.
31947 (update_callee_keys): Likewise.
31948
31949 2018-01-10 Kelvin Nilsen <kelvin@gcc.gnu.org>
31950
31951 * config/rs6000/rs6000-p8swap.c (rs6000_sum_of_two_registers_p):
31952 New function.
31953 (rs6000_quadword_masked_address_p): Likewise.
31954 (quad_aligned_load_p): Likewise.
31955 (quad_aligned_store_p): Likewise.
31956 (const_load_sequence_p): Add comment to describe the outer-most loop.
31957 (mimic_memory_attributes_and_flags): New function.
31958 (rs6000_gen_stvx): Likewise.
31959 (replace_swapped_aligned_store): Likewise.
31960 (rs6000_gen_lvx): Likewise.
31961 (replace_swapped_aligned_load): Likewise.
31962 (replace_swapped_load_constant): Capitalize argument name in
31963 comment describing this function.
31964 (rs6000_analyze_swaps): Add a third pass to search for vector loads
31965 and stores that access quad-word aligned addresses and replace
31966 with stvx or lvx instructions when appropriate.
31967 * config/rs6000/rs6000-protos.h (rs6000_sum_of_two_registers_p):
31968 New function prototype.
31969 (rs6000_quadword_masked_address_p): Likewise.
31970 (rs6000_gen_lvx): Likewise.
31971 (rs6000_gen_stvx): Likewise.
31972 * config/rs6000/vsx.md (*vsx_le_perm_load_<mode>): For modes
31973 VSX_D (V2DF, V2DI), modify this split to select lvx instruction
31974 when memory address is aligned.
31975 (*vsx_le_perm_load_<mode>): For modes VSX_W (V4SF, V4SI), modify
31976 this split to select lvx instruction when memory address is aligned.
31977 (*vsx_le_perm_load_v8hi): Modify this split to select lvx
31978 instruction when memory address is aligned.
31979 (*vsx_le_perm_load_v16qi): Likewise.
31980 (four unnamed splitters): Modify to select the stvx instruction
31981 when memory is aligned.
31982
31983 2018-01-13 Jan Hubicka <hubicka@ucw.cz>
31984
31985 * predict.c (determine_unlikely_bbs): Handle correctly BBs
31986 which appears in the queue multiple times.
31987
31988 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
31989 Alan Hayward <alan.hayward@arm.com>
31990 David Sherwood <david.sherwood@arm.com>
31991
31992 * tree-vectorizer.h (vec_lower_bound): New structure.
31993 (_loop_vec_info): Add check_nonzero and lower_bounds.
31994 (LOOP_VINFO_CHECK_NONZERO): New macro.
31995 (LOOP_VINFO_LOWER_BOUNDS): Likewise.
31996 (LOOP_REQUIRES_VERSIONING_FOR_ALIAS): Check lower_bounds too.
31997 * tree-data-ref.h (dr_with_seg_len): Add access_size and align
31998 fields. Make seg_len the distance travelled, not including the
31999 access size.
32000 (dr_direction_indicator): Declare.
32001 (dr_zero_step_indicator): Likewise.
32002 (dr_known_forward_stride_p): Likewise.
32003 * tree-data-ref.c: Include stringpool.h, tree-vrp.h and
32004 tree-ssanames.h.
32005 (runtime_alias_check_p): Allow runtime alias checks with
32006 variable strides.
32007 (operator ==): Compare access_size and align.
32008 (prune_runtime_alias_test_list): Rework for new distinction between
32009 the access_size and seg_len.
32010 (create_intersect_range_checks_index): Likewise. Cope with polynomial
32011 segment lengths.
32012 (get_segment_min_max): New function.
32013 (create_intersect_range_checks): Use it.
32014 (dr_step_indicator): New function.
32015 (dr_direction_indicator): Likewise.
32016 (dr_zero_step_indicator): Likewise.
32017 (dr_known_forward_stride_p): Likewise.
32018 * tree-loop-distribution.c (data_ref_segment_size): Return
32019 DR_STEP * (niters - 1).
32020 (compute_alias_check_pairs): Update call to the dr_with_seg_len
32021 constructor.
32022 * tree-vect-data-refs.c (vect_check_nonzero_value): New function.
32023 (vect_preserves_scalar_order_p): New function, split out from...
32024 (vect_analyze_data_ref_dependence): ...here. Check for zero steps.
32025 (vect_vfa_segment_size): Return DR_STEP * (length_factor - 1).
32026 (vect_vfa_access_size): New function.
32027 (vect_vfa_align): Likewise.
32028 (vect_compile_time_alias): Take access_size_a and access_b arguments.
32029 (dump_lower_bound): New function.
32030 (vect_check_lower_bound): Likewise.
32031 (vect_small_gap_p): Likewise.
32032 (vectorizable_with_step_bound_p): Likewise.
32033 (vect_prune_runtime_alias_test_list): Ignore cross-iteration
32034 depencies if the vectorization factor is 1. Convert the checks
32035 for nonzero steps into checks on the bounds of DR_STEP. Try using
32036 a bunds check for variable steps if the minimum required step is
32037 relatively small. Update calls to the dr_with_seg_len
32038 constructor and to vect_compile_time_alias.
32039 * tree-vect-loop-manip.c (vect_create_cond_for_lower_bounds): New
32040 function.
32041 (vect_loop_versioning): Call it.
32042 * tree-vect-loop.c (vect_analyze_loop_2): Clear LOOP_VINFO_LOWER_BOUNDS
32043 when retrying.
32044 (vect_estimate_min_profitable_iters): Account for any bounds checks.
32045
32046 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
32047 Alan Hayward <alan.hayward@arm.com>
32048 David Sherwood <david.sherwood@arm.com>
32049
32050 * doc/sourcebuild.texi (vect_scatter_store): Document.
32051 * optabs.def (scatter_store_optab, mask_scatter_store_optab): New
32052 optabs.
32053 * doc/md.texi (scatter_store@var{m}, mask_scatter_store@var{m}):
32054 Document.
32055 * genopinit.c (main): Add supports_vec_scatter_store and
32056 supports_vec_scatter_store_cached to target_optabs.
32057 * gimple.h (gimple_expr_type): Handle IFN_SCATTER_STORE and
32058 IFN_MASK_SCATTER_STORE.
32059 * internal-fn.def (SCATTER_STORE, MASK_SCATTER_STORE): New internal
32060 functions.
32061 * internal-fn.h (internal_store_fn_p): Declare.
32062 (internal_fn_stored_value_index): Likewise.
32063 * internal-fn.c (scatter_store_direct): New macro.
32064 (expand_scatter_store_optab_fn): New function.
32065 (direct_scatter_store_optab_supported_p): New macro.
32066 (internal_store_fn_p): New function.
32067 (internal_gather_scatter_fn_p): Handle IFN_SCATTER_STORE and
32068 IFN_MASK_SCATTER_STORE.
32069 (internal_fn_mask_index): Likewise.
32070 (internal_fn_stored_value_index): New function.
32071 (internal_gather_scatter_fn_supported_p): Adjust operand numbers
32072 for scatter stores.
32073 * optabs-query.h (supports_vec_scatter_store_p): Declare.
32074 * optabs-query.c (supports_vec_scatter_store_p): New function.
32075 * tree-vectorizer.h (vect_get_store_rhs): Declare.
32076 * tree-vect-data-refs.c (vect_analyze_data_ref_access): Return
32077 true for scatter stores.
32078 (vect_gather_scatter_fn_p): Handle scatter stores too.
32079 (vect_check_gather_scatter): Consider using scatter stores if
32080 supports_vec_scatter_store_p.
32081 * tree-vect-patterns.c (vect_try_gather_scatter_pattern): Handle
32082 scatter stores too.
32083 * tree-vect-stmts.c (exist_non_indexing_operands_for_use_p): Use
32084 internal_fn_stored_value_index.
32085 (check_load_store_masking): Handle scatter stores too.
32086 (vect_get_store_rhs): Make public.
32087 (vectorizable_call): Use internal_store_fn_p.
32088 (vectorizable_store): Handle scatter store internal functions.
32089 (vect_transform_stmt): Compare GROUP_STORE_COUNT with GROUP_SIZE
32090 when deciding whether the end of the group has been reached.
32091 * config/aarch64/aarch64.md (UNSPEC_ST1_SCATTER): New unspec.
32092 * config/aarch64/aarch64-sve.md (scatter_store<mode>): New expander.
32093 (mask_scatter_store<mode>): New insns.
32094
32095 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
32096 Alan Hayward <alan.hayward@arm.com>
32097 David Sherwood <david.sherwood@arm.com>
32098
32099 * tree-vectorizer.h (vect_gather_scatter_fn_p): Declare.
32100 * tree-vect-data-refs.c (vect_gather_scatter_fn_p): Make public.
32101 * tree-vect-stmts.c (vect_truncate_gather_scatter_offset): New
32102 function.
32103 (vect_use_strided_gather_scatters_p): Take a masked_p argument.
32104 Use vect_truncate_gather_scatter_offset if we can't treat the
32105 operation as a normal gather load or scatter store.
32106 (get_group_load_store_type): Take the gather_scatter_info
32107 as argument. Try using a gather load or scatter store for
32108 single-element groups.
32109 (get_load_store_type): Update calls to get_group_load_store_type
32110 and vect_use_strided_gather_scatters_p.
32111
32112 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
32113 Alan Hayward <alan.hayward@arm.com>
32114 David Sherwood <david.sherwood@arm.com>
32115
32116 * tree-vectorizer.h (vect_create_data_ref_ptr): Take an extra
32117 optional tree argument.
32118 * tree-vect-data-refs.c (vect_check_gather_scatter): Check for
32119 null target hooks.
32120 (vect_create_data_ref_ptr): Take the iv_step as an optional argument,
32121 but continue to use the current value as a fallback.
32122 (bump_vector_ptr): Use operand_equal_p rather than tree_int_cst_compare
32123 to compare the updates.
32124 * tree-vect-stmts.c (vect_use_strided_gather_scatters_p): New function.
32125 (get_load_store_type): Use it when handling a strided access.
32126 (vect_get_strided_load_store_ops): New function.
32127 (vect_get_data_ptr_increment): Likewise.
32128 (vectorizable_load): Handle strided gather loads. Always pass
32129 a step to vect_create_data_ref_ptr and bump_vector_ptr.
32130
32131 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
32132 Alan Hayward <alan.hayward@arm.com>
32133 David Sherwood <david.sherwood@arm.com>
32134
32135 * doc/md.texi (gather_load@var{m}): Document.
32136 (mask_gather_load@var{m}): Likewise.
32137 * genopinit.c (main): Add supports_vec_gather_load and
32138 supports_vec_gather_load_cached to target_optabs.
32139 * optabs-tree.c (init_tree_optimization_optabs): Use
32140 ggc_cleared_alloc to allocate target_optabs.
32141 * optabs.def (gather_load_optab, mask_gather_laod_optab): New optabs.
32142 * internal-fn.def (GATHER_LOAD, MASK_GATHER_LOAD): New internal
32143 functions.
32144 * internal-fn.h (internal_load_fn_p): Declare.
32145 (internal_gather_scatter_fn_p): Likewise.
32146 (internal_fn_mask_index): Likewise.
32147 (internal_gather_scatter_fn_supported_p): Likewise.
32148 * internal-fn.c (gather_load_direct): New macro.
32149 (expand_gather_load_optab_fn): New function.
32150 (direct_gather_load_optab_supported_p): New macro.
32151 (direct_internal_fn_optab): New function.
32152 (internal_load_fn_p): Likewise.
32153 (internal_gather_scatter_fn_p): Likewise.
32154 (internal_fn_mask_index): Likewise.
32155 (internal_gather_scatter_fn_supported_p): Likewise.
32156 * optabs-query.c (supports_at_least_one_mode_p): New function.
32157 (supports_vec_gather_load_p): Likewise.
32158 * optabs-query.h (supports_vec_gather_load_p): Declare.
32159 * tree-vectorizer.h (gather_scatter_info): Add ifn, element_type
32160 and memory_type field.
32161 (NUM_PATTERNS): Bump to 15.
32162 * tree-vect-data-refs.c: Include internal-fn.h.
32163 (vect_gather_scatter_fn_p): New function.
32164 (vect_describe_gather_scatter_call): Likewise.
32165 (vect_check_gather_scatter): Try using internal functions for
32166 gather loads. Recognize existing calls to a gather load function.
32167 (vect_analyze_data_refs): Consider using gather loads if
32168 supports_vec_gather_load_p.
32169 * tree-vect-patterns.c (vect_get_load_store_mask): New function.
32170 (vect_get_gather_scatter_offset_type): Likewise.
32171 (vect_convert_mask_for_vectype): Likewise.
32172 (vect_add_conversion_to_patterm): Likewise.
32173 (vect_try_gather_scatter_pattern): Likewise.
32174 (vect_recog_gather_scatter_pattern): New pattern recognizer.
32175 (vect_vect_recog_func_ptrs): Add it.
32176 * tree-vect-stmts.c (exist_non_indexing_operands_for_use_p): Use
32177 internal_fn_mask_index and internal_gather_scatter_fn_p.
32178 (check_load_store_masking): Take the gather_scatter_info as an
32179 argument and handle gather loads.
32180 (vect_get_gather_scatter_ops): New function.
32181 (vectorizable_call): Check internal_load_fn_p.
32182 (vectorizable_load): Likewise. Handle gather load internal
32183 functions.
32184 (vectorizable_store): Update call to check_load_store_masking.
32185 * config/aarch64/aarch64.md (UNSPEC_LD1_GATHER): New unspec.
32186 * config/aarch64/iterators.md (SVE_S, SVE_D): New mode iterators.
32187 * config/aarch64/predicates.md (aarch64_gather_scale_operand_w)
32188 (aarch64_gather_scale_operand_d): New predicates.
32189 * config/aarch64/aarch64-sve.md (gather_load<mode>): New expander.
32190 (mask_gather_load<mode>): New insns.
32191
32192 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
32193 Alan Hayward <alan.hayward@arm.com>
32194 David Sherwood <david.sherwood@arm.com>
32195
32196 * optabs.def (fold_left_plus_optab): New optab.
32197 * doc/md.texi (fold_left_plus_@var{m}): Document.
32198 * internal-fn.def (IFN_FOLD_LEFT_PLUS): New internal function.
32199 * internal-fn.c (fold_left_direct): Define.
32200 (expand_fold_left_optab_fn): Likewise.
32201 (direct_fold_left_optab_supported_p): Likewise.
32202 * fold-const-call.c (fold_const_fold_left): New function.
32203 (fold_const_call): Use it to fold CFN_FOLD_LEFT_PLUS.
32204 * tree-parloops.c (valid_reduction_p): New function.
32205 (gather_scalar_reductions): Use it.
32206 * tree-vectorizer.h (FOLD_LEFT_REDUCTION): New vect_reduction_type.
32207 (vect_finish_replace_stmt): Declare.
32208 * tree-vect-loop.c (fold_left_reduction_fn): New function.
32209 (needs_fold_left_reduction_p): New function, split out from...
32210 (vect_is_simple_reduction): ...here. Accept reductions that
32211 forbid reassociation, but give them type FOLD_LEFT_REDUCTION.
32212 (vect_force_simple_reduction): Also store the reduction type in
32213 the assignment's STMT_VINFO_REDUC_TYPE.
32214 (vect_model_reduction_cost): Handle FOLD_LEFT_REDUCTION.
32215 (merge_with_identity): New function.
32216 (vect_expand_fold_left): Likewise.
32217 (vectorize_fold_left_reduction): Likewise.
32218 (vectorizable_reduction): Handle FOLD_LEFT_REDUCTION. Leave the
32219 scalar phi in place for it. Check for target support and reject
32220 cases that would reassociate the operation. Defer the transform
32221 phase to vectorize_fold_left_reduction.
32222 * config/aarch64/aarch64.md (UNSPEC_FADDA): New unspec.
32223 * config/aarch64/aarch64-sve.md (fold_left_plus_<mode>): New expander.
32224 (*fold_left_plus_<mode>, *pred_fold_left_plus_<mode>): New insns.
32225
32226 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
32227
32228 * tree-if-conv.c (predicate_mem_writes): Remove redundant
32229 call to ifc_temp_var.
32230
32231 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
32232 Alan Hayward <alan.hayward@arm.com>
32233 David Sherwood <david.sherwood@arm.com>
32234
32235 * target.def (legitimize_address_displacement): Take the original
32236 offset as a poly_int.
32237 * targhooks.h (default_legitimize_address_displacement): Update
32238 accordingly.
32239 * targhooks.c (default_legitimize_address_displacement): Likewise.
32240 * doc/tm.texi: Regenerate.
32241 * lra-constraints.c (base_plus_disp_to_reg): Take the displacement
32242 as an argument, moving assert of ad->disp == ad->disp_term to...
32243 (process_address_1): ...here. Update calls to base_plus_disp_to_reg.
32244 Try calling targetm.legitimize_address_displacement before expanding
32245 the address rather than afterwards, and adjust for the new interface.
32246 * config/aarch64/aarch64.c (aarch64_legitimize_address_displacement):
32247 Match the new hook interface. Handle SVE addresses.
32248 * config/sh/sh.c (sh_legitimize_address_displacement): Make the
32249 new hook interface.
32250
32251 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
32252
32253 * Makefile.in (OBJS): Add early-remat.o.
32254 * target.def (select_early_remat_modes): New hook.
32255 * doc/tm.texi.in (TARGET_SELECT_EARLY_REMAT_MODES): New hook.
32256 * doc/tm.texi: Regenerate.
32257 * targhooks.h (default_select_early_remat_modes): Declare.
32258 * targhooks.c (default_select_early_remat_modes): New function.
32259 * timevar.def (TV_EARLY_REMAT): New timevar.
32260 * passes.def (pass_early_remat): New pass.
32261 * tree-pass.h (make_pass_early_remat): Declare.
32262 * early-remat.c: New file.
32263 * config/aarch64/aarch64.c (aarch64_select_early_remat_modes): New
32264 function.
32265 (TARGET_SELECT_EARLY_REMAT_MODES): Define.
32266
32267 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
32268 Alan Hayward <alan.hayward@arm.com>
32269 David Sherwood <david.sherwood@arm.com>
32270
32271 * tree-vect-loop-manip.c (vect_gen_scalar_loop_niters): Replace
32272 vfm1 with a bound_epilog parameter.
32273 (vect_do_peeling): Update calls accordingly, and move the prologue
32274 call earlier in the function. Treat the base bound_epilog as 0 for
32275 fully-masked loops and retain vf - 1 for other loops. Add 1 to
32276 this base when peeling for gaps.
32277 * tree-vect-loop.c (vect_analyze_loop_2): Allow peeling for gaps
32278 with fully-masked loops.
32279 (vect_estimate_min_profitable_iters): Handle the single peeled
32280 iteration in that case.
32281
32282 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
32283 Alan Hayward <alan.hayward@arm.com>
32284 David Sherwood <david.sherwood@arm.com>
32285
32286 * tree-vect-data-refs.c (vect_analyze_group_access_1): Allow
32287 single-element interleaving even if the size is not a power of 2.
32288 * tree-vect-stmts.c (get_load_store_type): Disallow elementwise
32289 accesses for single-element interleaving if the group size is
32290 not a power of 2.
32291
32292 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
32293 Alan Hayward <alan.hayward@arm.com>
32294 David Sherwood <david.sherwood@arm.com>
32295
32296 * doc/md.texi (fold_extract_last_@var{m}): Document.
32297 * doc/sourcebuild.texi (vect_fold_extract_last): Likewise.
32298 * optabs.def (fold_extract_last_optab): New optab.
32299 * internal-fn.def (FOLD_EXTRACT_LAST): New internal function.
32300 * internal-fn.c (fold_extract_direct): New macro.
32301 (expand_fold_extract_optab_fn): Likewise.
32302 (direct_fold_extract_optab_supported_p): Likewise.
32303 * tree-vectorizer.h (EXTRACT_LAST_REDUCTION): New vect_reduction_type.
32304 * tree-vect-loop.c (vect_model_reduction_cost): Handle
32305 EXTRACT_LAST_REDUCTION.
32306 (get_initial_def_for_reduction): Do not create an initial vector
32307 for EXTRACT_LAST_REDUCTION reductions.
32308 (vectorizable_reduction): Leave the scalar phi in place for
32309 EXTRACT_LAST_REDUCTIONs. Try using EXTRACT_LAST_REDUCTION
32310 ahead of INTEGER_INDUC_COND_REDUCTION. Do not check for an
32311 epilogue code for EXTRACT_LAST_REDUCTION and defer the
32312 transform phase to vectorizable_condition.
32313 * tree-vect-stmts.c (vect_finish_stmt_generation_1): New function,
32314 split out from...
32315 (vect_finish_stmt_generation): ...here.
32316 (vect_finish_replace_stmt): New function.
32317 (vectorizable_condition): Handle EXTRACT_LAST_REDUCTION.
32318 * config/aarch64/aarch64-sve.md (fold_extract_last_<mode>): New
32319 pattern.
32320 * config/aarch64/aarch64.md (UNSPEC_CLASTB): New unspec.
32321
32322 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
32323 Alan Hayward <alan.hayward@arm.com>
32324 David Sherwood <david.sherwood@arm.com>
32325
32326 * doc/md.texi (extract_last_@var{m}): Document.
32327 * optabs.def (extract_last_optab): New optab.
32328 * internal-fn.def (EXTRACT_LAST): New internal function.
32329 * internal-fn.c (cond_unary_direct): New macro.
32330 (expand_cond_unary_optab_fn): Likewise.
32331 (direct_cond_unary_optab_supported_p): Likewise.
32332 * tree-vect-loop.c (vectorizable_live_operation): Allow fully-masked
32333 loops using EXTRACT_LAST.
32334 * config/aarch64/aarch64-sve.md (aarch64_sve_lastb<mode>): Rename to...
32335 (extract_last_<mode>): ...this optab.
32336 (vec_extract<mode><Vel>): Update accordingly.
32337
32338 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
32339 Alan Hayward <alan.hayward@arm.com>
32340 David Sherwood <david.sherwood@arm.com>
32341
32342 * target.def (empty_mask_is_expensive): New hook.
32343 * doc/tm.texi.in (TARGET_VECTORIZE_EMPTY_MASK_IS_EXPENSIVE): New hook.
32344 * doc/tm.texi: Regenerate.
32345 * targhooks.h (default_empty_mask_is_expensive): Declare.
32346 * targhooks.c (default_empty_mask_is_expensive): New function.
32347 * tree-vectorizer.c (vectorize_loops): Only call optimize_mask_stores
32348 if the target says that empty masks are expensive.
32349 * config/aarch64/aarch64.c (aarch64_empty_mask_is_expensive):
32350 New function.
32351 (TARGET_VECTORIZE_EMPTY_MASK_IS_EXPENSIVE): Redefine.
32352
32353 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
32354 Alan Hayward <alan.hayward@arm.com>
32355 David Sherwood <david.sherwood@arm.com>
32356
32357 * tree-vectorizer.h (_loop_vec_info::mask_skip_niters): New field.
32358 (LOOP_VINFO_MASK_SKIP_NITERS): New macro.
32359 (vect_use_loop_mask_for_alignment_p): New function.
32360 (vect_prepare_for_masked_peels, vect_gen_while_not): Declare.
32361 * tree-vect-loop-manip.c (vect_set_loop_masks_directly): Add an
32362 niters_skip argument. Make sure that the first niters_skip elements
32363 of the first iteration are inactive.
32364 (vect_set_loop_condition_masked): Handle LOOP_VINFO_MASK_SKIP_NITERS.
32365 Update call to vect_set_loop_masks_directly.
32366 (get_misalign_in_elems): New function, split out from...
32367 (vect_gen_prolog_loop_niters): ...here.
32368 (vect_update_init_of_dr): Take a code argument that specifies whether
32369 the adjustment should be added or subtracted.
32370 (vect_update_init_of_drs): Likewise.
32371 (vect_prepare_for_masked_peels): New function.
32372 (vect_do_peeling): Skip prologue peeling if we're using a mask
32373 instead. Update call to vect_update_inits_of_drs.
32374 * tree-vect-loop.c (_loop_vec_info::_loop_vec_info): Initialize
32375 mask_skip_niters.
32376 (vect_analyze_loop_2): Allow fully-masked loops with peeling for
32377 alignment. Do not include the number of peeled iterations in
32378 the minimum threshold in that case.
32379 (vectorizable_induction): Adjust the start value down by
32380 LOOP_VINFO_MASK_SKIP_NITERS iterations.
32381 (vect_transform_loop): Call vect_prepare_for_masked_peels.
32382 Take the number of skipped iterations into account when calculating
32383 the loop bounds.
32384 * tree-vect-stmts.c (vect_gen_while_not): New function.
32385
32386 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
32387 Alan Hayward <alan.hayward@arm.com>
32388 David Sherwood <david.sherwood@arm.com>
32389
32390 * doc/sourcebuild.texi (vect_fully_masked): Document.
32391 * params.def (PARAM_MIN_VECT_LOOP_BOUND): Change minimum and
32392 default value to 0.
32393 * tree-vect-loop.c (vect_analyze_loop_costing): New function,
32394 split out from...
32395 (vect_analyze_loop_2): ...here. Don't check the vectorization
32396 factor against the number of loop iterations if the loop is
32397 fully-masked.
32398
32399 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
32400 Alan Hayward <alan.hayward@arm.com>
32401 David Sherwood <david.sherwood@arm.com>
32402
32403 * tree-ssa-loop-ivopts.c (USE_ADDRESS): Split into...
32404 (USE_REF_ADDRESS, USE_PTR_ADDRESS): ...these new use types.
32405 (dump_groups): Update accordingly.
32406 (iv_use::mem_type): New member variable.
32407 (address_p): New function.
32408 (record_use): Add a mem_type argument and initialize the new
32409 mem_type field.
32410 (record_group_use): Add a mem_type argument. Use address_p.
32411 Remove obsolete null checks of base_object. Update call to record_use.
32412 (find_interesting_uses_op): Update call to record_group_use.
32413 (find_interesting_uses_cond): Likewise.
32414 (find_interesting_uses_address): Likewise.
32415 (get_mem_type_for_internal_fn): New function.
32416 (find_address_like_use): Likewise.
32417 (find_interesting_uses_stmt): Try find_address_like_use before
32418 calling find_interesting_uses_op.
32419 (addr_offset_valid_p): Use the iv mem_type field as the type
32420 of the addressed memory.
32421 (add_autoinc_candidates): Likewise.
32422 (get_address_cost): Likewise.
32423 (split_small_address_groups_p): Use address_p.
32424 (split_address_groups): Likewise.
32425 (add_iv_candidate_for_use): Likewise.
32426 (autoinc_possible_for_pair): Likewise.
32427 (rewrite_groups): Likewise.
32428 (get_use_type): Check for USE_REF_ADDRESS instead of USE_ADDRESS.
32429 (determine_group_iv_cost): Update after split of USE_ADDRESS.
32430 (get_alias_ptr_type_for_ptr_address): New function.
32431 (rewrite_use_address): Rewrite address uses in calls that were
32432 identified by find_address_like_use.
32433
32434 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
32435 Alan Hayward <alan.hayward@arm.com>
32436 David Sherwood <david.sherwood@arm.com>
32437
32438 * expr.c (expand_expr_addr_expr_1): Handle ADDR_EXPRs of
32439 TARGET_MEM_REFs.
32440 * gimple-expr.h (is_gimple_addressable: Likewise.
32441 * gimple-expr.c (is_gimple_address): Likewise.
32442 * internal-fn.c (expand_call_mem_ref): New function.
32443 (expand_mask_load_optab_fn): Use it.
32444 (expand_mask_store_optab_fn): Likewise.
32445
32446 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
32447 Alan Hayward <alan.hayward@arm.com>
32448 David Sherwood <david.sherwood@arm.com>
32449
32450 * doc/md.texi (cond_add@var{mode}, cond_sub@var{mode})
32451 (cond_and@var{mode}, cond_ior@var{mode}, cond_xor@var{mode})
32452 (cond_smin@var{mode}, cond_smax@var{mode}, cond_umin@var{mode})
32453 (cond_umax@var{mode}): Document.
32454 * optabs.def (cond_add_optab, cond_sub_optab, cond_and_optab)
32455 (cond_ior_optab, cond_xor_optab, cond_smin_optab, cond_smax_optab)
32456 (cond_umin_optab, cond_umax_optab): New optabs.
32457 * internal-fn.def (COND_ADD, COND_SUB, COND_MIN, COND_MAX, COND_AND)
32458 (COND_IOR, COND_XOR): New internal functions.
32459 * internal-fn.h (get_conditional_internal_fn): Declare.
32460 * internal-fn.c (cond_binary_direct): New macro.
32461 (expand_cond_binary_optab_fn): Likewise.
32462 (direct_cond_binary_optab_supported_p): Likewise.
32463 (get_conditional_internal_fn): New function.
32464 * tree-vect-loop.c (vectorizable_reduction): Handle fully-masked loops.
32465 Cope with reduction statements that are vectorized as calls rather
32466 than assignments.
32467 * config/aarch64/aarch64-sve.md (cond_<optab><mode>): New insns.
32468 * config/aarch64/iterators.md (UNSPEC_COND_ADD, UNSPEC_COND_SUB)
32469 (UNSPEC_COND_SMAX, UNSPEC_COND_UMAX, UNSPEC_COND_SMIN)
32470 (UNSPEC_COND_UMIN, UNSPEC_COND_AND, UNSPEC_COND_ORR)
32471 (UNSPEC_COND_EOR): New unspecs.
32472 (optab): Add mappings for them.
32473 (SVE_COND_INT_OP, SVE_COND_FP_OP): New int iterators.
32474 (sve_int_op, sve_fp_op): New int attributes.
32475
32476 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
32477 Alan Hayward <alan.hayward@arm.com>
32478 David Sherwood <david.sherwood@arm.com>
32479
32480 * optabs.def (while_ult_optab): New optab.
32481 * doc/md.texi (while_ult@var{m}@var{n}): Document.
32482 * internal-fn.def (WHILE_ULT): New internal function.
32483 * internal-fn.h (direct_internal_fn_supported_p): New override
32484 that takes two types as argument.
32485 * internal-fn.c (while_direct): New macro.
32486 (expand_while_optab_fn): New function.
32487 (convert_optab_supported_p): Likewise.
32488 (direct_while_optab_supported_p): New macro.
32489 * wide-int.h (wi::udiv_ceil): New function.
32490 * tree-vectorizer.h (rgroup_masks): New structure.
32491 (vec_loop_masks): New typedef.
32492 (_loop_vec_info): Add masks, mask_compare_type, can_fully_mask_p
32493 and fully_masked_p.
32494 (LOOP_VINFO_CAN_FULLY_MASK_P, LOOP_VINFO_FULLY_MASKED_P)
32495 (LOOP_VINFO_MASKS, LOOP_VINFO_MASK_COMPARE_TYPE): New macros.
32496 (vect_max_vf): New function.
32497 (slpeel_make_loop_iterate_ntimes): Delete.
32498 (vect_set_loop_condition, vect_get_loop_mask_type, vect_gen_while)
32499 (vect_halve_mask_nunits, vect_double_mask_nunits): Declare.
32500 (vect_record_loop_mask, vect_get_loop_mask): Likewise.
32501 * tree-vect-loop-manip.c: Include tree-ssa-loop-niter.h,
32502 internal-fn.h, stor-layout.h and optabs-query.h.
32503 (vect_set_loop_mask): New function.
32504 (add_preheader_seq): Likewise.
32505 (add_header_seq): Likewise.
32506 (interleave_supported_p): Likewise.
32507 (vect_maybe_permute_loop_masks): Likewise.
32508 (vect_set_loop_masks_directly): Likewise.
32509 (vect_set_loop_condition_masked): Likewise.
32510 (vect_set_loop_condition_unmasked): New function, split out from
32511 slpeel_make_loop_iterate_ntimes.
32512 (slpeel_make_loop_iterate_ntimes): Rename to..
32513 (vect_set_loop_condition): ...this. Use vect_set_loop_condition_masked
32514 for fully-masked loops and vect_set_loop_condition_unmasked otherwise.
32515 (vect_do_peeling): Update call accordingly.
32516 (vect_gen_vector_loop_niters): Use VF as the step for fully-masked
32517 loops.
32518 * tree-vect-loop.c (_loop_vec_info::_loop_vec_info): Initialize
32519 mask_compare_type, can_fully_mask_p and fully_masked_p.
32520 (release_vec_loop_masks): New function.
32521 (_loop_vec_info): Use it to free the loop masks.
32522 (can_produce_all_loop_masks_p): New function.
32523 (vect_get_max_nscalars_per_iter): Likewise.
32524 (vect_verify_full_masking): Likewise.
32525 (vect_analyze_loop_2): Save LOOP_VINFO_CAN_FULLY_MASK_P around
32526 retries, and free the mask rgroups before retrying. Check loop-wide
32527 reasons for disallowing fully-masked loops. Make the final decision
32528 about whether use a fully-masked loop or not.
32529 (vect_estimate_min_profitable_iters): Do not assume that peeling
32530 for the number of iterations will be needed for fully-masked loops.
32531 (vectorizable_reduction): Disable fully-masked loops.
32532 (vectorizable_live_operation): Likewise.
32533 (vect_halve_mask_nunits): New function.
32534 (vect_double_mask_nunits): Likewise.
32535 (vect_record_loop_mask): Likewise.
32536 (vect_get_loop_mask): Likewise.
32537 (vect_transform_loop): Handle the case in which the final loop
32538 iteration might handle a partial vector. Call vect_set_loop_condition
32539 instead of slpeel_make_loop_iterate_ntimes.
32540 * tree-vect-stmts.c: Include tree-ssa-loop-niter.h and gimple-fold.h.
32541 (check_load_store_masking): New function.
32542 (prepare_load_store_mask): Likewise.
32543 (vectorizable_store): Handle fully-masked loops.
32544 (vectorizable_load): Likewise.
32545 (supportable_widening_operation): Use vect_halve_mask_nunits for
32546 booleans.
32547 (supportable_narrowing_operation): Likewise vect_double_mask_nunits.
32548 (vect_gen_while): New function.
32549 * config/aarch64/aarch64.md (umax<mode>3): New expander.
32550 (aarch64_uqdec<mode>): New insn.
32551
32552 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
32553 Alan Hayward <alan.hayward@arm.com>
32554 David Sherwood <david.sherwood@arm.com>
32555
32556 * optabs.def (reduc_and_scal_optab, reduc_ior_scal_optab)
32557 (reduc_xor_scal_optab): New optabs.
32558 * doc/md.texi (reduc_and_scal_@var{m}, reduc_ior_scal_@var{m})
32559 (reduc_xor_scal_@var{m}): Document.
32560 * doc/sourcebuild.texi (vect_logical_reduc): Likewise.
32561 * internal-fn.def (IFN_REDUC_AND, IFN_REDUC_IOR, IFN_REDUC_XOR): New
32562 internal functions.
32563 * fold-const-call.c (fold_const_call): Handle them.
32564 * tree-vect-loop.c (reduction_fn_for_scalar_code): Return the new
32565 internal functions for BIT_AND_EXPR, BIT_IOR_EXPR and BIT_XOR_EXPR.
32566 * config/aarch64/aarch64-sve.md (reduc_<bit_reduc>_scal_<mode>):
32567 (*reduc_<bit_reduc>_scal_<mode>): New patterns.
32568 * config/aarch64/iterators.md (UNSPEC_ANDV, UNSPEC_ORV)
32569 (UNSPEC_XORV): New unspecs.
32570 (optab): Add entries for them.
32571 (BITWISEV): New int iterator.
32572 (bit_reduc_op): New int attributes.
32573
32574 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
32575 Alan Hayward <alan.hayward@arm.com>
32576 David Sherwood <david.sherwood@arm.com>
32577
32578 * doc/md.texi (vec_shl_insert_@var{m}): New optab.
32579 * internal-fn.def (VEC_SHL_INSERT): New internal function.
32580 * optabs.def (vec_shl_insert_optab): New optab.
32581 * tree-vectorizer.h (can_duplicate_and_interleave_p): Declare.
32582 (duplicate_and_interleave): Likewise.
32583 * tree-vect-loop.c: Include internal-fn.h.
32584 (neutral_op_for_slp_reduction): New function, split out from
32585 get_initial_defs_for_reduction.
32586 (get_initial_def_for_reduction): Handle option 2 for variable-length
32587 vectors by loading the neutral value into a vector and then shifting
32588 the initial value into element 0.
32589 (get_initial_defs_for_reduction): Replace the code argument with
32590 the neutral value calculated by neutral_op_for_slp_reduction.
32591 Use gimple_build_vector for constant-length vectors.
32592 Use IFN_VEC_SHL_INSERT for variable-length vectors if all
32593 but the first group_size elements have a neutral value.
32594 Use duplicate_and_interleave otherwise.
32595 (vect_create_epilog_for_reduction): Take a neutral_op parameter.
32596 Update call to get_initial_defs_for_reduction. Handle SLP
32597 reductions for variable-length vectors by creating one vector
32598 result for each scalar result, with the elements associated
32599 with other scalar results stubbed out with the neutral value.
32600 (vectorizable_reduction): Call neutral_op_for_slp_reduction.
32601 Require IFN_VEC_SHL_INSERT for double reductions on
32602 variable-length vectors, or SLP reductions that have
32603 a neutral value. Require can_duplicate_and_interleave_p
32604 support for variable-length unchained SLP reductions if there
32605 is no neutral value, such as for MIN/MAX reductions. Also require
32606 the number of vector elements to be a multiple of the number of
32607 SLP statements when doing variable-length unchained SLP reductions.
32608 Update call to vect_create_epilog_for_reduction.
32609 * tree-vect-slp.c (can_duplicate_and_interleave_p): Make public
32610 and remove initial values.
32611 (duplicate_and_interleave): Make public.
32612 * config/aarch64/aarch64.md (UNSPEC_INSR): New unspec.
32613 * config/aarch64/aarch64-sve.md (vec_shl_insert_<mode>): New insn.
32614
32615 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
32616 Alan Hayward <alan.hayward@arm.com>
32617 David Sherwood <david.sherwood@arm.com>
32618
32619 * tree-vect-slp.c: Include gimple-fold.h and internal-fn.h
32620 (can_duplicate_and_interleave_p): New function.
32621 (vect_get_and_check_slp_defs): Take the vector of statements
32622 rather than just the current one. Remove excess parentheses.
32623 Restriction rejectinon of vect_constant_def and vect_external_def
32624 for variable-length vectors to boolean types, or types for which
32625 can_duplicate_and_interleave_p is false.
32626 (vect_build_slp_tree_2): Update call to vect_get_and_check_slp_defs.
32627 (duplicate_and_interleave): New function.
32628 (vect_get_constant_vectors): Use gimple_build_vector for
32629 constant-length vectors and suitable variable-length constant
32630 vectors. Use duplicate_and_interleave for other variable-length
32631 vectors. Don't defer the update when inserting new statements.
32632
32633 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
32634 Alan Hayward <alan.hayward@arm.com>
32635 David Sherwood <david.sherwood@arm.com>
32636
32637 * tree-vect-loop.c (vect_estimate_min_profitable_iters): Make sure
32638 min_profitable_iters doesn't go negative.
32639
32640 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
32641 Alan Hayward <alan.hayward@arm.com>
32642 David Sherwood <david.sherwood@arm.com>
32643
32644 * doc/md.texi (vec_mask_load_lanes@var{m}@var{n}): Document.
32645 (vec_mask_store_lanes@var{m}@var{n}): Likewise.
32646 * optabs.def (vec_mask_load_lanes_optab): New optab.
32647 (vec_mask_store_lanes_optab): Likewise.
32648 * internal-fn.def (MASK_LOAD_LANES): New internal function.
32649 (MASK_STORE_LANES): Likewise.
32650 * internal-fn.c (mask_load_lanes_direct): New macro.
32651 (mask_store_lanes_direct): Likewise.
32652 (expand_mask_load_optab_fn): Handle masked operations.
32653 (expand_mask_load_lanes_optab_fn): New macro.
32654 (expand_mask_store_optab_fn): Handle masked operations.
32655 (expand_mask_store_lanes_optab_fn): New macro.
32656 (direct_mask_load_lanes_optab_supported_p): Likewise.
32657 (direct_mask_store_lanes_optab_supported_p): Likewise.
32658 * tree-vectorizer.h (vect_store_lanes_supported): Take a masked_p
32659 parameter.
32660 (vect_load_lanes_supported): Likewise.
32661 * tree-vect-data-refs.c (strip_conversion): New function.
32662 (can_group_stmts_p): Likewise.
32663 (vect_analyze_data_ref_accesses): Use it instead of checking
32664 for a pair of assignments.
32665 (vect_store_lanes_supported): Take a masked_p parameter.
32666 (vect_load_lanes_supported): Likewise.
32667 * tree-vect-loop.c (vect_analyze_loop_2): Update calls to
32668 vect_store_lanes_supported and vect_load_lanes_supported.
32669 * tree-vect-slp.c (vect_analyze_slp_instance): Likewise.
32670 * tree-vect-stmts.c (get_group_load_store_type): Take a masked_p
32671 parameter. Don't allow gaps for masked accesses.
32672 Use vect_get_store_rhs. Update calls to vect_store_lanes_supported
32673 and vect_load_lanes_supported.
32674 (get_load_store_type): Take a masked_p parameter and update
32675 call to get_group_load_store_type.
32676 (vectorizable_store): Update call to get_load_store_type.
32677 Handle IFN_MASK_STORE_LANES.
32678 (vectorizable_load): Update call to get_load_store_type.
32679 Handle IFN_MASK_LOAD_LANES.
32680
32681 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
32682 Alan Hayward <alan.hayward@arm.com>
32683 David Sherwood <david.sherwood@arm.com>
32684
32685 * config/aarch64/aarch64-modes.def: Define x2, x3 and x4 vector
32686 modes for SVE.
32687 * config/aarch64/aarch64-protos.h
32688 (aarch64_sve_struct_memory_operand_p): Declare.
32689 * config/aarch64/iterators.md (SVE_STRUCT): New mode iterator.
32690 (vector_count, insn_length, VSINGLE, vsingle): New mode attributes.
32691 (VPRED, vpred): Handle SVE structure modes.
32692 * config/aarch64/constraints.md (Utx): New constraint.
32693 * config/aarch64/predicates.md (aarch64_sve_struct_memory_operand)
32694 (aarch64_sve_struct_nonimmediate_operand): New predicates.
32695 * config/aarch64/aarch64.md (UNSPEC_LDN, UNSPEC_STN): New unspecs.
32696 * config/aarch64/aarch64-sve.md (mov<mode>, *aarch64_sve_mov<mode>_le)
32697 (*aarch64_sve_mov<mode>_be, pred_mov<mode>): New patterns for
32698 structure modes. Split into pieces after RA.
32699 (vec_load_lanes<mode><vsingle>, vec_mask_load_lanes<mode><vsingle>)
32700 (vec_store_lanes<mode><vsingle>, vec_mask_store_lanes<mode><vsingle>):
32701 New patterns.
32702 * config/aarch64/aarch64.c (aarch64_classify_vector_mode): Handle
32703 SVE structure modes.
32704 (aarch64_classify_address): Likewise.
32705 (sizetochar): Move earlier in file.
32706 (aarch64_print_operand): Handle SVE register lists.
32707 (aarch64_array_mode): New function.
32708 (aarch64_sve_struct_memory_operand_p): Likewise.
32709 (TARGET_ARRAY_MODE): Redefine.
32710
32711 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
32712 Alan Hayward <alan.hayward@arm.com>
32713 David Sherwood <david.sherwood@arm.com>
32714
32715 * target.def (array_mode): New target hook.
32716 * doc/tm.texi.in (TARGET_ARRAY_MODE): New hook.
32717 * doc/tm.texi: Regenerate.
32718 * hooks.h (hook_optmode_mode_uhwi_none): Declare.
32719 * hooks.c (hook_optmode_mode_uhwi_none): New function.
32720 * tree-vect-data-refs.c (vect_lanes_optab_supported_p): Use
32721 targetm.array_mode.
32722 * stor-layout.c (mode_for_array): Likewise. Support polynomial
32723 type sizes.
32724
32725 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
32726 Alan Hayward <alan.hayward@arm.com>
32727 David Sherwood <david.sherwood@arm.com>
32728
32729 * fold-const.c (fold_binary_loc): Check the argument types
32730 rather than the result type when testing for a vector operation.
32731
32732 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
32733
32734 * doc/tm.texi.in (DWARF_LAZY_REGISTER_VALUE): Document.
32735 * doc/tm.texi: Regenerate.
32736
32737 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
32738 Alan Hayward <alan.hayward@arm.com>
32739 David Sherwood <david.sherwood@arm.com>
32740
32741 * doc/invoke.texi (-msve-vector-bits=): Document new option.
32742 (sve): Document new AArch64 extension.
32743 * doc/md.texi (w): Extend the description of the AArch64
32744 constraint to include SVE vectors.
32745 (Upl, Upa): Document new AArch64 predicate constraints.
32746 * config/aarch64/aarch64-opts.h (aarch64_sve_vector_bits_enum): New
32747 enum.
32748 * config/aarch64/aarch64.opt (sve_vector_bits): New enum.
32749 (msve-vector-bits=): New option.
32750 * config/aarch64/aarch64-option-extensions.def (fp, simd): Disable
32751 SVE when these are disabled.
32752 (sve): New extension.
32753 * config/aarch64/aarch64-modes.def: Define SVE vector and predicate
32754 modes. Adjust their number of units based on aarch64_sve_vg.
32755 (MAX_BITSIZE_MODE_ANY_MODE): Define.
32756 * config/aarch64/aarch64-protos.h (ADDR_QUERY_ANY): New
32757 aarch64_addr_query_type.
32758 (aarch64_const_vec_all_same_in_range_p, aarch64_sve_pred_mode)
32759 (aarch64_sve_cnt_immediate_p, aarch64_sve_addvl_addpl_immediate_p)
32760 (aarch64_sve_inc_dec_immediate_p, aarch64_add_offset_temporaries)
32761 (aarch64_split_add_offset, aarch64_output_sve_cnt_immediate)
32762 (aarch64_output_sve_addvl_addpl, aarch64_output_sve_inc_dec_immediate)
32763 (aarch64_output_sve_mov_immediate, aarch64_output_ptrue): Declare.
32764 (aarch64_simd_imm_zero_p): Delete.
32765 (aarch64_check_zero_based_sve_index_immediate): Declare.
32766 (aarch64_sve_index_immediate_p, aarch64_sve_arith_immediate_p)
32767 (aarch64_sve_bitmask_immediate_p, aarch64_sve_dup_immediate_p)
32768 (aarch64_sve_cmp_immediate_p, aarch64_sve_float_arith_immediate_p)
32769 (aarch64_sve_float_mul_immediate_p): Likewise.
32770 (aarch64_classify_symbol): Take the offset as a HOST_WIDE_INT
32771 rather than an rtx.
32772 (aarch64_sve_ld1r_operand_p, aarch64_sve_ldr_operand_p): Declare.
32773 (aarch64_expand_mov_immediate): Take a gen_vec_duplicate callback.
32774 (aarch64_emit_sve_pred_move, aarch64_expand_sve_mem_move): Declare.
32775 (aarch64_expand_sve_vec_cmp_int, aarch64_expand_sve_vec_cmp_float)
32776 (aarch64_expand_sve_vcond, aarch64_expand_sve_vec_perm): Declare.
32777 (aarch64_regmode_natural_size): Likewise.
32778 * config/aarch64/aarch64.h (AARCH64_FL_SVE): New macro.
32779 (AARCH64_FL_V8_3, AARCH64_FL_RCPC, AARCH64_FL_DOTPROD): Shift
32780 left one place.
32781 (AARCH64_ISA_SVE, TARGET_SVE): New macros.
32782 (FIXED_REGISTERS, CALL_USED_REGISTERS, REGISTER_NAMES): Add entries
32783 for VG and the SVE predicate registers.
32784 (V_ALIASES): Add a "z"-prefixed alias.
32785 (FIRST_PSEUDO_REGISTER): Change to P15_REGNUM + 1.
32786 (AARCH64_DWARF_VG, AARCH64_DWARF_P0): New macros.
32787 (PR_REGNUM_P, PR_LO_REGNUM_P): Likewise.
32788 (PR_LO_REGS, PR_HI_REGS, PR_REGS): New reg_classes.
32789 (REG_CLASS_NAMES): Add entries for them.
32790 (REG_CLASS_CONTENTS): Likewise. Update ALL_REGS to include VG
32791 and the predicate registers.
32792 (aarch64_sve_vg): Declare.
32793 (BITS_PER_SVE_VECTOR, BYTES_PER_SVE_VECTOR, BYTES_PER_SVE_PRED)
32794 (SVE_BYTE_MODE, MAX_COMPILE_TIME_VEC_BYTES): New macros.
32795 (REGMODE_NATURAL_SIZE): Define.
32796 * config/aarch64/aarch64-c.c (aarch64_update_cpp_builtins): Handle
32797 SVE macros.
32798 * config/aarch64/aarch64.c: Include cfgrtl.h.
32799 (simd_immediate_info): Add a constructor for series vectors,
32800 and an associated step field.
32801 (aarch64_sve_vg): New variable.
32802 (aarch64_dbx_register_number): Handle VG and the predicate registers.
32803 (aarch64_vect_struct_mode_p, aarch64_vector_mode_p): Delete.
32804 (VEC_ADVSIMD, VEC_SVE_DATA, VEC_SVE_PRED, VEC_STRUCT, VEC_ANY_SVE)
32805 (VEC_ANY_DATA, VEC_STRUCT): New constants.
32806 (aarch64_advsimd_struct_mode_p, aarch64_sve_pred_mode_p)
32807 (aarch64_classify_vector_mode, aarch64_vector_data_mode_p)
32808 (aarch64_sve_data_mode_p, aarch64_sve_pred_mode)
32809 (aarch64_get_mask_mode): New functions.
32810 (aarch64_hard_regno_nregs): Handle SVE data modes for FP_REGS
32811 and FP_LO_REGS. Handle PR_REGS, PR_LO_REGS and PR_HI_REGS.
32812 (aarch64_hard_regno_mode_ok): Handle VG. Also handle the SVE
32813 predicate modes and predicate registers. Explicitly restrict
32814 GPRs to modes of 16 bytes or smaller. Only allow FP registers
32815 to store a vector mode if it is recognized by
32816 aarch64_classify_vector_mode.
32817 (aarch64_regmode_natural_size): New function.
32818 (aarch64_hard_regno_caller_save_mode): Return the original mode
32819 for predicates.
32820 (aarch64_sve_cnt_immediate_p, aarch64_output_sve_cnt_immediate)
32821 (aarch64_sve_addvl_addpl_immediate_p, aarch64_output_sve_addvl_addpl)
32822 (aarch64_sve_inc_dec_immediate_p, aarch64_output_sve_inc_dec_immediate)
32823 (aarch64_add_offset_1_temporaries, aarch64_offset_temporaries): New
32824 functions.
32825 (aarch64_add_offset): Add a temp2 parameter. Assert that temp1
32826 does not overlap dest if the function is frame-related. Handle
32827 SVE constants.
32828 (aarch64_split_add_offset): New function.
32829 (aarch64_add_sp, aarch64_sub_sp): Add temp2 parameters and pass
32830 them aarch64_add_offset.
32831 (aarch64_allocate_and_probe_stack_space): Add a temp2 parameter
32832 and update call to aarch64_sub_sp.
32833 (aarch64_add_cfa_expression): New function.
32834 (aarch64_expand_prologue): Pass extra temporary registers to the
32835 functions above. Handle the case in which we need to emit new
32836 DW_CFA_expressions for registers that were originally saved
32837 relative to the stack pointer, but now have to be expressed
32838 relative to the frame pointer.
32839 (aarch64_output_mi_thunk): Pass extra temporary registers to the
32840 functions above.
32841 (aarch64_expand_epilogue): Likewise. Prevent inheritance of
32842 IP0 and IP1 values for SVE frames.
32843 (aarch64_expand_vec_series): New function.
32844 (aarch64_expand_sve_widened_duplicate): Likewise.
32845 (aarch64_expand_sve_const_vector): Likewise.
32846 (aarch64_expand_mov_immediate): Add a gen_vec_duplicate parameter.
32847 Handle SVE constants. Use emit_move_insn to move a force_const_mem
32848 into the register, rather than emitting a SET directly.
32849 (aarch64_emit_sve_pred_move, aarch64_expand_sve_mem_move)
32850 (aarch64_get_reg_raw_mode, offset_4bit_signed_scaled_p)
32851 (offset_6bit_unsigned_scaled_p, aarch64_offset_7bit_signed_scaled_p)
32852 (offset_9bit_signed_scaled_p): New functions.
32853 (aarch64_replicate_bitmask_imm): New function.
32854 (aarch64_bitmask_imm): Use it.
32855 (aarch64_cannot_force_const_mem): Reject expressions involving
32856 a CONST_POLY_INT. Update call to aarch64_classify_symbol.
32857 (aarch64_classify_index): Handle SVE indices, by requiring
32858 a plain register index with a scale that matches the element size.
32859 (aarch64_classify_address): Handle SVE addresses. Assert that
32860 the mode of the address is VOIDmode or an integer mode.
32861 Update call to aarch64_classify_symbol.
32862 (aarch64_classify_symbolic_expression): Update call to
32863 aarch64_classify_symbol.
32864 (aarch64_const_vec_all_in_range_p): New function.
32865 (aarch64_print_vector_float_operand): Likewise.
32866 (aarch64_print_operand): Handle 'N' and 'C'. Use "zN" rather than
32867 "vN" for FP registers with SVE modes. Handle (const ...) vectors
32868 and the FP immediates 1.0 and 0.5.
32869 (aarch64_print_address_internal): Handle SVE addresses.
32870 (aarch64_print_operand_address): Use ADDR_QUERY_ANY.
32871 (aarch64_regno_regclass): Handle predicate registers.
32872 (aarch64_secondary_reload): Handle big-endian reloads of SVE
32873 data modes.
32874 (aarch64_class_max_nregs): Handle SVE modes and predicate registers.
32875 (aarch64_rtx_costs): Check for ADDVL and ADDPL instructions.
32876 (aarch64_convert_sve_vector_bits): New function.
32877 (aarch64_override_options): Use it to handle -msve-vector-bits=.
32878 (aarch64_classify_symbol): Take the offset as a HOST_WIDE_INT
32879 rather than an rtx.
32880 (aarch64_legitimate_constant_p): Use aarch64_classify_vector_mode.
32881 Handle SVE vector and predicate modes. Accept VL-based constants
32882 that need only one temporary register, and VL offsets that require
32883 no temporary registers.
32884 (aarch64_conditional_register_usage): Mark the predicate registers
32885 as fixed if SVE isn't available.
32886 (aarch64_vector_mode_supported_p): Use aarch64_classify_vector_mode.
32887 Return true for SVE vector and predicate modes.
32888 (aarch64_simd_container_mode): Take the number of bits as a poly_int64
32889 rather than an unsigned int. Handle SVE modes.
32890 (aarch64_preferred_simd_mode): Update call accordingly. Handle
32891 SVE modes.
32892 (aarch64_autovectorize_vector_sizes): Add BYTES_PER_SVE_VECTOR
32893 if SVE is enabled.
32894 (aarch64_sve_index_immediate_p, aarch64_sve_arith_immediate_p)
32895 (aarch64_sve_bitmask_immediate_p, aarch64_sve_dup_immediate_p)
32896 (aarch64_sve_cmp_immediate_p, aarch64_sve_float_arith_immediate_p)
32897 (aarch64_sve_float_mul_immediate_p): New functions.
32898 (aarch64_sve_valid_immediate): New function.
32899 (aarch64_simd_valid_immediate): Use it as the fallback for SVE vectors.
32900 Explicitly reject structure modes. Check for INDEX constants.
32901 Handle PTRUE and PFALSE constants.
32902 (aarch64_check_zero_based_sve_index_immediate): New function.
32903 (aarch64_simd_imm_zero_p): Delete.
32904 (aarch64_mov_operand_p): Use aarch64_simd_valid_immediate for
32905 vector modes. Accept constants in the range of CNT[BHWD].
32906 (aarch64_simd_scalar_immediate_valid_for_move): Explicitly
32907 ask for an Advanced SIMD mode.
32908 (aarch64_sve_ld1r_operand_p, aarch64_sve_ldr_operand_p): New functions.
32909 (aarch64_simd_vector_alignment): Handle SVE predicates.
32910 (aarch64_vectorize_preferred_vector_alignment): New function.
32911 (aarch64_simd_vector_alignment_reachable): Use it instead of
32912 the vector size.
32913 (aarch64_shift_truncation_mask): Use aarch64_vector_data_mode_p.
32914 (aarch64_output_sve_mov_immediate, aarch64_output_ptrue): New
32915 functions.
32916 (MAX_VECT_LEN): Delete.
32917 (expand_vec_perm_d): Add a vec_flags field.
32918 (emit_unspec2, aarch64_expand_sve_vec_perm): New functions.
32919 (aarch64_evpc_trn, aarch64_evpc_uzp, aarch64_evpc_zip)
32920 (aarch64_evpc_ext): Don't apply a big-endian lane correction
32921 for SVE modes.
32922 (aarch64_evpc_rev): Rename to...
32923 (aarch64_evpc_rev_local): ...this. Use a predicated operation for SVE.
32924 (aarch64_evpc_rev_global): New function.
32925 (aarch64_evpc_dup): Enforce a 64-byte range for SVE DUP.
32926 (aarch64_evpc_tbl): Use MAX_COMPILE_TIME_VEC_BYTES instead of
32927 MAX_VECT_LEN.
32928 (aarch64_evpc_sve_tbl): New function.
32929 (aarch64_expand_vec_perm_const_1): Update after rename of
32930 aarch64_evpc_rev. Handle SVE permutes too, trying
32931 aarch64_evpc_rev_global and using aarch64_evpc_sve_tbl rather
32932 than aarch64_evpc_tbl.
32933 (aarch64_vectorize_vec_perm_const): Initialize vec_flags.
32934 (aarch64_sve_cmp_operand_p, aarch64_unspec_cond_code)
32935 (aarch64_gen_unspec_cond, aarch64_expand_sve_vec_cmp_int)
32936 (aarch64_emit_unspec_cond, aarch64_emit_unspec_cond_or)
32937 (aarch64_emit_inverted_unspec_cond, aarch64_expand_sve_vec_cmp_float)
32938 (aarch64_expand_sve_vcond): New functions.
32939 (aarch64_modes_tieable_p): Use aarch64_vector_data_mode_p instead
32940 of aarch64_vector_mode_p.
32941 (aarch64_dwarf_poly_indeterminate_value): New function.
32942 (aarch64_compute_pressure_classes): Likewise.
32943 (aarch64_can_change_mode_class): Likewise.
32944 (TARGET_GET_RAW_RESULT_MODE, TARGET_GET_RAW_ARG_MODE): Redefine.
32945 (TARGET_VECTORIZE_PREFERRED_VECTOR_ALIGNMENT): Likewise.
32946 (TARGET_VECTORIZE_GET_MASK_MODE): Likewise.
32947 (TARGET_DWARF_POLY_INDETERMINATE_VALUE): Likewise.
32948 (TARGET_COMPUTE_PRESSURE_CLASSES): Likewise.
32949 (TARGET_CAN_CHANGE_MODE_CLASS): Likewise.
32950 * config/aarch64/constraints.md (Upa, Upl, Uav, Uat, Usv, Usi, Utr)
32951 (Uty, Dm, vsa, vsc, vsd, vsi, vsn, vsl, vsm, vsA, vsM, vsN): New
32952 constraints.
32953 (Dn, Dl, Dr): Accept const as well as const_vector.
32954 (Dz): Likewise. Compare against CONST0_RTX.
32955 * config/aarch64/iterators.md: Refer to "Advanced SIMD" instead
32956 of "vector" where appropriate.
32957 (SVE_ALL, SVE_BH, SVE_BHS, SVE_BHSI, SVE_HSDI, SVE_HSF, SVE_SD)
32958 (SVE_SDI, SVE_I, SVE_F, PRED_ALL, PRED_BHS): New mode iterators.
32959 (UNSPEC_SEL, UNSPEC_ANDF, UNSPEC_IORF, UNSPEC_XORF, UNSPEC_COND_LT)
32960 (UNSPEC_COND_LE, UNSPEC_COND_EQ, UNSPEC_COND_NE, UNSPEC_COND_GE)
32961 (UNSPEC_COND_GT, UNSPEC_COND_LO, UNSPEC_COND_LS, UNSPEC_COND_HS)
32962 (UNSPEC_COND_HI, UNSPEC_COND_UO): New unspecs.
32963 (Vetype, VEL, Vel, VWIDE, Vwide, vw, vwcore, V_INT_EQUIV)
32964 (v_int_equiv): Extend to SVE modes.
32965 (Vesize, V128, v128, Vewtype, V_FP_EQUIV, v_fp_equiv, VPRED): New
32966 mode attributes.
32967 (LOGICAL_OR, SVE_INT_UNARY, SVE_FP_UNARY): New code iterators.
32968 (optab): Handle popcount, smin, smax, umin, umax, abs and sqrt.
32969 (logical_nn, lr, sve_int_op, sve_fp_op): New code attributs.
32970 (LOGICALF, OPTAB_PERMUTE, UNPACK, UNPACK_UNSIGNED, SVE_COND_INT_CMP)
32971 (SVE_COND_FP_CMP): New int iterators.
32972 (perm_hilo): Handle the new unpack unspecs.
32973 (optab, logicalf_op, su, perm_optab, cmp_op, imm_con): New int
32974 attributes.
32975 * config/aarch64/predicates.md (aarch64_sve_cnt_immediate)
32976 (aarch64_sve_addvl_addpl_immediate, aarch64_split_add_offset_immediate)
32977 (aarch64_pluslong_or_poly_operand, aarch64_nonmemory_operand)
32978 (aarch64_equality_operator, aarch64_constant_vector_operand)
32979 (aarch64_sve_ld1r_operand, aarch64_sve_ldr_operand): New predicates.
32980 (aarch64_sve_nonimmediate_operand): Likewise.
32981 (aarch64_sve_general_operand): Likewise.
32982 (aarch64_sve_dup_operand, aarch64_sve_arith_immediate): Likewise.
32983 (aarch64_sve_sub_arith_immediate, aarch64_sve_inc_dec_immediate)
32984 (aarch64_sve_logical_immediate, aarch64_sve_mul_immediate): Likewise.
32985 (aarch64_sve_dup_immediate, aarch64_sve_cmp_vsc_immediate): Likewise.
32986 (aarch64_sve_cmp_vsd_immediate, aarch64_sve_index_immediate): Likewise.
32987 (aarch64_sve_float_arith_immediate): Likewise.
32988 (aarch64_sve_float_arith_with_sub_immediate): Likewise.
32989 (aarch64_sve_float_mul_immediate, aarch64_sve_arith_operand): Likewise.
32990 (aarch64_sve_add_operand, aarch64_sve_logical_operand): Likewise.
32991 (aarch64_sve_lshift_operand, aarch64_sve_rshift_operand): Likewise.
32992 (aarch64_sve_mul_operand, aarch64_sve_cmp_vsc_operand): Likewise.
32993 (aarch64_sve_cmp_vsd_operand, aarch64_sve_index_operand): Likewise.
32994 (aarch64_sve_float_arith_operand): Likewise.
32995 (aarch64_sve_float_arith_with_sub_operand): Likewise.
32996 (aarch64_sve_float_mul_operand): Likewise.
32997 (aarch64_sve_vec_perm_operand): Likewise.
32998 (aarch64_pluslong_operand): Include aarch64_sve_addvl_addpl_immediate.
32999 (aarch64_mov_operand): Accept const_poly_int and const_vector.
33000 (aarch64_simd_lshift_imm, aarch64_simd_rshift_imm): Accept const
33001 as well as const_vector.
33002 (aarch64_simd_imm_zero, aarch64_simd_imm_minus_one): Move earlier
33003 in file. Use CONST0_RTX and CONSTM1_RTX.
33004 (aarch64_simd_or_scalar_imm_zero): Likewise. Add match_codes.
33005 (aarch64_simd_reg_or_zero): Accept const as well as const_vector.
33006 Use aarch64_simd_imm_zero.
33007 * config/aarch64/aarch64-sve.md: New file.
33008 * config/aarch64/aarch64.md: Include it.
33009 (VG_REGNUM, P0_REGNUM, P7_REGNUM, P15_REGNUM): New register numbers.
33010 (UNSPEC_REV, UNSPEC_LD1_SVE, UNSPEC_ST1_SVE, UNSPEC_MERGE_PTRUE)
33011 (UNSPEC_PTEST_PTRUE, UNSPEC_UNPACKSHI, UNSPEC_UNPACKUHI)
33012 (UNSPEC_UNPACKSLO, UNSPEC_UNPACKULO, UNSPEC_PACK)
33013 (UNSPEC_FLOAT_CONVERT, UNSPEC_WHILE_LO): New unspec constants.
33014 (sve): New attribute.
33015 (enabled): Disable instructions with the sve attribute unless
33016 TARGET_SVE.
33017 (movqi, movhi): Pass CONST_POLY_INT operaneds through
33018 aarch64_expand_mov_immediate.
33019 (*mov<mode>_aarch64, *movsi_aarch64, *movdi_aarch64): Handle
33020 CNT[BHSD] immediates.
33021 (movti): Split CONST_POLY_INT moves into two halves.
33022 (add<mode>3): Accept aarch64_pluslong_or_poly_operand.
33023 Split additions that need a temporary here if the destination
33024 is the stack pointer.
33025 (*add<mode>3_aarch64): Handle ADDVL and ADDPL immediates.
33026 (*add<mode>3_poly_1): New instruction.
33027 (set_clobber_cc): New expander.
33028
33029 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
33030
33031 * simplify-rtx.c (simplify_immed_subreg): Add an inner_bytes
33032 parameter and use it instead of GET_MODE_SIZE (innermode). Use
33033 inner_bytes * BITS_PER_UNIT instead of GET_MODE_BITSIZE (innermode).
33034 Use CEIL (inner_bytes, GET_MODE_UNIT_SIZE (innermode)) instead of
33035 GET_MODE_NUNITS (innermode). Also add a first_elem parameter.
33036 Change innermode from fixed_mode_size to machine_mode.
33037 (simplify_subreg): Update call accordingly. Handle a constant-sized
33038 subreg of a variable-length CONST_VECTOR.
33039
33040 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
33041 Alan Hayward <alan.hayward@arm.com>
33042 David Sherwood <david.sherwood@arm.com>
33043
33044 * tree-ssa-address.c (mem_ref_valid_without_offset_p): New function.
33045 (add_offset_to_base): New function, split out from...
33046 (create_mem_ref): ...here. When handling a scale other than 1,
33047 check first whether the address is valid without the offset.
33048 Add it into the base if so, leaving the index and scale as-is.
33049
33050 2018-01-12 Jakub Jelinek <jakub@redhat.com>
33051
33052 PR c++/83778
33053 * config/rs6000/rs6000-c.c (altivec_resolve_overloaded_builtin): Call
33054 fold_for_warn before checking if arg2 is INTEGER_CST.
33055
33056 2018-01-12 Segher Boessenkool <segher@kernel.crashing.org>
33057
33058 * config/rs6000/predicates.md (load_multiple_operation): Delete.
33059 (store_multiple_operation): Delete.
33060 * config/rs6000/rs6000-cpus.def (601): Remove MASK_STRING.
33061 * config/rs6000/rs6000-protos.h (rs6000_output_load_multiple): Delete.
33062 * config/rs6000/rs6000-string.c (expand_block_move): Delete everything
33063 guarded by TARGET_STRING.
33064 (rs6000_output_load_multiple): Delete.
33065 * config/rs6000/rs6000.c (rs6000_option_override_internal): Delete
33066 OPTION_MASK_STRING / TARGET_STRING handling.
33067 (print_operand) <'N', 'O'>: Add comment that these are unused now.
33068 (const rs6000_opt_masks) <"string">: Change mask to 0.
33069 * config/rs6000/rs6000.h (TARGET_DEFAULT): Remove MASK_STRING.
33070 (MASK_STRING): Delete.
33071 * config/rs6000/rs6000.md (*mov<mode>_string): Delete TARGET_STRING
33072 parts. Simplify.
33073 (load_multiple): Delete.
33074 (*ldmsi8): Delete.
33075 (*ldmsi7): Delete.
33076 (*ldmsi6): Delete.
33077 (*ldmsi5): Delete.
33078 (*ldmsi4): Delete.
33079 (*ldmsi3): Delete.
33080 (store_multiple): Delete.
33081 (*stmsi8): Delete.
33082 (*stmsi7): Delete.
33083 (*stmsi6): Delete.
33084 (*stmsi5): Delete.
33085 (*stmsi4): Delete.
33086 (*stmsi3): Delete.
33087 (movmemsi_8reg): Delete.
33088 (corresponding unnamed define_insn): Delete.
33089 (movmemsi_6reg): Delete.
33090 (corresponding unnamed define_insn): Delete.
33091 (movmemsi_4reg): Delete.
33092 (corresponding unnamed define_insn): Delete.
33093 (movmemsi_2reg): Delete.
33094 (corresponding unnamed define_insn): Delete.
33095 (movmemsi_1reg): Delete.
33096 (corresponding unnamed define_insn): Delete.
33097 * config/rs6000/rs6000.opt (mno-string): New.
33098 (mstring): Replace by deprecation warning stub.
33099 * doc/invoke.texi (RS/6000 and PowerPC Options): Delete -mstring.
33100
33101 2018-01-12 Jakub Jelinek <jakub@redhat.com>
33102
33103 * regrename.c (regrename_do_replace): If replacing the same
33104 reg multiple times, try to reuse last created gen_raw_REG.
33105
33106 PR debug/81155
33107 * bb-reorder.c (pass_partition_blocks::gate): In lto don't partition
33108 main to workaround a bug in GDB.
33109
33110 2018-01-12 Tom de Vries <tom@codesourcery.com>
33111
33112 PR target/83737
33113 * config.gcc (nvptx*-*-*): Set use_gcc_stdint=wrap.
33114
33115 2018-01-12 Vladimir Makarov <vmakarov@redhat.com>
33116
33117 PR rtl-optimization/80481
33118 * ira-color.c (get_cap_member): New function.
33119 (allocnos_conflict_by_live_ranges_p): Use it.
33120 (slot_coalesced_allocno_live_ranges_intersect_p): Add assert.
33121 (setup_slot_coalesced_allocno_live_ranges): Ditto.
33122
33123 2018-01-12 Uros Bizjak <ubizjak@gmail.com>
33124
33125 PR target/83628
33126 * config/alpha/alpha.md (*saddsi_1): New insn_ans_split pattern.
33127 (*saddl_se_1): Ditto.
33128 (*ssubsi_1): Ditto.
33129 (*ssubl_se_1): Ditto.
33130
33131 2018-01-12 Richard Sandiford <richard.sandiford@linaro.org>
33132
33133 * tree-predcom.c (aff_combination_dr_offset): Use wi::to_poly_widest
33134 rather than wi::to_widest for DR_INITs.
33135 * tree-vect-data-refs.c (vect_find_same_alignment_drs): Use
33136 wi::to_poly_offset rather than wi::to_offset for DR_INIT.
33137 (vect_analyze_data_ref_accesses): Require both DR_INITs to be
33138 INTEGER_CSTs.
33139 (vect_analyze_group_access_1): Note that here.
33140
33141 2018-01-12 Richard Sandiford <richard.sandiford@linaro.org>
33142
33143 * tree-vectorizer.c (get_vec_alignment_for_array_type): Handle
33144 polynomial type sizes.
33145
33146 2018-01-12 Richard Sandiford <richard.sandiford@linaro.org>
33147
33148 * gimplify.c (gimple_add_tmp_var_fn): Allow variables to have a
33149 poly_uint64 size, rather than requiring an unsigned HOST_WIDE_INT size.
33150 (gimple_add_tmp_var): Likewise.
33151
33152 2018-01-12 Martin Liska <mliska@suse.cz>
33153
33154 * gimple.c (gimple_alloc_counts): Use uint64_t instead of int.
33155 (gimple_alloc_sizes): Likewise.
33156 (dump_gimple_statistics): Use PRIu64 in printf format.
33157 * gimple.h: Change uint64_t to int.
33158
33159 2018-01-12 Martin Liska <mliska@suse.cz>
33160
33161 * tree-core.h: Use uint64_t instead of int.
33162 * tree.c (tree_node_counts): Likewise.
33163 (tree_node_sizes): Likewise.
33164 (dump_tree_statistics): Use PRIu64 in printf format.
33165
33166 2018-01-12 Martin Liska <mliska@suse.cz>
33167
33168 * Makefile.in: As qsort_chk is implemented in vec.c, add
33169 vec.o to linkage of gencfn-macros.
33170 * tree.c (build_new_poly_int_cst): Add CXX_MEM_STAT_INFO as it's
33171 passing the info to record_node_allocation_statistics.
33172 (test_vector_cst_patterns): Add CXX_MEM_STAT_INFO to declaration
33173 and pass the info.
33174 * ggc-common.c (struct ggc_usage): Add operator== and use
33175 it in operator< and compare function.
33176 * mem-stats.h (struct mem_usage): Likewise.
33177 * vec.c (struct vec_usage): Remove operator< and compare
33178 function. Can be simply inherited.
33179
33180 2018-01-12 Martin Jambor <mjambor@suse.cz>
33181
33182 PR target/81616
33183 * params.def: New parameter PARAM_AVOID_FMA_MAX_BITS.
33184 * tree-ssa-math-opts.c: Include domwalk.h.
33185 (convert_mult_to_fma_1): New function.
33186 (fma_transformation_info): New type.
33187 (fma_deferring_state): Likewise.
33188 (cancel_fma_deferring): New function.
33189 (result_of_phi): Likewise.
33190 (last_fma_candidate_feeds_initial_phi): Likewise.
33191 (convert_mult_to_fma): Added deferring logic, split actual
33192 transformation to convert_mult_to_fma_1.
33193 (math_opts_dom_walker): New type.
33194 (math_opts_dom_walker::after_dom_children): New method, body moved
33195 here from pass_optimize_widening_mul::execute, added deferring logic
33196 bits.
33197 (pass_optimize_widening_mul::execute): Moved most of code to
33198 math_opts_dom_walker::after_dom_children.
33199 * config/i386/x86-tune.def (X86_TUNE_AVOID_128FMA_CHAINS): New.
33200 * config/i386/i386.c (ix86_option_override_internal): Added
33201 maybe_setting of PARAM_AVOID_FMA_MAX_BITS.
33202
33203 2018-01-12 Richard Biener <rguenther@suse.de>
33204
33205 PR debug/83157
33206 * dwarf2out.c (gen_variable_die): Do not reset old_die for
33207 inline instance vars.
33208
33209 2018-01-12 Oleg Endo <olegendo@gcc.gnu.org>
33210
33211 PR target/81819
33212 * config/rx/rx.c (rx_is_restricted_memory_address):
33213 Handle SUBREG case.
33214
33215 2018-01-12 Richard Biener <rguenther@suse.de>
33216
33217 PR tree-optimization/80846
33218 * target.def (split_reduction): New target hook.
33219 * targhooks.c (default_split_reduction): New function.
33220 * targhooks.h (default_split_reduction): Declare.
33221 * tree-vect-loop.c (vect_create_epilog_for_reduction): If the
33222 target requests first reduce vectors by combining low and high
33223 parts.
33224 * tree-vect-stmts.c (vect_gen_perm_mask_any): Adjust.
33225 (get_vectype_for_scalar_type_and_size): Export.
33226 * tree-vectorizer.h (get_vectype_for_scalar_type_and_size): Declare.
33227 * doc/tm.texi.in (TARGET_VECTORIZE_SPLIT_REDUCTION): Document.
33228 * doc/tm.texi: Regenerate.
33229 * config/i386/i386.c (ix86_split_reduction): Implement
33230 TARGET_VECTORIZE_SPLIT_REDUCTION.
33231
33232 2018-01-12 Eric Botcazou <ebotcazou@adacore.com>
33233
33234 PR target/83368
33235 * config/sparc/sparc.h (PIC_OFFSET_TABLE_REGNUM): Set to INVALID_REGNUM
33236 in PIC mode except for TARGET_VXWORKS_RTP.
33237 * config/sparc/sparc.c: Include cfgrtl.h.
33238 (TARGET_INIT_PIC_REG): Define.
33239 (TARGET_USE_PSEUDO_PIC_REG): Likewise.
33240 (sparc_pic_register_p): New predicate.
33241 (sparc_legitimate_address_p): Use it.
33242 (sparc_legitimize_pic_address): Likewise.
33243 (sparc_delegitimize_address): Likewise.
33244 (sparc_mode_dependent_address_p): Likewise.
33245 (gen_load_pcrel_sym): Remove 4th parameter.
33246 (load_got_register): Adjust call to above. Remove obsolete stuff.
33247 (sparc_expand_prologue): Do not call load_got_register here.
33248 (sparc_flat_expand_prologue): Likewise.
33249 (sparc_output_mi_thunk): Set the pic_offset_table_rtx object.
33250 (sparc_use_pseudo_pic_reg): New function.
33251 (sparc_init_pic_reg): Likewise.
33252 * config/sparc/sparc.md (vxworks_load_got): Set the GOT register.
33253 (builtin_setjmp_receiver): Enable only for TARGET_VXWORKS_RTP.
33254
33255 2018-01-12 Christophe Lyon <christophe.lyon@linaro.org>
33256
33257 * doc/sourcebuild.texi (Effective-Target Keywords, Other attributes):
33258 Add item for branch_cost.
33259
33260 2018-01-12 Eric Botcazou <ebotcazou@adacore.com>
33261
33262 PR rtl-optimization/83565
33263 * rtlanal.c (nonzero_bits1): On WORD_REGISTER_OPERATIONS machines, do
33264 not extend the result to a larger mode for rotate operations.
33265 (num_sign_bit_copies1): Likewise.
33266
33267 2018-01-12 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
33268
33269 PR target/40411
33270 * config/sol2.h (STARTFILE_ARCH_SPEC): Don't use with -shared or
33271 -symbolic.
33272 Use values-Xc.o for -pedantic.
33273 Link with values-xpg4.o for C90, values-xpg6.o otherwise.
33274
33275 2018-01-12 Martin Liska <mliska@suse.cz>
33276
33277 PR ipa/83054
33278 * ipa-devirt.c (final_warning_record::grow_type_warnings):
33279 New function.
33280 (possible_polymorphic_call_targets): Use it.
33281 (ipa_devirt): Likewise.
33282
33283 2018-01-12 Martin Liska <mliska@suse.cz>
33284
33285 * profile-count.h (enum profile_quality): Use 0 as invalid
33286 enum value of profile_quality.
33287
33288 2018-01-12 Chung-Ju Wu <jasonwucj@gmail.com>
33289
33290 * doc/invoke.texi (NDS32 Options): Add -mext-perf, -mext-perf2 and
33291 -mext-string options.
33292
33293 2018-01-12 Richard Biener <rguenther@suse.de>
33294
33295 * lto-streamer-out.c (DFS::DFS_write_tree_body): Process
33296 DECL_DEBUG_EXPR conditional on DECL_HAS_DEBUG_EXPR_P.
33297 * tree-streamer-in.c (lto_input_ts_decl_common_tree_pointers):
33298 Likewise.
33299 * tree-streamer-out.c (write_ts_decl_common_tree_pointers): Likewise.
33300
33301 2018-01-11 Michael Meissner <meissner@linux.vnet.ibm.com>
33302
33303 * configure.ac (--with-long-double-format): Add support for the
33304 configuration option to change the default long double format on
33305 PowerPC systems.
33306 * config.gcc (powerpc*-linux*-*): Likewise.
33307 * configure: Regenerate.
33308 * config/rs6000/rs6000-c.c (rs6000_cpu_cpp_builtins): If long
33309 double is IEEE, define __KC__ and __KF__ to allow floatn.h to be
33310 used without modification.
33311
33312 2018-01-11 Bill Schmidt <wschmidt@linux.vnet.ibm.com>
33313
33314 * config/rs6000/rs6000-builtin.def (BU_P7_MISC_X): New #define.
33315 (SPEC_BARRIER): New instantiation of BU_P7_MISC_X.
33316 * config/rs6000/rs6000.c (rs6000_expand_builtin): Handle
33317 MISC_BUILTIN_SPEC_BARRIER.
33318 (rs6000_init_builtins): Likewise.
33319 * config/rs6000/rs6000.md (UNSPECV_SPEC_BARRIER): New UNSPECV
33320 enum value.
33321 (speculation_barrier): New define_insn.
33322 * doc/extend.texi: Document __builtin_speculation_barrier.
33323
33324 2018-01-11 Jakub Jelinek <jakub@redhat.com>
33325
33326 PR target/83203
33327 * config/i386/i386.c (ix86_expand_vector_init_one_nonzero): If one_var
33328 is 0, for V{8,16}S[IF] and V[48]D[IF]mode use gen_vec_set<mode>_0.
33329 * config/i386/sse.md (VI8_AVX_AVX512F, VI4F_256_512): New mode
33330 iterators.
33331 (ssescalarmodesuffix): Add 512-bit vectors. Use "d" or "q" for
33332 integral modes instead of "ss" and "sd".
33333 (vec_set<mode>_0): New define_insns for 256-bit and 512-bit
33334 vectors with 32-bit and 64-bit elements.
33335 (vecdupssescalarmodesuffix): New mode attribute.
33336 (vec_dup<mode>): Use it.
33337
33338 2018-01-11 H.J. Lu <hongjiu.lu@intel.com>
33339
33340 PR target/83330
33341 * config/i386/i386.c (ix86_compute_frame_layout): Align stack
33342 frame if argument is passed on stack.
33343
33344 2018-01-11 Jakub Jelinek <jakub@redhat.com>
33345
33346 PR target/82682
33347 * ree.c (combine_reaching_defs): Optimize also
33348 reg2=exp; reg1=reg2; reg2=any_extend(reg1); into
33349 reg2=any_extend(exp); reg1=reg2;, formatting fix.
33350
33351 2018-01-11 Jan Hubicka <hubicka@ucw.cz>
33352
33353 PR middle-end/83189
33354 * gimple-ssa-isolate-paths.c (isolate_path): Fix profile update.
33355
33356 2018-01-11 Jan Hubicka <hubicka@ucw.cz>
33357
33358 PR middle-end/83718
33359 * tree-inline.c (copy_cfg_body): Adjust num&den for scaling
33360 after they are computed.
33361
33362 2018-01-11 Bin Cheng <bin.cheng@arm.com>
33363
33364 PR tree-optimization/83695
33365 * gimple-loop-linterchange.cc
33366 (tree_loop_interchange::interchange_loops): Call scev_reset_htab to
33367 reset cached scev information after interchange.
33368 (pass_linterchange::execute): Remove call to scev_reset_htab.
33369
33370 2018-01-11 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
33371
33372 * config/arm/arm_neon.h (vfmlal_lane_low_u32, vfmlal_lane_high_u32,
33373 vfmlalq_laneq_low_u32, vfmlalq_lane_low_u32, vfmlal_laneq_low_u32,
33374 vfmlalq_laneq_high_u32, vfmlalq_lane_high_u32, vfmlal_laneq_high_u32,
33375 vfmlsl_lane_low_u32, vfmlsl_lane_high_u32, vfmlslq_laneq_low_u32,
33376 vfmlslq_lane_low_u32, vfmlsl_laneq_low_u32, vfmlslq_laneq_high_u32,
33377 vfmlslq_lane_high_u32, vfmlsl_laneq_high_u32): Define.
33378 * config/arm/arm_neon_builtins.def (vfmal_lane_low,
33379 vfmal_lane_lowv4hf, vfmal_lane_lowv8hf, vfmal_lane_high,
33380 vfmal_lane_highv4hf, vfmal_lane_highv8hf, vfmsl_lane_low,
33381 vfmsl_lane_lowv4hf, vfmsl_lane_lowv8hf, vfmsl_lane_high,
33382 vfmsl_lane_highv4hf, vfmsl_lane_highv8hf): New sets of builtins.
33383 * config/arm/iterators.md (VFMLSEL2, vfmlsel2): New mode attributes.
33384 (V_lane_reg): Likewise.
33385 * config/arm/neon.md (neon_vfm<vfml_op>l_lane_<vfml_half><VCVTF:mode>):
33386 New define_expand.
33387 (neon_vfm<vfml_op>l_lane_<vfml_half><vfmlsel2><mode>): Likewise.
33388 (vfmal_lane_low<mode>_intrinsic,
33389 vfmal_lane_low<vfmlsel2><mode>_intrinsic,
33390 vfmal_lane_high<vfmlsel2><mode>_intrinsic,
33391 vfmal_lane_high<mode>_intrinsic, vfmsl_lane_low<mode>_intrinsic,
33392 vfmsl_lane_low<vfmlsel2><mode>_intrinsic,
33393 vfmsl_lane_high<vfmlsel2><mode>_intrinsic,
33394 vfmsl_lane_high<mode>_intrinsic): New define_insns.
33395
33396 2018-01-11 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
33397
33398 * config/arm/arm-cpus.in (fp16fml): New feature.
33399 (ALL_SIMD): Add fp16fml.
33400 (armv8.2-a): Add fp16fml as an option.
33401 (armv8.3-a): Likewise.
33402 (armv8.4-a): Add fp16fml as part of fp16.
33403 * config/arm/arm.h (TARGET_FP16FML): Define.
33404 * config/arm/arm-c.c (arm_cpu_builtins): Define __ARM_FEATURE_FP16_FML
33405 when appropriate.
33406 * config/arm/arm-modes.def (V2HF): Define.
33407 * config/arm/arm_neon.h (vfmlal_low_u32, vfmlsl_low_u32,
33408 vfmlal_high_u32, vfmlsl_high_u32, vfmlalq_low_u32,
33409 vfmlslq_low_u32, vfmlalq_high_u32, vfmlslq_high_u32): Define.
33410 * config/arm/arm_neon_builtins.def (vfmal_low, vfmal_high,
33411 vfmsl_low, vfmsl_high): New set of builtins.
33412 * config/arm/iterators.md (PLUSMINUS): New code iterator.
33413 (vfml_op): New code attribute.
33414 (VFMLHALVES): New int iterator.
33415 (VFML, VFMLSEL): New mode attributes.
33416 (V_reg): Define mapping for V2HF.
33417 (V_hi, V_lo): New mode attributes.
33418 (VF_constraint): Likewise.
33419 (vfml_half, vfml_half_selector): New int attributes.
33420 * config/arm/neon.md (neon_vfm<vfml_op>l_<vfml_half><mode>): New
33421 define_expand.
33422 (vfmal_low<mode>_intrinsic, vfmsl_high<mode>_intrinsic,
33423 vfmal_high<mode>_intrinsic, vfmsl_low<mode>_intrinsic):
33424 New define_insn.
33425 * config/arm/t-arm-elf (v8_fps): Add fp16fml.
33426 * config/arm/t-multilib (v8_2_a_simd_variants): Add fp16fml.
33427 * config/arm/unspecs.md (UNSPEC_VFML_LO, UNSPEC_VFML_HI): New unspecs.
33428 * doc/invoke.texi (ARM Options): Document fp16fml. Update armv8.4-a
33429 documentation.
33430 * doc/sourcebuild.texi (arm_fp16fml_neon_ok, arm_fp16fml_neon):
33431 Document new effective target and option set.
33432
33433 2018-01-11 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
33434
33435 * config/arm/arm-cpus.in (armv8_4): New feature.
33436 (ARMv8_4a): New fgroup.
33437 (armv8.4-a): New arch.
33438 * config/arm/arm-tables.opt: Regenerate.
33439 * config/arm/t-aprofile: Add matching rules for -march=armv8.4-a.
33440 * config/arm/t-arm-elf (all_v8_archs): Add armv8.4-a.
33441 * config/arm/t-multilib (v8_4_a_simd_variants): New variable.
33442 Add matching rules for -march=armv8.4-a and extensions.
33443 * doc/invoke.texi (ARM Options): Document -march=armv8.4-a.
33444
33445 2018-01-11 Oleg Endo <olegendo@gcc.gnu.org>
33446
33447 PR target/81821
33448 * config/rx/rx.md (BW): New mode attribute.
33449 (sync_lock_test_and_setsi): Add mode suffix to insn output.
33450
33451 2018-01-11 Richard Biener <rguenther@suse.de>
33452
33453 PR tree-optimization/83435
33454 * graphite.c (canonicalize_loop_form): Ignore fake loop exit edges.
33455 * graphite-scop-detection.c (scop_detection::get_sese): Likewise.
33456 * tree-vrp.c (add_assert_info): Drop TREE_OVERFLOW if they appear.
33457
33458 2018-01-11 Richard Sandiford <richard.sandiford@linaro.org>
33459 Alan Hayward <alan.hayward@arm.com>
33460 David Sherwood <david.sherwood@arm.com>
33461
33462 * config/aarch64/aarch64.c (aarch64_address_info): Add a const_offset
33463 field.
33464 (aarch64_classify_address): Initialize it. Track polynomial offsets.
33465 (aarch64_print_address_internal): Use it to check for a zero offset.
33466
33467 2018-01-11 Richard Sandiford <richard.sandiford@linaro.org>
33468 Alan Hayward <alan.hayward@arm.com>
33469 David Sherwood <david.sherwood@arm.com>
33470
33471 * config/aarch64/aarch64-modes.def (NUM_POLY_INT_COEFFS): Set to 2.
33472 * config/aarch64/aarch64-protos.h (aarch64_initial_elimination_offset):
33473 Return a poly_int64 rather than a HOST_WIDE_INT.
33474 (aarch64_offset_7bit_signed_scaled_p): Take the offset as a poly_int64
33475 rather than a HOST_WIDE_INT.
33476 * config/aarch64/aarch64.h (aarch64_frame): Protect with
33477 HAVE_POLY_INT_H rather than HOST_WIDE_INT. Change locals_offset,
33478 hard_fp_offset, frame_size, initial_adjust, callee_offset and
33479 final_offset from HOST_WIDE_INT to poly_int64.
33480 * config/aarch64/aarch64-builtins.c (aarch64_simd_expand_args): Use
33481 to_constant when getting the number of units in an Advanced SIMD
33482 mode.
33483 (aarch64_builtin_vectorized_function): Check for a constant number
33484 of units.
33485 * config/aarch64/aarch64-simd.md (mov<mode>): Handle polynomial
33486 GET_MODE_SIZE.
33487 (aarch64_ld<VSTRUCT:nregs>_lane<VALLDIF:mode>): Use the nunits
33488 attribute instead of GET_MODE_NUNITS.
33489 * config/aarch64/aarch64.c (aarch64_hard_regno_nregs)
33490 (aarch64_class_max_nregs): Use the constant_lowest_bound of the
33491 GET_MODE_SIZE for fixed-size registers.
33492 (aarch64_const_vec_all_same_in_range_p): Use const_vec_duplicate_p.
33493 (aarch64_hard_regno_call_part_clobbered, aarch64_classify_index)
33494 (aarch64_mode_valid_for_sched_fusion_p, aarch64_classify_address)
33495 (aarch64_legitimize_address_displacement, aarch64_secondary_reload)
33496 (aarch64_print_operand, aarch64_print_address_internal)
33497 (aarch64_address_cost, aarch64_rtx_costs, aarch64_register_move_cost)
33498 (aarch64_short_vector_p, aapcs_vfp_sub_candidate)
33499 (aarch64_simd_attr_length_rglist, aarch64_operands_ok_for_ldpstp):
33500 Handle polynomial GET_MODE_SIZE.
33501 (aarch64_hard_regno_caller_save_mode): Likewise. Return modes
33502 wider than SImode without modification.
33503 (tls_symbolic_operand_type): Use strip_offset instead of split_const.
33504 (aarch64_pass_by_reference, aarch64_layout_arg, aarch64_pad_reg_upward)
33505 (aarch64_gimplify_va_arg_expr): Assert that we don't yet handle
33506 passing and returning SVE modes.
33507 (aarch64_function_value, aarch64_layout_arg): Use gen_int_mode
33508 rather than GEN_INT.
33509 (aarch64_emit_probe_stack_range): Take the size as a poly_int64
33510 rather than a HOST_WIDE_INT, but call sorry if it isn't constant.
33511 (aarch64_allocate_and_probe_stack_space): Likewise.
33512 (aarch64_layout_frame): Cope with polynomial offsets.
33513 (aarch64_save_callee_saves, aarch64_restore_callee_saves): Take the
33514 start_offset as a poly_int64 rather than a HOST_WIDE_INT. Track
33515 polynomial offsets.
33516 (offset_9bit_signed_unscaled_p, offset_12bit_unsigned_scaled_p)
33517 (aarch64_offset_7bit_signed_scaled_p): Take the offset as a
33518 poly_int64 rather than a HOST_WIDE_INT.
33519 (aarch64_get_separate_components, aarch64_process_components)
33520 (aarch64_expand_prologue, aarch64_expand_epilogue)
33521 (aarch64_use_return_insn_p): Handle polynomial frame offsets.
33522 (aarch64_anchor_offset): New function, split out from...
33523 (aarch64_legitimize_address): ...here.
33524 (aarch64_builtin_vectorization_cost): Handle polynomial
33525 TYPE_VECTOR_SUBPARTS.
33526 (aarch64_simd_check_vect_par_cnst_half): Handle polynomial
33527 GET_MODE_NUNITS.
33528 (aarch64_simd_make_constant, aarch64_expand_vector_init): Get the
33529 number of elements from the PARALLEL rather than the mode.
33530 (aarch64_shift_truncation_mask): Use GET_MODE_UNIT_BITSIZE
33531 rather than GET_MODE_BITSIZE.
33532 (aarch64_evpc_trn, aarch64_evpc_uzp, aarch64_evpc_ext)
33533 (aarch64_evpc_rev, aarch64_evpc_dup, aarch64_evpc_zip)
33534 (aarch64_expand_vec_perm_const_1): Handle polynomial
33535 d->perm.length () and d->perm elements.
33536 (aarch64_evpc_tbl): Likewise. Use nelt rather than GET_MODE_NUNITS.
33537 Apply to_constant to d->perm elements.
33538 (aarch64_simd_valid_immediate, aarch64_vec_fpconst_pow_of_2): Handle
33539 polynomial CONST_VECTOR_NUNITS.
33540 (aarch64_move_pointer): Take amount as a poly_int64 rather
33541 than an int.
33542 (aarch64_progress_pointer): Avoid temporary variable.
33543 * config/aarch64/aarch64.md (aarch64_<crc_variant>): Use
33544 the mode attribute instead of GET_MODE.
33545
33546 2018-01-11 Richard Sandiford <richard.sandiford@linaro.org>
33547 Alan Hayward <alan.hayward@arm.com>
33548 David Sherwood <david.sherwood@arm.com>
33549
33550 * config/aarch64/aarch64.c (aarch64_force_temporary): Assert that
33551 x exists before using it.
33552 (aarch64_add_constant_internal): Rename to...
33553 (aarch64_add_offset_1): ...this. Replace regnum with separate
33554 src and dest rtxes. Handle the case in which they're different,
33555 including when the offset is zero. Replace scratchreg with an rtx.
33556 Use 2 additions if there is no spare register into which we can
33557 move a 16-bit constant.
33558 (aarch64_add_constant): Delete.
33559 (aarch64_add_offset): Replace reg with separate src and dest
33560 rtxes. Take a poly_int64 offset instead of a HOST_WIDE_INT.
33561 Use aarch64_add_offset_1.
33562 (aarch64_add_sp, aarch64_sub_sp): Take the scratch register as
33563 an rtx rather than an int. Take the delta as a poly_int64
33564 rather than a HOST_WIDE_INT. Use aarch64_add_offset.
33565 (aarch64_expand_mov_immediate): Update uses of aarch64_add_offset.
33566 (aarch64_expand_prologue): Update calls to aarch64_sub_sp,
33567 aarch64_allocate_and_probe_stack_space and aarch64_add_offset.
33568 (aarch64_expand_epilogue): Update calls to aarch64_add_offset
33569 and aarch64_add_sp.
33570 (aarch64_output_mi_thunk): Use aarch64_add_offset rather than
33571 aarch64_add_constant.
33572
33573 2018-01-11 Richard Sandiford <richard.sandiford@linaro.org>
33574
33575 * config/aarch64/aarch64.c (aarch64_reinterpret_float_as_int):
33576 Use scalar_float_mode.
33577
33578 2018-01-11 Richard Sandiford <richard.sandiford@linaro.org>
33579
33580 * config/aarch64/aarch64-simd.md
33581 (aarch64_fml<f16mac1>l<f16quad>_low<mode>): Avoid GET_MODE_NUNITS.
33582 (aarch64_fml<f16mac1>l<f16quad>_high<mode>): Likewise.
33583 (aarch64_fml<f16mac1>l_lane_lowv2sf): Likewise.
33584 (aarch64_fml<f16mac1>l_lane_highv2sf): Likewise.
33585 (aarch64_fml<f16mac1>lq_laneq_lowv4sf): Likewise.
33586 (aarch64_fml<f16mac1>lq_laneq_highv4sf): Likewise.
33587 (aarch64_fml<f16mac1>l_laneq_lowv2sf): Likewise.
33588 (aarch64_fml<f16mac1>l_laneq_highv2sf): Likewise.
33589 (aarch64_fml<f16mac1>lq_lane_lowv4sf): Likewise.
33590 (aarch64_fml<f16mac1>lq_lane_highv4sf): Likewise.
33591
33592 2018-01-11 Prathamesh Kulkarni <prathamesh.kulkarni@linaro.org>
33593
33594 PR target/83514
33595 * config/arm/arm.c (arm_declare_function_name): Set arch_to_print if
33596 targ_options->x_arm_arch_string is non NULL.
33597
33598 2018-01-11 Tamar Christina <tamar.christina@arm.com>
33599
33600 * config/aarch64/aarch64.h
33601 (AARCH64_FL_FOR_ARCH8_4): Add AARCH64_FL_DOTPROD.
33602
33603 2018-01-11 Sudakshina Das <sudi.das@arm.com>
33604
33605 PR target/82096
33606 * expmed.c (emit_store_flag_force): Swap if const op0
33607 and change VOIDmode to mode of op0.
33608
33609 2018-01-11 Richard Sandiford <richard.sandiford@linaro.org>
33610
33611 PR rtl-optimization/83761
33612 * caller-save.c (replace_reg_with_saved_mem): Pass bits rather
33613 than bytes to mode_for_size.
33614
33615 2018-01-10 Jan Hubicka <hubicka@ucw.cz>
33616
33617 PR middle-end/83189
33618 * gfortran.fortran-torture/compile/pr83189.f90: New testcase.
33619 * tree-ssa-loop-manip.c (tree_transform_and_unroll_loop): Handle zero
33620 profile.
33621
33622 2018-01-10 Jan Hubicka <hubicka@ucw.cz>
33623
33624 PR middle-end/83575
33625 * cfgrtl.c (rtl_verify_edges): Only verify fixability of partition
33626 when in layout mode.
33627 (cfg_layout_finalize): Do not verify cfg before we are out of layout.
33628 * cfgcleanup.c (try_optimize_cfg): Only verify flow info when doing
33629 partition fixup.
33630
33631 2018-01-10 Michael Collison <michael.collison@arm.com>
33632
33633 * config/aarch64/aarch64-modes.def (V2HF): New VECTOR_MODE.
33634 * config/aarch64/aarch64-option-extension.def: Add
33635 AARCH64_OPT_EXTENSION of 'fp16fml'.
33636 * config/aarch64/aarch64-c.c (aarch64_update_cpp_builtins):
33637 (__ARM_FEATURE_FP16_FML): Define if TARGET_F16FML is true.
33638 * config/aarch64/predicates.md (aarch64_lane_imm3): New predicate.
33639 * config/aarch64/constraints.md (Ui7): New constraint.
33640 * config/aarch64/iterators.md (VFMLA_W): New mode iterator.
33641 (VFMLA_SEL_W): Ditto.
33642 (f16quad): Ditto.
33643 (f16mac1): Ditto.
33644 (VFMLA16_LOW): New int iterator.
33645 (VFMLA16_HIGH): Ditto.
33646 (UNSPEC_FMLAL): New unspec.
33647 (UNSPEC_FMLSL): Ditto.
33648 (UNSPEC_FMLAL2): Ditto.
33649 (UNSPEC_FMLSL2): Ditto.
33650 (f16mac): New code attribute.
33651 * config/aarch64/aarch64-simd-builtins.def
33652 (aarch64_fmlal_lowv2sf): Ditto.
33653 (aarch64_fmlsl_lowv2sf): Ditto.
33654 (aarch64_fmlalq_lowv4sf): Ditto.
33655 (aarch64_fmlslq_lowv4sf): Ditto.
33656 (aarch64_fmlal_highv2sf): Ditto.
33657 (aarch64_fmlsl_highv2sf): Ditto.
33658 (aarch64_fmlalq_highv4sf): Ditto.
33659 (aarch64_fmlslq_highv4sf): Ditto.
33660 (aarch64_fmlal_lane_lowv2sf): Ditto.
33661 (aarch64_fmlsl_lane_lowv2sf): Ditto.
33662 (aarch64_fmlal_laneq_lowv2sf): Ditto.
33663 (aarch64_fmlsl_laneq_lowv2sf): Ditto.
33664 (aarch64_fmlalq_lane_lowv4sf): Ditto.
33665 (aarch64_fmlsl_lane_lowv4sf): Ditto.
33666 (aarch64_fmlalq_laneq_lowv4sf): Ditto.
33667 (aarch64_fmlsl_laneq_lowv4sf): Ditto.
33668 (aarch64_fmlal_lane_highv2sf): Ditto.
33669 (aarch64_fmlsl_lane_highv2sf): Ditto.
33670 (aarch64_fmlal_laneq_highv2sf): Ditto.
33671 (aarch64_fmlsl_laneq_highv2sf): Ditto.
33672 (aarch64_fmlalq_lane_highv4sf): Ditto.
33673 (aarch64_fmlsl_lane_highv4sf): Ditto.
33674 (aarch64_fmlalq_laneq_highv4sf): Ditto.
33675 (aarch64_fmlsl_laneq_highv4sf): Ditto.
33676 * config/aarch64/aarch64-simd.md:
33677 (aarch64_fml<f16mac1>l<f16quad>_low<mode>): New pattern.
33678 (aarch64_fml<f16mac1>l<f16quad>_high<mode>): Ditto.
33679 (aarch64_simd_fml<f16mac1>l<f16quad>_low<mode>): Ditto.
33680 (aarch64_simd_fml<f16mac1>l<f16quad>_high<mode>): Ditto.
33681 (aarch64_fml<f16mac1>l_lane_lowv2sf): Ditto.
33682 (aarch64_fml<f16mac1>l_lane_highv2sf): Ditto.
33683 (aarch64_simd_fml<f16mac>l_lane_lowv2sf): Ditto.
33684 (aarch64_simd_fml<f16mac>l_lane_highv2sf): Ditto.
33685 (aarch64_fml<f16mac1>lq_laneq_lowv4sf): Ditto.
33686 (aarch64_fml<f16mac1>lq_laneq_highv4sf): Ditto.
33687 (aarch64_simd_fml<f16mac>lq_laneq_lowv4sf): Ditto.
33688 (aarch64_simd_fml<f16mac>lq_laneq_highv4sf): Ditto.
33689 (aarch64_fml<f16mac1>l_laneq_lowv2sf): Ditto.
33690 (aarch64_fml<f16mac1>l_laneq_highv2sf): Ditto.
33691 (aarch64_simd_fml<f16mac>l_laneq_lowv2sf): Ditto.
33692 (aarch64_simd_fml<f16mac>l_laneq_highv2sf): Ditto.
33693 (aarch64_fml<f16mac1>lq_lane_lowv4sf): Ditto.
33694 (aarch64_fml<f16mac1>lq_lane_highv4sf): Ditto.
33695 (aarch64_simd_fml<f16mac>lq_lane_lowv4sf): Ditto.
33696 (aarch64_simd_fml<f16mac>lq_lane_highv4sf): Ditto.
33697 * config/aarch64/arm_neon.h (vfmlal_low_u32): New intrinsic.
33698 (vfmlsl_low_u32): Ditto.
33699 (vfmlalq_low_u32): Ditto.
33700 (vfmlslq_low_u32): Ditto.
33701 (vfmlal_high_u32): Ditto.
33702 (vfmlsl_high_u32): Ditto.
33703 (vfmlalq_high_u32): Ditto.
33704 (vfmlslq_high_u32): Ditto.
33705 (vfmlal_lane_low_u32): Ditto.
33706 (vfmlsl_lane_low_u32): Ditto.
33707 (vfmlal_laneq_low_u32): Ditto.
33708 (vfmlsl_laneq_low_u32): Ditto.
33709 (vfmlalq_lane_low_u32): Ditto.
33710 (vfmlslq_lane_low_u32): Ditto.
33711 (vfmlalq_laneq_low_u32): Ditto.
33712 (vfmlslq_laneq_low_u32): Ditto.
33713 (vfmlal_lane_high_u32): Ditto.
33714 (vfmlsl_lane_high_u32): Ditto.
33715 (vfmlal_laneq_high_u32): Ditto.
33716 (vfmlsl_laneq_high_u32): Ditto.
33717 (vfmlalq_lane_high_u32): Ditto.
33718 (vfmlslq_lane_high_u32): Ditto.
33719 (vfmlalq_laneq_high_u32): Ditto.
33720 (vfmlslq_laneq_high_u32): Ditto.
33721 * config/aarch64/aarch64.h (AARCH64_FL_F16SML): New flag.
33722 (AARCH64_FL_FOR_ARCH8_4): New.
33723 (AARCH64_ISA_F16FML): New ISA flag.
33724 (TARGET_F16FML): New feature flag for fp16fml.
33725 (doc/invoke.texi): Document new fp16fml option.
33726
33727 2018-01-10 Michael Collison <michael.collison@arm.com>
33728
33729 * config/aarch64/aarch64-builtins.c:
33730 (aarch64_types_ternopu_imm_qualifiers, TYPES_TERNOPUI): New.
33731 * config/aarch64/aarch64-c.c (aarch64_update_cpp_builtins):
33732 (__ARM_FEATURE_SHA3): Define if TARGET_SHA3 is true.
33733 * config/aarch64/aarch64.h (AARCH64_FL_SHA3): New flags.
33734 (AARCH64_ISA_SHA3): New ISA flag.
33735 (TARGET_SHA3): New feature flag for sha3.
33736 * config/aarch64/iterators.md (sha512_op): New int attribute.
33737 (CRYPTO_SHA512): New int iterator.
33738 (UNSPEC_SHA512H): New unspec.
33739 (UNSPEC_SHA512H2): Ditto.
33740 (UNSPEC_SHA512SU0): Ditto.
33741 (UNSPEC_SHA512SU1): Ditto.
33742 * config/aarch64/aarch64-simd-builtins.def
33743 (aarch64_crypto_sha512hqv2di): New builtin.
33744 (aarch64_crypto_sha512h2qv2di): Ditto.
33745 (aarch64_crypto_sha512su0qv2di): Ditto.
33746 (aarch64_crypto_sha512su1qv2di): Ditto.
33747 (aarch64_eor3qv8hi): Ditto.
33748 (aarch64_rax1qv2di): Ditto.
33749 (aarch64_xarqv2di): Ditto.
33750 (aarch64_bcaxqv8hi): Ditto.
33751 * config/aarch64/aarch64-simd.md:
33752 (aarch64_crypto_sha512h<sha512_op>qv2di): New pattern.
33753 (aarch64_crypto_sha512su0qv2di): Ditto.
33754 (aarch64_crypto_sha512su1qv2di): Ditto.
33755 (aarch64_eor3qv8hi): Ditto.
33756 (aarch64_rax1qv2di): Ditto.
33757 (aarch64_xarqv2di): Ditto.
33758 (aarch64_bcaxqv8hi): Ditto.
33759 * config/aarch64/arm_neon.h (vsha512hq_u64): New intrinsic.
33760 (vsha512h2q_u64): Ditto.
33761 (vsha512su0q_u64): Ditto.
33762 (vsha512su1q_u64): Ditto.
33763 (veor3q_u16): Ditto.
33764 (vrax1q_u64): Ditto.
33765 (vxarq_u64): Ditto.
33766 (vbcaxq_u16): Ditto.
33767 * config/arm/types.md (crypto_sha512): New type attribute.
33768 (crypto_sha3): Ditto.
33769 (doc/invoke.texi): Document new sha3 option.
33770
33771 2018-01-10 Michael Collison <michael.collison@arm.com>
33772
33773 * config/aarch64/aarch64-builtins.c:
33774 (aarch64_types_quadopu_imm_qualifiers, TYPES_QUADOPUI): New.
33775 * config/aarch64/aarch64-c.c (aarch64_update_cpp_builtins):
33776 (__ARM_FEATURE_SM3): Define if TARGET_SM4 is true.
33777 (__ARM_FEATURE_SM4): Define if TARGET_SM4 is true.
33778 * config/aarch64/aarch64.h (AARCH64_FL_SM4): New flags.
33779 (AARCH64_ISA_SM4): New ISA flag.
33780 (TARGET_SM4): New feature flag for sm4.
33781 * config/aarch64/aarch64-simd-builtins.def
33782 (aarch64_sm3ss1qv4si): Ditto.
33783 (aarch64_sm3tt1aq4si): Ditto.
33784 (aarch64_sm3tt1bq4si): Ditto.
33785 (aarch64_sm3tt2aq4si): Ditto.
33786 (aarch64_sm3tt2bq4si): Ditto.
33787 (aarch64_sm3partw1qv4si): Ditto.
33788 (aarch64_sm3partw2qv4si): Ditto.
33789 (aarch64_sm4eqv4si): Ditto.
33790 (aarch64_sm4ekeyqv4si): Ditto.
33791 * config/aarch64/aarch64-simd.md:
33792 (aarch64_sm3ss1qv4si): Ditto.
33793 (aarch64_sm3tt<sm3tt_op>qv4si): Ditto.
33794 (aarch64_sm3partw<sm3part_op>qv4si): Ditto.
33795 (aarch64_sm4eqv4si): Ditto.
33796 (aarch64_sm4ekeyqv4si): Ditto.
33797 * config/aarch64/iterators.md (sm3tt_op): New int iterator.
33798 (sm3part_op): Ditto.
33799 (CRYPTO_SM3TT): Ditto.
33800 (CRYPTO_SM3PART): Ditto.
33801 (UNSPEC_SM3SS1): New unspec.
33802 (UNSPEC_SM3TT1A): Ditto.
33803 (UNSPEC_SM3TT1B): Ditto.
33804 (UNSPEC_SM3TT2A): Ditto.
33805 (UNSPEC_SM3TT2B): Ditto.
33806 (UNSPEC_SM3PARTW1): Ditto.
33807 (UNSPEC_SM3PARTW2): Ditto.
33808 (UNSPEC_SM4E): Ditto.
33809 (UNSPEC_SM4EKEY): Ditto.
33810 * config/aarch64/constraints.md (Ui2): New constraint.
33811 * config/aarch64/predicates.md (aarch64_imm2): New predicate.
33812 * config/arm/types.md (crypto_sm3): New type attribute.
33813 (crypto_sm4): Ditto.
33814 * config/aarch64/arm_neon.h (vsm3ss1q_u32): New intrinsic.
33815 (vsm3tt1aq_u32): Ditto.
33816 (vsm3tt1bq_u32): Ditto.
33817 (vsm3tt2aq_u32): Ditto.
33818 (vsm3tt2bq_u32): Ditto.
33819 (vsm3partw1q_u32): Ditto.
33820 (vsm3partw2q_u32): Ditto.
33821 (vsm4eq_u32): Ditto.
33822 (vsm4ekeyq_u32): Ditto.
33823 (doc/invoke.texi): Document new sm4 option.
33824
33825 2018-01-10 Michael Collison <michael.collison@arm.com>
33826
33827 * config/aarch64/aarch64-arches.def (armv8.4-a): New architecture.
33828 * config/aarch64/aarch64.h (AARCH64_ISA_V8_4): New ISA flag.
33829 (AARCH64_FL_FOR_ARCH8_4): New.
33830 (AARCH64_FL_V8_4): New flag.
33831 (doc/invoke.texi): Document new armv8.4-a option.
33832
33833 2018-01-10 Michael Collison <michael.collison@arm.com>
33834
33835 * config/aarch64/aarch64-c.c (aarch64_update_cpp_builtins):
33836 (__ARM_FEATURE_AES): Define if TARGET_AES is true.
33837 (__ARM_FEATURE_SHA2): Define if TARGET_SHA2 is true.
33838 * config/aarch64/aarch64-option-extension.def: Add
33839 AARCH64_OPT_EXTENSION of 'sha2'.
33840 (aes): Add AARCH64_OPT_EXTENSION of 'aes'.
33841 (crypto): Disable sha2 and aes if crypto disabled.
33842 (crypto): Enable aes and sha2 if enabled.
33843 (simd): Disable sha2 and aes if simd disabled.
33844 * config/aarch64/aarch64.h (AARCH64_FL_AES, AARCH64_FL_SHA2):
33845 New flags.
33846 (AARCH64_ISA_AES, AARCH64_ISA_SHA2): New ISA flags.
33847 (TARGET_SHA2): New feature flag for sha2.
33848 (TARGET_AES): New feature flag for aes.
33849 * config/aarch64/aarch64-simd.md:
33850 (aarch64_crypto_aes<aes_op>v16qi): Make pattern
33851 conditional on TARGET_AES.
33852 (aarch64_crypto_aes<aesmc_op>v16qi): Ditto.
33853 (aarch64_crypto_sha1hsi): Make pattern conditional
33854 on TARGET_SHA2.
33855 (aarch64_crypto_sha1hv4si): Ditto.
33856 (aarch64_be_crypto_sha1hv4si): Ditto.
33857 (aarch64_crypto_sha1su1v4si): Ditto.
33858 (aarch64_crypto_sha1<sha1_op>v4si): Ditto.
33859 (aarch64_crypto_sha1su0v4si): Ditto.
33860 (aarch64_crypto_sha256h<sha256_op>v4si): Ditto.
33861 (aarch64_crypto_sha256su0v4si): Ditto.
33862 (aarch64_crypto_sha256su1v4si): Ditto.
33863 (doc/invoke.texi): Document new aes and sha2 options.
33864
33865 2018-01-10 Martin Sebor <msebor@redhat.com>
33866
33867 PR tree-optimization/83781
33868 * gimple-fold.c (get_range_strlen): Avoid treating arrays of pointers
33869 as string arrays.
33870
33871 2018-01-11 Martin Sebor <msebor@gmail.com>
33872 Prathamesh Kulkarni <prathamesh.kulkarni@linaro.org>
33873
33874 PR tree-optimization/83501
33875 PR tree-optimization/81703
33876
33877 * tree-ssa-strlen.c (get_string_cst): Rename...
33878 (get_string_len): ...to this. Handle global constants.
33879 (handle_char_store): Adjust.
33880
33881 2018-01-10 Kito Cheng <kito.cheng@gmail.com>
33882 Jim Wilson <jimw@sifive.com>
33883
33884 * config/riscv/riscv-protos.h (riscv_output_return): New.
33885 * config/riscv/riscv.c (struct machine_function): New naked_p field.
33886 (riscv_attribute_table, riscv_output_return),
33887 (riscv_handle_fndecl_attribute, riscv_naked_function_p),
33888 (riscv_allocate_stack_slots_for_args, riscv_warn_func_return): New.
33889 (riscv_compute_frame_info): Only compute frame->mask if not a naked
33890 function.
33891 (riscv_expand_prologue): Add early return for naked function.
33892 (riscv_expand_epilogue): Likewise.
33893 (riscv_function_ok_for_sibcall): Return false for naked function.
33894 (riscv_set_current_function): New.
33895 (TARGET_SET_CURRENT_FUNCTION, TARGET_ALLOCATE_STACK_SLOTS_FOR_ARGS),
33896 (TARGET_ATTRIBUTE_TABLE, TARGET_WARN_FUNC_RETURN): New.
33897 * config/riscv/riscv.md (simple_return): Call riscv_output_return.
33898 * doc/extend.texi (RISC-V Function Attributes): New.
33899
33900 2018-01-10 Michael Meissner <meissner@linux.vnet.ibm.com>
33901
33902 * config/rs6000/rs6000.c (is_complex_IBM_long_double): Explicitly
33903 check for 128-bit long double before checking TCmode.
33904 * config/rs6000/rs6000.h (FLOAT128_IEEE_P): Explicitly check for
33905 128-bit long doubles before checking TFmode or TCmode.
33906 (FLOAT128_IBM_P): Likewise.
33907
33908 2018-01-10 Martin Sebor <msebor@redhat.com>
33909
33910 PR tree-optimization/83671
33911 * builtins.c (c_strlen): Unconditionally return zero for the empty
33912 string.
33913 Use -Warray-bounds for warnings.
33914 * gimple-fold.c (get_range_strlen): Handle non-constant lengths
33915 for non-constant array indices with COMPONENT_REF, arrays of
33916 arrays, and pointers to arrays.
33917 (gimple_fold_builtin_strlen): Determine and set length range for
33918 non-constant character arrays.
33919
33920 2018-01-10 Aldy Hernandez <aldyh@redhat.com>
33921
33922 PR middle-end/81897
33923 * tree-ssa-uninit.c (convert_control_dep_chain_into_preds): Skip
33924 empty blocks.
33925
33926 2018-01-10 Eric Botcazou <ebotcazou@adacore.com>
33927
33928 * dwarf2out.c (dwarf2out_var_location): Do not pass NULL to fprintf.
33929
33930 2018-01-10 Peter Bergner <bergner@vnet.ibm.com>
33931
33932 PR target/83399
33933 * config/rs6000/rs6000.c (print_operand) <'y'>: Use
33934 VECTOR_MEM_ALTIVEC_OR_VSX_P.
33935 * config/rs6000/vsx.md (*vsx_le_perm_load_<mode> for VSX_D): Use
33936 indexed_or_indirect_operand predicate.
33937 (*vsx_le_perm_load_<mode> for VSX_W): Likewise.
33938 (*vsx_le_perm_load_v8hi): Likewise.
33939 (*vsx_le_perm_load_v16qi): Likewise.
33940 (*vsx_le_perm_store_<mode> for VSX_D): Likewise.
33941 (*vsx_le_perm_store_<mode> for VSX_W): Likewise.
33942 (*vsx_le_perm_store_v8hi): Likewise.
33943 (*vsx_le_perm_store_v16qi): Likewise.
33944 (eight unnamed splitters): Likewise.
33945
33946 2018-01-10 Peter Bergner <bergner@vnet.ibm.com>
33947
33948 * config/rs6000/x86intrin.h: Change #warning to #error. Update message.
33949 * config/rs6000/emmintrin.h: Likewise.
33950 * config/rs6000/mmintrin.h: Likewise.
33951 * config/rs6000/xmmintrin.h: Likewise.
33952
33953 2018-01-10 David Malcolm <dmalcolm@redhat.com>
33954
33955 PR c++/43486
33956 * tree-core.h: Document EXPR_LOCATION_WRAPPER_P's usage of
33957 "public_flag".
33958 * tree.c (tree_nop_conversion): Return true for location wrapper
33959 nodes.
33960 (maybe_wrap_with_location): New function.
33961 (selftest::check_strip_nops): New function.
33962 (selftest::test_location_wrappers): New function.
33963 (selftest::tree_c_tests): Call it.
33964 * tree.h (STRIP_ANY_LOCATION_WRAPPER): New macro.
33965 (maybe_wrap_with_location): New decl.
33966 (EXPR_LOCATION_WRAPPER_P): New macro.
33967 (location_wrapper_p): New inline function.
33968 (tree_strip_any_location_wrapper): New inline function.
33969
33970 2018-01-10 H.J. Lu <hongjiu.lu@intel.com>
33971
33972 PR target/83735
33973 * config/i386/i386.c (ix86_compute_frame_layout): Always adjust
33974 stack_realign_offset for the largest alignment of stack slot
33975 actually used.
33976 (ix86_find_max_used_stack_alignment): New function.
33977 (ix86_finalize_stack_frame_flags): Use it. Set
33978 max_used_stack_alignment if we don't realign stack.
33979 * config/i386/i386.h (machine_function): Add
33980 max_used_stack_alignment.
33981
33982 2018-01-10 Christophe Lyon <christophe.lyon@linaro.org>
33983
33984 * config/arm/arm.opt (-mbranch-cost): New option.
33985 * config/arm/arm.h (BRANCH_COST): Take arm_branch_cost into
33986 account.
33987
33988 2018-01-10 Segher Boessenkool <segher@kernel.crashing.org>
33989
33990 PR target/83629
33991 * config/rs6000/rs6000.md (load_toc_v4_PIC_2, load_toc_v4_PIC_3b,
33992 load_toc_v4_PIC_3c): Wrap const term in CONST RTL.
33993
33994 2018-01-10 Richard Biener <rguenther@suse.de>
33995
33996 PR debug/83765
33997 * dwarf2out.c (gen_subprogram_die): Hoist old_die && declaration
33998 early out so it also covers the case where we have a non-NULL
33999 origin.
34000
34001 2018-01-10 Richard Sandiford <richard.sandiford@linaro.org>
34002
34003 PR tree-optimization/83753
34004 * tree-vect-stmts.c (get_group_load_store_type): Use VMAT_CONTIGUOUS
34005 for non-strided grouped accesses if the number of elements is 1.
34006
34007 2018-01-10 Jan Hubicka <hubicka@ucw.cz>
34008
34009 PR target/81616
34010 * i386.c (ix86_vectorize_builtin_gather): Check TARGET_USE_GATHER.
34011 * i386.h (TARGET_USE_GATHER): Define.
34012 * x86-tune.def (X86_TUNE_USE_GATHER): New.
34013
34014 2018-01-10 Martin Liska <mliska@suse.cz>
34015
34016 PR bootstrap/82831
34017 * basic-block.h (CLEANUP_NO_PARTITIONING): New define.
34018 * bb-reorder.c (pass_reorder_blocks::execute): Do not clean up
34019 partitioning.
34020 * cfgcleanup.c (try_optimize_cfg): Fix up partitioning if
34021 CLEANUP_NO_PARTITIONING is not set.
34022
34023 2018-01-10 Richard Sandiford <richard.sandiford@linaro.org>
34024
34025 * doc/rtl.texi: Remove documentation of (const ...) wrappers
34026 for vectors, as a partial revert of r254296.
34027 * rtl.h (const_vec_p): Delete.
34028 (const_vec_duplicate_p): Don't test for vector CONSTs.
34029 (unwrap_const_vec_duplicate, const_vec_series_p): Likewise.
34030 * expmed.c (make_tree): Likewise.
34031
34032 Revert:
34033 * common.md (E, F): Use CONSTANT_P instead of checking for
34034 CONST_VECTOR.
34035 * emit-rtl.c (gen_lowpart_common): Use const_vec_p instead of
34036 checking for CONST_VECTOR.
34037
34038 2018-01-09 Jan Hubicka <hubicka@ucw.cz>
34039
34040 PR middle-end/83575
34041 * predict.c (force_edge_cold): Handle in more sane way edges
34042 with no prediction.
34043
34044 2018-01-09 Carl Love <cel@us.ibm.com>
34045
34046 * config/rs6002/altivec.md (p8_vmrgow): Add support for V2DI, V2DF,
34047 V4SI, V4SF types.
34048 (p8_vmrgew): Add support for V2DI, V2DF, V4SF types.
34049 * config/rs6000/rs6000-builtin.def: Add definitions for FLOAT2_V2DF,
34050 VMRGEW_V2DI, VMRGEW_V2DF, VMRGEW_V4SF, VMRGOW_V4SI, VMRGOW_V4SF,
34051 VMRGOW_V2DI, VMRGOW_V2DF. Remove definition for VMRGOW.
34052 * config/rs6000/rs6000-c.c (VSX_BUILTIN_VEC_FLOAT2,
34053 P8V_BUILTIN_VEC_VMRGEW, P8V_BUILTIN_VEC_VMRGOW): Add definitions.
34054 * config/rs6000/rs6000-protos.h: Add extern defition for
34055 rs6000_generate_float2_double_code.
34056 * config/rs6000/rs6000.c (rs6000_generate_float2_double_code): Add
34057 function.
34058 * config/rs6000/vsx.md (vsx_xvcdpsp): Add define_insn.
34059 (float2_v2df): Add define_expand.
34060
34061 2018-01-09 Uros Bizjak <ubizjak@gmail.com>
34062
34063 PR target/83628
34064 * combine.c (force_int_to_mode) <case ASHIFT>: Use mode instead of
34065 op_mode in the force_to_mode call.
34066
34067 2018-01-09 Richard Sandiford <richard.sandiford@linaro.org>
34068
34069 * config/aarch64/aarch64.c (aarch64_evpc_trn): Use d.perm.series_p
34070 instead of checking each element individually.
34071 (aarch64_evpc_uzp): Likewise.
34072 (aarch64_evpc_zip): Likewise.
34073 (aarch64_evpc_ext): Likewise.
34074 (aarch64_evpc_rev): Likewise.
34075 (aarch64_evpc_dup): Test the encoding for a single duplicated element,
34076 instead of checking each element individually. Return true without
34077 generating rtl if
34078 (aarch64_vectorize_vec_perm_const): Use all_from_input_p to test
34079 whether all selected elements come from the same input, instead of
34080 checking each element individually. Remove calls to gen_rtx_REG,
34081 start_sequence and end_sequence and instead assert that no rtl is
34082 generated.
34083
34084 2018-01-09 Richard Sandiford <richard.sandiford@linaro.org>
34085
34086 * config/aarch64/aarch64.c (aarch64_legitimate_constant_p): Fix
34087 order of HIGH and CONST checks.
34088
34089 2018-01-09 Richard Sandiford <richard.sandiford@linaro.org>
34090
34091 * tree-vect-stmts.c (permute_vec_elements): Create a fresh variable
34092 if the destination isn't an SSA_NAME.
34093
34094 2018-01-09 Richard Biener <rguenther@suse.de>
34095
34096 PR tree-optimization/83668
34097 * graphite.c (canonicalize_loop_closed_ssa): Add edge argument,
34098 move prologue...
34099 (canonicalize_loop_form): ... here, renamed from ...
34100 (canonicalize_loop_closed_ssa_form): ... this and amended to
34101 swap successor edges for loop exit blocks to make us use
34102 the RPO order we need for initial schedule generation.
34103
34104 2018-01-09 Joseph Myers <joseph@codesourcery.com>
34105
34106 PR tree-optimization/64811
34107 * match.pd: When optimizing comparisons with Inf, avoid
34108 introducing or losing exceptions from comparisons with NaN.
34109
34110 2018-01-09 Martin Liska <mliska@suse.cz>
34111
34112 PR sanitizer/82517
34113 * asan.c (shadow_mem_size): Add gcc_assert.
34114
34115 2018-01-09 Georg-Johann Lay <avr@gjlay.de>
34116
34117 Don't save registers in main().
34118
34119 PR target/83738
34120 * doc/invoke.texi (AVR Options) [-mmain-is-OS_task]: Document it.
34121 * config/avr/avr.opt (-mmain-is-OS_task): New target option.
34122 * config/avr/avr.c (avr_set_current_function): Don't error if
34123 naked, OS_task or OS_main are specified at the same time.
34124 (avr_function_ok_for_sibcall): Don't disable sibcalls for OS_task,
34125 OS_main.
34126 (avr_insert_attributes) [-mmain-is-OS_task] <main>: Add OS_task
34127 attribute.
34128 * common/config/avr/avr-common.c (avr_option_optimization_table):
34129 Switch on -mmain-is-OS_task for optimizing compilations.
34130
34131 2018-01-09 Richard Biener <rguenther@suse.de>
34132
34133 PR tree-optimization/83572
34134 * graphite.c: Include cfganal.h.
34135 (graphite_transform_loops): Connect infinite loops to exit
34136 and remove fake edges at the end.
34137
34138 2018-01-09 Jan Hubicka <hubicka@ucw.cz>
34139
34140 * ipa-inline.c (edge_badness): Revert accidental checkin.
34141
34142 2018-01-09 Jan Hubicka <hubicka@ucw.cz>
34143
34144 PR ipa/80763
34145 * ipa-comdats.c (set_comdat_group): Only set comdat group of real
34146 symbols; not inline clones.
34147
34148 2018-01-09 Jakub Jelinek <jakub@redhat.com>
34149
34150 PR target/83507
34151 * modulo-sched.c (schedule_reg_moves): Punt if we'd need to move
34152 hard registers. Formatting fixes.
34153
34154 PR preprocessor/83722
34155 * gcc.c (try_generate_repro): Pass
34156 &temp_stderr_files[RETRY_ICE_ATTEMPTS - 1] rather than
34157 &temp_stdout_files[RETRY_ICE_ATTEMPTS - 1] as last argument to
34158 do_report_bug.
34159
34160 2018-01-08 Monk Chiang <sh.chiang04@gmail.com>
34161 Kito Cheng <kito.cheng@gmail.com>
34162
34163 * config/riscv/riscv.c (machine_function::is_leaf): Remove field.
34164 (riscv_leaf_function_p): Delete.
34165 (riscv_function_ok_for_sibcall): Return false when TARGET_SAVE_RESTORE.
34166
34167 2018-01-08 Aaron Sawdey <acsawdey@linux.vnet.ibm.com>
34168
34169 * config/rs6000/rs6000-string.c (do_load_for_compare_from_addr): New
34170 function.
34171 (do_ifelse): New function.
34172 (do_isel): New function.
34173 (do_sub3): New function.
34174 (do_add3): New function.
34175 (do_load_mask_compare): New function.
34176 (do_overlap_load_compare): New function.
34177 (expand_compare_loop): New function.
34178 (expand_block_compare): Call expand_compare_loop() when appropriate.
34179 * config/rs6000/rs6000.opt (-mblock-compare-inline-limit): Change
34180 option description.
34181 (-mblock-compare-inline-loop-limit): New option.
34182
34183 2018-01-08 Bill Schmidt <wschmidt@linux.vnet.ibm.com>
34184
34185 PR target/83677
34186 * config/rs6000/altivec.md (*altivec_vpermr_<mode>_internal):
34187 Reverse order of second and third operands in first alternative.
34188 * config/rs6000/rs6000.c (rs6000_expand_vector_set): Reverse order
34189 of first and second elements in UNSPEC_VPERMR vector.
34190 (altivec_expand_vec_perm_le): Likewise.
34191
34192 2018-01-08 Jeff Law <law@redhat.com>
34193
34194 PR rtl-optimizatin/81308
34195 * tree-switch-conversion.c (cfg_altered): New file scoped static.
34196 (process_switch): If group_case_labels makes a change, then set
34197 cfg_altered.
34198 (pass_convert_switch::execute): If a switch is converted, then
34199 set cfg_altered. Return TODO_cfg_cleanup if cfg_altered is true.
34200
34201 PR rtl-optimization/81308
34202 * recog.c (split_all_insns): Conditionally cleanup the CFG after
34203 splitting insns.
34204
34205 2018-01-08 Vidya Praveen <vidyapraveen@arm.com>
34206
34207 PR target/83663 - Revert r255946
34208 * config/aarch64/aarch64.c (aarch64_expand_vector_init): Modify code
34209 generation for cases where splatting a value is not useful.
34210 * simplify-rtx.c (simplify_ternary_operation): Simplify vec_merge
34211 across a vec_duplicate and a paradoxical subreg forming a vector
34212 mode to a vec_concat.
34213
34214 2018-01-08 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
34215
34216 * config/arm/t-aprofile (MULTILIB_MATCHES): Add mapping rules for
34217 -march=armv8.3-a variants.
34218 * config/arm/t-multilib: Likewise.
34219 * config/arm/t-arm-elf: Likewise. Handle dotprod extension.
34220
34221 2018-01-08 Aaron Sawdey <acsawdey@linux.vnet.ibm.com>
34222
34223 * config/rs6000/rs6000.md (cceq_ior_compare): Remove * so I can use it
34224 to generate rtl.
34225 (cceq_ior_compare_complement): Give it a name so I can use it, and
34226 change boolean_or_operator predicate to boolean_operator so it can
34227 be used to generate a crand.
34228 (eqne): New code iterator.
34229 (bd/bd_neg): New code_attrs.
34230 (<bd>_<mode>): New name for ctr<mode>_internal[12] now combined into
34231 a single define_insn.
34232 (<bd>tf_<mode>): A new insn pattern for the conditional form branch
34233 decrement (bdnzt/bdnzf/bdzt/bdzf).
34234 * config/rs6000/rs6000.c (rs6000_legitimate_combined_insn): Updated
34235 with the new names of the branch decrement patterns, and added the
34236 names of the branch decrement conditional patterns.
34237
34238 2018-01-08 Richard Biener <rguenther@suse.de>
34239
34240 PR tree-optimization/83563
34241 * graphite.c (canonicalize_loop_closed_ssa_form): Reset the SCEV
34242 cache.
34243
34244 2018-01-08 Richard Biener <rguenther@suse.de>
34245
34246 PR middle-end/83713
34247 * convert.c (do_narrow): Properly guard TYPE_OVERFLOW_WRAPS checks.
34248
34249 2018-01-08 Richard Biener <rguenther@suse.de>
34250
34251 PR tree-optimization/83685
34252 * tree-ssa-pre.c (create_expression_by_pieces): Do not insert
34253 references to abnormals.
34254
34255 2018-01-08 Richard Biener <rguenther@suse.de>
34256
34257 PR lto/83719
34258 * dwarf2out.c (output_indirect_strings): Handle empty
34259 skeleton_debug_str_hash.
34260 (dwarf2out_early_finish): Index strings for -gsplit-dwarf.
34261
34262 2018-01-08 Claudiu Zissulescu <claziss@synopsys.com>
34263
34264 * config/arc/arc.c (TARGET_TRAMPOLINE_ADJUST_ADDRESS): Delete.
34265 (emit_store_direct): Likewise.
34266 (arc_trampoline_adjust_address): Likewise.
34267 (arc_asm_trampoline_template): New function.
34268 (arc_initialize_trampoline): Use asm_trampoline_template.
34269 (TARGET_ASM_TRAMPOLINE_TEMPLATE): Define.
34270 * config/arc/arc.h (TRAMPOLINE_SIZE): Adjust to 16.
34271 * config/arc/arc.md (flush_icache): Delete pattern.
34272
34273 2018-01-08 Claudiu Zissulescu <claziss@synopsys.com>
34274
34275 * config/arc/arc-c.def (__ARC_UNALIGNED__): New define.
34276 * config/arc/arc.h (STRICT_ALIGNMENT): Control this macro using
34277 munaligned-access.
34278
34279 2018-01-08 Sebastian Huber <sebastian.huber@embedded-brains.de>
34280
34281 PR target/83681
34282 * config/epiphany/epiphany.h (make_pass_mode_switch_use): Guard
34283 by not USED_FOR_TARGET.
34284 (make_pass_resolve_sw_modes): Likewise.
34285
34286 2018-01-08 Sebastian Huber <sebastian.huber@embedded-brains.de>
34287
34288 * config/nios2/nios2.h (nios2_section_threshold): Guard by not
34289 USED_FOR_TARGET.
34290
34291 2018-01-08 Richard Biener <rguenther@suse.de>
34292
34293 PR middle-end/83580
34294 * tree-data-ref.c (split_constant_offset): Remove STRIP_NOPS.
34295
34296 2018-01-08 Richard Biener <rguenther@suse.de>
34297
34298 PR middle-end/83517
34299 * match.pd ((t * 2) / 2) -> t): Add missing :c.
34300
34301 2018-01-06 Aldy Hernandez <aldyh@redhat.com>
34302
34303 PR middle-end/81897
34304 * tree-ssa-uninit.c (compute_control_dep_chain): Do not bail on
34305 basic blocks with a small number of successors.
34306 (convert_control_dep_chain_into_preds): Improve handling of
34307 forwarder blocks.
34308 (dump_predicates): Split apart into...
34309 (dump_pred_chain): ...here...
34310 (dump_pred_info): ...and here.
34311 (can_one_predicate_be_invalidated_p): Add debugging printfs.
34312 (can_chain_union_be_invalidated_p): Improve check for invalidation
34313 of paths.
34314 (uninit_uses_cannot_happen): Avoid unnecessary if
34315 convert_control_dep_chain_into_preds yielded nothing.
34316
34317 2018-01-06 Martin Sebor <msebor@redhat.com>
34318
34319 PR tree-optimization/83640
34320 * gimple-ssa-warn-restrict.c (builtin_access::builtin_access): Avoid
34321 subtracting negative offset from size.
34322 (builtin_access::overlap): Adjust offset bounds of the access to fall
34323 within the size of the object if possible.
34324
34325 2018-01-06 Richard Sandiford <richard.sandiford@linaro.org>
34326
34327 PR rtl-optimization/83699
34328 * expmed.c (extract_bit_field_1): Restrict the vector usage of
34329 extract_bit_field_as_subreg to cases in which the extracted
34330 value is also a vector.
34331
34332 * lra-constraints.c (process_alt_operands): Test for the equivalence
34333 substitutions when detecting a possible reload cycle.
34334
34335 2018-01-06 Jakub Jelinek <jakub@redhat.com>
34336
34337 PR debug/83480
34338 * toplev.c (process_options): Don't enable debug_nonbind_markers_p
34339 by default if flag_selective_schedling{,2}. Formatting fixes.
34340
34341 PR rtl-optimization/83682
34342 * rtl.h (const_vec_duplicate_p): Only return true for VEC_DUPLICATE
34343 if it has non-VECTOR_MODE element mode.
34344 (vec_duplicate_p): Likewise.
34345
34346 PR middle-end/83694
34347 * cfgexpand.c (expand_debug_expr): Punt if mode1 is VOIDmode
34348 and bitsize might be greater than MAX_BITSIZE_MODE_ANY_INT.
34349
34350 2018-01-05 Jakub Jelinek <jakub@redhat.com>
34351
34352 PR target/83604
34353 * config/i386/i386-builtin.def
34354 (__builtin_ia32_vgf2p8affineinvqb_v64qi,
34355 __builtin_ia32_vgf2p8affineqb_v64qi, __builtin_ia32_vgf2p8mulb_v64qi):
34356 Require also OPTION_MASK_ISA_AVX512F in addition to
34357 OPTION_MASK_ISA_GFNI.
34358 (__builtin_ia32_vgf2p8affineinvqb_v16qi_mask,
34359 __builtin_ia32_vgf2p8affineqb_v16qi_mask): Require
34360 OPTION_MASK_ISA_AVX512VL instead of OPTION_MASK_ISA_SSE in addition
34361 to OPTION_MASK_ISA_GFNI.
34362 (__builtin_ia32_vgf2p8mulb_v32qi_mask): Require
34363 OPTION_MASK_ISA_AVX512VL in addition to OPTION_MASK_ISA_GFNI and
34364 OPTION_MASK_ISA_AVX512BW.
34365 (__builtin_ia32_vgf2p8mulb_v16qi_mask): Require
34366 OPTION_MASK_ISA_AVX512VL instead of OPTION_MASK_ISA_AVX512BW in
34367 addition to OPTION_MASK_ISA_GFNI.
34368 (__builtin_ia32_vgf2p8affineinvqb_v16qi,
34369 __builtin_ia32_vgf2p8affineqb_v16qi, __builtin_ia32_vgf2p8mulb_v16qi):
34370 Require OPTION_MASK_ISA_SSE2 instead of OPTION_MASK_ISA_SSE in addition
34371 to OPTION_MASK_ISA_GFNI.
34372 * config/i386/i386.c (def_builtin): Change to builtin isa/isa2 being
34373 a requirement for all ISAs rather than any of them with a few
34374 exceptions.
34375 (ix86_add_new_builtins): Clear OPTION_MASK_ISA_64BIT from isa before
34376 processing.
34377 (ix86_expand_builtin): Require all ISAs from builtin's isa and isa2
34378 bitmasks to be enabled with 3 exceptions, instead of requiring any
34379 enabled ISA with lots of exceptions.
34380 * config/i386/sse.md (vgf2p8affineinvqb_<mode><mask_name>,
34381 vgf2p8affineqb_<mode><mask_name>, vgf2p8mulb_<mode><mask_name>):
34382 Change avx512bw in isa attribute to avx512f.
34383 * config/i386/sgxintrin.h: Add license boilerplate.
34384 * config/i386/vaesintrin.h: Likewise. Fix macro spelling __AVX512F
34385 to __AVX512F__ and __AVX512VL to __AVX512VL__.
34386 (_mm256_aesdec_epi128, _mm256_aesdeclast_epi128, _mm256_aesenc_epi128,
34387 _mm256_aesenclast_epi128): Enable temporarily avx if __AVX__ is not
34388 defined.
34389 * config/i386/gfniintrin.h (_mm_gf2p8mul_epi8,
34390 _mm_gf2p8affineinv_epi64_epi8, _mm_gf2p8affine_epi64_epi8): Enable
34391 temporarily sse2 rather than sse if not enabled already.
34392
34393 PR target/83604
34394 * config/i386/sse.md (VI248_VLBW): Rename to ...
34395 (VI248_AVX512VL): ... this. Don't guard V32HI with TARGET_AVX512BW.
34396 (vpshrd_<mode><mask_name>, vpshld_<mode><mask_name>,
34397 vpshrdv_<mode>, vpshrdv_<mode>_mask, vpshrdv_<mode>_maskz,
34398 vpshrdv_<mode>_maskz_1, vpshldv_<mode>, vpshldv_<mode>_mask,
34399 vpshldv_<mode>_maskz, vpshldv_<mode>_maskz_1): Use VI248_AVX512VL
34400 mode iterator instead of VI248_VLBW.
34401
34402 2018-01-05 Jan Hubicka <hubicka@ucw.cz>
34403
34404 * ipa-fnsummary.c (record_modified_bb_info): Add OP.
34405 (record_modified): Skip clobbers; add debug output.
34406 (param_change_prob): Use sreal frequencies.
34407
34408 2018-01-05 Richard Sandiford <richard.sandiford@linaro.org>
34409
34410 * tree-vect-data-refs.c (vect_compute_data_ref_alignment): Don't
34411 punt for user-aligned variables.
34412
34413 2018-01-05 Richard Sandiford <richard.sandiford@linaro.org>
34414
34415 * tree-chrec.c (chrec_contains_symbols): Return true for
34416 POLY_INT_CST.
34417
34418 2018-01-05 Sudakshina Das <sudi.das@arm.com>
34419
34420 PR target/82439
34421 * simplify-rtx.c (simplify_relational_operation_1): Add simplifications
34422 of (x|y) == x for BICS pattern.
34423
34424 2018-01-05 Jakub Jelinek <jakub@redhat.com>
34425
34426 PR tree-optimization/83605
34427 * gimple-ssa-strength-reduction.c: Include tree-eh.h.
34428 (find_candidates_dom_walker::before_dom_children): Ignore stmts that
34429 can throw.
34430
34431 2018-01-05 Sebastian Huber <sebastian.huber@embedded-brains.de>
34432
34433 * config.gcc (epiphany-*-elf*): Add (epiphany-*-rtems*) configuration.
34434 * config/epiphany/rtems.h: New file.
34435
34436 2018-01-04 Jakub Jelinek <jakub@redhat.com>
34437 Uros Bizjak <ubizjak@gmail.com>
34438
34439 PR target/83554
34440 * config/i386/i386.md (*<rotate_insn>hi3_1 splitter): Use
34441 QIreg_operand instead of register_operand predicate.
34442 * config/i386/i386.c (ix86_rop_should_change_byte_p,
34443 set_rop_modrm_reg_bits, ix86_mitigate_rop): Use -mmitigate-rop in
34444 comments instead of -fmitigate[-_]rop.
34445
34446 2018-01-04 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
34447
34448 PR bootstrap/81926
34449 * cgraphunit.c (symbol_table::compile): Switch to text_section
34450 before calling assembly_start debug hook.
34451 * run-rtl-passes.c (run_rtl_passes): Likewise.
34452 Include output.h.
34453
34454 2018-01-04 Richard Sandiford <richard.sandiford@linaro.org>
34455
34456 * tree-vrp.c (extract_range_from_binary_expr_1): Check
34457 range_int_cst_p rather than !symbolic_range_p before calling
34458 extract_range_from_multiplicative_op_1.
34459
34460 2018-01-04 Jeff Law <law@redhat.com>
34461
34462 * tree-ssa-math-opts.c (execute_cse_reciprocals_1): Remove
34463 redundant test in assertion.
34464
34465 2018-01-04 Richard Sandiford <richard.sandiford@linaro.org>
34466
34467 * doc/rtl.texi: Document machine_mode wrapper classes.
34468
34469 2018-01-04 Richard Sandiford <richard.sandiford@linaro.org>
34470
34471 * fold-const.c (fold_ternary_loc): Check tree_fits_uhwi_p before
34472 using tree_to_uhwi.
34473
34474 2018-01-04 Richard Sandiford <richard.sandiford@linaro.org>
34475
34476 * tree-ssa-forwprop.c (is_combined_permutation_identity): Allow
34477 the VEC_PERM_EXPR fold to fail.
34478
34479 2018-01-04 Jakub Jelinek <jakub@redhat.com>
34480
34481 PR debug/83585
34482 * bb-reorder.c (insert_section_boundary_note): Set has_bb_partition
34483 to switched_sections.
34484
34485 2018-01-04 Richard Sandiford <richard.sandiford@linaro.org>
34486
34487 PR target/83680
34488 * config/arm/arm.c (arm_vectorize_vec_perm_const): Fix inverted
34489 test for d.testing.
34490
34491 2018-01-04 Peter Bergner <bergner@vnet.ibm.com>
34492
34493 PR target/83387
34494 * config/rs6000/rs6000.c (rs6000_discover_homogeneous_aggregate): Do not
34495 allow arguments in FP registers if TARGET_HARD_FLOAT is false.
34496
34497 2018-01-04 Jakub Jelinek <jakub@redhat.com>
34498
34499 PR debug/83666
34500 * cfgexpand.c (expand_debug_expr) <case BIT_FIELD_REF>: Punt if mode
34501 is BLKmode and bitpos not zero or mode change is needed.
34502
34503 2018-01-04 Richard Sandiford <richard.sandiford@linaro.org>
34504
34505 PR target/83675
34506 * config/sparc/sparc.c (sparc_vectorize_vec_perm_const): Require
34507 TARGET_VIS2.
34508
34509 2018-01-04 Uros Bizjak <ubizjak@gmail.com>
34510
34511 PR target/83628
34512 * config/alpha/alpha.md (*sadd<modesuffix>): Use ASHIFT
34513 instead of MULT rtx. Update all corresponding splitters.
34514 (*saddl_se): Ditto.
34515 (*ssub<modesuffix>): Ditto.
34516 (*ssubl_se): Ditto.
34517 (*cmp_sadd_di): Update split patterns.
34518 (*cmp_sadd_si): Ditto.
34519 (*cmp_sadd_sidi): Ditto.
34520 (*cmp_ssub_di): Ditto.
34521 (*cmp_ssub_si): Ditto.
34522 (*cmp_ssub_sidi): Ditto.
34523 * config/alpha/predicates.md (const23_operand): New predicate.
34524 * config/alpha/alpha.c (alpha_rtx_costs) [PLUS, MINUS]:
34525 Look for ASHIFT, not MULT inner operand.
34526 (alpha_split_conditional_move): Update for *sadd<modesuffix> change.
34527
34528 2018-01-04 Martin Liska <mliska@suse.cz>
34529
34530 PR gcov-profile/83669
34531 * gcov.c (output_intermediate_file): Add version to intermediate
34532 gcov file.
34533 * doc/gcov.texi: Document new field 'version' in intermediate
34534 file format. Fix location of '-k' option of gcov command.
34535
34536 2018-01-04 Martin Liska <mliska@suse.cz>
34537
34538 PR ipa/82352
34539 * ipa-icf.c (sem_function::merge): Do not cross comdat boundary.
34540
34541 2018-01-04 Jakub Jelinek <jakub@redhat.com>
34542
34543 * gimple-ssa-sprintf.c (parse_directive): Cast second dir.len to uhwi.
34544
34545 2018-01-03 Martin Sebor <msebor@redhat.com>
34546
34547 PR tree-optimization/83655
34548 * gimple-ssa-warn-restrict.c (wrestrict_dom_walker::check_call): Avoid
34549 checking calls with invalid arguments.
34550
34551 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
34552
34553 * tree-vect-stmts.c (vect_get_store_rhs): New function.
34554 (vectorizable_mask_load_store): Delete.
34555 (vectorizable_call): Return false for masked loads and stores.
34556 (vectorizable_store): Handle IFN_MASK_STORE. Use vect_get_store_rhs
34557 instead of gimple_assign_rhs1.
34558 (vectorizable_load): Handle IFN_MASK_LOAD.
34559 (vect_transform_stmt): Don't set is_store for call_vec_info_type.
34560
34561 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
34562
34563 * tree-vect-stmts.c (vect_build_gather_load_calls): New function,
34564 split out from..,
34565 (vectorizable_mask_load_store): ...here.
34566 (vectorizable_load): ...and here.
34567
34568 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
34569
34570 * tree-vect-stmts.c (vect_build_all_ones_mask)
34571 (vect_build_zero_merge_argument): New functions, split out from...
34572 (vectorizable_load): ...here.
34573
34574 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
34575
34576 * tree-vect-stmts.c (vect_check_store_rhs): New function,
34577 split out from...
34578 (vectorizable_mask_load_store): ...here.
34579 (vectorizable_store): ...and here.
34580
34581 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
34582
34583 * tree-vect-stmts.c (vect_check_load_store_mask): New function,
34584 split out from...
34585 (vectorizable_mask_load_store): ...here.
34586
34587 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
34588
34589 * tree-vectorizer.h (vec_load_store_type): Moved from tree-vec-stmts.c
34590 (vect_model_store_cost): Take a vec_load_store_type instead of a
34591 vect_def_type.
34592 * tree-vect-stmts.c (vec_load_store_type): Move to tree-vectorizer.h.
34593 (vect_model_store_cost): Take a vec_load_store_type instead of a
34594 vect_def_type.
34595 (vectorizable_mask_load_store): Update accordingly.
34596 (vectorizable_store): Likewise.
34597 * tree-vect-slp.c (vect_analyze_slp_cost_1): Update accordingly.
34598
34599 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
34600
34601 * tree-vect-loop.c (vect_transform_loop): Stub out scalar
34602 IFN_MASK_LOAD calls here rather than...
34603 * tree-vect-stmts.c (vectorizable_mask_load_store): ...here.
34604
34605 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
34606 Alan Hayward <alan.hayward@arm.com>
34607 David Sherwood <david.sherwood@arm.com>
34608
34609 * expmed.c (extract_bit_field_1): For vector extracts,
34610 fall back to extract_bit_field_as_subreg if vec_extract
34611 isn't available.
34612
34613 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
34614 Alan Hayward <alan.hayward@arm.com>
34615 David Sherwood <david.sherwood@arm.com>
34616
34617 * lra-spills.c (pseudo_reg_slot_compare): Sort slots by whether
34618 they are variable or constant sized.
34619 (assign_stack_slot_num_and_sort_pseudos): Don't reuse variable-sized
34620 slots for constant-sized data.
34621
34622 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
34623 Alan Hayward <alan.hayward@arm.com>
34624 David Sherwood <david.sherwood@arm.com>
34625
34626 * tree-vect-patterns.c (vect_recog_mask_conversion_pattern): When
34627 handling COND_EXPRs with boolean comparisons, try to find a better
34628 basis for the mask type than the boolean itself.
34629
34630 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
34631
34632 * doc/rtl.texi (MAX_BITSIZE_MODE_ANY_MODE): Describe how the default
34633 is calculated and how it can be overridden.
34634 * genmodes.c (max_bitsize_mode_any_mode): New variable.
34635 (create_modes): Initialize it from MAX_BITSIZE_MODE_ANY_MODE,
34636 if defined.
34637 (emit_max_int): Use it to set the output MAX_BITSIZE_MODE_ANY_MODE,
34638 if nonzero.
34639
34640 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
34641 Alan Hayward <alan.hayward@arm.com>
34642 David Sherwood <david.sherwood@arm.com>
34643
34644 * config/aarch64/aarch64-protos.h (aarch64_output_simd_mov_immediate):
34645 Remove the mode argument.
34646 (aarch64_simd_valid_immediate): Remove the mode and inverse
34647 arguments.
34648 * config/aarch64/iterators.md (bitsize): New iterator.
34649 * config/aarch64/aarch64-simd.md (*aarch64_simd_mov<mode>, and<mode>3)
34650 (ior<mode>3): Update calls to aarch64_output_simd_mov_immediate.
34651 * config/aarch64/constraints.md (Do, Db, Dn): Update calls to
34652 aarch64_simd_valid_immediate.
34653 * config/aarch64/predicates.md (aarch64_reg_or_orr_imm): Likewise.
34654 (aarch64_reg_or_bic_imm): Likewise.
34655 * config/aarch64/aarch64.c (simd_immediate_info): Replace mvn
34656 with an insn_type enum and msl with a modifier_type enum.
34657 Replace element_width with a scalar_mode. Change the shift
34658 to unsigned int. Add constructors for scalar_float_mode and
34659 scalar_int_mode elements.
34660 (aarch64_vect_float_const_representable_p): Delete.
34661 (aarch64_can_const_movi_rtx_p)
34662 (aarch64_simd_scalar_immediate_valid_for_move)
34663 (aarch64_simd_make_constant): Update call to
34664 aarch64_simd_valid_immediate.
34665 (aarch64_advsimd_valid_immediate_hs): New function.
34666 (aarch64_advsimd_valid_immediate): Likewise.
34667 (aarch64_simd_valid_immediate): Remove mode and inverse
34668 arguments. Rewrite to use the above. Use const_vec_duplicate_p
34669 to detect duplicated constants and use aarch64_float_const_zero_rtx_p
34670 and aarch64_float_const_representable_p on the result.
34671 (aarch64_output_simd_mov_immediate): Remove mode argument.
34672 Update call to aarch64_simd_valid_immediate and use of
34673 simd_immediate_info.
34674 (aarch64_output_scalar_simd_mov_immediate): Update call
34675 accordingly.
34676
34677 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
34678 Alan Hayward <alan.hayward@arm.com>
34679 David Sherwood <david.sherwood@arm.com>
34680
34681 * machmode.h (mode_precision): Prefix with CONST_MODE_PRECISION.
34682 (mode_nunits): Likewise CONST_MODE_NUNITS.
34683 * machmode.def (ADJUST_NUNITS): Document.
34684 * genmodes.c (mode_data::need_nunits_adj): New field.
34685 (blank_mode): Update accordingly.
34686 (adj_nunits): New variable.
34687 (print_maybe_const_decl): Replace CATEGORY with a NEEDS_ADJ
34688 parameter.
34689 (emit_mode_size_inline): Set need_bytesize_adj for all modes
34690 listed in adj_nunits.
34691 (emit_mode_nunits_inline): Set need_nunits_adj for all modes
34692 listed in adj_nunits. Don't emit case statements for such modes.
34693 (emit_insn_modes_h): Emit definitions of CONST_MODE_NUNITS
34694 and CONST_MODE_PRECISION. Make CONST_MODE_SIZE expand to
34695 nothing if adj_nunits is nonnull.
34696 (emit_mode_precision, emit_mode_nunits): Use print_maybe_const_decl.
34697 (emit_mode_unit_size, emit_mode_base_align, emit_mode_ibit)
34698 (emit_mode_fbit): Update use of print_maybe_const_decl.
34699 (emit_move_size): Likewise. Treat the array as non-const
34700 if adj_nunits.
34701 (emit_mode_adjustments): Handle adj_nunits.
34702
34703 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
34704
34705 * machmode.def (VECTOR_MODES_WITH_PREFIX): Document.
34706 * genmodes.c (VECTOR_MODES_WITH_PREFIX): New macro.
34707 (VECTOR_MODES): Use it.
34708 (make_vector_modes): Take the prefix as an argument.
34709
34710 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
34711 Alan Hayward <alan.hayward@arm.com>
34712 David Sherwood <david.sherwood@arm.com>
34713
34714 * mode-classes.def (MODE_VECTOR_BOOL): New mode class.
34715 * machmode.h (INTEGRAL_MODE_P, VECTOR_MODE_P): Return true
34716 for MODE_VECTOR_BOOL.
34717 * machmode.def (VECTOR_BOOL_MODE): Document.
34718 * genmodes.c (VECTOR_BOOL_MODE): New macro.
34719 (make_vector_bool_mode): New function.
34720 (complete_mode, emit_mode_wider, emit_mode_adjustments): Handle
34721 MODE_VECTOR_BOOL.
34722 * lto-streamer-in.c (lto_input_mode_table): Likewise.
34723 * rtx-vector-builder.c (rtx_vector_builder::find_cached_value):
34724 Likewise.
34725 * stor-layout.c (int_mode_for_mode): Likewise.
34726 * tree.c (build_vector_type_for_mode): Likewise.
34727 * varasm.c (output_constant_pool_2): Likewise.
34728 * emit-rtl.c (init_emit_once): Make sure that CONST1_RTX (BImode) and
34729 CONSTM1_RTX (BImode) are the same thing. Initialize const_tiny_rtx
34730 for MODE_VECTOR_BOOL.
34731 * expr.c (expand_expr_real_1): Use VECTOR_MODE_P instead of a list
34732 of mode class checks.
34733 * tree-vect-generic.c (expand_vector_operation): Use VECTOR_MODE_P
34734 instead of a list of mode class checks.
34735 (expand_vector_scalar_condition): Likewise.
34736 (type_for_widest_vector_mode): Handle BImode as an inner mode.
34737
34738 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
34739 Alan Hayward <alan.hayward@arm.com>
34740 David Sherwood <david.sherwood@arm.com>
34741
34742 * machmode.h (mode_size): Change from unsigned short to
34743 poly_uint16_pod.
34744 (mode_to_bytes): Return a poly_uint16 rather than an unsigned short.
34745 (GET_MODE_SIZE): Return a constant if ONLY_FIXED_SIZE_MODES,
34746 or if measurement_type is not polynomial.
34747 (fixed_size_mode::includes_p): Check for constant-sized modes.
34748 * genmodes.c (emit_mode_size_inline): Make mode_size_inline
34749 return a poly_uint16 rather than an unsigned short.
34750 (emit_mode_size): Change the type of mode_size from unsigned short
34751 to poly_uint16_pod. Use ZERO_COEFFS for the initializer.
34752 (emit_mode_adjustments): Cope with polynomial vector sizes.
34753 * lto-streamer-in.c (lto_input_mode_table): Use bp_unpack_poly_value
34754 for GET_MODE_SIZE.
34755 * lto-streamer-out.c (lto_write_mode_table): Use bp_pack_poly_value
34756 for GET_MODE_SIZE.
34757 * auto-inc-dec.c (try_merge): Treat GET_MODE_SIZE as polynomial.
34758 * builtins.c (expand_ifn_atomic_compare_exchange_into_call): Likewise.
34759 * caller-save.c (setup_save_areas): Likewise.
34760 (replace_reg_with_saved_mem): Likewise.
34761 * calls.c (emit_library_call_value_1): Likewise.
34762 * combine-stack-adj.c (combine_stack_adjustments_for_block): Likewise.
34763 * combine.c (simplify_set, make_extraction, simplify_shift_const_1)
34764 (gen_lowpart_for_combine): Likewise.
34765 * convert.c (convert_to_integer_1): Likewise.
34766 * cse.c (equiv_constant, cse_insn): Likewise.
34767 * cselib.c (autoinc_split, cselib_hash_rtx): Likewise.
34768 (cselib_subst_to_values): Likewise.
34769 * dce.c (word_dce_process_block): Likewise.
34770 * df-problems.c (df_word_lr_mark_ref): Likewise.
34771 * dwarf2cfi.c (init_one_dwarf_reg_size): Likewise.
34772 * dwarf2out.c (multiple_reg_loc_descriptor, mem_loc_descriptor)
34773 (concat_loc_descriptor, concatn_loc_descriptor, loc_descriptor)
34774 (rtl_for_decl_location): Likewise.
34775 * emit-rtl.c (gen_highpart, widen_memory_access): Likewise.
34776 * expmed.c (extract_bit_field_1, extract_integral_bit_field): Likewise.
34777 * expr.c (emit_group_load_1, clear_storage_hints): Likewise.
34778 (emit_move_complex, emit_move_multi_word, emit_push_insn): Likewise.
34779 (expand_expr_real_1): Likewise.
34780 * function.c (assign_parm_setup_block_p, assign_parm_setup_block)
34781 (pad_below): Likewise.
34782 * gimple-fold.c (optimize_atomic_compare_exchange_p): Likewise.
34783 * gimple-ssa-store-merging.c (rhs_valid_for_store_merging_p): Likewise.
34784 * ira.c (get_subreg_tracking_sizes): Likewise.
34785 * ira-build.c (ira_create_allocno_objects): Likewise.
34786 * ira-color.c (coalesced_pseudo_reg_slot_compare): Likewise.
34787 (ira_sort_regnos_for_alter_reg): Likewise.
34788 * ira-costs.c (record_operand_costs): Likewise.
34789 * lower-subreg.c (interesting_mode_p, simplify_gen_subreg_concatn)
34790 (resolve_simple_move): Likewise.
34791 * lra-constraints.c (get_reload_reg, operands_match_p): Likewise.
34792 (process_addr_reg, simplify_operand_subreg, curr_insn_transform)
34793 (lra_constraints): Likewise.
34794 (CONST_POOL_OK_P): Reject variable-sized modes.
34795 * lra-spills.c (slot, assign_mem_slot, pseudo_reg_slot_compare)
34796 (add_pseudo_to_slot, lra_spill): Likewise.
34797 * omp-low.c (omp_clause_aligned_alignment): Likewise.
34798 * optabs-query.c (get_best_extraction_insn): Likewise.
34799 * optabs-tree.c (expand_vec_cond_expr_p): Likewise.
34800 * optabs.c (expand_vec_perm_var, expand_vec_cond_expr): Likewise.
34801 (expand_mult_highpart, valid_multiword_target_p): Likewise.
34802 * recog.c (offsettable_address_addr_space_p): Likewise.
34803 * regcprop.c (maybe_mode_change): Likewise.
34804 * reginfo.c (choose_hard_reg_mode, record_subregs_of_mode): Likewise.
34805 * regrename.c (build_def_use): Likewise.
34806 * regstat.c (dump_reg_info): Likewise.
34807 * reload.c (complex_word_subreg_p, push_reload, find_dummy_reload)
34808 (find_reloads, find_reloads_subreg_address): Likewise.
34809 * reload1.c (eliminate_regs_1): Likewise.
34810 * rtlanal.c (for_each_inc_dec_find_inc_dec, rtx_cost): Likewise.
34811 * simplify-rtx.c (avoid_constant_pool_reference): Likewise.
34812 (simplify_binary_operation_1, simplify_subreg): Likewise.
34813 * targhooks.c (default_function_arg_padding): Likewise.
34814 (default_hard_regno_nregs, default_class_max_nregs): Likewise.
34815 * tree-cfg.c (verify_gimple_assign_binary): Likewise.
34816 (verify_gimple_assign_ternary): Likewise.
34817 * tree-inline.c (estimate_move_cost): Likewise.
34818 * tree-ssa-forwprop.c (simplify_vector_constructor): Likewise.
34819 * tree-ssa-loop-ivopts.c (add_autoinc_candidates): Likewise.
34820 (get_address_cost_ainc): Likewise.
34821 * tree-vect-data-refs.c (vect_enhance_data_refs_alignment): Likewise.
34822 (vect_supportable_dr_alignment): Likewise.
34823 * tree-vect-loop.c (vect_determine_vectorization_factor): Likewise.
34824 (vectorizable_reduction): Likewise.
34825 * tree-vect-stmts.c (vectorizable_assignment, vectorizable_shift)
34826 (vectorizable_operation, vectorizable_load): Likewise.
34827 * tree.c (build_same_sized_truth_vector_type): Likewise.
34828 * valtrack.c (cleanup_auto_inc_dec): Likewise.
34829 * var-tracking.c (emit_note_insn_var_location): Likewise.
34830 * config/arc/arc.h (ASM_OUTPUT_CASE_END): Use as_a <scalar_int_mode>.
34831 (ADDR_VEC_ALIGN): Likewise.
34832
34833 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
34834 Alan Hayward <alan.hayward@arm.com>
34835 David Sherwood <david.sherwood@arm.com>
34836
34837 * machmode.h (mode_to_bits): Return a poly_uint16 rather than an
34838 unsigned short.
34839 (GET_MODE_BITSIZE): Return a constant if ONLY_FIXED_SIZE_MODES,
34840 or if measurement_type is polynomial.
34841 * calls.c (shift_return_value): Treat GET_MODE_BITSIZE as polynomial.
34842 * combine.c (make_extraction): Likewise.
34843 * dse.c (find_shift_sequence): Likewise.
34844 * dwarf2out.c (mem_loc_descriptor): Likewise.
34845 * expmed.c (store_integral_bit_field, extract_bit_field_1): Likewise.
34846 (extract_bit_field, extract_low_bits): Likewise.
34847 * expr.c (convert_move, convert_modes, emit_move_insn_1): Likewise.
34848 (optimize_bitfield_assignment_op, expand_assignment): Likewise.
34849 (store_expr_with_bounds, store_field, expand_expr_real_1): Likewise.
34850 * fold-const.c (optimize_bit_field_compare, merge_ranges): Likewise.
34851 * gimple-fold.c (optimize_atomic_compare_exchange_p): Likewise.
34852 * reload.c (find_reloads): Likewise.
34853 * reload1.c (alter_reg): Likewise.
34854 * stor-layout.c (bitwise_mode_for_mode, compute_record_mode): Likewise.
34855 * targhooks.c (default_secondary_memory_needed_mode): Likewise.
34856 * tree-if-conv.c (predicate_mem_writes): Likewise.
34857 * tree-ssa-strlen.c (handle_builtin_memcmp): Likewise.
34858 * tree-vect-patterns.c (adjust_bool_pattern): Likewise.
34859 * tree-vect-stmts.c (vectorizable_simd_clone_call): Likewise.
34860 * valtrack.c (dead_debug_insert_temp): Likewise.
34861 * varasm.c (mergeable_constant_section): Likewise.
34862 * config/sh/sh.h (LOCAL_ALIGNMENT): Use as_a <fixed_size_mode>.
34863
34864 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
34865 Alan Hayward <alan.hayward@arm.com>
34866 David Sherwood <david.sherwood@arm.com>
34867
34868 * expr.c (expand_assignment): Cope with polynomial mode sizes
34869 when assigning to a CONCAT.
34870
34871 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
34872 Alan Hayward <alan.hayward@arm.com>
34873 David Sherwood <david.sherwood@arm.com>
34874
34875 * machmode.h (mode_precision): Change from unsigned short to
34876 poly_uint16_pod.
34877 (mode_to_precision): Return a poly_uint16 rather than an unsigned
34878 short.
34879 (GET_MODE_PRECISION): Return a constant if ONLY_FIXED_SIZE_MODES,
34880 or if measurement_type is not polynomial.
34881 (HWI_COMPUTABLE_MODE_P): Turn into a function. Optimize the case
34882 in which the mode is already known to be a scalar_int_mode.
34883 * genmodes.c (emit_mode_precision): Change the type of mode_precision
34884 from unsigned short to poly_uint16_pod. Use ZERO_COEFFS for the
34885 initializer.
34886 * lto-streamer-in.c (lto_input_mode_table): Use bp_unpack_poly_value
34887 for GET_MODE_PRECISION.
34888 * lto-streamer-out.c (lto_write_mode_table): Use bp_pack_poly_value
34889 for GET_MODE_PRECISION.
34890 * combine.c (update_rsp_from_reg_equal): Treat GET_MODE_PRECISION
34891 as polynomial.
34892 (try_combine, find_split_point, combine_simplify_rtx): Likewise.
34893 (expand_field_assignment, make_extraction): Likewise.
34894 (make_compound_operation_int, record_dead_and_set_regs_1): Likewise.
34895 (get_last_value): Likewise.
34896 * convert.c (convert_to_integer_1): Likewise.
34897 * cse.c (cse_insn): Likewise.
34898 * expr.c (expand_expr_real_1): Likewise.
34899 * lra-constraints.c (simplify_operand_subreg): Likewise.
34900 * optabs-query.c (can_atomic_load_p): Likewise.
34901 * optabs.c (expand_atomic_load): Likewise.
34902 (expand_atomic_store): Likewise.
34903 * ree.c (combine_reaching_defs): Likewise.
34904 * rtl.h (partial_subreg_p, paradoxical_subreg_p): Likewise.
34905 * rtlanal.c (nonzero_bits1, lsb_bitfield_op_p): Likewise.
34906 * tree.h (type_has_mode_precision_p): Likewise.
34907 * ubsan.c (instrument_si_overflow): Likewise.
34908
34909 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
34910 Alan Hayward <alan.hayward@arm.com>
34911 David Sherwood <david.sherwood@arm.com>
34912
34913 * tree.h (TYPE_VECTOR_SUBPARTS): Turn into a function and handle
34914 polynomial numbers of units.
34915 (SET_TYPE_VECTOR_SUBPARTS): Likewise.
34916 (valid_vector_subparts_p): New function.
34917 (build_vector_type): Remove temporary shim and take the number
34918 of units as a poly_uint64 rather than an int.
34919 (build_opaque_vector_type): Take the number of units as a
34920 poly_uint64 rather than an int.
34921 * tree.c (build_vector_from_ctor): Handle polynomial
34922 TYPE_VECTOR_SUBPARTS.
34923 (type_hash_canon_hash, type_cache_hasher::equal): Likewise.
34924 (uniform_vector_p, vector_type_mode, build_vector): Likewise.
34925 (build_vector_from_val): If the number of units is variable,
34926 use build_vec_duplicate_cst for constant operands and
34927 VEC_DUPLICATE_EXPR otherwise.
34928 (make_vector_type): Remove temporary is_constant ().
34929 (build_vector_type, build_opaque_vector_type): Take the number of
34930 units as a poly_uint64 rather than an int.
34931 (check_vector_cst): Handle polynomial TYPE_VECTOR_SUBPARTS and
34932 VECTOR_CST_NELTS.
34933 * cfgexpand.c (expand_debug_expr): Likewise.
34934 * expr.c (count_type_elements, categorize_ctor_elements_1): Likewise.
34935 (store_constructor, expand_expr_real_1): Likewise.
34936 (const_scalar_mask_from_tree): Likewise.
34937 * fold-const-call.c (fold_const_reduction): Likewise.
34938 * fold-const.c (const_binop, const_unop, fold_convert_const): Likewise.
34939 (operand_equal_p, fold_vec_perm, fold_ternary_loc): Likewise.
34940 (native_encode_vector, vec_cst_ctor_to_array): Likewise.
34941 (fold_relational_const): Likewise.
34942 (native_interpret_vector): Likewise. Change the size from an
34943 int to an unsigned int.
34944 * gimple-fold.c (gimple_fold_stmt_to_constant_1): Handle polynomial
34945 TYPE_VECTOR_SUBPARTS.
34946 (gimple_fold_indirect_ref, gimple_build_vector): Likewise.
34947 (gimple_build_vector_from_val): Use VEC_DUPLICATE_EXPR when
34948 duplicating a non-constant operand into a variable-length vector.
34949 * hsa-brig.c (hsa_op_immed::emit_to_buffer): Handle polynomial
34950 TYPE_VECTOR_SUBPARTS and VECTOR_CST_NELTS.
34951 * ipa-icf.c (sem_variable::equals): Likewise.
34952 * match.pd: Likewise.
34953 * omp-simd-clone.c (simd_clone_subparts): Likewise.
34954 * print-tree.c (print_node): Likewise.
34955 * stor-layout.c (layout_type): Likewise.
34956 * targhooks.c (default_builtin_vectorization_cost): Likewise.
34957 * tree-cfg.c (verify_gimple_comparison): Likewise.
34958 (verify_gimple_assign_binary): Likewise.
34959 (verify_gimple_assign_ternary): Likewise.
34960 (verify_gimple_assign_single): Likewise.
34961 * tree-pretty-print.c (dump_generic_node): Likewise.
34962 * tree-ssa-forwprop.c (simplify_vector_constructor): Likewise.
34963 (simplify_bitfield_ref, is_combined_permutation_identity): Likewise.
34964 * tree-vect-data-refs.c (vect_permute_store_chain): Likewise.
34965 (vect_grouped_load_supported, vect_permute_load_chain): Likewise.
34966 (vect_shift_permute_load_chain): Likewise.
34967 * tree-vect-generic.c (nunits_for_known_piecewise_op): Likewise.
34968 (expand_vector_condition, optimize_vector_constructor): Likewise.
34969 (lower_vec_perm, get_compute_type): Likewise.
34970 * tree-vect-loop.c (vect_determine_vectorization_factor): Likewise.
34971 (get_initial_defs_for_reduction, vect_transform_loop): Likewise.
34972 * tree-vect-patterns.c (vect_recog_bool_pattern): Likewise.
34973 (vect_recog_mask_conversion_pattern): Likewise.
34974 * tree-vect-slp.c (vect_supported_load_permutation_p): Likewise.
34975 (vect_get_constant_vectors, vect_transform_slp_perm_load): Likewise.
34976 * tree-vect-stmts.c (perm_mask_for_reverse): Likewise.
34977 (get_group_load_store_type, vectorizable_mask_load_store): Likewise.
34978 (vectorizable_bswap, simd_clone_subparts, vectorizable_assignment)
34979 (vectorizable_shift, vectorizable_operation, vectorizable_store)
34980 (vectorizable_load, vect_is_simple_cond, vectorizable_comparison)
34981 (supportable_widening_operation): Likewise.
34982 (supportable_narrowing_operation): Likewise.
34983 * tree-vector-builder.c (tree_vector_builder::binary_encoded_nelts):
34984 Likewise.
34985 * varasm.c (output_constant): Likewise.
34986
34987 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
34988 Alan Hayward <alan.hayward@arm.com>
34989 David Sherwood <david.sherwood@arm.com>
34990
34991 * tree-vect-data-refs.c (vect_permute_store_chain): Reorganize
34992 so that both the length == 3 and length != 3 cases set up their
34993 own permute vectors. Add comments explaining why we know the
34994 number of elements is constant.
34995 (vect_permute_load_chain): Likewise.
34996
34997 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
34998 Alan Hayward <alan.hayward@arm.com>
34999 David Sherwood <david.sherwood@arm.com>
35000
35001 * machmode.h (mode_nunits): Change from unsigned char to
35002 poly_uint16_pod.
35003 (ONLY_FIXED_SIZE_MODES): New macro.
35004 (pod_mode::measurement_type, scalar_int_mode::measurement_type)
35005 (scalar_float_mode::measurement_type, scalar_mode::measurement_type)
35006 (complex_mode::measurement_type, fixed_size_mode::measurement_type):
35007 New typedefs.
35008 (mode_to_nunits): Return a poly_uint16 rather than an unsigned short.
35009 (GET_MODE_NUNITS): Return a constant if ONLY_FIXED_SIZE_MODES,
35010 or if measurement_type is not polynomial.
35011 * genmodes.c (ZERO_COEFFS): New macro.
35012 (emit_mode_nunits_inline): Make mode_nunits_inline return a
35013 poly_uint16.
35014 (emit_mode_nunits): Change the type of mode_nunits to poly_uint16_pod.
35015 Use ZERO_COEFFS when emitting initializers.
35016 * data-streamer.h (bp_pack_poly_value): New function.
35017 (bp_unpack_poly_value): Likewise.
35018 * lto-streamer-in.c (lto_input_mode_table): Use bp_unpack_poly_value
35019 for GET_MODE_NUNITS.
35020 * lto-streamer-out.c (lto_write_mode_table): Use bp_pack_poly_value
35021 for GET_MODE_NUNITS.
35022 * tree.c (make_vector_type): Remove temporary shim and make
35023 the real function take the number of units as a poly_uint64
35024 rather than an int.
35025 (build_vector_type_for_mode): Handle polynomial nunits.
35026 * dwarf2out.c (loc_descriptor, add_const_value_attribute): Likewise.
35027 * emit-rtl.c (const_vec_series_p_1): Likewise.
35028 (gen_rtx_CONST_VECTOR): Likewise.
35029 * fold-const.c (test_vec_duplicate_folding): Likewise.
35030 * genrecog.c (validate_pattern): Likewise.
35031 * optabs-query.c (can_vec_perm_var_p, can_mult_highpart_p): Likewise.
35032 * optabs-tree.c (expand_vec_cond_expr_p): Likewise.
35033 * optabs.c (expand_vector_broadcast, expand_binop_directly): Likewise.
35034 (shift_amt_for_vec_perm_mask, expand_vec_perm_var): Likewise.
35035 (expand_vec_cond_expr, expand_mult_highpart): Likewise.
35036 * rtlanal.c (subreg_get_info): Likewise.
35037 * tree-vect-data-refs.c (vect_grouped_store_supported): Likewise.
35038 (vect_grouped_load_supported): Likewise.
35039 * tree-vect-generic.c (type_for_widest_vector_mode): Likewise.
35040 * tree-vect-loop.c (have_whole_vector_shift): Likewise.
35041 * simplify-rtx.c (simplify_unary_operation_1): Likewise.
35042 (simplify_const_unary_operation, simplify_binary_operation_1)
35043 (simplify_const_binary_operation, simplify_ternary_operation)
35044 (test_vector_ops_duplicate, test_vector_ops): Likewise.
35045 (simplify_immed_subreg): Use GET_MODE_NUNITS on a fixed_size_mode
35046 instead of CONST_VECTOR_NUNITS.
35047 * varasm.c (output_constant_pool_2): Likewise.
35048 * rtx-vector-builder.c (rtx_vector_builder::build): Only include the
35049 explicit-encoded elements in the XVEC for variable-length vectors.
35050
35051 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
35052
35053 * lra-constraints.c (curr_insn_transform): Use partial_subreg_p.
35054
35055 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
35056 Alan Hayward <alan.hayward@arm.com>
35057 David Sherwood <david.sherwood@arm.com>
35058
35059 * coretypes.h (fixed_size_mode): Declare.
35060 (fixed_size_mode_pod): New typedef.
35061 * builtins.h (target_builtins::x_apply_args_mode)
35062 (target_builtins::x_apply_result_mode): Change type to
35063 fixed_size_mode_pod.
35064 * builtins.c (apply_args_size, apply_result_size, result_vector)
35065 (expand_builtin_apply_args_1, expand_builtin_apply)
35066 (expand_builtin_return): Update accordingly.
35067
35068 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
35069
35070 * cse.c (hash_rtx_cb): Hash only the encoded elements.
35071 * cselib.c (cselib_hash_rtx): Likewise.
35072 * expmed.c (make_tree): Build VECTOR_CSTs directly from the
35073 CONST_VECTOR encoding.
35074
35075 2018-01-03 Jakub Jelinek <jakub@redhat.com>
35076 Jeff Law <law@redhat.com>
35077
35078 PR target/83641
35079 * config/i386/i386.c (ix86_adjust_stack_and_probe_stack_clash): For
35080 noreturn probe, use gen_pop instead of ix86_emit_restore_reg_using_pop,
35081 only set RTX_FRAME_RELATED_P on both the push and pop if cfa_reg is sp
35082 and add REG_CFA_ADJUST_CFA notes in that case to both insns.
35083
35084 PR target/83641
35085 * config/i386/i386.c (ix86_adjust_stack_and_probe_stack_clash): Do not
35086 explicitly probe *sp in a noreturn function if there were any callee
35087 register saves or frame pointer is needed.
35088
35089 2018-01-03 Jakub Jelinek <jakub@redhat.com>
35090
35091 PR debug/83621
35092 * cfgexpand.c (expand_debug_expr): Return NULL if mode is
35093 BLKmode for ternary, binary or unary expressions.
35094
35095 PR debug/83645
35096 * var-tracking.c (delete_vta_debug_insn): New inline function.
35097 (delete_vta_debug_insns): Add USE_CFG argument, if true, walk just
35098 insns from get_insns () to NULL instead of each bb separately.
35099 Use delete_vta_debug_insn. No longer static.
35100 (vt_debug_insns_local, variable_tracking_main_1): Adjust
35101 delete_vta_debug_insns callers.
35102 * rtl.h (delete_vta_debug_insns): Declare.
35103 * final.c (rest_of_handle_final): Call delete_vta_debug_insns
35104 instead of variable_tracking_main.
35105
35106 2018-01-03 Martin Sebor <msebor@redhat.com>
35107
35108 PR tree-optimization/83603
35109 * calls.c (maybe_warn_nonstring_arg): Avoid accessing function
35110 arguments past the endof the argument list in functions declared
35111 without a prototype.
35112 * gimple-ssa-warn-restrict.c (wrestrict_dom_walker::check_call):
35113 Avoid checking when arguments are null.
35114
35115 2018-01-03 Martin Sebor <msebor@redhat.com>
35116
35117 PR c/83559
35118 * doc/extend.texi (attribute const): Fix a typo.
35119 * ipa-pure-const.c ((warn_function_const, warn_function_pure): Avoid
35120 issuing -Wsuggest-attribute for void functions.
35121
35122 2018-01-03 Martin Sebor <msebor@redhat.com>
35123
35124 * gimple-ssa-warn-restrict.c (builtin_memref::builtin_memref): Use
35125 offset_int::from instead of wide_int::to_shwi.
35126 (maybe_diag_overlap): Remove assertion.
35127 Use HOST_WIDE_INT_PRINT_DEC instead of %lli.
35128 * gimple-ssa-sprintf.c (format_directive): Same.
35129 (parse_directive): Same.
35130 (sprintf_dom_walker::compute_format_length): Same.
35131 (try_substitute_return_value): Same.
35132
35133 2018-01-03 Jeff Law <law@redhat.com>
35134
35135 PR middle-end/83654
35136 * explow.c (anti_adjust_stack_and_probe_stack_clash): Test a
35137 non-constant residual for zero at runtime and avoid probing in
35138 that case. Reorganize code for trailing problem to mirror handling
35139 of the residual.
35140
35141 2018-01-03 Prathamesh Kulkarni <prathamesh.kulkarni@linaro.org>
35142
35143 PR tree-optimization/83501
35144 * tree-ssa-strlen.c (get_string_cst): New.
35145 (handle_char_store): Call get_string_cst.
35146
35147 2018-01-03 Martin Liska <mliska@suse.cz>
35148
35149 PR tree-optimization/83593
35150 * tree-ssa-strlen.c: Include tree-cfg.h.
35151 (strlen_check_and_optimize_stmt): Add new argument cleanup_eh.
35152 (strlen_dom_walker): Add new member variable m_cleanup_cfg.
35153 (strlen_dom_walker::strlen_dom_walker): Initialize m_cleanup_cfg
35154 to false.
35155 (strlen_dom_walker::before_dom_children): Call
35156 gimple_purge_dead_eh_edges. Dump tranformation with details
35157 dump flags.
35158 (strlen_dom_walker::before_dom_children): Update call by adding
35159 new argument cleanup_eh.
35160 (pass_strlen::execute): Return TODO_cleanup_cfg if needed.
35161
35162 2018-01-03 Martin Liska <mliska@suse.cz>
35163
35164 PR ipa/83549
35165 * cif-code.def (VARIADIC_THUNK): New enum value.
35166 * ipa-fnsummary.c (compute_fn_summary): Do not inline variadic
35167 thunks.
35168
35169 2018-01-03 Jan Beulich <jbeulich@suse.com>
35170
35171 * sse.md (mov<mode>_internal): Tighten condition for when to use
35172 vmovdqu<ssescalarsize> for TI and OI modes.
35173
35174 2018-01-03 Jakub Jelinek <jakub@redhat.com>
35175
35176 Update copyright years.
35177
35178 2018-01-03 Martin Liska <mliska@suse.cz>
35179
35180 PR ipa/83594
35181 * ipa-visibility.c (function_and_variable_visibility): Skip
35182 functions with noipa attribure.
35183
35184 2018-01-03 Jakub Jelinek <jakub@redhat.com>
35185
35186 * gcc.c (process_command): Update copyright notice dates.
35187 * gcov-dump.c (print_version): Ditto.
35188 * gcov.c (print_version): Ditto.
35189 * gcov-tool.c (print_version): Ditto.
35190 * gengtype.c (create_file): Ditto.
35191 * doc/cpp.texi: Bump @copying's copyright year.
35192 * doc/cppinternals.texi: Ditto.
35193 * doc/gcc.texi: Ditto.
35194 * doc/gccint.texi: Ditto.
35195 * doc/gcov.texi: Ditto.
35196 * doc/install.texi: Ditto.
35197 * doc/invoke.texi: Ditto.
35198
35199 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
35200
35201 * vector-builder.h (vector_builder::m_full_nelts): Change from
35202 unsigned int to poly_uint64.
35203 (vector_builder::full_nelts): Update prototype accordingly.
35204 (vector_builder::new_vector): Likewise.
35205 (vector_builder::encoded_full_vector_p): Handle polynomial full_nelts.
35206 (vector_builder::operator ==): Likewise.
35207 (vector_builder::finalize): Likewise.
35208 * int-vector-builder.h (int_vector_builder::int_vector_builder):
35209 Take the number of elements as a poly_uint64 rather than an
35210 unsigned int.
35211 * vec-perm-indices.h (vec_perm_indices::m_nelts_per_input): Change
35212 from unsigned int to poly_uint64.
35213 (vec_perm_indices::vec_perm_indices): Update prototype accordingly.
35214 (vec_perm_indices::new_vector): Likewise.
35215 (vec_perm_indices::length): Likewise.
35216 (vec_perm_indices::nelts_per_input): Likewise.
35217 (vec_perm_indices::input_nelts): Likewise.
35218 * vec-perm-indices.c (vec_perm_indices::new_vector): Take the
35219 number of elements per input as a poly_uint64 rather than an
35220 unsigned int. Use the original encoding for variable-length
35221 vectors, rather than clamping each individual element.
35222 For the second and subsequent elements in each pattern,
35223 clamp the step and base before clamping their sum.
35224 (vec_perm_indices::series_p): Handle polynomial element counts.
35225 (vec_perm_indices::all_in_range_p): Likewise.
35226 (vec_perm_indices_to_tree): Likewise.
35227 (vec_perm_indices_to_rtx): Likewise.
35228 * tree-vect-stmts.c (vect_gen_perm_mask_any): Likewise.
35229 * tree-vector-builder.c (tree_vector_builder::new_unary_operation)
35230 (tree_vector_builder::new_binary_operation): Handle polynomial
35231 element counts. Return false if we need to know the number
35232 of elements at compile time.
35233 * fold-const.c (fold_vec_perm): Punt if the number of elements
35234 isn't known at compile time.
35235
35236 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
35237
35238 * vec-perm-indices.h (vec_perm_builder): Change element type
35239 from HOST_WIDE_INT to poly_int64.
35240 (vec_perm_indices::element_type): Update accordingly.
35241 (vec_perm_indices::clamp): Handle polynomial element_types.
35242 * vec-perm-indices.c (vec_perm_indices::series_p): Likewise.
35243 (vec_perm_indices::all_in_range_p): Likewise.
35244 (tree_to_vec_perm_builder): Check for poly_int64 trees rather
35245 than shwi trees.
35246 * vector-builder.h (vector_builder::stepped_sequence_p): Handle
35247 polynomial vec_perm_indices element types.
35248 * int-vector-builder.h (int_vector_builder::equal_p): Likewise.
35249 * fold-const.c (fold_vec_perm): Likewise.
35250 * optabs.c (shift_amt_for_vec_perm_mask): Likewise.
35251 * tree-vect-generic.c (lower_vec_perm): Likewise.
35252 * tree-vect-slp.c (vect_transform_slp_perm_load): Likewise.
35253 * config/aarch64/aarch64.c (aarch64_evpc_tbl): Cast d->perm
35254 element type to HOST_WIDE_INT.
35255
35256 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
35257 Alan Hayward <alan.hayward@arm.com>
35258 David Sherwood <david.sherwood@arm.com>
35259
35260 * alias.c (addr_side_effect_eval): Take the size as a poly_int64
35261 rather than an int. Use plus_constant.
35262 (memrefs_conflict_p): Take the sizes as poly_int64s rather than ints.
35263 Take the offset "c" as a poly_int64 rather than a HOST_WIDE_INT.
35264
35265 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
35266 Alan Hayward <alan.hayward@arm.com>
35267 David Sherwood <david.sherwood@arm.com>
35268
35269 * calls.c (emit_call_1, expand_call): Change struct_value_size from
35270 a HOST_WIDE_INT to a poly_int64.
35271
35272 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
35273 Alan Hayward <alan.hayward@arm.com>
35274 David Sherwood <david.sherwood@arm.com>
35275
35276 * calls.c (load_register_parameters): Cope with polynomial
35277 mode sizes. Require a constant size for BLKmode parameters
35278 that aren't described by a PARALLEL. If BLOCK_REG_PADDING
35279 forces a parameter to be padded at the lsb end in order to
35280 fill a complete number of words, require the parameter size
35281 to be ordered wrt UNITS_PER_WORD.
35282
35283 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
35284 Alan Hayward <alan.hayward@arm.com>
35285 David Sherwood <david.sherwood@arm.com>
35286
35287 * reload1.c (spill_stack_slot_width): Change element type
35288 from unsigned int to poly_uint64_pod.
35289 (alter_reg): Treat mode sizes as polynomial.
35290
35291 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
35292 Alan Hayward <alan.hayward@arm.com>
35293 David Sherwood <david.sherwood@arm.com>
35294
35295 * reload.c (complex_word_subreg_p): New function.
35296 (reload_inner_reg_of_subreg, push_reload): Use it.
35297
35298 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
35299 Alan Hayward <alan.hayward@arm.com>
35300 David Sherwood <david.sherwood@arm.com>
35301
35302 * lra-constraints.c (process_alt_operands): Reject matched
35303 operands whose sizes aren't ordered.
35304 (match_reload): Refer to this check here.
35305
35306 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
35307 Alan Hayward <alan.hayward@arm.com>
35308 David Sherwood <david.sherwood@arm.com>
35309
35310 * builtins.c (expand_ifn_atomic_compare_exchange_into_call): Assert
35311 that the mode size is in the set {1, 2, 4, 8, 16}.
35312
35313 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
35314 Alan Hayward <alan.hayward@arm.com>
35315 David Sherwood <david.sherwood@arm.com>
35316
35317 * var-tracking.c (adjust_mems): Treat mode sizes as polynomial.
35318 Use plus_constant instead of gen_rtx_PLUS.
35319
35320 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
35321 Alan Hayward <alan.hayward@arm.com>
35322 David Sherwood <david.sherwood@arm.com>
35323
35324 * config/cr16/cr16-protos.h (cr16_push_rounding): Declare.
35325 * config/cr16/cr16.h (PUSH_ROUNDING): Move implementation to...
35326 * config/cr16/cr16.c (cr16_push_rounding): ...this new function.
35327 * config/h8300/h8300-protos.h (h8300_push_rounding): Declare.
35328 * config/h8300/h8300.h (PUSH_ROUNDING): Move implementation to...
35329 * config/h8300/h8300.c (h8300_push_rounding): ...this new function.
35330 * config/i386/i386-protos.h (ix86_push_rounding): Declare.
35331 * config/i386/i386.h (PUSH_ROUNDING): Move implementation to...
35332 * config/i386/i386.c (ix86_push_rounding): ...this new function.
35333 * config/m32c/m32c-protos.h (m32c_push_rounding): Take and return
35334 a poly_int64.
35335 * config/m32c/m32c.c (m32c_push_rounding): Likewise.
35336 * config/m68k/m68k-protos.h (m68k_push_rounding): Declare.
35337 * config/m68k/m68k.h (PUSH_ROUNDING): Move implementation to...
35338 * config/m68k/m68k.c (m68k_push_rounding): ...this new function.
35339 * config/pdp11/pdp11-protos.h (pdp11_push_rounding): Declare.
35340 * config/pdp11/pdp11.h (PUSH_ROUNDING): Move implementation to...
35341 * config/pdp11/pdp11.c (pdp11_push_rounding): ...this new function.
35342 * config/stormy16/stormy16-protos.h (xstormy16_push_rounding): Declare.
35343 * config/stormy16/stormy16.h (PUSH_ROUNDING): Move implementation to...
35344 * config/stormy16/stormy16.c (xstormy16_push_rounding): ...this new
35345 function.
35346 * expr.c (emit_move_resolve_push): Treat the input and result
35347 of PUSH_ROUNDING as a poly_int64.
35348 (emit_move_complex_push, emit_single_push_insn_1): Likewise.
35349 (emit_push_insn): Likewise.
35350 * lra-eliminations.c (mark_not_eliminable): Likewise.
35351 * recog.c (push_operand): Likewise.
35352 * reload1.c (elimination_effects): Likewise.
35353 * rtlanal.c (nonzero_bits1): Likewise.
35354 * calls.c (store_one_arg): Likewise. Require the padding to be
35355 known at compile time.
35356
35357 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
35358 Alan Hayward <alan.hayward@arm.com>
35359 David Sherwood <david.sherwood@arm.com>
35360
35361 * expr.c (emit_single_push_insn_1): Treat mode sizes as polynomial.
35362 Use plus_constant instead of gen_rtx_PLUS.
35363
35364 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
35365 Alan Hayward <alan.hayward@arm.com>
35366 David Sherwood <david.sherwood@arm.com>
35367
35368 * auto-inc-dec.c (set_inc_state): Take the mode size as a poly_int64
35369 rather than an int.
35370
35371 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
35372 Alan Hayward <alan.hayward@arm.com>
35373 David Sherwood <david.sherwood@arm.com>
35374
35375 * expr.c (expand_expr_real_1): Use tree_to_poly_uint64
35376 instead of int_size_in_bytes when handling VIEW_CONVERT_EXPRs
35377 via stack temporaries. Treat the mode size as polynomial too.
35378
35379 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
35380 Alan Hayward <alan.hayward@arm.com>
35381 David Sherwood <david.sherwood@arm.com>
35382
35383 * expr.c (expand_expr_real_2): When handling conversions involving
35384 unions, apply tree_to_poly_uint64 to the TYPE_SIZE rather than
35385 multiplying int_size_in_bytes by BITS_PER_UNIT. Treat GET_MODE_BISIZE
35386 as a poly_uint64 too.
35387
35388 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
35389 Alan Hayward <alan.hayward@arm.com>
35390 David Sherwood <david.sherwood@arm.com>
35391
35392 * rtlanal.c (subreg_get_info): Handle polynomial mode sizes.
35393
35394 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
35395 Alan Hayward <alan.hayward@arm.com>
35396 David Sherwood <david.sherwood@arm.com>
35397
35398 * combine.c (can_change_dest_mode): Handle polynomial
35399 REGMODE_NATURAL_SIZE.
35400 * expmed.c (store_bit_field_1): Likewise.
35401 * expr.c (store_constructor): Likewise.
35402 * emit-rtl.c (validate_subreg): Operate on polynomial mode sizes
35403 and polynomial REGMODE_NATURAL_SIZE.
35404 (gen_lowpart_common): Likewise.
35405 * reginfo.c (record_subregs_of_mode): Likewise.
35406 * rtlanal.c (read_modify_subreg_p): Likewise.
35407
35408 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
35409 Alan Hayward <alan.hayward@arm.com>
35410 David Sherwood <david.sherwood@arm.com>
35411
35412 * internal-fn.c (expand_vector_ubsan_overflow): Handle polynomial
35413 numbers of elements.
35414
35415 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
35416 Alan Hayward <alan.hayward@arm.com>
35417 David Sherwood <david.sherwood@arm.com>
35418
35419 * match.pd: Cope with polynomial numbers of vector elements.
35420
35421 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
35422 Alan Hayward <alan.hayward@arm.com>
35423 David Sherwood <david.sherwood@arm.com>
35424
35425 * fold-const.c (fold_indirect_ref_1): Handle polynomial offsets
35426 in a POINTER_PLUS_EXPR.
35427
35428 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
35429 Alan Hayward <alan.hayward@arm.com>
35430 David Sherwood <david.sherwood@arm.com>
35431
35432 * omp-simd-clone.c (simd_clone_subparts): New function.
35433 (simd_clone_init_simd_arrays): Use it instead of TYPE_VECTOR_SUBPARTS.
35434 (ipa_simd_modify_function_body): Likewise.
35435
35436 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
35437 Alan Hayward <alan.hayward@arm.com>
35438 David Sherwood <david.sherwood@arm.com>
35439
35440 * tree-vect-generic.c (nunits_for_known_piecewise_op): New function.
35441 (expand_vector_piecewise): Use it instead of TYPE_VECTOR_SUBPARTS.
35442 (expand_vector_addition, add_rshift, expand_vector_divmod): Likewise.
35443 (expand_vector_condition, vector_element): Likewise.
35444 (subparts_gt): New function.
35445 (get_compute_type): Use subparts_gt.
35446 (count_type_subparts): Delete.
35447 (expand_vector_operations_1): Use subparts_gt instead of
35448 count_type_subparts.
35449
35450 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
35451 Alan Hayward <alan.hayward@arm.com>
35452 David Sherwood <david.sherwood@arm.com>
35453
35454 * tree-vect-data-refs.c (vect_no_alias_p): Replace with...
35455 (vect_compile_time_alias): ...this new function. Do the calculation
35456 on poly_ints rather than trees.
35457 (vect_prune_runtime_alias_test_list): Update call accordingly.
35458
35459 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
35460 Alan Hayward <alan.hayward@arm.com>
35461 David Sherwood <david.sherwood@arm.com>
35462
35463 * tree-vect-slp.c (vect_build_slp_tree_1): Handle polynomial
35464 numbers of units.
35465 (vect_schedule_slp_instance): Likewise.
35466
35467 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
35468 Alan Hayward <alan.hayward@arm.com>
35469 David Sherwood <david.sherwood@arm.com>
35470
35471 * tree-vect-slp.c (vect_get_and_check_slp_defs): Reject
35472 constant and extern definitions for variable-length vectors.
35473 (vect_get_constant_vectors): Note that the number of units
35474 is known to be constant.
35475
35476 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
35477 Alan Hayward <alan.hayward@arm.com>
35478 David Sherwood <david.sherwood@arm.com>
35479
35480 * tree-vect-stmts.c (vectorizable_conversion): Treat the number
35481 of units as polynomial. Choose between WIDE and NARROW based
35482 on multiple_p.
35483
35484 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
35485 Alan Hayward <alan.hayward@arm.com>
35486 David Sherwood <david.sherwood@arm.com>
35487
35488 * tree-vect-stmts.c (simd_clone_subparts): New function.
35489 (vectorizable_simd_clone_call): Use it instead of TYPE_VECTOR_SUBPARTS.
35490
35491 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
35492 Alan Hayward <alan.hayward@arm.com>
35493 David Sherwood <david.sherwood@arm.com>
35494
35495 * tree-vect-stmts.c (vectorizable_call): Treat the number of
35496 vectors as polynomial. Use build_index_vector for
35497 IFN_GOMP_SIMD_LANE.
35498
35499 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
35500 Alan Hayward <alan.hayward@arm.com>
35501 David Sherwood <david.sherwood@arm.com>
35502
35503 * tree-vect-stmts.c (get_load_store_type): Treat the number of
35504 units as polynomial. Reject VMAT_ELEMENTWISE and VMAT_STRIDED_SLP
35505 for variable-length vectors.
35506 (vectorizable_mask_load_store): Treat the number of units as
35507 polynomial, asserting that it is constant if the condition has
35508 already been enforced.
35509 (vectorizable_store, vectorizable_load): Likewise.
35510
35511 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
35512 Alan Hayward <alan.hayward@arm.com>
35513 David Sherwood <david.sherwood@arm.com>
35514
35515 * tree-vect-loop.c (vectorizable_live_operation): Treat the number
35516 of units as polynomial. Punt if we can't tell at compile time
35517 which vector contains the final result.
35518
35519 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
35520 Alan Hayward <alan.hayward@arm.com>
35521 David Sherwood <david.sherwood@arm.com>
35522
35523 * tree-vect-loop.c (vectorizable_induction): Treat the number
35524 of units as polynomial. Punt on SLP inductions. Use an integer
35525 VEC_SERIES_EXPR for variable-length integer reductions. Use a
35526 cast of such a series for variable-length floating-point
35527 reductions.
35528
35529 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
35530 Alan Hayward <alan.hayward@arm.com>
35531 David Sherwood <david.sherwood@arm.com>
35532
35533 * tree.h (build_index_vector): Declare.
35534 * tree.c (build_index_vector): New function.
35535 * tree-vect-loop.c (get_initial_defs_for_reduction): Treat the number
35536 of units as polynomial, forcibly converting it to a constant if
35537 vectorizable_reduction has already enforced the condition.
35538 (vect_create_epilog_for_reduction): Likewise. Use build_index_vector
35539 to create a {1,2,3,...} vector.
35540 (vectorizable_reduction): Treat the number of units as polynomial.
35541 Choose vectype_in based on the largest scalar element size rather
35542 than the smallest number of units. Enforce the restrictions
35543 relied on above.
35544
35545 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
35546 Alan Hayward <alan.hayward@arm.com>
35547 David Sherwood <david.sherwood@arm.com>
35548
35549 * tree-vect-data-refs.c (vector_alignment_reachable_p): Treat the
35550 number of units as polynomial.
35551
35552 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
35553 Alan Hayward <alan.hayward@arm.com>
35554 David Sherwood <david.sherwood@arm.com>
35555
35556 * target.h (vector_sizes, auto_vector_sizes): New typedefs.
35557 * target.def (autovectorize_vector_sizes): Return the vector sizes
35558 by pointer, using vector_sizes rather than a bitmask.
35559 * targhooks.h (default_autovectorize_vector_sizes): Update accordingly.
35560 * targhooks.c (default_autovectorize_vector_sizes): Likewise.
35561 * config/aarch64/aarch64.c (aarch64_autovectorize_vector_sizes):
35562 Likewise.
35563 * config/arc/arc.c (arc_autovectorize_vector_sizes): Likewise.
35564 * config/arm/arm.c (arm_autovectorize_vector_sizes): Likewise.
35565 * config/i386/i386.c (ix86_autovectorize_vector_sizes): Likewise.
35566 * config/mips/mips.c (mips_autovectorize_vector_sizes): Likewise.
35567 * omp-general.c (omp_max_vf): Likewise.
35568 * omp-low.c (omp_clause_aligned_alignment): Likewise.
35569 * optabs-query.c (can_vec_mask_load_store_p): Likewise.
35570 * tree-vect-loop.c (vect_analyze_loop): Likewise.
35571 * tree-vect-slp.c (vect_slp_bb): Likewise.
35572 * doc/tm.texi: Regenerate.
35573 * tree-vectorizer.h (current_vector_size): Change from an unsigned int
35574 to a poly_uint64.
35575 * tree-vect-stmts.c (get_vectype_for_scalar_type_and_size): Take
35576 the vector size as a poly_uint64 rather than an unsigned int.
35577 (current_vector_size): Change from an unsigned int to a poly_uint64.
35578 (get_vectype_for_scalar_type): Update accordingly.
35579 * tree.h (build_truth_vector_type): Take the size and number of
35580 units as a poly_uint64 rather than an unsigned int.
35581 (build_vector_type): Add a temporary overload that takes
35582 the number of units as a poly_uint64 rather than an unsigned int.
35583 * tree.c (make_vector_type): Likewise.
35584 (build_truth_vector_type): Take the number of units as a poly_uint64
35585 rather than an unsigned int.
35586
35587 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
35588 Alan Hayward <alan.hayward@arm.com>
35589 David Sherwood <david.sherwood@arm.com>
35590
35591 * target.def (get_mask_mode): Take the number of units and length
35592 as poly_uint64s rather than unsigned ints.
35593 * targhooks.h (default_get_mask_mode): Update accordingly.
35594 * targhooks.c (default_get_mask_mode): Likewise.
35595 * config/i386/i386.c (ix86_get_mask_mode): Likewise.
35596 * doc/tm.texi: Regenerate.
35597
35598 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
35599 Alan Hayward <alan.hayward@arm.com>
35600 David Sherwood <david.sherwood@arm.com>
35601
35602 * omp-general.h (omp_max_vf): Return a poly_uint64 instead of an int.
35603 * omp-general.c (omp_max_vf): Likewise.
35604 * omp-expand.c (omp_adjust_chunk_size): Update call to omp_max_vf.
35605 (expand_omp_simd): Handle polynomial safelen.
35606 * omp-low.c (omplow_simd_context): Add a default constructor.
35607 (omplow_simd_context::max_vf): Change from int to poly_uint64.
35608 (lower_rec_simd_input_clauses): Update accordingly.
35609 (lower_rec_input_clauses): Likewise.
35610
35611 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
35612 Alan Hayward <alan.hayward@arm.com>
35613 David Sherwood <david.sherwood@arm.com>
35614
35615 * tree-vectorizer.h (vect_nunits_for_cost): New function.
35616 * tree-vect-loop.c (vect_model_reduction_cost): Use it.
35617 * tree-vect-slp.c (vect_analyze_slp_cost_1): Likewise.
35618 (vect_analyze_slp_cost): Likewise.
35619 * tree-vect-stmts.c (vect_model_store_cost): Likewise.
35620 (vect_model_load_cost): Likewise.
35621
35622 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
35623 Alan Hayward <alan.hayward@arm.com>
35624 David Sherwood <david.sherwood@arm.com>
35625
35626 * tree-vect-slp.c (vect_record_max_nunits, vect_build_slp_tree_1)
35627 (vect_build_slp_tree_2, vect_build_slp_tree): Change max_nunits
35628 from an unsigned int * to a poly_uint64_pod *.
35629 (calculate_unrolling_factor): New function.
35630 (vect_analyze_slp_instance): Use it. Track polynomial max_nunits.
35631
35632 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
35633 Alan Hayward <alan.hayward@arm.com>
35634 David Sherwood <david.sherwood@arm.com>
35635
35636 * tree-vectorizer.h (_slp_instance::unrolling_factor): Change
35637 from an unsigned int to a poly_uint64.
35638 (_loop_vec_info::slp_unrolling_factor): Likewise.
35639 (_loop_vec_info::vectorization_factor): Change from an int
35640 to a poly_uint64.
35641 (MAX_VECTORIZATION_FACTOR): Bump from 64 to INT_MAX.
35642 (vect_get_num_vectors): New function.
35643 (vect_update_max_nunits, vect_vf_for_cost): Likewise.
35644 (vect_get_num_copies): Use vect_get_num_vectors.
35645 (vect_analyze_data_ref_dependences): Change max_vf from an int *
35646 to an unsigned int *.
35647 (vect_analyze_data_refs): Change min_vf from an int * to a
35648 poly_uint64 *.
35649 (vect_transform_slp_perm_load): Take the vf as a poly_uint64 rather
35650 than an unsigned HOST_WIDE_INT.
35651 * tree-vect-data-refs.c (vect_analyze_possibly_independent_ddr)
35652 (vect_analyze_data_ref_dependence): Change max_vf from an int *
35653 to an unsigned int *.
35654 (vect_analyze_data_ref_dependences): Likewise.
35655 (vect_compute_data_ref_alignment): Handle polynomial vf.
35656 (vect_enhance_data_refs_alignment): Likewise.
35657 (vect_prune_runtime_alias_test_list): Likewise.
35658 (vect_shift_permute_load_chain): Likewise.
35659 (vect_supportable_dr_alignment): Likewise.
35660 (dependence_distance_ge_vf): Take the vectorization factor as a
35661 poly_uint64 rather than an unsigned HOST_WIDE_INT.
35662 (vect_analyze_data_refs): Change min_vf from an int * to a
35663 poly_uint64 *.
35664 * tree-vect-loop-manip.c (vect_gen_scalar_loop_niters): Take
35665 vfm1 as a poly_uint64 rather than an int. Make the same change
35666 for the returned bound_scalar.
35667 (vect_gen_vector_loop_niters): Handle polynomial vf.
35668 (vect_do_peeling): Likewise. Update call to
35669 vect_gen_scalar_loop_niters and handle polynomial bound_scalars.
35670 (vect_gen_vector_loop_niters_mult_vf): Assert that the vf must
35671 be constant.
35672 * tree-vect-loop.c (vect_determine_vectorization_factor)
35673 (vect_update_vf_for_slp, vect_analyze_loop_2): Handle polynomial vf.
35674 (vect_get_known_peeling_cost): Likewise.
35675 (vect_estimate_min_profitable_iters, vectorizable_reduction): Likewise.
35676 (vect_worthwhile_without_simd_p, vectorizable_induction): Likewise.
35677 (vect_transform_loop): Likewise. Use the lowest possible VF when
35678 updating the upper bounds of the loop.
35679 (vect_min_worthwhile_factor): Make static. Return an unsigned int
35680 rather than an int.
35681 * tree-vect-slp.c (vect_attempt_slp_rearrange_stmts): Cope with
35682 polynomial unroll factors.
35683 (vect_analyze_slp_cost_1, vect_analyze_slp_instance): Likewise.
35684 (vect_make_slp_decision): Likewise.
35685 (vect_supported_load_permutation_p): Likewise, and polynomial
35686 vf too.
35687 (vect_analyze_slp_cost): Handle polynomial vf.
35688 (vect_slp_analyze_node_operations): Likewise.
35689 (vect_slp_analyze_bb_1): Likewise.
35690 (vect_transform_slp_perm_load): Take the vf as a poly_uint64 rather
35691 than an unsigned HOST_WIDE_INT.
35692 * tree-vect-stmts.c (vectorizable_simd_clone_call, vectorizable_store)
35693 (vectorizable_load): Handle polynomial vf.
35694 * tree-vectorizer.c (simduid_to_vf::vf): Change from an int to
35695 a poly_uint64.
35696 (adjust_simduid_builtins, shrink_simd_arrays): Update accordingly.
35697
35698 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
35699 Alan Hayward <alan.hayward@arm.com>
35700 David Sherwood <david.sherwood@arm.com>
35701
35702 * match.pd: Handle bit operations involving three constants
35703 and try to fold one pair.
35704
35705 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
35706
35707 * tree-vect-loop-manip.c: Include gimple-fold.h.
35708 (slpeel_make_loop_iterate_ntimes): Add step, final_iv and
35709 niters_maybe_zero parameters. Handle other cases besides a step of 1.
35710 (vect_gen_vector_loop_niters): Add a step_vector_ptr parameter.
35711 Add a path that uses a step of VF instead of 1, but disable it
35712 for now.
35713 (vect_do_peeling): Add step_vector, niters_vector_mult_vf_var
35714 and niters_no_overflow parameters. Update calls to
35715 slpeel_make_loop_iterate_ntimes and vect_gen_vector_loop_niters.
35716 Create a new SSA name if the latter choses to use a ste other
35717 than zero, and return it via niters_vector_mult_vf_var.
35718 * tree-vect-loop.c (vect_transform_loop): Update calls to
35719 vect_do_peeling, vect_gen_vector_loop_niters and
35720 slpeel_make_loop_iterate_ntimes.
35721 * tree-vectorizer.h (slpeel_make_loop_iterate_ntimes, vect_do_peeling)
35722 (vect_gen_vector_loop_niters): Update declarations after above changes.
35723
35724 2018-01-02 Michael Meissner <meissner@linux.vnet.ibm.com>
35725
35726 * config/rs6000/rs6000.md (floor<mode>2): Add support for IEEE
35727 128-bit round to integer instructions.
35728 (ceil<mode>2): Likewise.
35729 (btrunc<mode>2): Likewise.
35730 (round<mode>2): Likewise.
35731
35732 2018-01-02 Aaron Sawdey <acsawdey@linux.vnet.ibm.com>
35733
35734 * config/rs6000/rs6000-string.c (expand_block_move): Allow the use of
35735 unaligned VSX load/store on P8/P9.
35736 (expand_block_clear): Allow the use of unaligned VSX
35737 load/store on P8/P9.
35738
35739 2018-01-02 Bill Schmidt <wschmidt@linux.vnet.ibm.com>
35740
35741 * config/rs6000/rs6000-p8swap.c (swap_feeds_both_load_and_store):
35742 New function.
35743 (rs6000_analyze_swaps): Mark a web unoptimizable if it contains a
35744 swap associated with both a load and a store.
35745
35746 2018-01-02 Andrew Waterman <andrew@sifive.com>
35747
35748 * config/riscv/linux.h (ICACHE_FLUSH_FUNC): New.
35749 * config/riscv/riscv.md (clear_cache): Use it.
35750
35751 2018-01-02 Artyom Skrobov <tyomitch@gmail.com>
35752
35753 * web.c: Remove out-of-date comment.
35754
35755 2018-01-02 Richard Sandiford <richard.sandiford@linaro.org>
35756
35757 * expr.c (fixup_args_size_notes): Check that any existing
35758 REG_ARGS_SIZE notes are correct, and don't try to re-add them.
35759 (emit_single_push_insn_1): Move stack_pointer_delta adjustment to...
35760 (emit_single_push_insn): ...here.
35761
35762 2018-01-02 Richard Sandiford <richard.sandiford@linaro.org>
35763
35764 * rtl.h (CONST_VECTOR_ELT): Redefine to const_vector_elt.
35765 (const_vector_encoded_nelts): New function.
35766 (CONST_VECTOR_NUNITS): Redefine to use GET_MODE_NUNITS.
35767 (const_vector_int_elt, const_vector_elt): Declare.
35768 * emit-rtl.c (const_vector_int_elt_1): New function.
35769 (const_vector_elt): Likewise.
35770 * simplify-rtx.c (simplify_immed_subreg): Avoid taking the address
35771 of CONST_VECTOR_ELT.
35772
35773 2018-01-02 Richard Sandiford <richard.sandiford@linaro.org>
35774
35775 * expr.c: Include rtx-vector-builder.h.
35776 (const_vector_mask_from_tree): Use rtx_vector_builder and operate
35777 directly on the tree encoding.
35778 (const_vector_from_tree): Likewise.
35779 * optabs.c: Include rtx-vector-builder.h.
35780 (expand_vec_perm_var): Use rtx_vector_builder and create a repeating
35781 sequence of "u" values.
35782 * vec-perm-indices.c: Include rtx-vector-builder.h.
35783 (vec_perm_indices_to_rtx): Use rtx_vector_builder and operate
35784 directly on the vec_perm_indices encoding.
35785
35786 2018-01-02 Richard Sandiford <richard.sandiford@linaro.org>
35787
35788 * doc/rtl.texi (const_vector): Describe new encoding scheme.
35789 * Makefile.in (OBJS): Add rtx-vector-builder.o.
35790 * rtx-vector-builder.h: New file.
35791 * rtx-vector-builder.c: Likewise.
35792 * rtl.h (rtx_def::u2): Add a const_vector field.
35793 (CONST_VECTOR_NPATTERNS): New macro.
35794 (CONST_VECTOR_NELTS_PER_PATTERN): Likewise.
35795 (CONST_VECTOR_DUPLICATE_P): Likewise.
35796 (CONST_VECTOR_STEPPED_P): Likewise.
35797 (CONST_VECTOR_ENCODED_ELT): Likewise.
35798 (const_vec_duplicate_p): Check for a duplicated vector encoding.
35799 (unwrap_const_vec_duplicate): Likewise.
35800 (const_vec_series_p): Check for a non-duplicated vector encoding.
35801 Say that the function only returns true for integer vectors.
35802 * emit-rtl.c: Include rtx-vector-builder.h.
35803 (gen_const_vec_duplicate_1): Delete.
35804 (gen_const_vector): Call gen_const_vec_duplicate instead of
35805 gen_const_vec_duplicate_1.
35806 (const_vec_series_p_1): Operate directly on the CONST_VECTOR encoding.
35807 (gen_const_vec_duplicate): Use rtx_vector_builder.
35808 (gen_const_vec_series): Likewise.
35809 (gen_rtx_CONST_VECTOR): Likewise.
35810 * config/powerpcspe/powerpcspe.c: Include rtx-vector-builder.h.
35811 (swap_const_vector_halves): Take an rtx pointer rather than rtx.
35812 Build a new vector rather than modifying a CONST_VECTOR in-place.
35813 (handle_special_swappables): Update call accordingly.
35814 * config/rs6000/rs6000-p8swap.c: Include rtx-vector-builder.h.
35815 (swap_const_vector_halves): Take an rtx pointer rather than rtx.
35816 Build a new vector rather than modifying a CONST_VECTOR in-place.
35817 (handle_special_swappables): Update call accordingly.
35818
35819 2018-01-02 Richard Sandiford <richard.sandiford@linaro.org>
35820
35821 * simplify-rtx.c (simplify_const_binary_operation): Use
35822 CONST_VECTOR_ELT instead of XVECEXP.
35823
35824 2018-01-02 Richard Sandiford <richard.sandiford@linaro.org>
35825
35826 * tree-cfg.c (verify_gimple_assign_ternary): Allow the size of
35827 the selector elements to be different from the data elements
35828 if the selector is a VECTOR_CST.
35829 * tree-vect-stmts.c (vect_gen_perm_mask_any): Use a vector of
35830 ssizetype for the selector.
35831
35832 2018-01-02 Richard Sandiford <richard.sandiford@linaro.org>
35833
35834 * optabs.c (shift_amt_for_vec_perm_mask): Try using series_p
35835 before testing each element individually.
35836 * tree-vect-generic.c (lower_vec_perm): Likewise.
35837
35838 2018-01-02 Richard Sandiford <richard.sandiford@linaro.org>
35839
35840 * selftest.h (selftest::vec_perm_indices_c_tests): Declare.
35841 * selftest-run-tests.c (selftest::run_tests): Call it.
35842 * vector-builder.h (vector_builder::operator ==): New function.
35843 (vector_builder::operator !=): Likewise.
35844 * vec-perm-indices.h (vec_perm_indices::series_p): Declare.
35845 (vec_perm_indices::all_from_input_p): New function.
35846 * vec-perm-indices.c (vec_perm_indices::series_p): Likewise.
35847 (test_vec_perm_12, selftest::vec_perm_indices_c_tests): Likewise.
35848 * fold-const.c (fold_ternary_loc): Use tree_to_vec_perm_builder
35849 instead of reading the VECTOR_CST directly. Detect whether both
35850 vector inputs are the same before constructing the vec_perm_indices,
35851 and update the number of inputs argument accordingly. Use the
35852 utility functions added above. Only construct sel2 if we need to.
35853
35854 2018-01-02 Richard Sandiford <richard.sandiford@linaro.org>
35855
35856 * optabs.c (expand_vec_perm_var): Use an explicit encoding for
35857 the broadcast of the low byte.
35858 (expand_mult_highpart): Use an explicit encoding for the permutes.
35859 * optabs-query.c (can_mult_highpart_p): Likewise.
35860 * tree-vect-loop.c (calc_vec_perm_mask_for_shift): Likewise.
35861 * tree-vect-stmts.c (perm_mask_for_reverse): Likewise.
35862 (vectorizable_bswap): Likewise.
35863 * tree-vect-data-refs.c (vect_grouped_store_supported): Use an
35864 explicit encoding for the power-of-2 permutes.
35865 (vect_permute_store_chain): Likewise.
35866 (vect_grouped_load_supported): Likewise.
35867 (vect_permute_load_chain): Likewise.
35868
35869 2018-01-02 Richard Sandiford <richard.sandiford@linaro.org>
35870
35871 * vec-perm-indices.h (vec_perm_indices_to_tree): Declare.
35872 * vec-perm-indices.c (vec_perm_indices_to_tree): New function.
35873 * tree-ssa-forwprop.c (simplify_vector_constructor): Use it.
35874 * tree-vect-slp.c (vect_transform_slp_perm_load): Likewise.
35875 * tree-vect-stmts.c (vectorizable_bswap): Likewise.
35876 (vect_gen_perm_mask_any): Likewise.
35877
35878 2018-01-02 Richard Sandiford <richard.sandiford@linaro.org>
35879
35880 * int-vector-builder.h: New file.
35881 * vec-perm-indices.h: Include int-vector-builder.h.
35882 (vec_perm_indices): Redefine as an int_vector_builder.
35883 (auto_vec_perm_indices): Delete.
35884 (vec_perm_builder): Redefine as a stand-alone class.
35885 (vec_perm_indices::vec_perm_indices): New function.
35886 (vec_perm_indices::clamp): Likewise.
35887 * vec-perm-indices.c: Include fold-const.h and tree-vector-builder.h.
35888 (vec_perm_indices::new_vector): New function.
35889 (vec_perm_indices::new_expanded_vector): Update for new
35890 vec_perm_indices class.
35891 (vec_perm_indices::rotate_inputs): New function.
35892 (vec_perm_indices::all_in_range_p): Operate directly on the
35893 encoded form, without computing elided elements.
35894 (tree_to_vec_perm_builder): Operate directly on the VECTOR_CST
35895 encoding. Update for new vec_perm_indices class.
35896 * optabs.c (expand_vec_perm_const): Create a vec_perm_indices for
35897 the given vec_perm_builder.
35898 (expand_vec_perm_var): Update vec_perm_builder constructor.
35899 (expand_mult_highpart): Use vec_perm_builder instead of
35900 auto_vec_perm_indices.
35901 * optabs-query.c (can_mult_highpart_p): Use vec_perm_builder and
35902 vec_perm_indices instead of auto_vec_perm_indices. Use a single
35903 or double series encoding as appropriate.
35904 * fold-const.c (fold_ternary_loc): Use vec_perm_builder and
35905 vec_perm_indices instead of auto_vec_perm_indices.
35906 * tree-ssa-forwprop.c (simplify_vector_constructor): Likewise.
35907 * tree-vect-data-refs.c (vect_grouped_store_supported): Likewise.
35908 (vect_permute_store_chain): Likewise.
35909 (vect_grouped_load_supported): Likewise.
35910 (vect_permute_load_chain): Likewise.
35911 (vect_shift_permute_load_chain): Likewise.
35912 * tree-vect-slp.c (vect_build_slp_tree_1): Likewise.
35913 (vect_transform_slp_perm_load): Likewise.
35914 (vect_schedule_slp_instance): Likewise.
35915 * tree-vect-stmts.c (perm_mask_for_reverse): Likewise.
35916 (vectorizable_mask_load_store): Likewise.
35917 (vectorizable_bswap): Likewise.
35918 (vectorizable_store): Likewise.
35919 (vectorizable_load): Likewise.
35920 * tree-vect-generic.c (lower_vec_perm): Use vec_perm_builder and
35921 vec_perm_indices instead of auto_vec_perm_indices. Use
35922 tree_to_vec_perm_builder to read the vector from a tree.
35923 * tree-vect-loop.c (calc_vec_perm_mask_for_shift): Take a
35924 vec_perm_builder instead of a vec_perm_indices.
35925 (have_whole_vector_shift): Use vec_perm_builder and
35926 vec_perm_indices instead of auto_vec_perm_indices. Leave the
35927 truncation to calc_vec_perm_mask_for_shift.
35928 (vect_create_epilog_for_reduction): Likewise.
35929 * config/aarch64/aarch64.c (expand_vec_perm_d::perm): Change
35930 from auto_vec_perm_indices to vec_perm_indices.
35931 (aarch64_expand_vec_perm_const_1): Use rotate_inputs on d.perm
35932 instead of changing individual elements.
35933 (aarch64_vectorize_vec_perm_const): Use new_vector to install
35934 the vector in d.perm.
35935 * config/arm/arm.c (expand_vec_perm_d::perm): Change
35936 from auto_vec_perm_indices to vec_perm_indices.
35937 (arm_expand_vec_perm_const_1): Use rotate_inputs on d.perm
35938 instead of changing individual elements.
35939 (arm_vectorize_vec_perm_const): Use new_vector to install
35940 the vector in d.perm.
35941 * config/powerpcspe/powerpcspe.c (rs6000_expand_extract_even):
35942 Update vec_perm_builder constructor.
35943 (rs6000_expand_interleave): Likewise.
35944 * config/rs6000/rs6000.c (rs6000_expand_extract_even): Likewise.
35945 (rs6000_expand_interleave): Likewise.
35946
35947 2018-01-02 Richard Sandiford <richard.sandiford@linaro.org>
35948
35949 * optabs-query.c (can_vec_perm_var_p): Check whether lowering
35950 to qimode could truncate the indices.
35951 * optabs.c (expand_vec_perm_var): Likewise.
35952
35953 2018-01-02 Richard Sandiford <richard.sandiford@linaro.org>
35954
35955 * Makefile.in (OBJS): Add vec-perm-indices.o.
35956 * vec-perm-indices.h: New file.
35957 * vec-perm-indices.c: Likewise.
35958 * target.h (vec_perm_indices): Replace with a forward class
35959 declaration.
35960 (auto_vec_perm_indices): Move to vec-perm-indices.h.
35961 * optabs.h: Include vec-perm-indices.h.
35962 (expand_vec_perm): Delete.
35963 (selector_fits_mode_p, expand_vec_perm_var): Declare.
35964 (expand_vec_perm_const): Declare.
35965 * target.def (vec_perm_const_ok): Replace with...
35966 (vec_perm_const): ...this new hook.
35967 * doc/tm.texi.in (TARGET_VECTORIZE_VEC_PERM_CONST_OK): Replace with...
35968 (TARGET_VECTORIZE_VEC_PERM_CONST): ...this new hook.
35969 * doc/tm.texi: Regenerate.
35970 * optabs.def (vec_perm_const): Delete.
35971 * doc/md.texi (vec_perm_const): Likewise.
35972 (vec_perm): Refer to TARGET_VECTORIZE_VEC_PERM_CONST.
35973 * expr.c (expand_expr_real_2): Use expand_vec_perm_const rather than
35974 expand_vec_perm for constant permutation vectors. Assert that
35975 the mode of variable permutation vectors is the integer equivalent
35976 of the mode that is being permuted.
35977 * optabs-query.h (selector_fits_mode_p): Declare.
35978 * optabs-query.c: Include vec-perm-indices.h.
35979 (selector_fits_mode_p): New function.
35980 (can_vec_perm_const_p): Check whether targetm.vectorize.vec_perm_const
35981 is defined, instead of checking whether the vec_perm_const_optab
35982 exists. Use targetm.vectorize.vec_perm_const instead of
35983 targetm.vectorize.vec_perm_const_ok. Check whether the indices
35984 fit in the vector mode before using a variable permute.
35985 * optabs.c (shift_amt_for_vec_perm_mask): Take a mode and a
35986 vec_perm_indices instead of an rtx.
35987 (expand_vec_perm): Replace with...
35988 (expand_vec_perm_const): ...this new function. Take the selector
35989 as a vec_perm_indices rather than an rtx. Also take the mode of
35990 the selector. Update call to shift_amt_for_vec_perm_mask.
35991 Use targetm.vectorize.vec_perm_const instead of vec_perm_const_optab.
35992 Use vec_perm_indices::new_expanded_vector to expand the original
35993 selector into bytes. Check whether the indices fit in the vector
35994 mode before using a variable permute.
35995 (expand_vec_perm_var): Make global.
35996 (expand_mult_highpart): Use expand_vec_perm_const.
35997 * fold-const.c: Includes vec-perm-indices.h.
35998 * tree-ssa-forwprop.c: Likewise.
35999 * tree-vect-data-refs.c: Likewise.
36000 * tree-vect-generic.c: Likewise.
36001 * tree-vect-loop.c: Likewise.
36002 * tree-vect-slp.c: Likewise.
36003 * tree-vect-stmts.c: Likewise.
36004 * config/aarch64/aarch64-protos.h (aarch64_expand_vec_perm_const):
36005 Delete.
36006 * config/aarch64/aarch64-simd.md (vec_perm_const<mode>): Delete.
36007 * config/aarch64/aarch64.c (aarch64_expand_vec_perm_const)
36008 (aarch64_vectorize_vec_perm_const_ok): Fuse into...
36009 (aarch64_vectorize_vec_perm_const): ...this new function.
36010 (TARGET_VECTORIZE_VEC_PERM_CONST_OK): Delete.
36011 (TARGET_VECTORIZE_VEC_PERM_CONST): Redefine.
36012 * config/arm/arm-protos.h (arm_expand_vec_perm_const): Delete.
36013 * config/arm/vec-common.md (vec_perm_const<mode>): Delete.
36014 * config/arm/arm.c (TARGET_VECTORIZE_VEC_PERM_CONST_OK): Delete.
36015 (TARGET_VECTORIZE_VEC_PERM_CONST): Redefine.
36016 (arm_expand_vec_perm_const, arm_vectorize_vec_perm_const_ok): Merge
36017 into...
36018 (arm_vectorize_vec_perm_const): ...this new function. Explicitly
36019 check for NEON modes.
36020 * config/i386/i386-protos.h (ix86_expand_vec_perm_const): Delete.
36021 * config/i386/sse.md (VEC_PERM_CONST, vec_perm_const<mode>): Delete.
36022 * config/i386/i386.c (ix86_expand_vec_perm_const_1): Update comment.
36023 (ix86_expand_vec_perm_const, ix86_vectorize_vec_perm_const_ok): Merge
36024 into...
36025 (ix86_vectorize_vec_perm_const): ...this new function. Incorporate
36026 the old VEC_PERM_CONST conditions.
36027 * config/ia64/ia64-protos.h (ia64_expand_vec_perm_const): Delete.
36028 * config/ia64/vect.md (vec_perm_const<mode>): Delete.
36029 * config/ia64/ia64.c (ia64_expand_vec_perm_const)
36030 (ia64_vectorize_vec_perm_const_ok): Merge into...
36031 (ia64_vectorize_vec_perm_const): ...this new function.
36032 * config/mips/loongson.md (vec_perm_const<mode>): Delete.
36033 * config/mips/mips-msa.md (vec_perm_const<mode>): Delete.
36034 * config/mips/mips-ps-3d.md (vec_perm_constv2sf): Delete.
36035 * config/mips/mips-protos.h (mips_expand_vec_perm_const): Delete.
36036 * config/mips/mips.c (mips_expand_vec_perm_const)
36037 (mips_vectorize_vec_perm_const_ok): Merge into...
36038 (mips_vectorize_vec_perm_const): ...this new function.
36039 * config/powerpcspe/altivec.md (vec_perm_constv16qi): Delete.
36040 * config/powerpcspe/paired.md (vec_perm_constv2sf): Delete.
36041 * config/powerpcspe/spe.md (vec_perm_constv2si): Delete.
36042 * config/powerpcspe/vsx.md (vec_perm_const<mode>): Delete.
36043 * config/powerpcspe/powerpcspe-protos.h (altivec_expand_vec_perm_const)
36044 (rs6000_expand_vec_perm_const): Delete.
36045 * config/powerpcspe/powerpcspe.c (TARGET_VECTORIZE_VEC_PERM_CONST_OK):
36046 Delete.
36047 (TARGET_VECTORIZE_VEC_PERM_CONST): Redefine.
36048 (altivec_expand_vec_perm_const_le): Take each operand individually.
36049 Operate on constant selectors rather than rtxes.
36050 (altivec_expand_vec_perm_const): Likewise. Update call to
36051 altivec_expand_vec_perm_const_le.
36052 (rs6000_expand_vec_perm_const): Delete.
36053 (rs6000_vectorize_vec_perm_const_ok): Delete.
36054 (rs6000_vectorize_vec_perm_const): New function.
36055 (rs6000_do_expand_vec_perm): Take a vec_perm_builder instead of
36056 an element count and rtx array.
36057 (rs6000_expand_extract_even): Update call accordingly.
36058 (rs6000_expand_interleave): Likewise.
36059 * config/rs6000/altivec.md (vec_perm_constv16qi): Delete.
36060 * config/rs6000/paired.md (vec_perm_constv2sf): Delete.
36061 * config/rs6000/vsx.md (vec_perm_const<mode>): Delete.
36062 * config/rs6000/rs6000-protos.h (altivec_expand_vec_perm_const)
36063 (rs6000_expand_vec_perm_const): Delete.
36064 * config/rs6000/rs6000.c (TARGET_VECTORIZE_VEC_PERM_CONST_OK): Delete.
36065 (TARGET_VECTORIZE_VEC_PERM_CONST): Redefine.
36066 (altivec_expand_vec_perm_const_le): Take each operand individually.
36067 Operate on constant selectors rather than rtxes.
36068 (altivec_expand_vec_perm_const): Likewise. Update call to
36069 altivec_expand_vec_perm_const_le.
36070 (rs6000_expand_vec_perm_const): Delete.
36071 (rs6000_vectorize_vec_perm_const_ok): Delete.
36072 (rs6000_vectorize_vec_perm_const): New function. Remove stray
36073 reference to the SPE evmerge intructions.
36074 (rs6000_do_expand_vec_perm): Take a vec_perm_builder instead of
36075 an element count and rtx array.
36076 (rs6000_expand_extract_even): Update call accordingly.
36077 (rs6000_expand_interleave): Likewise.
36078 * config/sparc/sparc.md (vec_perm_constv8qi): Delete in favor of...
36079 * config/sparc/sparc.c (sparc_vectorize_vec_perm_const): ...this
36080 new function.
36081 (TARGET_VECTORIZE_VEC_PERM_CONST): Redefine.
36082
36083 2018-01-02 Richard Sandiford <richard.sandiford@linaro.org>
36084
36085 * optabs.c (expand_vec_perm_1): Assert that SEL has an integer
36086 vector mode and that that mode matches the mode of the data
36087 being permuted.
36088 (expand_vec_perm): Split handling of non-CONST_VECTOR selectors
36089 out into expand_vec_perm_var. Do all CONST_VECTOR handling here,
36090 directly using expand_vec_perm_1 when forcing selectors into
36091 registers.
36092 (expand_vec_perm_var): New function, split out from expand_vec_perm.
36093
36094 2018-01-02 Richard Sandiford <richard.sandiford@linaro.org>
36095
36096 * optabs-query.h (can_vec_perm_p): Delete.
36097 (can_vec_perm_var_p, can_vec_perm_const_p): Declare.
36098 * optabs-query.c (can_vec_perm_p): Split into...
36099 (can_vec_perm_var_p, can_vec_perm_const_p): ...these two functions.
36100 (can_mult_highpart_p): Use can_vec_perm_const_p to test whether a
36101 particular selector is valid.
36102 * tree-ssa-forwprop.c (simplify_vector_constructor): Likewise.
36103 * tree-vect-data-refs.c (vect_grouped_store_supported): Likewise.
36104 (vect_grouped_load_supported): Likewise.
36105 (vect_shift_permute_load_chain): Likewise.
36106 * tree-vect-slp.c (vect_build_slp_tree_1): Likewise.
36107 (vect_transform_slp_perm_load): Likewise.
36108 * tree-vect-stmts.c (perm_mask_for_reverse): Likewise.
36109 (vectorizable_bswap): Likewise.
36110 (vect_gen_perm_mask_checked): Likewise.
36111 * fold-const.c (fold_ternary_loc): Likewise. Don't take
36112 implementations of variable permutation vectors into account
36113 when deciding which selector to use.
36114 * tree-vect-loop.c (have_whole_vector_shift): Don't check whether
36115 vec_perm_const_optab is supported; instead use can_vec_perm_const_p
36116 with a false third argument.
36117 * tree-vect-generic.c (lower_vec_perm): Use can_vec_perm_const_p
36118 to test whether the constant selector is valid and can_vec_perm_var_p
36119 to test whether a variable selector is valid.
36120
36121 2018-01-02 Richard Sandiford <richard.sandiford@linaro.org>
36122
36123 * optabs-query.h (can_vec_perm_p): Take a const vec_perm_indices *.
36124 * optabs-query.c (can_vec_perm_p): Likewise.
36125 * fold-const.c (fold_vec_perm): Take a const vec_perm_indices &
36126 instead of vec_perm_indices.
36127 * tree-vectorizer.h (vect_gen_perm_mask_any): Likewise,
36128 (vect_gen_perm_mask_checked): Likewise,
36129 * tree-vect-stmts.c (vect_gen_perm_mask_any): Likewise,
36130 (vect_gen_perm_mask_checked): Likewise,
36131
36132 2018-01-02 Richard Sandiford <richard.sandiford@linaro.org>
36133
36134 * optabs-query.h (qimode_for_vec_perm): Declare.
36135 * optabs-query.c (can_vec_perm_p): Split out qimode search to...
36136 (qimode_for_vec_perm): ...this new function.
36137 * optabs.c (expand_vec_perm): Use qimode_for_vec_perm.
36138
36139 2018-01-02 Aaron Sawdey <acsawdey@linux.vnet.ibm.com>
36140
36141 * rtlanal.c (canonicalize_condition): Return 0 if final rtx
36142 does not have a conditional at the top.
36143
36144 2018-01-02 Richard Biener <rguenther@suse.de>
36145
36146 * ipa-inline.c (big_speedup_p): Fix expression.
36147
36148 2018-01-02 Jan Hubicka <hubicka@ucw.cz>
36149
36150 PR target/81616
36151 * config/i386/x86-tune-costs.h: Increase cost of integer load costs
36152 for generic 4->6.
36153
36154 2018-01-02 Jan Hubicka <hubicka@ucw.cz>
36155
36156 PR target/81616
36157 Generic tuning.
36158 * x86-tune-costs.h (generic_cost): Reduce cost of FDIV 20->17,
36159 cost of sqrt 20->14, DIVSS 18->13, DIVSD 32->17, SQRtSS 30->14
36160 and SQRTsD 58->18, cond_not_taken_branch_cost. 2->1. Increase
36161 cond_taken_branch_cost 3->4.
36162
36163 2018-01-01 Jakub Jelinek <jakub@redhat.com>
36164
36165 PR tree-optimization/83581
36166 * tree-loop-distribution.c (pass_loop_distribution::execute): Return
36167 TODO_cleanup_cfg if any changes have been made.
36168
36169 PR middle-end/83608
36170 * expr.c (store_expr_with_bounds): Use simplify_gen_subreg instead of
36171 convert_modes if target mode has the right side, but different mode
36172 class.
36173
36174 PR middle-end/83609
36175 * expr.c (expand_assignment): Fix up a typo in simplify_gen_subreg
36176 last argument when extracting from CONCAT. If either from_real or
36177 from_imag is NULL, use expansion through memory. If result is not
36178 a CONCAT and simplify_gen_subreg fails, try to simplify_gen_subreg
36179 the parts directly to inner mode, if even that fails, use expansion
36180 through memory.
36181
36182 PR middle-end/83623
36183 * expmed.c (expand_shift_1): For 2-byte rotates by BITS_PER_UNIT,
36184 check for bswap in mode rather than HImode and use that in expand_unop
36185 too.
36186 \f
36187 Copyright (C) 2018 Free Software Foundation, Inc.
36188
36189 Copying and distribution of this file, with or without modification,
36190 are permitted in any medium without royalty provided the copyright
36191 notice and this notice are preserved.