Fix GNU coding style.
[gcc.git] / gcc / ChangeLog
1 2018-11-05 Martin Liska <mliska@suse.cz>
2
3 * mem-stats.h (mem_alloc_description::get_list): Fix GNU coding
4 style.
5 * vec.c: Likewise.
6
7 2018-11-05 Richard Biener <rguenther@suse.de>
8
9 * tree-scalar-evolution.h (final_value_replacement_loop): Update
10 prototype.
11 * tree-scalar-evolution.c (final_value_replacement_loop): Return
12 whether anything was done.
13 (scev_const_prop): Remove constant propagation part, fold
14 remains into ...
15 * tree-ssa-loop.c (pass_scev_cprop::execute): ... here.
16 (pass_data_scev_cprop): TODO_cleanup_cfg is now done
17 conditionally.
18
19 2018-11-05 Jakub Jelinek <jakub@redhat.com>
20
21 PR tree-optimization/87859
22 * gimple-ssa-store-merging.c (struct merged_store_group): Add
23 only_constants and first_nonmergeable_order members.
24 (merged_store_group::merged_store_group): Initialize them.
25 (merged_store_group::do_merge): Clear only_constants member if
26 adding something other than INTEGER_CST store.
27 (imm_store_chain_info::coalesce_immediate_stores): Don't merge
28 stores with order >= first_nonmergeable_order. Use
29 merged_store->only_constants instead of always recomputing it.
30 Set merged_store->first_nonmergeable_order if we've skipped any
31 stores. Attempt to merge overlapping INTEGER_CST stores that
32 we would otherwise skip.
33
34 PR sanitizer/87837
35 * match.pd (X + Y < X): Don't optimize if TYPE_OVERFLOW_SANITIZED.
36
37 2018-11-05 Xuepeng Guo <xuepeng.guo@intel.com>
38
39 PR target/87853
40 * config/i386/emmintrin.h (__v16qs): New to cope with option
41 -funsigned-char.
42 (_mm_cmpeq_epi8): Replace __v16qi with __v16qs.
43 (_mm_cmplt_epi8): Likewise.
44 (_mm_cmpgt_epi8): Likewise.
45
46 2018-11-05 Richard Biener <rguenther@suse.de>
47
48 PR rtl-optimization/87852
49 * fwprop.c (use_killed_between): Only consider single-defs of the
50 use whose definition statement dominates the use.
51
52 2018-11-05 Martin Liska <mliska@suse.cz>
53
54 PR web/87829
55 * doc/invoke.texi: Remove options that are
56 not disabled with -Os.
57
58 2018-11-05 Martin Liska <mliska@suse.cz>
59
60 PR c/87811
61 * doc/extend.texi: Update constrain about the last argument
62 of __builtin_expect_with_probability.
63
64 2018-11-05 Martin Liska <mliska@suse.cz>
65
66 PR c/87811
67 * predict.c (expr_expected_value_1): Verify
68 that last argument is a real constants and emit
69 error.
70
71 2018-11-05 Martin Liska <mliska@suse.cz>
72
73 PR gcov-profile/77698
74 * ipa-profile.c (ipa_profile): Adjust hotness threshold
75 only in LTO mode.
76
77 2018-11-04 Bernd Edlinger <bernd.edlinger@hotmail.de>
78
79 PR tree-optimization/86572
80 * builtins.c (c_strlen): Handle negative offsets in a safe way.
81
82 2018-11-04 Bernd Edlinger <bernd.edlinger@hotmail.de>
83
84 PR tree-optimization/87672
85 * gimple-fold.c (gimple_fold_builtin_stxcpy_chk): Gimplify.
86 * tree-ssa-strlen.c (handle_builtin_strcat): Adjust object size.
87
88 2018-11-04 Uros Bizjak <ubizjak@gmail.com>
89
90 PR middle-end/58372
91 * cfgexpand.c (pass_expand::execute): Move the call to
92 finish_eh_generation in front of the call to expand_stack_alignment.
93
94 2018-11-04 Venkataramanan Kumar <venkataramanan.kumar@amd.com>
95
96 * common/config/i386/i386-common.c (processor_alias_table): Add
97 znver2 entry.
98 * config.gcc (i[34567]86-*-linux* | ...): Add znver2.
99 (case ${target}): Add znver2.
100 * config/i386/driver-i386.c: (host_detect_local_cpu): Let
101 -march=native recognize znver2 processors.
102 * config/i386/i386-c.c (ix86_target_macros_internal): Add znver2.
103 * config/i386/i386.c (m_znver2): New definition.
104 (m_ZNVER): New definition.
105 (m_AMD_MULTIPLE): Includes m_znver2.
106 (processor_cost_table): Add znver2 entry.
107 (processor_target_table): Add znver2 entry.
108 (get_builtin_code_for_version): Set priority for
109 PROCESSOR_ZNVER2.
110 (processor_model): Add M_AMDFAM17H_ZNVER2.
111 (arch_names_table): Ditto.
112 (ix86_reassociation_width): Include znver2.
113 * config/i386/i386.h (TARGET_znver2): New definition.
114 (struct ix86_size_cost): Add TARGET_ZNVER2.
115 (enum processor_type): Add PROCESSOR_ZNVER2.
116 * config/i386/i386.md (define_attr "cpu"): Add znver2.
117 * config/i386/x86-tune-costs.h: (processor_costs) Add znver2 costs.
118 * config/i386/x86-tune-sched.c: (ix86_issue_rate): Add znver2.
119 (ix86_adjust_cost): Add znver2.
120 * config/i386/x86-tune.def: Replace m_ZNVER1 by m_ZNVER.
121 * gcc/doc/extend.texi: Add details about znver2.
122 * gcc/doc/invoke.texi: Add details about znver2.
123
124 2018-11-03 Sandra Loosemore <sandra@codesourcery.com>
125
126 PR target/87079
127
128 * config/nios2/nios2.c (nios2_rtx_costs): Recognize <mul>sidi3
129 pattern.
130
131 2018-11-02 Aaron Sawdey <acsawdey@linux.ibm.com>
132
133 * config/rs6000/rs6000-string.c (expand_strncmp_gpr_sequence): Pay
134 attention to TARGET_AVOID_XFORM and BYTES_BIG_ENDIAN.
135
136 2018-11-02 Richard Earnshaw <rearnsha@arm.com>
137
138 * config/aarch64/aarch64.c ((aarch64_override_options): Disable
139 shrink-wrapping when -mtrack-speculation.
140
141 2018-11-02 Richard Biener <rguenther@suse.de>
142
143 * tree-ssa-coalesce.c (struct coalesce_list): Add obstack member.
144 (pop_cost_one_pair): Do not free pair.
145 (pop_best_coalesce): Likewise.
146 (create_coalesce_list): Initialize obstack.
147 (delete_coalesce_list): Free obstack.
148 (find_coalesce_pair): Obstack-allocate coalesce pairs.
149 (add_cost_one_coalesce): Likewise.
150 (struct live_track): Remove bitmap pointer indirections.
151 (new_live_track): Adjust.
152 (delete_live_track): Likewise.
153 (live_track_remove_partition): Likewise.
154 (live_track_add_partition): Likewise.
155 (live_track_live_p): Likewise.
156 (live_track_process_def): Likewise.
157 (live_track_clear_base_vars): Likewise.
158
159 2018-11-02 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
160
161 * configure.ac (gcc_cv_as_sparc_register_op): Remove.
162 * configure: Regenerate.
163 * config.in: Regenerate.
164 * config/sparc/sparc.c (sparc_output_scratch_registers): Remove
165 HAVE_AS_REGISTER_PSEUDO_OP guard.
166 * config/sparc/sparc.h (ASM_ARCH64_SPEC): Remove
167 !HAVE_AS_REGISTER_PSEUDO_OP support.
168 (ASM_DECLARE_REGISTER_GLOBAL): Remove HAVE_AS_REGISTER_PSEUDO_OP
169 guard.
170
171 2018-11-02 Richard Biener <rguenther@suse.de>
172
173 * dwarf2out.c (build_abbrev_table): Guard lookup_external_ref call
174 with is_type_die.
175
176 2018-11-02 Richard Biener <rguenther@suse.de>
177
178 PR tree-optimization/87776
179 * tree-ssa-sccvn.c (do_rpo_vn): Do not mark backedges
180 executable when iterating but running into rpo-vn-max-loop-depth
181 and not eliding the iteration.
182
183 2018-11-30 Jan Hubicka <jh@suse.cz>
184
185 * tree.c (free_lang_data_in_decl): Free TREE_TYPE and alignment of
186 TYPE_DECL.
187
188 2018-11-01 Aaron Sawdey <acsawdey@linux.ibm.com>
189
190 * config/rs6000/rs6000-protos.h (rs6000_address_for_fpconvert): Remove
191 prototype.
192 * config/rs6000/rs6000.c (rs6000_force_indexed_or_indirect_mem):
193 Combine with rs6000_address_for_fpconvert.
194 (rs6000_address_for_fpconvert): Combine with
195 rs6000_force_indexed_or_indirect_mem.
196 (rs6000_expand_vector_init): Change function call from
197 rs6000_address_for_fpconvert to rs6000_force_indexed_or_indirect_mem.
198 * config/rs6000/rs6000.md (floatsi<mode>2_lfiwax): Change call from
199 rs6000_address_for_fpconvert to rs6000_force_indexed_or_indirect_mem.
200 (floatsi<mode>2_lfiwax_mem): Ditto.
201 (floatunssi<mode>2_lfiwzx): Ditto.
202 (floatunssi<mode>2_lfiwzx_mem): Ditto.
203 (float<QHI:mode><FP_ISA3:mode>2): Ditto.
204 (floatuns<QHI:mode><FP_ISA3:mode>2): Ditto.
205 (fix_trunc<mode>si2_stfiwx): Ditto.
206 (fixuns_trunc<mode>si2_stfiwx): Ditto.
207 (float_<mode>si2_hw): Ditto.
208 (floatuns_<mode>si2_hw): Ditto.
209 * config/rs6000/vsx.md (*vsx_extract_si): Ditto.
210 (vsx_splat_<mode>): Ditto.
211
212 2018-11-01 Joseph Myers <joseph@codesourcery.com>
213
214 * configure.ac (gcc_cv_as_ia64_ltoffx_ldxmov_relocs): Add newline
215 at end of assembler input text.
216 * configure: Regenerate.
217
218 2018-11-01 Jakub Jelinek <jakub@redhat.com>
219
220 PR tree-optimization/87826
221 * gimple-ssa-store-merging.c (do_shift_rotate): Punt if count is
222 negative or larger or equal to type's precision.
223
224 2018-10-31 Alexandre Oliva <aoliva@redhat.com>
225
226 * opts.c (default_options_table): Do not enable
227 OPT_fdelayed_branch at -Og.
228 * doc/invoke.texi (-fdelayed-branch): Document it.
229
230 2018-10-31 Richard Henderson <richard.henderson@linaro.org>
231
232 * optabs-libfuncs.c (build_libfunc_function_visibility):
233 New, split out from...
234 (build_libfunc_function): ... here.
235 (init_one_libfunc_visibility): New, split out from ...
236 (init_one_libfunc): ... here.
237
238 * config/aarch64/atomics.md (aarch64_atomic_<ATOMIC_LDOP><ALLI>_lse):
239 scratch register need not be early-clobber. Document the reason
240 why we cannot use ST<OP>.
241
242 2018-10-31 Joseph Myers <joseph@codesourcery.com>
243
244 PR bootstrap/82856
245 * configure.ac: Remove AC_PREREQ. Use AC_LANG_SOURCE. Use single
246 line for second argument of AC_DEFINE_UNQUOTED.
247 * doc/install.texi (Tools/packages necessary for modifying GCC):
248 Update to autoconf 2.69 and automake 1.15.1.
249 * aclocal.m4, config.in, configure: Regenerate.
250
251 2018-10-31 Pat Haugen <pthaugen@us.ibm.com>
252
253 * tree-ssa-loop-ivcanon.c (try_peel_loop): Fix typo and remove dead
254 initialization.
255
256 2018-10-31 Martin Liska <mliska@suse.cz>
257
258 PR driver/83193
259 * common/config/aarch64/aarch64-common.c (aarch64_parse_extension):
260 Add new argument invalid_extension.
261 (aarch64_get_all_extension_candidates): New function.
262 (aarch64_rewrite_selected_cpu): Add NULL to function call.
263 * config/aarch64/aarch64-protos.h (aarch64_parse_extension): Add
264 new argument.
265 (aarch64_get_all_extension_candidates): New function.
266 * config/aarch64/aarch64.c (aarch64_parse_arch): Add new
267 argument invalid_extension.
268 (aarch64_parse_cpu): Likewise.
269 (aarch64_print_hint_for_extensions): New function.
270 (aarch64_validate_mcpu): Provide hint about invalid extension.
271 (aarch64_validate_march): Likewise.
272 (aarch64_handle_attr_arch): Pass new argument.
273 (aarch64_handle_attr_cpu): Provide hint about invalid extension.
274 (aarch64_handle_attr_isa_flags): Likewise.
275
276 2018-10-31 Richard Biener <rguenther@suse.de>
277
278 PR middle-end/70359
279 PR middle-end/86270
280 * tree-outof-ssa.c (insert_backedge_copies): Restrict
281 copy generation to useful cases. Place the copy before
282 the definition of the backedge value when possible.
283
284 2018-10-31 Claudiu Zissulescu <claziss@synopsys.com>
285
286 * config/arc/arc-arch.h (ARC_TUNE_ARC7XX): New tune value.
287 * config/arc/arc.c (arc_active_insn): New function.
288 (check_store_cacheline_hazard): Likewise.
289 (workaround_arc_anomaly): Use check_store_cacheline_hazard.
290 (arc_override_options): Disable delay slot scheduler for older
291 A7.
292 (arc_store_addr_hazard_p): New implementation, old one renamed to
293 ...
294 (arc_store_addr_hazard_internal_p): Renamed.
295 (arc_reorg): Don't combine into brcc instructions which are part
296 of hardware hazard solution.
297 * config/arc/arc.md (attr tune): Consider new arc7xx tune value.
298 (tune_arc700): Likewise.
299 * config/arc/arc.opt (arc7xx): New tune value.
300 * config/arc/arc700.md: Improve A7 scheduler.
301
302 2018-10-31 Claudiu Zissulescu <claziss@synopsys.com>
303
304 * config/arc/arc.c (arc_override_options): Remove
305 TARGET_COMPACT_CASESI.
306 * config/arc/arc.h (ASM_OUTPUT_ADDR_DIFF_ELT): Update.
307 (CASE_VECTOR_MODE): Likewise.
308 (CASE_VECTOR_PC_RELATIVE): Likewise.
309 (CASE_VECTOR_SHORTEN_MODE): Likewise.
310 (CASE_VECTOR_SHORTEN_MODE1): Delete.
311 (ADDR_VEC_ALIGN): Update.
312 (ASM_OUTPUT_CASE_LABEL): Undefine.
313 (ASM_OUTPUT_BEFORE_CASE_LABEL): Undefine.
314 (TARGET_BI_BIH): Define.
315 (DEFAULT_BRANCH_INDEX): Likewise.
316 * config/arc/arc.md (casesi): Rework to accept BI/BIH
317 instructions, remove compact_casesi use case.
318 (casesi_compact_jump): Remove.
319 (casesi_dispatch): New pattern.
320 * config/arc/arc.opt: Add mbranch-index option. Deprecate
321 compact_casesi option.
322 * doc/invoke.texi: Document mbranch-index option.
323
324 2018-10-31 Claudiu Zissulescu <claziss@synopsys.com>
325
326 * config/arc/arc.c (arc_get_tp): Remove function.
327 (arc_emit_call_tls_get_addr): Likewise.
328 (arc_call_tls_get_addr): New function.
329 (arc_legitimize_tls_address): Make use of arc_call_tls_get_addr.
330 * config/arc/arc.md (tls_load_tp_soft): Remove.
331 (tls_gd_get_addr): Likewise.
332
333 2018-10-31 Claudiu Zissulescu <claziss@synopsys.com>
334
335 * config/arc/arc.md (mulsi3): Remove call to mulsi_600_lib.
336 (mulsi3_600_lib): Remove pattern.
337 (umulsi3_highpart_600_lib_le): Likewise.
338 (umulsi3_highpart): Remove call to umulsi3_highpart_600_lib_le.
339 (umulsidi3): Remove call to umulsidi3_600_lib.
340 (umulsidi3_600_lib): Remove pattern.
341 (peephole2): Remove peephole using the above deprecated patterns.
342
343 2018-10-31 Thomas Preud'homme <thomas.preudhomme@linaro.org>
344
345 PR target/87374
346 * config/arm/arm.c (arm_option_check_internal): Disable the combined
347 use of -mslow-flash-data and -mword-relocations.
348 (arm_option_override): Enable -mword-relocations if -fpic or -fPIC.
349 * config/arm/arm.md (SYMBOL_REF MOVT splitter): Stop checking for
350 flag_pic.
351 * doc/invoke.texi (-mword-relocations): Mention conflict with
352 -mslow-flash-data.
353 (-mslow-flash-data): Reciprocally.
354
355 2018-10-31 Richard Henderson <richard.henderson@linaro.org>
356
357 * config/aarch64/aarch64.c (aarch64_hard_regno_mode_ok): Force
358 16-byte modes held in GP registers to use an even regno.
359
360 * config/aarch64/aarch64.c (aarch64_emit_bic): Remove.
361 (aarch64_atomic_ldop_supported_p): Remove.
362 (aarch64_gen_atomic_ldop): Remove.
363 * config/aarch64/atomic.md (atomic_<atomic_optab><ALLI>):
364 Fully expand LSE operations here.
365 (atomic_fetch_<atomic_optab><ALLI>): Likewise.
366 (atomic_<atomic_optab>_fetch<ALLI>): Likewise.
367 (aarch64_atomic_<ATOMIC_LDOP><ALLI>_lse): Drop atomic_op iterator
368 and use ATOMIC_LDOP instead; use register_operand for the input;
369 drop the split and emit insns directly.
370 (aarch64_atomic_fetch_<ATOMIC_LDOP><ALLI>_lse): Likewise.
371 (aarch64_atomic_<atomic_op>_fetch<ALLI>_lse): Remove.
372 (@aarch64_atomic_load<ATOMIC_LDOP><ALLI>): Remove.
373
374 * config/aarch64/aarch64.c (aarch64_emit_atomic_swap): Remove.
375 (aarch64_gen_atomic_ldop): Don't call it.
376 * config/aarch64/atomics.md (atomic_exchange<ALLI>):
377 Use aarch64_reg_or_zero.
378 (aarch64_atomic_exchange<ALLI>): Likewise.
379 (aarch64_atomic_exchange<ALLI>_lse): Remove split; remove & from
380 operand 0; use aarch64_reg_or_zero for input; merge ...
381 (@aarch64_atomic_swp<ALLI>): ... this and remove.
382
383 * config/aarch64/aarch64.c (aarch64_gen_compare_reg_maybe_ze): New.
384 (aarch64_split_compare_and_swap): Use it.
385 (aarch64_expand_compare_and_swap): Likewise. Remove convert_modes;
386 test oldval against the proper predicate.
387 * config/aarch64/atomics.md (@atomic_compare_and_swap<ALLI>):
388 Use nonmemory_operand for expected.
389 (cas_short_expected_pred): New.
390 (@aarch64_compare_and_swap<SHORT>): Use it; use "rn" not "rI" to match.
391 (@aarch64_compare_and_swap<GPI>): Use "rn" not "rI" for expected.
392 * config/aarch64/predicates.md (aarch64_plushi_immediate): New.
393 (aarch64_plushi_operand): New.
394
395 * config/aarch64/aarch64.c (aarch64_expand_compare_and_swap):
396 Force oldval into the rval register for TARGET_LSE; emit the compare
397 during initial expansion so that it may be deleted if unused.
398 (aarch64_gen_atomic_cas): Remove.
399 * config/aarch64/atomics.md (@aarch64_compare_and_swap<SHORT>_lse):
400 Change =&r to +r for operand 0; use match_dup for operand 2;
401 remove is_weak and mod_f operands as unused. Drop the split
402 and merge with...
403 (@aarch64_atomic_cas<SHORT>): ... this pattern's output; remove.
404 (@aarch64_compare_and_swap<GPI>_lse): Similarly.
405 (@aarch64_atomic_cas<GPI>): Similarly.
406
407 2018-10-31 Richard Biener <rguenther@suse.de>
408
409 * tree-eh.c (replace_trapping_overflow): Simplify ABS_EXPR case
410 using ABSU_EXPR.
411
412 2018-10-31 Sameera Deshpande <sameera.deshpande@linaro.org>
413
414 * config/aarch64/aarch64-cores.def (saphira): Use saphira pipeline.
415 * config/aarch64/aarch64.md: Include saphira.md
416 * config/aarch64/saphira.md: New file for pipeline description.
417
418 2018-10-30 Martin Sebor <msebor@redhat.com>
419
420 PR middle-end/87041
421 * gimple-ssa-sprintf.c (format_directive): Use %G to include
422 inlining context.
423 (sprintf_dom_walker::compute_format_length):
424 Avoid setting POSUNDER4K here.
425 (get_destination_size): Handle null argument values.
426 (get_user_idx_format): New function.
427 (sprintf_dom_walker::handle_gimple_call): Handle all printf-like
428 functions, including user-defined with attribute format printf.
429 Use %G to include inlining context.
430 Set POSUNDER4K here.
431
432 2018-10-30 Jan Hubicka <jh@suse.cz>
433
434 * params.def (lto-partitions): Bump from 32 to 128.
435
436 2018-10-30 Jan Hubicka <jh@suse.cz>
437
438 * tree.c
439 (free_lang_data_d, add_tree_to_fld_list, fld_worklist_push): Move
440 head in file.
441 (free_lang_data_in_type): Forward declare.
442 (fld_type_variant_equal_p): New function.
443 (fld_type_variant): New function
444 (fld_incomplete_types): New hash.
445 (fld_incomplete_type_of): New function
446 (fld_simplfied-type): New function.
447 (free_lang_data_in_decl): Add fld parameter; simplify type of FIELD_DECL
448 (free_lang_data): Allocate and free fld_incomplete_type; update call
449 of free_lang_data_in_decl.
450
451 2018-10-30 Eric Botcazou <ebotcazou@adacore.com>
452
453 * gcov.c (output_lines): Remove duplicate line.
454
455 2018-10-30 Aaron Sawdey <acsawdey@linux.ibm.com>
456
457 * config/rs6000/rs6000.md (bswapdi2): Force address into register
458 if not in indexed or indirect form.
459 (bswapdi2_load): Change predicate to indexed_or_indirect_operand.
460 (bswapdi2_store): Ditto.
461 * config/rs6000/rs6000.c (rs6000_force_indexed_or_indirect_mem): New
462 helper function.
463 * config/rs6000/rs6000-protos.h (rs6000_force_indexed_or_indirect_mem):
464 Prototype for helper function.
465
466 2018-10-30 Martin Sebor <msebor@redhat.com>
467
468 * doc/extend.texi (optimize): Clarify/expand attribute documentation.
469 (target, pragma GCC optimize, pragma GCC target): Ditto.
470
471 2018-10-30 Jonathan Wakely <jwakely@redhat.com>
472
473 * doc/extend.texi: Fix prototype and description of
474 __builtin_expect_with_probability.
475
476 2018-10-30 Michael Ploujnikov <michael.ploujnikov@oracle.com>
477
478 * cgraph.h (clone_function_name_1): Replaced by new
479 clone_function_name_numbered that takes name as string; for
480 privatize_symbol_name_1 use only.
481 (clone_function_name): Renamed to
482 clone_function_name_numbered to be explicit about numbering.
483 (clone_function_name): New two-argument function that does
484 not number its output.
485 (clone_function_name): New three-argument function that
486 takes a number to append to its output.
487 * cgraphclones.c (duplicate_thunk_for_node):
488 (clone_function_name_1): Renamed.
489 (clone_function_name_numbered): Two new functions.
490 (clone_function_name): Improved documentation.
491 (cgraph_node::create_virtual_clone): Use clone_function_name_numbered.
492 * config/rs6000/rs6000.c (make_resolver_func): Ditto.
493 * final.c (final_scan_insn_1): Use the new clone_function_name
494 without numbering.
495 * multiple_target.c (create_dispatcher_calls): Ditto.
496 (create_target_clone): Ditto.
497 * omp-expand.c (grid_expand_target_grid_body): Ditto.
498 * omp-low.c (create_omp_child_function_name): Ditto.
499 * omp-simd-clone.c (simd_clone_create): Ditto.
500 * symtab.c (simd_symtab_node::noninterposable_alias): Use the
501 new clone_function_name without numbering.
502
503 2018-10-30 Richard Earnshaw <rearnsha@arm.com>
504
505 * alloc-pool.h (base_pool_allocator <TBlockAllocator>::initialize):
506 Assert that the allocation size is not zero.
507
508 2018-10-30 Richard Biener <rguenther@suse.de>
509
510 PR tree-optimization/87800
511 * tree-vect-slp.c (vect_build_slp_tree_2): Reject any
512 non-induction or reduction PHIs.
513
514 2018-10-30 Sameera Deshpande <sameera.deshpande@linaro.org
515
516 * config/aarch64/falkor-tag-collision-avoidance.c
517 (execute_tag_collision_avoidance): Call df_note_add_problem.
518
519 2018-10-30 Martin Liska <mliska@suse.cz>
520
521 * doc/extend.texi: Fix typo in documentation
522 of __builtin_expect_with_probability.
523
524 2018-10-29 David Malcolm <dmalcolm@redhat.com>
525
526 PR c++/87721
527 * input.c (get_substring_ranges_for_loc): Detect if
528 linemap_resolve_location gives us a NULL map, and reject
529 this case.
530
531 2018-10-29 Iain Buclaw <ibuclaw@gdcproject.org>
532
533 * config.gcc (xstormy16-*-elf): Set tm_d_file.
534
535 2018-10-29 David Malcolm <dmalcolm@redhat.com>
536 Martin Sebor <msebor@redhat.com>
537 Manuel Lopez-Ibanez <manu@gcc.gnu.org>
538
539 * doc/ux.texi (Quoting): New subsection, adapted from material at
540 https://gcc.gnu.org/wiki/DiagnosticsGuidelines written by
541 MartinSebor and ManuelLopezIbanez.
542 (Fix-it hints): Note that fix-it hints shouldn't be marked for
543 translation.
544
545 2018-10-29 Kugan Vivekanandarajah <kuganv@linaro.org>
546
547 PR middle-end/87469
548 * tree-ssa-loop-niter.c (number_of_iterations_popcount): Fix niter
549 max value.
550
551 2018-10-29 Paul A. Clarke <pc@us.ibm.com>
552
553 * gcc.target/powerpc/ssse3-check.h: Remove inaccurate comment.
554
555 2018-10-29 Paul Koning <ni1d@arrl.net>
556
557 * doc/rtl.texi (CONST_WIDE_INT_ELT): Give correct macro name.
558
559 2018-10-29 Paul A. Clarke <pc@us.ibm.com>
560
561 * gcc/config/rs6000/mmintrin.h (_mm_packs_pi16, _mm_packs_pi32,
562 _mm_packs_pu16, _mm_unpackhi_pi8, _mm_unpacklo_pi8, _mm_add_pi8,
563 _mm_add_pi16, _mm_add_pi32, _mm_sub_pi8, _mm_sub_pi16, _mm_sub_pi32,
564 _mm_cmpgt_pi8, _mm_cmpeq_pi16, _mm_cmpgt_pi16, _mm_cmpeq_pi32,
565 _mm_cmpgt_pi32, _mm_adds_pi8, _mm_adds_pi16, _mm_adds_pu8,
566 _mm_adds_pu16, _mm_subs_pi8, _mm_subs_pi16, _mm_subs_pu8,
567 _mm_subs_pu16, _mm_madd_pi16, _mm_mulhi_pi16, _mm_mullo_pi16,
568 _mm_sll_pi16, _mm_sra_pi16, _mm_srl_pi16, _mm_set1_pi16, _mm_set1_pi8):
569 Change 'vector' to '__vector'.
570 * gcc/config/rs6000/xmmintrin.h (_mm_cvtps_pi32, _mm_cvttps_pi32,
571 _mm_cvtps_pi16, _mm_cvtps_pi8, _mm_max_pi16, _mm_max_pu8, _mm_min_pi16,
572 _mm_min_pu8, _mm_mulhi_pu16, _mm_shuffle_pi16, _mm_avg_pu8,
573 _mm_avg_pu16): Likewise. And, whitespace corrections.
574
575 2018-10-29 Richard Biener <rguenther@suse.de>
576
577 PR tree-optimization/87785
578 * tree-vect-slp.c (vect_gather_slp_loads): Only gather
579 internal defs.
580
581 2018-10-29 Olivier Hainque <hainque@adacore.com>
582
583 * VXWORKS_NET_LIBS_RTP: New macro, network part of VXWORKS_LIBS_RTP.
584
585 2018-10-29 Olivier Hainque <hainque@adacore.com>
586
587 * config/vxworks.h (VXWORKS_PERSONALITY): New VxWorks
588 ports configuration macro, defaults to "gnu".
589 (VXWORKS_OS_CPP_BUILTINS): Use it. Feed TOOL and
590 TOOL_FAMILY instead of _VX_TOOL/_VXTOOL_FAMILY.
591
592 2018-10-29 Olivier Hainque <hainque@adacore.com>
593
594 * config/vxworks.h (CLEAR_INSN_CACHE): #undef before #define.
595
596 2018-10-29 Richard Biener <rguenther@suse.de>
597
598 PR tree-optimization/87790
599 * tree-vect-slp.c (vect_mark_slp_stmts): Simplify.
600 (vect_make_slp_decision): Adjust.
601 (vect_slp_analyze_bb_1): Likewise.
602 (vect_detect_hybrid_slp_stmts): Properly union SLP type over
603 edges.
604
605 2018-10-29 Richard Biener <rguenther@suse.de>
606
607 PR tree-optimization/87785
608 * tree-vect-slp.c (vect_build_slp_tree_2): Remove loads argument
609 and processing.
610 (vect_build_slp_tree): Likewise.
611 (vect_gather_slp_loads): New function.
612 (vect_analyze_slp_instance): Gather loads separately from the
613 SLP tree build.
614
615 2018-10-29 Martin Liska <mliska@suse.cz>
616
617 * Makefile.in: Make dependency to json.o.
618 * doc/gcov.texi: Document new JSON format, remove
619 old intermediate format documentation.
620 * gcov.c (struct function_info): Come up with m_name and
621 m_demangled_name.
622 (function_info::function_info): Initialize it.
623 (function_info::~function_info): Release it.
624 (main): Rename flag_intermediate_format to flag_json_format.
625 (print_usage): Describe --json-format.
626 (process_args): Set flag_json_format.
627 (output_intermediate_line): Remove.
628 (output_intermediate_json_line): Likewise.
629 (get_gcov_intermediate_filename): Return new extension
630 ".gcov.json.gz".
631 (output_intermediate_file): Implement JSON emission.
632 (output_json_intermediate_file): Implement JSON emission.
633 (generate_results): Use ::get_name for function name.
634 Handle JSON output file.
635 (read_graph_file): Use ::get_name instead of cplus_demangle.
636 (read_count_file): Likewise.
637 (solve_flow_graph): Likewise.
638 (add_line_counts): Likewise.
639 (accumulate_line_counts): Use new flag_json_format.
640 (output_function_details): Use ::get_name instead of cplus_demangle.
641 (output_lines): Likewise.
642 * json.cc (test_writing_literals): Add new tests.
643 * json.h (class literal): Add new boolean constructor.
644
645 2018-10-29 Segher Boessenkool <segher@kernel.crashing.org>
646
647 PR rtl-optimization/87701
648 PR rtl-optimization/87780
649 * combine.c (make_more_copies): Rewrite.
650
651 2018-10-28 Kugan Vivekanandarajah <kuganv@linaro.org>
652
653 * doc/generic.texi (ABSU_EXPR): Document.
654 * match.pd (absu(x)*absu(x) -> x*x): Handle.
655 (absu(absu(X)) -> absu(X)): Likewise.
656 (absu(-X) -> absu(X)): Likewise.
657 (absu(X) where X is nonnegative -> X): Likewise.
658
659 2018-10-28 Iain Buclaw <ibuclaw@gdcproject.org>
660
661 * Makefile.in (tm_d_file_list, tm_d_include_list): New variables.
662 (TM_D_H, D_TARGET_DEF, D_TARGET_H, D_TARGET_OBJS): New variables.
663 (tm_d.h, cs-tm_d.h, default-d.o): New rules.
664 (d/d-target-hooks-def.h, s-d-target-hooks-def-h): New rules.
665 (s-tm-texi): Also check timestamp on d-target.def.
666 (generated_files): Add TM_D_H and d-target-hooks-def.h.
667 (build/genhooks.o): Also depend on D_TARGET_DEF.
668 * config.gcc (tm_d_file, d_target_objs, target_has_targetdm): New
669 variables.
670 * config/aarch64/aarch64-d.c: New file.
671 * config/aarch64/aarch64-linux.h (GNU_USER_TARGET_D_CRITSEC_SIZE):
672 Define.
673 * config/aarch64/aarch64-protos.h (aarch64_d_target_versions): New
674 prototype.
675 * config/aarch64/aarch64.h (TARGET_D_CPU_VERSIONS): Define.
676 * config/aarch64/t-aarch64 (aarch64-d.o): New rule.
677 * config/arm/arm-d.c: New file.
678 * config/arm/arm-protos.h (arm_d_target_versions): New prototype.
679 * config/arm/arm.h (TARGET_D_CPU_VERSIONS): Define.
680 * config/arm/linux-eabi.h (EXTRA_TARGET_D_OS_VERSIONS): Define.
681 * config/arm/t-arm (arm-d.o): New rule.
682 * config/default-d.c: New file.
683 * config/glibc-d.c: New file.
684 * config/gnu.h (GNU_USER_TARGET_D_OS_VERSIONS): Define.
685 * config/i386/i386-d.c: New file.
686 * config/i386/i386-protos.h (ix86_d_target_versions): New prototype.
687 * config/i386/i386.h (TARGET_D_CPU_VERSIONS): Define.
688 * config/i386/linux-common.h (EXTRA_TARGET_D_OS_VERSIONS): Define.
689 (GNU_USER_TARGET_D_CRITSEC_SIZE): Define.
690 * config/i386/t-i386 (i386-d.o): New rule.
691 * config/kfreebsd-gnu.h (GNU_USER_TARGET_D_OS_VERSIONS): Define.
692 * config/kopensolaris-gnu.h (GNU_USER_TARGET_D_OS_VERSIONS): Define.
693 * config/linux-android.h (ANDROID_TARGET_D_OS_VERSIONS): Define.
694 * config/linux.h (GNU_USER_TARGET_D_OS_VERSIONS): Define.
695 * config/mips/linux-common.h (EXTRA_TARGET_D_OS_VERSIONS): Define.
696 * config/mips/mips-d.c: New file.
697 * config/mips/mips-protos.h (mips_d_target_versions): New prototype.
698 * config/mips/mips.h (TARGET_D_CPU_VERSIONS): Define.
699 * config/mips/t-mips (mips-d.o): New rule.
700 * config/powerpcspe/linux.h (GNU_USER_TARGET_D_OS_VERSIONS): Define.
701 * config/powerpcspe/linux64.h (GNU_USER_TARGET_D_OS_VERSIONS): Define.
702 * config/powerpcspe/powerpcspe-d.c: New file.
703 * config/powerpcspe/powerpcspe-protos.h (rs6000_d_target_versions):
704 New prototype.
705 * config/powerpcspe/powerpcspe.c (rs6000_output_function_epilogue):
706 Support GNU D by using 0 as the language type.
707 * config/powerpcspe/powerpcspe.h (TARGET_D_CPU_VERSIONS): Define.
708 * config/powerpcspe/t-powerpcspe (powerpcspe-d.o): New rule.
709 * config/riscv/riscv-d.c: New file.
710 * config/riscv/riscv-protos.h (riscv_d_target_versions): New
711 prototype.
712 * config/riscv/riscv.h (TARGET_D_CPU_VERSIONS): Define.
713 * config/riscv/t-riscv (riscv-d.o): New rule.
714 * config/rs6000/linux.h (GNU_USER_TARGET_D_OS_VERSIONS): Define.
715 * config/rs6000/linux64.h (GNU_USER_TARGET_D_OS_VERSIONS): Define.
716 * config/rs6000/rs6000-d.c: New file.
717 * config/rs6000/rs6000-protos.h (rs6000_d_target_versions): New
718 prototype.
719 * config/rs6000/rs6000.c (rs6000_output_function_epilogue):
720 Support GNU D by using 0 as the language type.
721 * config/rs6000/rs6000.h (TARGET_D_CPU_VERSIONS): Define.
722 * config/rs6000/t-rs6000 (rs6000-d.o): New rule.
723 * config/s390/s390-d.c: New file.
724 * config/s390/s390-protos.h (s390_d_target_versions): New prototype.
725 * config/s390/s390.h (TARGET_D_CPU_VERSIONS): Define.
726 * config/s390/t-s390 (s390-d.o): New rule.
727 * config/sparc/sparc-d.c: New file.
728 * config/sparc/sparc-protos.h (sparc_d_target_versions): New
729 prototype.
730 * config/sparc/sparc.h (TARGET_D_CPU_VERSIONS): Define.
731 * config/sparc/t-sparc (sparc-d.o): New rule.
732 * config/t-glibc (glibc-d.o): New rule.
733 * configure: Regenerated.
734 * configure.ac (tm_d_file): New variable.
735 (tm_d_file_list, tm_d_include_list, d_target_objs): Add substitutes.
736 * doc/contrib.texi (Contributors): Add self for the D frontend.
737 * doc/frontends.texi (G++ and GCC): Mention D as a supported language.
738 * doc/install.texi (Configuration): Mention libphobos as an option for
739 --enable-shared. Mention d as an option for --enable-languages.
740 (Testing): Mention check-d as a target.
741 * doc/invoke.texi (Overall Options): Mention .d, .dd, and .di as file
742 name suffixes. Mention d as a -x option.
743 * doc/sourcebuild.texi (Top Level): Mention libphobos.
744 * doc/standards.texi (Standards): Add section on D language.
745 * doc/tm.texi: Regenerated.
746 * doc/tm.texi.in: Add @node for D language and ABI, and @hook for
747 TARGET_CPU_VERSIONS, TARGET_D_OS_VERSIONS, and TARGET_D_CRITSEC_SIZE.
748 * dwarf2out.c (is_dlang): New function.
749 (gen_compile_unit_die): Use DW_LANG_D for D.
750 (declare_in_namespace): Return module die for D, instead of adding
751 extra declarations into the namespace.
752 (gen_namespace_die): Generate DW_TAG_module for D.
753 (gen_decl_die): Handle CONST_DECLSs for D.
754 (dwarf2out_decl): Likewise.
755 (prune_unused_types_walk_local_classes): Handle DW_tag_interface_type.
756 (prune_unused_types_walk): Handle DW_tag_interface_type same as other
757 kinds of aggregates.
758 * gcc.c (default_compilers): Add entries for .d, .dd and .di.
759 * genhooks.c: Include d/d-target.def.
760
761 2018-10-28 Iain Sandoe <iain@sandoe.co.uk>
762
763 PR target/85669
764 * config/rs6000/darwin.h (STACK_BOUNDARY): New.
765 (RS6000_STARTING_FRAME_OFFSET): Adjust to preserve 16byte alignment.
766 (STACK_DYNAMIC_OFFSET): Likewise.
767
768 2018-10-27 Sandra Loosemore <sandra@codesourcery.com>
769
770 PR target/80024
771 * config/nios2/nios2.c (nios2_valid_target_attribute_rec): Fix
772 error message.
773
774 2018-10-26 Tulio Magno Quites Machado Filho <tuliom@linux.ibm.com>
775
776 * doc/extend.texi (PowerPC builtins): Fix __builtin_unpack_ibm128
777 return type and other typos.
778
779 2018-10-26 Aaron Sawdey <acsawdey@linux.ibm.com>
780
781 * config/rs6000/rs6000-string.c (expand_strncmp_gpr_sequence): Change to
782 a shorter sequence with fewer branches.
783 (emit_final_str_compare_gpr): Ditto.
784
785 2018-10-26 Paul A. Clarke <pc@us.ibm.com>
786
787 * config/rs6000/tmmintrin.h: New file.
788 * config.gcc (powerpc*-*-*): Add tmmintrin.h to extra_headers.
789
790 2018-10-26 Paul A. Clarke <pc@us.ibm.com>
791
792 * config/rs6000/mmintrin.h: Enable 32bit compilation.
793 * config/rs6000/xmmintrin.h: Likewise.
794
795 2018-10-26 Paul A. Clarke <pc@us.ibm.com>
796
797 * config/rs6000/xmmintrin.h (_mm_extract_pi16): Fix for big-endian.
798
799 2018-10-26 Richard Biener <rguenther@suse.de>
800
801 * tree-vect-slp.c (vect_mark_slp_stmts): Add visited hash_set
802 and wrapper.
803 (vect_mark_slp_stmts_relevant): Likewise.
804 (vect_detect_hybrid_slp_stmts): Likewise.
805 (vect_bb_slp_scalar_cost): Likewise.
806 (vect_remove_slp_scalar_calls): Likewise.
807
808 2018-10-26 Jan Hubicka <jh@suse.cz>
809
810 * ipa-devirt.c (odr_subtypes_equivalent_p): Fix recursion.
811 (warn_types_mismatch): Fix walk of DECL_NAME.
812 (odr_types_equivalent_p): Fix overactive assert.
813
814 2018-10-26 Richard Biener <rguenther@suse.de>
815
816 PR tree-optimization/87105
817 * tree-vectorizer.h (_slp_tree::refcnt): New member.
818 * tree-vect-slp.c (vect_free_slp_tree): Decrement and honor
819 refcnt.
820 (vect_create_new_slp_node): Initialize refcnt to one.
821 (bst_traits): Move.
822 (scalar_stmts_set_t, bst_fail): Remove.
823 (vect_build_slp_tree_2): Add bst_map argument and adjust calls.
824 (vect_build_slp_tree): Add bst_map argument and lookup
825 already created SLP nodes.
826 (vect_print_slp_tree): Handle a SLP graph, print SLP node
827 addresses.
828 (vect_slp_rearrange_stmts): Handle a SLP graph.
829 (vect_analyze_slp_instance): Adjust and free SLP nodes from
830 the CSE map. Fix indenting.
831 (vect_schedule_slp_instance): Add short-cut.
832
833 2018-10-26 Martin Liska <mliska@suse.cz>
834
835 PR testsuite/86158
836 * ipa-prop.c (struct ipa_vr_ggc_hash_traits): Hash with
837 addr_expr and not with pointers.
838
839 2018-10-26 Jan Hubicka <jh@suse.cz>
840
841 * tree.c (free_lang_data_in_type): Only check main variants.
842 * ipa-devirt.c (warn_odr): Make static.
843 (types_same_for_odr): Drop strict variant.
844 (types_odr_comparable): Likewise.
845 (odr_or_derived_type_p): Look for main variants.
846 (odr_name_hasher::equal): Cleanup comment.
847 (odr_subtypes_equivalent): Add warn and warned arguments; check main
848 variants.
849 (type_variants_equivalent_p): break out from ...
850 (odr_types_equivalent): ... here; go for main variants where needed.
851 (warn_odr): ... here; turn static.
852 (warn_types_mismatch): Compare mangled names of main variants.
853 * ipa-utils.h (types_odr_comparable): Drop strict parameter.
854 (type_with_linkage_p): Sanity check that we look at main variant.
855 * lto.c (lto_read_decls): Only consider main variant to be ODR type.
856 * tree.h (types_same_for_odr): Drop strict argument.
857
858 2018-10-26 Richard Biener <rguenther@suse.de>
859
860 PR tree-optimization/87746
861 * tree-vect-data-refs.c (vect_update_misalignment_for_peel):
862 Simplify and fix WRT strided store groups with size not
863 equal to step in element count.
864 (vect_analyze_group_access_1): Dump the whole group.
865
866 2018-10-25 Carl Love <cel@us.ibm.com>
867
868 * config/rs6000/rs6000-c.c (P9V_BUILTIN_VEC_VSCEDPGT,
869 P9V_BUILTIN_VEC_VSCEDPLT, P9V_BUILTIN_VEC_VSCEDPEQ,
870 P9V_BUILTIN_VEC_VSCEDPUO): Rename base overloaded name. Add quad
871 precicion entry for each overloaded builtin.
872 * config/rs6000/rs6000-builtin.def (VSCEDPGT, VSCEDPLT, VSCEDPEQ,
873 VSCEDPUO): Rename overloaded name.
874 (VSCEDPGT, VSCEQPGT, VSCEDPLT, VSCEQPLT, VSCEDPEQ, VSCEQPEQ,
875 VSCEDPUO, VSCEQPUO): Add defitions for overloaded builtins.
876 * config/rs6000/vsx.md (xscmpexpqp_<code>_<mode>): Add
877 define_expand for xscmpexqp instruction.
878 (*xscmpexpqp): Add define_insn for the xscmpexqp instruction.
879
880 2018-10-25 Bill Schmidt <wschmidt@linux.ibm.com>
881 Jinsong Ji <jji@us.ibm.com>
882
883 * config/rs6000/emmintrin.h (_mm_slli_epi16): Replace deprecated
884 function with vec_sl.
885 (_mm_slli_epi32): Likewise.
886 (_mm_slli_epi64): Likewise.
887 (_mm_srai_epi16): Replace deprecated function with vec_sra.
888 (_mm_srai_epi32): Likewise.
889 (_mm_srli_epi16): Replace deprecated function with vec_sr.
890 (_mm_srli_epi32): Likewise.
891 (_mm_srli_epi64): Likewise.
892 (_mm_sll_epi16): Replace deprecated function with vec_sl.
893 (_mm_sll_epi32): Likewise.
894 (_mm_sll_epi64): Likewise.
895 (_mm_sra_epi16): Replace deprecated function with vec_sra.
896 (_mm_sra_epi32): Likewise.
897 (_mm_srl_epi16): Replace deprecated function with vec_sr.
898 (_mm_srl_epi32): Likewise.
899 (_mm_srl_epi64): Likewise.
900
901 2018-10-25 Bill Schmidt <wschmidt@linux.ibm.com>
902 Jinsong Ji <jji@us.ibm.com>
903
904 * gcc/config/rs6000/emmintrin.h (_mm_sll_epi16): Replace
905 comparison operators with vec_cmp* for compatibility due to
906 unfortunate history; clean up formatting and use types more
907 appropriately.
908 (_mm_sll_epi32): Likewise.
909 (_mm_sll_epi64): Likewise.
910 (_mm_srl_epi16): Likewise.
911 (_mm_srl_epi32): Likewise.
912 (_mm_srl_epi64): Likewise.
913
914 2018-10-25 Bill Schmidt <wschmidt@linux.ibm.com>
915 Jinsong Ji <jji@us.ibm.com>
916
917 * config/rs6000/emmintrin.h (_mm_sll_epi64): Remove wrong cast.
918 * config/rs6000/xmmintrin.h (_mm_min_ps): Change m's type to
919 __vector __bool int. Use vec_cmpgt in preference to deprecated
920 function vec_vcmpgtfp.
921 (_mm_max_ps): Likewise.
922
923 2018-10-25 Jeff Law <law@redhat.com>
924
925 * config/rl78/rl78.c (insn_ok_now): Always re-recognize the insn
926 if returning false.
927
928 2018-10-25 Martin Sebor <msebor@redhat.com>
929
930 * doc/extend.texi (aligned): Expand attribute description.
931 (Alignment): Rename section. Discuss function arguments.
932
933 2018-10-25 Jan Hubicka <jh@suse.cz>
934
935 * ipa-devirt.c (main_odr_variant): Remove.
936 (hash_odr_name, types_same_for_odr, types_odr_comparable,
937 odr_name_hasher::equal, odr_subtypes_equivalent_p):
938 Drop use of main_odr_variant.
939 (add_type_duplicate): Silence confused warnings on integer types.
940 (get_odr_type): Always look for main variant.
941 (register_odr_type): Simplify.
942
943 2018-10-25 Richard Biener <rguenther@suse.de>
944
945 * tree-vect-data-refs.c (vect_analyze_data_ref_accesses):
946 Initialize ng to silence error with release checking bootstrap.
947
948 2018-10-25 Richard Biener <rguenther@suse.de>
949
950 * tree-if-conv.c: Include tree-ssa-sccvn.h.
951 (tree_if_conversion): Run CSE on the if-converted loop body.
952
953 2018-10-25 Ilya Leoshkevich <iii@linux.ibm.com>
954
955 * config/s390/constraints.md (ZL): New constraint.
956 * config/s390/s390.c (legitimate_pic_operand_p): Accept LARL
957 operands.
958 * config/s390/s390.md (movdi_larl): Remove.
959 (movdi_64): Add the LARL alternative.
960
961 2018-10-25 Ilya Leoshkevich <iii@linux.ibm.com>
962
963 PR bootstrap/87747
964 * rtl.c (RTX_CODE_HWINT_P_1): New helper macro.
965 (RTX_CODE_HWINT_P): New macro.
966 (rtx_code_size): Use RTX_CODE_HWINT_P ().
967
968 2018-10-25 Jan Hubicka <jh@suse.cz>
969
970 * ipa-devirt.c (odr_types_equivalent_p): Do not ICE if one of types
971 is anonymous.
972
973 2018-10-25 Richard Biener <rguenther@suse.de>
974
975 PR tree-optimization/87665
976 PR tree-optimization/87745
977 * tree-vectorizer.h (get_earlier_stmt): Remove.
978 (get_later_stmt): Pick up UID from the original non-pattern stmt.
979
980 2018-10-25 Sam Tebbs <sam.tebbs@arm.com>
981
982 * options.texi (Deprecated): Move list to Var section.
983
984 2018-10-24 Bill Schmidt <wschmidt@linux.ibm.com>
985 Jinsong Ji <jji@us.ibm.com>
986
987 * config/rs6000/emmintrin.h (_mm_cvtpd_epi32): Change deprecated
988 __vector long to __vector long long.
989 (_mm_cvtpd_ps): Likewise.
990 (_mm_cvttpd_epi32): Likewise.
991 (_mm_cvtpi32_pd): Likewise.
992 (_mm_unpackhi_epi64): Likewise.
993 (_mm_unpacklo_epi64): Likewise.
994
995 2018-10-24 Segher Boessenkool <segher@kernel.crashing.org>
996
997 PR rtl-optimization/87720
998 * combine.c (make_more_copies): Skip if the dest is pc_rtx.
999
1000 2018-10-24 Alexandre Oliva <aoliva@redhat.com>
1001
1002 * gimple-ssa-isolate-paths.c
1003 (find_implicit_erroneous_behavior): Do not change code if the
1004 pass is running for warnings only.
1005 (find_explicit_erroneous_behavior): Likewise.
1006
1007 2018-10-24 Michael Meissner <meissner@linux.ibm.com>
1008
1009 * config/rs6000/rs6000.c (TARGET_MANGLE_DECL_ASSEMBLER_NAME):
1010 Define as rs6000_mangle_decl_assembler_name.
1011 (rs6000_mangle_decl_assembler_name): If the user switched from IBM
1012 long double to IEEE long double, switch the names of the long
1013 double built-in functions to be <func>f128 instead of <func>l.
1014
1015 2018-10-24 Martin Sebor <msebor@redhat.com>
1016
1017 * doc/extend.texi (nonnull): List no-argument form. Reference
1018 -fno-delete-null-pointer-checks and -fisolate-erroneous-paths-attribute.
1019
1020 2018-10-24 Richard Biener <rguenther@suse.de>
1021
1022 * tree-ssa-sccvn.c (do_rpo_vn): Free rpo_state.
1023
1024 2018-10-24 Martin Liska <mliska@suse.cz>
1025
1026 PR tree-optimization/84436
1027 * tree-switch-conversion.c (switch_conversion::contains_same_values_p):
1028 Remove.
1029 (switch_conversion::contains_linear_function_p): New.
1030 (switch_conversion::build_one_array): Support linear
1031 transformation on input.
1032 * tree-switch-conversion.h (struct switch_conversion): Add
1033 contains_linear_function_p declaration.
1034
1035 2018-10-24 Richard Biener <rguenther@suse.de>
1036
1037 * varasm.c (const_hash_1): Return hash of ADDR_EXPR
1038 if its argument is CONSTANT_CLASS_P.
1039
1040 2018-10-11 Jan Hubicka <hubicka@ucw.cz>
1041
1042 * ipa-utils.h (type_with_linkage_p): No longer check for TYPE_STUB_DECL;
1043 it is wrong for forward declarations.
1044
1045 2018-10-24 Ilya Leoshkevich <iii@linux.ibm.com>
1046
1047 * config/s390/s390.c (s390_check_qrst_address): Add the missing
1048 SYMBOL_REF_P () check.
1049
1050 2018-10-24 Richard Biener <rguenther@suse.de>
1051
1052 PR tree-optimization/87105
1053 * tree-vect-data-refs.c (vect_analyze_group_access_1): Adjust
1054 dump classification.
1055 (vect_analyze_data_ref_accesses): Handle duplicate loads and
1056 stores by splitting the affected group after the fact.
1057 * tree-vect-slp.c (vect_build_slp_tree_2): Dump when we
1058 fail the SLP build because of size constraints.
1059
1060 2018-10-24 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
1061
1062 * configure.ac (gcc_cv_ld_aligned_shf_merge): New test.
1063 * configure: Regenerate.
1064 * config.in: Regenerate.
1065 * varasm.c (mergeable_string_section): Use readonly_data_section
1066 if linker doesn't support SHF_MERGE with alignment > 8.
1067 (mergeable_constant_section): Likewise.
1068
1069 2018-10-24 Richard Biener <rguenther@suse.de>
1070
1071 PR tree-optimization/84013
1072 * tree-ssa-structalias.c (struct msdi_data): New struct for
1073 marshalling data to walk_stmt_load_store_ops.
1074 (maybe_set_dependence_info): Refactor as callback for
1075 walk_stmt_load_store_ops.
1076 (compute_dependence_clique): Set restrict info on all stmt kinds.
1077
1078 2018-10-24 Martin Liska <mliska@suse.cz>
1079
1080 * cgraph.c (cgraph_node::dump):
1081 Remove reduntant dumps and make tp_first_run dump more compact.
1082
1083 2018-10-24 Richard Biener <rguenther@suse.de>
1084
1085 PR tree-optimization/87665
1086 * tree-vect-data-refs.c (vect_preserves_scalar_order_p): Adjust
1087 to reflect reality.
1088
1089 2018-10-12 Jeff Law <law@redhat.com>
1090
1091 * config/h8300/h8300.c (h8300_expand_prologue): Fix stm generation
1092 for H8/S.
1093
1094 2018-10-23 Richard Biener <rguenther@suse.de>
1095
1096 * tree-vrp.c (add_assert_info): Guard dump_printf with
1097 dump_enabled_p.
1098 * gimple-ssa-evrp-analyze.c
1099 (evrp_range_analyzer::record_ranges_from_incoming_edge):
1100 Use value_range::ignore_equivs_equal_p.
1101
1102 2018-10-23 Richard Biener <rguenther@suse.de>
1103
1104 PR tree-optimization/87105
1105 PR tree-optimization/87608
1106 * passes.def (pass_all_early_optimizations): Add early phi-opt
1107 after dce.
1108 * tree-ssa-phiopt.c (value_replacement): Ignore NOPs and predicts in
1109 addition to debug stmts.
1110 (tree_ssa_phiopt_worker): Add early_p argument, do only min/max
1111 and abs replacement early.
1112 * tree-cfg.c (gimple_empty_block_p): Likewise.
1113
1114 2018-10-23 Richard Earnshaw <rearnsha@arm.com>
1115
1116 PR target/86383
1117 * config.gcc (arm*-*-netbsdelf*): Default to StrongARM if no CPU
1118 specified to configure.
1119 (arm*-*-*): Use ARM7TDMI as the target CPU if no default provided.
1120
1121 2018-10-23 Richard Biener <rguenther@suse.de>
1122
1123 PR tree-optimization/87700
1124 * tree-ssa-copy.c (set_copy_of_val): Fix change detection logic.
1125
1126 2018-10-23 Jakub Jelinek <jakub@redhat.com>
1127
1128 PR target/87674
1129 * config/i386/avx512vlintrin.h (_mm_mask_mullo_epi32): Change type of
1130 second argument from __mmask16 to __mmask8.
1131 * config/i386/avx512vlbwintrin.h (_mm_mask_packus_epi32,
1132 _mm_mask_packs_epi32): Likewise.
1133 * config/i386/avx512pfintrin.h (_mm512_mask_prefetch_i64scatter_ps):
1134 Likewise.
1135 (_mm512_mask_prefetch_i64scatter_pd): Likewise. Formatting fix.
1136
1137 2018-10-23 Richard Biener <rguenther@suse.de>
1138
1139 * tree-vect-stmts.c (vect_analyze_stmt): Fix typo in comment.
1140
1141 2018-10-23 Richard Biener <rguenther@suse.de>
1142
1143 PR tree-optimization/86144
1144 * tree-vect-stmts.c (vect_analyze_stmt): Prefer -mveclibabi
1145 over simd attribute.
1146
1147 2018-10-23 Richard Biener <rguenther@suse.de>
1148
1149 PR tree-optimization/87693
1150 * tree-ssa-threadedge.c (thread_around_empty_blocks): Handle
1151 the case we do not find the taken edge.
1152
1153 2018-10-22 Bill Schmidt <wschmidt@linux.ibm.com>
1154 Jinsong Ji <jji@us.ibm.com>
1155
1156 * config/rs6000/emmintrin.h (_MM_SHUFFLE2): Comment cleanup.
1157 (_mm_store_pd): Use unaligned vector type for pointer cast.
1158 (_mm_maskmoveu_si128): Likewise.
1159 * config/rs6000/xmmintrin.h (__m128_u): New typedef.
1160 (_mm_store_ps): Use unaligned vector type for pointer cast.
1161
1162 2018-10-22 Paul Koning <ni1d@arrl.net>
1163
1164 * symtab.c (symtab_node::increase_alignment): Correct max
1165 alignment check.
1166
1167 2018-10-22 Yury Gribov <tetra2005@gmail.com>
1168
1169 PR tree-optimization/87633
1170 * match.pd: Do not generate unordered integer comparisons.
1171
1172 2018-10-22 Segher Boessenkool <segher@kernel.crashing.org>
1173
1174 PR rtl-optimization/87600
1175 * combine.c: Add include of expr.h.
1176 (cant_combine_insn_p): Do not combine moves from any hard non-fixed
1177 register to a pseudo.
1178 (make_more_copies): New function, add a copy to a new pseudo after
1179 the moves from hard registers into pseudos.
1180 (rest_of_handle_combine): Declare rebuild_jump_labels_after_combine
1181 later. Call make_more_copies.
1182
1183 2018-10-22 Andrew Stubbs <ams@codesourcery.com>
1184
1185 * lra-constraints.c (process_alt_operands): New local array,
1186 matching_early_clobber. Check matching_early_clobber before
1187 decrementing reject, and set matching_early_clobber after.
1188
1189 2018-10-22 Segher Boessenkool <segher@kernel.crashing.org>
1190
1191 PR target/87598
1192 * config/rs6000/rs6000.c (print_operand_address): For unexpected RTL
1193 call output_addr_const and hope for the best.
1194
1195 2018-10-22 Richard Biener <rguenther@suse.de>
1196
1197 * gimple-ssa-evrp-analyze.c
1198 (evrp_range_analyzer::record_ranges_from_incoming_edge): Be
1199 smarter about what ranges to use.
1200 * tree-vrp.c (add_assert_info): Dump here.
1201 (register_edge_assert_for_2): Instead of here at multiple but
1202 not all places.
1203
1204 * gcc.dg/tree-ssa/evrp12.c: New testcase.
1205 * gcc.dg/predict-6.c: Adjust.
1206 * gcc.dg/tree-ssa/vrp33.c: Disable EVRP.
1207 * gcc.dg/tree-ssa/vrp02.c: Likewise.
1208 * gcc.dg/tree-ssa/cunroll-9.c: Likewise.
1209
1210 2018-10-22 Steven Bosscher <steven@gcc.gnu.org>
1211 Richard Biener <rguenther@suse.de>
1212
1213 * bitmap.h: Update data structure documentation, including a
1214 description of bitmap views as either linked-lists or splay trees.
1215 (struct bitmap_element_def): Update comments for splay tree bitmaps.
1216 (struct bitmap_head_def): Likewise.
1217 (bitmap_list_view, bitmap_tree_view): New prototypes.
1218 (bitmap_initialize_stat): Initialize a bitmap_head's indx and
1219 tree_form fields.
1220 (bmp_iter_set_init): Assert the iterated bitmaps are in list form.
1221 (bmp_iter_and_init, bmp_iter_and_compl_init): Likewise.
1222 * bitmap.c (bitmap_elem_to_freelist): Unregister overhead of a
1223 released bitmap element here.
1224 (bitmap_element_free): Remove.
1225 (bitmap_elt_clear_from): Work on splay tree bitmaps.
1226 (bitmap_list_link_element): Renamed from bitmap_element_link. Move
1227 this function similar ones such that linked-list bitmap implementation
1228 functions are grouped.
1229 (bitmap_list_unlink_element): Renamed from bitmap_element_unlink,
1230 and moved for grouping.
1231 (bitmap_list_insert_element_after): Renamed from
1232 bitmap_elt_insert_after, and moved for grouping.
1233 (bitmap_list_find_element): New function spliced from bitmap_find_bit.
1234 (bitmap_tree_link_left, bitmap_tree_link_right,
1235 bitmap_tree_rotate_left, bitmap_tree_rotate_right, bitmap_tree_splay,
1236 bitmap_tree_link_element, bitmap_tree_unlink_element,
1237 bitmap_tree_find_element): New functions for splay-tree bitmap
1238 implementation.
1239 (bitmap_element_link, bitmap_element_unlink, bitmap_elt_insert_after):
1240 Renamed and moved, see above entries.
1241 (bitmap_tree_listify_from): New function to convert part of a splay
1242 tree bitmap to a linked-list bitmap.
1243 (bitmap_list_view): Convert a splay tree bitmap to linked-list form.
1244 (bitmap_tree_view): Convert a linked-list bitmap to splay tree form.
1245 (bitmap_find_bit): Remove.
1246 (bitmap_clear, bitmap_clear_bit, bitmap_set_bit,
1247 bitmap_single_bit_set_p, bitmap_first_set_bit, bitmap_last_set_bit):
1248 Handle splay tree bitmaps.
1249 (bitmap_copy, bitmap_count_bits, bitmap_and, bitmap_and_into,
1250 bitmap_elt_copy, bitmap_and_compl, bitmap_and_compl_into,
1251 bitmap_compl_and_into, bitmap_elt_ior, bitmap_ior, bitmap_ior_into,
1252 bitmap_xor, bitmap_xor_into, bitmap_equal_p, bitmap_intersect_p,
1253 bitmap_intersect_compl_p, bitmap_ior_and_compl,
1254 bitmap_ior_and_compl_into, bitmap_set_range, bitmap_clear_range,
1255 bitmap_hash): Reject trying to act on splay tree bitmaps. Make
1256 corresponding changes to use linked-list specific bitmap_element
1257 manipulation functions as applicable for efficiency.
1258 (bitmap_tree_to_vec): New function.
1259 (debug_bitmap_elt_file): New function split out from ...
1260 (debug_bitmap_file): ... here. Handle splay tree bitmaps.
1261 (bitmap_print): Likewise.
1262
1263 PR tree-optimization/63155
1264 * tree-ssa-propagate.c (ssa_prop_init): Use tree-view for the
1265 SSA edge worklists.
1266 * tree-ssa-coalesce.c (coalesce_ssa_name): Populate used_in_copies
1267 in tree-view.
1268
1269 2018-10-22 Martin Liska <mliska@suse.cz>
1270
1271 PR tree-optimization/87686
1272 Revert
1273 2018-08-29 Martin Liska <mliska@suse.cz>
1274
1275 * tree-switch-conversion.c (switch_conversion::expand):
1276 Strenghten assumption about gswitch statements.
1277
1278 2018-10-22 Martin Liska <mliska@suse.cz>
1279
1280 * ipa-icf.c (sem_item::compare_attributes): Remove.
1281 (sem_item::compare_referenced_symbol_properties): Use
1282 attribute_list_equal instead.
1283 (sem_function::equals_wpa): Likewise.
1284 * ipa-icf.h: Remove compare_attributes.
1285
1286 2018-10-22 Richard Biener <rguenther@suse.de>
1287
1288 PR middle-end/87682
1289 * mem-stats.h (mem_usage::operator==): Fix pasto.
1290
1291 2018-10-22 Richard Biener <rguenther@suse.de>
1292
1293 PR tree-optimization/87640
1294 * tree-vrp.c (set_value_range_with_overflow): Decompose
1295 incomplete result.
1296 (extract_range_from_binary_expr_1): Adjust.
1297
1298 2018-10-22 Martin Jambor <mjambor@suse.cz>
1299
1300 * tree-eh.h (stmt_could_throw_p): Add function parameter.
1301 (stmt_can_throw_external): Likewise.
1302 (stmt_can_throw_internal): Likewise.
1303 * tree-eh.c (lower_eh_constructs_2): Pass cfun to stmt_could_throw_p.
1304 (lower_eh_constructs_2): Likewise.
1305 (stmt_could_throw_p): Add fun parameter, use it instead of cfun.
1306 (stmt_can_throw_external): Likewise.
1307 (stmt_can_throw_internal): Likewise.
1308 (maybe_clean_eh_stmt_fn): Pass cfun to stmt_could_throw_p.
1309 (maybe_clean_or_replace_eh_stmt): Pass cfun to stmt_could_throw_p.
1310 (maybe_duplicate_eh_stmt_fn): Pass new_fun to stmt_could_throw_p.
1311 (maybe_duplicate_eh_stmt): Pass cfun to stmt_could_throw_p.
1312 (pass_lower_eh_dispatch::execute): Pass cfun to
1313 stmt_can_throw_external.
1314 (cleanup_empty_eh): Likewise.
1315 (verify_eh_edges): Pass cfun to stmt_could_throw_p.
1316 * cgraph.c (cgraph_edge::set_call_stmt): Pass a function to
1317 stmt_can_throw_external instead of pushing it to cfun.
1318 (symbol_table::create_edge): Likewise.
1319 * gimple-fold.c (fold_builtin_atomic_compare_exchange): Pass cfun to
1320 stmt_can_throw_internal.
1321 * gimple-ssa-evrp.c (evrp_dom_walker::before_dom_children): Pass cfun
1322 to stmt_could_throw_p.
1323 * gimple-ssa-store-merging.c (handled_load): Pass cfun to
1324 stmt_can_throw_internal.
1325 (pass_store_merging::execute): Likewise.
1326 * gimple-ssa-strength-reduction.c
1327 (find_candidates_dom_walker::before_dom_children): Pass cfun to
1328 stmt_could_throw_p.
1329 * gimplify-me.c (gimple_regimplify_operands): Pass cfun to
1330 stmt_can_throw_internal.
1331 * ipa-pure-const.c (check_call): Pass cfun to stmt_could_throw_p and
1332 to stmt_can_throw_external.
1333 (check_stmt): Pass cfun to stmt_could_throw_p.
1334 (check_stmt): Pass cfun to stmt_can_throw_external.
1335 (pass_nothrow::execute): Likewise.
1336 * trans-mem.c (expand_call_tm): Pass cfun to stmt_can_throw_internal.
1337 * tree-cfg.c (is_ctrl_altering_stmt): Pass cfun to
1338 stmt_can_throw_internal.
1339 (verify_gimple_in_cfg): Pass cfun to stmt_could_throw_p.
1340 (stmt_can_terminate_bb_p): Pass cfun to stmt_can_throw_external.
1341 (gimple_purge_dead_eh_edges): Pass cfun to stmt_can_throw_internal.
1342 * tree-complex.c (expand_complex_libcall): Pass cfun to
1343 stmt_could_throw_p and to stmt_can_throw_internal.
1344 (expand_complex_multiplication): Pass cfun to stmt_can_throw_internal.
1345 * tree-inline.c (copy_edges_for_bb): Likewise.
1346 (maybe_move_debug_stmts_to_successors): Likewise.
1347 * tree-outof-ssa.c (ssa_is_replaceable_p): Pass cfun to
1348 stmt_could_throw_p.
1349 * tree-parloops.c (oacc_entry_exit_ok_1): Likewise.
1350 * tree-sra.c (scan_function): Pass cfun to stmt_can_throw_external.
1351 * tree-ssa-alias.c (stmt_kills_ref_p): Pass cfun to
1352 stmt_can_throw_internal.
1353 * tree-ssa-ccp.c (optimize_atomic_bit_test_and): Likewise.
1354 * tree-ssa-dce.c (mark_stmt_if_obviously_necessary): Pass cfun to
1355 stmt_could_throw_p.
1356 (mark_aliased_reaching_defs_necessary_1): Pass cfun to
1357 stmt_can_throw_internal.
1358 * tree-ssa-forwprop.c (pass_forwprop::execute): Likewise.
1359 * tree-ssa-loop-im.c (movement_possibility): Pass cfun to
1360 stmt_could_throw_p.
1361 * tree-ssa-loop-ivopts.c (find_givs_in_stmt_scev): Likewise.
1362 (add_autoinc_candidates): Pass cfun to stmt_can_throw_internal.
1363 * tree-ssa-math-opts.c (pass_cse_reciprocals::execute): Likewise.
1364 (convert_mult_to_fma_1): Likewise.
1365 (convert_to_divmod): Likewise.
1366 * tree-ssa-phiprop.c (propagate_with_phi): Likewise.
1367 * tree-ssa-pre.c (compute_avail): Pass cfun to stmt_could_throw_p.
1368 * tree-ssa-propagate.c
1369 (substitute_and_fold_dom_walker::before_dom_children): Likewise.
1370 * tree-ssa-reassoc.c (suitable_cond_bb): Likewise.
1371 (maybe_optimize_range_tests): Likewise.
1372 (linearize_expr_tree): Likewise.
1373 (reassociate_bb): Likewise.
1374 * tree-ssa-sccvn.c (copy_reference_ops_from_call): Likewise.
1375 * tree-ssa-scopedtables.c (hashable_expr_equal_p): Likewise.
1376 * tree-ssa-strlen.c (adjust_last_stmt): Likewise.
1377 (handle_char_store): Likewise.
1378 * tree-vect-data-refs.c (vect_find_stmt_data_reference): Pass cfun to
1379 stmt_can_throw_internal.
1380 * tree-vect-patterns.c (check_bool_pattern): Pass cfun to
1381 stmt_could_throw_p.
1382 * tree-vect-stmts.c (vect_finish_stmt_generation_1): Likewise.
1383 (vectorizable_call): Pass cfun to stmt_can_throw_internal.
1384 (vectorizable_simd_clone_call): Likewise.
1385 * value-prof.c (gimple_ic): Pass cfun to stmt_could_throw_p.
1386 (gimple_stringop_fixed_value): Likewise.
1387
1388 2018-10-22 Ilya Leoshkevich <iii@linux.ibm.com>
1389
1390 * config/s390/s390.c (s390_loadrelative_operand_p): Accept
1391 literal pool references.
1392 (s390_check_qrst_address): Adapt to the new behavior of
1393 s390_loadrelative_operand_p ().
1394
1395 2018-10-22 H.J. Lu <hongjiu.lu@intel.com>
1396
1397 PR target/72782
1398 * config/i386/sse.md (*andnot<mode>3_bcst): New.
1399
1400 2018-10-22 H.J. Lu <hongjiu.lu@intel.com>
1401
1402 PR target/72782
1403 * config/i386/sse.md (*<code><mode>3_bcst): New.
1404
1405 2018-10-22 H.J. Lu <hongjiu.lu@intel.com>
1406
1407 PR target/72782
1408 * config/i386/sse.md (avx512bcst): Updated for V4SI, V2DI, V8SI,
1409 V4DI, V16SI and V8DI.
1410 (*sub<mode>3<mask_name>_bcst): New.
1411 (*add<mode>3<mask_name>_bcst): Likewise.
1412
1413 2018-10-21 Bill Schmidt <wschmidt@linux.ibm.com>
1414 Jinsong Ji <jji@us.ibm.com>
1415
1416 * config/rs6000/emmintrin.h (_mm_movemask_pd): Replace __vector
1417 __m64 with __vector unsigned long long for compatibility.
1418 (_mm_movemask_epi8): Likewise.
1419 * config/rs6000/xmmintrin.h (_mm_cvtps_pi32): Likewise.
1420 (_mm_cvttps_pi32): Likewise.
1421 (_mm_cvtpi32_ps): Likewise.
1422 (_mm_cvtps_pi16): Likewise.
1423 (_mm_loadh_pi): Likewise.
1424 (_mm_storeh_pi): Likewise.
1425 (_mm_movehl_ps): Likewise.
1426 (_mm_movelh_ps): Likewise.
1427 (_mm_loadl_pi): Likewise.
1428 (_mm_storel_pi): Likewise.
1429 (_mm_movemask_ps): Likewise.
1430 (_mm_shuffle_pi16): Likewise.
1431
1432 2018-10-21 H.J. Lu <hongjiu.lu@intel.com>
1433
1434 PR target/72782
1435 * config/i386/avx512fintrin.h (_mm512_fnmsub_round_pd): Use
1436 __builtin_ia32_vfnmsubpd512_mask.
1437 (_mm512_mask_fnmsub_round_pd): Likewise.
1438 (_mm512_fnmsub_pd): Likewise.
1439 (_mm512_mask_fnmsub_pd): Likewise.
1440 (_mm512_maskz_fnmsub_round_pd): Use
1441 __builtin_ia32_vfnmsubpd512_maskz.
1442 (_mm512_maskz_fnmsub_pd): Likewise.
1443 (_mm512_fnmsub_round_ps): Use __builtin_ia32_vfnmsubps512_mask.
1444 (_mm512_mask_fnmsub_round_ps): Likewise.
1445 (_mm512_fnmsub_ps): Likewise.
1446 (_mm512_mask_fnmsub_ps): Likewise.
1447 (_mm512_maskz_fnmsub_round_ps): Use
1448 __builtin_ia32_vfnmsubps512_maskz.
1449 (_mm512_maskz_fnmsub_ps): Likewise.
1450 * config/i386/avx512vlintrin.h (_mm256_mask_fnmsub_pd): Use
1451 __builtin_ia32_vfnmsubpd256_mask.
1452 (_mm256_maskz_fnmsub_pd): Use __builtin_ia32_vfnmsubpd256_maskz.
1453 (_mm_mask_fnmsub_pd): Use __builtin_ia32_vfmaddpd128_mask
1454 (_mm_maskz_fnmsub_pd): Use __builtin_ia32_vfnmsubpd128_maskz.
1455 (_mm256_mask_fnmsub_ps): Use __builtin_ia32_vfnmsubps256_mask.
1456 (_mm256_mask_fnmsub_ps): Use __builtin_ia32_vfnmsubps256_mask.
1457 (_mm256_maskz_fnmsub_ps): Use __builtin_ia32_vfnmsubps256_maskz.
1458 (_mm_mask_fnmsub_ps): Use __builtin_ia32_vfnmsubps128_mask.
1459 (_mm_maskz_fnmsub_ps): Use __builtin_ia32_vfnmsubps128_maskz.
1460 * config/i386/fmaintrin.h (_mm_fnmsub_pd): Use
1461 __builtin_ia32_vfnmsubpd.
1462 (_mm256_fnmsub_pd): Use __builtin_ia32_vfnmsubpd256.
1463 (_mm_fnmsub_ps): Use __builtin_ia32_vfnmsubps.
1464 (_mm256_fnmsub_ps): Use __builtin_ia32_vfnmsubps256.
1465 (_mm_fnmsub_sd): Use __builtin_ia32_vfnmsubsd3.
1466 (_mm_fnmsub_ss): Use __builtin_ia32_vfnmsubss3.
1467 * config/i386/i386-builtin.def: Add
1468 __builtin_ia32_vfnmsubpd256_mask,
1469 __builtin_ia32_vfnmsubpd256_maskz,
1470 __builtin_ia32_vfnmsubpd128_mask,
1471 __builtin_ia32_vfnmsubpd128_maskz,
1472 __builtin_ia32_vfnmsubps256_mask,
1473 __builtin_ia32_vfnmsubps256_maskz,
1474 __builtin_ia32_vfnmsubps128_mask,
1475 __builtin_ia32_vfnmsubps128_maskz,
1476 __builtin_ia32_vfnmsubpd512_mask,
1477 __builtin_ia32_vfnmsubpd512_maskz,
1478 __builtin_ia32_vfnmsubps512_mask,
1479 __builtin_ia32_vfnmsubps512_maskz, __builtin_ia32_vfnmsubss3,
1480 __builtin_ia32_vfnmsubsd3, __builtin_ia32_vfnmsubps,
1481 __builtin_ia32_vfnmsubpd, __builtin_ia32_vfnmsubps256 and.
1482 __builtin_ia32_vfnmsubpd256.
1483 * config/i386/sse.md (fma4i_fnmsub_<mode>): New.
1484 (<avx512>_fnmsub_<mode>_maskz<round_expand_name>): Likewise.
1485 (*<sd_mask_codefor>fma_fnmsub_<mode><sd_maskz_name>_bcst_1):
1486 Likewise.
1487 (*<sd_mask_codefor>fma_fnmsub_<mode><sd_maskz_name>_bcst_2):
1488 Likewise.
1489 (*<sd_mask_codefor>fma_fnmsub_<mode><sd_maskz_name>_bcst_3):
1490 Likewise.
1491 (fmai_vmfnmsub_<mode><round_name>): Likewise.
1492
1493 2018-10-21 H.J. Lu <hongjiu.lu@intel.com>
1494
1495 PR target/72782
1496 * config/i386/avx512fintrin.h (_mm512_fnmadd_round_pd): Use
1497 __builtin_ia32_vfnmaddpd512_mask.
1498 (_mm512_mask_fnmadd_round_pd): Likewise.
1499 (_mm512_fnmadd_pd): Likewise.
1500 (_mm512_mask_fnmadd_pd): Likewise.
1501 (_mm512_maskz_fnmadd_round_pd): Use
1502 __builtin_ia32_vfnmaddpd512_maskz.
1503 (_mm512_maskz_fnmadd_pd): Likewise.
1504 (_mm512_fnmadd_round_ps): Use __builtin_ia32_vfnmaddps512_mask.
1505 (_mm512_mask_fnmadd_round_ps): Likewise.
1506 (_mm512_fnmadd_ps): Likewise.
1507 (_mm512_mask_fnmadd_ps): Likewise.
1508 (_mm512_maskz_fnmadd_round_ps): Use
1509 __builtin_ia32_vfnmaddps512_maskz.
1510 (_mm512_maskz_fnmadd_ps): Likewise.
1511 * config/i386/avx512vlintrin.h (_mm256_mask_fnmadd_pd): Use
1512 __builtin_ia32_vfnmaddpd256_mask.
1513 (_mm256_maskz_fnmadd_pd): Use __builtin_ia32_vfnmaddpd256_maskz.
1514 (_mm_mask_fnmadd_pd): Use __builtin_ia32_vfmaddpd128_mask
1515 (_mm_maskz_fnmadd_pd): Use __builtin_ia32_vfnmaddpd128_maskz.
1516 (_mm256_mask_fnmadd_ps): Use __builtin_ia32_vfnmaddps256_mask.
1517 (_mm256_mask_fnmadd_ps): Use __builtin_ia32_vfnmaddps256_mask.
1518 (_mm256_maskz_fnmadd_ps): Use __builtin_ia32_vfnmaddps256_maskz.
1519 (_mm_mask_fnmadd_ps): Use __builtin_ia32_vfnmaddps128_mask.
1520 (_mm_maskz_fnmadd_ps): Use __builtin_ia32_vfnmaddps128_maskz.
1521 * config/i386/fmaintrin.h (_mm_fnmadd_pd): Use
1522 __builtin_ia32_vfnmaddpd.
1523 (_mm256_fnmadd_pd): Use __builtin_ia32_vfnmaddpd256.
1524 (_mm_fnmadd_ps): Use __builtin_ia32_vfnmaddps.
1525 (_mm256_fnmadd_ps): Use __builtin_ia32_vfnmaddps256.
1526 (_mm_fnmadd_sd): Use __builtin_ia32_vfnmaddsd3.
1527 (_mm_fnmadd_ss): Use __builtin_ia32_vfnmaddss3.
1528 * config/i386/i386-builtin.def: Add
1529 __builtin_ia32_vfnmaddpd256_mask,
1530 __builtin_ia32_vfnmaddpd256_maskz,
1531 __builtin_ia32_vfnmaddpd128_mask,
1532 __builtin_ia32_vfnmaddpd128_maskz,
1533 __builtin_ia32_vfnmaddps256_mask,
1534 __builtin_ia32_vfnmaddps256_maskz,
1535 __builtin_ia32_vfnmaddps128_mask,
1536 __builtin_ia32_vfnmaddps128_maskz,
1537 __builtin_ia32_vfnmaddpd512_mask,
1538 __builtin_ia32_vfnmaddpd512_maskz,
1539 __builtin_ia32_vfnmaddps512_mask,
1540 __builtin_ia32_vfnmaddps512_maskz, __builtin_ia32_vfnmaddss3,
1541 __builtin_ia32_vfnmaddsd3, __builtin_ia32_vfnmaddps,
1542 __builtin_ia32_vfnmaddpd, __builtin_ia32_vfnmaddps256 and.
1543 __builtin_ia32_vfnmaddpd256.
1544 * config/i386/sse.md (fma4i_fnmadd_<mode>): New.
1545 (<avx512>_fnmadd_<mode>_maskz<round_expand_name>): Likewise.
1546 (*<sd_mask_codefor>fma_fnmadd_<mode><sd_maskz_name>_bcst_1):
1547 Likewise.
1548 (*<sd_mask_codefor>fma_fnmadd_<mode><sd_maskz_name>_bcst_2):
1549 Likewise.
1550 (*<sd_mask_codefor>fma_fnmadd_<mode><sd_maskz_name>_bcst_3):
1551 Likewise.
1552 (fmai_vmfnmadd_<mode><round_name>): Likewise.
1553
1554 2018-10-21 H.J. Lu <hongjiu.lu@intel.com>
1555
1556 PR target/72782
1557 * config/i386/avx512fintrin.h (_mm512_fmsub_round_pd): Use
1558 __builtin_ia32_vfmsubpd512_mask.
1559 (_mm512_mask_fmsub_round_pd): Likewise.
1560 (_mm512_fmsub_pd): Likewise.
1561 (_mm512_mask_fmsub_pd): Likewise.
1562 (_mm512_maskz_fmsub_round_pd): Use
1563 __builtin_ia32_vfmsubpd512_maskz.
1564 (_mm512_maskz_fmsub_pd): Likewise.
1565 (_mm512_fmsub_round_ps): Use __builtin_ia32_vfmsubps512_mask.
1566 (_mm512_mask_fmsub_round_ps): Likewise.
1567 (_mm512_fmsub_ps): Likewise.
1568 (_mm512_mask_fmsub_ps): Likewise.
1569 (_mm512_maskz_fmsub_round_ps): Use
1570 __builtin_ia32_vfmsubps512_maskz.
1571 (_mm512_maskz_fmsub_ps): Likewise.
1572 * config/i386/avx512vlintrin.h (_mm256_mask_fmsub_pd): Use
1573 __builtin_ia32_vfmsubpd256_mask.
1574 (_mm256_maskz_fmsub_pd): Use __builtin_ia32_vfmsubpd256_maskz.
1575 (_mm_mask_fmsub_pd): Use __builtin_ia32_vfmaddpd128_mask
1576 (_mm_maskz_fmsub_pd): Use __builtin_ia32_vfmsubpd128_maskz.
1577 (_mm256_mask_fmsub_ps): Use __builtin_ia32_vfmsubps256_mask.
1578 (_mm256_mask_fmsub_ps): Use __builtin_ia32_vfmsubps256_mask.
1579 (_mm256_maskz_fmsub_ps): Use __builtin_ia32_vfmsubps256_maskz.
1580 (_mm_mask_fmsub_ps): Use __builtin_ia32_vfmsubps128_mask.
1581 (_mm_maskz_fmsub_ps): Use __builtin_ia32_vfmsubps128_maskz.
1582 * config/i386/fmaintrin.h (_mm_fmsub_pd): Use
1583 __builtin_ia32_vfmsubpd.
1584 (_mm256_fmsub_pd): Use __builtin_ia32_vfmsubpd256.
1585 (_mm_fmsub_ps): Use __builtin_ia32_vfmsubps.
1586 (_mm256_fmsub_ps): Use __builtin_ia32_vfmsubps256.
1587 (_mm_fmsub_sd): Use __builtin_ia32_vfmsubsd3.
1588 (_mm_fmsub_ss): Use __builtin_ia32_vfmsubss3.
1589 * config/i386/i386-builtin.def: Add
1590 __builtin_ia32_vfmsubpd256_mask,
1591 __builtin_ia32_vfmsubpd256_maskz,
1592 __builtin_ia32_vfmsubpd128_mask,
1593 __builtin_ia32_vfmsubpd128_maskz,
1594 __builtin_ia32_vfmsubps256_mask,
1595 __builtin_ia32_vfmsubps256_maskz,
1596 __builtin_ia32_vfmsubps128_mask,
1597 __builtin_ia32_vfmsubps128_maskz,
1598 __builtin_ia32_vfmsubpd512_mask,
1599 __builtin_ia32_vfmsubpd512_maskz,
1600 __builtin_ia32_vfmsubps512_mask,
1601 __builtin_ia32_vfmsubps512_maskz, __builtin_ia32_vfmsubss3,
1602 __builtin_ia32_vfmsubsd3, __builtin_ia32_vfmsubps,
1603 __builtin_ia32_vfmsubpd, __builtin_ia32_vfmsubps256 and.
1604 __builtin_ia32_vfmsubpd256.
1605 * config/i386/sse.md (fma4i_fmsub_<mode>): New.
1606 (<avx512>_fmsub_<mode>_maskz<round_expand_name>): Likewise.
1607 (*<sd_mask_codefor>fma_fmsub_<mode><sd_maskz_name>_bcst_1):
1608 Likewise.
1609 (*<sd_mask_codefor>fma_fmsub_<mode><sd_maskz_name>_bcst_2):
1610 Likewise.
1611 (*<sd_mask_codefor>fma_fmsub_<mode><sd_maskz_name>_bcst_3):
1612 Likewise.
1613 (fmai_vmfmsub_<mode><round_name>): Likewise.
1614
1615 2018-10-21 H.J. Lu <hongjiu.lu@intel.com>
1616
1617 * config/i386/sse.md (*<plusminus_insn><mode>3<mask_name>_bcst_1):
1618 Remove plus. Renamed to ...
1619 (*sub<mode>3<mask_name>_bcst): This.
1620 (*add<mode>3<mask_name>_bcst_2): Renamede to ...
1621 (*add<mode>3<mask_name>_bcst): This.
1622
1623 2018-10-21 H.J. Lu <hongjiu.lu@intel.com>
1624
1625 PR target/72782
1626 * config/i386/sse.md (*mul<mode>3<mask_name>_bcst): New.
1627
1628 2018-10-21 H.J. Lu <hongjiu.lu@intel.com>
1629
1630 PR target/87662
1631 * i386/avx512vlintrin.h (_mm256_or_epi32): New.
1632 (_mm_or_epi32): Likewise.
1633 (_mm256_xor_epi32): Likewise.
1634 (_mm_xor_epi32): Likewise.
1635 (_mm256_or_epi64): Likewise.
1636 (_mm_or_epi64): Likewise.
1637 (_mm256_xor_epi64): Likewise.
1638 (_mm_xor_epi64): Likewise.
1639
1640 2018-10-20 H.J. Lu <hongjiu.lu@intel.com>
1641
1642 PR target/72782
1643 * config/i386/sse.md (*<avx512>_div<mode>3<mask_name>_bcst): New.
1644
1645 2018-10-20 Jakub Jelinek <jakub@redhat.com>
1646
1647 PR middle-end/87647
1648 * varasm.c (decode_addr_const): Handle COMPOUND_LITERAL_EXPR.
1649
1650 2018-10-20 Andreas Schwab <schwab@linux-m68k.org>
1651
1652 * doc/ux.texi: Move @section directly after @node.
1653
1654 2018-10-19 Jakub Jelinek <jakub@redhat.com>
1655
1656 PR middle-end/85488
1657 PR middle-end/87649
1658 * omp-low.c (check_omp_nesting_restrictions): Diagnose ordered without
1659 depend closely nested inside of loop with ordered clause with
1660 a parameter.
1661
1662 2018-10-19 David Malcolm <dmalcolm@redhat.com>
1663
1664 * Makefile.in (TEXI_GCCINT_FILES): Add ux.texi.
1665 * doc/gccint.texi: Include ux.texi and use it in top-level menu.
1666 * doc/ux.texi: New file.
1667
1668 2018-10-19 Segher Boessenkool <segher@kernel.crashing.org>
1669
1670 * config/rs6000/rs6000.h (REG_ALLOC_ORDER): Move 68 (that is, CR0) to
1671 be the first CR field allocated.
1672
1673 2018-10-19 Richard Biener <rguenther@suse.de>
1674
1675 PR target/87657
1676 * config/i386/i386.c (ix86_builtin_vectorization_cost): Use
1677 TYPE_VECTOR_SUBPARTS and avoid relying on vector mode.
1678
1679 2018-10-19 H.J. Lu <hongjiu.lu@intel.com>
1680
1681 PR target/72782
1682 * config/i386/sse.md
1683 (*<plusminus_insn><mode>3<mask_name>_bcst_1): New.
1684 (*add<mode>3<mask_name>_bcst_2): Likewise.
1685
1686 2018-10-19 H.J. Lu <hongjiu.lu@intel.com>
1687
1688 * config/i386/sse.md
1689 (*<sd_mask_codefor>fma_fmadd_<mode><sd_maskz_name>_bcst_1):
1690 Replace nonimmediate_operand with register_operand.
1691 (*<sd_mask_codefor>fma_fmadd_<mode><sd_maskz_name>_bcst_2):
1692 Likewise.
1693 (*<sd_mask_codefor>fma_fmadd_<mode><sd_maskz_name>_bcst_3):
1694 Likewise.
1695
1696 2018-10-19 Ilya Leoshkevich <iii@linux.ibm.com>
1697
1698 PR rtl-optimization/87596
1699 * lra-constraints.c (spill_hard_reg_in_range): Use INSN_P () +
1700 lra_get_insn_recog_data () instead of lra_insn_recog_data[]
1701 for instructions in FROM..TO range.
1702
1703 2018-10-19 Eric Botcazou <ebotcazou@adacore.com>
1704
1705 * cfgexpand.c (expand_one_var): Use specific wording in error message
1706 for non-local frame variables.
1707 * stor-layout.c (layout_decl): Do not issue a warning for them.
1708
1709 2018-10-19 Robin Dapp <rdapp@linux.ibm.com>
1710
1711 * haifa-sched.c (priority): Add force_recompute parameter.
1712 (apply_replacement): Call priority () with force_recompute = true.
1713 (restore_pattern): Likewise.
1714
1715 2018-10-18 H.J. Lu <hongjiu.lu@intel.com>
1716
1717 * simplify-rtx.c (simplify_subreg): Limit mask of vec_merge to
1718 HOST_BITS_PER_WIDE_INT.
1719 (test_vector_ops_duplicate): Likewise.
1720
1721 2018-10-18 H.J. Lu <hongjiu.lu@intel.com>
1722
1723 PR target/72782
1724 * config/i386/sse.md (VF_AVX512): New.
1725 (avx512bcst): Likewise.
1726 (*<sd_mask_codefor>fma_fmadd_<mode><sd_maskz_name>_bcst_1):
1727 Likewise.
1728 (*<sd_mask_codefor>fma_fmadd_<mode><sd_maskz_name>_bcst_2):
1729 Likewise.
1730 (*<sd_mask_codefor>fma_fmadd_<mode><sd_maskz_name>_bcst_3):
1731 Likewise.
1732
1733 2018-10-18 Jonathan Wakely <jwakely@redhat.com>
1734
1735 * doc/invoke.texi (-dumpversion): Improve grammar.
1736 (-dumpfullversion): Make more consistent with -dumpversion.
1737
1738 2018-10-18 Uros Bizjak <ubizjak@gmail.com>
1739
1740 * config/i386/i386.c (ix86_emit_fp_unordered_jump):
1741 Set JUMP_LABEL to the jump insn.
1742 (ix86_emit_i387_log1p): Use ix86_expand_branch to expand branch.
1743 Predict emitted jump and add label to jump insn.
1744
1745 2018-10-18 David Malcolm <dmalcolm@redhat.com>
1746
1747 PR tree-optimization/87562
1748 * input.c (get_substring_ranges_for_loc): Use
1749 LRK_SPELLING_LOCATION rather than LRK_MACRO_EXPANSION_POINT when
1750 getting the linemap for the endpoint. Verify that it's either
1751 in the same linemap as the start point's spelling location, or
1752 at least in the same file.
1753
1754 2018-10-18 Richard Biener <rguenther@suse.de>
1755
1756 * config/i386/i386.c (ix86_builtin_vectorization_cost): Do not
1757 feed width-specific load/store costs through ix86_vec_cost.
1758 * config/i386/x86-tune-costs.h (athlon_cost): Adjust.
1759 (k8_cost): Likewise.
1760 (bdver_cost): Likewise.
1761 (znver1_cost): Likewise.
1762 (btver1_cost): Likewise.
1763 (btver2_cost): Likewise.
1764
1765 2018-10-18 H.J. Lu <hongjiu.lu@intel.com>
1766
1767 * simplify-rtx.c (simplify_subreg): Call simplify_gen_subreg
1768 to simplify subreg of vec_merge.
1769
1770 2018-10-18 Richard Biener <rguenther@suse.de>
1771
1772 * config/i386/i386.c: Fix costing of vector FMA.
1773
1774 2018-10-18 Richard Biener <rguenther@suse.de>
1775
1776 * config/i386/i386.c (ix86_vec_cost): Remove !parallel path
1777 and argument.
1778 (ix86_builtin_vectorization_cost): For vec_construct properly
1779 cost insertion into SSE regs.
1780 (...): Adjust calls to ix86_vec_cost.
1781
1782 2018-10-18 Richard Biener <rguenther@suse.de>
1783
1784 PR middle-end/87087
1785 Revert
1786 2018-02-07 Richard Biener <rguenther@suse.de>
1787
1788 PR tree-optimization/84204
1789 * tree-chrec.c (chrec_fold_plus_1): Remove size limiting in
1790 this place.
1791
1792 2018-10-18 H.J. Lu <hongjiu.lu@intel.com>
1793
1794 PR target/87537
1795 * simplify-rtx.c (simplify_subreg): Simplify subreg of vec_merge
1796 of vec_duplicate.
1797 (test_vector_ops_duplicate): Add test for a scalar subreg of a
1798 VEC_MERGE of a VEC_DUPLICATE.
1799
1800 2018-10-17 Joseph Myers <joseph@codesourcery.com>
1801
1802 * doc/cpp.texi (__STDC_VERSION__): Document C2X handling.
1803 * doc/invoke.texi (-std=c2x, -std=gnu2x): Document new options.
1804 * doc/standards.texi (C Language): Document C2X.
1805 * dwarf2out.c (highest_c_language), config/rl78/rl78.c
1806 (rl78_option_override): Handle "GNU C2X" language name.
1807
1808 2018-10-17 Joseph Myers <joseph@codesourcery.com>
1809
1810 * doc/invoke.texi (-std=c17), doc/standards.texi (C Language):
1811 Document C17 as published in 2018.
1812
1813 2018-10-17 Eric Botcazou <ebotcazou@adacore.com>
1814
1815 PR middle-end/87623
1816 * fold-const.c (fold_truth_andor_1): If the right side is not constant,
1817 bail out if both sides do not have the same storage order.
1818
1819 2018-10-17 Aldy Hernandez <aldyh@redhat.com>
1820
1821 * bitmap.c (bitmap_head::dump): New.
1822 * bitmap.h (bitmap_head): Add dump().
1823 * gimple-ssa-evrp-analyze.c
1824 (evrp_range_analyzer::try_find_new_range): Adjust for value_range API.
1825 (evrp_range_analyzer::set_ssa_range_info): Same.
1826 (evrp_range_analyzer::record_ranges_from_phis): Same.
1827 (evrp_range_analyzer::record_ranges_from_stmt): Same.
1828 * gimple-ssa-evrp.c (evrp_dom_walker::before_dom_children): Same.
1829 * gimple-ssa-sprintf.c (get_int_range): Same.
1830 (format_integer): Same.
1831 (sprintf_dom_walker::handle_gimple_call): Same.
1832 * ipa-cp.c (ipcp_vr_lattice::meet_with_1): Same.
1833 (ipcp_vr_lattice::top_p): Same.
1834 (ipcp_vr_lattice::bottom_p): Same.
1835 (ipcp_vr_lattice::set_to_bottom): Same.
1836 (ipa_vr_operation_and_type_effects): Same.
1837 (propagate_vr_across_jump_function): Same.
1838 (ipcp_store_vr_results): Same.
1839 * ipa-prop.c (struct ipa_vr_ggc_hash_traits): Same.
1840 (ipa_print_node_jump_functions_for_edge): Same.
1841 (ipa_get_value_range): Same.
1842 (ipa_compute_jump_functions_for_edge): Same.
1843 (ipa_write_jump_function): Same.
1844 * tree-ssa-dom.c (simplify_stmt_for_jump_threading): Same.
1845 * tree-ssa-threadedge.c (record_temporary_equivalences_from_phis):
1846 Same.
1847 * vr-values.c (set_value_range_to_nonnegative): Same.
1848 (set_value_range_to_truthvalue): Same.
1849 (vr_values::get_value_range): Same.
1850 (vr_values::set_defs_to_varying): Same.
1851 (vr_values::update_value_range): Same.
1852 (symbolic_range_based_on_p): Same.
1853 (vr_values::op_with_boolean_value_range_p): Same.
1854 (vr_values::extract_range_for_var_from_comparison_expr): Same.
1855 (vr_values::extract_range_from_ssa_name): Same.
1856 (vr_values::extract_range_from_binary_expr): Same.
1857 (vr_values::extract_range_from_unary_expr): Same.
1858 (vr_values::extract_range_from_cond_expr): Same.
1859 (vr_values::extract_range_from_comparison): Same.
1860 (vr_values::check_for_binary_op_overflow): Same.
1861 (vr_values::extract_range_basic): Same.
1862 (vr_values::extract_range_from_assignment): Same.
1863 (compare_ranges): Same.
1864 (compare_range_with_value): Same.
1865 (vr_values::adjust_range_with_scev): Same.
1866 (vrp_valueize): Same.
1867 (vrp_valueize_1): Same.
1868 (vr_values::get_vr_for_comparison): Same.
1869 (vr_values::compare_name_with_value): Same.
1870 (vr_values::compare_names): Same.
1871 (vr_values::vrp_evaluate_conditional): Same.
1872 (find_case_label_ranges): Same.
1873 (vr_values::vrp_visit_switch_stmt): Same.
1874 (vr_values::extract_range_from_phi_node): Same.
1875 (vr_values::simplify_div_or_mod_using_ranges): Same.
1876 (vr_values::simplify_bit_ops_using_ranges): Same.
1877 (test_for_singularity): Same.
1878 (range_fits_type_p): Same.
1879 (vr_values::simplify_cond_using_ranges_1): Same.
1880 (vr_values::simplify_switch_using_ranges): Same.
1881 (vr_values::simplify_float_conversion_using_ranges): Same.
1882 (vr_values::two_valued_val_range_p): Same.
1883 (vr_values::add_equivalence): Move to value_range::equiv_add.
1884 * vr-values.h (vr_values::add_equivalence): Remove.
1885 (VR_INITIALIZER): Remove.
1886 * tree-vrp.c (value_range::set): New.
1887 (value_range::equiv_add): New.
1888 (value_range::value_range): New.
1889 (value_range::deep_copy): New.
1890 (value_range::check): New.
1891 (value_range::equal_p): New.
1892 (value_range::ignore_equivs_equal_p): New.
1893 (value_range::operator==): New.
1894 (value_range::operator!=): New.
1895 (value_range::symbolic_p): New.
1896 (value_range::numeric_p): New.
1897 (value_range::set_undefined): New.
1898 (value_range::set_varying): New.
1899 (value_range::may_contain_p): New.
1900 (value_range::equiv_clear): New.
1901 (value_range::singleton_p): New.
1902 (value_range::intersect): New.
1903 (value_range::dump): New.
1904 (value_range::set_and_canonicalize): New.
1905 (set_value_range): Adjust for value_range API.
1906 (set_value_range_to_undefined): Same.
1907 (set_value_range_to_varying): Same.
1908 (set_and_canonicalize_value_range): Same.
1909 (set_value_range_to_nonnull): Same.
1910 (set_value_range_to_null): Same.
1911 (range_is_null): Same.
1912 (range_is_nonnull): Same.
1913 (range_int_cst_p): Same.
1914 (range_int_cst_singleton_p): Same.
1915 (symbolic_range_p): Same.
1916 (range_includes_zero_p): Same.
1917 (value_range_constant_singleton): Same.
1918 (vrp_set_zero_nonzero_bits): Same.
1919 (ranges_from_anti_range): Same.
1920 (extract_range_into_wide_ints): Same.
1921 (extract_range_from_multiplicative_op): Same.
1922 (set_value_range_with_overflow): Same.
1923 (extract_range_from_binary_expr_1): Same.
1924 (extract_range_from_unary_expr): Same.
1925 (dump_value_range): Same.
1926 (debug_value_range): Same.
1927 (vrp_prop::check_array_ref): Same.
1928 (vrp_prop::check_mem_ref): Same.
1929 (vrp_prop::vrp_initialize): Same.
1930 (vrp_prop::visit_stmt): Same.
1931 (intersect_ranges): Same.
1932 (vrp_prop::visit_phi): Same.
1933 (vrp_prop::vrp_finalize): Same.
1934 (determine_value_range_1): Same.
1935 (determine_value_range): Same.
1936 (vrp_intersect_ranges_1): Rename to...
1937 (vrp_intersect_1): this.
1938 (vrp_intersect_ranges): Rename to...
1939 (value_range::intersect_helper): ...this.
1940 (vrp_meet_1): Rename to...
1941 (value_range::union_helper): ...this.
1942 (vrp_meet): Rename to...
1943 (value_range::union_): ...this.
1944 (copy_value_range): Remove.
1945 * tree-vrp.h (struct value_range): Rewrite into a proper class.
1946 (value_range::vrtype): New.
1947 (value_range::type): New.
1948 (value_range::equiv): New.
1949 (value_range::min): New.
1950 (value_range::max): New.
1951 (value_range::varying_p): New.
1952 (value_range::undefined_p): New.
1953 (value_range::null_p): New.
1954 (value_range::equiv_add): New.
1955 (copy_value_range): Remove.
1956
1957 2018-10-17 David Malcolm <dmalcolm@redhat.com>
1958
1959 * Makefile.in (SELFTEST_TARGETS): New.
1960 (selftest) Change from s-selftest-c to $(SELFTEST_TARGETS).
1961 (C_SELFTEST_FLAGS, C_SELFTEST_DEPS, s-selftest-c, selftest-c-gdb)
1962 (selftest-gdb, selftest-c-valgrind, selftest-valgrind): Move to
1963 c/Make-lang.in.
1964 (CPP_SELFTEST_FLAGS, CPP_SELFTEST_DEPS, s-selftest-c++)
1965 (selftest-c++-gdb, selftest-c++-valgrind): Move to
1966 cp/Make-lang.in.
1967 * configure: Regenerate.
1968 * configure.ac (selftest_languages): New.
1969
1970 2018-10-17 Aldy Hernandez <aldyh@redhat.com>
1971
1972 * tree-vrp.c (extract_range_from_multiplicative_op): Remove
1973 overflow wraps argument.
1974 (extract_range_from_binary_expr_1): Do not pass overflow wraps to
1975 wide_int_range_multiplicative_op.
1976 * wide-int-range.cc (wide_int_range_mult_wrapping): Remove
1977 overflow wraps argument.
1978 (wide_int_range_multiplicative_op): Same.
1979 (wide_int_range_lshift): Same.
1980 (wide_int_range_div): Same.
1981 * wide-int-range.h (wide_int_range_multiplicative_op): Same.
1982 (wide_int_range_lshift): Same.
1983 (wide_int_range_div): Same.
1984
1985 2018-10-17 Aldy Hernandez <aldyh@redhat.com>
1986
1987 * wide-int-range.h (wide_int_range_shift_undefined_p): Adjust to
1988 use sign as argument.
1989 * tree-vrp.c (extract_range_from_binary_expr_1): Pass sign to
1990 wide_int_range_shift_undefined_p.
1991
1992 2018-10-16 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
1993
1994 * config/aarch64/aarch64.md (despeculate_copy<ALLI_TI:mode>):
1995 Rename to...
1996 (@despeculate_copy<ALLI_TI:mode>): ... This.
1997 * config/aarch64/aarch64.c (aarch64_speculation_safe_value): Remove
1998 switch statement.
1999
2000 2018-10-16 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
2001
2002 * config.gcc: Obsolete *-*-solaris2.10*.
2003 * doc/install.texi (Specific, *-*-solaris2*): Document it.
2004
2005 2018-10-12 Jeff Law <law@redhat.com>
2006
2007 * config/ft32/ft32.md (ft32_general_movsrc_operand): Disable
2008 reg + sym +- const_int addressing modes.
2009
2010 2018-10-15 David Malcolm <dmalcolm@redhat.com>
2011
2012 * common.opt (fdiagnostics-minimum-margin-width=): New option.
2013 * diagnostic-show-locus.c (layout::layout): Apply the minimum
2014 margin width.
2015 (layout::start_annotation_line): Only print up to 3 of the
2016 margin character, to avoid touching the left-hand side.
2017 (selftest::test_diagnostic_show_locus_fixit_lines): Update for
2018 minimum margin width, as set by test_diagnostic_context's ctor.
2019 (selftest::test_fixit_insert_containing_newline): Likewise.
2020 (selftest::test_fixit_insert_containing_newline_2): Likewise.
2021 (selftest::test_line_numbers_multiline_range): Clear
2022 dc.min_margin_width.
2023 * diagnostic.c (diagnostic_initialize): Initialize
2024 min_margin_width.
2025 * diagnostic.h (struct diagnostic_context): Add field
2026 "min_margin_width".
2027 * doc/invoke.texi: Add -fdiagnostics-minimum-margin-width=.
2028 * opts.c (common_handle_option): Handle
2029 OPT_fdiagnostics_minimum_margin_width_.
2030 * selftest-diagnostic.c
2031 (selftest::test_diagnostic_context::test_diagnostic_context):
2032 Initialize min_margin_width to 6.
2033 * toplev.c (general_init): Initialize global_dc->min_margin_width.
2034
2035 2018-10-15 David Malcolm <dmalcolm@redhat.com>
2036
2037 * gcc-rich-location.h (gcc_rich_location::add_location_if_nearby):
2038 Fix usage of "error_at_rich_loc" in the comment.
2039
2040 2018-10-15 Renlin Li <renlin.li@arm.com>
2041
2042 PR target/87563
2043 * tree-vectorizer.c (try_vectorize_loop_1): Don't use
2044 if-conversioned loop when it contains ifn with types not
2045 supported by backend.
2046 * internal-fn.c (expand_direct_optab_fn): Add an assert.
2047 (direct_internal_fn_supported_p): New helper function.
2048 * internal-fn.h (direct_internal_fn_supported_p): Declare.
2049
2050 2018-10-15 Jakub Jelinek <jakub@redhat.com>
2051
2052 PR target/87572
2053 * common/config/i386/i386-common.c (OPTION_MASK_ISA_AVX512F_UNSET):
2054 Remove OPTION_MASK_ISA_AVX5124FMAPS_UNSET and
2055 OPTION_MASK_ISA_AVX5124VNNIW_UNSET.
2056
2057 2018-10-15 Bin Cheng <bin.cheng@linux.alibaba.com>
2058
2059 PR tree-optimization/87022
2060 * tree-loop-distribution.c (pg_add_dependence_edges): Check all
2061 bits in dist vector rather than the first one.
2062
2063 2018-10-15 Richard Biener <rguenther@suse.de>
2064
2065 PR middle-end/87610
2066 * tree-ssa-structalias.c (struct vls_data): Add escaped_p member.
2067 (visit_loadstore): When a used restrict tag escaped verify that
2068 the points-to solution of "other" pointers do not include
2069 escaped.
2070 (compute_dependence_clique): If a used restrict tag escaped
2071 communicated that down to visit_loadstore.
2072
2073 2018-10-15 Andreas Krebbel <krebbel@linux.ibm.com>
2074
2075 * config/s390/s390.c (s390_expand_vec_init): Force vector element
2076 into reg if it isn't a general operand.
2077
2078 2018-10-14 H.J. Lu <hongjiu.lu@intel.com>
2079
2080 PR target/87599
2081 * config/i386/sse.md (*vec_dupv2di): Add register source to
2082 movddup.
2083
2084 2018-10-14 H.J. Lu <hongjiu.lu@intel.com>
2085
2086 PR target/87572
2087 * common/config/i386/i386-common.c (OPTION_MASK_ISA_AVX512F_UNSET):
2088 Add OPTION_MASK_ISA_AVX512IFMA_UNSET,
2089 OPTION_MASK_ISA_AVX5124FMAPS_UNSET and
2090 OPTION_MASK_ISA_AVX5124VNNIW_UNSET.
2091
2092 2018-10-13 Eric Botcazou <ebotcazou@adacore.com>
2093
2094 * dwarf2cfi.c (struct dw_trace_info): Add args_size_defined_for_eh.
2095 (notice_args_size): Set it in the current trace if no insn that can
2096 throw internally has been seen yet.
2097 (connect_traces): When connecting args_size between traces, allow the
2098 incoming values not to match if there is an insn setting it before the
2099 first insn that can throw internally; in that case, force the creation
2100 of a CFI note on this latter insn.
2101
2102 2018-10-13 Jonathan Wakely <jwakely@redhat.com>
2103
2104 * opt-problem.h (opt_wrapper): Use template-argument-list when naming
2105 the base class, because using the injected-class-name was not clearly
2106 specified until DR 176.
2107
2108 2018-10-12 Paul Koning <ni1d@arrl.net>
2109
2110 * config/pdp11/pdp11.md (doloop_end): New expander.
2111 (doloop_end_insn): renamed from "doloop_end".
2112 (addqi3): New pattern.
2113 (subqi3): New pattern.
2114 * config/pdp11/predicates.md (incdec_operand): New predicate.
2115
2116 2018-10-12 Yury Gribov <tetra2005@gmail.com>
2117
2118 PR middle-end/81376
2119 * real.c (format_helper::can_represent_integral_type_p): New function
2120 * real.h (format_helper::can_represent_integral_type_p): Ditto.
2121 * match.pd: New pattern.
2122
2123 2018-10-12 Alexandre Oliva <oliva@adacore.com>
2124
2125 * configure.ac: Introduce --enable-large-address-aware
2126 to define MINGW_DEFAULT_LARGE_ADDR_AWARE.
2127 * doc/install.texi: Document it.
2128 * configure, config.in: Rebuilt.
2129 * config/i386/mingw32.h (LINK_SPEC_LARGE_ADDR_AWARE): Define,
2130 based on MINGW_DEFAULT_LARGE_ADDR_AWARE.
2131 (LINK_SPEC): Insert it.
2132 * config/i386/mingw-w64.h: Likewise.
2133
2134 * cygming.h (HAVE_GAS_ALIGNED_COMM): Fallback-define.
2135
2136 2018-10-12 Peter Bergner <bergner@linux.ibm.com>
2137
2138 PR rtl-optimization/87600
2139 * ira-lives (non_conflicting_reg_copy_p): Disable for non LRA targets.
2140
2141 2018-10-12 Paul Koning <ni1d@arrl.net>
2142
2143 * doc/md.texi (doloop_end): Document that the pattern code may
2144 need to check operand mode.
2145
2146 2018-10-12 Wilco Dijkstra <wdijkstr@arm.com>
2147
2148 * config/aarch64/aarch64.md (zero_extendsidi2_aarch64): Add alternatives
2149 to zero-extend between int and floating-point registers.
2150 (load_pair_zero_extendsidi2_aarch64): Add alternative for zero-extended
2151 ldp into floating-point registers. Add type and arch attributes.
2152 (zero_extend<SHORT:mode><GPI:mode>2_aarch64): Add arch attribute.
2153 Use f_loads for type attribute.
2154
2155 2018-10-11 Martin Sebor <msebor@redhat.com>
2156
2157 * doc/extend.texi (attribute packed): Correct typos.
2158
2159 2018-10-11 Martin Sebor <msebor@redhat.com>
2160
2161 * doc/extend.texi (attribute flatten): Mention interaction with
2162 noinline.
2163
2164 2018-10-11 Jan Hubicka <hubicka@ucw.cz>
2165
2166 PR target/87156
2167 * cgraphclones.c (cgraph_node::create_version_clone_with_body):
2168 Set new_decl virtual flag to zero.
2169
2170 2018-10-11 Martin Sebor <msebor@redhat.com>
2171
2172 PR middle-end/87593
2173 * doc/extend.texi (attribute format_arg): Discuss using multiple
2174 attributes on a single function.
2175
2176 2018-10-11 Giuliano Belinassi <giuliano.belinassi@usp.br>
2177
2178 PR tree-optimization/86829
2179 * match.pd (sin (atan (x))): New simplification rules.
2180 (cos (atan (x))): Likewise.
2181 * real.c (build_sinatan_real): New function.
2182 * real.h (build_sinatan_real): Prototype.
2183
2184 2018-10-11 Will Schmidt <will_schmidt@vnet.ibm.com>
2185
2186 * config/rs6000/rs6000.c (map_to_integral_tree_type): New helper
2187 function.
2188 (fold_mergeeo_helper): New helper function.
2189 (rs6000_gimple_fold_builtin): Add hooks for vec_mergee and vec_mergeo
2190 intrinsics. Correct some whitespace indentation issues.
2191
2192 2018-10-11 Wilco Dijkstra <wdijkstr@arm.com>
2193
2194 PR target/87511
2195 * config/aarch64/aarch64.c (aarch64_mask_and_shift_for_ubfiz_p):
2196 Use HOST_WIDE_INT_1U for shift.
2197
2198 2018-10-11 Doug Rupp <rupp@adacore.com>
2199 Olivier Hainque <hainque@adacore.com>
2200
2201 * config/rs6000/vxworks.h (VXWORKS_RELAX_LINK_SPEC): New macro.
2202 Pass --relax to the linker for RTPs.
2203 (LINK_SPEC): Append VXWORKS_RELAX_LINK_SPEC.
2204
2205 2018-10-11 Andrew Stubbs <ams@codesourcery.com>
2206 Jan Hubicka <jh@suse.cz>
2207 Martin Jambor <mjambor@suse.cz>
2208
2209 * print-rtl.c (print_rtx_operand_codes_E_and_V): Print how many times
2210 the same elements are repeated rather than printing all of them.
2211 * read-rtl.c (rtx_reader::read_rtx_operand): Recognize and expand
2212 "repeated" elements.
2213 * read-rtl-function.c (test_loading_repeat): New function.
2214 (read_rtl_function_c_tests): Call test_loading_repeat.
2215 * rtl-tests.c (test_dumping_repeat): New function.
2216 (rtl_tests_c_tests): Call test_dumping_repeat.
2217
2218 2018-10-11 Richard Biener <rguenther@suse.de>
2219
2220 * config/i386/x86-tune-costs.h (bdver?_memcpy, bdver?_memset,
2221 bdver?_cost): Unify to ...
2222 (bdver_memcpy, bdver_memset, bdver_cost): ... this.
2223 * config/i386/i386.c (processor_cost_table): Adjust.
2224
2225 2018-10-10 Eric Botcazou <ebotcazou@adacore.com>
2226
2227 PR middle-end/87574
2228 * cgraphunit.c (cgraph_node::expand_thunk): Force DECL_IGNORED_P on
2229 the thunk when expanding to GIMPLE.
2230
2231 2018-10-10 Bernd Edlinger <bernd.edlinger@hotmail.de>
2232
2233 * varasm.c (mergeable_string_section): Don't try to move zero-length
2234 strings to the merge section.
2235
2236 2018-10-10 Uros Bizjak <ubizjak@gmail.com>
2237
2238 PR target/87573
2239 * config/i386/mmx.md (const_vector 0 -> mem splitter): New splitter.
2240
2241 2018-10-10 Jakub Jelinek <jakub@redhat.com>
2242
2243 PR target/87550
2244 * config/i386/i386-builtin.def (IX86_BUILTIN_RDPMC): Move from args set
2245 to special_args set.
2246
2247 2018-10-10 Richard Biener <rguenther@suse.de>
2248
2249 * config/i386/sse.md (reduc_plus_scal_v8df, reduc_plus_scal_v4df,
2250 reduc_plus_scal_v2df, reduc_plus_scal_v16sf, reduc_plus_scal_v8sf,
2251 reduc_plus_scal_v4sf): Merge into pattern reducing to half width
2252 and recursing and pattern terminating the recursion on SSE
2253 vector width using ix86_expand_reduc.
2254 (reduc_sminmax_scal_<mode>): Split into part reducing to half
2255 width and recursing and SSE2 vector variant doing the final
2256 reduction with ix86_expand_reduc.
2257 (reduc_uminmax_scal_<mode>): Likewise for the AVX512 variants
2258 with terminating the recursion at AVX level, splitting that
2259 to SSE there.
2260
2261 2018-10-09 David Malcolm <dmalcolm@redhat.com>
2262
2263 * genmatch.c (error_cb): Rename to...
2264 (diagnostic_cb): ...this, converting int params to enums.
2265 (fatal_at): Update for renaming.
2266 (warning_at): Likewise.
2267 (main): Likewise.
2268 * input.c (selftest::ebcdic_execution_charset::apply):
2269 Update for renaming of...
2270 (selftest::ebcdic_execution_charset::on_error): ...this, renaming
2271 to...
2272 (selftest::ebcdic_execution_charset::on_diagnostic): ...this,
2273 converting level and reason to enums.
2274 (class selftest::lexer_error_sink): Rename to...
2275 (class selftest::lexer_test_options): ...this, renaming field
2276 "m_errors" to "m_diagnostics".
2277 (selftest::lexer_test_options::apply): Update for renaming of...
2278 (selftest::lexer_test_options::on_error): ...this, renaming to...
2279 (selftest::lexer_test_options::on_diagnostic): ...this
2280 converting level and reason to enums.
2281 (selftest::test_lexer_string_locations_raw_string_unterminated):
2282 Update for renamings.
2283 * opth-gen.awk (struct cpp_reason_option_codes_t): Use enum for
2284 "reason".
2285
2286 2018-10-09 Paul A. Clarke <pc@us.ibm.com>
2287
2288 * config.gcc (powerpc*-*-*): Add pmmintrin.h to extra_headers.
2289 * config/rs6000/pmmintrin.h: New file.
2290
2291 2018-10-09 Eric Botcazou <ebotcazou@adacore.com>
2292
2293 PR tree-optimization/86659
2294 * gimple-match.h (gimple_match_op constructors): Initialize reverse.
2295
2296 2018-10-09 Richard Biener <rguenther@suse.de>
2297
2298 PR tree-optimization/63155
2299 * tree-ssa-structalias.c: Include tree-ssa.h.
2300 (get_constraint_for_ssa_var): For undefs return nothing_id.
2301 (find_func_aliases): Cleanup PHI handling.
2302
2303 2018-10-09 Richard Biener <rguenther@suse.de>
2304
2305 * tree-vectorizer.c (dump_stmt_cost): Fix cut&paste missing
2306 replacements.
2307
2308 2018-10-09 Martin Liska <mliska@suse.cz>
2309
2310 * asan.c (asan_emit_stack_protection): If a stack variable
2311 is located in a same file as current function, then emit
2312 line info into variable definition string.
2313
2314 2018-10-08 Eric Botcazou <ebotcazou@adacore.com>
2315
2316 * print-rtl.c (rtx_writer::print_rtx_operand_code_i): Print column
2317 information.
2318
2319 2018-10-08 Eric Botcazou <ebotcazou@adacore.com>
2320
2321 * cgraphunit.c (cgraph_node::expand_thunk): Do not force DECL_IGNORED_P
2322 on the thunk.
2323
2324 2018-10-08 Eric Botcazou <ebotcazou@adacore.com>
2325
2326 PR tree-optimization/86659
2327 * gimple-match.h (struct gimple_match_op): Add reverse field.
2328 (gimple_match_op::set_op): New overloaded method.
2329 * gimple-match-head.c (maybe_build_generic_op) <BIT_FIELD_REF>: Set
2330 the REF_REVERSE_STORAGE_ORDER flag on the value.
2331 (gimple_simplify) <GIMPLE_ASSIGN>: For BIT_FIELD_REF, propagate the
2332 REF_REVERSE_STORAGE_ORDER flag and avoid simplifying if it is set.
2333
2334 2018-10-08 Richard Sandiford <richard.sandiford@arm.com>
2335
2336 PR middle-end/63155
2337 * gimple-ssa-backprop.c (backprop::intersect_uses): Use
2338 FOR_EACH_IMM_USE_FAST instead of FOR_EACH_IMM_USE_STMT.
2339
2340 2018-10-08 H.J. Lu <hongjiu.lu@intel.com>
2341
2342 PR target/87517
2343 * config/i386/avx512fintrin.h (_mm512_mask_fmaddsub_round_pd):
2344 Defined with __builtin_ia32_vfmaddsubpd512_mask.
2345
2346 2018-10-08 Richard Biener <rguenther@suse.de>
2347
2348 * config/i386/x86-tune-costs.h (znver1_cost): Make AVX256 vector loads
2349 cost the same as AVX128 ones.
2350
2351 2018-10-08 Paul Koning <ni1d@arrl.net>
2352
2353 * config/pdp11/pdp11-protos.h (output_block_move): Remove.
2354 (expand_block_move): New function.
2355 * config/pdp11/pdp11.c (output_block_move): Remove.
2356 (expand_block_move): New function.
2357 * config/pdp11/pdp11.h (MOVE_RATIO): New definition.
2358 * config/pdp11/pdp11.md (movmemhi): Use expand_block_move.
2359 (*movmemhi1): Remove.
2360
2361 2018-10-08 Robin Dapp <rdapp@linux.ibm.com>
2362
2363 * config/s390/2827.md: Increase latencies for some FP instructions.
2364
2365 2018-10-08 Richard Biener <rguenther@suse.de>
2366
2367 * tree-vect-loop.c (vect_compute_single_scalar_iteration_cost):
2368 Open a dump scope.
2369 * tree-vectorizer.c (dump_stmt_cost): Add cost param and dump it.
2370 * tree-vectorizer.h (dump_stmt_cost): Adjust.
2371 (add_stmt_cost): Dump return value of the hook.
2372
2373 2018-10-08 Richard Biener <rguenther@suse.de>
2374
2375 PR tree-optimization/63155
2376 * tree-ssa-propagate.c (add_ssa_edge): Do cheap check first.
2377 (ssa_propagation_engine::ssa_propagate): Remove redundant
2378 bitmap bit clearing.
2379
2380 2018-10-05 Peter Bergner <bergner@linux.ibm.com>
2381
2382 PR rtl-optimization/86939
2383 PR rtl-optimization/87479
2384 * ira.h (non_conflicting_reg_copy_p): New prototype.
2385 * ira-lives.c (ignore_reg_for_conflicts): New static variable.
2386 (make_hard_regno_dead): Don't add conflicts for register
2387 ignore_reg_for_conflicts.
2388 (make_object_dead): Likewise.
2389 (non_conflicting_reg_copy_p): New function.
2390 (process_bb_node_lives): Set ignore_reg_for_conflicts for copies.
2391 Remove special conflict handling of REAL_PIC_OFFSET_TABLE_REGNUM.
2392 * lra-lives.c (ignore_reg_for_conflicts): New static variable.
2393 (make_hard_regno_dead): Don't add conflicts for register
2394 ignore_reg_for_conflicts. Remove special conflict handling of
2395 REAL_PIC_OFFSET_TABLE_REGNUM. Remove now unused argument
2396 check_pic_pseudo_p and update callers.
2397 (mark_pseudo_dead): Don't add conflicts for register
2398 ignore_reg_for_conflicts.
2399 (process_bb_lives): Set ignore_reg_for_conflicts for copies.
2400
2401 2018-10-05 Andrew Waterman <andrew@sifive.com>
2402 Jim Wilson <jimw@sifive.com>
2403
2404 * config/riscv/riscv.md (f<quiet_pattern>_quiet<ANYF:mode><X:mode>4):
2405 Add define_expand. Add ! HONOR_SNANS check to current pattern. Add
2406 new pattern using HONOR_SNANS that emits one extra instruction.
2407
2408 2018-10-05 Segher Boessenkool <segher@kernel.crashing.org>
2409
2410 * config/rs6000/rs6000.md (unnamed mfcr scc_comparison_operator
2411 patterns): Merge SI and DI patterns to a GPR pattern.
2412 (unnamed define_insn and define_split for record form of that): Merge
2413 to a single define_insn_and_split pattern.
2414
2415 2018-10-05 David Malcolm <dmalcolm@redhat.com>
2416
2417 PR c++/56856
2418 * input.c (expand_location_to_spelling_point): Add param "aspect"
2419 and use rather than hardcoding LOCATION_ASPECT_CARET.
2420 (get_substring_ranges_for_loc): Handle the case of a single token
2421 within a macro expansion.
2422 * input.h (expand_location_to_spelling_point): Add "aspect" param,
2423 defaulting to LOCATION_ASPECT_CARET.
2424
2425 2018-10-05 Paul Koning <ni1d@arrl.net>
2426
2427 * config/pdp11/pdp11.c (TARGET_CXX_GUARD_TYPE): Define.
2428 (TARGET_CXX_CLASS_DATA_ALWAYS_COMDAT): Define.
2429 (TARGET_CXX_LIBRARY_RTTI_COMDAT): Define.
2430 (pdp11_guard_type): New function.
2431
2432 2018-10-05 Paul Koning <ni1d@arrl.net>
2433
2434 * config/pdp11/pdp11.h (FLOAT_TYPE_SIZE): Always 32.
2435 * config/pdp11/pdp11.opt (mfloat32): Remove.
2436 (mfloat64): Remove.
2437 * doc/invoke.texi (pdp11 -mfloat32): Remove:
2438 (pdp11 -mfloat64): Remove.
2439
2440 2018-10-05 Uros Bizjak <ubizjak@gmail.com>
2441
2442 * config/i386/i386.md (*cmpxf_cc_i387): Remove pattern.
2443 (*cmp<mode>_cc_i387): Ditto.
2444 (*cmpu<mode>_cc_i387): Ditto.
2445 (*cmp<X87MODEF:mode>_<SWI24:mode>_cc_i387): Ditto.
2446 * config/i386/i386.c (ix86_expand_fp_compare): Remove
2447 "scratch" argument.
2448 <case IX86_FPCMP_SAHF>: Do not generate pattern with HImode clobber.
2449 Emit x86_sahf_1 pattern.
2450 (ix86_expand_compare): Update call to ix86_expand_fp_compare.
2451 (ix86_expand_carry_flag_compare): Ditto.
2452
2453 2018-10-05 Uros Bizjak <ubizjak@gmail.com>
2454
2455 * config/i386/i386.md (*cmpxf_i387): Change operand 2 predicate
2456 to reg_or_0_operand. Add "C" constraint.
2457 (*cmpxf_cc_i387): Ditto.
2458 (*cmp<mode>_i387): Change operand 2 predicate
2459 to nonimm_or_0_operand. Add "C" constraint.
2460 (*cmp<mode>_cc_i387): Ditto.
2461 (*cmp<mode>_0_i387): Remove insn pattern.
2462 (*cmp<mode>_0_cc_i387): Ditto.
2463
2464 2018-10-05 Uros Bizjak <ubizjak@gmail.com>
2465
2466 * config/i386/constraints.md ("C"): Do not depend on TARGET_SSE.
2467 * config/i386/predicates.md (nonimm_or_0_operand): Rename
2468 from vector_move_operand. Update all uses.
2469
2470 2018-10-05 Martin Sebor <msebor@redhat.com>
2471
2472 PR tree-optimization/87490
2473 * builtins.c (expand_builtin_strnlen): Handle a null data.decl
2474 consistently.
2475
2476 2018-10-05 Richard Biener <rguenther@suse.de>
2477
2478 PR tree-optimization/63155
2479 * tree-ssa-ccp.c (ccp_propagate::visit_phi): Avoid excess
2480 vertical space in dumpfiles.
2481 * tree-ssa-propagate.h
2482 (ssa_propagation_engine::process_ssa_edge_worklist): Remove.
2483 * tree-ssa-propagate.c (cfg_blocks_back): New global.
2484 (ssa_edge_worklist_back): Likewise.
2485 (curr_order): Likewise.
2486 (cfg_blocks_get): Remove abstraction.
2487 (cfg_blocks_add): Likewise.
2488 (cfg_blocks_empty_p): Likewise.
2489 (add_ssa_edge): Add to current or next worklist based on
2490 RPO index.
2491 (add_control_edge): Likewise.
2492 (ssa_propagation_engine::process_ssa_edge_worklist): Fold
2493 into ...
2494 (ssa_propagation_engine::ssa_propagate): ... here. Unify
2495 iteration from CFG and SSA edge worklist so we process
2496 everything in RPO order, prioritizing forward progress
2497 over iteration.
2498 (ssa_prop_init): Allocate new worklists, do not dump
2499 immediate uses.
2500 (ssa_prop_fini): Free new worklists.
2501
2502 2018-10-05 Richard Biener <rguenther@suse.de>
2503
2504 * tree-core.h (tree_block::abstract_flag): Remove.
2505 (tree_block::block_num): Make full 32bits.
2506 * tree.def (BLOCK): Remove docs about BLOCK_ABSTRACT.
2507 * tree.h (BLOCK_ABSTRACT): Remove.
2508 * dwarf2out.c (gen_lexical_block_die): Remove dead code
2509 resulting from BLOCK_ABSTRACT being always false.
2510 (gen_inlined_subroutine_die): Likewise.
2511 (gen_block_die): Likewise.
2512 * tree.c (block_ultimate_origin): Likewise.
2513 * tree-pretty-print.c (dump_block_node): Remove code dealing
2514 with BLOCK_ABSTRACT.
2515 * tree-ssa-live.c (dump_scope_block): Likewise.
2516 * tree-streamer-in.c (unpack_ts_block_value_fields): Likewise.
2517 * tree-streamer-out.c (pack_ts_block_value_fields): Likewise.
2518
2519 2018-10-05 Richard Biener <rguenther@suse.de>
2520
2521 * config/i386/i386.c (ix86_add_stmt_cost): When scalar cost
2522 is asked for initialize mode to the component mode of the
2523 vector type.
2524
2525 2018-10-05 H.J. Lu <hongjiu.lu@intel.com>
2526
2527 PR target/87522
2528 * config/i386/gnu-user.h (ASM_SPEC): Don't pass -msse2avx to
2529 assembler for -mavx.
2530 * config/i386/gnu-user64.h (ASM_SPEC): Likewise.
2531
2532 2018-10-05 Segher Boessenkool <segher@kernel.crashing.org>
2533
2534 PR target/87509
2535 * config/rs6000/rs6000-builtin.def (RS6000_BUILTIN_SET_FPSCR_DRN): Use
2536 RS6000_BTM_DFP.
2537 * config/rs6000/rs6000.md (rs6000_set_fpscr_rn): Require the operand
2538 to be DImode. When using mffscrn, force the operand to a register.
2539
2540 2018-10-04 Uros Bizjak <ubizjak@gmail.com>
2541
2542 * config/i386/i386.md (*fop_<X87MODEF:mode>_2_i387): Macroize insn
2543 from *fop_<MODEF:mode>_2_i387 and *fop_xf_2_i387 using
2544 X87MODEF mode iterator.
2545 (*fop_<X87MODEF:mode>_3_i387): Macroize insn from
2546 *fop_<MODEF:mode>_3_i387 and *fop_xf_3_i387 using
2547 X87MODEF mode iterator.
2548
2549 2018-10-04 Vinay Kumar <vinay.kumar@blackfigtech.com>
2550
2551 * doc/invoke.texi (-Wno-prio-ctor-dtor): Document new warning
2552 -Wno-prio-ctor-dtor.
2553
2554 2018-10-04 David Malcolm <dmalcolm@redhat.com>
2555
2556 * Makefile.in (OBJS): Add opt-problem.o.
2557 * dump-context.h: Include "selftest.h.
2558 (selftest::temp_dump_context): New forward decl.
2559 (class dump_context): Make friend of class
2560 selftest::temp_dump_context.
2561 (dump_context::dump_loc_immediate): New decl.
2562 (class dump_pretty_printer): Move here from dumpfile.c.
2563 (class temp_dump_context): Move to namespace selftest.
2564 (temp_dump_context::temp_dump_context): Add param
2565 "forcibly_enable_dumping".
2566 (selftest::verify_dumped_text):
2567 (ASSERT_DUMPED_TEXT_EQ): Move here from dumpfile.c.
2568 (selftest::verify_item):
2569 (ASSERT_IS_TEXT): Move here from dumpfile.c.
2570 (ASSERT_IS_TREE): Likewise.
2571 (ASSERT_IS_GIMPLE): Likewise.
2572 * dumpfile.c (dump_context::dump_loc): Move immediate dumping
2573 to...
2574 (dump_context::dump_loc_immediate): ...this new function.
2575 (class dump_pretty_printer): Move to dump-context.h.
2576 (dump_switch_p_1): Don't enable MSG_PRIORITY_REEMITTED.
2577 (opt_info_switch_p_1): Enable MSG_PRIORITY_REEMITTED.
2578 (temp_dump_context::temp_dump_context): Move to "selftest"
2579 namespace. Add param "forcibly_enable_dumping", and use it to
2580 conditionalize the use of m_pp;
2581 (selftest::verify_dumped_text): Make non-static.
2582 (ASSERT_DUMPED_TEXT_EQ): Move to dump-context.h.
2583 (selftest::verify_item): Make non-static.
2584 (ASSERT_IS_TEXT): Move to dump-context.h.
2585 (ASSERT_IS_TREE): Likewise.
2586 (ASSERT_IS_GIMPLE): Likewise.
2587 (selftest::test_capture_of_dump_calls): Pass "true" for new
2588 param of temp_dump_context.
2589 * dumpfile.h (enum dump_flag): Add MSG_PRIORITY_REEMITTED, adding
2590 it to MSG_ALL_PRIORITIES. Update values of TDF_COMPARE_DEBUG and
2591 TDF_COMPARE_DEBUG.
2592 * opt-problem.cc: New file.
2593 * opt-problem.h: New file.
2594 * optinfo-emit-json.cc
2595 (selftest::test_building_json_from_dump_calls): Pass "true" for
2596 new param of temp_dump_context.
2597 * optinfo.cc (optinfo_kind_to_dump_flag): New function.
2598 (optinfo::emit_for_opt_problem): New function.
2599 (optinfo::emit): Clarity which emit_item is used.
2600 * optinfo.h (optinfo::get_dump_location): New accessor.
2601 (optinfo::emit_for_opt_problem): New decl.
2602 (optinfo::emit): Make const.
2603 * selftest-run-tests.c (selftest::run_tests): Call
2604 selftest::opt_problem_cc_tests.
2605 * selftest.h (selftest::opt_problem_cc_tests): New decl.
2606 * tree-data-ref.c (dr_analyze_innermost): Convert return type from
2607 bool to opt_result, converting fprintf messages to
2608 opt_result::failure_at calls. Add "stmt" param for use by the
2609 failure_at calls.
2610 (create_data_ref): Pass "stmt" to the dr_analyze_innermost call.
2611 (runtime_alias_check_p): Convert return type from bool to
2612 opt_result, converting dump_printf calls to
2613 opt_result::failure_at, using the statement DDR_A for their
2614 location.
2615 (find_data_references_in_stmt): Convert return type from bool to
2616 opt_result, converting "return false" to opt_result::failure_at
2617 with a new message.
2618 * tree-data-ref.h: Include "opt-problem.h".
2619 (dr_analyze_innermost): Convert return type from bool to opt_result,
2620 and add a const gimple * param.
2621 (find_data_references_in_stmt): Convert return type from bool to
2622 opt_result.
2623 (runtime_alias_check_p): Likewise.
2624 * tree-predcom.c (find_looparound_phi): Pass "init_stmt" to
2625 dr_analyze_innermost.
2626 * tree-vect-data-refs.c (vect_mark_for_runtime_alias_test):
2627 Convert return type from bool to opt_result, adding a message for
2628 the PARAM_VECT_MAX_VERSION_FOR_ALIAS_CHECKS zero case.
2629 (vect_analyze_data_ref_dependence): Convert return type from bool
2630 to opt_result. Change sense of return type from "false"
2631 effectively meaning "no problems" to "false" meaning a problem,
2632 so that "return false" becomes "return opt_result::success".
2633 Convert "return true" calls to opt_result::failure_at, using
2634 the location of statement A rather than vect_location.
2635 (vect_analyze_data_ref_dependences): Convert return type from bool
2636 to opt_result.
2637 (verify_data_ref_alignment): Likewise, converting dump_printf_loc
2638 calls to opt_result::failure_at, using the stmt location rather
2639 than vect_location.
2640 (vect_verify_datarefs_alignment): Convert return type from bool
2641 to opt_result.
2642 (vect_enhance_data_refs_alignment): Likewise. Split local "stat"
2643 into multiple more-tightly-scoped copies.
2644 (vect_analyze_data_refs_alignment): Convert return type from bool
2645 to opt_result.
2646 (vect_analyze_data_ref_accesses): Likewise, converting a
2647 "return false" to a "return opt_result::failure_at", adding a
2648 new message.
2649 (vect_prune_runtime_alias_test_list): Convert return type from
2650 bool to opt_result, converting dump_printf_loc to
2651 opt_result::failure_at. Add a %G to show the pertinent statement,
2652 and use the stmt's location rather than vect_location.
2653 (vect_find_stmt_data_reference): Convert return type from
2654 bool to opt_result, converting dump_printf_loc to
2655 opt_result::failure_at, using stmt's location.
2656 (vect_analyze_data_refs): Convert return type from bool to
2657 opt_result. Convert "return false" to "return
2658 opt_result::failure_at", adding messages as needed.
2659 * tree-vect-loop.c (vect_determine_vf_for_stmt_1): Convert return
2660 type from bool to opt_result.
2661 (vect_determine_vf_for_stmt): Likewise.
2662 (vect_determine_vectorization_factor): Likewise, converting
2663 dump_printf_loc to opt_result::failure_at, using location of phi
2664 rather than vect_location.
2665 (vect_analyze_loop_form_1): Convert return type from bool to
2666 opt_result, converting dump_printf_loc calls, retaining the use of
2667 vect_location.
2668 (vect_analyze_loop_form): Convert return type from loop_vec_info
2669 to opt_loop_vec_info.
2670 (vect_analyze_loop_operations): Convert return type from bool to
2671 opt_result, converting dump_printf_loc calls, using the location
2672 of phi/stmt rather than vect_location where available. Convert
2673 various "return false" to "return opt_result::failure_at" with
2674 "unsupported phi" messages.
2675 (vect_get_datarefs_in_loop): Convert return type from bool to
2676 opt_result. Add a message for the
2677 PARAM_LOOP_MAX_DATAREFS_FOR_DATADEPS failure.
2678 (vect_analyze_loop_2): Convert return type from bool to
2679 opt_result. Ensure "ok" is set to a opt_result::failure_at before
2680 each "goto again;", adding new messages where needed.
2681 Add "unsupported grouped {store|load}" messages.
2682 (vect_analyze_loop): Convert return type from loop_vec_info to
2683 opt_loop_vec_info.
2684 * tree-vect-slp.c (vect_analyze_slp): Convert return type from
2685 bool to opt_result.
2686 * tree-vect-stmts.c (process_use): Likewise, converting
2687 dump_printf_loc call and using stmt location, rather than
2688 vect_location.
2689 (vect_mark_stmts_to_be_vectorized): Likeise.
2690 (vect_analyze_stmt): Likewise, adding a %G.
2691 (vect_get_vector_types_for_stmt): Convert return type from bool to
2692 opt_result, converting dump_printf_loc calls and using stmt
2693 location, rather than vect_location.
2694 (vect_get_mask_type_for_stmt): Convert return type from tree to
2695 opt_tree, converting dump_printf_loc calls and using stmt location.
2696 * tree-vectorizer.c: Include "opt-problem.h.
2697 (try_vectorize_loop_1): Flag "Analyzing loop at" dump message as
2698 MSG_PRIORITY_INTERNALS. Convert local "loop_vinfo" from
2699 loop_vec_info to opt_loop_vec_info. If if fails, and dumping is
2700 enabled, use it to report at the top level "couldn't vectorize
2701 loop" followed by the problem.
2702 * tree-vectorizer.h (opt_loop_vec_info): New typedef.
2703 (vect_mark_stmts_to_be_vectorized): Convert return type from bool
2704 to opt_result.
2705 (vect_analyze_stmt): Likewise.
2706 (vect_get_vector_types_for_stmt): Likewise.
2707 (tree vect_get_mask_type_for_stmt): Likewise.
2708 (vect_analyze_data_ref_dependences): Likewise.
2709 (vect_enhance_data_refs_alignment): Likewise.
2710 (vect_analyze_data_refs_alignment): Likewise.
2711 (vect_verify_datarefs_alignment): Likewise.
2712 (vect_analyze_data_ref_accesses): Likewise.
2713 (vect_prune_runtime_alias_test_list): Likewise.
2714 (vect_find_stmt_data_reference): Likewise.
2715 (vect_analyze_data_refs): Likewise.
2716 (vect_analyze_loop): Convert return type from loop_vec_info to
2717 opt_loop_vec_info.
2718 (vect_analyze_loop_form): Likewise.
2719 (vect_analyze_slp): Convert return type from bool to opt_result.
2720
2721 2018-10-04 David Malcolm <dmalcolm@redhat.com>
2722
2723 * doc/invoke.texi (-fopt-info): Document new "internals"
2724 sub-option.
2725 * dump-context.h (dump_context::apply_dump_filter_p): New decl.
2726 * dumpfile.c (dump_options): Update for renaming of MSG_ALL to
2727 MSG_ALL_KINDS.
2728 (optinfo_verbosity_options): Add "internals".
2729 (kind_as_string): Update for renaming of MSG_ALL to MSG_ALL_KINDS.
2730 (dump_context::apply_dump_filter_p): New member function.
2731 (dump_context::dump_loc): Use apply_dump_filter_p rather than
2732 explicitly masking the dump_kind.
2733 (dump_context::begin_scope): Increment the scope depth first. Use
2734 apply_dump_filter_p rather than explicitly masking the dump_kind.
2735 (dump_context::emit_item): Use apply_dump_filter_p rather than
2736 explicitly masking the dump_kind.
2737 (dump_dec): Likewise.
2738 (dump_hex): Likewise.
2739 (dump_switch_p_1): Default to MSG_ALL_PRIORITIES.
2740 (opt_info_switch_p_1): Default to MSG_PRIORITY_USER_FACING.
2741 (opt_info_switch_p): Update handling of default
2742 MSG_OPTIMIZED_LOCATIONS to cope with default of
2743 MSG_PRIORITY_USER_FACING.
2744 (dump_basic_block): Use apply_dump_filter_p rather than explicitly
2745 masking the dump_kind.
2746 (selftest::test_capture_of_dump_calls): Update test_dump_context
2747 instances to use MSG_ALL_KINDS | MSG_PRIORITY_USER_FACING rather
2748 than MSG_ALL. Generalize scope test to be run at all four
2749 combinations of with/without MSG_PRIORITY_USER_FACING and
2750 MSG_PRIORITY_INTERNALS, adding examples of explicit priority
2751 for each of the two values.
2752 * dumpfile.h (enum dump_flag): Add comment about the MSG_* flags.
2753 Rename MSG_ALL to MSG_ALL_KINDS. Add MSG_PRIORITY_USER_FACING,
2754 MSG_PRIORITY_INTERNALS, and MSG_ALL_PRIORITIES, updating the
2755 values for TDF_COMPARE_DEBUG and TDF_ALL_VALUES.
2756 (AUTO_DUMP_SCOPE): Add a note to the comment about the interaction
2757 with MSG_PRIORITY_*.
2758 * tree-vect-loop-manip.c (vect_loop_versioning): Mark versioning
2759 dump messages as MSG_PRIORITY_USER_FACING.
2760 * tree-vectorizer.h (DUMP_VECT_SCOPE): Add a note to the comment
2761 about the interaction with MSG_PRIORITY_*.
2762
2763 2018-10-04 Bernd Edlinger <bernd.edlinger@hotmail.de>
2764
2765 * varasm.c (output_constant): Add new parameter merge_strings.
2766 Make strings properly zero terminated in merge string sections.
2767 (mergeable_string_section): Don't fail if the last char is non-zero.
2768 (assemble_variable_contents): Handle merge string sections.
2769 (assemble_variable): Likewise.
2770 (assemble_constant_contents): Likewise.
2771 (output_constant_def_contents): Likewise.
2772 (output_constructor_array_range,
2773 output_constructor_regular_field): Adjust call to output_constant.
2774 (output_object_block): Adjust call to assemble_constant_contents
2775 and assemble_variable_contents.
2776
2777 2018-10-04 Martin Liska <mliska@suse.cz>
2778
2779 PR c/87483
2780 * cgraphunit.c (process_function_and_variable_attributes):
2781 Warn about a function with alias attribute and a body.
2782
2783 2018-10-04 Martin Liska <mliska@suse.cz>
2784
2785 PR ipa/82625
2786 * multiple_target.c (redirect_to_specific_clone): New function.
2787 (ipa_target_clone): Use it.
2788 * tree-inline.c: Fix comment.
2789
2790 2018-10-04 David Malcolm <dmalcolm@redhat.com>
2791
2792 * dumpfile.c (gcc::dump_manager::dump_manager): Initialize new
2793 fields.
2794 (gcc::dump_manager::~dump_manager): Free m_optinfo_filename.
2795 (gcc::dump_manager::register_pass): New member function, adapted
2796 from loop body in gcc::pass_manager::register_pass, adding a
2797 call to update_dfi_for_opt_info.
2798 (gcc::dump_manager::opt_info_enable_passes): Store the
2799 -fopt-info options into the new fields. Move the loop
2800 bodies into...
2801 (gcc::dump_manager::update_dfi_for_opt_info): ...this new member
2802 function.
2803 * dumpfile.h (struct opt_pass): New forward decl.
2804 (gcc::dump_manager::register_pass): New decl.
2805 (gcc::dump_manager::update_dfi_for_opt_info): New decl.
2806 (class gcc::dump_manager): Add fields "m_optgroup_flags",
2807 "m_optinfo_flags", and "m_optinfo_filename".
2808 * passes.c (gcc::pass_manager::register_pass): Move all of the
2809 dump-handling code to gcc::dump_manager::register_pass.
2810
2811 2018-10-04 Peter Bergner <bergner@linux.ibm.com>
2812
2813 PR rtl-optimization/87466
2814 * target.def (setjmp_preserves_nonvolatile_regs_p): New target hook.
2815 * doc/tm.texi.in (TARGET_SETJMP_PRESERVES_NONVOLATILE_REGS_P): New hook.
2816 * doc/tm.texi: Regenerate.
2817 * ira-lives.c (process_bb_node_lives): Use the new target hook.
2818 * lra-lives.c (process_bb_lives): Likewise.
2819 * config/rs6000/rs6000.c (TARGET_SETJMP_PRESERVES_NONVOLATILE_REGS_P):
2820 Define.
2821
2822 2018-10-04 Tamar Christina <tamar.christina@arm.com>
2823
2824 * params.c (add_params): Fix initialization.
2825
2826 2018-10-04 Martin Liska <mliska@suse.cz>
2827
2828 PR gcov-profile/84107
2829 * tree-profile.c (init_ic_make_global_vars):
2830 Remove ic_void_ptr_var and ic_gcov_type_ptr_var.
2831 Come up with new ic_tuple* variables. Emit
2832 __gcov_indirect_call{,_topn} variables.
2833 (gimple_gen_ic_profiler): Access the variable
2834 and emit gimple.
2835 (gimple_gen_ic_func_profiler): Access
2836 __gcov_indirect_call.callee field.
2837 (gimple_init_gcov_profiler): Use ptr_type_node.
2838 * value-prof.c (gimple_ic): Use ptr_type_node.
2839
2840 2018-10-04 Prathamesh Kulkarni <prathamesh.kulkarni@linaro.org>
2841
2842 PR tree-optimization/85787
2843 * ipa-pure-const.c (malloc_candidate_p_1): Move most of malloc_candidate_p
2844 into this function and add support for detecting multiple phis.
2845 (DUMP_AND_RETURN): Move from malloc_candidate_p into top-level macro.
2846
2847 2018-10-04 Martin Liska <mliska@suse.cz>
2848
2849 PR ipa/87491
2850 * ipa-inline.c (inline_to_all_callers_1):
2851 Call ultimate_alias_target for node being inlined.
2852
2853 2018-10-03 Jeff Law <law@redhat.com>
2854
2855 * gimple-ssa-sprintf.c (format_string): Do not hardcode size of
2856 target's wchar_t.
2857 * tree.c (get_typenode_from_name): Moved from fortran/trans-types.c.
2858 * tree.h (get_typenode_from_name): Prototype.
2859
2860 2018-10-03 Uros Bizjak <ubizjak@gmail.com>
2861
2862 * config/i386/i386.md (*cmp<X87MODEF:mode>_<SWI24:mode>_i387):
2863 Change operand 2 predicate to nonimmediate_operand.
2864 (*cmp<X87MODEF:mode>_<SWI24:mode>_cc_i387): Ditto.
2865
2866 2018-10-03 Martin Sebor <msebor@redhat.com>
2867 Jeff Law <law@redhat.com>
2868
2869 * gimple-ssa-sprintf.c (struct fmtresult): Add new member and
2870 initialize it.
2871 (get_string_length): Detect unterminated arrays.
2872 (format_string): Same.
2873 (format_directive): Warn about unterminated arrays.
2874 (handle_gimple_call): Mark statements with no_warning as needed.
2875
2876 2018-10-03 Jim Wilson <jimw@sifive.com>
2877
2878 * config/riscv/riscv-c.c (riscv_cpu_cpp_builtins): For ABI_ILP32E,
2879 also define __riscv_abi_rve. Delete trailing white space.
2880
2881 2018-10-03 Paul Koning <ni1d@arrl.net>
2882
2883 Enable LRA register allocator for PDP11.
2884 * config/pdp11/constraints.md (Q): Use define_memory_constraint.
2885 (R): Likewise.
2886 (D): Likewise.
2887 * config/pdp11/pdp11.c (pdp11_lra_p): New function.
2888 * config/pdp11/pdp11.opt (-mlra): New option.
2889 * doc/invoke.texi (PDP-11 Options): Document -mlra.
2890
2891 2018-10-03 Uros Bizjak <ubizjak@gmail.com>
2892
2893 * config/i386/i386.md (*<absneg:code>extendsfdf2): Remove.
2894 (*<absneg:code>extend<mode>xf2): Ditto.
2895
2896 2018-10-03 Aldy Hernandez <aldyh@redhat.com>
2897
2898 PR tree-optimization/87415
2899 * tree-vrp.c (set_value_range_with_overflow): Special case one bit
2900 precision fields.
2901
2902 2018-10-02 Jeff Law <law@redhat.com>
2903
2904 * gimple-fold.c (get_range_strlen): Only set *nonstr when
2905 an unterminated string is discovered. Bubble up range
2906 even for unterminated strings.
2907 (gimple_fold_builtin_strlen): Do not fold if get_range_strlen
2908 indicates the string was not terminated via NONSTR.
2909
2910 2018-10-03 Aldy Hernandez <aldyh@redhat.com>
2911
2912 * tree-vrp.c (extract_range_from_unary_expr): Special case all
2913 pointer conversions.
2914 Do not do anything special for anti-ranges.
2915
2916 2018-10-03 Jérôme Lambourg <lambourg@adacore.com>
2917
2918 * config/arm/vxworks.h (ARM_TARGET2_DWARF_FORMAT): Adjust to
2919 DW_EH_PE_pcrel | DW_EH_PE_indirect for RTPs.
2920
2921 2018-10-03 Martin Liska <mliska@suse.cz>
2922
2923 PR gcov-profile/86109
2924 * coverage.c (coverage_begin_function): Do not
2925 mark lambdas as artificial.
2926 * tree-core.h (struct GTY): Remove tm_clone_flag
2927 and introduce new lambda_function.
2928 * tree.h (DECL_LAMBDA_FUNCTION): New macro.
2929
2930 2018-10-02 Aaron Sawdey <acsawdey@linux.ibm.com>
2931
2932 PR target/87474
2933 * config/rs6000/rs6000-string.c (expand_strn_compare): Check that both
2934 P8_VECTOR and VSX are enabled.
2935
2936 2018-10-02 Andreas Krebbel <krebbel@linux.ibm.com>
2937
2938 * config/s390/driver-native.c (s390_host_detect_local_cpu): Add
2939 0x3907 as CPU model number.
2940
2941 2018-10-02 Andreas Krebbel <krebbel@linux.ibm.com>
2942
2943 * common/config/s390/s390-common.c: Rename PF_ARCH12 to PF_Z14.
2944 * config/s390/s390.h (enum processor_flags): Rename PF_ARCH12 to
2945 PF_Z14. Rename TARGET_CPU_ARCH12 to TARGET_CPU_Z14,
2946 TARGET_CPU_ARCH12_P to TARGET_CPU_Z14_P, TARGET_ARCH12 to
2947 TARGET_Z14, and TARGET_ARCH12_P to TARGET_Z14_P.
2948 * config/s390/s390.md: Likewise. Rename also the cpu attribute
2949 value from arch12 to z14.
2950
2951 2018-10-02 Uros Bizjak <ubizjak@gmail.com>
2952
2953 * config/i386/i386.md (fxam<mode>2_i387_with_temp): Remove.
2954 (isinfxf2): Ditto.
2955 (isinf<mode>2): Ditto.
2956
2957 2018-10-02 Uros Bizjak <ubizjak@gmail.com>
2958
2959 * config/i386/i386.c (ix86_emit_i387_round): Extend op1 to XFmode
2960 before emitting fxam. Perform calculations in XFmode.
2961
2962 2018-10-02 Marc Glisse <marc.glisse@inria.fr>
2963
2964 * match.pd (((X /[ex] A) +- B) * A): New transformation.
2965
2966 2018-10-02 Marc Glisse <marc.glisse@inria.fr>
2967
2968 PR middle-end/87319
2969 * fold-const.c (fold_plusminus_mult_expr): Handle complex and vectors.
2970 * tree.c (signed_or_unsigned_type_for): Handle complex.
2971
2972 2018-10-02 Jeff Law <law@redhat.com>
2973
2974 * gimple-fold.c (get_range_strlen): Remove dead code.
2975
2976 2018-10-02 Martin Sebor <msebor@redhat.com>
2977 Jeff Law <law@redhat.com>
2978
2979 * builtins.c (unterminated_array): Add new arguments.
2980 If argument is not terminated, bubble up size and exact
2981 state to callers.
2982 (expand_builtin_strnlen): Detect, avoid expanding
2983 and diagnose unterminated arrays.
2984 (c_strlen): Fill in offset of start of unterminated strings.
2985 * builtins.h (unterminated_array): Update prototype.
2986
2987 2018-10-02 Richard Biener <rguenther@suse.de>
2988
2989 * config/i386/sse.md (reduc_plus_scal_v4df): Avoid the use
2990 of haddv4df, first reduce to SSE width and exploit the fact
2991 that we only need element zero with the reduction result.
2992 (reduc_plus_scal_v2df): Likewise.
2993
2994 2018-10-02 Eric Botcazou <ebotcazou@adacore.com>
2995
2996 * dojump.h (do_jump): Delete.
2997 (do_jump_1): Likewise.
2998 (split_comparison): Move around.
2999 * dojump.c (do_jump): Make static.
3000 (do_jump_1): Likewise.
3001 (jumpifnot): Move around.
3002 (jumpifnot_1): Likewise.
3003 (jumpif): Likewise.
3004 (jumpif_1): Likewise.
3005 * expr.c (expand_expr_real_1): Call jumpif[not] instead of do_jump.
3006
3007 2018-10-02 Eric Botcazou <ebotcazou@adacore.com>
3008
3009 * reorg.c (make_return_insns): Use emit_copy_of_insn_after for the
3010 insns in the delay slot and add_insn_after for the jump insn.
3011
3012 2018-10-02 Richard Biener <rguenther@suse.de>
3013
3014 * tree-inline.c (expand_call_inline): Use the location of
3015 the callee declaration for the inline-entry marker.
3016 * final.c (notice_source_line): Remove special-casing of
3017 NOTE_INSN_INLINE_ENTRY.
3018
3019 2018-10-01 Carl Love <cel@us.ibm.com>
3020
3021 PR 69431
3022 * config/rs6000/rs6000-builtin.def (__builtin_mffsl): New.
3023 (__builtin_mtfsb0): New.
3024 (__builtin_mtfsb1): New.
3025 ( __builtin_set_fpscr_rn): New.
3026 (__builtin_set_fpscr_drn): New.
3027 * config/rs6000/rs6000.c (rs6000_expand_mtfsb_builtin): Add.
3028 (rs6000_expand_set_fpscr_rn_builtin): Add.
3029 (rs6000_expand_set_fpscr_drn_builtin): Add.
3030 (rs6000_expand_builtin): Add case statement entries for
3031 RS6000_BUILTIN_MTFSB0, RS6000_BUILTIN_MTFSB1,
3032 RS6000_BUILTIN_SET_FPSCR_RN, RS6000_BUILTIN_SET_FPSCR_DRN,
3033 RS6000_BUILTIN_MFFSL.
3034 (rs6000_init_builtins): Add ftype initialization and def_builtin
3035 calls for __builtin_mffsl, __builtin_mtfsb0, __builtin_mtfsb1,
3036 __builtin_set_fpscr_rn, __builtin_set_fpscr_drn.
3037 * config/rs6000.md (rs6000_mtfsb0, rs6000_mtfsb1, rs6000_mffscrn,
3038 rs6000_mffscdrn): Add define_insn.
3039 (rs6000_set_fpscr_rn, rs6000_set_fpscr_drn): Add define_expand.
3040 * doc/extend.texi: Add documentation for the builtins.
3041
3042 2018-10-01 Richard Biener <rguenther@suse.de>
3043
3044 PR tree-optimization/87465
3045 * tree-ssa-loop-ivcanon.c (tree_estimate_loop_size): Fix typo
3046 causing branch miscounts.
3047
3048 2018-10-01 Tamar Christina <tamar.christina@arm.com>
3049
3050 * common/config/aarch64/aarch64-common.c (TARGET_OPTION_DEFAULT_PARAM,
3051 aarch64_option_default_param): New.
3052 (params.h): Include.
3053 (TARGET_OPTION_VALIDATE_PARAM, aarch64_option_validate_param): New.
3054 * config/aarch64/aarch64.c (aarch64_override_options_internal): Simplify
3055 stack-clash protection validation code.
3056
3057 2018-10-01 Tamar Christina <tamar.christina@arm.com>
3058
3059 * params.c (validate_param): New.
3060 (add_params): Use it.
3061 (set_param_value): Refactor param validation into validate_param.
3062 (diagnostic.h): Include.
3063 * diagnostic.h (diagnostic_ready_p): New.
3064
3065 2018-10-01 Tamar Christina <tamar.christina@arm.com>
3066
3067 * params.c (set_param_value):
3068 Add index of parameter being validated.
3069 * common/common-target.def (option_validate_param): New.
3070 * common/common-targhooks.h (default_option_validate_param): New.
3071 * common/common-targhooks.c (default_option_validate_param): New.
3072 * doc/tm.texi.in (TARGET_OPTION_VALIDATE_PARAM): New.
3073 * doc/tm.texi: Regenerate.
3074
3075 2018-10-01 Tamar Christina <tamar.christina@arm.com>
3076
3077 PR target/86486
3078 * config/aarch64/aarch64.c (aarch64_override_options_internal):
3079 Add validation for stack-clash parameters and set defaults.
3080
3081 2018-10-01 Tamar Christina <tamar.christina@arm.com>
3082
3083 PR target/86486
3084 * configure.ac: Add stack-clash-protection-guard-size.
3085 * doc/install.texi: Document it.
3086 * config.in (DEFAULT_STK_CLASH_GUARD_SIZE): New.
3087 * params.def: Update comment for guard-size.
3088 (PARAM_STACK_CLASH_PROTECTION_GUARD_SIZE,
3089 PARAM_STACK_CLASH_PROTECTION_PROBE_INTERVAL): Update description.
3090 * configure: Regenerate.
3091
3092 2018-10-01 Tamar Christina <tamar.christina@arm.com>
3093
3094 PR target/86486
3095 * config/aarch64/aarch64.h (STACK_CLASH_MIN_BYTES_OUTGOING_ARGS,
3096 STACK_DYNAMIC_OFFSET): New.
3097 * config/aarch64/aarch64.c (aarch64_layout_frame):
3098 Update outgoing args size.
3099 (aarch64_stack_clash_protection_alloca_probe_range,
3100 TARGET_STACK_CLASH_PROTECTION_ALLOCA_PROBE_RANGE): New.
3101
3102 2018-10-01 Tamar Christina <tamar.christina@arm.com>
3103
3104 PR target/86486
3105 * explow.c (anti_adjust_stack_and_probe_stack_clash): Support custom
3106 probe ranges.
3107 * target.def (stack_clash_protection_alloca_probe_range): New.
3108 (stack_clash_protection_final_dynamic_probe): Remove.
3109 * targhooks.h (default_stack_clash_protection_alloca_probe_range) New.
3110 (default_stack_clash_protection_final_dynamic_probe): Remove.
3111 * targhooks.c: Likewise.
3112 * doc/tm.texi.in (TARGET_STACK_CLASH_PROTECTION_ALLOCA_PROBE_RANGE): New.
3113 (TARGET_STACK_CLASH_PROTECTION_FINAL_DYNAMIC_PROBE): Remove.
3114 * doc/tm.texi: Regenerate.
3115
3116 2018-10-01 Tamar Christina <tamar.christina@arm.com>
3117
3118 PR target/86486
3119 * config/aarch64/aarch64-protos.h (aarch64_output_probe_sve_stack_clash): New.
3120 * config/aarch64/aarch64.c (aarch64_output_probe_sve_stack_clash,
3121 aarch64_clamp_to_uimm12_shift): New.
3122 (aarch64_allocate_and_probe_stack_space): Add SVE specific section.
3123 * config/aarch64/aarch64.md (probe_sve_stack_clash): New.
3124
3125 2018-10-01 Tamar Christina <tamar.christina@arm.com>
3126
3127 PR target/86486
3128 * config/aarch64/aarch64.c (aarch64_layout_frame): Add assert.
3129
3130 2018-10-01 Jeff Law <law@redhat.com>
3131 Richard Sandiford <richard.sandiford@linaro.org>
3132 Tamar Christina <tamar.christina@arm.com>
3133
3134 PR target/86486
3135 * config/aarch64/aarch64.md
3136 (probe_stack_range): Add k (SP) constraint.
3137 * config/aarch64/aarch64.h (STACK_CLASH_CALLER_GUARD,
3138 STACK_CLASH_MAX_UNROLL_PAGES): New.
3139 * config/aarch64/aarch64.c (aarch64_output_probe_stack_range): Emit
3140 stack probes for stack clash.
3141 (aarch64_allocate_and_probe_stack_space): New.
3142 (aarch64_expand_prologue): Use it.
3143 (aarch64_expand_epilogue): Likewise and update IP regs re-use criteria.
3144 (aarch64_sub_sp): Add emit_move_imm optional param.
3145
3146 2018-10-01 MCC CS <deswurstes@users.noreply.github.com>
3147
3148 PR tree-optimization/87261
3149 * match.pd: Remove trailing whitespace.
3150 Add (x & y) | ~(x | y) -> ~(x ^ y),
3151 (~x | y) ^ (x ^ y) -> x | ~y and (x ^ y) | ~(x | y) -> ~(x & y)
3152
3153 2018-10-01 Claudiu Zissulescu <claziss@synopsys.com>
3154
3155 * config/arc/arc.md (*add_n): Clean up pattern, update instruction
3156 constraints.
3157 (ashlsi3_insn): Update instruction constraints.
3158 (ashrsi3_insn): Likewise.
3159 (rotrsi3): Likewise.
3160 (add_shift): Likewise.
3161 * config/arc/constraints.md (Csz): New 32 bit constraint. It
3162 avoids placing in the limm field small constants which, otherwise,
3163 could end into a small instruction.
3164
3165 2018-10-01 Claudiu Zissulescu <claziss@synopsys.com>
3166
3167 * config/arc/arc.md (maddsidi4_split): Don't use dmac if the
3168 destination register is not odd-even.
3169 (umaddsidi4_split): Likewise.
3170
3171 2018-10-01 Richard Biener <rguenther@suse.de>
3172
3173 * tree-inline.c (expand_call_inline): Store origin of fn
3174 in BLOCK_ABSTRACT_ORIGIN for the inline BLOCK.
3175 * tree.c (block_ultimate_origin): Simplify and do some
3176 checking.
3177
3178 2018-09-30 Uros Bizjak <ubizjak@gmail.com>
3179
3180 * config/i386/mmx.md (EMMS): New int iterator.
3181 (emms): New int attribute.
3182 (mmx_<emms>): Macroize insn from *mmx_emms and *mmx_femms using
3183 EMMS int iterator. Explicitly declare clobbers.
3184 (mmx_emms): Remove expander.
3185 (mmx_femms): Ditto.
3186 * config/i386/predicates.md (emms_operation): Remove predicate.
3187 (vzeroall_pattern): New predicate.
3188 (vzeroupper_pattern): Rename from vzeroupper_operation.
3189 * config/i386/i386.c (ix86_avx_u128_mode_after): Use
3190 vzeroupper_pattern and vzeroall_pattern predicates.
3191
3192 2018-09-30 Peter Bergner <bergner@linux.ibm.com>
3193
3194 PR rtl-optimization/86939
3195 * ira-lives.c (make_hard_regno_born): Rename from this...
3196 (make_hard_regno_live): ... to this. Remove update to conflict
3197 information. Update function comment.
3198 (make_hard_regno_dead): Add conflict information update. Update
3199 function comment.
3200 (make_object_born): Rename from this...
3201 (make_object_live): ... to this. Remove update to conflict information.
3202 Update function comment.
3203 (make_object_dead): Add conflict information update. Update function
3204 comment.
3205 (mark_pseudo_regno_live): Call make_object_live.
3206 (mark_pseudo_regno_subword_live): Likewise.
3207 (mark_hard_reg_dead): Update function comment.
3208 (mark_hard_reg_live): Call make_hard_regno_live.
3209 (process_bb_node_lives): Likewise.
3210 * lra-lives.c (make_hard_regno_born): Rename from this...
3211 (make_hard_regno_live): ... to this. Remove update to conflict
3212 information. Remove now uneeded check_pic_pseudo_p argument.
3213 Update function comment.
3214 (make_hard_regno_dead): Add check_pic_pseudo_p argument and add update
3215 to conflict information. Update function comment.
3216 (mark_pseudo_live): Remove update to conflict information. Update
3217 function comment.
3218 (mark_pseudo_dead): Add conflict information update.
3219 (mark_regno_live): Call make_hard_regno_live.
3220 (mark_regno_dead): Call make_hard_regno_dead with new arguement.
3221 (process_bb_lives): Call make_hard_regno_live and make_hard_regno_dead.
3222
3223 2018-09-29 H.J. Lu <hongjiu.lu@intel.com>
3224
3225 PR target/87370
3226 * config/i386/i386.c (construct_container): Use TImode for
3227 BLKmode values in 2 integer registers.
3228
3229 2018-09-29 Jeff Law <law@redhat.com>
3230
3231 * builtins.c (unterminated_array): Pass in c_strlen_data * to
3232 c_strlen rather than just a tree *.
3233 (c_strlen): Change NONSTR argument to a c_strlen_data pointer.
3234 Update recursive calls appropriately. If caller did not provide a
3235 suitable data pointer, create a local one. When a non-terminated
3236 string is discovered, bubble up information about the string via the
3237 c_strlen_data object.
3238 * builtins.h (c_strlen): Update prototype.
3239 (c_strlen_data): New structure.
3240 * gimple-fold.c (get_range_strlen): Update calls to c_strlen.
3241 For a type 2 call, if c_strlen indicates a non-terminated string
3242 use the length of the non-terminated string.
3243 (gimple_fold_builtin_stpcpy): Update calls to c_strlen.
3244
3245 2018-09-29 Jakub Jelinek <jakub@redhat.com>
3246
3247 PR target/87467
3248 * config/i386/avx512fintrin.h (_mm512_abs_pd, _mm512_mask_abs_pd): Use
3249 __m512d type for __A argument rather than __m512.
3250
3251 2018-09-28 John David Anglin <danglin@gcc.gnu.org>
3252
3253 * match.pd (simple_comparison): Don't optimize if either operand is
3254 a function pointer when target needs function pointer canonicalization.
3255
3256 2018-09-28 Segher Boessenkool <segher@kernel.crashing.org>
3257
3258 * config/rs6000/driver-rs6000.c (asm_names): Adjust the entries for
3259 power5 .. power9 to remove indirection.
3260 * config/rs6000/rs6000.h (ASM_CPU_POWER5_SPEC, ASM_CPU_POWER6_SPEC,
3261 ASM_CPU_POWER7_SPEC, ASM_CPU_POWER8_SPEC, ASM_CPU_POWER9_SPEC,
3262 ASM_CPU_476_SPEC): Delete.
3263 (ASM_CPU_SPEC): Adjust.
3264 (EXTRA_SPECS): Delete asm_cpu_power5, asm_cpu_power6, asm_cpu_power7,
3265 asm_cpu_power8, asm_cpu_power9, asm_cpu_476.
3266
3267 2018-09-28 Segher Boessenkool <segher@kernel.crashing.org>
3268
3269 * config.in: Delete HAVE_AS_DCI.
3270 * config/powerpcspe/powerpcspe.h: Treat HAVE_AS_DCI as always true.
3271 * config/rs6000/rs6000.h: Ditto.
3272 * configure.ac: Delete HAVE_AS_DCI.
3273 * configure: Regenerate.
3274
3275 2018-09-28 Segher Boessenkool <segher@kernel.crashing.org>
3276
3277 * config.in (HAVE_AS_LWSYNC): Delete.
3278 * config/powerpcspe/powerpcspe.h (TARGET_LWSYNC_INSTRUCTION): Delete.
3279 * config/powerpcspe/sync.md (*lwsync): Always generate lwsync, never
3280 do it as a .long .
3281 * config/rs6000/rs6000.h (TARGET_LWSYNC_INSTRUCTION): Delete.
3282 * config/rs6000/sync.md (*lwsync): Always generate lwsync, never do it
3283 as a .long .
3284 * configure.ac: Delete HAVE_AS_LWSYNC.
3285 * configure: Regenerate.
3286
3287 2018-09-28 Eric Botcazou <ebotcazou@adacore.com>
3288 Pierre-Marie de Rodat <derodat@adacore.com>
3289
3290 * calls.c (expand_call): Try to do a tail call for thunks at -O0 too.
3291 * cgraph.h (struct cgraph_thunk_info): Add indirect_offset.
3292 (cgraph_node::create_thunk): Add indirect_offset parameter.
3293 (thunk_adjust): Likewise.
3294 * cgraph.c (cgraph_node::create_thunk): Add indirect_offset parameter
3295 and initialize the corresponding field with it.
3296 (cgraph_node::dump): Dump indirect_offset field.
3297 * cgraphclones.c (duplicate_thunk_for_node): Deal with indirect_offset.
3298 * cgraphunit.c (cgraph_node::analyze): Be prepared for external thunks.
3299 (thunk_adjust): Add indirect_offset parameter and deal with it.
3300 (cgraph_node::expand_thunk): Deal with the indirect_offset field and
3301 pass it to thunk_adjust. Do not call the target hook if it's non-zero
3302 or if the thunk is external or local. Fix formatting. Do not chain
3303 the RESULT_DECL to BLOCK_VARS. Pass the static chain to the target,
3304 if any, in the GIMPLE representation.
3305 * ipa-icf.c (sem_function::equals_wpa): Deal with indirect_offset.
3306 * lto-cgraph.c (lto_output_node): Write indirect_offset field.
3307 (input_node): Read indirect_offset field.
3308 * tree-inline.c (expand_call_inline): Pass indirect_offset field in the
3309 call to thunk_adjust.
3310 * tree-nested.c (struct nesting_info): Add thunk_p field.
3311 (create_nesting_tree): Set it.
3312 (convert_all_function_calls): Copy static chain from targets to thunks.
3313 (finalize_nesting_tree_1): Return early for thunks.
3314 (unnest_nesting_tree_1): Do not finalize thunks.
3315 (gimplify_all_functions): Do not gimplify thunks.
3316
3317 2018-09-28 David Malcolm <dmalcolm@redhat.com>
3318
3319 * opt-suggestions.c (option_proposer::build_option_suggestions):
3320 Release "option_values".
3321
3322 2018-09-28 David Malcolm <dmalcolm@redhat.com>
3323
3324 * coverage.c (get_coverage_counts): Convert problem-reporting dump
3325 messages from MSG_OPTIMIZED_LOCATIONS to MSG_MISSED_OPTIMIZATION.
3326 * dumpfile.c (kind_as_string): New function.
3327 (dump_loc): Rather than a hardcoded prefix of "note: ", use
3328 kind_as_string to vary the prefix based on dump_kind.
3329 (selftest::test_capture_of_dump_calls): Update for above.
3330
3331 2018-09-28 Uros Bizjak <ubizjak@gmail.com>
3332
3333 * config/i386/i386.h (SSE_REGNO): Fix check for FIRST_REX_SSE_REG.
3334 (GET_SSE_REGNO): Rename from SSE_REGNO. Update all uses for rename.
3335
3336 2018-09-28 Uros Bizjak <ubizjak@gmail.com>
3337
3338 * config/i386/i386.h (CC_REGNO): Remove FPSR_REG.
3339 * config/i386/i386.c (ix86_fixed_condition_code_regs): Use
3340 INVALID_REGNUM instead of FPSR_REG.
3341 (ix86_md_asm_adjust): Do not clobber FPSR_REG.
3342 * config/i386/i386.md: Update comment of FP compares.
3343 (fldenv): Do not clobber FPSR_REG.
3344
3345 2018-09-28 Richard Biener <rguenther@suse.de>
3346
3347 * tree.h (BLOCK_ORIGIN): New.
3348 * omp-expand.c (grid_expand_target_grid_body): Assign
3349 BLOCK_ORIGIN to BLOCK_ABSTRACT_ORIGIN.
3350 * tree-inline.c (remap_block): Likewise.
3351 * auto-profile.c (get_function_decl_from_block): Simplify
3352 by eliding the BLOCK_ABSTRACT_ORIGIN chasing.
3353 * langhooks.c (lhd_print_error_function): Likewise.
3354 * optinfo-emit-json.cc (optrecord_json_writer::inlining_chain_to):
3355 Likewise.
3356 * tree-ssa-live.c (remove_unused_scope_block_p): Likewise.
3357 * tree.c (block_nonartificial_location): Likewise.
3358 (block_ultimate_origin): Likewise.
3359 * tree-pretty-print.c (percent_K_format): Likewise. Remove
3360 no longer needed LTO case.
3361
3362 2018-09-28 Andrew Stubbs <ams@codesourcery.com>
3363 Jan Hubicka <jh@suse.cz>
3364 Martin Jambor <mjambor@suse.cz>
3365
3366 * simplify-rtx.c (simplify_merge_mask): New function.
3367 (simplify_ternary_operation): Use it, also see if VEC_MERGEs with the
3368 same masks are used in op1 or op2.
3369 (test_vec_merge): New function.
3370 (test_vector_ops): Call test_vec_merge.
3371
3372 2018-09-28 Eric Botcazou <ebotcazou@adacore.com>
3373
3374 * config/sparc/sparc-protos.h (sparc_branch_cost): Declare.
3375 * config/sparc/sparc.h (BRANCH_COST): Call sparc_branch_cost.
3376 * config/sparc/sparc.c (struct processor_costs): Add branch_cost field.
3377 (cypress_costs): Set it.
3378 (supersparc_costs): Likewise.
3379 (hypersparc_costs): Likewise.
3380 (leon_cost): Likewise.
3381 (leon3_costs): Likewise.
3382 (sparclet_costs): Likewise.
3383 (ultrasparc_costs): Likewise.
3384 (ultrasparc_costs): Likewise.
3385 (niagara_costs): Likewise.
3386 (niagara2_costs): Likewise.
3387 (niagara3_costs): Likewise.
3388 (niagara4_costs): Likewise.
3389 (niagara7_costs): Likewise.
3390 (m8_costs): Likewise.
3391 (TARGET_CAN_FOLLOW_JUMP): Define.
3392 (pass_work_around_errata::gate): Minor tweak.
3393 (sparc_option_override): Remove MASK_FSMULD mask for V7 processors.
3394 Do not set both MASK_VIS4 and MASK_VIS4B for M8 processor.
3395 Automaitcally clear MASK_FSMULD mask for V7 processors.
3396 (sparc_can_follow_jump): New static function.
3397 (output_ubranch): Deal with CROSSING_JUMP_P.
3398 (sparc_use_sched_lookahead): Rewrite using switch statement.
3399 (sparc_issue_rate): Reorder.
3400 (sparc_branch_cost): New function.
3401
3402 2018-09-27 Martin Sebor <msebor@redhat.com>
3403
3404 * tree.h (tree_to_shwi): Add attribute nonnull and pure.
3405 (tree_to_poly_int64, tree_to_uhwi, tree_to_poly_uint64): Same.
3406 (int_fits_type_p): Same.
3407
3408 2018-09-27 Uros Bizjak <ubizjak@gmail.com>
3409
3410 * config/i386/i386.md (FPCR_REG): Remove.
3411 (UNSPEC_FLDCW): Remove.
3412 (x86_fnstcw_1): Use (const_int 0) instead of FPCR_REG.
3413 (x86_fldcw_1): Remove insn pattern.
3414 (fnstenv): Do not clobber FPCR_REG.
3415 (fldenv): Ditto.
3416 * config/i386/i386.h (FIXED_REGISTERS) Remove fpsr register.
3417 (CALL_USED_REGISTERS): Ditto.
3418 (REG_ALLOC_ORDER): Ditto.
3419 (REG_CLASS_CONTENTS): Ditto.
3420 (HI_REGISTER_NAMES): Ditto.
3421 (ADDITIONAL_REGISTER_NAMES): Use defines instead
3422 of numerical constants.
3423 * config/i386/i386.c (regclass_map): Remove fpsr register.
3424 (dbx_register_map): Ditto.
3425 (dbx64_register_map): Ditto.
3426 (svr4_dbx_register_map): Ditto.
3427 (print_reg): Do not handle FPCR_REG.
3428
3429 2018-09-27 Segher Boessenkool <segher@kernel.crashing.org>
3430
3431 PR target/87149
3432 * config.in (HAVE_AS_CMPB, HAVE_AS_DFP, HAVE_AS_FPRND, HAVE_AS_MFPGPR,
3433 HAVE_AS_POPCNTB, HAVE_AS_POPCNTD, HAVE_AS_POWER8, HAVE_AS_POWER9):
3434 Delete, always treat as true.
3435 * config/powerpcspe/powerpcspe.c (rs6000_option_override_internal):
3436 Ditto. Simplify remaining code.
3437 * config/powerpcspe/powerpcspe.h: Ditto.
3438 * config/rs6000/rs6000.c (rs6000_option_override_internal): Ditto.
3439 Simplify remaining code.
3440 (rs6000_expand_builtin): Ditto.
3441 * config/rs6000/rs6000.h: Ditto.
3442 * configure.ac: Ditto.
3443 * configure: Regenerate.
3444
3445 2018-09-27 Martin Liska <mliska@suse.cz>
3446
3447 * coverage.c (get_coverage_counts): Revert the formatting
3448 of missing profile opt info.
3449
3450 2018-09-27 Richard Biener <rguenther@suse.de>
3451
3452 PR debug/37801
3453 PR debug/87440
3454 * dwarf2out.c (set_block_origin_self): Do not mark outermost
3455 block as we do not output that.
3456 (gen_inlined_subroutine_die): Elide the originally outermost
3457 block, matching what we do for concrete instances.
3458 (decls_for_scope): Add parameter specifying whether to recurse
3459 to subblocks.
3460
3461 2018-09-27 Andrew Stubbs <ams@codesourcery.com>
3462 Tom de Vries <tom@codesourcery.com>
3463
3464 PR 82089
3465
3466 * expmed.c (emit_cstore): Fix handling of result_mode == BImode and
3467 STORE_FLAG_VALUE == 1.
3468
3469 2018-09-27 Andreas Krebbel <krebbel@linux.ibm.com>
3470
3471 * config/s390/s390.md (PPA_TX_ABORT, PPA_OOO_BARRIER): New
3472 constant definitions.
3473 ("tx_assist"): Replace magic number with PPA_TX_ABORT.
3474 ("*ppa"): Enable pattern also for -march=zEC12 -mno-htm.
3475 ("speculation_barrier"): New expander definition.
3476
3477 2018-09-26 Indu Bhagat <indu.bhagat@oracle.com>
3478
3479 PR gcov-profile/86957
3480 * common.opt: New warning option -Wmissing-profile.
3481 * coverage.c (get_coverage_counts): Add warning for missing .gcda file.
3482 * doc/invoke.texi: Document -Wmissing-profile.
3483
3484 2018-09-26 Jim Wilson <jimw@sifive.com>
3485
3486 * config/riscv/riscv.md (subsi3_extended2): Add J constraint.
3487 (negdi2, negsi2, negsi2_extended, negsi2_extended2): New.
3488
3489 2018-09-26 Martin Sebor <msebor@redhat.com>
3490
3491 * tree.c (zerop): Change return type to bool.
3492 (integer_zerop, integer_onep, integer_each_onep): Same.
3493 (integer_all_onesp, integer_minus_onep, integer_pow2p): Same.
3494 (integer_nonzerop, integer_truep, tree_ctz, real_zerop): Same.
3495 (real_onep, real_minus_onep, chain_index): Same.
3496 (print_type_hash_statistics, type_list_equal): Same.
3497 * tree.h (zerop): Same.
3498 (zerop, integer_zerop, integer_onep, integer_each_onep): Same.
3499 (integer_all_onesp, integer_minus_onep, integer_pow2p): Same.
3500 (integer_nonzerop, integer_truep, tree_ctz, real_zerop): Same.
3501 (real_onep, real_minus_onep, chain_index): Same.
3502 (print_type_hash_statistics, type_list_equal): Same.
3503
3504 2018-09-26 Jim Wilson <jimw@sifive.com>
3505
3506 * config/riscv/riscv.h (FUNCTION_ARG_REGNO_P): Fix comment.
3507
3508 2018-09-26 Jakub Jelinek <jakub@redhat.com>
3509
3510 PR target/87414
3511 * config/i386/i386.c: Include debug.h and dwarf2out.h.
3512 (output_indirect_thunk): Emit DW_CFA_def_cfa_offset after the
3513 call.
3514
3515 2018-09-25 Andrew Stubbs <ams@codesourcery.com>
3516
3517 * builtins.c (get_builtin_sync_mem): Force address mode conversion.
3518
3519 2018-09-26 Uros Bizjak <ubizjak@gmail.com>
3520
3521 * config/i386/i386.h (enum reg_class): Remove FP_TOP_SSE_REGS
3522 and FP_SECOND_SSE_REGS.
3523 (REG_CLASS_NAMES): Ditto.
3524 (REG_CLASS_CONTENTS): Ditto.
3525 * config/i386/i386.c (ix86_preferred_reload_class) Do not handle
3526 FP_TOP_SSE_REGS and FP_SECOND_SSE_REGS classes.
3527 (ix86_preferred_output_reload_class): Ditto.
3528 * config/i386/i386.md (fix_trunc<mode>_i387_fisttp): Change "=&1f"
3529 clobber constraint to "=&f".
3530 (fix_truncdi_i387): Ditto.
3531 (lrintxfdi2): Ditto.
3532 (fistdi2_<rounding>): Ditto.
3533 (fpremxf4_i387): Change "=u" constraint to "=f".
3534 (fprem1xf4_i387): Ditto.
3535 (sincosxf3): Ditto.
3536 (fptanxf4_i387): Ditto.
3537 (fxtractxf3_i387): Ditto.
3538 (fscalexf4_i387): Ditto.
3539 (atan2xf3): Change "u" constraint to "f".
3540 (fyl2xxf3_i387): Ditto.
3541 (fyl2xp1xf3_i387): Ditto.
3542
3543 2018-09-26 Uros Bizjak <ubizjak@gmail.com>
3544
3545 PR target/87439
3546 * config/i386/i386.h (NUM_MODES_FOR_MODE_SWITCHING): Update
3547 for removed I387_MASK_PM entity.
3548
3549
3550 2018-09-26 Jeff Law <law@redhat.com>
3551 Revert
3552 2018-09-26 Alexey Neyman <stilor@att.net>
3553
3554 * graphite.h: Include <isl/id.h> and <isl/space.h>; these
3555 headers are no longer pulled in by <isl/val.h>.
3556
3557 2018-09-26 Richard Biener <rguenther@suse.de>
3558
3559 PR debug/87443
3560 * dwarf2out.c (gen_lexical_block_die): Do not equate inline
3561 or concrete instance DIE to the tree. Create abstract origin
3562 attributes also for concrete instances.
3563
3564 2018-09-26 Alexey Neyman <stilor@att.net>
3565
3566 * graphite.h: Include <isl/id.h> and <isl/space.h>; these
3567 headers are no longer pulled in by <isl/val.h>.
3568
3569 2018-09-26 Matthew Malcomson <matthew.malcomson@arm.com>
3570
3571 * config/arm/arm.c (arm_split_compare_and_swap, arm_split_atomic_op):
3572 Use new helper functions.
3573 * config/arm/sync.md (atomic_load<mode>, atomic_store<mode>):
3574 Use new helper functions.
3575 * config/arm/aarch-common-protos.h (aarch_mm_needs_acquire,
3576 aarch_mm_needs_release): New declarations.
3577 * config/arm/aarch-common.c (aarch_mm_needs_acquire,
3578 aarch_mm_needs_release): New.
3579
3580 2018-09-26 Eric Botcazou <ebotcazou@adacore.com>
3581
3582 * config/arm/arm.c (arm_reorg): Skip Thumb reorg pass for thunks.
3583 (arm32_output_mi_thunk): Deal with long calls.
3584
3585 2018-09-26 Richard Biener <rguenther@suse.de>
3586
3587 PR debug/87428
3588 PR debug/87362
3589 * tree-inline.c (expand_call_inline): When the location
3590 of the call is UNKNOWN_LOCATION use DECL_SOURCE_LOCATION
3591 or BUILTINS_LOCATION for the BLOCK_SOURCE_LOCATION of
3592 the inserted BLOCK to make inlined_function_outer_scope_p
3593 recognize it.
3594 * dwarf2out.c (add_call_src_coords_attributes): Do not add
3595 coords for reserved locations.
3596
3597 2018-09-25 Segher Boessenkool <segher@kernel.crashing.org>
3598
3599 * config/rs6000/rs6000.md (*movcc_internal1): Use set_attr_alternative.
3600 (*call_indirect_nonlocal_sysv<mode>): Ditto.
3601 (*call_value_indirect_nonlocal_sysv<mode>): Ditto.
3602 (*sibcall_nonlocal_sysv<mode>): Ditto.
3603 (*sibcall_value_nonlocal_sysv<mode>): Ditto.
3604 (<bd>_<mode>): Ditto.
3605 (<bd>tf_<mode>): Ditto.
3606
3607 2018-09-25 Segher Boessenkool <segher@kernel.crashing.org>
3608
3609 * config/rs6000/altivec.md (*altivec_mov<mode>): Write the output
3610 control string as a list of templates instead of as C code.
3611 (*altivec_movti): Ditto.
3612 * config/rs6000/darwin.md (movdf_low_di): Ditto.
3613
3614 2018-09-25 Jim Wilson <jimw@sifive.com>
3615
3616 * config/riscv/riscv.c (riscv_split_symbol): Mark auipc label as weak
3617 when target symbol is weak.
3618
3619 2018-09-25 Bernd Edlinger <bernd.edlinger@hotmail.de>
3620
3621 PR c/87387
3622 * builtins.c (unterminated_array): Simplify.
3623 * expr.c (string_constant): Handle SSA_NAME. Add more exceptions
3624 where pointer arithmetic is safe.
3625
3626 2018-09-25 Segher Boessenkool <segher@kernel.crashing.org>
3627
3628 PR target/86987
3629 * config/rs6000/altivec.md (altivec_vspltb): Use
3630 const_0_to_15_operand instead of u5bit_cint_operand.
3631 (*altivec_vspltb_internal): Ditto.
3632 (altivec_vspltb_direct): Ditto.
3633 (altivec_vsplth): Use const_0_to_7_operand instead of
3634 u5bit_cint_operand.
3635 (*altivec_vsplth_internal): Ditto.
3636 (altivec_vsplth_direct): Ditto.
3637 (altivec_vspltw): Use const_0_to_3_operand instead of
3638 u5bit_cint_operand.
3639 (*altivec_vspltw_internal): Ditto.
3640 (altivec_vspltw_direct): Ditto.
3641 (altivec_vspltsf): Ditto.
3642 (*altivec_vspltsf_internal): Ditto.
3643 * config/rs6000/rs6000.c (rs6000_expand_binop_builtin): Handle the
3644 various splats with the proper size immediate. Reorder the various
3645 cases by ascending size of immediate, and put all such together.
3646
3647 2018-09-25 Richard Biener <rguenther@suse.de>
3648
3649 PR debug/83941
3650 * dwarf2out.c (add_AT_external_die_ref): Remove now redundant
3651 GC-ification.
3652 (maybe_create_die_with_external_ref): Do not create
3653 DW_TAG_imported_unit here.
3654 (add_abstract_origin_attribute): Handle external BLOCK refs.
3655 (dwarf2out_abstract_function): Simplify LTO case.
3656 (dwarf2out_early_finish): Create DW_TAG_imported_unit explicitely
3657 rather than using maybe_create_die_with_external_ref.
3658
3659 2018-09-25 Uros Bizjak <ubizjak@gmail.com>
3660
3661 PR target/71278
3662 * config/i386/i386.md (frndintxf2_mask_pm): Remove.
3663 (frndintxf2_mask_pm_i387): Ditto.
3664 (nearbyintxf2): Rewrite expander pattern to match rintxf2.
3665 Enable for !flag_trapping_math.
3666 (nearbyint<mode>2): Enable x87 modes for !flag_trapping_math.
3667 Enable SSE modes for TARGET_SSE4_1 and expand them with round insn.
3668 Change operand 1 predicate to nonimmediate_operand.
3669 (attr "i387_cw"): Remove mask_pm.
3670 * config/i386/i386.h (enum ix86_stack_slot): Remove SLOT_CW_MASK_PM.
3671 (enum ix86_entity): Remove I387_MASK_PM.
3672 * config/i386/i386.c (ix86_i387_mode_needed): Do not
3673 handle I387_MASK_PM.
3674 (ix86_mode_needed): Ditto.
3675 (ix86_mode_after): Ditto.
3676 (ix86_mode_entry): Ditto.
3677 (ix86_mode_exit): Ditto.
3678 (emit_i387_cw_initialization): Do not handle I387_CW_MASK_PM.
3679
3680 2018-09-25 Jakub Jelinek <jakub@redhat.com>
3681
3682 * vr-values.c (vr_values::vr_values): Initialize to_remove_edges and
3683 to_update_switch_stmts to vNULL instead of calling create on them
3684 immediately.
3685
3686 2018-09-25 Richard Biener <rguenther@suse.de>
3687
3688 PR tree-optimization/87402
3689 * tree-ssa-sccvn.c (SSA_VISITED): Remove unused function.
3690 (visit_phi): Re-instantiate handling of supposed to be VARYING
3691 but non-VARYING backedge value.
3692
3693 2018-09-25 Richard Biener <rguenther@suse.de>
3694
3695 PR debug/83941
3696 * dwarf2out.c (struct sym_off_pair): New.
3697 (external_die_map): New global.
3698 (lookup_decl_die): When in LTO create DIEs lazily from the
3699 external_die_map.
3700 (lookup_block_die): New function, create DIEs lazily in LTO.
3701 (equate_block_to_die): New function.
3702 (dwarf2out_die_ref_for_decl): During WPA get the association
3703 from the external DIE map.
3704 (dwarf2out_register_external_die): Record mapping into the
3705 external DIE map.
3706 (maybe_create_die_with_external_ref): New function split out from
3707 DIE generation part of old dwarf2out_register_external_die.
3708 (add_abstract_origin_attribute): Do not return the DIE. When
3709 in LTO reference externals directly.
3710 (dwarf2out_abstract_function): When in LTO ignore calls for
3711 decls with external DIEs (already present abstract instances).
3712 (gen_call_site_die): Adjust.
3713 (add_high_low_attributes): Likewise.
3714 (gen_lexical_block_die): Likewise.
3715 (gen_inlined_subroutine_die): Likewie.
3716 (gen_block_die): Likewise.
3717 (dwarf2out_inline_entry): Likewise.
3718 (dwarf2out_early_finish): In LTRANS phase create DW_TAG_imported_unit
3719 DIEs.
3720
3721 2018-09-25 Martin Liska <mliska@suse.cz>
3722
3723 * ipa-fnsummary.c (estimate_node_size_and_time): Scale by two
3724 integers and not by a float value.
3725
3726 2018-09-25 Martin Liska <mliska@suse.cz>
3727
3728 PR fortran/87394
3729 * dbgcnt.c (dbg_cnt_process_single_pair): Return false
3730 instead of NULL.
3731 * dumpfile.c (dump_enable_all): Remove extra parenthesis.
3732 * gcov-tool.c: Declare the function with ATTRIBUTE_NORETURN.
3733 * godump.c (go_format_type): Remove extra parenthesis.
3734
3735 2018-09-25 Martin Liska <mliska@suse.cz>
3736
3737 * alias.c (set_dest_equal_p): Remove unused function.
3738 * config/i386/i386.c (def_builtin_pure2): Likewise.
3739 * diagnostic-show-locus.c (class layout): Remove
3740 unused field.
3741 (layout::layout): Likewise here.
3742 * dump-context.h (class temp_dump_context): Likewise.
3743 * dwarf2out.c (add_AT_fde_ref): Remove unused function.
3744 (add_AT_loclistsptr): Likewise.
3745 (add_AT_offset): Likewise.
3746 (get_AT_hi_pc): Likewise.
3747 (is_comdat_die): Likewise.
3748 (type_is_enum): Likewise.
3749 (ceiling): Likewise.
3750 (add_AT_vms_delta): Likewise.
3751 (is_class_die): Likewise.
3752 * edit-context.c (class line_event): Remove unused field.
3753 * graphite-sese-to-poly.c (tree_int_to_gmp): Remove
3754 unused function.
3755 * ipa-cp.c (ipa_get_vr_lat): Likewise.
3756 * lra-constraints.c (ok_for_index_p_nonstrict): Likewise.
3757 (ok_for_base_p_nonstrict): Likewise.
3758 * tree-chrec.c (is_not_constant_evolution): Likewise.
3759 (chrec_fold_poly_cst): Likewise.
3760 * tree-if-conv.c (has_pred_critical_p): Likewise.
3761 * tree-ssa-coalesce.c (print_exprs): Likewise.
3762 * tree-ssa-pre.c (bitmap_set_contains_expr): Likewise.
3763 * tree-ssa-uninit.c (is_and_or_or_p): Likewise.
3764 * tree-vrp.c (value_ranges_intersect_p): Likewise.
3765 (value_range_nonnegative_p): Likewise.
3766
3767 2018-09-25 Martin Liska <mliska@suse.cz>
3768
3769 * config/powerpcspe/powerpcspe.c (rs6000_output_function_epilogue):
3770 Do not handle "GNU Pascal".
3771 * config/rs6000/rs6000.c (rs6000_output_function_epilogue):
3772 Likewise.
3773 * config/sparc/sparc.c (sparc_pass_by_reference): Remove Pascal
3774 from documentation. Likewise.
3775 * dbxout.c (dbxout_range_type): Likewise.
3776 * doc/cpp.texi: Likewise.
3777 * doc/extend.texi: Likewise.
3778 * doc/frontends.texi: Likewise.
3779 * doc/invoke.texi: Remove Pascal entry.
3780 * tree.def (CLEANUP_POINT_EXPR): Likewise.
3781 * doc/rtl.texi (MODE_FUNCTION): Remove not used entry.
3782
3783 2018-09-25 Martin Liska <mliska@suse.cz>
3784
3785 PR middle-end/86078
3786 * doc/invoke.texi: Document all parameters and remove default
3787 of the parameters.
3788
3789 2018-09-25 Ilya Leoshkevich <iii@linux.ibm.com>
3790
3791 PR bootstrap/87417
3792 * rtl.c (rtx_code_size): Take into account that EQ_ATTR_ALT
3793 contains HOST_WIDE_INTs when computing its size.
3794
3795 2018-09-24 Jim Wilson <jimw@sifive.com>
3796
3797 PR target/87391
3798 * config/riscv/riscv.h (STACK_BOUNDARY): Test riscv_abi == ABI_ILP32E
3799 not TARGET_RVE.
3800 (ABI_STACK_BOUNDARY, MAX_ARGS_IN_REGISTERS): Likewise.
3801
3802 2018-09-24 Andrew Pinski <apinski@marvell.com>
3803
3804 * config/aarch64/aarch64.c (aarch_macro_fusion_pair_p): Don't
3805 access prev before checking it for NULLness in the
3806 AARCH64_FUSE_CMP_BRANCH case.
3807
3808 2018-09-24 H.J. Lu <hongjiu.lu@intel.com>
3809
3810 PR target/82699
3811 * config/i386/i386.c (rest_of_insert_endbranch): Set
3812 endbr_queued_at_entrance to true and don't insert ENDBR if
3813 x86_function_profiler will be called.
3814 (x86_function_profiler): Insert ENDBR if endbr_queued_at_entrance
3815 is true.
3816 * config/i386/i386.h (machine_function): Add
3817 endbr_queued_at_entrance.
3818
3819 2018-09-24 Ilya Leoshkevich <iii@linux.ibm.com>
3820
3821 * genattrtab.c (mk_attr_alt): Use alternative_mask.
3822 (attr_rtx_1): Adjust caching to match the new EQ_ATTR_ALT field
3823 types.
3824 (check_attr_test): Use alternative_mask.
3825 (get_attr_value): Likewise.
3826 (compute_alternative_mask): Use alternative_mask and XWINT.
3827 (make_alternative_compare): Use alternative_mask.
3828 (attr_alt_subset_p): Use XWINT.
3829 (attr_alt_subset_of_compl_p): Likewise.
3830 (attr_alt_intersection): Use alternative_mask and XWINT.
3831 (attr_alt_union): Likewise.
3832 (attr_alt_complement): Use HOST_WIDE_INT and XWINT.
3833 (mk_attr_alt): Use alternative_mask and HOST_WIDE_INT.
3834 (simplify_test_exp): Use alternative_mask and XWINT.
3835 (write_test_expr): Use alternative_mask and XWINT, adjust bit
3836 number calculation to support 64 bits. Generate code that
3837 checks 64-bit masks.
3838 (main): Use alternative_mask.
3839 * rtl.def (EQ_ATTR_ALT): Change field types from ii to ww.
3840
3841 2018-09-24 Ilya Leoshkevich <iii@linux.ibm.com>
3842
3843 PR target/80080
3844 * config/s390/s390.c (s390_emit_epilogue): Do not use PARALLEL
3845 RETURN+USE when returning via %r14.
3846
3847 2018-09-24 Martin Liska <mliska@suse.cz>
3848
3849 * gcov.c (output_lines): Print colorization legend
3850 for both flag_use_colors and flag_use_hotness_colors.
3851 Reword the help.
3852
3853 2018-09-24 Martin Liska <mliska@suse.cz>
3854
3855 * coverage.c (get_coverage_counts): Use warning_at
3856 with current_function_decl location. Use %qD in warning
3857 message.
3858
3859 2018-09-24 Martin Liska <mliska@suse.cz>
3860
3861 * memory-block.h (memory_block_pool::release): Annotate with
3862 valgrind that the memory is not accessible.
3863
3864 2018-09-24 Martin Liska <mliska@suse.cz>
3865
3866 PR sanitizer/85774
3867 * asan.c: Make asan_handled_variables extern.
3868 * asan.h: Likewise.
3869 * cfgexpand.c (expand_stack_vars): Make sure
3870 a representative is unpoison if another
3871 variable in the partition is handled by
3872 use-after-scope sanitization.
3873
3874 2018-09-24 Richard Biener <rguenther@suse.de>
3875
3876 PR tree-optimization/63155
3877 * tree-ssa-propagate.c (add_ssa_edge): Avoid adding PHIs to
3878 the worklist when the edge of the respective argument isn't
3879 executable.
3880
3881 2018-09-23 Uros Bizjak <ubizjak@gmail.com>
3882
3883 * config/i386/i386.h (enum reg_class): Rename MASK_REGS to
3884 ALL_MASK_REGS and MASK_EVEX_REGS to MASK_REGS.
3885 (MASK_CLASS_P): Update for rename.
3886 (MAYBE_MASK_CLASS_P): Ditto.
3887 (REG_CLASS_NAMES): Update.
3888 (REG_CLASS_CONTENT): Update.
3889 * config/i386/i386.c (regclass_map): Update for MASK_REG
3890 and ALL_MASK_REGS rename.
3891 * config/i386/constraints.md (Yk): Update for rename.
3892 (k): Ditto.
3893
3894 2018-09-23 Uros Bizjak <ubizjak@gmail.com>
3895
3896 * config/i386/i386.h (enum reg_class): Remove
3897 EVEX_SSE_REGS and MOD4_SSE_REGS.
3898 (REG_CLASS_NAMES): Update.
3899 (REG_CLASS_CONTENT): Update.
3900 * config/i386/i386.c (regclass_map): Declare AVX-512 SSE
3901 registers as ALL_SSE_REGS.
3902 (ix86_additional_allocno_class_p): Remove.
3903 (TARGET_ADDITIONAL_ALLOCNO_CLASS_P): Remove.
3904 (ix86_register_priority): Lower priority of EVEX SSE registers.
3905 Use IN_RANGE macro where appropriate.
3906 (ix86_hard_regno_mode_ok): Merge AVX-5124FMAPS and
3907 AVX-5124VNNIW checks.
3908 (ix86_modes_tieable_p): Tie 512-bit SSE modes.
3909 * config/i386/sse.md (avx5124fmaddps_4fmaddps)
3910 (avx5124fmaddps_4fmaddps_mask, avx5124fmaddps_4fmaddps_maskz)
3911 (avx5124fmaddps_4fmaddss, avx5124fmaddps_4fmaddss_mask)
3912 (avx5124fmaddps_4fmaddss_maskz, avx5124fmaddps_4fnmaddps)
3913 (avx5124fmaddps_4fnmaddps_mask, avx5124fmaddps_4fnmaddps_maskz)
3914 (avx5124fmaddps_4fnmaddss, avx5124fmaddps_4fnmaddss_mask)
3915 (avx5124fmaddps_4fnmaddss_maskz, avx5124vnniw_vp4dpwssd)
3916 (avx5124vnniw_vp4dpwssd_mask, avx5124vnniw_vp4dpwssd_maskz)
3917 (avx5124vnniw_vp4dpwssds, avx5124vnniw_vp4dpwssds_mask)
3918 (avx5124vnniw_vp4dpwssds_maskz): Use "v" instead of "Yh" constraint.
3919 * config/i386/constraints.md (Yh): Remove.
3920
3921 2018-09-23 Uros Bizjak <ubizjak@gmail.com>
3922
3923 * config/i386/i386.c (regclass_map): Declare integer REX registers
3924 as GENERAL_REGS.
3925
3926 2018-09-23 Gerald Pfeifer <gerald@pfeifer.com>
3927
3928 * doc/service.texi (Service): Switch the fsf.org link to https.
3929
3930 2018-09-22 Chung-Ju Wu <jasonwucj@gmail.com>
3931
3932 PR target/86798
3933 * config/nds32/nds32.c (TARGET_HAVE_SPECULATION_SAFE_VALUE):
3934 Define to speculation_safe_value_not_needed.
3935
3936 2018-09-21 Florian Weimer <fweimer@redhat.com>
3937
3938 PR middle-end/81035
3939 * doc/extend.texi (Common Function Attributes): Mention that
3940 noreturn suppresses tail call optimization.
3941
3942 2018-09-21 Jeff Law <law@redhat.com>
3943
3944 * gimple-ssa-evrp.c (evrp_dom_walker::cleanup): Call
3945 vr_values::cleanup_edges_and_switches.
3946 * tree-vrp.c (to_remove_edges, to_update_switch_stmts): Moved into
3947 vr_values class.
3948 (identify_jump_threads): Remove EDGE_IGNORE handling.
3949 (execute_vrp): Move handling of to_remove_edges and
3950 to_update_switch_stmts into vr_values class member functions.
3951 * tree-vrp.h (switch_update, to_remove_edges): Remove declarations.
3952 (to_update_switch_stmts): Likewise.
3953 * vr-values.c: Include cfghooks.h.
3954 (vr_values::vr_values): Initialize to_remove_edges and
3955 to_update_switch_stmts.
3956 (vr_values::~vr_values): Verify to_remove_edges and
3957 to_update_switch_stmts are empty.
3958 (vr_values::simplify_switch_using_ranges): Set EDGE_IGNORE as needed.
3959 (vr_values::cleanup_edges_and_switches): New member function.
3960 * vr-values.h (vr_values): Add cleanup_edges_and_switches member
3961 function. Add new data members.
3962
3963 2018-09-21 David Malcolm <dmalcolm@redhat.com>
3964
3965 PR tree-optimization/87309
3966 * dumpfile.c (dump_context::begin_scope): Filter the dump_loc
3967 calls with pflags and alt_flags.
3968 (selftest::test_capture_of_dump_calls): Add test of interaction of
3969 MSG_OPTIMIZED_LOCATIONS with AUTO_DUMP_SCOPE.
3970
3971 2018-09-21 Olivier Hainque <hainque@adacore.com>
3972
3973 * config.gcc: Factorize and comment inclusion of vxworks-dummy.h.
3974
3975 2018-09-21 Olivier Hainque <hainque@adacore.com>
3976
3977 * config/vxworks.h (CLEAR_INSN_CACHE): #define to 1.
3978
3979 2018-09-21 Olivier Hainque <hainque@adacore.com>
3980
3981 * config/vxworks.h (VXWORKS_LIBGCC_SPEC): Remove -lc_internal.
3982 Merge block comment with the one ahead of VXWORKS_LIBS_RTP. Then:
3983 (VXWORKS_LIBS_RTP): Minor reordering.
3984
3985 2018-09-21 Olivier Hainque <hainque@adacore.com>
3986
3987 * config/vxworks.h (STARTFILE_PREFIX_SPEC): Define.
3988 (VXWORKS_LIBS_DIR_RTP): Remove definition and use.
3989
3990 2018-09-21 Olivier Hainque <hainque@adacore.com>
3991
3992 * config/vxworks.h (SIZE_TYPE): Account for TARGET_VXWORKS64.
3993 (PTRDIFF_TYPE): Likewise.
3994
3995 2018-09-21 Olivier Hainque <hainque@adacore.com>
3996
3997 * config.gcc: Enforce def of TARGET_VXWORKS64 to 1 from
3998 triplet, similar to support for VxWorks7.
3999 * config/vxworks-dummy.h: Provide a default definition
4000 of TARGET_VXWORKS64 to 0.
4001
4002 2018-09-21 Olivier Hainque <hainque@adacore.com>
4003
4004 * config/vxworks.h (TARGET_VXWORKS7): Move default definition ...
4005 * config/vxworks-dummy.h: here.
4006
4007 2018-09-21 Olivier Hainque <hainque@adacore.com>
4008
4009 * config.gcc: Prepend vxworks-dummy.h to tm_file for powerpc*
4010
4011 2018-09-21 Shaokun Zhang <zhangshaokun@hisilicon.com>
4012 Bo Zhou <zbo.zhou@hisilicon.com>
4013
4014 * config/aarch64/aarch64-cores.def (tsv110): New CPU.
4015 * config/aarch64/aarch64-tune.md: Regenerated.
4016 * doc/invoke.texi (AArch64 Options/-mtune): Add "tsv110".
4017 * config/aarch64/aarch64.c (tsv110_tunings): New tuning table.
4018 * config/aarch64/aarch64-cost-tables.h: Add "tsv110" extra costs.
4019
4020 2018-09-21 Andrew Stubbs <ams@codesourcery.com>
4021 Julian Brown <julian@codesourcery.com>
4022
4023 * builtins.c (get_builtin_sync_mem): Handle address spaces.
4024
4025 2018-09-21 Eric Botcazou <ebotcazou@adacore.com>
4026
4027 * config/rs6000/rs6000.c (rs6000_function_ok_for_sibcall): Return false
4028 if the call takes a static chain.
4029
4030 2018-09-21 Martin Liska <mliska@suse.cz>
4031
4032 * auto-profile.c (autofdo_source_profile::read): Do not
4033 set sum_all.
4034 (read_profile): Do not add working sets.
4035 (read_autofdo_file): Remove sum_all.
4036 (afdo_callsite_hot_enough_for_early_inline): Remove const
4037 qualifier.
4038 * coverage.c (struct counts_entry): Remove gcov_summary.
4039 (read_counts_file): Read new GCOV_TAG_OBJECT_SUMMARY,
4040 do not support GCOV_TAG_PROGRAM_SUMMARY.
4041 (get_coverage_counts): Remove summary and expected
4042 arguments.
4043 * coverage.h (get_coverage_counts): Likewise.
4044 * doc/gcov-dump.texi: Remove -w option.
4045 * gcov-dump.c (dump_working_sets): Remove.
4046 (main): Do not support '-w' option.
4047 (print_usage): Likewise.
4048 (tag_summary): Likewise.
4049 * gcov-io.c (gcov_write_summary): Do not dump
4050 histogram.
4051 (gcov_read_summary): Likewise.
4052 (gcov_histo_index): Remove.
4053 (gcov_histogram_merge): Likewise.
4054 (compute_working_sets): Likewise.
4055 * gcov-io.h (GCOV_TAG_OBJECT_SUMMARY): Mark
4056 it not obsolete.
4057 (GCOV_TAG_PROGRAM_SUMMARY): Mark it obsolete.
4058 (GCOV_TAG_SUMMARY_LENGTH): Adjust.
4059 (GCOV_HISTOGRAM_SIZE): Remove.
4060 (GCOV_HISTOGRAM_BITVECTOR_SIZE): Likewise.
4061 (struct gcov_summary): Simplify rapidly just
4062 to runs and sum_max fields.
4063 (gcov_histo_index): Remove.
4064 (NUM_GCOV_WORKING_SETS): Likewise.
4065 (compute_working_sets): Likewise.
4066 * gcov-tool.c (print_overlap_usage_message): Remove
4067 trailing empty line.
4068 * gcov.c (read_count_file): Read GCOV_TAG_OBJECT_SUMMARY.
4069 (output_lines): Remove program related line.
4070 * ipa-profile.c (ipa_profile): Do not consider GCOV histogram.
4071 * lto-cgraph.c (output_profile_summary): Do not stream GCOV
4072 histogram.
4073 (input_profile_summary): Do not read it.
4074 (merge_profile_summaries): And do not merge it.
4075 (input_symtab): Do not call removed function.
4076 * modulo-sched.c (sms_schedule): Do not print sum_max.
4077 * params.def (HOT_BB_COUNT_FRACTION): Reincarnate param that was
4078 removed when histogram method was invented.
4079 (HOT_BB_COUNT_WS_PERMILLE): Mention that it's used only in LTO
4080 mode.
4081 * postreload-gcse.c (eliminate_partially_redundant_load): Fix
4082 GCOV coding style.
4083 * predict.c (get_hot_bb_threshold): Use HOT_BB_COUNT_FRACTION
4084 and dump selected value.
4085 * profile.c (add_working_set): Remove.
4086 (get_working_sets): Likewise.
4087 (find_working_set): Likewise.
4088 (get_exec_counts): Do not work with working sets.
4089 (read_profile_edge_counts): Do not inform as sum_max is removed.
4090 (compute_branch_probabilities): Likewise.
4091 (compute_value_histograms): Remove argument for call of
4092 get_coverage_counts.
4093 * profile.h: Do not make gcov_summary const.
4094
4095 2018-09-21 Monk Chiang <sh.chiang04@gmail.com>
4096
4097 * config.gcc (nds32*-*-*): Set TARGET_DEFAULT_TLSDESC_TRAMPOLINE=0.
4098
4099 2018-09-21 Eric Botcazou <ebotcazou@adacore.com>
4100
4101 PR tree-optimization/86990
4102 * gimple-ssa-store-merging.c (imm_store_chain_info:coalesce_immediate):
4103 Check that the entire merged store group is made of constants only for
4104 overlapping stores.
4105
4106 2018-09-20 Allan Sandfeld Jensen <allan.jensen@qt.io>
4107
4108 * gcc.c (LINK_COMMAND_SPEC): Handle -r like -nostdlib.
4109 (VTABLE_VERIFICATION_SPEC): Likewise.
4110 (SANITIZER_EARLY_SPEC): Likewise.
4111 (SANITIZER_SPEC): Likewise.
4112 * config/darwin.h (LINK_COMMAND_SPEC): Likewise.
4113 * doc/invoke.texi (Link Options): Document -r.
4114
4115 2018-09-20 Richard Biener <rguenther@suse.de>
4116
4117 PR middle-end/87054
4118 * gimplify.c (gimplify_expr): Retain alignment of
4119 addressable lvalue in dereference.
4120
4121 2018-09-20 Alexandre Oliva <aoliva@redhat.com>
4122
4123 PR bootstrap/87013
4124 * configure.ac: Check for .loc is_stmt support.
4125 * configure, config.in: Rebuilt.
4126 * dwarf2out.c (dwarf2out_source_line): Skip is_stmt
4127 if not supported.
4128
4129 2018-09-20 Segher Boessenkool <segher@kernel.crashing.org>
4130
4131 * config/rs6000/rs6000.opt (misel=no, misel=yes): Delete.
4132 * doc/invoke.texi (RS/6000 and PowerPC Options): Delete -misel=yes and
4133 -misel=no.
4134
4135 2018-09-20 Segher Boessenkool <segher@kernel.crashing.org>
4136
4137 * config/rs6000/rs6000-opts.h (enum rs6000_vector): Delete
4138 VECTOR_OTHER.
4139 * config/rs6000/rs6000.c (rs6000_debug_vector_unit): Delete
4140 case VECTOR_OTHER.
4141
4142 2018-09-20 Marek Polacek <polacek@redhat.com>
4143
4144 * doc/invoke.texi: Add -Wno-init-list-lifetime to C++ Language Options.
4145
4146 2018-09-20 Richard Sandiford <richard.sandiford@arm.com>
4147
4148 PR tree-optimization/87288
4149 * tree-vect-loop.c (vect_analyze_loop_2): Take PEELING_FOR_GAPS
4150 into account when determining PEELING_FOR_NITERS.
4151
4152 2018-09-20 Richard Sandiford <richard.sandiford@arm.com>
4153
4154 PR tree-optimization/86877
4155 * tree-vect-loop.c (vect_analyze_loop_2): Call
4156 vect_verify_datarefs_alignment.
4157
4158 2018-09-19 Marek Polacek <polacek@redhat.com>
4159
4160 * doc/invoke.texi: Document -Wclass-conversion.
4161
4162 2018-09-19 John David Anglin <danglin@gcc.gnu.org>
4163
4164 * config/pa/pa.c (pa_adjust_priority): Delete.
4165 (TARGET_SCHED_ADJUST_PRIORITY): Delete define.
4166
4167 * config/pa/pa.md (atomic_storeqi): Restore deleted expander.
4168 (atomic_storehi): Likewise.
4169 (atomic_storesi): Likewise.
4170 (atomic_loaddi): Restore compare and swap exchange loop code.
4171
4172 2018-09-19 Segher Boessenkool <segher@kernel.crashing.org>
4173
4174 PR rtl-optimization/86902
4175 * combine.c (try_combine): When changing the CC mode used, don't change
4176 an unrelated mode in other_insn to that new CC mode.
4177
4178 2018-09-19 David Malcolm <dmalcolm@redhat.com>
4179
4180 * tree-data-ref.c (runtime_alias_check_p): Use formatted printing
4181 with %T in place of calls to dump_generic_expr.
4182 (prune_runtime_alias_test_list): Likewise.
4183 (create_runtime_alias_checks): Likewise.
4184 * tree-vect-data-refs.c (vect_check_nonzero_value): Likewise.
4185 (vect_analyze_data_ref_dependence): Likewise.
4186 (vect_slp_analyze_data_ref_dependence): Likewise.
4187 (vect_record_base_alignment): Likewise. Use %G in place of call
4188 to dump_gimple_stmt.
4189 (vect_compute_data_ref_alignment): Likewise.
4190 (verify_data_ref_alignment): Likewise.
4191 (vect_find_same_alignment_drs): Likewise.
4192 (vect_analyze_group_access_1): Likewise.
4193 (vect_analyze_data_ref_accesses): Likewise.
4194 (dependence_distance_ge_vf): Likewise.
4195 (dump_lower_bound): Likewise.
4196 (vect_prune_runtime_alias_test_list): Likewise.
4197 (vect_find_stmt_data_reference): Likewise.
4198 (vect_analyze_data_refs): Likewise.
4199 (vect_create_addr_base_for_vector_ref): Likewise.
4200 (vect_create_data_ref_ptr): Likewise.
4201 * tree-vect-loop-manip.c (vect_set_loop_condition): Likewise.
4202 (vect_can_advance_ivs_p): Likewise.
4203 (vect_update_ivs_after_vectorizer): Likewise.
4204 (vect_gen_prolog_loop_niters): Likewise.
4205 (vect_prepare_for_masked_peels): Likewise.
4206 * tree-vect-loop.c (vect_determine_vf_for_stmt): Likewise.
4207 (vect_determine_vectorization_factor): Likewise.
4208 (vect_is_simple_iv_evolution): Likewise.
4209 (vect_analyze_scalar_cycles_1): Likewise.
4210 (vect_analyze_loop_operations): Likewise.
4211 (report_vect_op): Likewise.
4212 (vect_is_slp_reduction): Likewise.
4213 (check_reduction_path): Likewise.
4214 (vect_is_simple_reduction): Likewise.
4215 (vect_create_epilog_for_reduction): Likewise.
4216 (vect_finalize_reduction:): Likewise.
4217 (vectorizable_induction): Likewise.
4218 (vect_transform_loop_stmt): Likewise.
4219 (vect_transform_loop): Likewise.
4220 (optimize_mask_stores): Likewise.
4221 * tree-vect-patterns.c (vect_pattern_detected): Likewise.
4222 (vect_split_statement): Likewise.
4223 (vect_recog_over_widening_pattern): Likewise.
4224 (vect_recog_average_pattern): Likewise.
4225 (vect_determine_min_output_precision_1): Likewise.
4226 (vect_determine_precisions_from_range): Likewise.
4227 (vect_determine_precisions_from_users): Likewise.
4228 (vect_mark_pattern_stmts): Likewise.
4229 (vect_pattern_recog_1): Likewise.
4230 * tree-vect-slp.c (vect_get_and_check_slp_defs): Likewise.
4231 (vect_record_max_nunits): Likewise.
4232 (vect_build_slp_tree_1): Likewise.
4233 (vect_build_slp_tree_2): Likewise.
4234 (vect_print_slp_tree): Likewise.
4235 (vect_analyze_slp_instance): Likewise.
4236 (vect_detect_hybrid_slp_stmts): Likewise.
4237 (vect_detect_hybrid_slp_1): Likewise.
4238 (vect_slp_analyze_operations): Likewise.
4239 (vect_slp_analyze_bb_1): Likewise.
4240 (vect_transform_slp_perm_load): Likewise.
4241 (vect_schedule_slp_instance): Likewise.
4242 * tree-vect-stmts.c (vect_mark_relevant): Likewise.
4243 (vect_mark_stmts_to_be_vectorized): Likewise.
4244 (vect_init_vector_1): Likewise.
4245 (vect_get_vec_def_for_operand): Likewise.
4246 (vect_finish_stmt_generation_1): Likewise.
4247 (vect_check_load_store_mask): Likewise.
4248 (vectorizable_call): Likewise.
4249 (vectorizable_conversion): Likewise.
4250 (vectorizable_operation): Likewise.
4251 (vectorizable_load): Likewise.
4252 (vect_analyze_stmt): Likewise.
4253 (vect_is_simple_use): Likewise.
4254 (vect_get_vector_types_for_stmt): Likewise.
4255 (vect_get_mask_type_for_stmt): Likewise.
4256 * tree-vectorizer.c (increase_alignment): Likewise.
4257
4258 2018-09-19 Andrew Stubbs <ams@codesourcery.com>
4259
4260 * doc/rtl.texi: Adjust vec_select description.
4261 * simplify-rtx.c (simplify_binary_operation_1): Allow VEC_SELECT to use
4262 non-constant selectors.
4263
4264 2018-09-19 Matthew Malcomson <matthew.malcomson@arm.com>
4265
4266 * config/aarch64/aarch64-protos.h
4267 (aarch64_offset_9bit_signed_unscaled_p): New declaration.
4268 * config/aarch64/aarch64.md (arches): New "rcpc8_4" attribute value.
4269 (arch_enabled): Add check for "rcpc8_4" attribute value of "arch".
4270 * config/aarch64/aarch64.h (AARCH64_FL_RCPC8_4): New bitfield.
4271 (AARCH64_FL_FOR_ARCH8_4): Include AARCH64_FL_RCPC8_4.
4272 (AARCH64_FL_PROFILE): Move index so flags are ordered.
4273 (AARCH64_ISA_RCPC8_4): New flag.
4274 * config/aarch64/aarch64.c (offset_9bit_signed_unscaled_p): Renamed
4275 to aarch64_offset_9bit_signed_unscaled_p.
4276 * config/aarch64/atomics.md (atomic_store<mode>): Allow offset
4277 and use stlur.
4278 * config/aarch64/constraints.md (Ust): New constraint.
4279 * config/aarch64/predicates.md.
4280 (aarch64_9bit_offset_memory_operand): New predicate.
4281 (aarch64_rcpc_memory_operand): New predicate.
4282
4283 2018-09-19 Eric Botcazou <ebotcazou@adacore.com>
4284
4285 PR rtl-optimization/87361
4286 * rtlanal.c (nonzero_bits1): Revert accidental change.
4287
4288 2018-09-19 Richard Biener <rguenther@suse.de>
4289
4290 PR tree-optimization/87349
4291 PR tree-optimization/87342
4292 * tree-ssa-sccvn.c (do_rpo_vn): Iterate max_rpo computation.
4293
4294 2018-09-18 Marek Polacek <polacek@redhat.com>
4295
4296 P1064R0 - Allowing Virtual Function Calls in Constant Expressions
4297 * gimple-fold.c (gimple_get_virt_method_for_vtable): Adjust assert.
4298
4299 2018-09-18 Segher Boessenkool <segher@kernel.crashing.org>
4300
4301 * config/rs6000/rs6000.md: Remove old "Cygnus sibcall" comment.
4302
4303 2018-09-18 Segher Boessenkool <segher@kernel.crashing.org>
4304
4305 PR rtl-optimization/86882
4306 * rtlanal.c (reg_overlap_mentioned_p): Handle CLOBBER.
4307
4308 2018-09-18 Uros Bizjak <ubizjak@gmail.com>
4309
4310 * config/i386/i386.md (*<code>extend<mode>xf2): Macroize insn from
4311 *<code>extendsfxf2 and *<code>extenddfxf2 using MODEF mode iterator.
4312
4313 2018-09-18 Jonathan Wakely <jwakely@redhat.com>
4314
4315 PR other/87353
4316 * doc/invoke.texi (Link Options): Fix formatting and grammar.
4317
4318 2018-09-18 Richard Biener <rguenther@suse.de>
4319
4320 PR middle-end/63155
4321 * tree-ssa-coalesce.c (tree_int_map_hasher): Remove.
4322 (compute_samebase_partition_bases): Likewise.
4323 (coalesce_ssa_name): Always use compute_optimized_partition_bases.
4324 (gimple_can_coalesce_p): Simplify.
4325
4326 2018-09-18 Hans-Peter Nilsson <hp@bitrange.com>
4327
4328 Handle a library implementation of ffs calling __builtin_ffs.
4329 * config/mmix/mmix.c (TARGET_INIT_LIBFUNCS): Override with...
4330 (mmix_init_libfuncs): New function: make __builtin_ffs expand
4331 to __ffsdi2.
4332
4333 2018-09-17 David Malcolm <dmalcolm@redhat.com>
4334
4335 * diagnostic-show-locus.c (class layout_range): Add field
4336 "m_original_idx".
4337 (layout_range::layout_range): Add "original_idx" param and use it
4338 to initialize new field.
4339 (make_range): Use 0 for original_idx.
4340 (layout::layout): Pass in index to calls to
4341 maybe_add_location_range.
4342 (layout::maybe_add_location_range): Add param "original_idx" and
4343 pass it on to layout_range.
4344 (layout::print_any_labels): Pass on range->m_original_idx to
4345 get_text call.
4346 (gcc_rich_location::add_location_if_nearby): Use 0 for
4347 original_idx.
4348 * gcc-rich-location.h (text_range_label::get_text): Update for new
4349 param.
4350 (range_label_for_type_mismatch::get_text): Likewise.
4351
4352 2018-09-17 Uros Bizjak <ubizjak@gmail.com>
4353
4354 * config/i386/i386.c (ix86_emit_i387_log1p): Emit fldln2 earlier.
4355
4356 2018-09-17 David Malcolm <dmalcolm@redhat.com>
4357
4358 * gimple-ssa-sprintf.c (fmtwarn): Update for introduction of
4359 format_string_diagnostic_t.
4360 (fmtwarn_n): Likewise.
4361 * substring-locations.c
4362 (format_string_diagnostic_t::format_string_diagnostic_t) New ctor.
4363 (format_warning_n_va): Convert to...
4364 (format_string_diagnostic_t::emit_warning_n_va): ...this.
4365 (format_warning_va): Convert to...
4366 (format_string_diagnostic_t::emit_warning_va): ...this.
4367 (format_warning_at_substring): Convert to...
4368 (format_string_diagnostic_t::emit_warning): ...this.
4369 (format_warning_at_substring_n): Convert to...
4370 (format_string_diagnostic_t::emit_warning_n): ...this.
4371 * substring-locations.h (class format_string_diagnostic_t): New
4372 class.
4373 (format_warning_va): Convert to
4374 format_string_diagnostic_t::emit_warning_va.
4375 (format_warning_n_va): Convert to
4376 format_string_diagnostic_t::emit_warning_n_va.
4377 (format_warning_at_substring): Convert to
4378 format_string_diagnostic_t::emit_warning.
4379 (format_warning_at_substring_n): Convert to
4380 format_string_diagnostic_t::emit_warning_n.
4381
4382 2018-09-17 Cesar Philippidis <cesar@codesourcery.com>
4383 Bernd Schmidt <bernds_cb1@t-online.de>
4384
4385 * config/nvptx/nvptx.md (atomic_fetch_<logic><mode>): Enable with
4386 SImode args.
4387
4388 2018-09-17 Uros Bizjak <ubizjak@gmail.com>
4389
4390 * config/i386/i386.md (truncxf<mode>2_i387_noop_unspec): Change
4391 operand 0 predicate to nonimmediate operand.
4392 (rint<mode>2_frndint): Remove insn pattern.
4393 (rint<mode>2): Change operand 1 predicate to general_operand.
4394 Extend operand 1 to XFmode and generate rintxf2 insn.
4395 (frndintxf2_<rounding>): Rename from frndint<mode>2_<rounding>.
4396 Do not use X87MODEF mode macro.
4397 (frndintxf2_<rounding>_i387): Rename from
4398 frndint<mode>2_<rounding>_i387. Do not use X87MODEF mode macro.
4399 (<rounding_insn><mode>2): For non-SSE modes, extend operand 1
4400 to XFmode and generate significandxf3 insn.
4401
4402 2018-09-17 Richard Biener <rguenther@suse.de>
4403
4404 PR tree-optimization/87328
4405 * tree-ssa-sccvn.c (process_bb): Remove assertion about not
4406 visiting unexecutable backedges when not iterating.
4407 (do_rpo_vn): Mark all edges not executable even when not
4408 iterating.
4409
4410 2018-09-17 Martin Jambor <mjambor@suse.cz>
4411
4412 PR c/63886
4413 * doc/invoke.texi (Warning Options): Likewise.
4414
4415 2018-09-17 Richard Biener <rguenther@suse.de>
4416
4417 PR tree-optimization/87301
4418 * tree-ssa-sccvn.c (eliminate_dom_walker::eliminate_cleanup): Properly
4419 clean EH info from leftover copy assignments.
4420
4421 2018-09-17 Martin Liska <mliska@suse.cz>
4422
4423 PR gcov-profile/85871
4424 * gcov.c (output_intermediate_file): Fix out of bounds
4425 access.
4426
4427 2018-09-17 Vineet Gupta <vgupta@synopsys.com>
4428
4429 * config/arc/arc.c: Object attributes for core4 not reflected
4430 correctly.
4431 * config/arc/arc.h: Don't restrict DBNZ to core3 (core4 includes
4432 core3).
4433
4434 2018-09-17 Alexey Brodkin <abrodkin@synopsys.com>
4435
4436 * config/arc/linux.h (LINK_EH_SPEC): Add missing space.
4437
4438 2018-09-17 Martin Liska <mliska@suse.cz>
4439
4440 * doc/gcov.texi: Document new option --use-hotness-colors.
4441 * gcov.c (struct source_info): Declare new field.
4442 (source_info::source_info): Set default for maximum_count.
4443 (print_usage): Add new -q option.
4444 (process_args): Process it.
4445 (accumulate_line_info): Save src->maximum_count.
4446 (output_line_beginning): Make color line number if
4447 flag_use_hotness_colors is set.
4448 (output_line_details): Pass default argument value.
4449 (output_lines): Pass src->maximum_count.
4450
4451 2018-09-17 Martin Liska <mliska@suse.cz>
4452
4453 * common/config/i386/i386-common.c (ix86_get_valid_option_values):
4454 Use processor_names table.
4455 * config/i386/i386.c (ix86_default_align): Use
4456 processor_cost_table for alignment values.
4457 (ix86_option_override_internal): Use processor_names.
4458 (ix86_function_specific_print): Likewise.
4459 * config/i386/i386.h (struct processor_costs):
4460 Add alignment values.
4461 (struct ptt): Remove and replace with const char *.
4462 * config/i386/x86-tune-costs.h (struct processor_costs):
4463 Declare default alignments for all costs.
4464
4465 2018-09-17 Aldy Hernandez <aldyh@redhat.com>
4466
4467 * tree-vrp.c (extract_range_from_unary_expr): Do not special case
4468 symbolics or VR_VARYING ranges for ABS_EXPR.
4469 * wide-int-range.cc (wide_int_range_abs): Return positive numbers
4470 when range will wrap.
4471
4472 2018-09-15 Eric Botcazou <ebotcazou@adacore.com>
4473
4474 PR middle-end/86864
4475 * cfgexpand.c (expand_gimple_basic_block): Be prepared for a BARRIER
4476 before and after a JUMP_TABLE_DATA.
4477
4478 2018-09-14 John David Anglin <danglin@gcc.gnu.org>
4479
4480 PR middle-end/87188
4481 * dojump.c (do_compare_and_jump): Canonicalize function pointers
4482 when one operand is a function pointer. Use POINTER_TYPE_P and
4483 FUNC_OR_METHOD_TYPE_P.
4484 * expr.c (do_store_flag): Use POINTER_TYPE_P and FUNC_OR_METHOD_TYPE_P.
4485 * fold-const.c (build_range_check): Likewise.
4486 * match.pd (simple_comparison): Likewise.
4487
4488 2018-09-14 David Malcolm <dmalcolm@redhat.com>
4489
4490 PR c/82967
4491 * spellcheck.c (get_edit_distance_cutoff): New function.
4492 (selftest::test_edit_distance_unit_test_oneway): Rename to...
4493 (selftest::test_get_edit_distance_one_way): ...this.
4494 (selftest::test_get_edit_distance_unit): Rename to...
4495 (selftest::test_get_edit_distance_both_ways): ...this.
4496 (selftest::test_edit_distances): Move tests to this new function,
4497 and test some more pairs of strings. Update for above renaming.
4498 (selftest::get_old_cutoff): New function.
4499 (selftest::test_get_edit_distance_cutoff): New function.
4500 (selftest::assert_suggested_for): New function.
4501 (ASSERT_SUGGESTED_FOR): New macro.
4502 (selftest::assert_not_suggested_for): New function.
4503 (ASSERT_NOT_SUGGESTED_FOR): New macro.
4504 (selftest::test_suggestions): New function.
4505 (selftest::spellcheck_c_tests): Move test_get_edit_distance_unit
4506 tests to selftest::test_edit_distances and call it. Add calls to
4507 selftest::test_get_edit_distance_cutoff and
4508 selftest::test_suggestions.
4509 * spellcheck.h (get_edit_distance_cutoff): New function declaration.
4510 (best_match::consider): Replace hard-coded cutoff calculation with
4511 a call to...
4512 (best_match::get_cutoff): New declaration.
4513 (best_match::get_best_meaningful_candidate): Likewise.
4514
4515 2018-09-14 Bernd Edlinger <bernd.edlinger@hotmail.de>
4516
4517 * builtins.c (fold_builtin_strlen): Remove TODO comment.
4518
4519 2018-09-14 Bernd Edlinger <bernd.edlinger@hotmail.de>
4520
4521 revert:
4522 2018-07-30 Bernd Edlinger <bernd.edlinger@hotmail.de>
4523
4524 * tree-ssa-forwprop.c (simplify_builtin_call): Don't create a not NUL
4525 terminated string literal.
4526
4527 2018-09-14 Martin Sebor <msebor@redhat.com>
4528
4529 * builtins.c (unterminated_array): Handle ARRAY_REF.
4530 (expand_builtin_stpcpy_1): Detect unterminated char arrays.
4531 * builtins.h (unterminated_array): Declare extern.
4532 * gimple-fold.c (gimple_fold_builtin_stpcpy): Detect unterminated
4533 arrays.
4534 (gimple_fold_builtin_sprintf): Propagate NO_WARNING to transformed
4535 calls.
4536
4537 2018-09-14 Martin Sebor <msebor@redhat.com>
4538 Jeff Law <law@redhat.com>
4539
4540 * builtins.c (unterminated_array): New.
4541 (expand_builtin_strcpy): Adjust.
4542 (expand_builtin_strcpy_args): Detect unterminated arrays.
4543 * gimple-fold.c (get_maxval_strlen): Add argument. Detect
4544 unterminated arrays.
4545 * gimple-fold.h (get_maxval_strlen): Add argument.
4546 (gimple_fold_builtin_strcpy): Detec unterminated arrays.
4547
4548 * gimple-fold.c (get_range_strlen): Add argument.
4549 (get_maxval_strlen): Adjust.
4550 * gimple-fold.h (get_range_strlen): Add argument.
4551
4552 2018-09-14 Wei Xiao <wei3.xiao@intel.com>
4553
4554 * config/i386/movdirintrin.h: Fix copyright year.
4555
4556 2018-09-14 Uros Bizjak <ubizjak@gmail.com>
4557
4558 * reg-stack.c: Include regs.h.
4559 (replace_reg): Assert that mode is MODE_FLOAT or MODE_COMPLEX_FLOAT.
4560 (emit_pop_insn): Default pop insn mode to the reg_raw_mode of
4561 FIRST_STACK_REG, not DFmode.
4562 (emit_swap_insn): Default swap insn mode to the reg_raw_mode of
4563 FIRST_STACK_REG, not XFmode. Explicitly construct swap RTX.
4564 (change stack): Default register mode to the reg_raw_mode of
4565 FIRST_STACK_REG, not DFmode.
4566 * config/i386/i386.md (*swap<mode>): Remove insn pattern.
4567 (*swapxf): Rename from swapxf.
4568
4569 2018-09-14 Carl Love <cel@us.ibm.com>
4570
4571 * config/rs6000/emmintrin.h: Add _MM_SHUFFLE2.
4572 * config/rs6000/xmmintrin.h: Add _MM_SHUFFLE.
4573
4574 2018-09-14 Segher Boessenkool <segher@kernel.crashing.org>
4575
4576 PR target/87224
4577 * config/rs6000/rs6000.md (*mov<mode>_hardfloat64): Add Z to the Y
4578 alternatives.
4579
4580 2018-09-14 Sam Tebbs <sam.tebbs@arm.com>
4581
4582 PR target/85628
4583 * config/aarch64/aarch64.md (*aarch64_bfxilsi_uxtw): Define.
4584
4585 2018-09-14 Jason Merrill <jason@redhat.com>
4586
4587 Fix --enable-gather-detailed-mem-stats.
4588 * hash-table.c (hash_table_usage): Change from variable to function.
4589 * hash-table.h: Adjust.
4590 * Makefile.in: Add missing dependencies on hash-table.h.
4591
4592 2018-09-14 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
4593
4594 PR tree-optimization/87259
4595 PR lto/87283
4596 (pass_cse_reciprocals::execute): Run optimize_recip_sqrt after
4597 execute_cse_reciprocals_1 has tried transforming.
4598
4599 2018-09-14 Aldy Hernandez <aldyh@redhat.com>
4600
4601 * tree-vrp.c (extract_range_from_binary_expr_1): Normalize
4602 VR_VARYING for PLUS/MINUS_EXPR.
4603
4604 2018-09-14 Ilya Leoshkevich <iii@linux.ibm.com>
4605
4606 * config/s390/s390-passes.def (INSERT_PASS_BEFORE): Improve
4607 formatting.
4608
4609 2018-09-14 Richard Biener <rguenther@suse.de>
4610
4611 PR middle-end/63155
4612 * tree-ssa-coalesce.c (ssa_conflicts_merge): Remove conflict
4613 bits for the merged partition.
4614
4615 2018-09-13 Martin Sebor <msebor@redhat.com>
4616 Bernd Edlinger <bernd.edlinger@hotmail.de>
4617
4618 * builtins.h (c_srlen): Add argument.
4619 * builtins.c (warn_string_no_nul): New function.
4620 (c_strlen): Add argument and use it. Update recursive calls.
4621 Pass DECL argument to string_constant to get info on non
4622 terminated strings. Update *NONSTR as needed.
4623 (fold_builtin_strlen): Add argument to calls to c_strlen.
4624 Warn for unterminated arrays.
4625 (warn_string_no_null): Add prototype.
4626 * expr.c (string_constant): Update arguments. Update recursive
4627 calls appropriately. Detect missing NUL terminator and outermost
4628 declaration its missing in.
4629 Improve checks for arrays with nonzero lower bound or elements
4630 that are not a single byte. Simplify offset computation.
4631 Simplify checks for non-NUL terminated strings.
4632 * gimple-fold.c (get_range_strlen): Add argument to c_strlen call.
4633 * gimple-ssa-sprintf.c (get_string_length): Remove unnecessary code.
4634
4635 2018-09-13 Bernd Edlinger <bernd.edlinger@hotmail.de>
4636
4637 * builtins.c (c_strlen): Handle not zero terminated STRING_CSTs
4638 correctly.
4639 * fold-const.c (c_getstr): Fix function comment. Remove unused third
4640 argument. Fix range checks.
4641 * fold-const.h (c_getstr): Adjust protoype.
4642 * gimple-fold.c (gimple_fold_builtin_memory_op): Avoid folding when
4643 string is constant but contains no NUL byte.
4644
4645 * expr.c (string_constant): Adjust function comment.
4646 Remove bogus check for zero termination.
4647
4648 * fold-const.c (c_getstr): Clamp STRING_LENGTH to STRING_SIZE.
4649
4650 * varasm.c (compare_constant): Compare type size of STRING_CSTs.
4651 (get_constant_size): Don't make STRING_CSTs larger than they are.
4652 (check_string_literal): New check function for STRING_CSTs.
4653 (output_constant): Use it.
4654
4655 2018-09-13 Eric Botcazou <ebotcazou@adacore.com>
4656
4657 PR target/86812
4658 * config/visium/visium.c (TARGET_HAVE_SPECULATION_SAFE_VALUE): Define.
4659
4660 2018-09-13 Richard Biener <rguenther@suse.de>
4661
4662 PR tree-optimization/87263
4663 * tree-ssa-sccvn.c (visit_phi): Revert some earlier changes.
4664 (struct unwind_state): Add max_rpo field.
4665 (do_rpo_vn): Allow up-to-date loop state to be used when not iterating.
4666 Compute max_rpo, the max RPO number a block can be backwards reached
4667 from. Re-write non-iterating mode to a RPO ordered worklist approach,
4668 separating it from the iterating mode.
4669
4670 2018-09-13 Vlad Lazar <vlad.lazar@arm.com>
4671
4672 * haifa-sched.c (rank_for_schedule): Schedule by INSN_COST.
4673 (rfs_decision): New scheduling decision.
4674
4675 2018-09-13 Richard Biener <rguenther@suse.de>
4676
4677 PR bootstrap/87134
4678 * tree-ssa-sccvn.c (vn_nary_op_insert_into): Fix assert.
4679 (vn_nary_op_insert_pieces_predicated): Do not write useless
4680 valid_dominated_by_p entry outside of the allocated storage.
4681
4682 2018-09-13 Omar Sandoval <osandov@osandov.com>
4683 Tom de Vries <tdevries@suse.de>
4684
4685 PR debug/86985
4686 * dwarf2out.c (is_c): New function.
4687 (add_subscript_info): Add DW_AT_count of 0 for C zero-length arrays.
4688
4689 2018-09-13 Sam Tebbs <sam.tebbs@arm.com>
4690
4691 PR target/85628
4692 * config/aarch64/aarch64.md (*aarch64_bfxil):
4693 Define.
4694 * config/aarch64/constraints.md (Ulc): Define.
4695 * config/aarch64/aarch64-protos.h (aarch64_high_bits_all_ones_p):
4696 Define.
4697 * config/aarch64/aarch64.c (aarch64_high_bits_all_ones_p):
4698 New function.
4699
4700 2018-09-13 Vlad Lazar <vlad.lazar@arm.com>
4701
4702 * config/aarch64/aarch64.h (TARGET_COMPUTE_FRAME_LAYOUT): Define.
4703 * config/aarch64/aarch64.c (aarch64_expand_prologue): Remove
4704 aarch64_layout_frame call.
4705 (aarch64_expand_epilogue): Likewise.
4706 (aarch64_initial_elimination_offset): Likewise.
4707 (aarch64_get_separate_components): Likewise.
4708 (aarch64_use_return_insn_p): Likewise.
4709 (aarch64_layout_frame): Remove unneeded check.
4710
4711 2018-09-13 Jakub Jelinek <jakub@redhat.com>
4712
4713 * configure.ac: Only append
4714 " : (reconfigured) $TOPLEVEL_CONFIGURE_ARGUMENTS" to
4715 gcc_config_arguments if it was never reconfigured or last reconfigure
4716 was with different arguments.
4717 * configure: Regenerated.
4718
4719 2018-09-13 Jakub Jelinek <jakub@redhat.com>
4720 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
4721
4722 PR middle-end/87290
4723 * expr.c (maybe_optimize_pow2p_mod_cmp): New function.
4724 (maybe_optimize_mod_cmp): Use it if integer_pow2p treeop1.
4725
4726 2018-09-13 Jakub Jelinek <jakub@redhat.com>
4727
4728 PR tree-optimization/87287
4729 * fold-const.c (fold_binary_loc) <case EQ_EXPR>: Move signed modulo
4730 X % C == 0 to X % (unsigned) C == 0 optimization to ...
4731 * match.pd (X % C == 0): ... here. New optimization.
4732
4733 2018-09-12 Jakub Jelinek <jakub@redhat.com>
4734
4735 PR middle-end/82853
4736 * expr.h (maybe_optimize_mod_cmp): Declare.
4737 * expr.c (mod_inv): New function.
4738 (maybe_optimize_mod_cmp): New function.
4739 (do_store_flag): Use it.
4740 * cfgexpand.c (expand_gimple_cond): Likewise.
4741
4742 2018-09-09 Cesar Philippidis <cesar@codesourcery.com>
4743 Julian Brown <julian@codesourcery.com>
4744
4745 PR middle-end/86336
4746 * gimplify.c (gimplify_scan_omp_clauses): Set
4747 target_firstprivatize_array_bases in OpenACC parallel and kernels
4748 region contexts. Remove GOMP_MAP_FIRSTPRIVATE_REFERENCE clauses from
4749 OpenACC data regions.
4750
4751 2018-09-12 Uros Bizjak <ubizjak@gmail.com>
4752
4753 * config/i386/i386.md (sqrt_extend<mode>xf3_i387): Remove.
4754 (sqrt<mode>2): Extend operand 1 to XFmode and generate sqrtxf3 insn.
4755
4756 2018-09-12 Richard Biener <rguenther@suse.de>
4757
4758 PR tree-optimization/87280
4759 * tree-ssa-sccvn.c (process_bb): Handle the case of executable
4760 edge but unreachable target.
4761 (do_rpo_vn): For conservatively handling a PHI only mark
4762 the backedge executable but not the block reachable.
4763
4764 2018-09-12 Richard Biener <rguenther@suse.de>
4765
4766 PR tree-optimization/87266
4767 * tree-ssa-sccvn.c (do_rpo_vn): Always iterate to not yet
4768 visited blocks.
4769
4770 2018-09-12 Andreas Krebbel <krebbel@linux.ibm.com>
4771
4772 * config/s390/s390.md (PFPO_RND_MODE_DFP, PFPO_RND_MODE_BFP): New
4773 constants.
4774 ("trunc<BFP:mode><DFP_ALL:mode>2")
4775 ("trunc<DFP_ALL:mode><BFP:mode>2")
4776 ("extend<BFP:mode><DFP_ALL:mode>2")
4777 ("extend<DFP_ALL:mode><BFP:mode>2"): Set proper rounding mode
4778 according to the target operand type.
4779
4780 2018-09-12 Jakub Jelinek <jakub@redhat.com>
4781 Andreas Krebbel <krebbel@linux.ibm.com>
4782
4783 PR tree-optimization/86844
4784 * gimple-ssa-store-merging.c
4785 (imm_store_chain_info::coalesce_immediate): For overlapping stores, if
4786 there are any overlapping stores in between them, make sure they are
4787 also coalesced or we give up completely.
4788
4789 2018-09-12 Jakub Jelinek <jakub@redhat.com>
4790
4791 PR middle-end/87248
4792 * fold-const.c (fold_ternary_loc) <case COND_EXPR>: Verify also that
4793 BIT_AND_EXPR's second operand is a power of two. Formatting fix.
4794
4795 2018-09-12 Tom de Vries <tdevries@suse.de>
4796
4797 * common.opt (gdescribe-dies): Add option.
4798 * dwarf2out.c (add_name_and_src_coords_attributes): Add description
4799 attribute for artifical and nameless decls.
4800 (dwarf2out_register_external_die): Add description attribute to
4801 external reference die.
4802 (add_desc_attribute): New functions.
4803 (gen_subprogram_die): Add description attribute to
4804 DW_TAG_call_site_parameter.
4805 * tree-pretty-print.c (print_generic_expr_to_str): New function.
4806 * tree-pretty-print.h (print_generic_expr_to_str): Declare.
4807 * doc/invoke.texi (@item Debugging Options): Add -gdescribe-dies and
4808 -gno-describe-dies.
4809 (@item -gdescribe-dies): Add.
4810
4811 2018-09-12 Aldy Hernandez <aldyh@redhat.com>
4812
4813 * tree-vrp.c (vrp_shift_undefined_p): Remove.
4814 (extract_range_from_binary_expr_1: Call
4815 wide_int_range_shift_undefined_p instead of vrp_shift_undefined_p.
4816 * wide-int-range.h (wide_int_range_shift_undefined_p): Do not
4817 depend on sign.
4818
4819 2018-09-12 Aldy Hernandez <aldyh@redhat.com>
4820
4821 * gimple-ssa-warn-alloca.c
4822 (alloca_type_and_limit::alloca_type_and_limit): Initialize limit
4823 field for ALLOCA_BOUND_*_LARGE.
4824
4825 2018-09-11 Nathan Sidwell <nathan@acm.org>
4826
4827 * gcc.c (load_specs, execute, run_attempt): Use %qs not '%s'.
4828
4829 2018-09-11 Uros Bizjak <ubizjak@gmail.com>
4830
4831 * reg-stack.c (subst_asm_stack_regs): Call replace_reg also
4832 for clobbers. Remove obsolete comment.
4833
4834 2018-09-11 Uros Bizjak <ubizjak@gmail.com>
4835
4836 * config/i386/i386.md (define_attr "type"): Remove mpxmov, mpxmk,
4837 mpxchk, mpxld and mpxst types.
4838 (define_attr length_immediate): Remove all processing of mpx types.
4839 (define_attr prefix_0f): Ditto.
4840 (define_attr memory): Ditto.
4841
4842 2018-09-11 Uros Bizjak <ubizjak@gmail.com>
4843
4844 * config/i386/i386.md (fyl2x_extend<mode>xf3_i387): Remove.
4845 (log<mode>2): Change operand 1 predicate to general_operand.
4846 Extend operand 1 to XFmode and generate logxf3 insn.
4847 (log10<mode>2): Change operand 1 predicate to general_operand.
4848 Extend operand 1 to XFmode and generate log10xf3 insn.
4849 (log2<mode>2): Change operand 1 predicate to general_operand.
4850 Extend operand 1 to XFmode and generate log2xf3 insn.
4851 (fyl2xp1_extend<mode>xf3_i387): Remove.
4852 (log1p<mode>2): Change operand 1 predicate to general_operand.
4853 Extend operand 1 to XFmode and generate log1pxf3 insn.
4854 (fxtract_extend<mode>xf3_i387): Remove.
4855 (logb<mode>2): Change operand 1 predicate to general_operand.
4856 Extend operand 1 to XFmode and generate logbxf3 insn.
4857 (ilogb<mode>2): Change operand 1 predicate to general_operand.
4858 Extend operand 1 to XFmode and generate fxtractxf3_i387 insn.
4859 (significand<mode>2): Change operand 1 predicate to general_operand.
4860 Extend operand 1 to XFmode and generate significandxf3 insn.
4861
4862 2018-09-11 Nathan Sidwell <nathan@acm.org>
4863
4864 * gcc.c (perror_with_name, pfatal_with_name): Delete.
4865 (load_specs): Use fatal_error.
4866 (DELETE_IF_ORDINARY, process_command): Use error.
4867 (execute, run_attempt): Use fatal_error.
4868
4869 2018-09-11 Andrew Stubbs <ams@codesourcery.com>
4870
4871 * diagnostic-core.h (sorry_at): New prototype.
4872 * diagnostic.c (sorry_at): New function.
4873
4874 2018-09-11 Aldy Hernandez <aldyh@redhat.com>
4875
4876 * tree-vrp.c (extract_range_from_binary_expr_1): Treat all divisions
4877 by zero as VR_UNDEFINED.
4878
4879 2018-09-10 Uros Bizjak <ubizjak@gmail.com>
4880
4881 * config/i386/i386.md (<sincos>xf2): Rename from *<sincos>xf2_i387.
4882 (*<sincos>_extend<mode>xf2_i387): Remove insn pattern.
4883 (<sincos>mode2): New expander.
4884 (sincos_extend<mode>xf3_i387): Remove insn pattern.
4885 (sincos -> sin, cos splitters): Remove splitter patterns.
4886 (sincos<mode>3): Change operand 2 predicate to general_operand.
4887 Extend operand 2 to XFmode and generate sincosxf3 insn.
4888 (fptanxf4_i387): Change mode of operands 0 and 3 to SFmode.
4889 Change operand 3 predicate to const1_operand.
4890 (fptan_extend<mode>xf4_i387): Remove insn pattern.
4891 (tanxf2): Update operands in the call to fptanxf4_i387.
4892 (tan<mode>2): Change operand 1 predicate to general_operand.
4893 Extend operand 1 to XFmode and generate tanxf3 insn.
4894 (atan2xf3): Rename from *fpatanxf3_i387.
4895 (fpatan_extend<mode>xf3_i387): Remove insn pattern.
4896 (atan2xf3): Remove expander.
4897 (atan2<mode<3): Change operand 1 and 2 predicates to general_operand.
4898 Extend operands 1 and 2 to XFmode and generate atan2xf3 insn.
4899 (atan<mode>2): Change operand 1 predicate to general_operand.
4900 Extend operand 1 to XFmode and generate atanxf3 insn.
4901
4902 2018-09-10 Uros Bizjak <ubizjak@gmail.com>
4903
4904 * config/i386/i386.md (x87/SSE constant load splitter): Use
4905 memory_operand instead of nonimmediate_operand for input operand
4906 predicate.
4907
4908 2018-09-09 Uros Bizjak <ubizjak@gmail.com>
4909
4910 * config/i386/i386.md (float partial SSE register stall splitter): Move
4911 splitter near its instruction pattern.
4912 (float_extend partial SSE register stall splitter): Ditto.
4913 (float_truncate partial SSE register stall splitter): Ditto.
4914
4915 2018-09-09 Hans-Peter Nilsson <hp@bitrange.com>
4916
4917 PR target/86794
4918 * config/mmix/mmix.c (TARGET_HAVE_SPECULATION_SAFE_VALUE): Redefine
4919 to speculation_safe_value_not_needed.
4920
4921 PR target/85666
4922 * config/mmix/mmix.c (mmix_assemble_integer): Handle byte-size
4923 non-CONST_INT rtx:es using assemble_integer_with_op ".byte".
4924 (MMIX_CFUN_NEEDS_SAVED_EH_RETURN_ADDRESS): Don't call
4925 leaf_function_p, instead use has_hard_reg_initial_val.
4926
4927 2018-09-09 Nathan Sidwell <nathan@acm.org>
4928
4929 * gcc.h (pfatal_with_name): Don't declare here.
4930 * gcc.c (pfatal_with_name): Make static.
4931
4932 2018-09-09 Xianmiao Qu <xianmiao_qu@c-sky.com>
4933
4934 * config/csky/csky.md (*cskyv2_adddi3, *cskyv2_subdi3): Add
4935 earlyclobber.
4936
4937 2018-09-08 John David Anglin <danglin@gcc.gnu.org>
4938
4939 PR rtl-optimization/85458
4940 * sel-sched.c (sel_target_adjust_priority): Allow backend adjust
4941 priority hook to reduce the priority of EXPR.
4942
4943 2018-09-07 Uros Bizjak <ubizjak@gmail.com>
4944
4945 * config/i386/i386.md (float<SWI48x:mode><MODEF:mode>2) Enable
4946 DImode for x87 on 32bit targets. Conditionally disable x87 modes
4947 with X87_ENABLE_FLOAT. Remove preparation code.
4948 (*float<SWI48:mode><MODEF:mode>2): Rename from
4949 *float<SWI48:mode><MODEF:mode>2_mixed. Handle x87, SSE and mixed
4950 math using "enabled" attribute.
4951 (*floatdi<MODEF:mode>2_i387): Rename from
4952 *float<SWI48x:mode><MODEF:mode>2_i387. Handle only DImode and
4953 enable for 32bit targets only.
4954 (floatdi<X87MODEF:mode>2_i387_with_xmm pre-reload splitter): New
4955 splitter.
4956 (floatdi<X87MODEF:mode>2_i387_with_xmm): Use register_operand
4957 as operand 1 predicate. Rewrite as define_insn_and_split.
4958 (floatdi<X87MODEF:mode>2_i387_with_xmm memory input splitter): Remove.
4959
4960 2018-09-06 Uros Bizjak <ubizjak@gmail.com>
4961
4962 * reg-stack.c (get_true_reg) <case FLOAT_TRUNCATE>: Reorder
4963 to fallthru to FLOAT case.
4964
4965 2018-09-06 Will Schmidt <will_schmidt@vnet.ibm.com>
4966
4967 PR target/86731
4968 * config/rs6000/rs6000.c (rs6000_gimple_fold_builtin): Update logic
4969 around folding of vec_sl to handle out of range shift values.
4970
4971 2018-09-06 Uros Bizjak <ubizjak@gmail.com>
4972
4973 * config/i386/i386.md (fix_trunc<mode>_fisttp_i387_1): Remove.
4974 Update callers to gen_fix_trunc<mode>_i387_fisttp
4975 (fix_trunc<mode>_i387_fisttp): Change operand 0 predicate to
4976 nonimmediate_operand.
4977 (fix_trunc<mode>_i387_fisttp_with_temp): Remove insn pattern
4978 and corresponding splitters.
4979 (*fix_trunc<mode>_i387_1): Always expand with fix_trunc<mode>_i387.
4980 (fix_truncdi_i387): Change operand 0 predicate to nonimmediate_operand.
4981 (fix_truncdi_i387_with_temp): Remove insn pattern
4982 and corresponding splitters.
4983 (fix_trunc<mode>_i387): Change operand 0 predicate to
4984 nonimmediate_operand.
4985 (fix_trunc<mode>_i387_with_temp): Remove insn pattern
4986 and corresponding splitters.
4987 (*fistdi2_1): Remove.
4988 (fistdi2): Ditto.
4989 (fistdi2_with_temp): Remove insn pattern and corresponding splitters.
4990 (lrintxfdi2): Remove expander. Reimplement as define_insn.
4991 (*fist<mode>2_1): Remove.
4992 (fist<mode>2): Ditto.
4993 (fist<mode>2_with_temp): Remove insn pattern and corresponding
4994 splitters.
4995 (lrintxf<mode>2): Remove expander. Reimplement as define_insn.
4996 (*fist<mode>2_<rounding>_1): Always expand with fist<mode>2_<rounding>.
4997 (fistdi2_<rounding>): Change operand 0 predicate to
4998 nonimmediate_operand.
4999 (fistdi2_<rounding>_with_temp): Remove insn pattern
5000 and corresponding splitters.
5001 (fist<mode>2_<rounding>): Change operand 0 predicate to
5002 nonimmediate_operand.
5003 (fist<mode>2_<rounding>_with_temp): Remove insn pattern
5004 and corresponding splitters.
5005
5006 (*fixuns_trunc<mode>si2_avx512f_zext): Depend on TARGET_SSE_MATH.
5007
5008 2018-09-06 Bernd Edlinger <bernd.edlinger@hotmail.de>
5009
5010 * varasm.c (output_constructor_regular_field): Check TYPE_SIZE_UNIT of
5011 the init value.
5012
5013 2018-09-06 Will Schmidt <will_schmidt@vnet.ibm.com>
5014
5015 * config/rs6000/rs6000.c (rs6000_gimple_fold_builtin): Add support for
5016 early gimple folding of vec_splat().
5017 * tree-vect-generic.c: Remove static from tree_vec_extract() definition.
5018 * gimple-fold.h: Add an extern define for tree_vec_extract().
5019
5020 2018-09-06 Will Schmidt <will_schmidt@vnet.ibm.com>
5021
5022 * config/rs6000/rs6000.c (fold_mergehl_helper): Add types_compatible_p
5023 wrappers around TREE_TYPE comparisons.
5024
5025 2018-09-06 Ilya Leoshkevich <iii@linux.ibm.com>
5026
5027 PR target/80080
5028 * config/s390/predicates.md: Add nonsym_memory_operand.
5029 * config/s390/s390.c (s390_legitimize_cs_operand): If operand
5030 contains a SYMBOL_REF, load it into an intermediate pseudo.
5031 (s390_emit_compare_and_swap): Legitimize operand.
5032 * config/s390/s390.md: Use the new nonsym_memory_operand
5033 with UNSPECV_CAS patterns.
5034
5035 2018-09-06 Ilya Leoshkevich <iii@linux.ibm.com>
5036
5037 PR target/80080
5038 * config/s390/s390-passes.def: New file.
5039 * config/s390/s390-protos.h (class rtl_opt_pass): Add forward
5040 declaration.
5041 (make_pass_s390_early_mach): Add declaration.
5042 * config/s390/s390.c (make_pass_s390_early_mach):
5043 (s390_option_override): Remove dynamic registration.
5044 * config/s390/t-s390: Add s390-passes.def.
5045
5046 2018-09-06 Ilya Leoshkevich <iii@linux.ibm.com>
5047
5048 * config/s390/s390.c (s390_decompose_constant_pool_ref):
5049 Remove UNSPEC_LTREL_BASE check.
5050 (annotate_constant_pool_refs): Likewise.
5051 (find_constant_pool_ref): Likewise.
5052 (find_ltrel_base): Removed.
5053 (replace_ltrel_base): Removed.
5054 (s390_mainpool_finish): Remove replace_ltrel_base call.
5055 (s390_chunkify_start): Remove pending LTREL_BASE logic.
5056 (s390_chunkify_finish): Remove replace_ltrel_base call.
5057 * config/s390/s390.md: Remove UNSPEC_LTREL_BASE.
5058
5059 2018-09-06 Hans-Peter Nilsson <hp@axis.com>
5060
5061 PR target/86779
5062 * config/cris/cris.c (TARGET_HAVE_SPECULATION_SAFE_VALUE): Redefine
5063 to speculation_safe_value_not_needed.
5064
5065 2018-09-05 Cesar Philippidis <cesar@codesourcery.com>
5066 Bernd Schmidt <bernds_cb1@t-online.de>
5067
5068 * config/nvptx/nvptx-opts.h: New file.
5069 * config/nvptx/nvptx.c (nvptx_file_start): Print the correct .target.
5070 * config/nvptx/nvptx.h: Include "nvptx-opts.h".
5071 (ASM_SPEC): Define.
5072 (TARGET_SM35): New macro.
5073 * config/nvptx/nvptx.md (atomic_fetch_<logic><mode>): Enable with the
5074 correct predicate.
5075 * config/nvptx/nvptx.opt (ptx_isa, sm_30, sm_35): New enum and its
5076 values.
5077 (misa=): New option.
5078 * doc/invoke.texi (Nvidia PTX Options): Document -misa.
5079
5080 2018-09-05 Uros Bizjak <ubizjak@gmail.com>
5081
5082 * config/i386/i386.md (truncdfsf2): Remove expander.
5083 (truncdfsf2_with_temp): Ditto.
5084 (truncxf<mode>2): Ditto.
5085 (*truncdfsf_fast_mixed): Remove insn pattern.
5086 (*truncdfsf_fast_i387): Ditto.
5087 (*truncdfsf_mixed): Ditto.
5088 (*truncdfsf_i387): Ditto.
5089 (*truncdfsf2_i387_1): Ditto.
5090 (*truncxfsf2_mixed): Ditto.
5091 (*truncxfdf2_mixed): Ditto.
5092 (*truncxf<mode>2_i387_noop): Ditto. Update callers
5093 to call gen_truncxf<mode>2 instead.
5094 (*truncxf<mode>2_i387): Remove.
5095 (reg->reg splitters): Remove splitter pattern.
5096 (reg->mem splitters): Ditto.
5097
5098 (truncdfsf2): New insn pattern.
5099 (truncxf<mode>2): Ditto.
5100
5101 2018-09-05 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
5102
5103 * tree-ssa-math-opts.c (is_mult_by): New function.
5104 (is_square_of): Use the above.
5105 (optimize_recip_sqrt): New function.
5106 (pass_cse_reciprocals::execute): Use the above.
5107
5108 2018-09-05 Richard Biener <rguenther@suse.de>
5109
5110 PR bootstrap/87134
5111 * tree-ssa-sccvn.c (rpo_elim::eliminate_push_avail): Make sure
5112 to zero-init the emplaced vec.
5113
5114 2018-09-05 Martin Liska <mliska@suse.cz>
5115
5116 PR tree-optimization/87205
5117 * tree-switch-conversion.c (pass_lower_switch::execute):
5118 Group cases for switch statements.
5119
5120 2018-09-05 Richard Biener <rguenther@suse.de>
5121
5122 PR tree-optimization/87217
5123 * tree-ssa-sccvn.c (vuse_valueize): New.
5124 (vn_reference_lookup_pieces): Use it.
5125 (vn_reference_lookup): Likewise.
5126
5127 2018-09-05 Nathan Sidwell <nathan@acm.org>
5128
5129 PR c++/87137
5130 * stor-layout.c (place_field): Scan forwards to check last
5131 bitfield when ms_bitfield_placement is in effect.
5132
5133 2018-09-05 Richard Biener <rguenther@suse.de>
5134
5135 PR bootstrap/87225
5136 * tree-vect-stmts.c (vectorizable_simd_clone_call): Fix bogus
5137 return.
5138
5139 2018-09-05 Siddhesh Poyarekar <siddhesh@sourceware.org>
5140 Kugan Vivekanandarajah <kugan.vivekanandarajah@linaro.org>
5141
5142 * config/aarch64/falkor-tag-collision-avoidance.c: New file.
5143 * config.gcc (extra_objs): Build it.
5144 * config/aarch64/t-aarch64 (falkor-tag-collision-avoidance.o):
5145 Likewise.
5146 * config/aarch64/aarch64-passes.def
5147 (pass_tag_collision_avoidance): New pass.
5148 * config/aarch64/aarch64.c (qdf24xx_tunings): Add
5149 AARCH64_EXTRA_TUNE_RENAME_LOAD_REGS to tuning_flags.
5150 (aarch64_classify_address): Remove static qualifier.
5151 (aarch64_address_info, aarch64_address_type): Move to...
5152 * config/aarch64/aarch64-protos.h: ... here.
5153 (make_pass_tag_collision_avoidance): New function.
5154 * config/aarch64/aarch64-tuning-flags.def (rename_load_regs):
5155 New tuning flag.
5156
5157 2018-09-05 Martin Liska <mliska@suse.cz>
5158
5159 * doc/gcov.texi: Update documentation of humar
5160 readable mode.
5161 * gcov.c (format_count): Print one decimal place, it provides
5162 more fine number of situations like '1G' vs. '1.4G'.
5163
5164 2018-09-05 Martin Liska <mliska@suse.cz>
5165
5166 PR target/87164
5167 * config/rs6000/rs6000.opt: Mark the option as Deprecated.
5168 * optc-gen.awk: Allow 'Var' for Deprecated options in order
5169 to generate a MASK value.
5170
5171 2018-09-04 H.J. Lu <hongjiu.lu@intel.com>
5172
5173 PR debug/86593
5174 * dwarf2out.c (based_loc_descr): Allow hard frame pointer even
5175 if frame pointer isn't used.
5176 (compute_frame_pointer_to_fb_displacement): Likewise.
5177
5178 2018-09-04 Jakub Jelinek <jakub@redhat.com>
5179
5180 PR target/87198
5181 * common/config/i386/i386-common.c (OPTION_MASK_ISA_XSAVEOPT_SET,
5182 OPTION_MASK_ISA_XSAVES_SET, OPTION_MASK_ISA_XSAVEC_SET): Use
5183 OPTION_MASK_ISA_XSAVE_SET instead of OPTION_MASK_ISA_XSAVE.
5184 (OPTION_MASK_ISA_XSAVE_UNSET): Add OPTION_MASK_ISA_XSAVES_UNSET
5185 and OPTION_MASK_ISA_XSAVEC_UNSET.
5186
5187 2018-09-04 Max Filippov <jcmvbkbc@gmail.com>
5188
5189 * config/xtensa/xtensa.c (xtensa_expand_atomic): Reorder AND and
5190 XOR operations in NAND case.
5191
5192 2018-09-04 Aldy Hernandez <aldyh@redhat.com>
5193
5194 * wide-int-range.cc (wide_int_range_convert): New.
5195 * wide-int-range.h (wide_int_range_convert): New.
5196 * tree-vrp.c (extract_range_from_unary_expr): Abstract wide int
5197 code into wide_int_range_convert.
5198 (extract_range_into_wide_ints): Do not munge anti range constants
5199 into the entire domain. Just return the range back.
5200
5201 2018-09-04 Martin Liska <mliska@suse.cz>
5202
5203 * genmatch.c (output_line_directive): Add new argument
5204 fnargs.
5205 (dt_simplify::gen_1): Encapsulate dump within __builtin_expect.
5206
5207 2018-09-04 Jonathan Wakely <jwakely@redhat.com>
5208
5209 * doc/invoke.texi (Option Summary): Add whitespace.
5210
5211 * doc/invoke.texi (Option Summary): Add -Waligned-new.
5212
5213 2018-09-04 Richard Biener <rguenther@suse.de>
5214
5215 PR tree-optimization/87211
5216 * tree-ssa-sccvn.c (visit_phi): When value-numbering to a
5217 backedge value we're supposed to treat as VARYING also number
5218 the PHI to VARYING in case it got a different value-number already.
5219
5220 2018-09-04 Aldy Hernandez <aldyh@redhat.com>
5221
5222 * tree-vrp.c (vrp_can_optimize_bit_op): Remove.
5223 (extract_range_from_binary_expr_1): Do not call
5224 vrp_can_optimize_bit_op.
5225 * wide-int-range.cc (wide_int_range_can_optimize_bit_op): Make
5226 static.
5227 (wide_int_range_get_mask_and_bounds): New.
5228 (wide_int_range_optimize_bit_op): New.
5229 (wide_int_range_bit_ior): Call wide_int_range_optimize_bit_op.
5230 (wide_int_range_bit_and): Same.
5231 * wide-int-range.h (wide_int_range_can_optimize_bit_op): Remove.
5232 (wide_int_range_optimize_bit_op): New.
5233 (wide_int_range_get_mask_and_bounds): New.
5234
5235 2018-09-04 Richard Biener <rguenther@suse.de>
5236
5237 PR tree-optimization/87176
5238 * tree-ssa-sccvn.c (visit_phi): Remove redundant allsame
5239 variable. When value-numbering a virtual PHI node make sure
5240 to not value-number to the backedge value.
5241
5242 2018-09-04 Jonathan Wakely <jwakely@redhat.com>
5243
5244 * doc/extend.texi (Long Long, Hex Floats): Document support for
5245 long long and hex floats in more recent versions of ISO C++.
5246
5247 2018-09-03 Richard Biener <rguenther@suse.de>
5248
5249 PR tree-optimization/87177
5250 * tree-ssa-sccvn.c (vuse_ssa_val): Revert previous change, keep
5251 cleanup.
5252
5253 2018-09-03 Alexander Monakov <amonakov@ispras.ru>
5254
5255 * bb-reorder.c (edge_order): Convert to C-qsort-style
5256 tri-state comparator.
5257 (reorder_basic_blocks_simple): Change std::stable_sort to
5258 gcc_stablesort.
5259
5260 2018-09-03 Alexander Monakov <amonakov@ispras.ru>
5261
5262 * tree-loop-distribution.c (offset_cmp): Convert to C-qsort-style
5263 tri-state comparator.
5264 (fuse_memset_builtins): Change std::stable_sort to gcc_stablesort.
5265
5266 2018-09-03 Alexander Monakov <amonakov@ispras.ru>
5267
5268 * sort.cc (struct sort_ctx): New field 'nlim'. Use it...
5269 (mergesort): ... here as maximum count for using netsort.
5270 (gcc_qsort): Set nlim to 3 if stable sort is requested.
5271 (gcc_stablesort): New.
5272 * system.h (gcc_stablesort): Declare.
5273
5274 2018-09-03 Alexander Monakov <amonakov@ispras.ru>
5275
5276 * sort.cc (gcc_qsort) [CHECKING_P]: Call qsort_chk.
5277 * system.h (qsort): Always redirect to gcc_qsort. Update comment.
5278 * vec.c (qsort_chk): Do not call gcc_qsort. Update comment.
5279
5280 2018-09-03 Segher Boessenkool <segher@kernel.crashing.org>
5281
5282 * config/rs6000/rs6000.md (*mov<mode>_hardfloat32): Remove %U from the
5283 lxsdx and stxsdx alternatives.
5284 (*mov<mode>_hardfloat64): Ditto.
5285 * config/rs6000/vsx.md (*vsx_extract_<mode>_store): Ditto.
5286
5287 2018-09-03 Richard Biener <rguenther@suse.de>
5288
5289 PR tree-optimization/87200
5290 * tree-ssa-sccvn.c (vn_nary_build_or_lookup_1): Valueize a
5291 simplify result.
5292
5293 2018-09-03 Martin Liska <mliska@suse.cz>
5294
5295 PR tree-optimization/87201
5296 * tree-switch-conversion.c (switch_decision_tree::balance_case_nodes):
5297 Fix parenthesis in an expression.
5298
5299 2018-09-03 Richard Biener <rguenther@suse.de>
5300
5301 PR tree-optimization/87197
5302 * tree-ssa-sccvn.c (vn_nary_build_or_lookup_1): Mark the new def
5303 visited. CSE the VN_INFO hashtable lookup.
5304
5305 PR tree-optimization/87169
5306 * tree-ssa-sccvn.c (do_rpo_vn): When marking loops for not
5307 iterating make sure there's no extra backedges from irreducible
5308 regions feeding the header. Mark the destination block
5309 executable.
5310
5311 2018-09-03 Martin Liska <mliska@suse.cz>
5312
5313 PR driver/83193
5314 * common/common-target.def: Add TARGET_GET_VALID_OPTION_VALUES.
5315 * common/common-targhooks.c (default_get_valid_option_values):
5316 New function.
5317 * common/common-targhooks.h (default_get_valid_option_values):
5318 Likewise.
5319 * common/config/i386/i386-common.c: Move processor_target_table
5320 from i386.c.
5321 (ix86_get_valid_option_values): New function.
5322 (TARGET_GET_VALID_OPTION_VALUES): New macro.
5323 * config/i386/i386.c (struct ptt): Move to i386-common.c.
5324 (PTA_*): Move all defined masks into i386-common.c.
5325 (ix86_function_specific_restore): Use new processor_cost_table.
5326 * config/i386/i386.h (struct ptt): Moved from i386.c.
5327 (struct pta): Likewise.
5328 * doc/tm.texi: Document new TARGET_GET_VALID_OPTION_VALUES.
5329 * doc/tm.texi.in: Likewise.
5330 * opt-suggestions.c (option_proposer::suggest_option):
5331 Pass prefix to build_option_suggestions.
5332 (option_proposer::get_completions): Likewise.
5333 (option_proposer::build_option_suggestions): Use the new target
5334 hook.
5335 * opts.c (struct option_help_tuple): New struct.
5336 (print_filtered_help): Use the new target hook.
5337
5338 2018-09-03 Martin Liska <mliska@suse.cz>
5339
5340 PR middle-end/59521
5341 * predict.c (set_even_probabilities): Add likely_edges
5342 argument and handle cases where we have precisely one
5343 likely edge.
5344 (combine_predictions_for_bb): Catch also likely_edges.
5345 (tree_predict_by_opcode): Handle gswitch statements.
5346 * tree-cfg.h (find_case_label_for_value): New declaration.
5347 (find_taken_edge_switch_expr): Likewise.
5348 * tree-switch-conversion.c (switch_decision_tree::balance_case_nodes):
5349 Find pivot in decision tree based on probabily, not by number of
5350 nodes.
5351
5352 2018-09-02 Gerald Pfeifer <gerald@pfeifer.com>
5353
5354 * doc/standards.texi (Standards): Update Objective-C reference.
5355
5356 2018-09-01 Gerald Pfeifer <gerald@pfeifer.com>
5357
5358 * doc/install.texi (Prerequisites): Update link for MPC.
5359
5360 2018-09-01 Michael Matz <matz@suse.de>
5361
5362 PR tree-optimization/87074
5363 * gimple-loop-jam.c (unroll_jam_possible_p): Check loop exit
5364 PHIs for outer-loop uses.
5365
5366 2018-09-01 Gerald Pfeifer <gerald@pfeifer.com>
5367
5368 * doc/generic.texi (OpenMP): Adjust link to openmp.org.
5369 * doc/invoke.texi (C Dialect Options): Ditto.
5370
5371 2018-09-01 Gerald Pfeifer <gerald@pfeifer.com>
5372
5373 * doc/install.texi (Prerequisites): Adjust link mpfr.org.
5374
5375 2018-08-31 Richard Biener <rguenther@suse.de>
5376
5377 PR tree-optimization/87168
5378 * tree-ssa-sccvn.c (SSA_VAL): Add visited output parameter.
5379 (rpo_elim::eliminate_avail): When OP was not visited it must
5380 be available.
5381
5382 2018-08-31 David Malcolm <dmalcolm@redhat.com>
5383
5384 * tree-vrp.c (copy_value_range): Convert param "from" from
5385 "value_range *" to "const value_range *".
5386 (range_is_null): Likewise for param "vr".
5387 (range_int_cst_p): Likewise.
5388 (range_int_cst_singleton_p): Likewise.
5389 (symbolic_range_p): Likewise.
5390 (value_ranges_intersect_p): Likewise for both params.
5391 (value_range_nonnegative_p): Likewise for param "vr".
5392 (value_range_constant_singleton): Likewise.
5393 (vrp_set_zero_nonzero_bits): Likewise for param "ar".
5394 (extract_range_into_wide_ints): Likewise for param "vr".
5395 (extract_range_from_multiplicative_op): Likewise for params "vr0"
5396 and "vr1".
5397 (vrp_can_optimize_bit_op): Likewise.
5398 (extract_range_from_binary_expr_1): Likewise for params "vr0_" and
5399 "vr1_".
5400 (extract_range_from_unary_expr): Likewise.
5401 (debug_value_range): Likewise for param "vr".
5402 (value_range::dump): Add "const" qualifier.
5403 (vrp_prop::check_array_ref): Convert local "vr" from
5404 "value_range *" to "const value_range *".
5405 (vrp_prop::check_mem_ref): Likewise.
5406 (vrp_prop::visit_stmt): Likewise for local "old_vr".
5407 (vrp_intersect_ranges_1): Likewise for param "vr_1".
5408 (vrp_intersect_ranges): Likewise.
5409 (simplify_stmt_for_jump_threading): Likewise for local "vr".
5410 (vrp_prop::vrp_finalize): Likewise.
5411 * tree-vrp.h (value_range::dump): Add "const" qualifier.
5412 (vrp_intersect_ranges): Add "const" qualifier to params as above.
5413 (extract_range_from_unary_expr): Likewise.
5414 (value_range_constant_singleton): Likewise.
5415 (symbolic_range_p): Likewise.
5416 (copy_value_range): Likewise.
5417 (extract_range_from_binary_expr_1): Likewise.
5418 (range_int_cst_p): Likewise.
5419 (vrp_set_zero_nonzero_bits): Likewise.
5420 (range_int_cst_singleton_p): Likewise.
5421
5422 2018-08-31 Vlad Lazar <vlad.lazar@arm.com>
5423
5424 * config/aarch64/arm_neon.h (vabsd_s64): New.
5425 (vnegd_s64): Likewise.
5426
5427 2018-08-31 Martin Jambor <mjambor@suse.cz>
5428
5429 * ipa-cp.c (estimate_local_effects): Replace wrong MAX with MIN.
5430
5431 2018-08-31 Martin Liska <mliska@suse.cz>
5432
5433 * ipa-icf.c (sem_item::add_type): Use
5434 sem_item::m_type_hash_cache.
5435 * ipa-icf.h: Move the cache from sem_item_optimizer
5436 to sem_item.
5437
5438 2018-08-31 Nathan Sidwell <nathan@acm.org>
5439
5440 * doc/extend.texi (Backwards Compatibility): Remove implicit
5441 extern C leeway of () being (...).
5442
5443 2018-08-31 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
5444
5445 * ipa-inline.c (can_inline_edge_by_limits_p): Fix typos in comment.
5446
5447 2018-08-31 Segher Boessenkool <segher@kernel.crashing.org>
5448
5449 PR target/86684
5450 PR target/87149
5451 * config/rs6000/rs6000.md (lround<mode>di2): Gate on TARGET_FPRND.
5452
5453 2018-08-31 Jakub Jelinek <jakub@redhat.com>
5454
5455 PR middle-end/87138
5456 * expmed.c (expand_mult_const): Use immed_wide_int_const instead of
5457 gen_int_mode. Formatting fixes.
5458
5459 2018-08-30 Sandra Loosemore <sandra@codesourcery.com>
5460
5461 * target.def (custom_function_descriptors): Improve documentation.
5462 * doc/tm.texi.in (Trampolines): Expand discussion of function
5463 descriptors and move TARGET_CUSTOM_FUNCTION_DESCRIPTORS to the
5464 beginning of the section.
5465 * doc/tm.texi: Regenerated.
5466
5467 2018-08-30 Jose E. Marchesi <jose.marchesi@oracle.com>
5468
5469 * cfg.h (class auto_edge_flag): Spell out the template-id of the
5470 base class in the initializer list. This is a workaround for
5471 building with older GCC.
5472 (class auto_bb_flag): Likewise.
5473
5474 2018-08-30 Aaron Sawdey <acsawdey@linux.ibm.com>
5475
5476 * config/rs6000/altivec.md (altivec_eq<mode>): Remove star.
5477 (altivec_vcmpequ<VI_char>_p): Remove star.
5478 * config/rs6000/rs6000-string.c (do_load_for_compare): Support
5479 vector load modes.
5480 (expand_strncmp_vec_sequence): New function.
5481 (emit_final_str_compare_vec): New function.
5482 (expand_strn_compare): Add support for vector strncmp.
5483 * config/rs6000/rs6000.opt (-mstring-compare-inline-limit): Change
5484 length specification to bytes.
5485 * config/rs6000/vsx.md (vsx_ld_elemrev_v16qi_internal): Remove star.
5486 (vcmpnezb_p): New pattern.
5487 * doc/invoke.texi (RS/6000 and PowerPC Options): Update documentation
5488 for option -mstring-compare-inline-limit.
5489
5490 2018-08-30 Thiago Macieira <thiago.macieira@intel.com>
5491
5492 * config/i386/i386.c (PTA_WESTMERE): Remove PTA_AES.
5493 (PTA_SKYLAKE): Add PTA_AES.
5494 (PTA_GOLDMONT): Likewise.
5495
5496 2018-08-29 Jan Hubicka <jh@suse.cz>
5497
5498 PR lto/86517
5499 * lto-opts.c (lto_write_options): Always stream PIC/PIE mode.
5500 * lto-wrapper.c (merge_and_complain): Fix merging of PIC/PIE.
5501
5502 2018-08-29 Jan Hubicka <jh@suse.cz>
5503
5504 * lto-streamer-out.c (DFS::DFS_write_tree_body): Do not follow
5505 TYPE_STUB_DECL.
5506 (hash_tree): Do not visit TYPE_STUB_DECL.
5507 * tree-streamer-out.c (write_ts_type_common_tree_pointers): Do not
5508 stream TYPE_STUB_DECL.
5509 * tree-streamer-in.c (lto_input_ts_type_common_tree_pointers): Likewise.
5510 * ipa-utils.h (type_with_linkage_p): Do not rely on TYPE_STUB_DECL
5511 after free_lang_data.
5512 (type_in_anonymous_namespace_p): Likewise.
5513
5514 2018-08-29 Jan Hubicka <jh@suse.cz>
5515
5516 * sreal.h (SREAL_PART_BITS): Change to 31; remove seemingly unnecessary
5517 comment that it has to be even number.
5518 (class sreal): Change m_sig type to int32_t.
5519 * sreal.c (sreal::dump, sreal::to_int, opreator+, operator-): Use
5520 int64_t for temporary calculations.
5521 (sreal_verify_basics): Drop one bit from minimum and maximum.
5522
5523 2018-08-30 Richard Biener <rguenther@suse.de>
5524
5525 PR tree-optimization/87147
5526 * tree-ssa-sccvn.c (SSA_VISITED): New function.
5527 (visit_phi): When the degenerate result is from the backedge and
5528 we didn't visit its definition yet drop to VARYING.
5529 (do_rpo_vn): Properly mark blocks with incoming backedges as executable.
5530
5531 2018-08-29 Jan Hubicka <jh@suse.cz>
5532
5533 * lto-streamer-out.c (DFS::DFS_write_tree_body): Do not walk
5534 DECL_VINDEX.
5535 (hash_tree): Likewise.
5536
5537 2018-08-29 Jan Hubicka <jh@suse.cz>
5538
5539 * tree.c (find_decls_types_r): Walk also TYPE_NEXT_PTR_TO
5540 and TYPE_NEXT_REF_TO.
5541
5542 2018-08-29 Jan Hubicka <jh@suse.cz>
5543
5544 * sreal.h (SREAL_PART_BITS): Change to 31; remove seemingly unnecessary
5545 comment that it has to be even number.
5546 (class sreal): Change m_sig type to int32_t.
5547 * sreal.c (sreal::dump, sreal::to_int, opreator+, operator-): Use
5548 int64_t for temporary calculations.
5549 (sreal_verify_basics): Drop one bit from minimum and maximum.
5550
5551 2018-08-30 Tamar Christina <tamar.christina@arm.com>
5552
5553 * config/aarch64/aarch64.c (aarch64_expand_movmem): Set TImode max.
5554
5555 2018-08-30 Vlad Lazar <vlad.lazar@arm.com>
5556
5557 PR middle-end/86995
5558 * expmed.c (canonicalize_comparison): Use wi::sub instead of wi::add
5559 if to_add is negative.
5560
5561 2018-08-29 Bernd Edlinger <bernd.edlinger@hotmail.de>
5562
5563 PR middle-end/87053
5564 * builtins.c (c_strlen): Improve range checks.
5565
5566 2018-08-29 Martin Sebor <msebor@redhat.com>
5567 Jeff Law <law@redhat.com>
5568
5569 PR tree-optimization/86714
5570 PR tree-optimization/86711
5571 * builtins.c (c_strlen): Add arguments to call to string_constant.
5572 * expr.c (string_constant): Add argument. Detect missing nul
5573 terminator and outermost declaration it's missing in.
5574 * expr.h (string_constant): Add argument.
5575 * fold-const.c (read_from_constant_string): Add arguments to call to
5576 string_constant.
5577 (c_getstr): Likewise.
5578 * tree-ssa-forwprop.c (simplify_builtin_call): Likewise.
5579 to string_constant.
5580 * tree-ssa-strlen.c (get_stridx): Likewise.
5581
5582 2018-08-29 Jan Hubicka <jh@suse.cz>
5583
5584 * tree-streamer-in.c (lto_input_ts_function_decl_tree_pointers):
5585 Do not stream DECL_VINDEX.
5586 * tree-streamer-out.c (write_ts_function_decl_tree_pointers): Likewise.
5587 * tree.c (free_lang_data_in_decl): Clear DECL_VINDEX.
5588 (decl_function_context): Use DECL_VIRTUAL_P rather than DECL_VINDEX.
5589
5590 2018-08-29 Richard Biener <rguenther@suse.de>
5591
5592 * tree-ssa-sccvn.c (vuse_ssa_val): Return NULL for unvisited
5593 virtual operands that are not default defs to honor region
5594 boundaries.
5595 (rpo_vn_valueize): Remove ineffective code here.
5596
5597 2018-08-29 Richard Biener <rguenther@suse.de>
5598
5599 PR tree-optimization/87132
5600 * tree-ssa-alias.c (get_continuation_for_phi): Do not translate
5601 when skipping defs reachable over backedges.
5602
5603 2018-08-29 Richard Biener <rguenther@suse.de>
5604
5605 * tree-core.h: Document use of deprecated_flag in SSA_NAME.
5606 * tree.h (SSA_NAME_POINTS_TO_READONLY_MEMORY): Define.
5607 * tree-into-ssa.c (pass_build_ssa::execute): Initialize
5608 function parameters SSA_NAME_POINTS_TO_READONLY_MEMORY from fnspec.
5609 * tree-ssa-sccvn.c (const_parms, init_const_parms): Remove.
5610 (vn_reference_lookup_3): Remove use of const_parms.
5611 (free_rpo_vn): Do not free const_parms.
5612 (do_rpo_vn): Do not call init_const_parms.
5613 * tree-ssa-alias.c (refs_may_alias_p_1): Honor
5614 SSA_NAME_POINTS_TO_READONLY_MEMORY.
5615 (call_may_clobber_ref_p_1): Likewise.
5616
5617 2018-08-29 Alexander Monakov <amonakov@ispras.ru>
5618
5619 PR other/86726
5620 * invoke.texi (Optimization Options): List -ftree-scev-cprop.
5621 (-O): Ditto.
5622 (-ftree-scev-cprop): Document.
5623
5624 2018-08-29 Jan Hubicka <jh@suse.cz>
5625
5626 * sreal.h (normalize, normalize_up, normalize_down): Add new_sig/new_exp
5627 parameters.
5628 (sreal constructor): Update.
5629 * sreal.c (sreal:operator+, sreal:operator-, sreal:operator*,
5630 sreal:operator/): Update.
5631
5632 2018-08-29 Martin Liska <mliska@suse.cz>
5633
5634 * tree-switch-conversion.c (switch_conversion::expand):
5635 Strenghten assumption about gswitch statements.
5636
5637 2018-08-29 Richard Biener <rguenther@suse.de>
5638
5639 PR tree-optimization/87117
5640 * tree-ssa-sccvn.c (eliminate_dom_walker::eliminate_stmt): Only
5641 re-value-number released SSA VDEFs.
5642
5643 2018-08-29 Richard Biener <rguenther@suse.de>
5644
5645 PR tree-optimization/87126
5646 * tree-ssa-sccvn.c (vn_reference_insert): Remove assert.
5647
5648 2018-08-28 Jim Wilson <jimw@sifive.com>
5649
5650 * config/riscv/pic.md: Rewrite.
5651 * config/riscv/riscv.c (riscv_address_insns): Return cost of 3 for
5652 invalid address.
5653 * config/riscv/riscv.md (ZERO_EXTEND_LOAD): Delete.
5654 (SOFTF, default_load, softload, softstore): New.
5655
5656 2018-08-28 Jeff Law <law@redhat.com>
5657
5658 * fold-const.c (fold_binary_loc): Remove recently added assert.
5659
5660 2018-08-28 Joern Rennecke <joern.rennecke@riscy-ip.com>
5661
5662 * genpreds.c (write_predicate_subfunction): Also add ATTRIBUTE_UNUSED
5663 to OP parmeter of generated function.
5664
5665 2018-08-28 MCC CS <deswurstes@users.noreply.github.com>
5666
5667 PR tree-optimization/87009
5668 * match.pd: Add boolean optimizations.
5669
5670 2018-08-28 Martin Sebor <msebor@redhat.com>
5671
5672 PR middle-end/86631
5673 * calls.c (alloc_max_size): Treat HOST_WIDE_INT special.
5674 * gimple-ssa-warn-alloca.c (adjusted_warn_limit): New function.
5675 (pass_walloca::gate): Use it.
5676 (alloca_call_type): Same.
5677 (pass_walloca::execute): Same.
5678 * stor-layout.c (layout_decl): Treat HOST_WIDE_INT special.
5679
5680 2018-08-28 David Malcolm <dmalcolm@redhat.com>
5681
5682 * dumpfile.h (ATTRIBUTE_GCC_DUMP_PRINTF): Change version check on
5683 GCC_VERSION for usage of "__gcc_dump_printf__" format from
5684 >= 3005 to >= 9000.
5685
5686 2018-08-28 Richard Biener <rguenther@suse.de>
5687
5688 PR tree-optimization/87124
5689 * tree-ssa-sccvn.c (vn_lookup_simplify_result): Guard against
5690 constants before looking up avail.
5691
5692 2018-08-28 Jakub Jelinek <jakub@redhat.com>
5693
5694 PR middle-end/87099
5695 * calls.c (maybe_warn_nonstring_arg): Punt early if
5696 warn_stringop_overflow is zero. Don't call get_range_strlen
5697 on 3rd argument, keep iterating until lenrng[1] is INTEGER_CST.
5698 Swap comparison operands to have constants on rhs. Only use
5699 lenrng[1] if non-NULL and INTEGER_CST. Don't uselessly
5700 increment lenrng[0].
5701
5702 2018-08-28 Richard Sandiford <richard.sandiford@arm.com>
5703
5704 * tree-ssa-sccvn.c (fully_constant_vn_reference_p): Fix unguarded
5705 use of tree_to_shwi. Remove duplicated test for the size being
5706 a whole number of bytes.
5707
5708 2018-08-28 Richard Biener <rguenther@suse.de>
5709
5710 PR tree-optimization/87117
5711 * tree-ssa-sccvn.c (eliminate_dom_walker::eliminate_cleanup):
5712 Handle removed stmt without LHS (GIMPLE_NOP).
5713
5714 2018-08-28 Richard Biener <rguenther@suse.de>
5715
5716 PR tree-optimization/87117
5717 * tree-ssa-sccvn.c (fully_constant_vn_reference_p): Exclude
5718 void which is is_gimple_reg_type by checking for COMPLETE_TYPE_P.
5719
5720 2018-08-28 Richard Biener <rguenther@suse.de>
5721
5722 PR tree-optimization/87117
5723 * tree-ssa-pre.c (compute_avail): Do not make expressions
5724 with predicated values available.
5725 (get_expr_value_id): Assert we do not run into predicated value
5726 expressions.
5727
5728 2018-08-28 Richard Biener <rguenther@suse.de>
5729
5730 PR tree-optimization/87117
5731 * tree-ssa-operands.c (add_stmt_operand): STRING_CST may
5732 get virtual operands.
5733 (get_expr_operands): Handle STRING_CST like other decls.
5734
5735 2018-08-28 Martin Liska <mliska@suse.cz>
5736
5737 * tree.h: Update documentation of fndecl_built_in_p
5738 functions.
5739
5740
5741 2018-08-27 Jeff Law <law@redhat.com>
5742 PR tree-optimization/87110
5743 * tree-ssa-dse.c (compute_trims): Handle non-constant
5744 TYPE_SIZE_UNIT.
5745
5746 2018-08-27 Martin Sebor <msebor@redhat.com>
5747
5748 PR tree-optimization/86914
5749 * tree-ssa-strlen.c (maybe_set_strlen_range): Avoid MEM_REF.
5750
5751 2018-08-27 Martin Sebor <msebor@redhat.com>
5752
5753 PR tree-optimization/87112
5754 * builtins.c (expand_builtin_strnlen): Convert c_strlen result to
5755 the type of the bound argument.
5756
5757 2018-08-27 Jeff Law <law@redhat.com>
5758
5759 * tree-ssa-dse.c (compute_trims): Handle case where the reference's
5760 type does not have a TYPE_SIZE_UNIT.
5761
5762 2018-08-27 Steve Ellcey <sellcey@cavium.com>
5763
5764 * config/aarch64/aarch64-speculation.cc: Replace include of cfg.h
5765 with include of backend.h.
5766
5767 2018-08-27 Richard Biener <rguenther@suse.de>
5768
5769 PR tree-optimization/86927
5770 * tree-vect-loop.c (vect_create_epilog_for_reduction): Properly
5771 use const cond reduction code.
5772
5773 2018-08-27 Alexander Monakov <amonakov@ispras.ru>
5774
5775 PR tree-optimization/85758
5776 * match.pd ((X & Y) ^ Y): Add :s qualifier to inner expression.
5777
5778 2018-08-27 David Malcolm <dmalcolm@redhat.com>
5779
5780 PR c++/87091
5781 * diagnostic-show-locus.c (class layout_range): Update for
5782 conversion of show_caret_p to a tri-state.
5783 (layout_range::layout_range): Likewise.
5784 (make_range): Likewise.
5785 (layout::maybe_add_location_range): Likewise.
5786 (layout::should_print_annotation_line_p): Don't show annotation
5787 lines for ranges that are SHOW_LINES_WITHOUT_RANGE.
5788 (layout::get_state_at_point): Update for conversion of
5789 show_caret_p to a tri-state. Bail out early for
5790 SHOW_LINES_WITHOUT_RANGE, so that such ranges don't affect
5791 underlining or source colorization.
5792 (gcc_rich_location::add_location_if_nearby): Update for conversion
5793 of show_caret_p to a tri-state.
5794 (selftest::test_one_liner_multiple_carets_and_ranges): Likewise.
5795 (selftest::test_one_liner_fixit_replace_equal_secondary_range):
5796 Likewise.
5797 (selftest::test_one_liner_labels): Likewise.
5798 * gcc-rich-location.c (gcc_rich_location::add_expr): Update for
5799 conversion of show_caret_p to a tri-state.
5800 * pretty-print.c (text_info::set_location): Likewise.
5801 * pretty-print.h (text_info::set_location): Likewise.
5802 * substring-locations.c (format_warning_n_va): Likewise.
5803 * tree-diagnostic.c (default_tree_printer): Likewise.
5804 * tree-pretty-print.c (newline_and_indent): Likewise.
5805
5806 2018-08-27 David Malcolm <dmalcolm@redhat.com>
5807
5808 PR c++/87091
5809 * diagnostic-show-locus.c (get_line_span_for_fixit_hint): Show the
5810 line above for line-insertion fix-it hints.
5811 (selftest::test_fixit_insert_containing_newline): Update the
5812 expected results, and add a test with line-numbering enabled.
5813
5814 2018-08-27 Martin Liska <mliska@suse.cz>
5815
5816 PR sanitizer/86962
5817 * sanopt.c (sanitize_rewrite_addressable_params): Ignore
5818 params with DECL_HAS_VALUE_EXPR_P.
5819
5820 2018-08-27 Martin Liska <mliska@suse.cz>
5821
5822 * config/i386/i386.c (ix86_expand_set_or_movmem): Dump
5823 selected expansion strategy.
5824
5825 2018-08-27 Martin Liska <mliska@suse.cz>
5826
5827 * builtins.h (is_builtin_fn): Remove and fndecl_built_in_p.
5828 * builtins.c (is_builtin_fn): Likewise.
5829 * attribs.c (diag_attr_exclusions): Use new function
5830 fndecl_built_in_p and remove check for FUNCTION_DECL if
5831 possible.
5832 (builtin_mathfn_code): Likewise.
5833 (fold_builtin_expect): Likewise.
5834 (fold_call_expr): Likewise.
5835 (fold_builtin_call_array): Likewise.
5836 (fold_call_stmt): Likewise.
5837 (set_builtin_user_assembler_name): Likewise.
5838 (is_simple_builtin): Likewise.
5839 * calls.c (gimple_alloca_call_p): Likewise.
5840 (maybe_warn_nonstring_arg): Likewise.
5841 * cfgexpand.c (expand_call_stmt): Likewise.
5842 * cgraph.c (cgraph_update_edges_for_call_stmt_node): Likewise.
5843 (cgraph_edge::verify_corresponds_to_fndecl): Likewise.
5844 (cgraph_node::verify_node): Likewise.
5845 * cgraphclones.c (build_function_decl_skip_args): Likewise.
5846 (cgraph_node::create_clone): Likewise.
5847 * config/arm/arm.c (arm_insert_attributes): Likewise.
5848 * config/i386/i386.c (ix86_gimple_fold_builtin): Likewise.
5849 * dse.c (scan_insn): Likewise.
5850 * expr.c (expand_expr_real_1): Likewise.
5851 * fold-const.c (operand_equal_p): Likewise.
5852 (fold_binary_loc): Likewise.
5853 * gimple-fold.c (gimple_fold_stmt_to_constant_1): Likewise.
5854 * gimple-low.c (lower_stmt): Likewise.
5855 * gimple-pretty-print.c (dump_gimple_call): Likewise.
5856 * gimple-ssa-warn-restrict.c (wrestrict_dom_walker::check_call):
5857 Likewise.
5858 * gimple.c (gimple_build_call_from_tree): Likewise.
5859 (gimple_call_builtin_p): Likewise.
5860 (gimple_call_combined_fn): Likewise.
5861 * gimplify.c (gimplify_call_expr): Likewise.
5862 (gimple_boolify): Likewise.
5863 (gimplify_modify_expr): Likewise.
5864 (gimplify_addr_expr): Likewise.
5865 * hsa-gen.c (gen_hsa_insns_for_call): Likewise.
5866 * ipa-cp.c (determine_versionability): Likewise.
5867 * ipa-fnsummary.c (compute_fn_summary): Likewise.
5868 * ipa-param-manipulation.c (ipa_modify_formal_parameters): Likewise.
5869 * ipa-split.c (visit_bb): Likewise.
5870 (split_function): Likewise.
5871 * ipa-visibility.c (cgraph_externally_visible_p): Likewise.
5872 * lto-cgraph.c (input_node): Likewise.
5873 * lto-streamer-out.c (write_symbol): Likewise.
5874 * omp-low.c (setjmp_or_longjmp_p): Likewise.
5875 (lower_omp_1): Likewise.
5876 * predict.c (strip_predict_hints): Likewise.
5877 * print-tree.c (print_node): Likewise.
5878 * symtab.c (symtab_node::output_to_lto_symbol_table_p): Likewise.
5879 * trans-mem.c (is_tm_irrevocable): Likewise.
5880 (is_tm_load): Likewise.
5881 (is_tm_simple_load): Likewise.
5882 (is_tm_store): Likewise.
5883 (is_tm_simple_store): Likewise.
5884 (is_tm_abort): Likewise.
5885 (tm_region_init_1): Likewise.
5886 * tree-call-cdce.c (gen_shrink_wrap_conditions): Likewise.
5887 * tree-cfg.c (verify_gimple_call): Likewise.
5888 (move_stmt_r): Likewise.
5889 (stmt_can_terminate_bb_p): Likewise.
5890 * tree-eh.c (lower_eh_constructs_2): Likewise.
5891 * tree-if-conv.c (if_convertible_stmt_p): Likewise.
5892 * tree-inline.c (remap_gimple_stmt): Likewise.
5893 (copy_bb): Likewise.
5894 (estimate_num_insns): Likewise.
5895 (fold_marked_statements): Likewise.
5896 * tree-sra.c (scan_function): Likewise.
5897 * tree-ssa-ccp.c (surely_varying_stmt_p): Likewise.
5898 (optimize_stack_restore): Likewise.
5899 (pass_fold_builtins::execute): Likewise.
5900 * tree-ssa-dce.c (mark_stmt_if_obviously_necessary): Likewise.
5901 (mark_all_reaching_defs_necessary_1): Likewise.
5902 * tree-ssa-dom.c (dom_opt_dom_walker::optimize_stmt): Likewise.
5903 * tree-ssa-forwprop.c (simplify_builtin_call): Likewise.
5904 (pass_forwprop::execute): Likewise.
5905 * tree-ssa-loop-im.c (stmt_cost): Likewise.
5906 * tree-ssa-math-opts.c (pass_cse_reciprocals::execute): Likewise.
5907 * tree-ssa-sccvn.c (fully_constant_vn_reference_p): Likewise.
5908 * tree-ssa-strlen.c (get_string_length): Likewise.
5909 * tree-ssa-structalias.c (handle_lhs_call): Likewise.
5910 (find_func_aliases_for_call): Likewise.
5911 * tree-ssa-ter.c (find_replaceable_in_bb): Likewise.
5912 * tree-stdarg.c (optimize_va_list_gpr_fpr_size): Likewise.
5913 * tree-tailcall.c (find_tail_calls): Likewise.
5914 * tree.c (need_assembler_name_p): Likewise.
5915 (free_lang_data_in_decl): Likewise.
5916 (get_call_combined_fn): Likewise.
5917 * ubsan.c (is_ubsan_builtin_p): Likewise.
5918 * varasm.c (incorporeal_function_p): Likewise.
5919 * tree.h (DECL_BUILT_IN): Remove and replace with
5920 fndecl_built_in_p.
5921 (DECL_BUILT_IN_P): Transfort to fndecl_built_in_p.
5922 (fndecl_built_in_p): New.
5923
5924 2018-08-27 Martin Liska <mliska@suse.cz>
5925
5926 PR tree-optimization/86847
5927 * tree-switch-conversion.c (switch_decision_tree::dump_case_nodes):
5928 Dump also subtree probability.
5929 (switch_decision_tree::do_jump_if_equal): New function.
5930 (switch_decision_tree::emit_case_nodes): Handle special
5931 situations in balanced tree that can be emitted much simpler.
5932 Fix calculation of probabilities that happen in tree expansion.
5933 * tree-switch-conversion.h (struct cluster): Add
5934 is_single_value_p.
5935 (struct simple_cluster): Likewise.
5936 (struct case_tree_node): Add new function has_child.
5937 (do_jump_if_equal): New.
5938
5939 2018-08-27 Martin Liska <mliska@suse.cz>
5940
5941 * tree-switch-conversion.c (bit_test_cluster::find_bit_tests):
5942 Add new argument to bit_test_cluster constructor.
5943 (bit_test_cluster::emit): Set bits really number of values
5944 handlel by a test.
5945 (bit_test_cluster::hoist_edge_and_branch_if_true): Add
5946 probability argument.
5947 * tree-switch-conversion.h (struct bit_test_cluster):
5948 Add m_handles_entire_switch.
5949
5950 2018-08-27 Martin Liska <mliska@suse.cz>
5951
5952 PR tree-optimization/86702
5953 * tree-switch-conversion.c (jump_table_cluster::emit):
5954 Make probabilities even for values in jump table
5955 according to number of cases handled.
5956 (switch_decision_tree::compute_cases_per_edge): Pass
5957 argument to reset_out_edges_aux function.
5958 (switch_decision_tree::analyze_switch_statement): Likewise.
5959 * tree-switch-conversion.h (switch_decision_tree::reset_out_edges_aux):
5960 Make it static.
5961
5962 2018-08-27 Martin Liska <mliska@suse.cz>
5963
5964 * cfgexpand.c (expand_asm_stmt): Use label_to_block and pass
5965 cfun argument explicitly.
5966 * gimple-pretty-print.c (dump_gimple_switch): Likewise.
5967 * hsa-gen.c (gen_hsa_insns_for_switch_stmt): Use new
5968 function gimple_switch_default_bb.
5969 (convert_switch_statements):
5970 (expand_builtins):
5971 * ipa-fnsummary.c (set_switch_stmt_execution_predicate):
5972 * stmt.c (label_to_block_fn): Use label_to_block and pass
5973 cfun argument explicitly and use gimple_switch_label_bb.
5974 (expand_case): Likewise.
5975 * tree-cfg.c (lower_phi_internal_fn): Use label_to_block and pass
5976 cfun argument explicitly. Likewise.
5977 (make_edges_bb): Likewise.
5978 (make_cond_expr_edges): Likewise.
5979 (get_cases_for_edge): Likewise.
5980 (make_gimple_switch_edges): Likewise.
5981 (label_to_block_fn): Likewise.
5982 (label_to_block): Likewise.
5983 (make_goto_expr_edges): Likewise.
5984 (make_gimple_asm_edges): Likewise.
5985 (main_block_label): Likewise.
5986 (group_case_labels_stmt): Likewise.
5987 (find_taken_edge_computed_goto): Likewise.
5988 (find_taken_edge_switch_expr): Likewise.
5989 (gimple_verify_flow_info): Likewise.
5990 (gimple_redirect_edge_and_branch): Likewise.
5991 (gimple_switch_label_bb): New function.
5992 (gimple_switch_default_bb): Likewise.
5993 (gimple_switch_edge): Likewise.
5994 (gimple_switch_default_edge): Likewise.
5995 * tree-cfg.h (label_to_block_fn): Remove and replace ...
5996 (label_to_block): ... with this.
5997 (gimple_switch_label_bb): New.
5998 (gimple_switch_default_bb): Likewise.
5999 (gimple_switch_edge): Likewise.
6000 (gimple_switch_default_edge): Likewise.
6001 * tree-cfgcleanup.c (convert_single_case_switch): Use
6002 new gimple functions and pass new argument to label_to_block.
6003 (cleanup_control_flow_bb):
6004 * tree-eh.c (make_eh_dispatch_edges): Use label_to_block and pass
6005 cfun argument explicitly.
6006 (make_eh_edges): Likewise.
6007 (redirect_eh_dispatch_edge): Likewise.
6008 (lower_resx): Likewise.
6009 (lower_eh_dispatch): Likewise.
6010 (maybe_remove_unreachable_handlers): Likewise.
6011 (unsplit_eh): Likewise.
6012 (cleanup_empty_eh): Likewise.
6013 (verify_eh_edges): Likewise.
6014 (verify_eh_dispatch_edge): Likewise.
6015 * tree-ssa-dom.c (record_edge_info): Likewise.
6016 * tree-ssa-forwprop.c (simplify_gimple_switch_label_vec): Likewise.
6017 * tree-ssa-threadedge.c (thread_around_empty_blocks): Likewise.
6018 (thread_through_normal_block): Likewise.
6019 * tree-ssa-uncprop.c (associate_equivalences_with_edges): Likewise.
6020 * tree-ssa-uninit.c (convert_control_dep_chain_into_preds):
6021 * tree-switch-conversion.c (switch_conversion::collect): Use new
6022 gimple functions.
6023 (switch_conversion::check_final_bb): Likewise.
6024 (switch_conversion::gather_default_values): Pass new argument
6025 to label_to_block.
6026 (switch_conversion::build_constructors): Likewise.
6027 (switch_decision_tree::compute_cases_per_edge): Use new
6028 gimple_switch_edge function.
6029 (switch_decision_tree::analyze_switch_statement): Pass new argument
6030 to label_to_block.
6031 (switch_decision_tree::try_switch_expansion): Use
6032 gimple_switch_default_edge.
6033 * tree-vrp.c (find_switch_asserts): Pass new argument
6034 to label_to_block.
6035 * vr-values.c (vr_values::vrp_visit_switch_stmt): Likewise.
6036 (vr_values::simplify_switch_using_ranges): Likewise.
6037
6038 2018-08-27 Richard Biener <rguenther@suse.de>
6039
6040 * cfganal.h (rev_post_order_and_mark_dfs_back_seme): Declare.
6041 * cfganal.c (rev_post_order_and_mark_dfs_back_seme): New function.
6042
6043 * tree-ssa-sccvn.h (struct vn_pval): New structure.
6044 (struct vn_nary_op_s): Add unwind_to member. Add
6045 predicated_values flag and put result into a union together
6046 with a linked list of vn_pval.
6047 (struct vn_ssa_aux): Add name member to make maintaining
6048 a map of SSA name to vn_ssa_aux possible. Remove no longer
6049 needed info, dfsnum, low, visited, on_sccstack, use_processed
6050 and range_info_anti_range_p members.
6051 (run_scc_vn, vn_eliminate, free_scc_vn, vn_valueize): Remove.
6052 (do_rpo_vn, run_rpo_vn, eliminate_with_rpo_vn, free_rpo_vn):
6053 New functions.
6054 (vn_valueize): New global.
6055 (vn_context_bb): Likewise.
6056 (VN_INFO_RANGE_INFO, VN_INFO_ANTI_RANGE_P, VN_INFO_RANGE_TYPE,
6057 VN_INFO_PTR_INFO): Remove.
6058 * tree-ssa-sccvn.c: ... (rewrite)
6059 (pass_fre::execute): For -O2+ initialize loops and run
6060 RPO VN in optimistic mode (iterating). For -O1 and -Og
6061 run RPO VN in non-optimistic mode.
6062 * params.def (PARAM_SCCVN_MAX_SCC_SIZE): Remove.
6063 (PARAM_RPO_VN_MAX_LOOP_DEPTH): Add.
6064 * doc/invoke.texi (sccvn-max-scc-size): Remove.
6065 (rpo-vn-max-loop-depth): Document.
6066 * tree-ssa-alias.c (walk_non_aliased_vuses): Stop walking
6067 when valuezing the VUSE signals we walked out of the region.
6068 * tree-ssa-pre.c (phi_translate_1): Ignore predicated values.
6069 (phi_translate): Set VN context block to use for availability
6070 lookup.
6071 (compute_avail): Likewise.
6072 (pre_valueize): New function.
6073 (pass_pre::execute): Adjust to the RPO VN API.
6074
6075 * tree-ssa-loop-ivcanon.c: Include tree-ssa-sccvn.h.
6076 (propagate_constants_for_unrolling): Remove.
6077 (tree_unroll_loops_completely): Perform value-numbering
6078 on the unrolled bodies loop parent.
6079
6080 2018-08-27 Richard Biener <rguenther@suse.de>
6081
6082 * tree-ssa-pre.c (compute_antic): Re-use inverted postorder
6083 for partial antic compute.
6084
6085 2018-08-27 Jakub Jelinek <jakub@redhat.com>
6086
6087 PR rtl-optimization/87065
6088 * combine.c (simplify_if_then_else): Formatting fix.
6089 (if_then_else_cond): Guard MULT optimization with SCALAR_INT_MODE_P
6090 check.
6091 (known_cond): Don't return const_true_rtx for vector modes. Use
6092 CONST0_RTX instead of const0_rtx. Formatting fixes.
6093
6094 2018-08-27 Martin Liska <mliska@suse.cz>
6095
6096 PR gcov-profile/87069
6097 * gcov.c (process_file): Record files already processed
6098 and warn about a file being processed multiple times.
6099
6100 2018-08-27 Martin Liska <mliska@suse.cz>
6101
6102 PR driver/83193
6103 * config/aarch64/aarch64.c (aarch64_override_options_internal):
6104 Set default values for x_aarch64_*_string strings.
6105 * config/aarch64/aarch64.opt: Remove --{march,mcpu,mtune}==
6106 prefix. For -mabi do not print '=ABI' in help and use
6107 <option_value> format for -msve-vector-bits and -moverride
6108 options.
6109
6110 2018-08-26 Jeff Law <law@redhat.com>
6111
6112 * config/mips/frame-header-opt.c: Include "backend.h" rather than
6113 "cfg.h"
6114
6115 2018-08-26 Marek Polacek <polacek@redhat.com>
6116
6117 PR c++/87029, Implement -Wredundant-move.
6118 * doc/invoke.texi: Document -Wredundant-move.
6119
6120 2018-08-25 Martin Sebor <msebor@redhat.com>
6121
6122 PR tree-optimization/87059
6123 * builtins.c (expand_builtin_strncmp): Convert MIN_EXPR operand
6124 to the same type as the other.
6125 * fold-const.c (fold_binary_loc): Assert expectation.
6126
6127 2018-08-25 Iain Sandoe <iain@sandoe.co.uk>
6128
6129 * config/darwin.c (machopic_legitimize_pic_address): Clean up
6130 extraneous parentheses, dead code section and formatting.
6131
6132 2018-08-24 David Malcolm <dmalcolm@redhat.com>
6133
6134 PR c++/87091
6135 * diagnostic-show-locus.c (layout::layout): Ensure the margin is
6136 wide enough for jumps in the line-numbering to be visible.
6137 (layout::print_gap_in_line_numbering): New member function.
6138 (layout::calculate_line_spans): When using line numbering, merge
6139 line spans that are only 1 line apart.
6140 (diagnostic_show_locus): When printing line numbers, show gaps in
6141 line numbering directly, rather than printing headers.
6142 (selftest::test_diagnostic_show_locus_fixit_lines): Add test of
6143 line-numbering with multiple line spans.
6144 (selftest::test_fixit_insert_containing_newline_2): Add test of
6145 line-numbering, in which the spans are close enough to be merged.
6146
6147 2018-08-24 Aldy Hernandez <aldyh@redhat.com>
6148
6149 * gimple-ssa-evrp-analyze.c (set_ssa_range_info): Pass value_range
6150 to range_includes_zero_p. Do not special case VR_ANTI_RANGE.
6151 * tree-vrp.c (range_is_nonnull): Remove.
6152 (range_includes_zero_p): Accept value_range instead of min/max.
6153 (extract_range_from_binary_expr_1): Do not early bail on
6154 POINTER_PLUS_EXPR.
6155 Use range_includes_zero_p instead of range_is_nonnull.
6156 (extract_range_from_unary_expr): Use range_includes_zero_p instead
6157 of range_is_nonnull.
6158 (vrp_meet_1): Pass value_range to range_includes_zero_p. Do not
6159 special case VR_ANTI_RANGE.
6160 (vrp_finalize): Same.
6161 * tree-vrp.h (range_includes_zero_p): Pass value_range as argument
6162 instead of min/max.
6163 (range_is_nonnull): Remove.
6164 * vr-values.c (vrp_stmt_computes_nonzero): Use
6165 range_includes_zero_p instead of range_is_nonnull.
6166 (extract_range_basic): Pass value_range to range_includes_zero_p
6167 instead of range_is_nonnull.
6168
6169 2018-08-24 Uros Bizjak <ubizjak@gmail.com>
6170
6171 * emit-rtl.c (init_emit_once): Do not emit MODE_POINTER_BOUNDS RTXes.
6172 * emit-rtl.h (rtl_data): Remove return_bnd.
6173 * explow.c (trunc_int_for_mode): Do not handle POINTER_BOUNDS_MODE_P.
6174 * function.c (diddle_return_value): Do not handle crtl->return_bnd.
6175 * genmodes.c (complete_mode): Do not handle MODE_POINTER_BOUNDS.
6176 (POINTER_BOUNDS_MODE): Remove definition.
6177 (make_pointer_bounds_mode): Remove.
6178 (get_mode_class): Do not handle MODE_POINTER_BOUNDS.
6179 * machmode.h (POINTER_BOUNDS_MODE_P): Remove definition.
6180 (scalare_mode::includes_p): Do not handle MODE_POINTER_BOUNDS.
6181 * mode-classes.def: Do not define MODE_POINTER_BOUNDS.
6182 * stor-layout.c (int_mode_for_mode): Do not handle MODE_POINTER_BOUNDS.
6183 * tree-core.h (enum tree_index): Remove TI_POINTER_BOUNDS_TYPE.
6184 * varasm.c (output_constant_pool_2): Do not handle MODE_POINTER_BOUNDS.
6185
6186 * config/i386/i386-modes.def (BND32, BND64): Remove.
6187 * config/i386/i386.c (dbx_register_map): Remove bound registers.
6188 (dbx64_register_map): Ditto.
6189 (svr4_dbx_register_map): Ditto.
6190 (indirect_thunk_bnd_needed): Remove.
6191 (indirect_thunks_bnd_used): Ditto.
6192 (indirect_return_bnd_needed): Ditto.
6193 (indirect_return_via_cx_bnd): Ditto.
6194 (enum indirect_thunk_prefix): Remove indirect_thunk_prefix_bnd.
6195 (indirect_thunk_name): Remove handling of indirect_thunk_prefix_bnd.
6196 (output_indirect_thunk): Ditto. Remove need_prefix argument.
6197 (output_indirect_thunk_function): Remove handling of
6198 indirect_return_bnd_needed, indirect_return_via_cx_bnd,
6199 indirect_thunk_bnd_needed and indirect_thunks_bnd_used variables.
6200 (ix86_save_reg): Remove handling of crtl->return_bnd.
6201 (ix86_legitimate_constant_p): Remove handling of POINTER_BOUNDS_MODE_P.
6202 (ix86_print_operand_address_as): Remove handling of UNSPEC_BNDMK_ADDR
6203 and UNSPEC_BNDLX_ADDR.
6204 (ix86_output_indirect_branch_via_reg): Remove handling of
6205 indirect_thunk_prefix_bnd.
6206 (ix86_output_indirect_branch_via_push): Ditto.
6207 (ix86_output_function_return): Ditto.
6208 (ix86_output_indirect_function_return): Ditto.
6209 (avoid_func_arg_motion): Do not handle UNSPEC_BNDSTX.
6210 * config/i386/i386.h (FIXED_REGISTERS): Remove bound registers.
6211 (CALL_USED_REGISTERS): Ditto.
6212 (REG_ALLOC_ORDER): Update for removal of bound registers.
6213 (HI_REGISTER_NAMES): Ditto.
6214 * config/i386/i386.md (UNSPEC_BNDMK, UNSPEC_BNDMK_ADDR, UNSPEC_BNDSTX)
6215 (UNSPEC_BNDLDX, UNSPEC_BNDLDX_ADDR, UNSPEC_BNDCL, UNSPEC_BNDCU)
6216 (UNSPEC_BNDCN, UNSPEC_MPX_FENCE): Remove.
6217 (BND0_REG, BND1_REG, BND2_REG, BND3_REG): Remove
6218 (FIRST_PSEUDO_REG): Update.
6219 (BND): Remove mode iterator.
6220 * config/i386/predicates.md (bnd_mem_operator): Remove.
6221
6222 2018-08-24 Richard Sandiford <richard.sandiford@arm.com>
6223
6224 * tree-vect-stmts.c (vectorizable_bswap): Handle variable-length
6225 vectors.
6226
6227 2018-08-24 Richard Sandiford <richard.sandiford@arm.com>
6228
6229 * tree-vect-slp.c (vect_transform_slp_perm_load): Separate out
6230 the case in which the permute needs only a single element and
6231 repeats for every vector of the result. Extend that case to
6232 handle variable-length vectors.
6233 * tree-vect-stmts.c (vectorizable_load): Update accordingly.
6234
6235 2018-08-24 H.J. Lu <hongjiu.lu@intel.com>
6236
6237 PR debug/79342
6238 * dwarf2out.c (save_macinfo_strings): Call set_indirect_string
6239 on DW_MACINFO_start_file for -gsplit-dwarf -g3.
6240
6241 2018-08-24 Richard Biener <rguenther@suse.de>
6242
6243 * cfg.h (struct control_flow_graph): Add edge_flags_allocated and
6244 bb_flags_allocated members.
6245 (auto_flag): New RAII class for allocating flags.
6246 (auto_edge_flag): New RAII class for allocating edge flags.
6247 (auto_bb_flag): New RAII class for allocating bb flags.
6248 * cfgloop.c (verify_loop_structure): Allocate temporary edge
6249 flag dynamically.
6250 * cfganal.c (dfs_enumerate_from): Remove use of visited sbitmap
6251 in favor of temporarily allocated BB flag.
6252 * hsa-brig.c: Re-order includes.
6253 * hsa-dump.c: Likewise.
6254 * hsa-regalloc.c: Likewise.
6255 * print-rtl.c: Likewise.
6256 * profile-count.c: Likewise.
6257
6258 2018-08-24 Segher Boessenkool <segher@kernel.crashing.org>
6259
6260 PR target/86989
6261 * config/rs6000/rs6000.c (toc_relative_expr_p): Check that the base is
6262 the TOC register.
6263
6264 2018-08-24 Aldy Hernandez <aldyh@redhat.com>
6265
6266 PR 87073/bootstrap
6267 * wide-int-range.cc (wide_int_range_div): Do not ignore result
6268 from wide_int_range_multiplicative_op.
6269
6270 2018-08-23 Prathamesh Kulkarni <prathamesh.kulkarni@linaro.org>
6271
6272 * tree-vect-data-refs.c (vect_grouped_store_supported): Fix typo
6273 "permutaion".
6274
6275 2018-08-23 Giuliano Belinassi <giuliano.belinassi@usp.br>
6276
6277 * genmatch.c (parser::parse_operation): Fix typo 'exapnded'
6278 to 'expanded'.
6279
6280 2018-08-23 Alexander Monakov <amonakov@ispras.ru>
6281
6282 * tree-scalar-evolution.c (final_value_replacement_loop): Dump
6283 full GENERIC expression used for replacement.
6284
6285 2018-08-23 Aldy Hernandez <aldyh@redhat.com>
6286
6287 * tree-vrp.c (abs_extent_range): Remove.
6288 (extract_range_into_wide_ints): Pass wide ints by reference.
6289 (extract_range_from_binary_expr_1): Rewrite the *DIV_EXPR code.
6290 Pass wide ints by reference in all calls to
6291 extract_range_into_wide_ints.
6292 * wide-int-range.cc (wide_int_range_div): New.
6293 * wide-int-range.h (wide_int_range_div): New.
6294 (wide_int_range_includes_zero_p): New.
6295 (wide_int_range_zero_p): New.
6296
6297 2018-08-23 Matthew Malcomson <matthew.malcomson@arm.com>
6298
6299 * config/aarch64/aarch64.md (arches): New enum.
6300 (arch): New enum attr.
6301 (arch_enabled): New attr.
6302 (enabled): Now uses arch_enabled only.
6303 (simd, sve, fp16): Removed attribute.
6304 (fp): Attr now defined in terms of 'arch'.
6305 (*mov<mode>_aarch64, *movsi_aarch64, *movdi_aarch64, *movti_aarch64,
6306 *movhf_aarch64, <optab><fcvt_target><GPF:mode>2,
6307 <FCVT_F2FIXED:fcvt_fixed_insn><GPF:mode>3,
6308 <FCVT_FIXED2F:fcvt_fixed_insn><GPI:mode>3): Merge 'fp' and 'simd'
6309 attributes into 'arch'.
6310 (*movsf_aarch64, *movdf_aarch64, *movtf_aarch64, *add<mode>3_aarch64,
6311 subdi3, neg<mode>2, <optab><mode>3, one_cmpl<mode>2,
6312 *<NLOGICAL:optab>_one_cmpl<mode>3, *xor_one_cmpl<mode>3,
6313 *aarch64_ashl_sisd_or_int_<mode>3, *aarch64_lshr_sisd_or_int_<mode>3,
6314 *aarch64_ashr_sisd_or_int_<mode>3, *aarch64_sisd_ushl): Convert use of
6315 'simd' attribute into 'arch'.
6316 (load_pair_sw_<SX:mode><SX2:mode>, load_pair_dw_<DX:mode><DX2:mode>,
6317 store_pair_sw_<SX:mode><SX2:mode>, store_pair_dw_<DX:mode><DX2:mode>):
6318 Convert use of 'fp' attribute to 'arch'.
6319 * config/aarch64/aarch64-simd.md (move_lo_quad_internal_<mode>,
6320 move_lo_quad_internal_<mode>): (different modes) Merge 'fp' and 'simd'
6321 into 'arch'.
6322 (move_lo_quad_internal_be_<mode>, move_lo_quad_internal_be_<mode>):
6323 (different modes) Merge 'fp' and 'simd' into 'arch'.
6324 (*aarch64_combinez<mode>, *aarch64_combinez_be<mode>): Merge 'fp' and
6325 'simd' into 'arch'.
6326
6327 2018-08-23 Segher Boessenkool <segher@kernel.crashing.org>
6328
6329 PR rtl-optimization/87026
6330 * expmed.c (canonicalize_comparison): If we can no longer create
6331 pseudoregisters, don't.
6332
6333 2018-08-23 Richard Earnshaw <rearnsha@arm.com>
6334
6335 PR target/86951
6336 * config/arm/arm-protos.h (arm_emit_speculation_barrier): New
6337 prototype.
6338 * config/arm/arm.c (speculation_barrier_libfunc): New static
6339 variable.
6340 (arm_init_libfuncs): Initialize it.
6341 (arm_emit_speculation_barrier): New function.
6342 * config/arm/arm.md (speculation_barrier): Call
6343 arm_emit_speculation_barrier for architectures that do not have
6344 DSB or ISB.
6345 (speculation_barrier_insn): Only match on Armv7 or later.
6346
6347 2018-08-23 Richard Biener <rguenther@suse.de>
6348
6349 PR middle-end/87024
6350 * tree-inline.c (copy_bb): Drop unused __builtin_va_arg_pack_len
6351 calls.
6352
6353 2018-08-23 Richard Sandiford <richard.sandiford@arm.com>
6354
6355 * config/aarch64/aarch64.c (aarch64_evpc_sve_tbl): Fix handling
6356 of single-vector TBLs.
6357 (aarch64_vectorize_vec_perm_const): Set one_vector_p when only
6358 one input is given.
6359
6360 2018-08-23 Richard Sandiford <richard.sandiford@arm.com>
6361
6362 PR target/85910
6363 * config/aarch64/aarch64.c (aarch64_expand_vec_perm_const_1): Fix
6364 aarch64_evpc_tbl guard.
6365
6366 2018-08-22 Bernd Edlinger <bernd.edlinger@hotmail.de>
6367
6368 * tree-ssa-dse.c (compute_trims): Avoid folding away undefined
6369 behaviour.
6370
6371 2018-08-22 Martin Sebor <msebor@redhat.com>
6372
6373 PR middle-end/87052
6374 * tree-pretty-print.c (pretty_print_string): Add argument.
6375 (dump_generic_node): Call to pretty_print_string with string size.
6376
6377 2018-08-22 Segher Boessenkool <segher@kernel.crashing.org>
6378
6379 PR rtl-optimization/86771
6380 * combine.c (try_combine): Do not allow splitting a resulting PARALLEL
6381 of two SETs into those two SETs, one to be placed at i2, if that SETs
6382 destination is modified between i2 and i3.
6383
6384 2018-08-22 Richard Sandiford <richard.sandiford@arm.com>
6385
6386 PR tree-optimization/86725
6387 * tree-vect-loop.c (vect_inner_phi_in_double_reduction_p): New
6388 function.
6389 (vect_analyze_scalar_cycles_1): Check it.
6390
6391 2018-08-22 Richard Sandiford <richard.sandiford@arm.com>
6392
6393 PR tree-optimization/86725
6394 * tree-vect-loop.c (vect_is_simple_reduction): When treating
6395 an outer loop phi as a double reduction, make sure that the
6396 single user of the phi result is an inner loop phi.
6397
6398 2018-08-22 Richard Sandiford <richard.sandiford@arm.com>
6399
6400 * tree-vect-data-refs.c (vect_analyze_group_access_1): Convert
6401 grouped stores with gaps to a strided group.
6402
6403 2018-08-22 Richard Sandiford <richard.sandiford@arm.com>
6404
6405 * tree-vect-stmts.c (get_group_load_store_type)
6406 (get_load_store_type): Only test STMT_VINFO_STRIDED_P for the
6407 first statement in a group.
6408
6409 2018-08-22 Iain Sandoe <iain@sandoe.co.uk>
6410
6411 * config/darwin.h (LINK_COMMAND_SPEC_A): Sync LTO options with
6412 the sequence used in gcc/gcc.c.
6413
6414 2018-08-22 Iain Sandoe <iain@sandoe.co.uk>
6415
6416 PR other/704
6417 * gcc-ar.c (main): Don’t try to invoke the plug-in if we’re not
6418 building it.
6419
6420 2018-08-22 Iain Sandoe <iain@sandoe.co.uk>
6421
6422 * config/darwin10.h (LINK_GCC_C_SEQUENCE_SPEC): Adjust to use the
6423 Darwin10-specific unwinder-shim.
6424 * config/darwin12.h (LINK_GCC_C_SEQUENCE_SPEC): Remove.
6425 * config/rs6000/darwin.h (DARWIN_CRT1_SPEC, DARWIN_DYLIB1_SPEC):
6426 New to cater for Darwin10 Rosetta.
6427
6428 2018-08-22 Iain Sandoe <iain@sandoe.co.uk>
6429
6430 * config/i386/i386.c (ix86_output_addr_diff_elt): Move the MACH-O
6431 specific test before the one for HAVE_AS_GOTOFF_IN_DATA.
6432
6433 2018-08-22 Iain Sandoe <iain@sandoe.co.uk>
6434
6435 PR bootstrap/81033
6436 PR target/81733
6437 PR target/52795
6438 * gcc/dwarf2out.c (FUNC_SECOND_SECT_LABEL): New.
6439 (dwarf2out_switch_text_section): Generate a local label for the
6440 second function sub-section and apply it as the second FDE start
6441 label.
6442 * gcc/final.c (final_scan_insn_1): Emit second FDE label after the
6443 second sub-section start.
6444
6445 2018-08-22 Richard Biener <rguenther@suse.de>
6446
6447 PR tree-optimization/86988
6448 * tree-vrp.c (vrp_prop::check_mem_ref): Bail out on VLAs.
6449
6450 2018-08-22 Richard Biener <rguenther@suse.de>
6451
6452 PR tree-optimization/86945
6453 * tree-cfg.c (generate_range_test): Use unsigned arithmetic.
6454
6455 2018-08-22 Alexandre Oliva <oliva@adacore.com>
6456
6457 * config/rs6000/rs6000.c (SMALL_DATA_RELOC, SMALL_DATA_REG): Add
6458 a comment about how uses of r2 for .sdata2 come about.
6459
6460 2018-08-22 Alexandre Oliva <aoliva@redhat.com>
6461
6462 * tree-ssa-reassoc.c (is_reassociable_op): Fix cut&pasto.
6463
6464 2018-08-21 Marek Polacek <polacek@redhat.com>
6465
6466 PR c++/86981, Implement -Wpessimizing-move.
6467 * doc/invoke.texi: Document -Wpessimizing-move.
6468
6469 2018-08-21 Jan Hubicka <jh@suse.cz>
6470
6471 * tree.c (find_decls_types_r): Do not check for redundant typedefs.
6472 * tree.h (is_redundant_typedef): Remove.
6473 * dwarf2out.c (is_redundant_typedef): Turn into static function.
6474
6475 2018-08-21 Jan Hubicka <jh@suse.cz>
6476
6477 * tree.c (free_lang_data_in_decl): Remove types from DECL_CONTEXT
6478 when possible.
6479
6480 2018-08-21 Tamar Christina <tamar.christina@arm.com>
6481
6482 * expmed.c (extract_low_bits): Reject invalid subregs early.
6483
6484 2018-08-21 Bernd Edlinger <bernd.edlinger@hotmail.de>
6485
6486 PR middle-end/86121
6487 * tree-ssa-strlen.c (adjust_last_stmt): Avoid folding away undefined
6488 behaviour.
6489
6490 2018-08-21 Rasmus Villemoes <rv@rasmusvillemoes.dk>
6491
6492 * config/vxworks.h: Guard vxworks_asm_out_constructor and
6493 vxworks_asm_out_destructor by !HAVE_INITFINI_ARRAY_SUPPORT
6494 * config/vxworks.c: Likewise.
6495
6496 2018-08-21 Rasmus Villemoes <rv@rasmusvillemoes.dk>
6497
6498 * config/vxworks.c: Set targetm.have_ctors_dtors
6499 if HAVE_INITFINI_ARRAY_SUPPORT.
6500 * config/vxworks.h: Set SUPPORTS_INIT_PRIORITY
6501 if HAVE_INITFINI_ARRAY_SUPPORT.
6502
6503 2018-08-21 Rasmus Villemoes <rv@rasmusvillemoes.dk>
6504
6505 * config/vxworks.h: Add $(WIND_BASE)/target/h/wrn/coreip to
6506 default search path for VxWorks < 7.
6507
6508 2018-08-21 Bernd Edlinger <bernd.edlinger@hotmail.de>
6509
6510 * gimple-ssa-sprintf.c (decl_constant_value): Remove.
6511 (get_format_string): Refer to c_getstr.
6512
6513 2018-08-21 Tom de Vries <tdevries@suse.de>
6514
6515 * cgraph.h (debuginfo_early_init, debuginfo_init, debuginfo_fini)
6516 (debuginfo_start, debuginfo_stop, debuginfo_early_start)
6517 (debuginfo_early_stop): Declare.
6518 * cgraphunit.c (debuginfo_early_init, debuginfo_init, debuginfo_fini)
6519 (debuginfo_start, debuginfo_stop, debuginfo_early_start)
6520 (debuginfo_early_stop): New function.
6521 (symbol_table::finalize_compilation_unit): Call debuginfo_early_start
6522 and debuginfo_early_stop.
6523 * dwarf2out.c (dwarf2out_finish, dwarf2out_early_finish): Dump dwarf.
6524 * toplev.c (compile_file): Call debuginfo_start and debuginfo_stop.
6525 (general_init): Call debuginfo_early_init.
6526 (finalize): Call debuginfo_fini.
6527 (do_compile): Call debuginfo_init.
6528 * doc/invoke.texi (@gccoptlist): Add -fdump-debug and
6529 -fdump-early-debug.
6530 (@item -fdump-debug, @item -fdump-earlydebug): Add.
6531
6532 2018-08-21 Tom de Vries <tdevries@suse.de>
6533
6534 * dwarf2out.c (print_dw_val, print_loc_descr, print_die): Handle
6535 flag_dump_noaddr and flag_dump_unnumbered.
6536
6537 2018-08-21 Aldy Hernandez <aldyh@redhat.com>
6538
6539 * wide-int-range.cc (wide_int_range_abs): New.
6540 (wide_int_range_order_set): Rename from wide_int_range_min_max.
6541 * wide-int-range.h (wide_int_range_abs): New.
6542 (wide_int_range_min_max): New.
6543 * tree-vrp.c (extract_range_from_unary_expr): Rewrite ABS_EXPR
6544 case to call wide_int_range_abs.
6545 Rewrite MIN/MAX_EXPR to call wide_int_range_min_max.
6546 (extract_range_from_abs_expr): Delete.
6547
6548 2018-08-20 Michael Meissner <meissner@linux.ibm.com>
6549
6550 PR target/87033
6551 * config/rs6000/rs6000.md (extendsi<mode>2): Change constraints
6552 from 'Y' to 'YZ' to enable the LWAX instruction to be generated
6553 for indexed loads.
6554
6555 2018-08-20 Nathan Sidwell <nathan@acm.org>
6556 Jeff Law <law@redhat.com>
6557
6558 * config/s390/s390-c (s390_macro_to_expand): Use cpp_macro_p.
6559 * config/spu/spu-c.c (spu_macro_to_expand): Likewise.
6560
6561 2018-08-20 David Malcolm <dmalcolm@redhat.com>
6562
6563 PR other/84889
6564 * attribs.c (diag_attr_exclusions): Add auto_diagnostic_group instance.
6565 (decl_attributes): Likewise.
6566 * calls.c (maybe_warn_nonstring_arg): Add auto_diagnostic_group
6567 instance.
6568 * cgraphunit.c (maybe_diag_incompatible_alias): Likewise.
6569 * diagnostic-core.h (class auto_diagnostic_group): New class.
6570 * diagnostic.c (diagnostic_initialize): Initialize the new fields.
6571 (diagnostic_report_diagnostic): Handle the first diagnostics within
6572 a group.
6573 (emit_diagnostic): Add auto_diagnostic_group instance.
6574 (inform): Likewise.
6575 (inform_n): Likewise.
6576 (warning): Likewise.
6577 (warning_at): Likewise.
6578 (warning_n): Likewise.
6579 (pedwarn): Likewise.
6580 (permerror): Likewise.
6581 (error): Likewise.
6582 (error_n): Likewise.
6583 (error_at): Likewise.
6584 (sorry): Likewise.
6585 (fatal_error): Likewise.
6586 (internal_error): Likewise.
6587 (internal_error_no_backtrace): Likewise.
6588 (auto_diagnostic_group::auto_diagnostic_group): New ctor.
6589 (auto_diagnostic_group::~auto_diagnostic_group): New dtor.
6590 * diagnostic.h (struct diagnostic_context): Add fields
6591 "diagnostic_group_nesting_depth",
6592 "diagnostic_group_emission_count", "begin_group_cb",
6593 "end_group_cb".
6594 * gimple-ssa-isolate-paths.c (find_implicit_erroneous_behavior):
6595 Add auto_diagnostic_group instance(s).
6596 (find_explicit_erroneous_behavior): Likewise.
6597 * gimple-ssa-warn-alloca.c (pass_walloca::execute): Likewise.
6598 * gimple-ssa-warn-restrict.c (maybe_diag_offset_bounds): Likewise.
6599 * gimplify.c (warn_implicit_fallthrough_r): Likewise.
6600 (gimplify_va_arg_expr): Likewise.
6601 * hsa-gen.c (HSA_SORRY_ATV): Likewise.
6602 (HSA_SORRY_AT): Likewise.
6603 * ipa-devirt.c (compare_virtual_tables): Likewise.
6604 (warn_odr): Likewise.
6605 * multiple_target.c (expand_target_clones): Likewise.
6606 * opts-common.c (cmdline_handle_error): Likewise.
6607 * reginfo.c (globalize_reg): Likewise.
6608 * substring-locations.c (format_warning_n_va): Likewise.
6609 * tree-inline.c (expand_call_inline): Likewise.
6610 * tree-ssa-ccp.c (pass_post_ipa_warn::execute): Likewise.
6611 * tree-ssa-loop-niter.c
6612 (do_warn_aggressive_loop_optimizations): Likewise.
6613 * tree-ssa-uninit.c (warn_uninit): Likewise.
6614 * tree.c (warn_deprecated_use): Likewise.
6615
6616 2018-08-20 H.J. Lu <hongjiu.lu@intel.com>
6617
6618 PR target/87014
6619 * config/i386/i386.md (eh_return): Always update EH return
6620 address in word_mode.
6621
6622 2018-08-20 Chung-Lin Tang <cltang@codesourcery.com>
6623
6624 * targhooks.c (std_gimplify_va_arg_expr): Properly handle case of when
6625 TARGET_SPLIT_COMPLEX_ARG is defined.
6626
6627 2018-08-20 Bernd Edlinger <bernd.edlinger@hotmail.de>
6628
6629 * expr.c (store_field): Change gcc_assert to gcc_checking_assert.
6630
6631 2018-08-20 Bernd Edlinger <bernd.edlinger@hotmail.de>
6632
6633 PR target/86984
6634 * expr.c (expand_assignment): Assert that bitpos is positive.
6635 (store_field): Likewise
6636 (expand_expr_real_1): Make sure that bitpos is positive.
6637 * config/alpha/alpha.h (CONSTANT_ADDRESS_P): Avoid signed
6638 integer overflow.
6639
6640 2018-08-20 Nathan Sidwell <nathan@acm.org>
6641
6642 * Makefile.in (CPP_ID_DATA_H): Delete.
6643 (CPP_INTERNAL_H): Don't add it.
6644 (GTFILES): Replace CPP_ID_DATA_H with CPPLIB_H.
6645 * gengtype.c (open_base_files): Replace cpp-id-data.h with cpplib.h
6646
6647 2018-08-20 Richard Biener <rguenther@suse.de>
6648
6649 PR tree-optimization/78655
6650 * tree-vrp.c (extract_range_from_binary_expr_1): Make
6651 pointer + offset nonnull if either operand is nonnull work.
6652
6653 2018-08-20 Tom de Vries <tdevries@suse.de>
6654
6655 * dwarf2out.c (add_scalar_info): Don't add reference to existing die
6656 unless the referenced die describes the added property using
6657 DW_AT_location or DW_AT_const_value. Fall back to exprloc case.
6658 Otherwise, add a DW_AT_location to the referenced die.
6659
6660 2018-08-19 Uros Bizjak <ubizjak@gmail.com>
6661
6662 PR target/86994
6663 * config/i386/i386.c (ix86_rtx_costs) [case SET]: Check source for
6664 register_operand when calling ix86_set_reg_reg_cost.
6665 [case CONST_INT, case CONST, case LABEL_REF, case SYMBOL_REF]:
6666 Set *total to 0 for operands that satisfy x86_64_immediate_operand
6667 predicate and to 1 otherwise.
6668
6669 2018-08-18 Iain Sandoe <iain@sandoe.co.uk>
6670
6671 * config/darwin.c (darwin_override_options): If -gsplit-dwarf is set,
6672 emit a diagnostic that it is not supported and reset the option.
6673 * config/darwin.h (DRIVER_SELF_SPECS): Note that gsplit-dwarf is not
6674 supported and consume the option. (ASM_FINAL_SPEC): New.
6675
6676 2018-08-17 Segher Boessenkool <segher@kernel.crashing.org>
6677
6678 * doc/md.texi (Patterns): Use @ref instead of @xref in the middle of
6679 a sentence.
6680
6681 2018-08-17 Sandra Loosemore <sandra@codesourcery.com>
6682
6683 C-SKY port: Documentation
6684
6685 * doc/extend.texi (C-SKY Function Attributes): New section.
6686 * doc/invoke.texi (Option Summary): Add C-SKY options.
6687 (C-SKY Options): New section.
6688 * doc/md.texi (Machine Constraints): Document C-SKY constraints.
6689
6690 2018-08-17 Jojo <jijie_rong@c-sky.com>
6691 Huibin Wang <huibin_wang@c-sky.com>
6692 Sandra Loosemore <sandra@codesourcery.com>
6693 Chung-Lin Tang <cltang@codesourcery.com>
6694
6695 C-SKY port: Backend implementation
6696
6697 * config/csky/*: New.
6698 * common/config/csky/*: New.
6699
6700 2018-08-17 Jojo <jijie_rong@c-sky.com>
6701 Huibin Wang <huibin_wang@c-sky.com>
6702 Sandra Loosemore <sandra@codesourcery.com>
6703 Chung-Lin Tang <cltang@codesourcery.com>
6704 Andrew Jenner <andrew@codesourcery.com>
6705
6706 C-SKY port: Configury
6707
6708 * config.gcc (csky-*-*): New.
6709 * configure.ac: Add csky to targets for dwarf2 debug_line support.
6710 * configure: Regenerated.
6711
6712 2018-08-17 David Malcolm <dmalcolm@redhat.com>
6713
6714 * dump-context.h: Include "dumpfile.h".
6715 (dump_context::dump_printf_va): Convert final param from va_list
6716 to va_list *. Convert from ATTRIBUTE_PRINTF to
6717 ATTRIBUTE_GCC_DUMP_PRINTF.
6718 (dump_context::dump_printf_loc_va): Likewise.
6719 * dumpfile.c: Include "stringpool.h".
6720 (make_item_for_dump_printf_va): Delete.
6721 (make_item_for_dump_printf): Delete.
6722 (class dump_pretty_printer): New class.
6723 (dump_pretty_printer::dump_pretty_printer): New ctor.
6724 (dump_pretty_printer::emit_items): New member function.
6725 (dump_pretty_printer::emit_any_pending_textual_chunks): New member
6726 function.
6727 (dump_pretty_printer::emit_item): New member function.
6728 (dump_pretty_printer::stash_item): New member function.
6729 (dump_pretty_printer::format_decoder_cb): New member function.
6730 (dump_pretty_printer::decode_format): New member function.
6731 (dump_context::dump_printf_va): Reimplement in terms of
6732 dump_pretty_printer.
6733 (dump_context::dump_printf_loc_va): Convert final param from va_list
6734 to va_list *.
6735 (dump_context::begin_scope): Reimplement call to
6736 make_item_for_dump_printf.
6737 (dump_printf): Update for change to dump_printf_va.
6738 (dump_printf_loc): Likewise.
6739 (selftest::test_capture_of_dump_calls): Convert "stmt" from
6740 greturn * to gimple *. Add a test_decl. Add tests of dump_printf
6741 with %T, %E, and %G.
6742 * dumpfile.h (ATTRIBUTE_GCC_DUMP_PRINTF): New macro.
6743 (dump_printf): Replace ATTRIBUTE_PRINTF_2 with
6744 ATTRIBUTE_GCC_DUMP_PRINTF (2, 3).
6745 (dump_printf_loc): Replace ATTRIBUTE_PRINTF_3 with
6746 ATTRIBUTE_GCC_DUMP_PRINTF (3, 0).
6747 * tree-vect-data-refs.c (vect_lanes_optab_supported_p): Convert
6748 use of HOST_WIDE_INT_PRINT_DEC on unsigned HOST_WIDE_INT "count"
6749 within a dump_printf_loc call to "%wu".
6750 (vector_alignment_reachable_p): Merge two dump_printf[_loc] calls,
6751 converting a use of HOST_WIDE_INT_PRINT_DEC to "%wd". Add a
6752 missing space after "=".
6753 * tree-vect-loop.c (vect_analyze_loop_2) Within a dump_printf
6754 call, convert use of HOST_WIDE_INT_PRINT_DEC to "%wd".
6755 * tree-vect-slp.c (vect_slp_bb): Within a dump_printf_loc call,
6756 convert use of HOST_WIDE_INT_PRINT_UNSIGNED to "%wu".
6757 * tree-vectorizer.c (try_vectorize_loop_1): Likewise. Remove
6758 duplicate "vectorized" from message.
6759
6760 2018-08-17 Szabolcs Nagy <szabolcs.nagy@arm.com>
6761
6762 * config/arm/arm-builtins.c (arm_init_simd_builtin_types): Clear
6763 polyNxK_t element's TYPE_STRING_FLAG.
6764
6765 2018-08-17 Segher Boessenkool <segher@kernel.crashing.org>
6766
6767 * config/rs6000/rs6000.md (*cbranch, *creturn): Name these patterns
6768 (they were unnamed before). Fix comments.
6769
6770 2018-08-17 Nathan Sidwell <nathan@acm.org>
6771
6772 * cppbuiltin.c: Include "cpplib.h", not "cpp-id-data.h".
6773
6774 2018-08-17 Richard Biener <rguenther@suse.de>
6775
6776 PR tree-optimization/86841
6777 * wide-int-range.cc (wide_int_range_lshift): Use to_uhwi.
6778
6779 2018-08-17 Martin Liska <mliska@suse.cz>
6780
6781 * common.opt: Remove Warn, Init and Report for options with
6782 Ignore/Deprecated flag. Warning is done automatically for
6783 Deprecated flags.
6784 * config/i386/i386.opt: Likewise.
6785 * config/ia64/ia64.opt: Likewise.
6786 * config/rs6000/rs6000.opt: Likewise.
6787 * cppbuiltin.c (define_builtin_macros_for_compilation_flags):
6788 Remove usage of flag_check_pointer_bounds.
6789 * lto-wrapper.c (merge_and_complain): Do not handle
6790 OPT_fcheck_pointer_bounds.
6791 (append_compiler_options): Likewise.
6792 * opt-functions.awk: Do not handle Deprecated.
6793 * optc-gen.awk: Check that Var, Report and Init are not
6794 used for an option with Ignore/Deprecated flag.
6795 * opts-common.c (decode_cmdline_option): Do not report
6796 CL_ERR_DEPRECATED.
6797 (read_cmdline_option): Report warning for OPT_SPECIAL_deprecated
6798 options.
6799 * opts.h (struct cl_option): Remove cl_deprecated flag.
6800 (CL_ERR_DEPRECATED): Remove error enum value.
6801
6802 2018-08-17 Richard Biener <rguenther@suse.de>
6803
6804 PR middle-end/86505
6805 * tree-inline.c (copy_bb): When inlining __builtin_va_arg_pack_len ()
6806 across a va-arg-pack using call adjust its return value accordingly.
6807
6808 2018-08-16 Martin Sebor <msebor@redhat.com>
6809
6810 PR tree-optimization/86853
6811 * gimple-ssa-sprintf.c (struct format_result): Rename member.
6812 (struct fmtresult): Add member and initialize it in ctors.
6813 (format_character): Handle %C. Extend range to NUL. Set MAYFAIL.
6814 (format_string): Handle %S the same as %ls. Set MAYFAIL.
6815 (format_directive): Set POSUNDER4K when MAYFAIL is set.
6816 (parse_directive): Handle %C same as %c.
6817 (sprintf_dom_walker::compute_format_length): Adjust.
6818 (is_call_safe): Adjust.
6819
6820 2018-08-16 Bernd Edlinger <bernd.edlinger@hotmail.de>
6821
6822 * builtins.c (c_strlen): Add new parameter eltsize. Use it
6823 for determining how to count the elements.
6824 * builtins.h (c_strlen): Adjust prototype.
6825 * expr.c (string_constant): Add new parameter mem_size.
6826 Set *mem_size appropriately.
6827 * expr.h (string_constant): Adjust protoype.
6828 * gimple-fold.c (get_range_strlen): Add new parameter eltsize.
6829 * gimple-fold.h (get_range_strlen): Adjust prototype.
6830 * gimple-ssa-sprintf.c (get_string_length): Add new parameter eltsize.
6831 (format_string): Call get_string_length with eltsize.
6832
6833 2018-08-16 David Malcolm <dmalcolm@redhat.com>
6834
6835 * diagnostic.c (default_diagnostic_start_span_fn): Call pp_string
6836 to emit the span, rather than setting it as the prefix.
6837
6838 2018-08-16 David Malcolm <dmalcolm@redhat.com>
6839
6840 * diagnostic-show-locus.c (layout::start_annotation_line): Add
6841 "margin_char" parameter, defaulting to space. Use it in place
6842 of pp_space for the initial part of the margin.
6843 (layout::print_leading_fixits): Use '+' when filling the margin
6844 of line-insertion fix-it hints.
6845
6846 2018-08-16 Segher Boessenkool <segher@kernel.crashing.org>
6847
6848 * config/rs6000/rs6000.md (two unnamed define_insn and define_split):
6849 Delete.
6850
6851 2018-08-16 Segher Boessenkool <segher@kernel.crashing.org>
6852
6853 * config/rs6000/altivec.md: Don't set length attribute to the default
6854 value.
6855 * config/rs6000/darwin.md: Ditto.
6856 * config/rs6000/dfp.md: Ditto.
6857 * config/rs6000/htm.md: Ditto.
6858 * config/rs6000/rs6000.md: Ditto.
6859 * config/rs6000/sync.md: Ditto.
6860 * config/rs6000/vsx.md: Ditto.
6861
6862 2018-08-16 Segher Boessenkool <segher@kernel.crashing.org>
6863
6864 * config/rs6000/altivec.md: Don't set length attribute to the default
6865 value, for branch instructions.
6866 * config/rs6000/darwin.md: Ditto.
6867 * config/rs6000/rs6000.md: Ditto.
6868
6869 2018-08-16 Segher Boessenkool <segher@kernel.crashing.org>
6870
6871 * config/rs6000/rs6000.md (length): Always define as const_int 4.
6872 (unnamed conditional branch define_insn): Set length to 4 or 8
6873 depending on offset.
6874 (<bd>_<mode>): Similar, for alternative 0.
6875 (<bd>tf_<mode>): Ditto.
6876
6877 2018-08-16 Tamar Christina <tamar.christina@arm.com>
6878
6879 * expr.c (copy_blkmode_to_reg): Perform larger copies when safe.
6880
6881 2018-08-16 Matthew Malcomson <matthew.malcomson@arm.com>
6882
6883 * doc/rtl.texi: Replace old RTX class names with new names.
6884
6885
6886 2018-08-16 Vlad Lazar <vlad.lazar@arm.com>
6887
6888 * expmed.h (canonicalize_comparison): New declaration.
6889 * expmed.c (canonicalize_comparison, equivalent_cmp_code): New function.
6890 * expmed.c (emit_store_flag_1): Add call to canonicalize_comparison.
6891 * optabs.c (prepare_cmp_insn): Likewise.
6892 * rtl.h (unsigned_condition_p): New function which checks if a
6893 comparison operator is unsigned.
6894
6895 2018-08-16 Nathan Sidwell <nathan@acm.org>
6896
6897 * config/rs6000/rs6000-c.c (rs6000_macro_to_expend): Use cpp_macro_p.
6898 * config/powerpcspc/powerpcspe-c.c (rs6000_macro_to_expend): Likewise.
6899
6900 2018-08-16 Tamar Christina <tamar.christina@arm.com>
6901
6902 PR target/84711
6903 * config/arm/arm.c (arm_can_change_mode_class): Disallow subreg.
6904 * config/arm/neon.md (movv4hf, movv8hf): Refactored to..
6905 (mov<mov>): ..this and enable unconditionally.
6906
6907 2018-08-16 Tamar Christina <tamar.christina@arm.com>
6908
6909 * config/arm/neon.md (*neon_mov<mode>): Remove reg-to-reg alternative.
6910
6911 2018-08-16 Sam Tebbs <sam.tebbs@arm.com>
6912
6913 * config/aarch64/aarch64.opt (mlow-precision-recip-sqrt)
6914 (mlow-precision-sqrt, mlow-precision-div, mverbose-cost-dump): Replace
6915 "Common" with "Target".
6916
6917 2018-08-15 Uros Bizjak <ubizjak@gmail.com>
6918
6919 * config/i386/i386.opt (mmitigate-rop): Mark as deprecated.
6920 * doc/invoke.texi (mmitigate-rop): Remove.
6921 * config/i386/i386.c: Do not include "regrename.h".
6922 (ix86_rop_should_change_byte_p, reg_encoded_number)
6923 (ix86_get_modrm_for_rop, set_rop_modrm_reg_bits, ix86_mitigate_rop):
6924 Remove.
6925 (ix86_reorg): Remove call to ix86_mitigate_rop.
6926 * config/i386/i386.md (attr "modrm_class"): Remove.
6927 (cmp<mode>_ccno_1, mov<mode>_xor, movstrict<mode>_xor)
6928 (x86_mov<mode>cc_0_m1. x86_mov<mode>cc_0_m1_se)
6929 (x86_mov<mode>cc_0_m1_neg): Remove modrm_class attribute override.
6930
6931 2018-08-15 Will Schmidt <will_schmidt@vnet.ibm.com>
6932
6933 * config/rs6000/rs600.c (rs6000_gimple_fold_builtin): Add entries to
6934 allow folding of mergeh() and mergel() for the float and double types.
6935 (fold_mergehl_helper): Rework to handle building a permute tree
6936 for float vectors.
6937
6938 2018-08-15 Uros Bizjak <ubizjak@gmail.com>
6939
6940 * config/i386/i386.c (expand_vec_perm_movs): Enable V4SFmode
6941 for TARGET_SSE.
6942
6943 2018-08-15 David Malcolm <dmalcolm@redhat.com>
6944
6945 * common.opt (fdiagnostics-show-labels): New option.
6946 * diagnostic-show-locus.c (class layout_range): Add field
6947 "m_label".
6948 (class layout): Add field "m_show_labels_p".
6949 (layout_range::layout_range): Add param "label" and use it to
6950 initialize m_label.
6951 (make_range): Pass in NULL for new "label" param of layout_range's
6952 ctor.
6953 (layout::layout): Initialize m_show_labels_p.
6954 (layout::maybe_add_location_range): Pass in loc_range->m_label
6955 when constructing layout_range instances.
6956 (struct line_label): New struct.
6957 (layout::print_any_labels): New member function.
6958 (layout::print_line): Call it if label-printing is enabled.
6959 (selftest::test_one_liner_labels): New test.
6960 (selftest::test_diagnostic_show_locus_one_liner): Call it.
6961 * diagnostic.c (diagnostic_initialize): Initialize
6962 context->show_labels_p.
6963 * diagnostic.h (struct diagnostic_context): Add field
6964 "show_labels_p".
6965 * doc/invoke.texi (Diagnostic Message Formatting Options): Add
6966 -fno-diagnostics-show-labels.
6967 * dwarf2out.c (gen_producer_string): Add
6968 OPT_fdiagnostics_show_labels to the ignored options.
6969 * gcc-rich-location.c (gcc_rich_location::add_expr): Add "label"
6970 param.
6971 (gcc_rich_location::maybe_add_expr): Likewise.
6972 * gcc-rich-location.h (gcc_rich_location::gcc_rich_location): Add
6973 label" param, defaulting to NULL.
6974 (gcc_rich_location::add_expr): Add "label" param.
6975 (gcc_rich_location::maybe_add_expr): Likewise.
6976 (class text_range_label): New class.
6977 (class range_label_for_type_mismatch): New class.
6978 * gimple-ssa-sprintf.c (fmtwarn): Pass NULL for new label params
6979 of format_warning_va.
6980 (fmtwarn_n): Likewise for new params of format_warning_n_va.
6981 * lto-wrapper.c (merge_and_complain): Add
6982 OPT_fdiagnostics_show_labels to the "pick one setting" options.
6983 (append_compiler_options): Likewise to the dropped options.
6984 (append_diag_options): Likewise to the passed-on options.
6985 * opts.c (common_handle_option): Handle the new option.
6986 * selftest-diagnostic.c
6987 (test_diagnostic_context::test_diagnostic_context): Enable
6988 show_labels_p.
6989 * substring-locations.c: Include "gcc-rich-location.h".
6990 (format_warning_n_va): Add "fmt_label" and "param_label" params
6991 and use them as appropriate.
6992 (format_warning_va): Add "fmt_label" and "param_label" params,
6993 passing them on to format_warning_n_va.
6994 (format_warning_at_substring): Likewise.
6995 (format_warning_at_substring_n): Likewise.
6996 * substring-locations.h (format_warning_va): Add "fmt_label" and
6997 "param_label" params.
6998 (format_warning_n_va): Likewise.
6999 (format_warning_at_substring): Likewise.
7000 (format_warning_at_substring_n): Likewise.
7001 * toplev.c (general_init): Initialize global_dc->show_labels_p.
7002
7003 2018-08-15 Qing Zhao <qing.zhao@oracle.com>
7004
7005 PR testsuite/86519
7006 * builtins.c (expand_builtin_memcmp): Do not expand the call
7007 when overflow is detected.
7008
7009 2018-08-15 Martin Sebor <msebor@redhat.com>
7010
7011 PR tree-optimization/71625
7012 * config/aarch64/aarch64-builtins.c
7013 (aarch64_init_simd_builtin_types): Clear Poly8_t's TYPE_STRING_FLAG.
7014
7015 2018-08-15 Ilya Leoshkevich <iii@linux.ibm.com>
7016
7017 * config/s390/s390.c (s390_reorg): Remove loop.
7018
7019 2018-08-15 Iain Sandoe <iain@sandoe.co.uk>
7020
7021 * config/darwin.c
7022 (darwin_function_switched_text_sections): Delete.
7023 * gcc/config/darwin.h
7024 (TARGET_ASM_FUNCTION_SWITCHED_TEXT_SECTIONS): Likewise.
7025
7026 2018-08-15 Iain Sandoe <iain@sandoe.co.uk>
7027
7028 PR target/81685
7029 * config/darwin.h: (DEBUG_STR_OFFSETS_SECTION, DEBUG_LOCLISTS_SECTION,
7030 DEBUG_RNGLISTS_SECTION) new macros. (DEBUG_PUBNAMES_SECTION,
7031 DEBUG_PUBTYPES_SECTION) update to include GNU variant.
7032
7033 2018-08-15 Martin Liska <mliska@suse.cz>
7034
7035 PR tree-optimization/86925
7036 * predict.c (expr_expected_value_1): When taking
7037 later predictor, assign also probability.
7038 Use fold_build2_initializer_loc in order to fold
7039 the expression in -frounding-math.
7040
7041 2018-08-14 Allan Sandfeld Jensen <allan.jensen@qt.io>
7042
7043 * config/i386/i386.c (expand_vec_perm_movs): New method matching movs
7044 patterns.
7045 (expand_vec_perm_1): Try the new method.
7046
7047 2018-08-14 Ilya Leoshkevich <iii@linux.ibm.com>
7048
7049 PR target/86547
7050 * lra-lives.c (remove_some_program_points_and_update_live_ranges):
7051 Check whether lra_live_max_point is 0 before dividing.
7052
7053 2018-08-14 Martin Sebor <msebor@redhat.com>
7054
7055 PR tree-optimization/86650
7056 * tree-vrp.c (vrp_prop::check_array_ref): Print an inform message.
7057 (vrp_prop::check_mem_ref): Same.
7058
7059 2018-08-13 Liu Hao <lh_mouse@126.com>
7060
7061 * pretty-print.c (eat_esc_sequence): Swap the foreground and
7062 background colors if the COMMON_LVB_REVERSE_VIDEO flag is set,
7063 and clear it thereafter, as it only works for DBCS.
7064
7065 2018-08-13 Liu Hao <lh_mouse@126.com>
7066
7067 * pretty-print.c (mingw_ansi_fputs): Do not call _close() on the
7068 handle returned by _get_osf_handle().
7069
7070 2018-08-13 Will Schmidt <will_schmidt@vnet.ibm.com>
7071
7072 * gcc/config/rs6000/rs6000.c (rs6000_gimple_fold_builtin): Add support
7073 for folding vec_perm.
7074
7075 2018-08-13 Will Schmidt <will_schmidt@vnet.ibm.com>
7076
7077 * config/rs6000/rs6000.c (rs6000_gimple_fold_builtin):
7078 Add support for gimple-folding of vec_pack() and vec_unpack()
7079 intrinsics.
7080
7081 2018-08-13 Will Schmidt <will_schmidt@vnet.ibm.com>
7082
7083 * config/rs6000/rs6000.c (rs6000_builtin_valid_without_lhs): Add
7084 vec_xst variants to the list.
7085 (rs6000_gimple_fold_builtin): Add support for folding unaligned
7086 vector loads and stores.
7087
7088 2018-08-13 David Edelsohn <dje.gcc@gmail.com>
7089
7090 * config.gcc (rs6000-ibm-aix4.x): Delete.
7091 (rs6000-ibm-aix5.1): Delete.
7092 (rs6000-ibm-aix5.2): Delete.
7093 (rs6000-ibm-aix5.3): Delete.
7094 * config/rs6000/aix43.h: Delete.
7095 * config/rs6000/aix51.h: Delete.
7096 * config/rs6000/aix52.h: Delete.
7097 * config/rs6000/t-aix43: Delete.
7098
7099 2018-08-13 Ilya Leoshkevich <iii@linux.ibm.com>
7100
7101 * config/s390/s390.c (s390_decompose_constant_pool_ref):
7102 New function.
7103 (s390_decompose_address): Factor out constant pool ref
7104 decomposition.
7105
7106 2018-08-12 Chung-Ju Wu <jasonwucj@gmail.com>
7107
7108 * config/nds32/nds32-predicates.c
7109 (nds32_can_use_bclr_p): Change return type as bool.
7110 (nds32_can_use_bset_p): Ditto.
7111 (nds32_can_use_btgl_p): Ditto.
7112 (nds32_can_use_bitci_p): Ditto.
7113 * config/nds32/nds32-protos.h
7114 (nds32_can_use_bclr_p): Change declaration.
7115 (nds32_can_use_bset_p): Ditto.
7116 (nds32_can_use_btgl_p): Ditto.
7117 (nds32_can_use_bitci_p): Ditto.
7118
7119 2018-08-12 Chung-Ju Wu <jasonwucj@gmail.com>
7120
7121 * config/nds32/nds32.c (nds32_expand_prologue, nds32_expand_epilogue):
7122 Support -msched-prolog-epilog option.
7123 * config/nds32/nds32.opt (msched-prolog-epilog): New option.
7124
7125 2018-08-12 Chung-Ju Wu <jasonwucj@gmail.com>
7126
7127 * common/config/nds32/nds32-common.c
7128 (nds32_option_optimization_table): Enalbe -malways-align.
7129
7130 2018-08-12 Chung-Ju Wu <jasonwucj@gmail.com>
7131
7132 * config.gcc (nds32*): Add nds32_isr.h and nds32_init.inc in
7133 extra_headers.
7134 * common/config/nds32/nds32-common.c (nds32_handle_option): Handle
7135 OPT_misr_secure_ case.
7136 * config/nds32/nds32-isr.c: Implementation of backward compatibility.
7137 * config/nds32/nds32-protos.h (nds32_isr_function_critical_p): New.
7138 * config/nds32/nds32.c (nds32_attribute_table): Add critical and
7139 secure attribute.
7140 * config/nds32/nds32.h (nds32_isr_nested_type): Add NDS32_CRITICAL.
7141 (nds32_isr_info): New field security_level.
7142 (TARGET_ISR_VECTOR_SIZE_4_BYTE): New macro.
7143 * config/nds32/nds32.md (return_internal): Consider critical attribute.
7144 * config/nds32/nds32.opt (misr-secure): New option.
7145 * config/nds32/nds32_init.inc: New file.
7146 * config/nds32/nds32_isr.h: New file.
7147
7148 2018-08-11 John David Anglin <danglin@gcc.gnu.org>
7149
7150 * config/pa/pa.md (UNSPEC_MEMORY_BARRIER): New unspec enum.
7151 Update comment for atomic instructions.
7152 (atomic_storeqi, atomic_storehi, atomic_storesi, atomic_storesf,
7153 atomic_loaddf, atomic_loaddf_1, atomic_storedf, atomic_storedf_1):
7154 Remove.
7155 (atomic_loaddi): Revise fence expansion to only emit fence prior to
7156 load for __ATOMIC_SEQ_CST model.
7157 (atomic_loaddi_1): Remove float register target.
7158 (atomic_storedi): Handle CONST_INT values.
7159 (atomic_storedi_1): Remove float register source. Add special case
7160 for zero value.
7161 (memory_barrier): New expander and insn.
7162
7163 2018-08-11 Jakub Jelinek <jakub@redhat.com>
7164
7165 PR tree-optimization/86835
7166 * tree-ssa-math-opts.c (insert_reciprocals): Even when inserting
7167 new_stmt after def_gsi, make sure to insert new_square_stmt after
7168 that stmt, not 2 stmts before it.
7169
7170 2018-08-10 Alexander Monakov <amonakov@ispras.ru>
7171
7172 PR target/82418
7173 * config/i386/i386.md (<s>mul<mode>3_highpart): Use DWIH mode iterator
7174 instead of SWI48.
7175
7176 2018-08-10 Martin Liska <mliska@suse.cz>
7177
7178 PR target/83610
7179 * builtin-types.def (BT_FN_LONG_LONG_LONG_DOUBLE): Add new
7180 function type.
7181 * builtins.c (expand_builtin_expect_with_probability):
7182 New function.
7183 (expand_builtin_expect_with_probability): New function.
7184 (build_builtin_expect_predicate): Add new argumnet probability
7185 for BUILT_IN_EXPECT_WITH_PROBABILITY.
7186 (fold_builtin_expect):
7187 (fold_builtin_2):
7188 (fold_builtin_3):
7189 * builtins.def (BUILT_IN_EXPECT_WITH_PROBABILITY):
7190 * builtins.h (fold_builtin_expect): Set new argument.
7191 * doc/extend.texi: Document __builtin_expect_with_probability.
7192 * doc/invoke.texi: Likewise.
7193 * gimple-fold.c (gimple_fold_call): Pass new argument.
7194 * ipa-fnsummary.c (find_foldable_builtin_expect): Handle
7195 also BUILT_IN_EXPECT_WITH_PROBABILITY.
7196 * predict.c (get_predictor_value): New function.
7197 (expr_expected_value): Add new argument probability. Assume
7198 that predictor and probability are always non-null.
7199 (expr_expected_value_1): Likewise. For __builtin_expect and
7200 __builtin_expect_with_probability set probability. Handle
7201 combination in binary expressions.
7202 (tree_predict_by_opcode): Simplify code by simply calling
7203 get_predictor_value.
7204 (pass_strip_predict_hints::execute): Add handling of
7205 BUILT_IN_EXPECT_WITH_PROBABILITY.
7206 * predict.def (PRED_BUILTIN_EXPECT_WITH_PROBABILITY): Add
7207 new predictor.
7208 * tree.h (DECL_BUILT_IN_P): New function.
7209
7210 2018-08-10 Martin Liska <mliska@suse.cz>
7211
7212 PR tree-optimization/85799
7213 * passes.def: Add argument for pass_strip_predict_hints.
7214 * predict.c (class pass_strip_predict_hints): Add new argument
7215 early_p.
7216 (strip_predictor_early): New function.
7217 (pass_strip_predict_hints::execute): Call the function to
7218 strip predictors.
7219 (strip_predict_hints): New function.
7220 * predict.def: Fix comment.
7221
7222 2018-08-10 Thomas Preud'homme <thomas.preudhomme@linaro.org>
7223
7224 * Makefile.in: Clarify which tm.texi to copy over to assert the
7225 right to grant a GFDL license for all.
7226
7227 2018-08-09 Jeff Law <law@redhat.com>
7228
7229 * config/m68k/m68k.c (m68k_adjust_decorated_operand): Remove
7230 unused variable.
7231
7232 2018-08-09 Andreas Schwab <schwab@linux-m68k.org>
7233
7234 * config/m68k/m68k-protos.h (m68k_final_prescan_insn): Remove
7235 prototype.
7236
7237 2018-08-09 Richard Sandiford <richard.sandiford@arm.com>
7238
7239 * tree-vect-loop.c (vectorizable_reduction): Allow inner-loop
7240 reductions for variable-length vectors.
7241
7242 2018-08-09 David Malcolm <dmalcolm@redhat.com>
7243
7244 PR other/84889
7245 * common.opt (fdiagnostics-show-line-numbers): New option.
7246 * diagnostic-show-locus.c (class layout): Add fields
7247 "m_show_line_numbers_p" and "m_linenum_width";
7248 (num_digits): New function.
7249 (test_num_digits): New function.
7250 (layout::layout): Initialize new fields. Update m_x_offset
7251 logic to handle any left margin.
7252 (layout::print_source_line): Print line number when requested.
7253 (layout::start_annotation_line): New member function.
7254 (layout::print_annotation_line): Call it.
7255 (layout::print_leading_fixits): Likewise.
7256 (layout::print_trailing_fixits): Likewise. Update calls to
7257 move_to_column for new parameter.
7258 (layout::get_x_bound_for_row): Add "add_left_margin" param and use
7259 it to potentially call start_annotation_line.
7260 (layout::show_ruler): Call start_annotation_line.
7261 (selftest::test_line_numbers_multiline_range): New selftest.
7262 (selftest::diagnostic_show_locus_c_tests): Call test_num_digits
7263 and selftest::test_line_numbers_multiline_range.
7264 * diagnostic.c (diagnostic_initialize): Initialize
7265 show_line_numbers_p.
7266 * diagnostic.h (struct diagnostic_context): Add field
7267 "show_line_numbers_p".
7268 * doc/invoke.texi (Diagnostic Message Formatting Options): Add
7269 -fno-diagnostics-show-line-numbers.
7270 * dwarf2out.c (gen_producer_string): Add
7271 OPT_fdiagnostics_show_line_numbers to the ignored options.
7272 * lto-wrapper.c (merge_and_complain): Likewise to the "pick
7273 one setting" options.
7274 (append_compiler_options): Likewise to the dropped options.
7275 (append_diag_options): Likewise to the passed-on options.
7276 * opts.c (common_handle_option): Handle the new option.
7277 * toplev.c (general_init): Set up global_dc->show_line_numbers_p.
7278
7279 2018-08-09 Kelvin Nilsen <kelvin@gcc.gnu.org>
7280
7281 * doc/extend.texi (PowerPC AltiVec Built-in Functions Available on
7282 ISA 2.07): Correct spelling of bcdsub to be __builtin_bcdsub. Add
7283 third argument of type "const signed char" to descriptions of
7284 __builtin_bcdadd, __builtin_bcdadd_lt, __builtin_bcdadd_eq,
7285 __builtin_bcdadd_gt, __builtin_bcdadd_ov, __builtin_bcdsub,
7286 __builtin_bcdsub_lt, __builtin_bcdsub_eq, __builtin_bcdsub_gt,
7287 __builtin_bcdsub_ov functions.
7288
7289 2018-08-09 Richard Sandiford <richard.sandiford@arm.com>
7290
7291 PR tree-optimization/86858
7292 * tree-vect-loop.c (vect_is_simple_reduction): Restore
7293 flow_bb_inside_loop_p calls.
7294
7295 2018-08-09 Richard Sandiford <richard.sandiford@arm.com>
7296
7297 PR tree-optimization/86871
7298 * tree-vect-stmts.c (vect_transform_stmt): Use gimple_get_lhs
7299 instead of gimple_assign_lhs.
7300
7301 2018-08-09 Richard Earnshaw <rearnsha@arm.com>
7302
7303 PR target/86887
7304 * config/aarch64/aarch64.md (add<mode>3_carryinC_zero): Add missing
7305 register constraint to operand 0.
7306 (add<mode>3_carryinC): Likewise.
7307 (add<mode>3_carryinV_zero, add<mode>3_carryinV): Likewise.
7308
7309 2018-08-09 Martin Liska <mliska@suse.cz>
7310
7311 PR c/86895
7312 * common.opt: Remove extra line.
7313
7314 2018-08-09 Martin Liska <mliska@suse.cz>
7315
7316 * params.def (PARAM_ALIGN_LOOP_ITERATIONS): Remove double dots
7317 at the end of a line, make first letter capital and end up
7318 a sentence with a dot.
7319 (PARAM_LOOP_INTERCHANGE_STRIDE_RATIO): Likewise.
7320 (PARAM_LOOP_BLOCK_TILE_SIZE): Likewise.
7321 (PARAM_GRAPHITE_MAX_NB_SCOP_PARAMS): Likewise.
7322 (PARAM_GRAPHITE_MAX_ARRAYS_PER_SCOP): Likewise.
7323 (PARAM_MAX_ISL_OPERATIONS): Likewise.
7324 (PARAM_GRAPHITE_ALLOW_CODEGEN_ERRORS): Likewise.
7325 (PARAM_PROFILE_FUNC_INTERNAL_ID): Likewise.
7326 (PARAM_INDIR_CALL_TOPN_PROFILE): Likewise.
7327 (PARAM_SLP_MAX_INSNS_IN_BB): Likewise.
7328 (PARAM_IPA_CP_EVAL_THRESHOLD): Likewise.
7329 (PARAM_IPA_CP_RECURSION_PENALTY): Likewise.
7330 (PARAM_IPA_CP_SINGLE_CALL_PENALTY): Likewise.
7331 (PARAM_IPA_CP_LOOP_HINT_BONUS): Likewise.
7332 (PARAM_IPA_CP_ARRAY_INDEX_HINT_BONUS): Likewise.
7333 (PARAM_TREE_REASSOC_WIDTH): Likewise.
7334 (PARAM_HSA_GEN_DEBUG_STORES): Likewise.
7335 (PARAM_MAX_SPECULATIVE_DEVIRT_MAYDEFS): Likewise.
7336 (PARAM_MAX_VRP_SWITCH_ASSERTIONS): Likewise.
7337
7338 2018-08-09 Andreas Krebbel <krebbel@linux.ibm.com>
7339
7340 PR target/84332
7341 * config/s390/s390.c (s390_option_override_internal): Reduce the
7342 stack-clash-protection-probe-interval param if it would be too big
7343 for z900.
7344
7345 2018-08-08 Andreas Schwab <schwab@linux-m68k.org>
7346
7347 PR target/46179
7348 * config/m68k/m68k.h (FINAL_PRESCAN_INSN): Don't define.
7349 * config/m68k/m68k.c (handle_move_double): Don't call
7350 m68k_final_prescan_insn.
7351 (m68k_adjust_decorated_operand): Renamed from
7352 m68k_final_prescan_insn, remove first and third operand and
7353 simplify.
7354 (print_operand): Call it.
7355 (print_operand_address): Call it.
7356
7357 2018-08-08 Nathan Sidwell <nathan@acm.org>
7358
7359 * diagnostic.c (diagnostic_report_current_module): Use
7360 linemap_included_from & linemap_included_from_linemap.
7361
7362 2018-08-08 Hongbo Zhang <hongbo.zhang@linaro.org>
7363
7364 * config/aarch64/aarch64-cores.def: Add phecda core.
7365 * config/aarch64/aarch64-tune.md: Regenerate.
7366 * doc/invoke.texi: Add phecda core.
7367
7368 2018-08-08 Andreas Krebbel <krebbel@linux.ibm.com>
7369
7370 PR target/85295
7371 * config/s390/constraints.md ("NxHD0", "NxSD0"): New constraint
7372 definitions.
7373 * config/s390/s390.md ("movti"): Add more alternatives for
7374 constant to GPR copies.
7375
7376 2018-08-08 Andreas Krebbel <krebbel@linux.ibm.com>
7377
7378 * config/s390/s390.c: Fix whitespace damage throughout the file.
7379 * config/s390/s390.h: Likewise.
7380 * config/s390/tpf.h: Likewise.
7381
7382 2018-08-08 Ilya Leoshkevich <iii@linux.ibm.com>
7383
7384 * config/s390/s390.c (s390_loadrelative_operand_p):
7385 Remove TARGET_CPU_ZARCH usages.
7386 (s390_rtx_costs): Likewise.
7387 (s390_legitimate_constant_p): Likewise.
7388 (s390_cannot_force_const_mem): Likewise.
7389 (legitimate_reload_constant_p): Likewise.
7390 (s390_preferred_reload_class): Likewise.
7391 (legitimize_pic_address): Likewise.
7392 (legitimize_tls_address): Likewise.
7393 (s390_split_branches): Removed.
7394 (s390_add_execute): Removed.
7395 (s390_dump_pool): Remove TARGET_CPU_ZARCH usages.
7396 (s390_mainpool_start): Likewise.
7397 (s390_mainpool_finish): Likewise.
7398 (s390_mainpool_cancel): Removed.
7399 (s390_chunkify_start): Remove TARGET_CPU_ZARCH usages.
7400 (s390_chunkify_cancel): Likewise.
7401 (s390_return_addr_rtx): Likewise.
7402 (s390_register_info): Remove split_branches_pending_p uages.
7403 (s390_optimize_register_info): Likewise.
7404 (s390_init_frame_layout): Remove TARGET_CPU_ZARCH and
7405 split_branches_pending_p usages.
7406 (s390_can_eliminate): Remove TARGET_CPU_ZARCH usages.
7407 (s390_load_got): Likewise.
7408 (s390_expand_split_stack_prologue): Likewise.
7409 (output_asm_nops): Likewise.
7410 (s390_function_profiler): Likewise.
7411 (s390_emit_call): Likewise.
7412 (s390_conditional_register_usage): Likewise.
7413 (s390_optimize_prologue): Likewise.
7414 (s390_reorg): Remove TARGET_CPU_ZARCH and
7415 split_branches_pending_p usages.
7416 (s390_option_override_internal): Remove TARGET_CPU_ZARCH
7417 usages.
7418 (s390_output_indirect_thunk_function): Likewise.
7419 * config/s390/s390.h (TARGET_CPU_ZARCH): Removed.
7420 (TARGET_CPU_ZARCH_P): Removed.
7421 (struct machine_function): Remove split_branches_pending_p.
7422 * config/s390/s390.md: Remove TARGET_CPU_ZARCH usages.
7423
7424 2018-08-08 Ilya Leoshkevich <iii@linux.ibm.com>
7425
7426 * common/config/s390/s390-common.c (processor_flags_table):
7427 Remove flags.
7428 * config.gcc: Remove with_arch/with_tune support.
7429 * config/s390/2064.md: Remove cpu attribute comparisons.
7430 * config/s390/driver-native.c (s390_host_detect_local_cpu):
7431 Remove MTN.
7432 * config/s390/linux.h (ASM_SPEC):
7433 Remove -march support.
7434 * config/s390/s390-c.c (s390_cpu_cpp_builtins_internal):
7435 Use a table to get an arch level.
7436 * config/s390/s390-opts.h (enum processor_type):
7437 Remove enum values.
7438 * config/s390/s390.c
7439 (processor_table): Remove entries, add arch_level values.
7440 (s390_issue_rate): Remove cases.
7441 (s390_option_override): Adjust
7442 s390_option_override_internal() call.
7443 (s390_option_override_internal): Remove deprecation warning.
7444 (s390_valid_target_attribute_tree): Adjust
7445 s390_option_override_internal() call.
7446 * config/s390/s390.h (struct s390_processor):
7447 Share with s390-c.c, add arch_level field.
7448 * config/s390/s390.md:
7449 Remove occurrences in cpu attribute.
7450 * config/s390/s390.opt: Remove -march/-mtune support.
7451 * config/s390/tpf.h (ASM_SPEC): Remove -march support.
7452 * doc/invoke.texi: Remove deprecation warning.
7453
7454 2018-08-08 Luis Machado <luis.machado@linaro.org>
7455
7456 * config/aarch64/aarch64.c (qdf24xx_vector_cost): New static
7457 global.
7458 (qdf24xx_tunings): Set vector cost structure to
7459 qdf24xx_vector_cost.
7460
7461 * config/aarch64/aarch64.c (qdf24xx_addrcost_table)
7462 <register_sextend>: Set to 3.
7463
7464 2018-08-07 Richard Sandiford <richard.sandiford@arm.com>
7465
7466 PR target/86838
7467 * config/aarch64/iterators.md (FRECP, frecp_suffix): Delete.
7468 * config/aarch64/aarch64-simd.md
7469 (aarch64_frecp<FRECP:frecp_suffix><mode>): Fold FRECPE into...
7470 (@aarch64_frecpe<mode>): ...here and the move FRECPX to...
7471 (aarch64_frecpx<mode>): ...this new pattern.
7472 * config/aarch64/aarch64-simd-builtins.def: Remove comment
7473 about aarch64_frecp<FRECP:frecp_suffix><mode>.
7474
7475 2018-08-07 Martin Liska <mliska@suse.cz>
7476
7477 PR middle-end/83023
7478 * predict.c (expr_expected_value_1): Handle DECL_IS_MALLOC,
7479 BUILT_IN_REALLOC and DECL_IS_OPERATOR_NEW.
7480 * predict.def (PRED_MALLOC_NONNULL): New predictor.
7481 * doc/extend.texi: Document that malloc attribute adds
7482 hit to compiler.
7483
7484 2018-08-06 John David Anglin <danglin@gcc.gnu.org>
7485
7486 PR target/86785
7487 * config/pa/pa.c (TARGET_HAVE_SPECULATION_SAFE_VALUE):
7488 Define to speculation_safe_value_not_needed.
7489
7490 2018-08-06 Jeff Law <law@redhat.com>
7491
7492 * tree-ssa-dom.c (dom_opt_dom_walker::optimize_stmt): Pass down
7493 the vr_values instance to cprop_into_stmt.
7494 (cprop_into_stmt): Pass vr_values instance down to cprop_operand.
7495 (cprop_operand): Also query EVRP to determine if OP is a constant.
7496
7497 2018-08-06 Nathan Sidwell <nathan@acm.org>
7498
7499 * diagnostic.c (diagnostic_report_current_module): Reroll
7500 included-at loop. Translate text.
7501
7502 2018-08-06 David Malcolm <dmalcolm@redhat.com>
7503
7504 * function-tests.c (selftest::test_expansion_to_rtl): Call
7505 free_after_compilation.
7506
7507 2018-08-06 Alan Hayward <alan.hayward@arm.com>
7508
7509 * config/aarch64/aarch64.md: Add clobber highs to tls_desc.
7510
7511 2018-08-06 Andreas Krebbel <krebbel@linux.ibm.com>
7512
7513 * config/s390/s390.c (s390_loop_unroll_adjust): Prevent small
7514 loops with memory block operations from getting unrolled.
7515
7516 2018-08-06 Ulrich Weigand <uweigand@de.ibm.com>
7517
7518 PR target/86807
7519 * config/spu/spu.c (TARGET_HAVE_SPECULATION_SAFE_VALUE):
7520 Define to speculation_safe_value_not_needed.
7521
7522 2018-08-06 Jeff Law <law@redhat.com>
7523
7524 * reload1.c (forget_old_reloads_1): Adjust CLOBBER_HIGH
7525 assert.
7526
7527 2018-08-06 Jozef Lawrynowicz <jozef.l@mittosystems.com>
7528
7529 PR target/86662
7530 * gcc/tree.c (build_common_tree_nodes): Initialize integer_types array
7531 with all enabled __intN types.
7532
7533 * gcc/testsuite/gcc.target/msp430/pr86662.c: New test.
7534
7535 2018-08-06 Alan Hayward <alan.hayward@arm.com>
7536
7537 * alias.c (record_set): Check for clobber high.
7538 * cfgexpand.c (expand_gimple_stmt): Likewise.
7539 * combine-stack-adj.c (single_set_for_csa): Likewise.
7540 * combine.c (find_single_use_1): Likewise.
7541 (set_nonzero_bits_and_sign_copies): Likewise.
7542 (get_combine_src_dest): Likewise.
7543 (is_parallel_of_n_reg_sets): Likewise.
7544 (try_combine): Likewise.
7545 (record_dead_and_set_regs_1): Likewise.
7546 (reg_dead_at_p_1): Likewise.
7547 (reg_dead_at_p): Likewise.
7548 * dce.c (deletable_insn_p): Likewise.
7549 (mark_nonreg_stores_1): Likewise.
7550 (mark_nonreg_stores_2): Likewise.
7551 * df-scan.c (df_find_hard_reg_defs): Likewise.
7552 (df_uses_record): Likewise.
7553 (df_get_call_refs): Likewise.
7554 * dwarf2out.c (mem_loc_descriptor): Likewise.
7555 * haifa-sched.c (haifa_classify_rtx): Likewise.
7556 * ira-build.c (create_insn_allocnos): Likewise.
7557 * ira-costs.c (scan_one_insn): Likewise.
7558 * ira.c (equiv_init_movable_p): Likewise.
7559 (rtx_moveable_p): Likewise.
7560 (interesting_dest_for_shprep): Likewise.
7561 * jump.c (mark_jump_label_1): Likewise.
7562 * postreload-gcse.c (record_opr_changes): Likewise.
7563 * postreload.c (reload_cse_simplify): Likewise.
7564 (struct reg_use): Add source expr.
7565 (reload_combine): Check for clobber high.
7566 (reload_combine_note_use): Likewise.
7567 (reload_cse_move2add): Likewise.
7568 (move2add_note_store): Likewise.
7569 * print-rtl.c (print_pattern): Likewise.
7570 * recog.c (decode_asm_operands): Likewise.
7571 (store_data_bypass_p): Likewise.
7572 (if_test_bypass_p): Likewise.
7573 * regcprop.c (kill_clobbered_value): Likewise.
7574 (kill_set_value): Likewise.
7575 * reginfo.c (reg_scan_mark_refs): Likewise.
7576 * reload1.c (maybe_fix_stack_asms): Likewise.
7577 (eliminate_regs_1): Likewise.
7578 (elimination_effects): Likewise.
7579 (mark_not_eliminable): Likewise.
7580 (scan_paradoxical_subregs): Likewise.
7581 (forget_old_reloads_1): Likewise.
7582 * reorg.c (find_end_label): Likewise.
7583 (try_merge_delay_insns): Likewise.
7584 (redundant_insn): Likewise.
7585 (own_thread_p): Likewise.
7586 (fill_simple_delay_slots): Likewise.
7587 (fill_slots_from_thread): Likewise.
7588 (dbr_schedule): Likewise.
7589 * resource.c (update_live_status): Likewise.
7590 (mark_referenced_resources): Likewise.
7591 (mark_set_resources): Likewise.
7592 * rtl.c (copy_rtx): Likewise.
7593 * rtlanal.c (reg_referenced_p): Likewise.
7594 (single_set_2): Likewise.
7595 (noop_move_p): Likewise.
7596 (note_stores): Likewise.
7597 * sched-deps.c (sched_analyze_reg): Likewise.
7598 (sched_analyze_insn): Likewise.
7599
7600 2018-08-06 Alan Hayward <alan.hayward@arm.com>
7601
7602 * cse.c (invalidate_reg): New function extracted from...
7603 (invalidate): ...here.
7604 (canonicalize_insn): Check for clobber high.
7605 (invalidate_from_clobbers): invalidate clobber highs.
7606 (invalidate_from_sets_and_clobbers): Likewise.
7607 (count_reg_usage): Check for clobber high.
7608 (insn_live_p): Likewise.
7609 * cselib.c (cselib_expand_value_rtx_1):Likewise.
7610 (cselib_invalidate_regno): Check for clobber in setter.
7611 (cselib_invalidate_rtx): Pass through setter.
7612 (cselib_invalidate_rtx_note_stores):
7613 (cselib_process_insn): Check for clobber high.
7614 * cselib.h (cselib_invalidate_rtx): Add operand.
7615
7616 2018-08-06 Alan Hayward <alan.hayward@arm.com>
7617
7618 * lra-eliminations.c (lra_eliminate_regs_1): Check for clobber high.
7619 (mark_not_eliminable): Likewise.
7620 * lra-int.h (struct lra_insn_reg): Add clobber high marker.
7621 * lra-lives.c (process_bb_lives): Check for clobber high.
7622 * lra.c (new_insn_reg): Remember clobber highs.
7623 (collect_non_operand_hard_regs): Check for clobber high.
7624 (lra_set_insn_recog_data): Likewise.
7625 (add_regs_to_insn_regno_info): Likewise.
7626 (lra_update_insn_regno_info): Likewise.
7627
7628 2018-08-06 Alan Hayward <alan.hayward@arm.com>
7629
7630 * rtl.h (reg_is_clobbered_by_clobber_high): Add declarations.
7631 * rtlanal.c (reg_is_clobbered_by_clobber_high): Add function.
7632
7633 2018-08-06 Alan Hayward <alan.hayward@arm.com>
7634
7635 * emit-rtl.c (verify_rtx_sharing): Check for CLOBBER_HIGH.
7636 (copy_insn_1): Likewise.
7637 (gen_hard_reg_clobber_high): New gen function.
7638 * genconfig.c (walk_insn_part): Check for CLOBBER_HIGH.
7639 * genemit.c (gen_exp): Likewise.
7640 (gen_emit_seq): Pass through info.
7641 (gen_insn): Check for CLOBBER_HIGH.
7642 (gen_expand): Pass through info.
7643 (gen_split): Likewise.
7644 (output_add_clobbers): Likewise.
7645 * genrecog.c (validate_pattern): Check for CLOBBER_HIGH.
7646 (remove_clobbers): Likewise.
7647 * rtl.h (gen_hard_reg_clobber_high): New declaration.
7648
7649 2018-08-06 Alan Hayward <alan.hayward@arm.com>
7650
7651 * doc/rtl.texi (clobber_high): Add.
7652 (parallel): Add in clobber high
7653 * rtl.c (rtl_check_failed_code3): Add function.
7654 * rtl.def (CLOBBER_HIGH): Add expression.
7655 * rtl.h (RTL_CHECKC3): Add macro.
7656 (rtl_check_failed_code3): Add declaration.
7657 (XC3EXP): Add macro.
7658
7659 2018-08-05 H.J. Lu <hongjiu.lu@intel.com>
7660
7661 PR target/86386
7662 * config/i386/i386.c (ix86_finalize_stack_frame_flags): Set
7663 cfun->machine->max_used_stack_alignment if needed.
7664
7665 2018-08-04 Martin Sebor <msebor@redhat.com>
7666
7667 PR tree-optimization/86571
7668 * gimple-ssa-sprintf.c (format_floating): Extend upper bound of
7669 NaN output to 4.
7670
7671 2018-08-03 Sandra Loosemore <sandra@codesourcery.com>
7672
7673 PR target/86799
7674 * config/nios2/nios2.c (TARGET_HAVE_SPECULATION_SAFE_VALUE):
7675 Define.
7676
7677 2018-08-03 Jeff Law <law@redhat.com>
7678
7679 PR target/86795
7680 * config/mn10300/mn10300.c (TARGET_HAVE_SPECULATION_SAFE_VALUE):
7681 Define to speculation_safe_value_not_needed.
7682
7683 2018-08-03 David Malcolm <dmalcolm@redhat.com>
7684
7685 * doc/gcov.texi (-x): Remove duplicate "to".
7686 * doc/invoke.texi (-Wnoexcept-type): Remove duplicate "calls".
7687 (-Wif-not-aligned): Remove duplicate "is".
7688 (-flto): Remove duplicate "the".
7689 (MicroBlaze Options): In examples of "-mcpu=cpu-type", remove
7690 duplicate "v5.00.b".
7691 (MSP430 Options): Remove duplicate "and" from the description
7692 of "-mgprel-sec=regexp".
7693 (x86 Options): Remove duplicate copies of "vmldLog102" and
7694 vmlsLog104 from description of "-mveclibabi=type".
7695
7696 2018-08-03 Richard Sandiford <richard.sandiford@arm.com>
7697
7698 * internal-fn.h (first_commutative_argument): Declare.
7699 * internal-fn.c (first_commutative_argument): New function.
7700 * tree-vect-slp.c (vect_get_and_check_slp_defs): Remove extra
7701 restrictions for pattern statements. Use first_commutative_argument
7702 to look for commutative operands in calls to internal functions.
7703
7704 2018-08-03 Aldy Hernandez <aldyh@redhat.com>
7705
7706 * Makefile.in (wide-int-range.o): New.
7707 * tree-vrp.c: Move all the wide_int_* functions to...
7708 * wide-int-range.cc: ...here.
7709 * tree-vrp.h: Move all the wide_int_* prototypes to...
7710 * wide-int-range.h: ...here.
7711
7712 2018-08-03 Tom de Vries <tdevries@suse.de>
7713
7714 * common/config/nvptx/nvptx-common.c (nvptx_except_unwind_info): Return
7715 UI_NONE.
7716 * config/nvptx/nvptx.c (TARGET_ASM_BYTE_OP): Remove define.
7717 * except.c (output_function_exception_table): Do early exit if
7718 targetm_common.except_unwind_info (&global_options) == UI_NONE.
7719
7720 2018-08-03 Martin Liska <mliska@suse.cz>
7721
7722 * predict.c (dump_prediction): Change to 2 digits
7723 in fraction part.
7724
7725 2018-08-03 Siddhesh Poyarekar <siddhesh@sourceware.org>
7726
7727 * config/aarch64/falkor.md (falkor_am_1_vxvy_vxvy): Move
7728 neon_dup_q to...
7729 (falkor_am_1_gtov_gtov): ... a new insn reservation.
7730
7731 2018-07-19 Ilya Leoshkevich <iii@linux.ibm.com>
7732
7733 * config/nds32/nds32.c (nds32_hard_regno_mode_ok): Replace > with >=.
7734 * df-problems.c (df_remove_dead_eq_notes): Replace > with >=.
7735 * dwarf2out.c (mem_loc_descriptor): Replace > with >=.
7736 * lra-constraints.c (spill_hard_reg_in_range): Replace <= with <.
7737 * lra-remat.c (call_used_input_regno_present_p): Replace <= with <.
7738
7739 2018-08-02 David Malcolm <dmalcolm@redhat.com>
7740
7741 * diagnostic-show-locus.c (diagnostic_show_locus): Use
7742 pp_take_prefix when saving the existing prefix.
7743 * diagnostic.c (diagnostic_append_note): Likewise.
7744 * langhooks.c (lhd_print_error_function): Likewise.
7745 * pretty-print.c (pp_set_prefix): Drop the "const" from "prefix"
7746 param's type. Free the existing prefix.
7747 (pp_take_prefix): New function.
7748 (pretty_printer::pretty_printer): Drop the prefix parameter.
7749 Rename the length parameter to match the comment.
7750 (pretty_printer::~pretty_printer): Free the prefix.
7751 * pretty-print.h (pretty_printer::pretty_printer): Drop the prefix
7752 parameter.
7753 (struct pretty_printer): Drop the "const" from "prefix" field's
7754 type and clarify memory management.
7755 (pp_set_prefix): Drop the "const" from the 2nd param.
7756 (pp_take_prefix): New decl.
7757
7758 2018-08-02 Aaron Sawdey <acsawdey@linux.ibm.com>
7759
7760 * config/rs6000/rs6000-string.c (select_block_compare_mode): Move test
7761 for word_mode_ok here instead of passing as argument.
7762 (expand_block_compare): Change select_block_compare_mode() call.
7763 (expand_strncmp_gpr_sequence): New function.
7764 (expand_strn_compare): Make use of expand_strncmp_gpr_sequence.
7765
7766 2018-08-02 Jeff Law <law@redhat.com>
7767
7768 PR target/86790
7769 * config/m68k/m68k.c (TARGET_HAVE_SPECULATION_SAFE_VALUE):
7770 Define to speculation_safe_value_not_needed.
7771
7772 PR target/86784
7773 * config/h8300/h8300.c (TARGET_HAVE_SPECULATION_SAFE_VALUE):
7774 Define to speculation_safe_value_not_needed.
7775
7776 2018-08-02 Tom de Vries <tdevries@suse.de>
7777
7778 PR target/86660
7779 * common/config/nvptx/nvptx-common.c (nvptx_except_unwind_info): New
7780 function. Return UI_TARGET unconditionally.
7781 (TARGET_EXCEPT_UNWIND_INFO): Redefine to nvptx_except_unwind_info.
7782 * config/nvptx/nvptx.c (TARGET_ASM_BYTE_OP): Emit commented out '.byte'.
7783
7784 2018-08-02 Richard Sandiford <richard.sandiford@arm.com>
7785
7786 * genemit.c (print_overload_test): Fix typo.
7787
7788 2018-08-02 Richard Biener <rguenther@suse.de>
7789
7790 PR tree-optimization/86816
7791 * tree-ssa-tail-merge.c (tail_merge_valueize): New function
7792 which checks for value availability before querying it.
7793 (gvn_uses_equal): Use it.
7794 (same_succ_hash): Likewise.
7795 (gimple_equal_p): Likewise.
7796
7797 2018-08-02 Nick Clifton <nickc@redhat.com>
7798
7799 PR target/86813
7800 * config/stormy16/stormy16.c (TARGET_HAVE_SPECULATION_SAFE_VALUE):
7801 Define to speculation_safe_value_not_needed.
7802
7803 PR target/86810
7804 * config/v850/v850.c (TARGET_HAVE_SPECULATION_SAFE_VALUE):
7805 Define to speculation_safe_value_not_needed.
7806
7807 PR target/86810
7808 * config/v850/v850.c (TARGET_HAVE_SPECULATION_SAFE_VALUE):
7809 Define to speculation_safe_value_not_needed.
7810
7811 PR target/86803
7812 * config/rx/rx.c (TARGET_HAVE_SPECULATION_SAFE_VALUE):
7813 Define to speculation_safe_value_not_needed.
7814
7815 PR target/86797
7816 * config/msp430/msp430.c (TARGET_HAVE_SPECULATION_SAFE_VALUE):
7817 Define to speculation_safe_value_not_needed.
7818
7819 PR target/86791
7820 * config/mcore/mcore.c (TARGET_HAVE_SPECULATION_SAFE_VALUE):
7821 Define to speculation_safe_value_not_needed.
7822
7823 PR target/86789
7824 * config/m32r/m32r.c (TARGET_HAVE_SPECULATION_SAFE_VALUE):
7825 Define to speculation_safe_value_not_needed.
7826
7827 PR target/86787
7828 * config/iq2000/iq2000.c (TARGET_HAVE_SPECULATION_SAFE_VALUE):
7829 Define to speculation_safe_value_not_needed.
7830
7831 PR target/86782
7832 * config/frv/frv.c (TARGET_HAVE_SPECULATION_SAFE_VALUE): Define to
7833 speculation_safe_value_not_needed.
7834
7835 PR target/86781
7836 * config/fr30/fr30.c (TARGET_HAVE_SPECULATION_SAFE_VALUE): Define
7837 to speculation_safe_value_not_needed.
7838
7839 2018-08-02 Richard Sandiford <richard.sandiford@arm.com>
7840
7841 * doc/md.texi: Expand the documentation of instruction names
7842 to mention port-local uses. Document '@' in pattern names.
7843 * read-md.h (overloaded_instance, overloaded_name): New structs.
7844 (mapping): Declare.
7845 (md_reader::handle_overloaded_name): New member function.
7846 (md_reader::get_overloads): Likewise.
7847 (md_reader::m_first_overload): New member variable.
7848 (md_reader::m_next_overload_ptr): Likewise.
7849 (md_reader::m_overloads_htab): Likewise.
7850 * read-md.c (md_reader::md_reader): Initialize m_first_overload,
7851 m_next_overload_ptr and m_overloads_htab.
7852 * read-rtl.c (iterator_group): Add "type" and "get_c_token" fields.
7853 (get_mode_token, get_code_token, get_int_token): New functions.
7854 (map_attr_string): Add an optional argument that passes back
7855 the associated iterator.
7856 (overloaded_name_hash, overloaded_name_eq_p, named_rtx_p):
7857 (md_reader::handle_overloaded_name, add_overload_instance): New
7858 functions.
7859 (apply_iterators): Handle '@' names. Report an error if '@'
7860 is used without iterators.
7861 (initialize_iterators): Initialize the new iterator_group fields.
7862 * genopinit.c (handle_overloaded_code_for)
7863 (handle_overloaded_gen): New functions.
7864 (main): Use them to print declarations of maybe_code_for_* and
7865 maybe_gen_* functions, and inline definitions of code_for_* and gen_*.
7866 * genemit.c (print_overload_arguments, print_overload_test)
7867 (handle_overloaded_code_for, handle_overloaded_gen): New functions.
7868 (main): Use it to print definitions of maybe_code_for_* and
7869 maybe_gen_* functions.
7870 * config/aarch64/aarch64.c (aarch64_split_128bit_move): Use
7871 gen_aarch64_mov{low,high}_di and gen_aarch64_movdi_{low,high}
7872 instead of explicit mode checks.
7873 (aarch64_split_simd_combine): Likewise gen_aarch64_simd_combine.
7874 (aarch64_split_simd_move): Likewise gen_aarch64_split_simd_mov.
7875 (aarch64_emit_load_exclusive): Likewise gen_aarch64_load_exclusive.
7876 (aarch64_emit_store_exclusive): Likewise gen_aarch64_store_exclusive.
7877 (aarch64_expand_compare_and_swap): Likewise
7878 gen_aarch64_compare_and_swap and gen_aarch64_compare_and_swap_lse
7879 (aarch64_gen_atomic_cas): Likewise gen_aarch64_atomic_cas.
7880 (aarch64_emit_atomic_swap): Likewise gen_aarch64_atomic_swp.
7881 (aarch64_constant_pool_reload_icode): Delete.
7882 (aarch64_secondary_reload): Use code_for_aarch64_reload_movcp
7883 instead of aarch64_constant_pool_reload_icode. Use
7884 code_for_aarch64_reload_mov instead of explicit mode checks.
7885 (rsqrte_type, get_rsqrte_type, rsqrts_type, get_rsqrts_type): Delete.
7886 (aarch64_emit_approx_sqrt): Use gen_aarch64_rsqrte instead of
7887 get_rsqrte_type and gen_aarch64_rsqrts instead of gen_rqrts_type.
7888 (recpe_type, get_recpe_type, recps_type, get_recps_type): Delete.
7889 (aarch64_emit_approx_div): Use gen_aarch64_frecpe instead of
7890 get_recpe_type and gen_aarch64_frecps instead of get_recps_type.
7891 (aarch64_atomic_load_op_code): Delete.
7892 (aarch64_emit_atomic_load_op): Likewise.
7893 (aarch64_gen_atomic_ldop): Use UNSPECV_ATOMIC_* instead of
7894 aarch64_atomic_load_op_code. Use gen_aarch64_atomic_load
7895 instead of aarch64_emit_atomic_load_op.
7896 * config/aarch64/aarch64.md (aarch64_reload_movcp<GPF_TF:mode><P:mode>)
7897 (aarch64_reload_movcp<VALL:mode><P:mode>, aarch64_reload_mov<mode>)
7898 (aarch64_movdi_<mode>low, aarch64_movdi_<mode>high)
7899 (aarch64_mov<mode>high_di, aarch64_mov<mode>low_di): Add a '@'
7900 character before the pattern name.
7901 * config/aarch64/aarch64-simd.md (aarch64_split_simd_mov<mode>)
7902 (aarch64_rsqrte<mode>, aarch64_rsqrts<mode>)
7903 (aarch64_simd_combine<mode>, aarch64_frecpe<mode>)
7904 (aarch64_frecps<mode>): Likewise.
7905 * config/aarch64/atomics.md (atomic_compare_and_swap<mode>)
7906 (aarch64_compare_and_swap<mode>, aarch64_compare_and_swap<mode>_lse)
7907 (aarch64_load_exclusive<mode>, aarch64_store_exclusive<mode>)
7908 (aarch64_atomic_swp<mode>, aarch64_atomic_cas<mode>)
7909 (aarch64_atomic_load<atomic_ldop><mode>): Likewise.
7910
7911 2018-08-02 Richard Sandiford <richard.sandiford@arm.com>
7912
7913 * config/aarch64/aarch64.c (aarch64_float_const_representable_p):
7914 Allow HFmode constants if TARGET_FP_F16INST.
7915
7916 2018-08-02 Jackson Woodruff <jackson.woodruff@arm.com>
7917
7918 PR target/86014
7919 * config/aarch64/aarch64.c (aarch64_operands_adjust_ok_for_ldpstp):
7920 No longer check last store for clobber of address register.
7921
7922 2018-08-02 Martin Liska <mliska@suse.cz>
7923
7924 PR gcov-profile/86817
7925 * gcov.c (process_all_functions): New function.
7926 (main): Call it.
7927 (process_file): Move functions processing to
7928 process_all_functions.
7929
7930 2018-08-02 David Malcolm <dmalcolm@redhat.com>
7931
7932 * dumpfile.c (dump_user_location_t::dump_user_location_t): Add
7933 "const" to the "gimple *" and "rtx_insn *" parameters.
7934 * dumpfile.h (dump_user_location_t::dump_user_location_t):
7935 Likewise.
7936 (dump_location_t::dump_location_t): Likewise.
7937
7938 2018-08-01 Martin Sebor <msebor@redhat.com>
7939
7940 PR tree-optimization/86650
7941 * gimple-pretty-print.c (percent_G_format): Accept a "gimple *"
7942 rather than a "gcall *". Directly pass the data of interest
7943 to percent_K_format, rather than building a temporary CALL_EXPR
7944 to hold it.
7945 * gimple-fold.c (gimple_fold_builtin_strncpy): Adjust.
7946 (gimple_fold_builtin_strncat): Adjust.
7947 * gimple-ssa-warn-restrict.h (check_bounds_or_overlap): Replace
7948 gcall* argument with gimple*.
7949 * gimple-ssa-warn-restrict.c (check_call): Same.
7950 (wrestrict_dom_walker::before_dom_children): Same.
7951 (builtin_access::builtin_access): Same.
7952 (check_bounds_or_overlap): Same
7953 (maybe_diag_overlap): Same.
7954 (maybe_diag_offset_bounds): Same.
7955 * tree-diagnostic.c (default_tree_printer): Move usage of
7956 EXPR_LOCATION (t) and TREE_BLOCK (t) from within percent_K_format
7957 to this callsite.
7958 * tree-pretty-print.c (percent_K_format): Add argument.
7959 * tree-pretty-print.h: Add argument.
7960 * tree-ssa-ccp.c (pass_post_ipa_warn::execute): Adjust.
7961 * tree-ssa-strlen.c (maybe_diag_stxncpy_trunc): Adjust.
7962 (maybe_diag_stxncpy_trunc): Same.
7963 (handle_builtin_stxncpy): Same.
7964 (handle_builtin_strcat): Same.
7965
7966 2018-08-01 Richard Sandiford <richard.sandiford@arm.com>
7967
7968 * match.pd: Optimise pointer range checks.
7969
7970 2018-08-01 Richard Sandiford <richard.sandiford@arm.com>
7971
7972 PR tree-optimization/86758
7973 * tree-vect-stmts.c (vectorizable_simd_clone_call): Don't try
7974 to remove pattern statements.
7975
7976 2018-08-01 Richard Sandiford <richard.sandiford@arm.com>
7977
7978 * tree-vect-loop.c (_loop_vec_info::_loop_vec_info): Use the
7979 result of dfs_enumerate_from when constructing stmt_vec_infos,
7980 instead of additionally calling get_loop_body.
7981
7982 2018-08-01 Richard Sandiford <richard.sandiford@arm.com>
7983
7984 * tree-vectorizer.h (vect_create_data_ref_ptr): Remove inv_p
7985 parameter.
7986 * tree-vect-data-refs.c (vect_create_data_ref_ptr): Likewise.
7987 When creating an iv, assert that the step is not known to be zero.
7988 (vect_setup_realignment): Update call accordingly.
7989 * tree-vect-stmts.c (vectorizable_store): Likewise.
7990 (vectorizable_load): Likewise. Handle VMAT_INVARIANT separately.
7991
7992 2018-08-01 Richard Sandiford <richard.sandiford@arm.com>
7993
7994 * tree-vectorizer.h (vect_stmt_to_vectorize): New function.
7995 * tree-vect-loop.c (vect_update_vf_for_slp): Use it.
7996 (vectorizable_reduction): Likewise.
7997 * tree-vect-slp.c (vect_analyze_slp_instance): Likewise.
7998 (vect_detect_hybrid_slp_stmts): Likewise.
7999 * tree-vect-stmts.c (vect_is_simple_use): Likewise.
8000
8001 2018-08-01 Aldy Hernandez <aldyh@redhat.com>
8002
8003 * tree-vrp (zero_nonzero_bits_from_bounds): Rename to...
8004 (wide_int_set_zero_nonzero_bits): ...this.
8005 (zero_nonzero_bits_from_vr): Rename to...
8006 (vrp_set_zero_nonzero_bits): ...this.
8007 (extract_range_from_multiplicative_op_1): Abstract wide int
8008 code...
8009 (wide_int_range_multiplicative_op): ...here.
8010 (extract_range_from_binary_expr_1): Extract wide int binary
8011 operations into their own functions.
8012 (wide_int_range_lshift): New.
8013 (wide_int_range_can_optimize_bit_op): New.
8014 (wide_int_range_shift_undefined_p): New.
8015 (wide_int_range_bit_xor): New.
8016 (wide_int_range_bit_ior): New.
8017 (wide_int_range_bit_and): New.
8018 (wide_int_range_trunc_mod): New.
8019 (extract_range_into_wide_ints): New.
8020 (vrp_shift_undefined_p): New.
8021 (extract_range_from_multiplicative_op): New.
8022 (vrp_can_optimize_bit_op): New.
8023 * tree-vrp.h (value_range::dump): New.
8024 (wide_int_range_multiplicative_op): New.
8025 (wide_int_range_lshift):New.
8026 (wide_int_range_shift_undefined_p): New.
8027 (wide_int_range_bit_xor): New.
8028 (wide_int_range_bit_ior): New.
8029 (wide_int_range_bit_and): New.
8030 (wide_int_range_trunc_mod): New.
8031 (zero_nonzero_bits_from_bounds): Rename to...
8032 (wide_int_set_zero_nonzero_bits): ...this.
8033 (zero_nonzero_bits_from_vr): Rename to...
8034 (vrp_set_zero_nonzero_bits): ...this.
8035 (range_easy_mask_min_max): Rename to...
8036 (wide_int_range_can_optimize_bit_op): this.
8037 * vr-values.c (simplify_bit_ops_using_ranges): Rename
8038 zero_nonzero_bits_from_vr into vrp_set_zero_nonzero_bits.
8039
8040 2018-08-01 Richard Sandiford <richard.sandiford@arm.com>
8041
8042 * tree-vectorizer.h (vect_orig_stmt): New function.
8043 * tree-vect-data-refs.c (vect_preserves_scalar_order_p): Use it.
8044 * tree-vect-loop.c (vect_model_reduction_cost): Likewise.
8045 (vect_create_epilog_for_reduction): Likewise.
8046 (vectorizable_live_operation): Likewise.
8047 * tree-vect-slp.c (vect_find_last_scalar_stmt_in_slp): Likewise.
8048 (vect_detect_hybrid_slp_stmts, vect_schedule_slp): Likewise.
8049 * tree-vect-stmts.c (vectorizable_call): Likewise.
8050 (vectorizable_simd_clone_call, vect_remove_stores): Likewise.
8051
8052 2018-08-01 Richard Sandiford <richard.sandiford@arm.com>
8053
8054 * tree-vectorizer.h (vect_transform_stmt): Remove grouped_store
8055 argument.
8056 * tree-vect-stmts.c (vect_transform_stmt): Likewise.
8057 * tree-vect-loop.c (vect_transform_loop_stmt): Update call accordingly.
8058 (vect_transform_loop): Likewise.
8059 * tree-vect-slp.c (vect_schedule_slp_instance): Likewise.
8060
8061 2018-08-01 Richard Sandiford <richard.sandiford@arm.com>
8062
8063 * tree-vectorizer.h (vect_schedule_slp): Return void.
8064 * tree-vect-slp.c (vect_schedule_slp_instance): Likewise.
8065 (vect_schedule_slp): Likewise.
8066
8067 2018-08-01 Richard Sandiford <richard.sandiford@arm.com>
8068
8069 * tree-vect-loop.c (vect_transform_loop_stmt): Remove slp_scheduled
8070 argument.
8071 (vect_transform_loop): Update calls accordingly. Schedule SLP
8072 instances before the main loop, if any exist.
8073
8074 2018-08-01 Richard Sandiford <richard.sandiford@arm.com>
8075
8076 PR tree-optimization/86749
8077 * tree-vect-patterns.c (vect_determine_min_output_precision_1):
8078 If the lhs is used in a COND_EXPR, check that it is being used
8079 as the "then" or "else" value.
8080
8081 2018-08-01 Tom de Vries <tdevries@suse.de>
8082
8083 PR target/86800
8084 * config/nvptx/nvptx.c (TARGET_HAVE_SPECULATION_SAFE_VALUE): Define to
8085 speculation_safe_value_not_needed.
8086
8087 2018-08-01 Richard Biener <rguenther@suse.de>
8088
8089 * tree-ssa-sccvn.c (visit_phi): Compare invariant addresses
8090 as base and offset.
8091
8092 2018-08-01 Martin Liska <mliska@suse.cz>
8093
8094 * value-prof.c (gimple_divmod_fixed_value_transform): Unify
8095 format how successful transformation is dumped.
8096 (gimple_mod_pow2_value_transform): Likewise.
8097 (gimple_mod_subtract_transform): Likewise.
8098 (gimple_stringops_transform): Likewise.
8099
8100 2018-08-01 Martin Liska <mliska@suse.cz>
8101
8102 PR value-prof/35543
8103 * value-prof.c (interesting_stringop_to_profile_p):
8104 Simplify the code and add BUILT_IN_MEMMOVE.
8105 (gimple_stringops_transform): Likewise.
8106
8107 2018-08-01 Sam Tebbs <sam.tebbs@arm.com>
8108
8109 * config/aarch64/aarch64-simd.md
8110 (*aarch64_get_lane_zero_extendsi<mode>): Rename to...
8111 (*aarch64_get_lane_zero_extend<GPI:mode><VDQQH:mode>): ... This and
8112 use GPI iterator instead of SI mode.
8113
8114 2018-08-01 Richard Earnshaw <rearnsha@arm.com>
8115
8116 * config/rs6000/rs6000.md (speculation_barrier): Renamed from
8117 rs6000_speculation_barrier.
8118 * config/rs6000/rs6000.c (rs6000_expand_builtin): Adjust for
8119 new barrier pattern name.
8120
8121 2018-08-01 Richard Earnshaw <rearnsha@arm.com>
8122
8123 * config/i386/i386.md (unspecv): Add UNSPECV_SPECULATION_BARRIER.
8124 (speculation_barrier): New insn.
8125
8126 2018-08-01 Richard Biener <rguenther@suse.de>
8127
8128 PR bootstrap/86724
8129 * graphite.h: Include isl/id.h and isl/space.h to allow build
8130 with ISL 0.20.
8131
8132 2018-08-01 Jan Willem Jagersma <jwjagersma@gmail.com>
8133
8134 PR target/86651
8135 * dwarf2out.c (dwarf2out_early_finish): Do not generate assembly in LTO
8136 mode for COFF targets.
8137 * defaults.h (TARGET_COFF): Define.
8138 * config/i386/djgpp.h (TARGET_ASM_LTO_START, TARGET_ASM_LTO_END,
8139 TARGET_COFF): Define.
8140 (i386_djgpp_asm_lto_start, i386_djgpp_asm_lto_end): Declare.
8141 * config/i386/djgpp.c (saved_debug_info_level): New static variable.
8142 (i386_djgpp_asm_lto_start, i386_djgpp_asm_lto_end): New functions.
8143
8144 2018-07-31 Alexandre Oliva <oliva@adacore.com>
8145
8146 * gimple-streamer-in.c (input_bb): Restore BB discriminator.
8147 * gimple-streamer-out.c (output_bb): Save it.
8148 * lto-streamer-in.c (input_struct_function_base): Restore
8149 instance discriminator if available. Create map on demand.
8150 * lto-streamer-out.c (output_struct_function_base): Save it if
8151 available.
8152 * final.c (decl_to_instance_map): Document LTO strategy.
8153
8154 2018-07-31 Alexandre Oliva <oliva@adacore.com>
8155 Olivier Hainque <hainque@adacore.com>
8156
8157 * debug.h (decl_to_instance_map_t): New type.
8158 (decl_to_instance_map): Declare.
8159 (maybe_create_decl_to_instance_map): New inline function.
8160 * final.c (bb_discriminator, last_bb_discriminator): New statics,
8161 to track basic block discriminators.
8162 (final_start_function_1): Initialize them.
8163 (final_scan_insn_1): On NOTE_INSN_BASIC_BLOCK, track
8164 bb_discriminator.
8165 (decl_to_instance_map): New variable.
8166 (map_decl_to_instance, maybe_set_discriminator): New functions.
8167 (notice_source_line): Set discriminator.
8168
8169 2018-07-31 Ian Lance Taylor <iant@golang.org>
8170
8171 * targhooks.c (default_have_speculation_safe_value): Add
8172 ATTRIBUTE_UNUSED.
8173
8174 2018-07-31 David Malcolm <dmalcolm@redhat.com>
8175
8176 * dump-context.h: Include "pretty-print.h".
8177 (dump_context::refresh_dumps_are_enabled): New decl.
8178 (dump_context::emit_item): New decl.
8179 (class dump_context): Add fields "m_test_pp" and
8180 "m_test_pp_flags".
8181 (temp_dump_context::temp_dump_context): Add param "test_pp_flags".
8182 (temp_dump_context::get_dumped_text): New decl.
8183 (class temp_dump_context): Add field "m_pp".
8184 * dumpfile.c (refresh_dumps_are_enabled): Convert to...
8185 (dump_context::refresh_dumps_are_enabled): ...and add a test for
8186 m_test_pp.
8187 (set_dump_file): Update for above change.
8188 (set_alt_dump_file): Likewise.
8189 (dump_loc): New overload, taking a pretty_printer *.
8190 (dump_context::dump_loc): Call end_any_optinfo. Dump the location
8191 to any test pretty-printer.
8192 (make_item_for_dump_gimple_stmt): New function, adapted from
8193 optinfo::add_gimple_stmt.
8194 (dump_context::dump_gimple_stmt): Call it, and use the result,
8195 eliminating the direct usage of dump_file and alt_dump_file in
8196 favor of indirectly using them via emit_item.
8197 (make_item_for_dump_gimple_expr): New function, adapted from
8198 optinfo::add_gimple_expr.
8199 (dump_context::dump_gimple_expr): Call it, and use the result,
8200 eliminating the direct usage of dump_file and alt_dump_file in
8201 favor of indirectly using them via emit_item.
8202 (make_item_for_dump_generic_expr): New function, adapted from
8203 optinfo::add_tree.
8204 (dump_context::dump_generic_expr): Call it, and use the result,
8205 eliminating the direct usage of dump_file and alt_dump_file in
8206 favor of indirectly using them via emit_item.
8207 (make_item_for_dump_printf_va): New function, adapted from
8208 optinfo::add_printf_va.
8209 (make_item_for_dump_printf): New function.
8210 (dump_context::dump_printf_va): Call make_item_for_dump_printf_va,
8211 and use the result, eliminating the direct usage of dump_file and
8212 alt_dump_file in favor of indirectly using them via emit_item.
8213 (make_item_for_dump_dec): New function.
8214 (dump_context::dump_dec): Call it, and use the result,
8215 eliminating the direct usage of dump_file and alt_dump_file in
8216 favor of indirectly using them via emit_item.
8217 (make_item_for_dump_symtab_node): New function, adapted from
8218 optinfo::add_symtab_node.
8219 (dump_context::dump_symtab_node): Call it, and use the result,
8220 eliminating the direct usage of dump_file and alt_dump_file in
8221 favor of indirectly using them via emit_item.
8222 (dump_context::begin_scope): Reimplement, avoiding direct usage
8223 of dump_file and alt_dump_file in favor of indirectly using them
8224 via emit_item.
8225 (dump_context::emit_item): New member function.
8226 (temp_dump_context::temp_dump_context): Add param "test_pp_flags".
8227 Set up test pretty-printer on the underlying context. Call
8228 refresh_dumps_are_enabled.
8229 (temp_dump_context::~temp_dump_context): Call
8230 refresh_dumps_are_enabled.
8231 (temp_dump_context::get_dumped_text): New member function.
8232 (selftest::verify_dumped_text): New function.
8233 (ASSERT_DUMPED_TEXT_EQ): New macro.
8234 (selftest::test_capture_of_dump_calls): Run all tests twice, with
8235 and then without optinfo enabled. Add uses of
8236 ASSERT_DUMPED_TEXT_EQ to all tests. Add test of nested scopes.
8237 * dumpfile.h: Update comment for the dump_* API.
8238 * optinfo-emit-json.cc
8239 (selftest::test_building_json_from_dump_calls): Update for new
8240 param for temp_dump_context ctor.
8241 * optinfo.cc (optinfo_item::optinfo_item): Remove "owned" param
8242 and "m_owned" field.
8243 (optinfo_item::~optinfo_item): Likewise.
8244 (optinfo::add_item): New member function.
8245 (optinfo::emit): Update comment.
8246 (optinfo::add_string): Delete.
8247 (optinfo::add_printf): Delete.
8248 (optinfo::add_printf_va): Delete.
8249 (optinfo::add_gimple_stmt): Delete.
8250 (optinfo::add_gimple_expr): Delete.
8251 (optinfo::add_tree): Delete.
8252 (optinfo::add_symtab_node): Delete.
8253 (optinfo::add_dec): Delete.
8254 * optinfo.h (class dump_context): New forward decl.
8255 (optinfo::add_item): New decl.
8256 (optinfo::add_string): Delete.
8257 (optinfo::add_printf): Delete.
8258 (optinfo::add_printf_va): Delete.
8259 (optinfo::add_gimple_stmt): Delete.
8260 (optinfo::add_gimple_expr): Delete.
8261 (optinfo::add_tree): Delete.
8262 (optinfo::add_symtab_node): Delete.
8263 (optinfo::add_dec): Delete.
8264 (optinfo::add_poly_int): Delete.
8265 (optinfo_item::optinfo_item): Remove "owned" param.
8266 (class optinfo_item): Remove field "m_owned".
8267
8268 2018-07-31 Jozef Lawrynowicz <jozef.l@mittosystems.com>
8269
8270 PR middle-end/86705
8271 * gcc/cfgexpand.c (set_parm_rtl): Use the alignment of Pmode when
8272 MAX_SUPPORTED_STACK_ALIGNMENT would otherwise be exceeded by the
8273 requested variable alignment.
8274 (expand_one_ssa_partition): Likewise.
8275 (expand_one_var): Likewise.
8276
8277 2018-07-31 Richard Earnshaw <rearnsha@arm.com>
8278
8279 * config/pdp11/pdp11.c (TARGET_HAVE_SPECULATION_SAFE_VALUE): Redefine
8280 to speculation_safe_value_not_needed.
8281
8282 2018-07-31 Richard Earnshaw <rearnsha@arm.com>
8283
8284 * targhooks.h (speculation_safe_value_not_needed): New prototype.
8285 * targhooks.c (speculation_safe_value_not_needed): New function.
8286 * target.def (have_speculation_safe_value): Update documentation.
8287 * doc/tm.texi: Regenerated.
8288
8289 2018-07-31 Richard Earnshaw <rearnsha@arm.com>
8290
8291 * config/aarch64/iterators.md (ALLI_TI): New iterator.
8292 * config/aarch64/aarch64.md (despeculate_copy<ALLI_TI:mode>): New
8293 expand.
8294 (despeculate_copy<ALLI:mode>_insn): New insn.
8295 (despeculate_copyti_insn): New insn.
8296 (despeculate_simple<ALLI:mode>): New insn
8297 (despeculate_simpleti): New insn.
8298 * config/aarch64/aarch64.c (aarch64_speculation_safe_value): New
8299 function.
8300 (TARGET_SPECULATION_SAFE_VALUE): Redefine to
8301 aarch64_speculation_safe_value.
8302 (aarch64_print_operand): Handle const0_rtx in modifier 'H'.
8303
8304 2018-07-31 Richard Earnshaw <rearnsha@arm.com>
8305
8306 * config/aarch64/aarch64-speculation.cc: New file.
8307 * config/aarch64/aarch64-passes.def (pass_track_speculation): Add
8308 before pass_reorder_blocks.
8309 * config/aarch64/aarch64-protos.h (make_pass_track_speculation): Add
8310 prototype.
8311 * config/aarch64/aarch64.c (aarch64_conditional_register_usage): Fix
8312 X14 and X15 when tracking speculation.
8313 * config/aarch64/aarch64.md (register name constants): Add
8314 SPECULATION_TRACKER_REGNUM and SPECULATION_SCRATCH_REGNUM.
8315 (unspec): Add UNSPEC_SPECULATION_TRACKER.
8316 (speculation_barrier): New insn attribute.
8317 (cmp<mode>): Allow SP in comparisons.
8318 (speculation_tracker): New insn.
8319 (speculation_barrier): Add speculation_barrier attribute.
8320 * config/aarch64/t-aarch64: Add make rule for aarch64-speculation.o.
8321 * config.gcc (aarch64*-*-*): Add aarch64-speculation.o to extra_objs.
8322 * doc/invoke.texi (AArch64 Options): Document -mtrack-speculation.
8323
8324 2018-07-31 Richard Earnshaw <rearnsha@arm.com>
8325
8326 * config/aarch64/aarch64.md (cb<optab><mode>1): Disable when
8327 aarch64_track_speculation is true.
8328 (tb<optab><mode>1): Likewise.
8329 * config/aarch64/aarch64.c (aarch64_split_compare_regs): Do not
8330 generate CB[N]Z when tracking speculation.
8331 (aarch64_split_compare_and_swap): Likewise.
8332 (aarch64_split_atomic_op): Likewise.
8333
8334 2018-07-31 Richard Earnshaw <rearnsha@arm.com>
8335
8336 * config/aarch64/aarch64.opt (mtrack-speculation): New target option.
8337
8338 2018-07-31 Richard Earnshaw <rearnsha@arm.com>
8339
8340 * config/aarch64.md (unspecv): Add UNSPECV_SPECULAION_BARRIER.
8341 (speculation_barrier): New insn.
8342
8343 2018-07-31 Richard Earnshaw <rearnsha@arm.com>
8344
8345 * config/arm/unspecs.md (unspecv): Add VUNSPEC_SPECULATION_BARRIER.
8346 * config/arm/arm.md (speculation_barrier): New expand.
8347 (speculation_barrier_insn): New pattern.
8348
8349 2018-07-31 Richard Earnshaw <rearnsha@arm.com>
8350
8351 * builtin-types.def (BT_FN_PTR_PTR_VAR): New function type.
8352 (BT_FN_I1_I1_VAR, BT_FN_I2_I2_VAR, BT_FN_I4_I4_VAR): Likewise.
8353 (BT_FN_I8_I8_VAR, BT_FN_I16_I16_VAR): Likewise.
8354 * builtin-attrs.def (ATTR_NOVOPS_NOTHROW_LEAF_LIST): New attribute
8355 list.
8356 * builtins.def (BUILT_IN_SPECULATION_SAFE_VALUE_N): New builtin.
8357 (BUILT_IN_SPECULATION_SAFE_VALUE_PTR): New internal builtin.
8358 (BUILT_IN_SPECULATION_SAFE_VALUE_1): Likewise.
8359 (BUILT_IN_SPECULATION_SAFE_VALUE_2): Likewise.
8360 (BUILT_IN_SPECULATION_SAFE_VALUE_4): Likewise.
8361 (BUILT_IN_SPECULATION_SAFE_VALUE_8): Likewise.
8362 (BUILT_IN_SPECULATION_SAFE_VALUE_16): Likewise.
8363 * builtins.c (expand_speculation_safe_value): New function.
8364 (expand_builtin): Call it.
8365 * doc/cpp.texi: Document predefine __HAVE_SPECULATION_SAFE_VALUE.
8366 * doc/extend.texi: Document __builtin_speculation_safe_value.
8367 * doc/md.texi: Document "speculation_barrier" pattern.
8368 * doc/tm.texi.in: Pull in TARGET_SPECULATION_SAFE_VALUE and
8369 TARGET_HAVE_SPECULATION_SAFE_VALUE.
8370 * doc/tm.texi: Regenerated.
8371 * target.def (have_speculation_safe_value, speculation_safe_value): New
8372 hooks.
8373 * targhooks.c (default_have_speculation_safe_value): New function.
8374 (default_speculation_safe_value): New function.
8375 * targhooks.h (default_have_speculation_safe_value): Add prototype.
8376 (default_speculation_safe_value): Add prototype.
8377
8378 2018-07-31 David Malcolm <dmalcolm@redhat.com>
8379
8380 * dump-context.h (dump_context::dump_loc): New decl.
8381 * dumpfile.c (dump_context::dump_loc): New member function.
8382 (dump_context::dump_gimple_stmt_loc): Reimplement using dump_loc
8383 and dump_gimple_stmt.
8384 (dump_context::dump_gimple_expr_loc): Likewise, using
8385 dump_gimple_expr.
8386 (dump_context::dump_generic_expr_loc): Likewise, using
8387 dump_generic_expr.
8388 (dump_context::dump_printf_loc_va): Likewise, using
8389 dump_printf_va.
8390 (dump_context::begin_scope): Explicitly using the global function
8391 "dump_loc", rather than the member function.
8392
8393 2018-07-31 Martin Sebor <msebor@redhat.com>
8394
8395 PR tree-optimization/86741
8396 * tree-vrp.c (vrp_prop::check_mem_ref): Avoid incomplete types.
8397
8398 2018-07-31 Andreas Krebbel <krebbel@linux.ibm.com>
8399
8400 * config/s390/s390.c (s390_expand_setmem): Make the unrolling to
8401 depend on whether prefetch instructions will be emitted or not.
8402 Use TARGET_SETMEM_PFD for checking whether prefetch instructions
8403 will be emitted or not.
8404 * config/s390/s390.h (TARGET_SETMEM_PREFETCH_DISTANCE)
8405 (TARGET_SETMEM_PFD): New macros.
8406
8407 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
8408
8409 * tree-vectorizer.h (stmt_vec_info): Turn back into a typedef.
8410 (NULL_STMT_VEC_INFO): Delete.
8411 (stmt_vec_info::operator*): Likewise.
8412 (stmt_vec_info::operator gimple *): Likewise.
8413 * tree-vect-loop.c (vectorizable_reduction): Use NULL instead
8414 of NULL_STMT_VEC_INFO.
8415 * tree-vect-patterns.c (vect_init_pattern_stmt): Likewise.
8416 (vect_reassociating_reduction_p): Likewise.
8417 * tree-vect-stmts.c (vect_build_gather_load_calls): Likewise.
8418 (vectorizable_store): Likewise.
8419 * tree-vectorizer.c (vec_info::set_vinfo_for_stmt): Likewise.
8420 (vec_info::free_stmt_vec_infos): Likewise.
8421
8422 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
8423
8424 * tree-vectorizer.h (vect_stmt_in_region_p): Delete.
8425 * tree-vectorizer.c (vect_stmt_in_region_p): Likewise.
8426
8427 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
8428
8429 * tree-vectorizer.h (vec_info::new_vinfo_for_stmt)
8430 (vec_info::set_vinfo_for_stmt, vec_info::free_stmt_vec_infos)
8431 (vec_info::free_stmt_vec_info): New private member functions.
8432 (set_stmt_vec_info_vec, free_stmt_vec_infos, vinfo_for_stmt)
8433 (set_vinfo_for_stmt, new_stmt_vec_info, free_stmt_vec_info): Delete.
8434 * tree-parloops.c (gather_scalar_reductions): Remove calls to
8435 set_stmt_vec_info_vec and free_stmt_vec_infos.
8436 * tree-vect-loop.c (_loop_vec_info): Remove call to
8437 set_stmt_vec_info_vec.
8438 * tree-vect-stmts.c (new_stmt_vec_info, set_stmt_vec_info_vec)
8439 (free_stmt_vec_infos, free_stmt_vec_info): Delete in favor of...
8440 * tree-vectorizer.c (vec_info::new_stmt_vec_info)
8441 (vec_info::set_vinfo_for_stmt, vec_info::free_stmt_vec_infos)
8442 (vec_info::free_stmt_vec_info): ...these new functions. Remove
8443 assignments in {vec_info::,}new_stmt_vec_info that are redundant
8444 with the clearing in the xcalloc.
8445 (stmt_vec_info_vec): Delete.
8446 (vec_info::vec_info): Don't call set_stmt_vec_info_vec.
8447 (vectorize_loops): Likewise.
8448 (vec_info::~vec_info): Remove argument from call to
8449 free_stmt_vec_infos.
8450 (vec_info::add_stmt): Remove vinfo argument from call to
8451 new_stmt_vec_info.
8452
8453 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
8454
8455 * tree-vectorizer.h (free_stmt_vec_info): Take a stmt_vec_info
8456 rather than a gimple stmt.
8457 * tree-vect-stmts.c (free_stmt_vec_info): Likewise. Don't free
8458 information for pattern statements when passed the original
8459 statement; instead wait to be passed the pattern statement itself.
8460 Don't call set_vinfo_for_stmt here.
8461 (free_stmt_vec_infos): Update call to free_stmt_vec_info.
8462 * tree-vect-loop.c (_loop_vec_info::~loop_vec_info): Don't free
8463 stmt_vec_infos here.
8464 * tree-vect-slp.c (_bb_vec_info::~bb_vec_info): Likewise.
8465 * tree-vectorizer.c (vec_info::remove_stmt): Nullify the statement's
8466 stmt_vec_infos entry.
8467
8468 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
8469
8470 * tree-vectorizer.h (vec_info::replace_stmt): Declare.
8471 * tree-vectorizer.c (vec_info::replace_stmt): New function.
8472 * tree-vect-slp.c (vect_remove_slp_scalar_calls): Use it.
8473 * tree-vect-stmts.c (vectorizable_call): Likewise.
8474 (vectorizable_simd_clone_call): Likewise.
8475
8476 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
8477
8478 * tree-vectorizer.h (vec_info::remove_stmt): Declare.
8479 * tree-vectorizer.c (vec_info::remove_stmt): New function.
8480 * tree-vect-loop-manip.c (vect_set_loop_condition): Use it.
8481 * tree-vect-loop.c (vect_transform_loop): Likewise.
8482 * tree-vect-slp.c (vect_schedule_slp): Likewise.
8483 * tree-vect-stmts.c (vect_remove_stores): Likewise.
8484
8485 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
8486
8487 * tree-vectorizer.h (vec_info::lookup_dr): New member function.
8488 (vect_dr_stmt): Delete.
8489 * tree-vectorizer.c (vec_info::lookup_dr): New function.
8490 * tree-vect-loop-manip.c (vect_update_inits_of_drs): Use it instead
8491 of DR_VECT_AUX.
8492 * tree-vect-data-refs.c (vect_analyze_possibly_independent_ddr)
8493 (vect_analyze_data_ref_dependence, vect_record_base_alignments)
8494 (vect_verify_datarefs_alignment, vect_peeling_supportable)
8495 (vect_analyze_data_ref_accesses, vect_prune_runtime_alias_test_list)
8496 (vect_analyze_data_refs): Likewise.
8497 (vect_slp_analyze_data_ref_dependence): Likewise. Take a vec_info
8498 argument.
8499 (vect_find_same_alignment_drs): Likewise.
8500 (vect_slp_analyze_node_dependences): Update calls accordingly.
8501 (vect_analyze_data_refs_alignment): Likewise. Use vec_info::lookup_dr
8502 instead of DR_VECT_AUX.
8503 (vect_get_peeling_costs_all_drs): Take a loop_vec_info instead
8504 of a vector data references. Use vec_info::lookup_dr instead of
8505 DR_VECT_AUX.
8506 (vect_peeling_hash_get_lowest_cost): Update calls accordingly.
8507 (vect_enhance_data_refs_alignment): Likewise. Use vec_info::lookup_dr
8508 instead of DR_VECT_AUX.
8509
8510 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
8511
8512 * tree-vectorizer.h (_loop_vec_info::unaligned_dr): Change to
8513 dr_vec_info.
8514 * tree-vect-data-refs.c (vect_enhance_data_refs_alignment): Update
8515 accordingly.
8516 * tree-vect-loop.c (vect_analyze_loop_2): Likewise.
8517 * tree-vect-loop-manip.c (get_misalign_in_elems): Likewise.
8518 (vect_gen_prolog_loop_niters): Likewise.
8519
8520 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
8521
8522 * tree-vectorizer.h (set_dr_misalignment, dr_misalignment)
8523 (DR_TARGET_ALIGNMENT, aligned_access_p, known_alignment_for_access_p)
8524 (vect_known_alignment_in_bytes, vect_dr_behavior)
8525 (vect_get_scalar_dr_size): Take references as dr_vec_infos
8526 instead of data_references. Update calls to other routines for
8527 which the same change has been made.
8528 * tree-vect-data-refs.c (vect_preserves_scalar_order_p): Take
8529 dr_vec_infos instead of stmt_vec_infos.
8530 (vect_analyze_data_ref_dependence): Update call accordingly.
8531 (vect_slp_analyze_data_ref_dependence)
8532 (vect_record_base_alignments): Use DR_VECT_AUX.
8533 (vect_calculate_target_alignment, vect_compute_data_ref_alignment)
8534 (vect_update_misalignment_for_peel, verify_data_ref_alignment)
8535 (vector_alignment_reachable_p, vect_get_data_access_cost)
8536 (vect_peeling_supportable, vect_analyze_group_access_1)
8537 (vect_analyze_group_access, vect_analyze_data_ref_access)
8538 (vect_vfa_segment_size, vect_vfa_access_size, vect_vfa_align)
8539 (vect_compile_time_alias, vect_small_gap_p)
8540 (vectorizable_with_step_bound_p, vect_duplicate_ssa_name_ptr_info):
8541 (vect_supportable_dr_alignment): Take references as dr_vec_infos
8542 instead of data_references. Update calls to other routines for
8543 which the same change has been made.
8544 (vect_verify_datarefs_alignment, vect_get_peeling_costs_all_drs)
8545 (vect_find_same_alignment_drs, vect_analyze_data_refs_alignment)
8546 (vect_slp_analyze_and_verify_node_alignment)
8547 (vect_analyze_data_ref_accesses, vect_prune_runtime_alias_test_list)
8548 (vect_create_addr_base_for_vector_ref, vect_create_data_ref_ptr)
8549 (vect_setup_realignment): Use dr_vec_infos. Update calls after
8550 above changes.
8551 (_vect_peel_info::dr): Replace with...
8552 (_vect_peel_info::dr_info): ...this new field.
8553 (vect_peeling_hash_get_most_frequent)
8554 (vect_peeling_hash_choose_best_peeling): Update accordingly.
8555 (vect_peeling_hash_get_lowest_cost):
8556 (vect_enhance_data_refs_alignment): Likewise. Update calls to other
8557 routines for which the same change has been made.
8558 (vect_peeling_hash_insert): Likewise. Take a dr_vec_info instead of a
8559 data_reference.
8560 * tree-vect-loop-manip.c (get_misalign_in_elems)
8561 (vect_gen_prolog_loop_niters): Use dr_vec_infos. Update calls after
8562 above changes.
8563 * tree-vect-loop.c (vect_analyze_loop_2): Likewise.
8564 * tree-vect-stmts.c (vect_get_store_cost, vect_get_load_cost)
8565 (vect_truncate_gather_scatter_offset, compare_step_with_zero)
8566 (get_group_load_store_type, get_negative_load_store_type)
8567 (vect_get_data_ptr_increment, vectorizable_store)
8568 (vectorizable_load): Likewise.
8569 (ensure_base_align): Take a dr_vec_info instead of a data_reference.
8570 Update calls to other routines for which the same change has been made.
8571
8572 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
8573
8574 * tree-vectorizer.h (vec_info::move_dr): New member function.
8575 (dataref_aux): Rename to...
8576 (dr_vec_info): ...this and add "dr" and "stmt" fields.
8577 (_stmt_vec_info::dr_aux): Update accordingly.
8578 (_stmt_vec_info::data_ref_info): Delete.
8579 (STMT_VINFO_GROUPED_ACCESS, DR_GROUP_FIRST_ELEMENT)
8580 (DR_GROUP_NEXT_ELEMENT, DR_GROUP_SIZE, DR_GROUP_STORE_COUNT)
8581 (DR_GROUP_GAP, DR_GROUP_SAME_DR_STMT, REDUC_GROUP_FIRST_ELEMENT):
8582 (REDUC_GROUP_NEXT_ELEMENT, REDUC_GROUP_SIZE): Use dr_aux.dr instead
8583 of data_ref.
8584 (STMT_VINFO_DATA_REF): Likewise. Turn into an lvalue.
8585 (STMT_VINFO_DR_INFO): New macro.
8586 (DR_VECT_AUX): Use STMT_VINFO_DR_INKFO and vect_dr_stmt.
8587 (set_dr_misalignment): Update after rename of dataref_aux.
8588 (vect_dr_stmt): Move earlier in file. Return dr_aux.stmt.
8589 * tree-vect-stmts.c (new_stmt_vec_info): Remove redundant
8590 initialization of STMT_VINFO_DATA_REF.
8591 * tree-vectorizer.c (vec_info::move_dr): New function.
8592 * tree-vect-patterns.c (vect_recog_bool_pattern)
8593 (vect_recog_mask_conversion_pattern)
8594 (vect_recog_gather_scatter_pattern): Use it.
8595 * tree-vect-data-refs.c (vect_analyze_data_refs): Initialize
8596 the "dr" and "stmt" fields of dr_vec_info instead of
8597 STMT_VINFO_DATA_REF.
8598
8599 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
8600
8601 * tree-vectorizer.h (_stmt_vec_info::pattern_stmt_p): New field.
8602 (is_pattern_stmt_p): Use it.
8603 * tree-vect-patterns.c (vect_init_pattern_stmt): Set pattern_stmt_p
8604 on pattern statements.
8605
8606 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
8607
8608 * tree-vect-patterns.c (vect_mark_pattern_stmts): Take the
8609 original stmt as a stmt_vec_info rather than a gimple stmt.
8610 (vect_pattern_recog_1): Take the statement directly as a
8611 stmt_vec_info, rather than via a gimple_stmt_iterator.
8612 Update call to vect_mark_pattern_stmts.
8613 (vect_pattern_recog): Update calls accordingly.
8614
8615 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
8616
8617 * tree-vectorizer.h (vect_get_vec_defs_for_stmt_copy)
8618 (vect_get_vec_def_for_stmt_copy): Take a vec_info rather than
8619 a vect_def_type for the first argument.
8620 * tree-vect-stmts.c (vect_get_vec_defs_for_stmt_copy): Likewise.
8621 (vect_get_vec_def_for_stmt_copy): Likewise. Return the original
8622 operand if it isn't defined by a vectorized statement.
8623 (vect_build_gather_load_calls): Remove the mask_dt argument and
8624 update calls to vect_get_vec_def_for_stmt_copy.
8625 (vectorizable_bswap): Likewise the dt argument.
8626 (vectorizable_call): Update calls to vectorizable_bswap and
8627 vect_get_vec_def_for_stmt_copy.
8628 (vectorizable_simd_clone_call, vectorizable_assignment)
8629 (vectorizable_shift, vectorizable_operation, vectorizable_condition)
8630 (vectorizable_comparison): Update calls to
8631 vect_get_vec_def_for_stmt_copy.
8632 (vectorizable_store): Likewise. Remove now-unnecessary calls to
8633 vect_is_simple_use.
8634 (vect_get_loop_based_defs): Remove dt argument and update call
8635 to vect_get_vec_def_for_stmt_copy.
8636 (vectorizable_conversion): Update calls to vect_get_loop_based_defs
8637 and vect_get_vec_def_for_stmt_copy.
8638 (vectorizable_load): Update calls to vect_build_gather_load_calls
8639 and vect_get_vec_def_for_stmt_copy.
8640 * tree-vect-loop.c (vect_create_epilog_for_reduction)
8641 (vectorizable_reduction, vectorizable_live_operation): Update calls
8642 to vect_get_vec_def_for_stmt_copy.
8643
8644 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
8645
8646 * tree-vect-data-refs.c (vect_record_base_alignment): Replace vec_info
8647 and gimple stmt arguments with a stmt_vec_info.
8648 (vect_record_base_alignments): Update calls accordingly.
8649 * tree-vect-slp.c (vect_record_max_nunits): Replace vec_info
8650 and gimple stmt arguments with a stmt_vec_info.
8651 (vect_build_slp_tree_1): Remove vinfo argument and update call
8652 to vect_record_max_nunits.
8653 (vect_build_slp_tree_2): Update calls to vect_build_slp_tree_1
8654 and vect_record_max_nunits.
8655
8656 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
8657
8658 * tree-vectorizer.h (nested_in_vect_loop_p): Move further down
8659 file and take a stmt_vec_info instead of a gimple stmt.
8660 (supportable_widening_operation, vect_finish_replace_stmt)
8661 (vect_finish_stmt_generation, vect_get_store_rhs)
8662 (vect_get_vec_def_for_operand_1, vect_get_vec_def_for_operand)
8663 (vect_get_vec_defs, vect_init_vector, vect_transform_stmt)
8664 (vect_remove_stores, vect_analyze_stmt, vectorizable_condition)
8665 (vect_get_smallest_scalar_type, vect_check_gather_scatter)
8666 (vect_create_data_ref_ptr, bump_vector_ptr)
8667 (vect_permute_store_chain, vect_setup_realignment)
8668 (vect_transform_grouped_load, vect_record_grouped_load_vectors)
8669 (vect_create_addr_base_for_vector_ref, vectorizable_live_operation)
8670 (vectorizable_reduction, vectorizable_induction)
8671 (get_initial_def_for_reduction, is_simple_and_all_uses_invariant)
8672 (vect_get_place_in_interleaving_chain): Take stmt_vec_infos rather
8673 than gimple stmts as arguments.
8674 * tree-vect-data-refs.c (vect_get_smallest_scalar_type)
8675 (vect_preserves_scalar_order_p, vect_slp_analyze_node_dependences)
8676 (can_group_stmts_p, vect_check_gather_scatter)
8677 (vect_create_addr_base_for_vector_ref, vect_create_data_ref_ptr)
8678 (bump_vector_ptr, vect_permute_store_chain, vect_setup_realignment)
8679 (vect_permute_load_chain, vect_shift_permute_load_chain)
8680 (vect_transform_grouped_load)
8681 (vect_record_grouped_load_vectors): Likewise.
8682 * tree-vect-loop.c (vect_fixup_reduc_chain)
8683 (get_initial_def_for_reduction, vect_create_epilog_for_reduction)
8684 (vectorize_fold_left_reduction, is_nonwrapping_integer_induction)
8685 (vectorizable_reduction, vectorizable_induction)
8686 (vectorizable_live_operation, vect_loop_kill_debug_uses): Likewise.
8687 * tree-vect-patterns.c (type_conversion_p, adjust_bool_stmts)
8688 (vect_get_load_store_mask): Likewise.
8689 * tree-vect-slp.c (vect_get_place_in_interleaving_chain)
8690 (vect_analyze_slp_instance, vect_mask_constant_operand_p): Likewise.
8691 * tree-vect-stmts.c (vect_mark_relevant)
8692 (is_simple_and_all_uses_invariant)
8693 (exist_non_indexing_operands_for_use_p, process_use)
8694 (vect_init_vector_1, vect_init_vector, vect_get_vec_def_for_operand_1)
8695 (vect_get_vec_def_for_operand, vect_get_vec_defs)
8696 (vect_finish_stmt_generation_1, vect_finish_replace_stmt)
8697 (vect_finish_stmt_generation, vect_truncate_gather_scatter_offset)
8698 (compare_step_with_zero, vect_get_store_rhs, get_group_load_store_type)
8699 (get_negative_load_store_type, get_load_store_type)
8700 (vect_check_load_store_mask, vect_check_store_rhs)
8701 (vect_build_gather_load_calls, vect_get_strided_load_store_ops)
8702 (vectorizable_bswap, vectorizable_call, vectorizable_simd_clone_call)
8703 (vect_create_vectorized_demotion_stmts, vectorizable_conversion)
8704 (vectorizable_assignment, vectorizable_shift, vectorizable_operation)
8705 (get_group_alias_ptr_type, vectorizable_store, hoist_defs_of_uses)
8706 (vectorizable_load, vectorizable_condition, vectorizable_comparison)
8707 (vect_analyze_stmt, vect_transform_stmt, vect_remove_stores)
8708 (supportable_widening_operation): Likewise.
8709
8710 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
8711
8712 * tree-vect-data-refs.c (vect_describe_gather_scatter_call): Take
8713 a stmt_vec_info instead of a gcall.
8714 (vect_check_gather_scatter): Update call accordingly.
8715 * tree-vect-loop-manip.c (iv_phi_p): Take a stmt_vec_info instead
8716 of a gphi.
8717 (vect_can_advance_ivs_p, vect_update_ivs_after_vectorizer)
8718 (slpeel_update_phi_nodes_for_loops):): Update calls accordingly.
8719 * tree-vect-loop.c (vect_transform_loop_stmt): Take a stmt_vec_info
8720 instead of a gimple stmt.
8721 (vect_transform_loop): Update calls accordingly.
8722 * tree-vect-slp.c (vect_split_slp_store_group): Take and return
8723 stmt_vec_infos instead of gimple stmts.
8724 (vect_analyze_slp_instance): Update use accordingly.
8725 * tree-vect-stmts.c (read_vector_array, write_vector_array)
8726 (vect_clobber_variable, vect_stmt_relevant_p, permute_vec_elements)
8727 (vect_use_strided_gather_scatters_p, vect_build_all_ones_mask)
8728 (vect_build_zero_merge_argument, vect_get_gather_scatter_ops)
8729 (vect_gen_widened_results_half, vect_get_loop_based_defs)
8730 (vect_create_vectorized_promotion_stmts, can_vectorize_live_stmts):
8731 Take a stmt_vec_info instead of a gimple stmt and pass stmt_vec_infos
8732 down to subroutines.
8733
8734 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
8735
8736 * tree-vect-loop.c (vect_analyze_scalar_cycles_1): Change the type
8737 of the worklist from a vector of gimple stmts to a vector of
8738 stmt_vec_infos.
8739 * tree-vect-stmts.c (vect_mark_relevant, process_use)
8740 (vect_mark_stmts_to_be_vectorized): Likewise
8741
8742 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
8743
8744 * tree-vect-loop.c (vect_analyze_loop_operations): Look up the
8745 statement before passing it to vect_analyze_stmt.
8746 (vect_create_epilog_for_reduction): Use a stmt_vec_info to walk
8747 the chain of phi vector definitions. Track the exit phi via its
8748 stmt_vec_info.
8749 (vectorizable_reduction): Set cond_stmt_vinfo directly from the
8750 STMT_VINFO_REDUC_DEF.
8751 * tree-vect-slp.c (vect_get_place_in_interleaving_chain): Use
8752 stmt_vec_infos to handle the statement chains.
8753 (vect_get_slp_defs): Record the first statement in the node
8754 using a stmt_vec_info.
8755 * tree-vect-stmts.c (vect_mark_stmts_to_be_vectorized): Look up
8756 statements here and pass their stmt_vec_info down to subroutines.
8757 (vect_init_vector_1): Hoist call to vinfo_for_stmt and pass it
8758 down to vect_finish_stmt_generation.
8759 (vect_init_vector, vect_get_vec_defs, vect_finish_replace_stmt)
8760 (vect_finish_stmt_generation): Call vinfo_for_stmt and pass
8761 stmt_vec_infos to subroutines.
8762 (vect_remove_stores): Use stmt_vec_infos to handle the statement
8763 chains.
8764
8765 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
8766
8767 * tree-vect-data-refs.c (vect_slp_analyze_node_dependences):
8768 (vect_check_gather_scatter, vect_create_data_ref_ptr, bump_vector_ptr)
8769 (vect_permute_store_chain, vect_setup_realignment)
8770 (vect_permute_load_chain, vect_shift_permute_load_chain)
8771 (vect_transform_grouped_load): Use stmt_vec_info rather than gimple
8772 stmts internally, and when passing values to other vectorizer routines.
8773 * tree-vect-loop-manip.c (vect_can_advance_ivs_p): Likewise.
8774 * tree-vect-loop.c (vect_analyze_scalar_cycles_1)
8775 (vect_analyze_loop_operations, get_initial_def_for_reduction)
8776 (vect_create_epilog_for_reduction, vectorize_fold_left_reduction)
8777 (vectorizable_reduction, vectorizable_induction)
8778 (vectorizable_live_operation, vect_transform_loop_stmt)
8779 (vect_transform_loop): Likewise.
8780 * tree-vect-patterns.c (vect_reassociating_reduction_p)
8781 (vect_recog_widen_op_pattern, vect_recog_mixed_size_cond_pattern)
8782 (vect_recog_bool_pattern, vect_recog_gather_scatter_pattern): Likewise.
8783 * tree-vect-slp.c (vect_analyze_slp_instance): Likewise.
8784 (vect_slp_analyze_node_operations_1): Likewise.
8785 * tree-vect-stmts.c (vect_mark_relevant, process_use)
8786 (exist_non_indexing_operands_for_use_p, vect_init_vector_1)
8787 (vect_mark_stmts_to_be_vectorized, vect_get_vec_def_for_operand)
8788 (vect_finish_stmt_generation_1, get_group_load_store_type)
8789 (get_load_store_type, vect_build_gather_load_calls)
8790 (vectorizable_bswap, vectorizable_call, vectorizable_simd_clone_call)
8791 (vect_create_vectorized_demotion_stmts, vectorizable_conversion)
8792 (vectorizable_assignment, vectorizable_shift, vectorizable_operation)
8793 (vectorizable_store, vectorizable_load, vectorizable_condition)
8794 (vectorizable_comparison, vect_analyze_stmt, vect_transform_stmt)
8795 (supportable_widening_operation): Likewise.
8796 (vect_get_vector_types_for_stmt): Likewise.
8797 * tree-vectorizer.h (vect_dr_behavior): Likewise.
8798
8799 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
8800
8801 * tree-vect-data-refs.c (vect_analyze_data_ref_dependence)
8802 (vect_slp_analyze_node_dependences, vect_analyze_data_ref_accesses)
8803 (vect_permute_store_chain, vect_permute_load_chain)
8804 (vect_shift_permute_load_chain, vect_transform_grouped_load): Avoid
8805 repeated stmt_vec_info lookups.
8806 * tree-vect-loop-manip.c (vect_can_advance_ivs_p): Likewise.
8807 (vect_update_ivs_after_vectorizer): Likewise.
8808 * tree-vect-loop.c (vect_is_simple_reduction): Likewise.
8809 (vect_create_epilog_for_reduction, vectorizable_reduction): Likewise.
8810 * tree-vect-patterns.c (adjust_bool_stmts): Likewise.
8811 * tree-vect-slp.c (vect_analyze_slp_instance): Likewise.
8812 (vect_bb_slp_scalar_cost): Likewise.
8813 * tree-vect-stmts.c (get_group_alias_ptr_type): Likewise.
8814
8815 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
8816
8817 * tree-vect-data-refs.c (vect_check_gather_scatter): Pass the
8818 gcall rather than the generic gimple stmt to gimple_call_internal_fn.
8819 (vect_get_smallest_scalar_type, can_group_stmts_p): Use dyn_cast
8820 to get gassigns and gcalls, rather than operating on generc gimple
8821 stmts.
8822 * tree-vect-stmts.c (exist_non_indexing_operands_for_use_p)
8823 (vect_mark_stmts_to_be_vectorized, vectorizable_store)
8824 (vectorizable_load, vect_analyze_stmt): Likewise.
8825 * tree-vect-loop.c (vectorizable_reduction): Likewise gphi.
8826
8827 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
8828
8829 * tree-vectorizer.h (get_earlier_stmt, get_later_stmt): Take and
8830 return stmt_vec_infos rather than gimple stmts. Do not accept
8831 null arguments.
8832 (vect_find_last_scalar_stmt_in_slp): Return a stmt_vec_info instead
8833 of a gimple stmt.
8834 * tree-vect-slp.c (vect_find_last_scalar_stmt_in_slp): Likewise.
8835 Update use of get_later_stmt.
8836 (vect_get_constant_vectors): Update call accordingly.
8837 (vect_schedule_slp_instance): Likewise
8838 * tree-vect-data-refs.c (vect_slp_analyze_node_dependences): Likewise.
8839 (vect_slp_analyze_instance_dependence): Likewise.
8840 (vect_preserves_scalar_order_p): Update use of get_earlier_stmt.
8841
8842 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
8843
8844 * tree-vectorizer.h (stmt_info_for_cost::stmt): Replace with...
8845 (stmt_info_for_cost::stmt_info): ...this new field.
8846 (add_stmt_costs): Update accordingly.
8847 * tree-vect-loop.c (vect_compute_single_scalar_iteration_cost)
8848 (vect_get_known_peeling_cost): Likewise.
8849 (vect_estimate_min_profitable_iters): Likewise.
8850 * tree-vect-stmts.c (record_stmt_cost): Likewise.
8851
8852 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
8853
8854 * tree-vectorizer.h (_loop_vec_info::may_misalign_stmts): Change
8855 from an auto_vec<gimple *> to an auto_vec<stmt_vec_info>.
8856 * tree-vect-data-refs.c (vect_enhance_data_refs_alignment): Update
8857 accordingly.
8858 * tree-vect-loop-manip.c (vect_create_cond_for_align_checks): Likewise.
8859
8860 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
8861
8862 * tree-vectorizer.h (_stmt_vec_info::same_dr_stmt): Change from
8863 a gimple stmt to a stmt_vec_info.
8864 * tree-vect-stmts.c (vectorizable_load): Update accordingly.
8865
8866 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
8867
8868 * tree-vectorizer.h (vec_info::grouped_stores): Change from
8869 an auto_vec<gimple *> to an auto_vec<stmt_vec_info>.
8870 (_loop_vec_info::reduction_chains): Likewise.
8871 * tree-vect-loop.c (vect_fixup_scalar_cycles_with_patterns): Update
8872 accordingly.
8873 * tree-vect-slp.c (vect_analyze_slp): Likewise.
8874
8875 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
8876
8877 * tree-vectorizer.h (_stmt_vec_info::first_element): Change from
8878 a gimple stmt to a stmt_vec_info.
8879 (_stmt_vec_info::next_element): Likewise.
8880 * tree-vect-data-refs.c (vect_update_misalignment_for_peel)
8881 (vect_slp_analyze_and_verify_node_alignment)
8882 (vect_analyze_group_access_1, vect_analyze_group_access)
8883 (vect_small_gap_p, vect_prune_runtime_alias_test_list)
8884 (vect_create_data_ref_ptr, vect_record_grouped_load_vectors)
8885 (vect_supportable_dr_alignment): Update accordingly.
8886 * tree-vect-loop.c (vect_fixup_reduc_chain): Likewise.
8887 (vect_fixup_scalar_cycles_with_patterns, vect_is_slp_reduction)
8888 (vect_is_simple_reduction, vectorizable_reduction): Likewise.
8889 * tree-vect-patterns.c (vect_reassociating_reduction_p): Likewise.
8890 * tree-vect-slp.c (vect_build_slp_tree_1)
8891 (vect_attempt_slp_rearrange_stmts, vect_supported_load_permutation_p)
8892 (vect_split_slp_store_group, vect_analyze_slp_instance)
8893 (vect_analyze_slp, vect_transform_slp_perm_load): Likewise.
8894 * tree-vect-stmts.c (vect_model_store_cost, vect_model_load_cost)
8895 (get_group_load_store_type, get_load_store_type)
8896 (get_group_alias_ptr_type, vectorizable_store, vectorizable_load)
8897 (vect_transform_stmt, vect_remove_stores): Likewise.
8898
8899 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
8900
8901 * tree-vectorizer.h (vect_dr_stmt): Return a stmt_vec_info rather
8902 than a gimple stmt.
8903 * tree-vect-data-refs.c (vect_analyze_data_ref_dependence)
8904 (vect_slp_analyze_data_ref_dependence, vect_record_base_alignments)
8905 (vect_calculate_target_alignmentm, vect_compute_data_ref_alignment)
8906 (vect_update_misalignment_for_peel, vect_verify_datarefs_alignment)
8907 (vector_alignment_reachable_p, vect_get_data_access_cost)
8908 (vect_get_peeling_costs_all_drs, vect_peeling_hash_get_lowest_cost)
8909 (vect_peeling_supportable, vect_enhance_data_refs_alignment)
8910 (vect_find_same_alignment_drs, vect_analyze_data_refs_alignment)
8911 (vect_analyze_group_access_1, vect_analyze_group_access)
8912 (vect_analyze_data_ref_access, vect_analyze_data_ref_accesses)
8913 (vect_vfa_access_size, vect_small_gap_p, vect_analyze_data_refs)
8914 (vect_supportable_dr_alignment): Remove vinfo_for_stmt from the
8915 result of vect_dr_stmt and use the stmt_vec_info instead of
8916 the associated gimple stmt.
8917 * tree-vect-loop-manip.c (get_misalign_in_elems): Likewise.
8918 (vect_gen_prolog_loop_niters): Likewise.
8919 * tree-vect-loop.c (vect_analyze_loop_2): Likewise.
8920
8921 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
8922
8923 * tree-vectorizer.h (_slp_tree::stmts): Change from a vec<gimple *>
8924 to a vec<stmt_vec_info>.
8925 * tree-vect-slp.c (vect_free_slp_tree): Update accordingly.
8926 (vect_create_new_slp_node): Take a vec<gimple *> instead of a
8927 vec<stmt_vec_info>.
8928 (_slp_oprnd_info::def_stmts): Change from a vec<gimple *>
8929 to a vec<stmt_vec_info>.
8930 (bst_traits::value_type, bst_traits::value_type): Likewise.
8931 (bst_traits::hash): Update accordingly.
8932 (vect_get_and_check_slp_defs): Change the stmts parameter from
8933 a vec<gimple *> to a vec<stmt_vec_info>.
8934 (vect_two_operations_perm_ok_p, vect_build_slp_tree_1): Likewise.
8935 (vect_build_slp_tree): Likewise.
8936 (vect_build_slp_tree_2): Likewise. Update uses of
8937 SLP_TREE_SCALAR_STMTS.
8938 (vect_print_slp_tree): Update uses of SLP_TREE_SCALAR_STMTS.
8939 (vect_mark_slp_stmts, vect_mark_slp_stmts_relevant)
8940 (vect_slp_rearrange_stmts, vect_attempt_slp_rearrange_stmts)
8941 (vect_supported_load_permutation_p, vect_find_last_scalar_stmt_in_slp)
8942 (vect_detect_hybrid_slp_stmts, vect_slp_analyze_node_operations_1)
8943 (vect_slp_analyze_node_operations, vect_slp_analyze_operations)
8944 (vect_bb_slp_scalar_cost, vect_slp_analyze_bb_1)
8945 (vect_get_constant_vectors, vect_get_slp_defs)
8946 (vect_transform_slp_perm_load, vect_schedule_slp_instance)
8947 (vect_remove_slp_scalar_calls, vect_schedule_slp): Likewise.
8948 (vect_analyze_slp_instance): Build up a vec of stmt_vec_infos
8949 instead of gimple stmts.
8950 * tree-vect-data-refs.c (vect_slp_analyze_node_dependences): Change
8951 the stores parameter for a vec<gimple *> to a vec<stmt_vec_info>.
8952 (vect_slp_analyze_instance_dependence): Update uses of
8953 SLP_TREE_SCALAR_STMTS.
8954 (vect_slp_analyze_and_verify_node_alignment): Likewise.
8955 (vect_slp_analyze_and_verify_instance_alignment): Likewise.
8956 * tree-vect-loop.c (neutral_op_for_slp_reduction): Likewise.
8957 (get_initial_defs_for_reduction): Likewise.
8958 (vect_create_epilog_for_reduction): Likewise.
8959 (vectorize_fold_left_reduction): Likewise.
8960 * tree-vect-stmts.c (vect_prologue_cost_for_slp_op): Likewise.
8961 (vect_model_simple_cost, vectorizable_shift, vectorizable_load)
8962 (can_vectorize_live_stmts): Likewise.
8963
8964 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
8965
8966 * tree-vectorizer.h (_loop_vec_info::reductions): Change from an
8967 auto_vec<gimple *> to an auto_vec<stmt_vec_info>.
8968 (vect_force_simple_reduction): Take and return stmt_vec_infos rather
8969 than gimple stmts.
8970 * tree-parloops.c (valid_reduction_p): Take a stmt_vec_info instead
8971 of a gimple stmt.
8972 (gather_scalar_reductions): Update after above interface changes.
8973 * tree-vect-loop.c (vect_analyze_scalar_cycles_1): Likewise.
8974 (vect_is_simple_reduction): Take and return stmt_vec_infos rather
8975 than gimple stmts.
8976 (vect_force_simple_reduction): Likewise.
8977 * tree-vect-patterns.c (vect_pattern_recog_1): Update use of
8978 LOOP_VINFO_REDUCTIONS.
8979 * tree-vect-slp.c (vect_analyze_slp_instance): Likewise.
8980
8981 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
8982
8983 * tree-vectorizer.h (_stmt_vec_info::reduc_def): Change from
8984 a gimple stmt to a stmt_vec_info.
8985 * tree-vect-loop.c (vect_active_double_reduction_p)
8986 (vect_force_simple_reduction, vectorizable_reduction): Update
8987 accordingly.
8988
8989 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
8990
8991 * tree-vectorizer.h (_slp_tree::vec_stmts): Change from a
8992 vec<gimple *> to a vec<stmt_vec_info>.
8993 * tree-vect-loop.c (vect_create_epilog_for_reduction): Change
8994 the reduction_phis argument from a vec<gimple *> to a
8995 vec<stmt_vec_info>.
8996 (vectorizable_reduction): Likewise the phis local variable that
8997 is passed to vect_create_epilog_for_reduction. Update for new type
8998 of SLP_TREE_VEC_STMTS.
8999 (vectorizable_induction): Update for new type of SLP_TREE_VEC_STMTS.
9000 (vectorizable_live_operation): Likewise.
9001 * tree-vect-slp.c (vect_get_slp_vect_defs): Likewise.
9002 (vect_transform_slp_perm_load, vect_schedule_slp_instance): Likewise.
9003
9004 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
9005
9006 * tree-vectorizer.h (_stmt_vec_info::vectorized_stmt): Change from
9007 a gimple stmt to a stmt_vec_info.
9008 (vectorizable_condition, vectorizable_live_operation)
9009 (vectorizable_reduction, vectorizable_induction): Pass back the
9010 vectorized statement as a stmt_vec_info.
9011 * tree-vect-data-refs.c (vect_record_grouped_load_vectors): Update
9012 use of STMT_VINFO_VEC_STMT.
9013 * tree-vect-loop.c (vect_create_epilog_for_reduction): Likewise,
9014 accumulating the inner phis that feed the STMT_VINFO_VEC_STMT
9015 as stmt_vec_infos rather than gimple stmts.
9016 (vectorize_fold_left_reduction): Change vec_stmt from a gimple stmt
9017 to a stmt_vec_info.
9018 (vectorizable_live_operation): Likewise.
9019 (vectorizable_reduction, vectorizable_induction): Likewise,
9020 updating use of STMT_VINFO_VEC_STMT.
9021 * tree-vect-stmts.c (vect_get_vec_def_for_operand_1): Update use
9022 of STMT_VINFO_VEC_STMT.
9023 (vect_build_gather_load_calls, vectorizable_bswap, vectorizable_call)
9024 (vectorizable_simd_clone_call, vectorizable_conversion)
9025 (vectorizable_assignment, vectorizable_shift, vectorizable_operation)
9026 (vectorizable_store, vectorizable_load, vectorizable_condition)
9027 (vectorizable_comparison, can_vectorize_live_stmts): Change vec_stmt
9028 from a gimple stmt to a stmt_vec_info.
9029 (vect_transform_stmt): Update use of STMT_VINFO_VEC_STMT. Pass a
9030 pointer to a stmt_vec_info to the vectorizable_* routines.
9031
9032 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
9033
9034 * tree-vectorizer.h (_stmt_vec_info::related_stmt): Change from
9035 a gimple stmt to a stmt_vec_info.
9036 (is_pattern_stmt_p): Update accordingly.
9037 * tree-vect-data-refs.c (vect_preserves_scalar_order_p): Likewise.
9038 (vect_record_grouped_load_vectors): Likewise.
9039 * tree-vect-loop.c (vect_determine_vf_for_stmt): Likewise.
9040 (vect_fixup_reduc_chain, vect_update_vf_for_slp): Likewise.
9041 (vect_model_reduction_cost): Likewise.
9042 (vect_create_epilog_for_reduction): Likewise.
9043 (vectorizable_reduction, vectorizable_induction): Likewise.
9044 * tree-vect-patterns.c (vect_init_pattern_stmt): Likewise.
9045 Return the stmt_vec_info for the pattern statement.
9046 (vect_set_pattern_stmt): Update use of STMT_VINFO_RELATED_STMT.
9047 (vect_split_statement, vect_mark_pattern_stmts): Likewise.
9048 * tree-vect-slp.c (vect_detect_hybrid_slp_stmts): Likewise.
9049 (vect_detect_hybrid_slp, vect_get_slp_defs): Likewise.
9050 * tree-vect-stmts.c (vect_mark_relevant): Likewise.
9051 (vect_get_vec_def_for_operand_1, vectorizable_call): Likewise.
9052 (vectorizable_simd_clone_call, vect_analyze_stmt, new_stmt_vec_info)
9053 (free_stmt_vec_info, vect_is_simple_use): Likewise.
9054
9055 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
9056
9057 * tree-vectorizer.h (vect_finish_replace_stmt): Return a stmt_vec_info
9058 (vect_finish_stmt_generation): Likewise.
9059 * tree-vect-stmts.c (vect_finish_stmt_generation_1): Likewise.
9060 (vect_finish_replace_stmt, vect_finish_stmt_generation): Likewise.
9061 (vect_build_gather_load_calls): Use the return value of the above
9062 functions instead of a separate call to vinfo_for_stmt. Use narrow
9063 scopes for the input gimple stmt and wider scopes for the associated
9064 stmt_vec_info. Use vec_info::lookup_def when setting these
9065 stmt_vec_infos from an SSA_NAME definition.
9066 (vectorizable_bswap, vectorizable_call, vectorizable_simd_clone_call)
9067 (vect_create_vectorized_demotion_stmts, vectorizable_conversion)
9068 (vectorizable_assignment, vectorizable_shift, vectorizable_operation)
9069 (vectorizable_store, vectorizable_load, vectorizable_condition)
9070 (vectorizable_comparison): Likewise.
9071 * tree-vect-loop.c (vectorize_fold_left_reduction): Likewise.
9072 (vectorizable_reduction): Likewise.
9073
9074 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
9075
9076 * tree-vectorizer.h (vect_is_simple_use): Add an optional
9077 stmt_vec_info * parameter before the optional gimple **.
9078 * tree-vect-stmts.c (vect_is_simple_use): Likewise.
9079 (process_use, vect_get_vec_def_for_operand_1): Update callers.
9080 (vect_get_vec_def_for_operand, vectorizable_shift): Likewise.
9081 * tree-vect-loop.c (vectorizable_reduction): Likewise.
9082 (vectorizable_live_operation): Likewise.
9083 * tree-vect-patterns.c (type_conversion_p): Likewise.
9084 (vect_look_through_possible_promotion): Likewise.
9085 (vect_recog_rotate_pattern): Likewise.
9086 * tree-vect-slp.c (vect_get_and_check_slp_defs): Likewise.
9087
9088 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
9089
9090 * tree-vectorizer.h (stmt_vec_info): Temporarily change from
9091 a typedef to a wrapper class.
9092 (NULL_STMT_VEC_INFO): New macro.
9093 (vec_info::stmt_infos): Change to vec<stmt_vec_info>.
9094 (stmt_vec_info::operator*): New function.
9095 (stmt_vec_info::operator gimple *): Likewise.
9096 (set_vinfo_for_stmt): Use NULL_STMT_VEC_INFO.
9097 (add_stmt_costs): Likewise.
9098 * tree-vect-loop-manip.c (iv_phi_p): Likewise.
9099 * tree-vect-loop.c (vect_compute_single_scalar_iteration_cost)
9100 (vect_get_known_peeling_cost): Likewise.
9101 (vect_estimate_min_profitable_iters): Likewise.
9102 * tree-vect-patterns.c (vect_init_pattern_stmt): Likewise.
9103 * tree-vect-slp.c (vect_remove_slp_scalar_calls): Likewise.
9104 * tree-vect-stmts.c (vect_build_gather_load_calls): Likewise.
9105 (vectorizable_store, free_stmt_vec_infos): Likewise.
9106 (new_stmt_vec_info): Change return type of xcalloc to
9107 _stmt_vec_info *.
9108
9109 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
9110
9111 * tree-vectorizer.h (vec_info::lookup_single_use): Declare.
9112 * tree-vectorizer.c (vec_info::lookup_single_use): New function.
9113 * tree-vect-loop.c (vectorizable_reduction): Use it instead of
9114 a single_imm_use-based sequence.
9115 * tree-vect-stmts.c (supportable_widening_operation): Likewise.
9116
9117 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
9118
9119 * tree-vectorizer.h (vec_info::lookup_def): Declare.
9120 * tree-vectorizer.c (vec_info::lookup_def): New function.
9121 * tree-vect-patterns.c (vect_get_internal_def): Use it.
9122 (vect_widened_op_tree): Likewise.
9123 * tree-vect-stmts.c (vect_is_simple_use): Likewise.
9124 * tree-vect-loop.c (vect_analyze_loop_operations): Likewise.
9125 (vectorizable_reduction): Likewise.
9126 (vect_valid_reduction_input_p): Take a stmt_vec_info instead
9127 of a gimple *.
9128 (vect_is_slp_reduction): Update calls accordingly. Use
9129 vec_info::lookup_def.
9130 (vect_is_simple_reduction): Likewise
9131 * tree-vect-slp.c (vect_detect_hybrid_slp_1): Use vec_info::lookup_def.
9132
9133 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
9134
9135 * tree-vectorizer.h (vec_info::lookup_stmt): Declare.
9136 * tree-vectorizer.c (vec_info::lookup_stmt): New function.
9137 * tree-vect-loop.c (vect_determine_vf_for_stmt): Use it instead
9138 of vinfo_for_stmt.
9139 (vect_determine_vectorization_factor, vect_analyze_scalar_cycles_1)
9140 (vect_compute_single_scalar_iteration_cost, vect_analyze_loop_form)
9141 (vect_update_vf_for_slp, vect_analyze_loop_operations)
9142 (vect_is_slp_reduction, vectorizable_induction)
9143 (vect_transform_loop_stmt, vect_transform_loop): Likewise.
9144 * tree-vect-patterns.c (vect_init_pattern_stmt):
9145 (vect_determine_min_output_precision_1, vect_determine_precisions)
9146 (vect_pattern_recog): Likewise.
9147 * tree-vect-stmts.c (vect_analyze_stmt, vect_transform_stmt): Likewise.
9148 * config/powerpcspe/powerpcspe.c (rs6000_density_test): Likewise.
9149 * config/rs6000/rs6000.c (rs6000_density_test): Likewise.
9150 * tree-vect-slp.c (vect_detect_hybrid_slp_stmts): Likewise.
9151 (vect_detect_hybrid_slp_1, vect_detect_hybrid_slp_2)
9152 (vect_detect_hybrid_slp): Likewise. Change the walk_stmt_info
9153 info field from a loop to a loop_vec_info.
9154
9155 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
9156
9157 * tree-vectorizer.h (stmt_vec_info): Move typedef earlier in file.
9158 (vec_info::add_stmt): Declare.
9159 * tree-vectorizer.c (vec_info::add_stmt): New function.
9160 * tree-vect-data-refs.c (vect_create_data_ref_ptr): Use it.
9161 * tree-vect-loop.c (_loop_vec_info::_loop_vec_info): Likewise.
9162 (vect_create_epilog_for_reduction, vectorizable_reduction): Likewise.
9163 (vectorizable_induction): Likewise.
9164 * tree-vect-slp.c (_bb_vec_info::_bb_vec_info): Likewise.
9165 * tree-vect-stmts.c (vect_finish_stmt_generation_1): Likewise.
9166 (vectorizable_simd_clone_call, vectorizable_store): Likewise.
9167 (vectorizable_load): Likewise.
9168 * tree-vect-patterns.c (vect_init_pattern_stmt): Likewise.
9169 (vect_recog_bool_pattern, vect_recog_mask_conversion_pattern)
9170 (vect_recog_gather_scatter_pattern): Likewise.
9171 (append_pattern_def_seq): Likewise. Remove a check that is
9172 performed by add_stmt itself.
9173
9174 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
9175
9176 * tree-vect-loop.c (vectorizable_reduction): Fix an instance in
9177 which make_ssa_name was called with new_stmt before new_stmt
9178 had been created.
9179
9180 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
9181
9182 * tree-vect-loop.c (vect_valid_reduction_input_p): New function,
9183 split out from...
9184 (vect_is_slp_reduction): ...here...
9185 (vect_is_simple_reduction): ...and here. Remove repetition of tests
9186 that are already known to be false.
9187
9188 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
9189
9190 * tree-vectorizer.h (vect_free_slp_instance): Add a final_p parameter.
9191 * tree-vect-slp.c (vect_free_slp_tree): Likewise. Don't update
9192 STMT_VINFO_NUM_SLP_USES when it's true.
9193 (vect_free_slp_instance): Add a final_p parameter and pass it to
9194 vect_free_slp_tree.
9195 (vect_build_slp_tree_2): Update call to vect_free_slp_instance.
9196 (vect_analyze_slp_instance): Likewise.
9197 (vect_slp_analyze_operations): Likewise.
9198 (vect_slp_analyze_bb_1): Likewise.
9199 * tree-vectorizer.c (vec_info): Likewise.
9200 * tree-vect-loop.c (vect_transform_loop): Likewise.
9201
9202 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
9203
9204 * tree-vect-loop.c (vectorizable_reduction): Assert that the
9205 function is not called for second and subsequent members of
9206 a reduction group.
9207
9208 2018-07-31 Richard Sandiford <richard.sandiford@arm.com>
9209
9210 * tree-vect-loop.c (get_initial_def_for_reduction): Move special
9211 cases for nested loops from here to ...
9212 (vect_create_epilog_for_reduction): ...here. Only call
9213 vect_is_simple_use for inner-loop reductions.
9214
9215 2018-07-31 Martin Liska <mliska@suse.cz>
9216
9217 PR gcov-profile/85338
9218 PR gcov-profile/85350
9219 PR gcov-profile/85372
9220 * profile.c (struct location_triplet): New.
9221 (struct location_triplet_hash): Likewise.
9222 (output_location): Do not output a BB that
9223 is already recorded for a line.
9224 (branch_prob): Use streamed_locations.
9225
9226 2018-07-31 Martin Liska <mliska@suse.cz>
9227
9228 PR gcov-profile/85370
9229 * coverage.c (coverage_begin_function): Do not mark target
9230 clones as artificial functions.
9231
9232 2018-07-31 Martin Liska <mliska@suse.cz>
9233
9234 PR gcov-profile/83813
9235 PR gcov-profile/84758
9236 PR gcov-profile/85217
9237 PR gcov-profile/85332
9238 * profile.c (branch_prob): Do not record GOTO expressions
9239 for GIMPLE statements which locations are already streamed.
9240
9241 2018-07-31 Olivier Hainque <hainque@adacore.com>
9242
9243 * gcc.c (handle_spec_function): Accept a soft_matched_part
9244 argument, as do_spec_1. Pass it down to ...
9245 (eval_spec_function): Accept a soft_matched_part argument,
9246 and pass it down to ...
9247 (do_spec_2): Accept a soft_matched_part argument, and pass
9248 it down to do_spec_1.
9249 (do_spec_1): Pass soft_matched_part to handle_spec_function.
9250 (handle_braces): Update call to handle_spec_function.
9251 (driver::set_up_specs): Update calls to do_spec_2.
9252 (compare_debug_dump_opt_spec_function): Likewise.
9253 (compare_debug_self_opt_spec_function): Likewise.
9254
9255 2018-07-31 Olivier Hainque <hainque@adacore.com>
9256
9257 * common.opt (nolibc): New option.
9258 * doc/invoke.texi (Link Options): Document it.
9259 * gcc.c (LINK_GCC_C_SEQUENCE_SPEC): Honor nolibc.
9260 * config/alpha/linux.h: Likewise.
9261 * config/arc/elf.h: Likewise.
9262 * config/arm/uclinux-elf.h: Likewise.
9263 * config/arm/unknown-elf.h: Likewise.
9264 * config/avr/avrlibc.h: Likewise.
9265 * config/bfin/bfin.h: Likewise.
9266 * config/bfin/linux.h: Likewise.
9267 * config/bfin/uclinux.h: Likewise.
9268 * config/darwin.h: Likewise.
9269 * config/darwin10.h: Likewise.
9270 * config/darwin12.h: Likewise.
9271 * config/gnu-user.h: Likewise.
9272 * config/lm32/uclinux-elf.h: Likewise.
9273 * config/pa/pa-hpux11.h: Likewise.
9274 * config/pa/pa64-hpux.h: Likewise.
9275 * config/sparc/sparc.h: Likewise.
9276
9277 2018-07-31 Olivier Hainque <hainque@adacore.com>
9278
9279 * gcc.c (getenv_spec_function): Prepend '/' to value for allowed
9280 undefined variables.
9281
9282 2018-07-30 Segher Boessenkool <segher@kernel.crashing.org>
9283
9284 PR target/86640
9285 * config/arm/arm.c (arm_block_set_aligned_vect): Use gen_int_mode
9286 instead of GEN_INT.
9287
9288 2018-07-30 Bernd Edlinger <bernd.edlinger@hotmail.de>
9289
9290 * tree-ssa-forwprop.c (simplify_builtin_call): Don't create a not NUL
9291 terminated string literal.
9292
9293 2018-07-30 Segher Boessenkool <segher@kernel.crashing.org>
9294
9295 PR rtl-optimization/85160
9296 * combine.c (is_just_move): New function.
9297 (try_combine): Allow combining two instructions into two if neither of
9298 the original instructions was a move.
9299
9300 2018-07-30 Alexander Monakov <amonakov@ispras.ru>
9301
9302 PR target/86673
9303 * doc/extend.texi (Global Register Variables): Discourage use of type
9304 qualifiers.
9305 (Local Register Variables): Likewise.
9306
9307 2018-07-30 Richard Sandiford <richard.sandiford@arm.com>
9308
9309 PR tree-optimization/86506
9310 * hwint.h (ceil_log2): Resync with hwint.c implementation.
9311
9312 2018-07-30 Ilya Leoshkevich <iii@linux.ibm.com>
9313
9314 PR target/86547
9315 * lra-constraints.c (spill_hard_reg_in_range): When selecting the
9316 hard_regno, make sure no insn between `from` and `to` clobbers it.
9317
9318 2018-07-30 Cesar Philippidis <cesar@codesourcery.com>
9319 Tom de Vries <tdevries@suse.de>
9320
9321 * config/nvptx/nvptx.c (PTX_GANG_DEFAULT): Rename to ...
9322 (PTX_DEFAULT_RUNTIME_DIM): ... this.
9323 (nvptx_goacc_validate_dims): Set default worker and gang dims to
9324 PTX_DEFAULT_RUNTIME_DIM.
9325 (nvptx_dim_limit): Ignore GOMP_DIM_WORKER.
9326
9327 2018-07-29 John David Anglin <danglin@gcc.gnu.org>
9328
9329 * config/pa/pa.c (pa_output_addr_vec): Align address table.
9330 * config/pa/pa.h (JUMP_TABLES_IN_TEXT_SECTION): Revise comment.
9331 * config/pa/pa32-linux.h (JUMP_TABLES_IN_TEXT_SECTION): Define.
9332
9333 2018-07-27 Michael Meissner <meissner@linux.ibm.com>
9334
9335 * config/rs6000/constraints.md (wG constraint): Delete, no longer
9336 used.
9337 * config/rs6000/predicates.md (p9_fusion_reg_operand): Rename
9338 predicate to reflect toc fusion has been deleted.
9339 (toc_fusion_mem_raw): Delete, no longer used.
9340 (toc_fusion_mem_wrapped): Likewise.
9341 * config/rs6000/rs6000-cpus.def (POWERPC_MASKS): Delete toc
9342 fusion mask bit.
9343 * config/rs6000/rs6000-protos.h (fusion_wrap_memory_address):
9344 Delete, no longer used.
9345 * config/rs6000/rs6000.c (struct rs6000_reg_addr): Delete fields
9346 meant to be used for toc fusion.
9347 (rs6000_debug_print_mode): Delete toc fusion debugging.
9348 (rs6000_debug_reg_global): Likewise.
9349 (rs6000_init_hard_regno_mode_ok): Delete setting up fields for toc
9350 fusion and secondary reload support that were never used.
9351 (rs6000_option_override_internal): Delete TOC fusion, that was only
9352 partially defined, and it did not work unless you also used the
9353 -mcmodel= switch.
9354 (rs6000_legitimate_address_p): Delete TOC fusion support.
9355 (rs6000_opt_masks): Likewise.
9356 (fusion_wrap_memory_address): Delete function, no longer used.
9357 (fusion_split_address); Delete TOC fusion support.
9358 * config/rs6000/rs6000.h (TARGET_TOC_FUSION_INT): Delete, no
9359 longer used with toc fusion being deleted.
9360 (TARGET_TOC_FUSION_FP): Likewise.
9361 * config/rs6000/rs6000.md (UNSPEC_FUSION_ADDIS): Delete TOC fusion
9362 UNSPEC.
9363 (toc fusion spliter): Delete TOC fusion support.
9364 (toc_fusionload_<mode>): Likewise.
9365 (toc_fusionload_di): Likewise.
9366 (fusion_gpr_load_<mode>): Delete generator function, this insn no
9367 longer needs to be named. Rename predicate to delete TOC fusion.
9368 (fusion_gpr_<P:mode>_<GPR_FUSION:mode>_load): Likewise.
9369 (fusion_gpr_<P:mode>_<GPR_FUSION:mode>_store): Likewise.
9370 (fusion_vsx_<P:mode>_<GPR_FUSION:mode>_load): Likewise.
9371 (fusion_vsx_<P:mode>_<GPR_FUSION:mode>_store): Likewise.
9372 (p9 fusion peephole2s): Rename predicate to delete TOC fusion.
9373
9374 2018-07-27 Kelvin Nilsen <kelvin@gcc.gnu.org>
9375
9376 * doc/extend.texi (Basic PowerPC Built-in Functions Available on
9377 ISA 2.05): Replace __uint128_t with __uint128 and __int128_t with
9378 __int128 in built-in function prototypes.
9379 (PowerPC AltiVec Built-in Functions on ISA 2.07): Likewise.
9380 (PowerPC AltiVec Built-in Functions on ISA 3.0): Likewise.
9381
9382 2018-07-27 Martin Sebor <msebor@redhat.com>
9383
9384 PR tree-optimization/86696
9385 * tree-ssa-strlen.c (get_min_string_length): Handle all integer
9386 types, including enums.
9387 (handle_char_store): Be prepared for the above function to fail.
9388
9389 2018-07-26 Qing Zhao <qing.zhao@oracle.com>
9390
9391 * builtins.c (inline_expand_builtin_string_cmp): Disable inlining
9392 when optimization level is lower than 2 or optimize for size.
9393
9394 2018-07-26 Martin Sebor <msebor@redhat.com>
9395
9396 PR tree-optimization/86043
9397 PR tree-optimization/86042
9398 * tree-ssa-strlen.c (handle_builtin_memcpy): Handle strict overlaps.
9399 (get_string_cst_length): Rename...
9400 (get_min_string_length): ...to this. Add argument.
9401 (handle_char_store): Extend to handle multi-character stores by
9402 MEM_REF.
9403 * tree.c (initializer_zerop): Use new argument. Handle MEM_REF.
9404 * tree.h (initializer_zerop): Add argument.
9405
9406 2018-07-26 Jakub Jelinek <jakub@redhat.com>
9407
9408 PR middle-end/86660
9409 * omp-low.c (scan_sharing_clauses): Don't ignore map clauses for
9410 declare target to variables if they have always,{to,from,tofrom} map
9411 kinds.
9412
9413 2018-07-26 Martin Liska <mliska@suse.cz>
9414
9415 PR lto/86548
9416 * lto-wrapper.c: Add linker_output as prefix
9417 for ltrans_output_file.
9418
9419 2018-07-26 Segher Boessenkool <segher@kernel.crashing.org>
9420
9421 PR rtl-optimization/85805
9422 * combine.c (reg_nonzero_bits_for_combine): Only use the last set
9423 value for hard registers if that was written in the same mode.
9424
9425 2018-07-26 Martin Liska <mliska@suse.cz>
9426
9427 PR gcov-profile/86536
9428 * gcov.c (format_gcov): Use printf format %.*f directly
9429 and do not handle special values.
9430
9431 2018-07-25 Claudiu Zissulescu <claziss@synopsys.com>
9432
9433 * common/config/arc/arc-common.c (arc_option_optimization_table):
9434 Update default optimizations for size.
9435
9436 2018-07-25 Claudiu Zissulescu <claziss@synopsys.com>
9437
9438 * config/arc/arc.md (movsf_insn): Add short instruction selection.
9439 * config/arc/constraints.md (CfZ): New constraint.
9440 * config/arc/fpu.md (addssf3_fpu): Use CfZ constraint.
9441 (subsf3_fpu): Likewise.
9442 (cmpsf_fpu): Likewise.
9443 (cmpsf_fpu_uneq): Likewise.
9444
9445 2018-07-25 Claudiu Zissulescu <claziss@synopsys.com>
9446
9447 * config/arc/arc.c (compact_memory_operand_p): Check for uncached
9448 accesses as well.
9449 (arc_is_uncached_mem_p): uncached applies to both the variable and
9450 the pointer.
9451
9452 2018-07-25 Claudiu Zissulescu <claziss@synopsys.com>
9453
9454 * config/arc/arc.h (ADDITIONAL_REGISTER_NAMES): Add additional
9455 register names.
9456
9457 2018-07-25 David Malcolm <dmalcolm@redhat.com>
9458
9459 * optinfo-emit-json.cc (class optrecord_json_writer): Convert
9460 field "m_scopes" from vec to auto_vec.
9461
9462 2018-07-25 Martin Liska <mliska@suse.cz>
9463
9464 * config/powerpcspe/powerpcspe-protos.h (rs6000_loop_align): Fix
9465 return type.
9466
9467 2018-07-25 Richard Biener <rguenther@suse.de>
9468
9469 PR debug/86654
9470 * dwarf2out.c (dwarf2out_decl): Do not handle nested functions
9471 special wrt context_die late.
9472 (gen_subprogram_die): Re-use DIEs in local scope.
9473
9474 2018-07-25 Richard Sandiford <richard.sandiford@arm.com>
9475
9476 PR tree-optimization/86644
9477 * hwint.c (ceil_log2): Fix comment. Return 0 for 0.
9478
9479 2018-07-25 Martin Liska <mliska@suse.cz>
9480
9481 PR middle-end/86645
9482 * dumpfile.c: And excluded values with TDF_ALL_VALUES.
9483 * dumpfile.h (enum dump_flag): Defince TDF_ALL_VALUES.
9484
9485 2018-07-25 Martin Liska <mliska@suse.cz>
9486
9487 PR sanitizer/79635
9488 * params.def: Explain ASan abbreviation and provide
9489 a documentation link.
9490
9491 2018-07-24 Martin Sebor <msebor@redhat.com>
9492
9493 PR tree-optimization/86622
9494 PR tree-optimization/86532
9495 * builtins.h (string_length): Declare.
9496 * builtins.c (c_strlen): Correct handling of non-constant offsets.
9497 (check_access): Be prepared for non-constant length ranges.
9498 (string_length): Make extern.
9499 * expr.c (string_constant): Only handle the minor non-constant
9500 array index. Use string_constant to compute the length of
9501 a generic string constant.
9502
9503 2018-07-24 Richard Sandiford <richard.sandiford@arm.com>
9504
9505 PR tree-optimization/86618
9506 * tree-vect-stmts.c (vectorizable_call): Don't take the address
9507 of LOOP_VINFO_MASKS (loop_vinfo) when loop_vinfo is null.
9508
9509 2018-07-24 David Malcolm <dmalcolm@redhat.com>
9510
9511 PR tree-optimization/86636
9512 * json.cc (json::object::set): Fix comment. Add assertions.
9513 (json::array::append): Move here from json.h. Add comment and an
9514 assertion.
9515 (json::string::string): Likewise.
9516 * json.h (json::array::append): Move to json.cc.
9517 (json::string::string): Likewise.
9518 * optinfo-emit-json.cc
9519 (optrecord_json_writer::impl_location_to_json): Assert that we
9520 aren't attempting to write out UNKNOWN_LOCATION, or an ad-hoc
9521 wrapper around it. Expand the location once, rather than three
9522 times.
9523 (optrecord_json_writer::inlining_chain_to_json): Fix the check for
9524 UNKNOWN_LOCATION, to use LOCATION_LOCUS to look through ad-hoc
9525 wrappers.
9526 (optrecord_json_writer::optinfo_to_json): Likewise, in four
9527 places. Fix some overlong lines.
9528
9529 2018-07-24 Matthew Malcomson <matthew.malcomson@arm.com>
9530
9531 * config/aarch64/aarch64-simd.md
9532 (aarch64_<ANY_EXTEND:su><ADDSUB:optab>w<mode>): Split into...
9533 (aarch64_<ANY_EXTEND:su>subw<mode>): ... This...
9534 (aarch64_<ANY_EXTEND:su>addw<mode>): ... And this.
9535 (aarch64_<ANY_EXTEND:su><ADDSUB:optab>w<mode>_internal): Split into...
9536 (aarch64_<ANY_EXTEND:su>subw<mode>_internal): ... This...
9537 (aarch64_<ANY_EXTEND:su>addw<mode>_internal): ... And this.
9538 (aarch64_<ANY_EXTEND:su><ADDSUB:optab>w2<mode>_internal): Split into...
9539 (aarch64_<ANY_EXTEND:su>subw2<mode>_internal): ... This...
9540 (aarch64_<ANY_EXTEND:su>addw2<mode>_internal): ... And this.
9541
9542 2018-07-24 Jakub Jelinek <jakub@redhat.com>
9543
9544 PR middle-end/86627
9545 * expmed.c (expand_divmod): Punt if d == HOST_WIDE_INT_MIN
9546 and size > HOST_BITS_PER_WIDE_INT. For size > HOST_BITS_PER_WIDE_INT
9547 and abs_d == d, do the power of two handling if profitable.
9548
9549 2018-07-24 Richard Biener <rguenther@suse.de>
9550
9551 * match.pd: Add BIT_FIELD_REF canonicalizations.
9552
9553 2018-07-23 Bernd Edlinger <bernd.edlinger@hotmail.de>
9554
9555 PR c/86617
9556 * genmatch.c (dt_operand::gen_match_op): Avoid folding volatile values.
9557
9558 2018-07-23 Bernd Edlinger <bernd.edlinger@hotmail.de>
9559
9560 * gimple-fold.c (gimple_fold_builtin_printf): Don't create a not NUL
9561 terminated STRING_CST object.
9562
9563 2018-07-23 Bernd Edlinger <bernd.edlinger@hotmail.de>
9564
9565 hsa-dump.c (dump_hsa_symbol): Avoid out of scope access to buf.
9566
9567 2018-07-23 Segher Boessenkool <segher@kernel.crashing.org>
9568
9569 * config/rs6000/rs6000-p8swap.c (rtx_is_swappable_p): Adjust.
9570 * config/rs6000/rs6000-protos.h (rs6000_split_v4si_init): Delete.
9571 * config/rs6000/rs6000.c (rs6000_expand_vector_init): Always force
9572 the elements into a register.
9573 (rs6000_split_v4si_init_di_reg): Delete.
9574 (rs6000_split_v4si_init): Delete.
9575 * config/rs6000/vsx.md (unspec): Delete UNSPEC_VSX_VEC_INIT.
9576 (vsx_init_v4si): Rewrite as a define_expand.
9577
9578 2018-07-23 Segher Boessenkool <segher@kernel.crashing.org>
9579
9580 * config/rs6000/rs6000.md (splitters for rldimi and rlwimi with the
9581 zero_extend argument from memory): New.
9582
9583 2018-07-22 Martin Sebor <msebor@redhat.com>
9584
9585 PR bootstrap/86621
9586 * gimple-ssa-warn-alloca.c (alloca_call_type_by_arg): Avoid
9587 diagnosing calls with unknown arguments unless -Walloca-larger-than
9588 is restricted to less than PTRDIFF_MAX bytes.
9589
9590 2018-07-22 Gerald Pfeifer <gerald@pfeifer.com>
9591
9592 * doc/gcov.texi (Invoking Gcov): Editorial changes.
9593
9594 2018-07-20 David Malcolm <dmalcolm@redhat.com>
9595
9596 * pretty-print.c (text_info::set_location): Remove redundant
9597 "line_table" parameter from call to rich_location::set_range.
9598
9599 2018-07-20 Martin Sebor <msebor@redhat.com>
9600
9601 PR middle-end/82063
9602 * builtins.c (expand_builtin_alloca): Adjust.
9603 * calls.c (alloc_max_size): Simplify.
9604 * cgraphunit.c (cgraph_node::expand): Adjust.
9605 * common.opt (larger_than_size, warn_frame_larger_than): Remove
9606 variables.
9607 (frame_larger_than_size): Same.
9608 (-Wframe-larger-than, -Wlarger-than, -Wstack-usage): Change options
9609 to take a HOST_WIDE_INT argument and accept a byte-size suffix.
9610 Initialize.
9611 * doc/invoke.texi (GCC Command Options): Document option arguments.
9612 Explain byte-size arguments and suffixes.
9613 (-Wvla-larger-than, -Wno-alloc-size-larger-than): Update.
9614 (-Wno-alloca-larger-than, -Wno-vla-larger-than): Same.
9615 (-Wframe-larger-than, -Wlarger-than, -Wstack-usage): Same.
9616 * doc/options.texi (UInteger): Expand.
9617 (Host_Wide_Int, ByteSize): Document new properties.
9618 * final.c (final_start_function_1): Include sizes in an error message.
9619 * function.c (frame_offset_overflow): Same.
9620 * gimple-ssa-warn-alloca.c (pass_walloca::gate): Adjust.
9621 (alloca_call_type_by_arg): Change function argument to HOST_WIDE_INT.
9622 Diagnose unbounded alloca calls only for limits of less than
9623 PTRDIFF_MAX.
9624 (alloca_call_type): Adjust. Diagnose possibly out-of-bounds alloca
9625 calls and VLA size only for limits of less than PTRDIFF_MAX. Same
9626 for alloca(0).
9627 (pass_walloca::execute): Adjust. Diagnose alloca calls in loops
9628 only for limits of less than PTRDIFF_MAX.
9629 * langhooks-def.h (lhd_handle_option): Change function argument
9630 to HOST_WIDE_INT.
9631 * langhooks.c (lhd_handle_option): Same.
9632 * langhooks.h (handle_option): Same.
9633 * opt-functions.awk (switch_bit_fields): Handle Host_Wide_Int and
9634 ByteSize flags.
9635 (var_type, var_type_struct): Same.
9636 (var_set): Handle ByteSize flag.
9637 * optc-gen.awk: Add comments to output to ease debugging. Make
9638 use of HOST_WIDE_INT where appropriate.
9639 * opts-gen-save.awk: Use %lx to format unsigned long.
9640 * opth-gen.awk: Change function argument to HOST_WIDE_INT.
9641 * opts-common.c (integral_argument): Return HOST_WIDE_INT and add
9642 arguments. Parse bytes-size suffixes.
9643 (enum_arg_to_value): Change function argument to HOST_WIDE_INT.
9644 (enum_value_to_arg): Same.
9645 (decode_cmdline_option): Handle cl_host_wide_int. Adjust.
9646 (handle_option): Adjust.
9647 (generate_option): Change function argument to HOST_WIDE_INT.
9648 (cmdline_handle_error): Adjust.
9649 (read_cmdline_option): Change function argument to HOST_WIDE_INT.
9650 (set_option): Change function argument to HOST_WIDE_INT.
9651 (option_enabled): Handle cl_host_wide_int.
9652 (get_option_state): Handle CLVC_SIZE.
9653 (control_warning_option): Same.
9654 * opts.c (common_handle_option): Change function argument to
9655 HOST_WIDE_INT. Remove handling of OPT_Walloca_larger_than_ and
9656 OPT_Wvla_larger_than_.
9657 * opts.h (enum cl_var_type): Add an enumerator.
9658 * stor-layout.c (layout_decl): Print a more meaningful warning.
9659 * toplev.c (output_stack_usage): Adjust.
9660
9661 2018-07-20 Qing Zhao <qing.zhao@oracle.com>
9662
9663 * builtins.c (expand_builtin_memcmp): Delete the last parameter for
9664 call to inline_expand_builtin_string_cmp.
9665 (expand_builtin_strcmp): Likewise.
9666 (expand_builtin_strncmp): Likewise.
9667 (inline_string_cmp): Delete the last parameter, change char_type_node
9668 to unsigned_char_type_node for strcmp/strncmp, add conversions to the
9669 two operands.
9670 (inline_expand_builtin_string_cmp): Delete the last parameter, give up
9671 the inlining expansion on target where the type of the call has same or
9672 narrower precision than unsigned char.
9673
9674 2018-07-20 David Malcolm <dmalcolm@redhat.com>
9675
9676 * Makefile.in (OBJS): Add json.o and optinfo-emit-json.o.
9677 (CFLAGS-optinfo-emit-json.o): Define TARGET_NAME.
9678 * common.opt (fsave-optimization-record): New option.
9679 * coretypes.h (struct kv_pair): Move here from dumpfile.c.
9680 * doc/invoke.texi (-fsave-optimization-record): New option.
9681 * dumpfile.c: Include "optinfo-emit-json.h".
9682 (struct kv_pair): Move to coretypes.h.
9683 (optgroup_options): Make non-static.
9684 (dump_context::end_scope): Call
9685 optimization_records_maybe_pop_dump_scope.
9686 * dumpfile.h (optgroup_options): New decl.
9687 * json.cc: New file.
9688 * json.h: New file.
9689 * optinfo-emit-json.cc: New file.
9690 * optinfo-emit-json.h: New file.
9691 * optinfo.cc: Include "optinfo-emit-json.h".
9692 (optinfo::emit): Call optimization_records_maybe_record_optinfo.
9693 (optinfo_enabled_p): Check optimization_records_enabled_p.
9694 (optinfo_wants_inlining_info_p): Likewise.
9695 * optinfo.h: Update comment.
9696 * profile-count.c (profile_quality_as_string): New function.
9697 * profile-count.h (profile_quality_as_string): New decl.
9698 (profile_count::quality): New accessor.
9699 * selftest-run-tests.c (selftest::run_tests): Call json_cc_tests
9700 and optinfo_emit_json_cc_tests.
9701 * selftest.h (selftest::json_cc_tests): New decl.
9702 (selftest::optinfo_emit_json_cc_tests): New decl.
9703 * toplev.c: Include "optinfo-emit-json.h".
9704 (compile_file): Call optimization_records_finish.
9705 (do_compile): Call optimization_records_start.
9706 * tree-ssa-live.c: Include optinfo.h.
9707 (remove_unused_scope_block_p): Retain inlining information if
9708 optinfo_wants_inlining_info_p returns true.
9709
9710 2018-07-20 Richard Biener <rguenther@suse.de>
9711
9712 PR debug/86585
9713 * dwarf2out.c (dwarf2out_die_ref_for_decl): Test in_lto_p
9714 to cover -flto-partition=none.
9715
9716 2018-07-20 Martin Liska <mliska@suse.cz>
9717
9718 * tree.h (DECL_LOCATION_RANGE): Remove unused macro.
9719 (get_decl_source_range): Remove unused function.
9720
9721 2018-07-20 Richard Biener <rguenther@suse.de>
9722
9723 * tree-ssa-sccvn.h (struct vn_nary_op_s): Add next member.
9724 (struct vn_phi_s): Likewise.
9725 (struct vn_reference_s): Likewise.
9726 * tree-ssa-sccvn.c (vn_nary_op_hasher::equal): Add shortcut
9727 for searching the slot of an entry known to be in the hash itself.
9728 (vn_phi_hasher::equal): Likewise.
9729 (vn_reference_hasher::equal): Likewise.
9730 (last_inserted_ref, last_inserted_phi, last_inserted_nary): New
9731 globals.
9732 (optimistic_info, current_info): Remove, keeping only valid_info.
9733 (vn_reference_lookup_1): Remove fallback lookup.
9734 (vn_reference_lookup_2): Likewise.
9735 (vn_nary_op_lookup_1): Likewise.
9736 (vn_phi_lookup): Likewise.
9737 (vn_nary_build_or_lookup_1): Make sure to not chain the built
9738 hash element.
9739 (vn_reference_insert): Adjust, chain the inserted hash element
9740 at last_inserted_ref.
9741 (vn_reference_insert_pieces): Likewise.
9742 (visit_reference_op_call): Likewise.
9743 (vn_nary_op_insert_into): Chain the inserted hash element at
9744 last_inserted_nary.
9745 (vn_nary_op_insert_pieces): Adjust.
9746 (vn_nary_op_insert): Likewise.
9747 (vn_nary_op_insert_stmt): Likewise.
9748 (vn_phi_insert): Adjust, chain the inserted hash element at
9749 last_inserted_phi.
9750 (process_scc): Remove clearing and copying the optimistic
9751 table. Instead remove elements inserted during an optimistic
9752 iteration from the single table we maintain.
9753 (init_scc_vn): Adjust.
9754 (free_scc_vn): Likewise.
9755 (sccvn_dom_walker::record_cond): Likewise.
9756 (sccvn_dom_walker::after_dom_children): Likewise.
9757
9758 2018-07-19 Martin Sebor <msebor@redhat.com>
9759
9760 PR tree-optimization/84047
9761 PR tree-optimization/83776
9762 * tree-vrp.c (vrp_prop::check_mem_ref): New function.
9763 (check_array_bounds): Call it.
9764
9765 2018-07-19 Martin Sebor <msebor@redhat.com>
9766
9767 * align.h (align_flags): Use member initialization.
9768
9769 2018-07-19 David Malcolm <dmalcolm@redhat.com>
9770
9771 * Makefile.in (OBJS): Add optinfo.o.
9772 * coretypes.h (class symtab_node): New forward decl.
9773 (struct cgraph_node): New forward decl.
9774 (class varpool_node): New forward decl.
9775 * dump-context.h: New file.
9776 * dumpfile.c: Include "optinfo.h", "dump-context.h", "cgraph.h",
9777 "tree-pass.h".
9778 (refresh_dumps_are_enabled): Use optinfo_enabled_p.
9779 (set_dump_file): Call dumpfile_ensure_any_optinfo_are_flushed.
9780 (set_alt_dump_file): Likewise.
9781 (dump_context::~dump_context): New dtor.
9782 (dump_gimple_stmt): Move implementation to...
9783 (dump_context::dump_gimple_stmt): ...this new member function.
9784 Add the stmt to any pending optinfo, creating one if need be.
9785 (dump_gimple_stmt_loc): Move implementation to...
9786 (dump_context::dump_gimple_stmt_loc): ...this new member function.
9787 Start a new optinfo and add the stmt to it.
9788 (dump_gimple_expr): Move implementation to...
9789 (dump_context::dump_gimple_expr): ...this new member function.
9790 Add the stmt to any pending optinfo, creating one if need be.
9791 (dump_gimple_expr_loc): Move implementation to...
9792 (dump_context::dump_gimple_expr_loc): ...this new member function.
9793 Start a new optinfo and add the stmt to it.
9794 (dump_generic_expr): Move implementation to...
9795 (dump_context::dump_generic_expr): ...this new member function.
9796 Add the tree to any pending optinfo, creating one if need be.
9797 (dump_generic_expr_loc): Move implementation to...
9798 (dump_context::dump_generic_expr_loc): ...this new member
9799 function. Add the tree to any pending optinfo, creating one if
9800 need be.
9801 (dump_printf): Move implementation to...
9802 (dump_context::dump_printf_va): ...this new member function. Add
9803 the text to any pending optinfo, creating one if need be.
9804 (dump_printf_loc): Move implementation to...
9805 (dump_context::dump_printf_loc_va): ...this new member function.
9806 Start a new optinfo and add the stmt to it.
9807 (dump_dec): Move implementation to...
9808 (dump_context::dump_dec): ...this new member function. Add the
9809 value to any pending optinfo, creating one if need be.
9810 (dump_context::dump_symtab_node): New member function.
9811 (dump_context::get_scope_depth): New member function.
9812 (dump_context::begin_scope): New member function.
9813 (dump_context::end_scope): New member function.
9814 (dump_context::ensure_pending_optinfo): New member function.
9815 (dump_context::begin_next_optinfo): New member function.
9816 (dump_context::end_any_optinfo): New member function.
9817 (dump_context::s_current): New global.
9818 (dump_context::s_default): New global.
9819 (dump_scope_depth): Delete global.
9820 (dumpfile_ensure_any_optinfo_are_flushed): New function.
9821 (dump_symtab_node): New function.
9822 (get_dump_scope_depth): Reimplement in terms of dump_context.
9823 (dump_begin_scope): Likewise.
9824 (dump_end_scope): Likewise.
9825 (selftest::temp_dump_context::temp_dump_context): New ctor.
9826 (selftest::temp_dump_context::~temp_dump_context): New dtor.
9827 (selftest::verify_item): New function.
9828 (ASSERT_IS_TEXT): New macro.
9829 (ASSERT_IS_TREE): New macro.
9830 (ASSERT_IS_GIMPLE): New macro.
9831 (selftest::test_capture_of_dump_calls): New test.
9832 (selftest::dumpfile_c_tests): Call it.
9833 * dumpfile.h (dump_printf, dump_printf_loc, dump_basic_block)
9834 (dump_generic_expr_loc, dump_generic_expr, dump_gimple_stmt_loc)
9835 (dump_gimple_stmt, dump_dec): Gather these related decls and add a
9836 descriptive comment.
9837 (dump_function, print_combine_total_stats, enable_rtl_dump_file)
9838 (dump_node, dump_bb): Move these unrelated decls.
9839 (class dump_manager): Add leading comment.
9840 * optinfo.cc: New file.
9841 * optinfo.h: New file.
9842
9843 2018-07-19 Michael Collison <michael.collison@arm.com>
9844 Richard Henderson <rth@redhat.com>
9845
9846 * config/aarch64/aarch64.md (subv<GPI>4, usubv<GPI>4): New patterns.
9847 (subti): Handle op1 zero.
9848 (subvti4, usub4ti4): New.
9849 (*sub<GPI>3_compare1_imm): New.
9850 (sub<GPI>3_carryinCV): New.
9851 (*sub<GPI>3_carryinCV_z1_z2, *sub<GPI>3_carryinCV_z1): New.
9852 (*sub<GPI>3_carryinCV_z2, *sub<GPI>3_carryinCV): New.
9853
9854 2018-07-19 Michael Collison <michael.collison@arm.com>
9855 Richard Henderson <rth@redhat.com>
9856
9857 * config/aarch64/aarch64.md: (addv<GPI>4, uaddv<GPI>4): New.
9858 (addti3): Create simpler code if low part is already known to be 0.
9859 (addvti4, uaddvti4): New.
9860 (*add<GPI>3_compareC_cconly_imm): New.
9861 (*add<GPI>3_compareC_cconly): New.
9862 (*add<GPI>3_compareC_imm): New.
9863 (*add<GPI>3_compareC): Rename from add<GPI>3_compare1; do not
9864 handle constants within this pattern..
9865 (*add<GPI>3_compareV_cconly_imm): New.
9866 (*add<GPI>3_compareV_cconly): New.
9867 (*add<GPI>3_compareV_imm): New.
9868 (add<GPI>3_compareV): New.
9869 (add<GPI>3_carryinC, add<GPI>3_carryinV): New.
9870 (*add<GPI>3_carryinC_zero, *add<GPI>3_carryinV_zero): New.
9871 (*add<GPI>3_carryinC, *add<GPI>3_carryinV): New.
9872 ((*add<GPI>3_compareC_cconly_imm): Replace 'ne' operator
9873 with 'comparison' operator.
9874 (*add<GPI>3_compareV_cconly_imm): Ditto.
9875 (*add<GPI>3_compareV_cconly): Ditto.
9876 (*add<GPI>3_compareV_imm): Ditto.
9877 (add<GPI>3_compareV): Ditto.
9878 (add<mode>3_carryinC): Ditto.
9879 (*add<mode>3_carryinC_zero): Ditto.
9880 (*add<mode>3_carryinC): Ditto.
9881 (add<mode>3_carryinV): Ditto.
9882 (*add<mode>3_carryinV_zero): Ditto.
9883 (*add<mode>3_carryinV): Ditto.
9884
9885 2018-07-19 Michael Collison <michael.collison@arm.com>
9886 Richard Henderson <rth@redhat.com>
9887
9888 * config/aarch64/aarch64-modes.def (CC_V): New.
9889 * config/aarch64/aarch64-protos.h
9890 (aarch64_addti_scratch_regs): Declare
9891 (aarch64_subvti_scratch_regs): Declare.
9892 (aarch64_expand_subvti): Declare.
9893 (aarch64_gen_unlikely_cbranch): Declare
9894 * config/aarch64/aarch64.c (aarch64_select_cc_mode): Test
9895 for signed overflow using CC_Vmode.
9896 (aarch64_get_condition_code_1): Handle CC_Vmode.
9897 (aarch64_gen_unlikely_cbranch): New function.
9898 (aarch64_addti_scratch_regs): New function.
9899 (aarch64_subvti_scratch_regs): New function.
9900 (aarch64_expand_subvti): New function.
9901
9902 2018-07-19 Andre Vieira <andre.simoesdiasvieira@arm.com>
9903
9904 * config/aarch64/aarch64-option-extensions.def: New entry for profile
9905 extension.
9906 * config/aarch64/aarch64.h (AARCH64_FL_PROFILE): New.
9907 * doc/invoke.texi (aarch64-feature-modifiers): New entry for profile
9908 extension.
9909
9910 2018-07-19 Andre Vieira <andre.simoesdiasvieira@arm.com>
9911
9912 PR target/83009
9913 * config/aarch64/predicates.md (aarch64_mem_pair_lanes_operand): Make
9914 address check not strict.
9915
9916 2018-07-19 Andre Vieira <andre.simoesdiasvieira@arm.com>
9917
9918 * config/aarch64/aarch64-simd.md (aarch64_simd_mov<VQ:mode>): Replace
9919 Umq with Umn.
9920 (store_pair_lanes<mode>): Likewise.
9921 * config/aarch64/aarch64-protos.h (aarch64_addr_query_type): Add new
9922 enum value 'ADDR_QUERY_LDP_STP_N'.
9923 * config/aarch64/aarch64.c (aarch64_addr_query_type): Likewise.
9924 (aarch64_print_address_internal): Add declaration.
9925 (aarch64_print_ldpstp_address): Remove.
9926 (aarch64_classify_address): Adapt mode for 'ADDR_QUERY_LDP_STP_N'.
9927 (aarch64_print_operand): Change printing of 'y'.
9928 * config/aarch64/predicates.md (aarch64_mem_pair_lanes_operand): Use
9929 new enum value 'ADDR_QUERY_LDP_STP_N', don't hardcode mode and use
9930 'true' rather than '1'.
9931 * config/aarch64/constraints.md (Uml): Likewise.
9932 (Uml): Rename to Umn.
9933 (Umq): Remove.
9934
9935 2018-07-19 Richard Biener <rguenther@suse.de>
9936
9937 * tree-ssa-sccvn.h (struct vn_phi_s): Make phiargs member
9938 a trailing array.
9939 * tree-ssa-sccvn.c: Remove alloc-pool.h use.
9940 (vn_phi_hasher): Derive from nofree_ptr_hash and remove remove method.
9941 (vn_reference_hasher): Likewise.
9942 (struct vn_tables_s): Remove obstack and alloc-pool members.
9943 (vn_tables_obstack, vn_tables_insert_obstack): New global obstacks.
9944 (vn_nary_build_or_lookup_1): Manually build in vn_tables_insert_obstack.
9945 (vn_reference_insert): Allocate from obstack instead of from alloc-pool.
9946 (vn_reference_insert_pieces): Likewise.
9947 (alloc_vn_nary_op_noinit): Adjust.
9948 (vn_nary_op_insert_stmt): Allocate phiargs in-place.
9949 (vn_phi_eq): Adjust.
9950 (shared_lookup_phiargs): Remove.
9951 (vn_phi_lookup): Allocate temporary vn_phi_s on the stack.
9952 (vn_phi_insert): Allocate from obstack instead of from alloc-pool.
9953 (visit_reference_op_call): Likewise.
9954 (copy_nary, copy_phi, copy_reference): Remove.
9955 (process_scc): Rewind the obstack when iterating. Do not
9956 copy the elements to valid_info but just move them from one
9957 hashtable to the other.
9958 (allocate_vn_table): Adjust.
9959 (free_vn_table): Likewise.
9960 (init_scc_vn): Likewise.
9961 (free_scc_vn): Likewise.
9962
9963 2018-07-19 H.J. Lu <hongjiu.lu@intel.com>
9964
9965 PR target/86560
9966 * config/i386/i386.c (rest_of_insert_endbranch): Lookup
9967 indirect_return as function type attribute.
9968 (ix86_attribute_table): Change indirect_return to function
9969 type attribute.
9970 * doc/extend.texi: Update indirect_return attribute.
9971
9972 2018-07-19 Aldy Hernandez <aldyh@redhat.com>
9973
9974 * wide-int.h (widest2_int): New.
9975 * gimple-fold.c (arith_overflowed_p): Use it.
9976 * tree.h (widest2_int_cst): New.
9977 * tree-vrp.c (wide_int_binop_overflow): Rename from
9978 vrp_int_const_binop.
9979 Rewrite to work on trees.
9980 (extract_range_from_multiplicative_op_1): Abstract code to...
9981 (wide_int_range_min_max): ...here.
9982 (wide_int_range_cross_product): ...and here.
9983 (extract_range_from_binary_expr_1): Abstract overflow code to...
9984 (wide_int_range_mult_wrapping): ...here.
9985 * tree-vrp.h (wide_int_range_cross_product): New.
9986 (wide_int_range_mult_wrapping): New.
9987
9988 2018-07-19 Andrew Senkevich <andrew.senkevich@intel.com>
9989 Julia Koval <julia.koval@intel.com>
9990
9991 * config/i386/x86-tune-costs.h (skylake_memcpy,
9992 skylake_memset): Replace rep_prefix with unrolling for size 512.
9993
9994 2018-07-18 Kugan Vivekanandarajah <kuganv@linaro.org>
9995
9996 PR middle-end/86544
9997 * tree-ssa-phiopt.c (cond_removal_in_popcount_pattern): Handle
9998 comparision with EQ_EXPR in last stmt.
9999
10000 2018-07-18 Kelvin Nilsen <kelvin@gcc.gnu.org>
10001
10002 * doc/extend.texi (PowerPC AltiVec Built-in Functions): Rename
10003 this subsection to "PowerPC AltiVec/VSX Built-in Functions".
10004 (PowerPC AltiVec/VSX Built-in Functions): New name for subsection
10005 previously known as "PowerPC AltiVec Built-in Functions". Move
10006 some material to new subsubsections "PowerPC AltiVec Built-in
10007 Functions on ISA 2.06" and "PowerPC AltiVec Built-in Functions on
10008 ISA 2.07".
10009 (PowerPC Altivec Built-in Functions on ISA 2.05): New subsubsection.
10010 (PowerPC Altivec Built-in Functions on ISA 2.06): Likewise.
10011 (PowerPC Altivec Built-in Functions on ISA 2.07): Likewise.
10012 (PowerPC Altivec Built-in Functions on ISA 3.0): Likewise.
10013
10014 2018-07-18 Richard Biener <rguenther@suse.de>
10015
10016 PR tree-optimization/86557
10017 * tree-vect-patterns.c (vect_recog_divmod_pattern): Also handle
10018 EXACT_DIV_EXPR.
10019
10020 2018-07-18 Ilya Leoshkevich <iii@linux.ibm.com>
10021
10022 * config/s390/s390.c (s390_function_profiler): Generate CFI.
10023
10024 2018-07-17 Jeff Law <law@redhat.com>
10025
10026 * config/arm/arm.c (get_label_padding): Update for recent
10027 changes to label_to_alignment.
10028
10029 PR tree-optimization/86010
10030 * tree-ssa-dse.c (compute_trims): Fix typo/thinko.
10031
10032 * config/mips/mips.c (vr4130_align_insns): Update for recent
10033 changes to label_to_alignment.
10034
10035 * config/frv/frv.c (frv_label_align): Update for recent changes
10036 to label_to_alignment.
10037
10038 * config/nios2/nios2.c (nios2_label_align): Update for recent
10039 changes which dropped ALIGN_LABELS_LOG.
10040
10041 2018-07-17 Andreas Schwab <schwab@linux-m68k.org>
10042
10043 * config/m68k/m68k.md (umulsi3_highpart+1, const_umulsi3_highpart)
10044 (smulsi3_highpart+1, const_smulsi3_highpart): Add CC_STATUS_INIT.
10045
10046 2018-07-17 Claudiu Zissulescu <claziss@synopsys.com>
10047
10048 * config/arc/arc.c (arc_label_align): Use align_labels instead of
10049 deprecated align_labels_log.
10050
10051 2018-07-17 Richard Biener <rguenther@suse.de>
10052
10053 PR lto/86456
10054 * dwarf2out.c (init_sections_and_labels): Always generate
10055 a debug_line_str_section for early LTO debug.
10056 (dwarf2out_finish): Reset debug_line_str_hash output early.
10057 Bump counter for extra dwarf5 .debug_loc labels to not conflict
10058 with fat LTO part.
10059 (dwarf2out_early_finish): Output debug_line_str.
10060
10061 2018-07-17 Robin Dapp <rdapp@linux.ibm.com>
10062
10063 * config/s390/s390.c (preferred_la_operand_p): Do not use LA with
10064 index register on z196 or later.
10065
10066 2018-07-17 Robin Dapp <rdapp@linux.ibm.com>
10067
10068 * config/s390/s390.c (s390_default_align): Set default function
10069 alignment to 16.
10070 (s390_override_options_after_change): Call s390_default align.
10071 (s390_option_override_internal): Call s390_default_align.
10072 (TARGET_OVERRIDE_OPTIONS_AFTER_CHANGE): Define.
10073
10074 2018-07-17 Jakub Jelinek <jakub@redhat.com>
10075
10076 PR middle-end/86542
10077 * omp-low.c (create_task_copyfn): Copy over also fields corresponding
10078 to _looptemp_ clauses, other than the first two.
10079
10080 2018-07-17 Martin Liska <mliska@suse.cz>
10081
10082 * opts.c: Do not enable OPT_falign_* for -Os.
10083
10084 2018-07-17 Martin Liska <mliska@suse.cz>
10085
10086 * align.h (MAX_CODE_ALIGN): New.
10087 (MAX_CODE_ALIGN_VALUE): New.
10088 * common/config/i386/i386-common.c (ix86_handle_option):
10089 (MAX_CODE_ALIGN): Moved to align.h.
10090 * final.c (MAX_CODE_ALIGN): Likewise.
10091 * opts.c (parse_and_check_align_values):
10092 (MAX_CODE_ALIGN): Likewise.
10093 (MAX_CODE_ALIGN_VALUE): Likewise.
10094
10095 2018-07-17 Martin Liska <mliska@suse.cz>
10096
10097 * config/i386/att.h (ASM_OUTPUT_ALIGN): Fix spacing
10098 in order to fulfil coding style.
10099 * config/i386/cygming.h (ASM_OUTPUT_ALIGN): Likewise.
10100 * config/i386/gas.h (ASM_OUTPUT_MAX_SKIP_ALIGN): Likewise.
10101 * config/i386/x86-64.h (ASM_OUTPUT_MAX_SKIP_PAD): Likewise.
10102 * config/iq2000/iq2000.h (ASM_OUTPUT_ALIGN): Likewise.
10103 * config/pa/pa.h (ASM_OUTPUT_ALIGN): Likewise.
10104 * config/sparc/sol2.h (ASM_OUTPUT_ALIGN_WITH_NOP): Likewise.
10105 * config/sparc/sparc.h (ASM_OUTPUT_ALIGN): Likewise.
10106 * config/visium/visium.h (ASM_OUTPUT_ALIGN): Likewise.
10107 (ASM_OUTPUT_MAX_SKIP_ALIGN): Likewise.
10108
10109 2018-07-17 Martin Liska <mliska@suse.cz>
10110
10111 * align.h: New file.
10112 * config/alpha/alpha.c (alpha_align_insns_1): Use align_functions
10113 directly.
10114 * config/i386/i386.c (ix86_avoid_jump_mispredicts): Use new return type
10115 align_flags of label_to_alignment.
10116 * config/m32r/m32r.h (LOOP_ALIGN): Wrap returned values into
10117 align_flags class.
10118 * config/m68k/m68k.c: Do not use removed align_labels_value and
10119 align_loops_value.
10120 * config/nds32/nds32.h (JUMP_ALIGN): Wrap result into align_flags class.
10121 (LOOP_ALIGN): Likewise.
10122 (LABEL_ALIGN): Likewise.
10123 * config/powerpcspe/powerpcspe.c (TARGET_ASM_LOOP_ALIGN_MAX_SKIP):
10124 Remove not used macro.
10125 (rs6000_loop_align): Change return type to align_flags.
10126 (rs6000_loop_align_max_skip): Remove.
10127 * config/rs6000/rs6000-protos.h (rs6000_loop_align):
10128 Change return type to align_flags.
10129 * config/rs6000/rs6000.c (TARGET_ASM_LOOP_ALIGN_MAX_SKIP):
10130 Remove not used macro.
10131 (rs6000_loop_align): Change return type to align_flags.
10132 (rs6000_loop_align_max_skip): Remove.
10133 * config/rx/rx.h (JUMP_ALIGN): Wrap integer values
10134 * config/rx/rx-protos.h (rx_align_for_label): Make it
10135 static function.
10136 * config/rx/rx.c (rx_align_for_label): Change return type
10137 to align_flags.
10138 (rx_max_skip_for_label): Remove TARGET_ASM_*_ALIGN_MAX_SKIP
10139 macro definitions.
10140 into align_flags class.
10141 (LABEL_ALIGN): Likewise.
10142 (LOOP_ALIGN): Likewise.
10143 * config/s390/s390.c (s390_label_align): Use align_flags
10144 class member.
10145 (s390_asm_output_function_label): Likewise.
10146 * config/sh/sh.c (sh_override_options_after_change):
10147 Use align_flags class directly without macros.
10148 (find_barrier): Likewise.
10149 (barrier_align): Likewise.
10150 (sh_loop_align): Likewise.
10151 * config/spu/spu.c (spu_option_override):
10152 Use align_flags_tuple::get_value instead of removed macros.
10153 (spu_sched_init): Likewise.
10154 * config/spu/spu.h (GTY): Likewise.
10155 * config/visium/visium.c (visium_option_override):
10156 Set "8" as default secondary alignment.
10157 * config/visium/visium.h (SUBALIGN_LOG): Define to 3
10158 in order to guarantee secondary alignment of 8.
10159 * coretypes.h: Include align.h header file.
10160 * doc/tm.texi: Remove TARGET_ASM_JUMP_ALIGN_MAX_SKIP,
10161 TARGET_ASM_LOOP_ALIGN_MAX_SKIP, TARGET_ASM_LABEL_ALIGN_MAX_SKIP
10162 and TARGET_ASM_LABEL_ALIGN_AFTER_BARRIER_MAX_SKIP macros.
10163 * doc/tm.texi.in: Likewise.
10164 * final.c (struct label_alignment): Remove not used structure.
10165 (LABEL_ALIGN): Change type to align_flags.
10166 (LOOP_ALIGN): Likewise.
10167 (JUMP_ALIGN): Likewise.
10168 (default_loop_align_max_skip): Remove.
10169 (default_label_align_max_skip): Likewise.
10170 (default_jump_align_max_skip): Likewise.
10171 (default_label_align_after_barrier_max_skip):
10172 (LABEL_TO_ALIGNMENT): Change to access label_align vector.
10173 (LABEL_TO_MAX_SKIP): Remove.
10174 (label_to_alignment): Return align_flags type instead of integer.
10175 (label_to_max_skip): Remove.
10176 (align_fuzz): Use align_flags type.
10177 (compute_alignments): Use align_flags type and use align_flags::max
10178 to combine multiple alignments.
10179 (grow_label_align): Grow vec instead of C array.
10180 (update_alignments): Assign just LABEL_TO_ALIGNMENT.
10181 (shorten_branches): Use align_flags type and use align_flags::max
10182 to combine multiple alignments.
10183 (final_scan_insn_1): Remove usage of secondary alignment that comes
10184 from label alignment, but instead use proper secondary alignment
10185 which is computed in grow_label_align.
10186 * flags.h (struct align_flags_tuple): Move to align.h.
10187 (struct align_flags): Likewise.
10188 (state_align_loops): Rename to align_loops.
10189 (state_align_jumps): Rename to align_jumps.
10190 (state_align_labels): Rename to align_labels.
10191 (state_align_functions): Rename to align_functions.
10192 (align_loops_log): Remove.
10193 (align_jumps_log): Remove.
10194 (align_labels_log): Remove.
10195 (align_functions_log): Remove.
10196 (align_loops_max_skip): Remove.
10197 (align_jumps_max_skip): Remove.
10198 (align_labels_max_skip): Remove.
10199 (align_functions_max_skip): Remove.
10200 (align_loops_value): Remove.
10201 (align_jumps_value): Remove.
10202 (align_labels_value): Remove.
10203 (align_functions_value): Remove.
10204 * output.h (label_to_alignment): Change return type to align_flags.
10205 (label_to_max_skip): Remove.
10206 * target.def: Remove loop_align_max_skip, label_align_max_skip,
10207 jump_align_max_skip macros.
10208 * targhooks.h (default_loop_align_max_skip): Remove.
10209 (default_label_align_max_skip): Likewise.
10210 (default_jump_align_max_skip): Likewise.
10211 (default_label_align_after_barrier_max_skip): Remove.
10212 * toplev.c (read_log_maxskip): Use ::normalize function.
10213 (parse_N_M): Remove not used argument and also call ::normalize.
10214 (parse_alignment_opts): Do not pass unused arguments.
10215 * varasm.c (assemble_start_function): Use directly align_functions
10216 instead of removed macros.
10217 * system.h: Do not poison removed macros.
10218
10219 2018-07-17 Jakub Jelinek <jakub@redhat.com>
10220
10221 PR middle-end/86539
10222 * gimplify.c (gimplify_omp_for): Ensure taskloop firstprivatized init
10223 and cond temporaries don't have reference type if iterator has
10224 pointer type. For init use &for_pre_body instead of pre_p if
10225 for_pre_body is non-empty.
10226
10227 2018-07-16 Segher Boessenkool <segher@kernel.crashing.org>
10228
10229 * config/rs6000/rs6000.md (trunc<mode>sf2): Expand truncates of
10230 double-double modes to SFmode directly directly.
10231 (trunc<mode>sf2_fprs): Delete.
10232
10233 2018-07-16 Segher Boessenkool <segher@kernel.crashing.org>
10234
10235 * config/rs6000/rs6000.c (init_float128_ibm): Use the correct names
10236 for conversions between IFmode and the decimal floating point modes.
10237 (init_float128_ieee): Use the correct names for conversions between
10238 KFmode and the decimal floating point modes.
10239
10240 2018-07-16 Segher Boessenkool <segher@kernel.crashing.org>
10241
10242 * config/rs6000/rs6000.c (init_float128_ibm): Use more correct names
10243 for the conversions between TDmode and IFmode.
10244 (init_float128_ieee): Use more correct names for the conversions
10245 between TDmode and KFmode.
10246
10247 2018-07-16 Jakub Jelinek <jakub@redhat.com>
10248
10249 PR tree-optimization/86526
10250 * builtins.c (expand_builtin_memcmp): Formatting fixes.
10251 (inline_expand_builtin_string_cmp): Likewise.
10252 (inline_string_cmp): Likewise. Use c_readstr instead of
10253 builtin_memcpy_read_str. Add unit_mode temporary.
10254
10255 2018-07-16 Bernd Edlinger <bernd.edlinger@hotmail.de>
10256
10257 PR middle-end/86528
10258 * builtins.c (check_access): Bail out if range[0] is no INTEGER_CST.
10259 * expr.c (string_constant): Fix the element size of ARRAY_TYPE.
10260
10261 2018-07-16 Kelvin Nilsen <kelvin@gcc.gnu.org>
10262
10263 * doc/extend.texi (PowerPC AltiVec Built-in Functions):
10264 Alphabetize prototypes of built-in functions, separating out
10265 built-in functions that are listed in this section but should be
10266 described elsewhere.
10267
10268 2018-07-16 Uros Bizjak <ubizjak@gmail.com>
10269
10270 PR target/86511
10271 * expmed.c (emit_store_flag): Do not emit setcc followed by a
10272 conditional move when trapping comparison was split to a
10273 non-trapping one (and vice versa).
10274
10275 2018-07-16 Ilya Leoshkevich <iii@linux.ibm.com>
10276
10277 * config/s390/s390.c (s390_function_profiler): Generate nops
10278 instead of profiler call sequences.
10279 * config/s390/s390.opt: Add the new option.
10280
10281 2018-07-16 Ilya Leoshkevich <iii@linux.ibm.com>
10282
10283 * config/s390/s390.c (s390_function_profiler): Generate
10284 __mcount_loc section.
10285 * config/s390/s390.opt: Add the new option.
10286
10287 2018-07-16 Ilya Leoshkevich <iii@linux.ibm.com>
10288
10289 * common.opt: Add the new warning.
10290 * config/s390/s390.c (s390_function_profiler): Emit "brasl
10291 %r0,__fentry__" when -mfentry is specified.
10292 (s390_option_override_internal): Disallow -mfentry for 31-bit
10293 CPUs.
10294 * config/s390/s390.opt: Add the new option.
10295
10296 2018-07-16 Richard Biener <rguenther@suse.de>
10297
10298 PR lto/86523
10299 * dwarf2out.c (dwarf2out_register_external_die): Assign DIE parents
10300 for function-local FUNCTION_DECL and RESULT_DECL immediately.
10301
10302 2018-07-16 Martin Liska <mliska@suse.cz>
10303
10304 PR ipa/86529
10305 * ipa-pure-const.c (malloc_candidate_p): Revert ::get
10306 to ::get_create.
10307
10308 2017-07-16 Claudiu Zissulescu <claziss@synopsys.com>
10309
10310 * config/arc/arcHS.md: Update ARCHS scheduling rules.
10311
10312 2017-07-16 Claudiu Zissulescu <claziss@synopsys.com>
10313
10314 * config/arc/arc-arch.h (arc_tune_attr): Add new tune parameters
10315 for ARCHS4x.
10316 * config/arc/arc-cpus.def (hs4x): New cpu.
10317 (hs4xd): Likewise.
10318 * config/arc/arc-tables.opt: Regenerate.
10319 * config/arc/arc.c (arc_sched_issue_rate): New function.
10320 (TARGET_SCHED_ISSUE_RATE): Define.
10321 (TARGET_SCHED_EXPOSED_PIPELINE): Likewise.
10322 * config/arc/arc.md (attr type): Add fpu_fuse, fpu_sdiv, fpu_ddiv,
10323 fpu_cvt.
10324 (attr tune): Add ARCHS4x tune values.
10325 (attr tune_dspmpy): Define.
10326 (*tst): Correct instruction type.
10327 * config/arc/arcHS.md: Don't use this automaton for ARCHS4x cpus.
10328 * config/arc/arcHS4x.md: New file.
10329 * config/arc/fpu.md: Update instruction type attributes.
10330 * config/arc/t-multilib: Regenerate.
10331
10332 2018-07-16 Tom de Vries <tdevries@suse.de>
10333
10334 PR debug/86455
10335 * var-tracking.c (vt_initialize): Fix pre_dec handling.
10336
10337 2018-07-16 Ramana Radhakrishnan <ramana.radhakrishnan@arm.com>
10338
10339 * config/aarch64/atomics.md (aarch64_store_execlusive<mode>): Add
10340 early clobber.
10341
10342 2018-07-16 Eric Botcazou <ebotcazou@adacore.com>
10343
10344 PR tree-optimization/86514
10345 * tree-ssa-reassoc.c (init_range_entry) <CASE_CONVERT>: Return for a
10346 conversion to a boolean type from a type with greater precision.
10347
10348 2018-07-16 Tom de Vries <tdevries@suse.de>
10349
10350 * var-tracking.c (vt_initialize): Print adjusted insn slim if
10351 dump_flags request TDF_SLIM.
10352
10353 2018-07-16 Aldy Hernandez <aldyh@redhat.com>
10354
10355 * fold-const.c (int_const_binop_1): Abstract...
10356 (wide_int_binop): ...wide int code here.
10357 (poly_int_binop): ...poly int code here.
10358 Abstract the rest of int_const_binop_1 into int_const_binop.
10359 * fold-const.h (wide_int_binop): New.
10360 * tree-vrp.c (vrp_int_const_binop): Call wide_int_binop.
10361 Remove useless PLUS/MINUS_EXPR case.
10362 (zero_nonzero_bits_from_vr): Move wide int code...
10363 (zero_nonzero_bits_from_bounds): ...here.
10364 (extract_range_from_binary_expr_1): Move mask optimization code...
10365 (range_easy_mask_min_max): ...here.
10366 * tree-vrp.h (zero_nonzero_bits_from_bounds): New.
10367 (range_easy_mask_min_max): New.
10368
10369 2018-07-15 Jeff Law <law@redhat.com>
10370
10371 PR target/85993
10372 * config/sh/sh.c (output_mi_thunk): Remove dead conditional
10373 block.
10374
10375 2018-07-14 Jim Wilson <jimw@sifive.com>
10376
10377 * config/riscv/linux.h (TARGET_ASM_FILE_END): New.
10378
10379 2018-07-14 Paul Koning <ni1d@arrl.net>
10380
10381 * config/pdp11/pdp11.c (pdp11_rtx_costs): Bugfixes.
10382
10383 2018-07-13 Jan Hubicka <hubicka@ucw.cz>
10384
10385 * lto-streamer-out.c (copy_function_or_variable): Dump info about
10386 copying section.
10387
10388 2018-07-13 Bill Schmidt <wschmidt@linux.ibm.com>
10389 Steve Munroe <munroesj52@gmail.com>
10390
10391 * config/rs6000/emmintrin.h (_mm_and_si128): New function.
10392 (_mm_andnot_si128): Likewise.
10393 (_mm_or_si128): Likewise.
10394 (_mm_xor_si128): Likewise.
10395
10396 2018-07-13 Qing Zhao <qing.zhao@oracle.com>
10397
10398 PR middle-end/78809
10399 * builtins.c (expand_builtin_memcmp): Inline the calls first
10400 when result_eq is false.
10401 (expand_builtin_strcmp): Inline the calls first.
10402 (expand_builtin_strncmp): Likewise.
10403 (inline_string_cmp): New routine. Expand a string compare
10404 call by using a sequence of char comparison.
10405 (inline_expand_builtin_string_cmp): New routine. Inline expansion
10406 a call to str(n)cmp/memcmp.
10407 * doc/invoke.texi (--param builtin-string-cmp-inline-length):
10408 New option.
10409 * params.def (BUILTIN_STRING_CMP_INLINE_LENGTH): New.
10410
10411 2018-07-13 Richard Earnshaw <rearnsha@arm.com>
10412
10413 * config/arm/driver-arm.c: Include arm-native.h.
10414 (host_detect_local_cpu): Use auto-generated data tables.
10415 (vendors, arm_cpu_table): Delete. Move part information to ...
10416 * config/arm/arm-cpus.in: ... here.
10417 * config/arm/parsecpu.awk (gen_native): New function.
10418 (vendor, part): New CPU fields.
10419 (END): Add support for building the native CPU detection tables.
10420 * config/arm/t-arm (arm-native.h): Add build rule.
10421 (driver-arm.o): Add dependency on arm-native.h.
10422
10423 2018-07-13 Richard Biener <rguenther@suse.de>
10424
10425 PR middle-end/85974
10426 * match.pd (addr1 - addr2): Allow either of the operand to
10427 have a conversion.
10428
10429 2018-07-13 Tom de Vries <tdevries@suse.de>
10430
10431 * tree-inline.c (remap_ssa_name): Save and reuse debug exprs generated
10432 in remap_ssa_name.
10433
10434 2018-07-13 Jackson Woodruff <jackson.woodruff@arm.com>
10435
10436 * config/aarch64/aarch64.c (aarch64_operands_adjust_ok_for_ldpstp): Use
10437 arrays instead of numbered variables.
10438
10439 2018-07-13 Eric Botcazou <ebotcazou@adacore.com>
10440
10441 * config/sparc/sparc-protos.h (sparc_compute_frame_size): Delete.
10442 * config/sparc/sparc.c (sparc_compute_frame_size): Make static.
10443
10444 2018-07-13 Richard Biener <rguenther@suse.de>
10445
10446 PR debug/86452
10447 * dwarf2out.c (gen_type_die_with_usage): Use scope_die_for
10448 instead of get_context_die.
10449
10450 2018-07-13 Kugan Vivekanandarajah <kuganv@linaro.org>
10451 Richard Biener <rguenther@suse.de>
10452
10453 PR middle-end/86489
10454 * tree-ssa-loop-niter.c (number_of_iterations_popcount): Check
10455 that the loop latch destination where phi is defined.
10456
10457 2018-07-12 Kito Cheng <kito.cheng@gmail.com>
10458
10459 * config/riscv/riscv.c (enum riscv_privilege_levels): Add UNKNOWN_MODE.
10460 (riscv_expand_epilogue): Add assertion to check interrupt mode.
10461 (riscv_set_current_function): Extract getting interrupt type to new
10462 function.
10463 (riscv_get_interrupt_type): New function.
10464 (riscv_merge_decl_attributes): New function, checking interrupt type is
10465 same.
10466 (TARGET_MERGE_DECL_ATTRIBUTES): Define.
10467
10468 2018-07-12 Paul Koning <ni1d@arrl.net>
10469
10470 * config/pdp11/pdp11.c (pdp11_output_def): Fix typo in .set
10471 directive.
10472
10473 2018-07-12 Paul Koning <ni1d@arrl.net>
10474
10475 * doc/rtl.texi (REG_NONNEG): Remove decrement and branch until
10476 zero reference, add doloop_end instead.
10477 * doc/md.texi (decrement_and_branch_until_zero): Remove.
10478 (Looping patterns): Remove decrement_and_branch_until_zero. Add
10479 detail for doloop_end.
10480
10481 2018-07-12 Martin Sebor <msebor@redhat.com>
10482
10483 PR c/86453
10484 * attribs.c (decl_attributes): Reject conflicting attributes before
10485 calling attribute handlers.
10486
10487 2018-07-12 Jan Hubicka <hubicka@ucw.cz>
10488
10489 * dumpfile.c (gcc::dump_manager::get_dump_file_name): Add PART
10490 parameter.
10491 (gcc::dump_manager::get_dump_file_name): likewise.
10492 (dump_begin): Likewise.
10493 * dumpfile.h (dump_begin): Update prototype.
10494 (gcc::dump_manager::get_dump_file_name,
10495 gcc::dump_manager::get_dump_file_name): Update prototype.
10496
10497 2018-07-12 Richard Sandiford <richard.sandiford@linaro.org>
10498
10499 * internal-fn.h (vectorizable_internal_fn_p): New function.
10500 * tree-vect-slp.c (compatible_calls_p): Likewise.
10501 (vect_build_slp_tree_1): Remove nops argument. Handle calls
10502 to internal functions.
10503 (vect_build_slp_tree_2): Update call to vect_build_slp_tree_1.
10504
10505 2018-07-12 Richard Sandiford <richard.sandiford@linaro.org>
10506
10507 * fold-const.h (inverse_conditions_p): Declare.
10508 * fold-const.c (inverse_conditions_p): New function.
10509 * match.pd: Use inverse_conditions_p. Add folds of view_converts
10510 that test the inverse condition of a conditional internal function.
10511 * internal-fn.h (vectorized_internal_fn_supported_p): Declare.
10512 * internal-fn.c (internal_fn_mask_index): Handle conditional
10513 internal functions.
10514 (vectorized_internal_fn_supported_p): New function.
10515 * tree-if-conv.c: Include internal-fn.h and fold-const.h.
10516 (any_pred_load_store): Replace with...
10517 (need_to_predicate): ...this new variable.
10518 (redundant_ssa_names): New variable.
10519 (ifcvt_can_use_mask_load_store): Move initial checks to...
10520 (ifcvt_can_predicate): ...this new function. Handle tree codes
10521 for which a conditional internal function exists.
10522 (if_convertible_gimple_assign_stmt_p): Use ifcvt_can_predicate
10523 instead of ifcvt_can_use_mask_load_store. Update after variable
10524 name change.
10525 (predicate_load_or_store): New function, split out from
10526 predicate_mem_writes.
10527 (check_redundant_cond_expr): New function.
10528 (value_available_p): Likewise.
10529 (predicate_rhs_code): Likewise.
10530 (predicate_mem_writes): Rename to...
10531 (predicate_statements): ...this. Use predicate_load_or_store
10532 and predicate_rhs_code.
10533 (combine_blocks, tree_if_conversion): Update after above name changes.
10534 (ifcvt_local_dce): Handle redundant_ssa_names.
10535 * tree-vect-patterns.c (vect_recog_mask_conversion_pattern): Handle
10536 general conditional functions.
10537 * tree-vect-stmts.c (vectorizable_call): Likewise.
10538
10539 2018-07-12 Richard Sandiford <richard.sandiford@linaro.org>
10540 Alan Hayward <alan.hayward@arm.com>
10541 David Sherwood <david.sherwood@arm.com>
10542
10543 * internal-fn.h (can_interpret_as_conditional_op_p): Declare.
10544 * internal-fn.c (can_interpret_as_conditional_op_p): New function.
10545 * tree-ssa-math-opts.c (convert_mult_to_fma_1): Handle conditional
10546 plus and minus and convert them into IFN_COND_FMA-based sequences.
10547 (convert_mult_to_fma): Handle conditional plus and minus.
10548
10549 2018-07-12 Richard Sandiford <richard.sandiford@linaro.org>
10550
10551 * doc/md.texi (cond_fma, cond_fms, cond_fnma, cond_fnms): Document.
10552 * optabs.def (cond_fma_optab, cond_fms_optab, cond_fnma_optab)
10553 (cond_fnms_optab): New optabs.
10554 * internal-fn.def (COND_FMA, COND_FMS, COND_FNMA, COND_FNMS): New
10555 internal functions.
10556 (FMA): Use DEF_INTERNAL_FLT_FN rather than DEF_INTERNAL_FLT_FLOATN_FN.
10557 * internal-fn.h (get_conditional_internal_fn): Declare.
10558 (get_unconditional_internal_fn): Likewise.
10559 * internal-fn.c (cond_ternary_direct): New macro.
10560 (expand_cond_ternary_optab_fn): Likewise.
10561 (direct_cond_ternary_optab_supported_p): Likewise.
10562 (FOR_EACH_COND_FN_PAIR): Likewise.
10563 (get_conditional_internal_fn): New function.
10564 (get_unconditional_internal_fn): Likewise.
10565 * gimple-match.h (gimple_match_op::MAX_NUM_OPS): Bump to 5.
10566 (gimple_match_op::gimple_match_op): Add a new overload for 5
10567 operands.
10568 (gimple_match_op::set_op): Likewise.
10569 (gimple_resimplify5): Declare.
10570 * genmatch.c (decision_tree::gen): Generate simplifications for
10571 5 operands.
10572 * gimple-match-head.c (gimple_simplify): Define an overload for
10573 5 operands. Handle calls with 5 arguments in the top-level overload.
10574 (convert_conditional_op): Handle conversions from unconditional
10575 internal functions to conditional ones.
10576 (gimple_resimplify5): New function.
10577 (build_call_internal): Pass a fifth operand.
10578 (maybe_push_res_to_seq): Likewise.
10579 (try_conditional_simplification): Try converting conditional
10580 internal functions to unconditional internal functions.
10581 Handle 3-operand unconditional forms.
10582 * match.pd (UNCOND_TERNARY, COND_TERNARY): Operator lists.
10583 Define ternary equivalents of the current rules for binary conditional
10584 internal functions.
10585 * config/aarch64/aarch64.c (aarch64_preferred_else_value): Handle
10586 ternary operations.
10587 * config/aarch64/iterators.md (UNSPEC_COND_FMLA, UNSPEC_COND_FMLS)
10588 (UNSPEC_COND_FNMLA, UNSPEC_COND_FNMLS): New unspecs.
10589 (optab): Handle them.
10590 (SVE_COND_FP_TERNARY): New int iterator.
10591 (sve_fmla_op, sve_fmad_op): New int attributes.
10592 * config/aarch64/aarch64-sve.md (cond_<optab><mode>)
10593 (*cond_<optab><mode>_2, *cond_<optab><mode_4)
10594 (*cond_<optab><mode>_any): New SVE_COND_FP_TERNARY patterns.
10595
10596 2018-07-12 Richard Sandiford <richard.sandiford@linaro.org>
10597
10598 * target.def (preferred_else_value): New target hook.
10599 * doc/tm.texi.in (TARGET_PREFERRED_ELSE_VALUE): New hook.
10600 * doc/tm.texi: Regenerate.
10601 * targhooks.h (default_preferred_else_value): Declare.
10602 * targhooks.c (default_preferred_else_value): New function.
10603 * internal-fn.h (conditional_internal_fn_code): Declare.
10604 * internal-fn.c (FOR_EACH_CODE_MAPPING): New macro.
10605 (get_conditional_internal_fn): Use it.
10606 (conditional_internal_fn_code): New function.
10607 * gimple-match.h (gimple_match_cond): New struct.
10608 (gimple_match_op): Add a cond member function.
10609 (gimple_match_op::gimple_match_op): Update all forms to take a
10610 gimple_match_cond.
10611 * genmatch.c (expr::gen_transform): Use the same condition as res_op
10612 for the suboperation, but don't specify a particular else_value.
10613 * tree-ssa-sccvn.c (vn_nary_simplify, vn_reference_lookup_3)
10614 (visit_nary_op, visit_reference_op_load): Pass
10615 gimple_match_cond::UNCOND to the gimple_match_op constructor.
10616 * gimple-match-head.c: Include tree-eh.h
10617 (convert_conditional_op): New function.
10618 (maybe_resimplify_conditional_op): Likewise.
10619 (gimple_resimplify1): Call maybe_resimplify_conditional_op.
10620 (gimple_resimplify2): Likewise.
10621 (gimple_resimplify3): Likewise.
10622 (gimple_resimplify4): Likewise.
10623 (maybe_push_res_to_seq): Return null for conditional operations.
10624 (try_conditional_simplification): New function.
10625 (gimple_simplify): Call it. Pass conditions to the gimple_match_op
10626 constructor.
10627 * match.pd: Fold VEC_COND_EXPRs of an IFN_COND_* call to a new
10628 IFN_COND_* call.
10629 * config/aarch64/aarch64.c (aarch64_preferred_else_value): New
10630 function.
10631 (TARGET_PREFERRED_ELSE_VALUE): Redefine.
10632
10633 2018-07-12 Jan Hubicka <hubicka@ucw.cz>
10634
10635 * lto-streamer-out.c (DFS::DFS_write_tree_body): Do not stream
10636 DECL_FCONTEXT
10637 (hash_tree): Do not hash DECL_FCONTEXT
10638 * tree-streamer-in.c (lto_input_ts_field_decl_tree_pointers):
10639 Do not stream DECL_FCONTEXT.
10640 * tree-streamer-out.c (write_ts_field_decl_tree_pointers): Likewise.
10641 * tree.c (free_lang_data_in_decl): Free DECL_FCONTEXT.
10642
10643 2018-07-12 Richard Biener <rguenther@suse.de>
10644
10645 PR debug/86462
10646 * dwarf2out.c (gen_block_die): Only output blocks when they have
10647 at least one !DECL_IGNORED_P variable.
10648
10649 2018-07-12 Richard Biener <rguenther@suse.de>
10650
10651 PR target/84829
10652 * config/gnu-user.h (GNU_USER_TARGET_NO_PTHREADS_LIB_SPEC):
10653 Remove -mieee-fp handling.
10654
10655 2018-07-12 Richard Biener <rguenther@suse.de>
10656
10657 * tree-ssa-sccvn.c (vn_lookup_simplify_result): Remove bogus
10658 left-over from last patch.
10659
10660 2018-07-12 Jakub Jelinek <jakub@redhat.com>
10661
10662 PR tree-optimization/86492
10663 * gimple-ssa-store-merging.c
10664 (imm_store_chain_info::coalesce_immediate_stores): Call
10665 check_no_overlap even for the merge_overlapping case. Formatting fix.
10666
10667 2018-07-12 Richard Biener <rguenther@suse.de>
10668
10669 PR middle-end/86479
10670 * fold-const.c (fold_binary_op_with_conditional_arg): Do not
10671 move possibly trapping operations into the conditional.
10672
10673 2018-07-12 Richard Biener <rguenther@suse.de>
10674
10675 * tree-ssa-sccvn.c (mprts_hook_cnt): Remove.
10676 (vn_lookup_simplify_result): Remove recursion limit applied
10677 here.
10678 (vn_nary_build_or_lookup_1): Adjust.
10679 (try_to_simplify): Likewise.
10680 * gimple-match-head.c (gimple_resimplify1): Instead apply one
10681 here.
10682 (gimple_resimplify2): Likewise.
10683 (gimple_resimplify3): Likewise.
10684 (gimple_resimplify4): Likewise.
10685
10686 2018-07-11 Jakub Jelinek <jakub@redhat.com>
10687
10688 * config/i386/avx512bitalgintrin.h (_mm512_mask_bitshuffle_epi64_mask):
10689 Use __mmask64 type instead of __mmask8 for __M argument.
10690 * config/i386/avx512fintrin.h (_mm512_mask_xor_epi64,
10691 _mm512_maskz_xor_epi64): Use __mmask8 type instead of __mmask16 for
10692 __U argument.
10693 (_mm512_mask_cmpneq_epi64_mask): Use __mmask8 type instead of
10694 __mmask16 for __M argument.
10695 (_mm512_maskz_insertf32x4, _mm512_maskz_inserti32x4,
10696 _mm512_mask_insertf32x4, _mm512_mask_inserti32x4): Cast last argument
10697 to __mmask16 instead of __mmask8.
10698 * config/i386/avx512vlintrin.h (_mm_mask_add_ps, _mm_maskz_add_ps,
10699 _mm256_mask_add_ps, _mm256_maskz_add_ps, _mm_mask_sub_ps,
10700 _mm_maskz_sub_ps, _mm256_mask_sub_ps, _mm256_maskz_sub_ps,
10701 _mm256_maskz_cvtepi32_ps, _mm_maskz_cvtepi32_ps): Use __mmask8 type
10702 instead of __mmask16 for __U argument.
10703 * config/i386/avx512vlbwintrin.h (_mm_mask_cmp_epi8_mask): Use
10704 __mmask16 instead of __mmask8 for __U argument.
10705 (_mm256_mask_cmp_epi8_mask): Use __mmask32 instead of __mmask16 for
10706 __U argument.
10707 (_mm256_cmp_epi8_mask): Use __mmask32 return type instead of
10708 __mmask16.
10709 (_mm_mask_cmp_epu8_mask): Use __mmask16 instead of __mmask8 for __U
10710 argument.
10711 (_mm256_mask_cmp_epu8_mask): Use __mmask32 instead of __mmask16 for
10712 __U argument.
10713 (_mm256_cmp_epu8_mask): Use __mmask32 return type instead of
10714 __mmask16.
10715 (_mm_mask_cmp_epi16_mask): Cast last argument to __mmask8 instead
10716 of __mmask16.
10717 (_mm256_mask_cvtepi8_epi16): Use __mmask16 instead of __mmask32 for
10718 __U argument.
10719 (_mm_mask_cvtepi8_epi16): Use __mmask8 instead of __mmask32 for
10720 __U argument.
10721 (_mm256_mask_cvtepu8_epi16): Use __mmask16 instead of __mmask32 for
10722 __U argument.
10723 (_mm_mask_cvtepu8_epi16): Use __mmask8 instead of __mmask32 for
10724 __U argument.
10725 (_mm256_mask_cmpneq_epu8_mask, _mm256_mask_cmplt_epu8_mask,
10726 _mm256_mask_cmpge_epu8_mask, _mm256_mask_cmple_epu8_mask): Change
10727 return type as well as __M argument type and all casts from __mmask8
10728 to __mmask32.
10729 (_mm256_mask_cmpneq_epu16_mask, _mm256_mask_cmplt_epu16_mask,
10730 _mm256_mask_cmpge_epu16_mask, _mm256_mask_cmple_epu16_mask): Change
10731 return type as well as __M argument type and all casts from __mmask8
10732 to __mmask16.
10733 (_mm256_mask_cmpneq_epi8_mask, _mm256_mask_cmplt_epi8_mask,
10734 _mm256_mask_cmpge_epi8_mask, _mm256_mask_cmple_epi8_mask): Change
10735 return type as well as __M argument type and all casts from __mmask8
10736 to __mmask32.
10737 (_mm256_mask_cmpneq_epi16_mask, _mm256_mask_cmplt_epi16_mask,
10738 _mm256_mask_cmpge_epi16_mask, _mm256_mask_cmple_epi16_mask): Change
10739 return type as well as __M argument type and all casts from __mmask8
10740 to __mmask16.
10741 * config/i386/avx512vbmi2vlintrin.h (_mm_mask_shrdi_epi32,
10742 _mm_mask_shldi_epi32): Cast last argument to __mmask8 instead of
10743 __mmask16.
10744
10745 2018-07-11 Grazvydas Ignotas <notasas@gmail.com>
10746
10747 * config/i386/avx512bwintrin.h: (_mm512_mask_cmp_epi8_mask,
10748 _mm512_mask_cmp_epu8_mask): Use __mmask64 type instead of __mmask32
10749 for __U argument.
10750
10751 2018-07-11 Paul Koning <ni1d@arrl.net>
10752
10753 * doc/md.texi (define_subst): Document how multiple occurrences of
10754 the same argument in the replacement pattern are handled.
10755
10756 2018-07-11 Paul Koning <ni1d@arrl.net>
10757
10758 * doc/extend.texi (Common Variable Attributes): Move "mode" into
10759 alphabetical order.
10760 (Common Type Attributes): Add "mode" attribute.
10761
10762 2018-07-11 Jan Hubicka <hubicka@ucw.cz>
10763
10764 * lto-streamer-out.c (DFS::DFS_write_tree_body): Do not
10765 stream DECL_ORIGINAL_TYPE.
10766 (DFS::DFS_write_tree_body): Drop hack handling local external decls.
10767 (hash_tree): Do not walk DECL_ORIGINAL_TYPE.
10768 * tree-streamer-in.c (lto_input_ts_decl_non_common_tree_pointers):
10769 Do not walk original type.
10770 * tree-streamer-out.c (streamer_write_chain): Drop hack handling
10771 external decls.
10772 (write_ts_decl_non_common_tree_pointers): Do not stream
10773 DECL_ORIGINAL_TYPE
10774 * tree.c (free_lang_data_in_decl): Clear DECL_ORIGINAL_TYPE.
10775 (find_decls_types_r): Do not walk DEC_ORIGINAL_TYPE.
10776
10777 2018-07-11 Aldy Hernandez <aldyh@redhat.com>
10778
10779 * tree-ssa-threadupdate.c (thread_through_all_blocks): Do not jump
10780 thread twice from the same starting edge.
10781
10782 2018-07-11 Aldy Hernandez <aldyh@redhat.com>
10783
10784 * vr-values.c (gimple_stmt_nonzero_p): Abstract common code to...
10785 * gimple.c (gimple_call_nonnull_result_p): ...here...
10786 (gimple_call_nonnull_arg): ...and here.
10787 * gimple.h (gimple_call_nonnull_result_p): New.
10788 (gimple_call_nonnull_arg): New.
10789
10790 2018-07-11 Richard Earnshaw <rearnsha@arm.com>
10791
10792 * config/arm/arm-cpus.in: Move information from fpu field of each
10793 cpu definition to the isa field.
10794 * config/arm/parsecpu.awk (fpu): Delete match rule.
10795 (gen_comm_data): Don't add bits from the CPU's FPU entry.
10796
10797 2018-07-11 Richard Biener <rguenther@suse.de>
10798
10799 PR debug/86457
10800 * dwarf2out.c (init_sections_and_labels): Use
10801 output_asm_line_debug_info consistently.
10802 (dwarf2out_early_finish): Likewise.
10803 (dwarf2out_finish): Remove DW_AT_stmt_list from early generated
10804 type units.
10805
10806 2018-07-11 Richard Biener <rguenther@suse.de>
10807
10808 * tree-ssa-loop-ivcanon.c (tree_unroll_loops_completely_1):
10809 Rework father_bb setting in a way to avoid propagating constants
10810 multiple times on a loop body.
10811
10812 2018-07-10 Mark Wielaard <mark@klomp.org>
10813
10814 PR debug/86459
10815 * dwarf2out.c (output_macinfo_op): Fix dwarf_FORM typo in gcc_assert.
10816
10817 2018-07-10 Richard Biener <rguenther@suse.de>
10818
10819 * hash-map.h (hash_map::iterator::operator*): Return
10820 references to key and value.
10821
10822 2018-07-10 Jakub Jelinek <jakub@redhat.com>
10823
10824 PR c++/86443
10825 * gimplify.c (find_combined_omp_for): Add DATA argument, in addition
10826 to finding the inner OMP_FOR/OMP_SIMD stmt find non-trivial wrappers,
10827 BLOCKs with BLOCK_VARs, OMP_PARALLEL in between, OMP_FOR in between.
10828 (gimplify_omp_for): For composite loops, move outer
10829 OMP_{DISTRIBUTE,TASKLOOP,FOR,PARALLEL} right around innermost
10830 OMP_FOR/OMP_SIMD if there are any non-trivial wrappers. For class
10831 iterators add any needed clauses. Allow OMP_FOR_ORIG_DECLS to contain
10832 TREE_LIST for both the original class iterator and the "last" helper
10833 var. Gimplify OMP_FOR_PRE_BODY before the outermost composite
10834 loop, remember has_decl_expr from outer composite loops for the
10835 innermost OMP_SIMD in TREE_PRIVATE bit on OMP_FOR_INIT.
10836
10837 2018-07-09 Martin Sebor <msebor@redhat.com>
10838
10839 PR middle-end/77357
10840 PR middle-end/86428
10841 * builtins.c (c_strlen): Avoid out-of-bounds warnings when
10842 accessing implicitly initialized array elements.
10843 * expr.c (string_constant): Handle string initializers of
10844 character arrays within aggregates.
10845 * gimple-fold.c (fold_array_ctor_reference): Add argument.
10846 Store element offset. As a special case, handle zero size.
10847 (fold_nonarray_ctor_reference): Same.
10848 (fold_ctor_reference): Add argument. Store subobject offset.
10849 * gimple-fold.h (fold_ctor_reference): Add argument.
10850
10851 2018-07-09 Paul Koning <ni1d@arrl.net>
10852
10853 * config/pdp11/pdp11.c (pdp11_addr_cost): New function.
10854 (pdp11_insn_cost): New function.
10855 (pdp11_md_asm_adjust): New function.
10856 (TARGET_INVALID_WITHIN_DOLOOP): Define.
10857 (pdp11_rtx_costs): Update to match machine better.
10858 (output_addr_const_pdp11): Correct format mismatch warnings.
10859 * config/pdp11/pdp11.h (SLOW_BYTE_ACCESS): Correct definition.
10860 * config/pdp11/pdp11.md: General change to add base_cost and/or
10861 length attributes for use by new pdp11_insn_cost function.
10862 (MIN_BRANCH): Correct definition.
10863 (MIN_SOB): Ditto.
10864 (doloop_end): Use standard pattern name for looping pattern.
10865 (doloop_end_nocc): New.
10866 (movsf): Add another constraint alternative.
10867 (zero_extendqihi2): Add constraint alternatives for not in place
10868 extend.
10869 (zero_extendhisi2): Remove.
10870 (shift patterns): Add CC handling variants.
10871 (bswaphi2): New.
10872 (bswapsi2): New.
10873 (rothi3): New.
10874 (define_peephole2): New peephole to recognize mov that sets CC for
10875 subsequent test.
10876
10877 2018-07-09 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
10878
10879 * config/sparc/sparc.c (sparc_fold_builtin) <SPARC_BUILTIN_PDIST,
10880 SPARC_BUILTIN_PDISTN>: Adapt for signature change of wi::neg,
10881 wi::add.
10882
10883 2018-07-09 Jakub Jelinek <jakub@redhat.com>
10884
10885 PR c/86420
10886 * real.c (real_nextafter): Return true if result is denormal.
10887
10888 2018-07-09 Martin Liska <mliska@suse.cz>
10889
10890 * common.opt: Add back wrongly removed attribute.
10891
10892 2018-07-09 Richard Biener <rguenther@suse.de>
10893
10894 PR debug/86413
10895 * dwarf2out.c (gen_block_die): For an early generated DIE
10896 always output high/low PC attributes.
10897
10898 2018-07-09 Tom de Vries <tdevries@suse.de>
10899
10900 * cfgexpand.c (expand_debug_source_expr): Handle VAR_DECL.
10901 * tree-inline.c (remap_ssa_name): Handle default def ssa_name mapping
10902 onto VAR_DECL with abstract origin.
10903
10904 2018-07-07 Jim Wilson <jimw@sifive.com>
10905
10906 * config/riscv/riscv.c (TARGET_CUSTOM_FUNCTION_DESCRIPTORS): New.
10907
10908 2018-07-07 Tom de Vries <tdevries@suse.de>
10909
10910 * tree-dfa.c (dump_enumerated_decls): Handle cfun->cfg == NULL.
10911
10912 2018-07-07 Aldy Hernandez <aldyh@redhat.com>
10913
10914 * tree-vrp.c (vrp_int_const_binop): Change overflow type to
10915 overflow_type.
10916 (combine_bound): Use wide-int overflow calculation instead of
10917 rolling our own.
10918 * calls.c (maybe_warn_alloc_args_overflow): Change overflow type to
10919 overflow_type.
10920 * fold-const.c (int_const_binop_2): Same.
10921 (extract_muldiv_1): Same.
10922 (fold_div_compare): Same.
10923 (fold_abs_const): Same.
10924 * match.pd: Same.
10925 * poly-int.h (add): Same.
10926 (sub): Same.
10927 (neg): Same.
10928 (mul): Same.
10929 * predict.c (predict_iv_comparison): Same.
10930 * profile-count.c (slow_safe_scale_64bit): Same.
10931 * simplify-rtx.c (simplify_const_binary_operation): Same.
10932 * tree-chrec.c (tree_fold_binomial): Same.
10933 * tree-data-ref.c (split_constant_offset_1): Same.
10934 * tree-if-conv.c (idx_within_array_bound): Same.
10935 * tree-scalar-evolution.c (iv_can_overflow_p): Same.
10936 * tree-ssa-phiopt.c (minmax_replacement): Same.
10937 * tree-vect-loop.c (is_nonwrapping_integer_induction): Same.
10938 * tree-vect-stmts.c (vect_truncate_gather_scatter_offset): Same.
10939 * vr-values.c (vr_values::adjust_range_with_scev): Same.
10940 * wide-int.cc (wi::add_large): Same.
10941 (wi::mul_internal): Same.
10942 (wi::sub_large): Same.
10943 (wi::divmod_internal): Same.
10944 * wide-int.h: Change overflow type to overflow_type for neg, add,
10945 mul, smul, umul, div_trunc, div_floor, div_ceil, div_round,
10946 mod_trunc, mod_ceil, mod_round, add_large, sub_large,
10947 mul_internal, divmod_internal.
10948 (overflow_type): New enum.
10949 (accumulate_overflow): New.
10950
10951 2018-07-06 Kugan Vivekanandarajah <kugan.vivekanandarajah@linaro.org>
10952
10953 * tree-ssa-phiopt.c (cond_removal_in_popcount_pattern): New.
10954 (tree_ssa_phiopt_worker): Call cond_removal_in_popcount_pattern.
10955
10956 2018-07-06 Kugan Vivekanandarajah <kuganv@linaro.org>
10957
10958 * tree-ssa-loop-niter.c (number_of_iterations_popcount): If popcount
10959 argument is checked for zero before entering loop, avoid checking again.
10960
10961 2018-07-06 Kugan Vivekanandarajah <kuganv@linaro.org>
10962
10963 * gimplify.h (generic_expr_could_trap_p): Set as global function.
10964 * gimplify.h (generic_expr_could_trap_p): Likwise.
10965 * tree-scalar-evolution.c (expression_expensive_p): Handle COND_EXPR.
10966
10967 2018-07-06 Jakub Jelinek <jakub@redhat.com>
10968
10969 PR tree-optimization/86401
10970 * fold-const.c (fold_binary_loc) <case BIT_AND_EXPR>: Move the
10971 ((A & N) + B) & M -> (A + B) & M etc. optimization into ...
10972 (fold_bit_and_mask): ... here. New helper function for match.pd.
10973 * fold-const.h (fold_bit_and_mask): Declare.
10974 * match.pd (((A & N) + B) & M -> (A + B) & M): New optimization.
10975
10976 2018-07-06 Peter Bergner <bergner@linux.ibm.com>
10977
10978 PR target/86324
10979 * target.def (translate_mode_attribute): New hook.
10980 * targhooks.h (default_translate_mode_attribute): Declare.
10981 * targhooks.c (default_translate_mode_attribute): New function.
10982 * doc/tm.texi.in (TARGET_TRANSLATE_MODE_ATTRIBUTE): New hook.
10983 * doc/tm.texi: Regenerate.
10984 * config/rs6000/rs6000.c (TARGET_TRANSLATE_MODE_ATTRIBUTE): Define.
10985 (rs6000_translate_mode_attribute): New function.
10986
10987 2018-07-06 Paul Koning <ni1d@arrl.net>
10988
10989 * doc/md.texi (define_split): Document DONE and FAIL.
10990 (define_peephole2): Ditto.
10991
10992 2018-07-05 Jeff Law <law@redhat.com>
10993
10994 PR tree-optimization/86010
10995 * tree-ssa-dse.c (compute_trims): More aggressively trim at
10996 both the head and tail of mem* and str* calls.
10997
10998 2018-07-05 Jim Wilson <jimw@sifive.com>
10999
11000 * config.gcc (riscv*-*-*): When setting xlen, handle riscv-*.
11001
11002 2018-07-05 Indu Bhagat <indu.bhagat@oracle.com>
11003
11004 * config/aarch64/aarch64-simd.md: correct flags text for
11005 MIN_EXPR replacement.
11006
11007 2018-07-05 James Clarke <jrtc27@jrtc27.com>
11008
11009 * configure: Regenerated.
11010
11011 2018-07-05 Carl Love <cel@us.ibm.com>
11012
11013 * config/rs6000/rs6000-c.c: Map ALTIVEC_BUILTIN_VEC_UNPACKH for
11014 float argument to VSX_BUILTIN_DOUBLEH_V4SF.
11015 Map ALTIVEC_BUILTIN_VEC_UNPACKL for float argument to
11016 VSX_BUILTIN_DOUBLEL_V4SF.
11017
11018 2018-07-05 Martin Sebor <msebor@redhat.com>
11019
11020 PR c++/86400
11021 * tree-ssa-strlen.c (maybe_set_strlen_range): Use type size rather
11022 than its domain to compute its the upper bound of a char array.
11023
11024 2018-07-05 Nathan Sidwell <nathan@acm.org>
11025
11026 Replace NO_IMPLICIT_EXTERN_C with SYSTEM_IMPLICIT_EXTERN_C.
11027 * doc/cpp.texi: Update comment.
11028 * doc/tm.texi: Rebuilt.
11029 * doc/tm.texi.in (NO_IMPLICIT_EXTERN_C): Replace with ...
11030 (SYSTEM_IMPLICIT_EXTERN_C): ... this, opposite sense.
11031 * doc/extend.texi (Backwards Compatibility): Clarify it is system
11032 headers affected by extern "C".
11033 * system.h: Poison NO_IMPLICIT_EXTERN_C.
11034 * config/alpha/alpha.h, config/arm/uclinux-elf.h,
11035 config/bfin/elf.h, config/cris/cris.h, config/darwin.h,
11036 config/dragonfly.h, config/freebsd.h, config/gnu-user.h,
11037 config/i386/cygming.h, config/i386/djgpp.h, config/i386/nto.h,
11038 config/ia64/hpux.h, config/lm32/lm32.h, config/lm32/uclinux-elf.h,
11039 config/lynx.h, config/mips/elf.h, config/mmix/mmix.h,
11040 config/netbsd.h, config/pa/pa-hpux.h, config/powerpcspe/sysv4.h,
11041 config/riscv/elf.h, config/rs6000/sysv4.h, config/rtems.h,
11042 config/s390/tpf.h, config/sh/newlib.h, config/sol2.h,
11043 config/sparc/openbsd64.h, config/sparc/sp-elf.h,
11044 config/sparc/sp64-elf.h, config/spu/spu.h,
11045 config/stormy16/stormy16.h, config/v850/v850.h,
11046 config/visium/visium.h, config/vx-common.h, config/xtensa/elf.h: Don't
11047 define NO_IMPLICIT_EXTERN_C.
11048 * config/rs6000/aix.h: Set SYSTEM_IMPLICIT_EXTERN_C.
11049
11050 2018-07-05 Tamar Christina <tamar.christina@arm.com>
11051
11052 PR target/84711
11053 * config/arm/arm.c (arm_can_change_mode_class): Use GET_MODE_UNIT_SIZE
11054 instead of GET_MODE_SIZE when comparing Units.
11055
11056 2018-07-05 Tamar Christina <tamar.christina@arm.com>
11057
11058 PR target/84711
11059 * rtlanal.c (set_noop_p): Constrain on mode change,
11060 include hard-reg-set.h
11061
11062 2018-07-05 Tamar Christina <tamar.christina@arm.com>
11063
11064 * config/aarch64/aarch64.c (aarch64_expand_movmem): Fix mode size.
11065
11066 2018-07-05 Jakub Jelinek <jakub@redhat.com>
11067
11068 Revert
11069 2018-07-04 Maxim Ostapenko <m.ostapenko@samsung.com>
11070
11071 PR sanitizer/84250
11072 * config/gnu-user.h (LIBASAN_EARLY_SPEC): Pass -lstdc++ for static
11073 libasan.
11074 * gcc.c: Do not pass LIBUBSAN_SPEC if ASan is enabled with UBSan.
11075
11076 2018-07-04 Maxim Ostapenko <m.ostapenko@samsung.com>
11077
11078 PR sanitizer/84250
11079 * config/gnu-user.h (LIBASAN_EARLY_SPEC): Pass -lstdc++ for static
11080 libasan.
11081 * gcc.c: Do not pass LIBUBSAN_SPEC if ASan is enabled with UBSan.
11082
11083 2018-07-04 Eric Botcazou <ebotcazou@adacore.com>
11084
11085 PR middle-end/86380
11086 * expmed.c (choose_multiplier): Fix incorrect comparison with mask.
11087
11088 2018-07-04 Aldy Hernandez <aldyh@redhat.com>
11089
11090 * tree-vrp.c (extract_range_from_binary_expr_1): Initialize
11091 neg_*_op* variables.
11092
11093 2018-07-04 Martin Liska <mliska@suse.cz>
11094
11095 * tree-switch-conversion.c: Define
11096 max_ratio_for_speed and max_ratio_for_size constants.
11097
11098 2018-07-04 Denys Vlasenko <dvlasenk@redhat.com>
11099 Martin Liska <mliska@suse.cz>
11100
11101 PR middle-end/66240
11102 PR target/45996
11103 PR c/84100
11104 * common.opt: Rename align options with 'str_' prefix.
11105 * common/config/i386/i386-common.c (set_malign_value): New
11106 function.
11107 (ix86_handle_option): Use it to set -falign-* options/
11108 * config/aarch64/aarch64-protos.h (struct tune_params): Change
11109 type from int to string.
11110 * config/aarch64/aarch64.c: Update default values from int
11111 to string.
11112 * config/alpha/alpha.c (alpha_override_options_after_change):
11113 Likewise.
11114 * config/arm/arm.c (arm_override_options_after_change_1): Likewise.
11115 * config/i386/dragonfly.h (ASM_OUTPUT_MAX_SKIP_ALIGN): Print
11116 max skip conditionally.
11117 * config/i386/freebsd.h (SUBALIGN_LOG): New.
11118 (ASM_OUTPUT_MAX_SKIP_ALIGN): Print
11119 max skip conditionally.
11120 * config/i386/gas.h (ASM_OUTPUT_MAX_SKIP_ALIGN): Print
11121 max skip conditionally.
11122 * config/i386/gnu-user.h (SUBALIGN_LOG): New.
11123 (ASM_OUTPUT_MAX_SKIP_ALIGN): Print
11124 max skip conditionally.
11125 * config/i386/i386.c (struct ptt): Change type from int to
11126 string.
11127 (ix86_default_align): Set default values.
11128 * config/i386/i386.h (ASM_OUTPUT_MAX_SKIP_PAD): Print
11129 max skip conditionally.
11130 * config/i386/iamcu.h (SUBALIGN_LOG): New.
11131 (ASM_OUTPUT_MAX_SKIP_ALIGN):
11132 * config/i386/lynx.h (ASM_OUTPUT_MAX_SKIP_ALIGN):
11133 * config/i386/netbsd-elf.h (ASM_OUTPUT_MAX_SKIP_ALIGN): Print
11134 max skip conditionally.
11135 * config/i386/openbsdelf.h (SUBALIGN_LOG): New.
11136 (ASM_OUTPUT_MAX_SKIP_ALIGN) Print max skip conditionally.:
11137 * config/i386/x86-64.h (SUBALIGN_LOG): New.
11138 (ASM_OUTPUT_MAX_SKIP_ALIGN): Print
11139 max skip conditionally.
11140 (ASM_OUTPUT_MAX_SKIP_PAD): Likewise.
11141 * config/ia64/ia64.c (ia64_option_override): Set default values
11142 for alignment options.
11143 * config/m68k/m68k.c: Handle new str_align_* options.
11144 * config/mips/mips.c (mips_set_compression_mode): Change
11145 type of constants.
11146 (mips_option_override): Set default values for options.
11147 * config/powerpcspe/powerpcspe.c (rs6000_option_override_internal):
11148 Likewise.
11149 * config/rs6000/rs6000.c (rs6000_option_override_internal):
11150 Likewise.
11151 * config/rx/rx.c (rx_option_override): Likewise.
11152 * config/rx/rx.h (JUMP_ALIGN): Use align_jumps_log.
11153 (LABEL_ALIGN): Use align_labels_log.
11154 (LOOP_ALIGN): Use align_loops_align.
11155 * config/s390/s390.c (s390_asm_output_function_label): Use new
11156 macros.
11157 * config/sh/sh.c (sh_override_options_after_change):
11158 Change type of constants.
11159 * config/spu/spu.c (spu_sched_init): Likewise.
11160 * config/sparc/sparc.c (sparc_option_override): Set default
11161 values for options.
11162 * config/visium/visium.c (visium_option_override): Likewise.
11163 * config/visium/visium.h (ASM_OUTPUT_MAX_SKIP_ALIGN): Do not
11164 emit p2align format with last argument if it's not needed.
11165 * doc/invoke.texi: Document extended format of -falign-*.
11166 * final.c: Use align_labels alignment.
11167 * flags.h (struct target_flag_state): Change type to use
11168 align_flags.
11169 (struct align_flags_tuple): New.
11170 (struct align_flags): Likewise.
11171 (align_loops_log): Redefine macro to use new types.
11172 (align_loops_max_skip): Redefine macro to use new types.
11173 (align_jumps_log): Redefine macro to use new types.
11174 (align_jumps_max_skip): Redefine macro to use new types.
11175 (align_labels_log): Redefine macro to use new types.
11176 (align_labels_max_skip): Redefine macro to use new types.
11177 (align_functions_log): Redefine macro to use new types.
11178 (align_loops): Redefine macro to use new types.
11179 (align_jumps): Redefine macro to use new types.
11180 (align_labels): Redefine macro to use new types.
11181 (align_functions): Redefine macro to use new types.
11182 (align_functions_max_skip): Redefine macro to use new types.
11183 (align_loops_value): New macro.
11184 (align_jumps_value): New macro.
11185 (align_labels_value): New macro.
11186 (align_functions_value): New macro.
11187 * function.c (invoke_set_current_function_hook): Propagate
11188 alignment values from flags to global variables default in
11189 topleev.h.
11190 * ipa-icf.c (sem_function::equals_wpa): Use
11191 cl_optimization_option_eq instead of memcmp.
11192 * lto-streamer.h (cl_optimization_stream_out): Support streaming
11193 of string types.
11194 (cl_optimization_stream_in): Likewise.
11195 * optc-save-gen.awk: Support strings in cl_optimization.
11196 * opth-gen.awk: Likewise.
11197 * opts.c (finish_options): Remove error checking of invalid
11198 value ranges.
11199 (MAX_CODE_ALIGN): Remove.
11200 (MAX_CODE_ALIGN_VALUE): Likewise.
11201 (parse_and_check_align_values): New function.
11202 (check_alignment_argument): Likewise.
11203 (common_handle_option): Use check_alignment_argument.
11204 * opts.h (parse_and_check_align_values): Declare.
11205 * toplev.c (init_alignments): Remove.
11206 (read_log_maxskip): New.
11207 (parse_N_M): Likewise.
11208 (parse_alignment_opts): Likewise.
11209 (backend_init_target): Remove usage of init_alignments.
11210 * toplev.h (parse_alignment_opts): Declare.
11211 * tree-streamer-in.c (streamer_read_tree_bitfields): Add new
11212 argument.
11213 * tree-streamer-out.c (streamer_write_tree_bitfields): Likewise.
11214 * tree.c (cl_option_hasher::equal): New.
11215 * varasm.c: Use new global macros.
11216
11217 2018-07-04 Denys Vlasenko <dvlasenk@redhat.com>
11218
11219 * config/i386/dragonfly.h: (ASM_OUTPUT_MAX_SKIP_ALIGN):
11220 Use a simpler align directive also if MAXSKIP = ALIGN-1.
11221 * config/i386/gas.h (ASM_OUTPUT_MAX_SKIP_ALIGN): Likewise.
11222 * config/i386/lynx.h (ASM_OUTPUT_MAX_SKIP_ALIGN): Likewise.
11223 * config/i386/netbsd-elf.h (ASM_OUTPUT_MAX_SKIP_ALIGN): Likewise.
11224 * config/i386/i386.h (ASM_OUTPUT_MAX_SKIP_PAD): Likewise.
11225 * config/i386/freebsd.h (ASM_OUTPUT_MAX_SKIP_ALIGN): Remove "If N
11226 is large, do at least 8 byte alignment" code. Add SUBALIGN_LOG
11227 define. Use a simpler align directive also if MAXSKIP = ALIGN-1.
11228 * config/i386/gnu-user.h (ASM_OUTPUT_MAX_SKIP_ALIGN): Likewise.
11229 * config/i386/iamcu.h (ASM_OUTPUT_MAX_SKIP_ALIGN): Likewise.
11230 * config/i386/openbsdelf.h (ASM_OUTPUT_MAX_SKIP_ALIGN): Likewise.
11231 * config/i386/x86-64.h (ASM_OUTPUT_MAX_SKIP_ALIGN): Likewise.
11232
11233 2018-07-04 Martin Liska <mliska@suse.cz>
11234 Jonathan Wakely <jwakely@redhat.com>
11235
11236 * coverage.c: Use correct type.
11237 * doc/invoke.texi: Language correction.
11238
11239 2018-07-03 H.J. Lu <hongjiu.lu@intel.com>
11240
11241 PR target/85620
11242 * config/i386/i386.c (rest_of_insert_endbranch): Also generate
11243 ENDBRANCH for non-tail call which may return via indirect branch.
11244 * doc/extend.texi: Document indirect_return attribute.
11245
11246 2018-07-03 Martin Sebor <msebor@redhat.com>
11247
11248 PR tree-optimization/86274
11249 * gimple-ssa-sprintf.c (fmtresult::type_max_digits): Verify
11250 precondition.
11251 (format_floating): Correct handling of infinities and NaNs.
11252
11253 2018-07-03 Martin Sebor <msebor@redhat.com>
11254
11255 * print-tree.c (print_real_cst): New function.
11256 (print_node_brief): Call it.
11257 (print_node): Ditto.
11258
11259 2018-07-03 Jeff Law <law@redhat.com>
11260
11261 * config/h8300/h8300.md (logical<mode>3_sn, logical<mode>3): Merge
11262 into a single pattern.
11263
11264 * config/h8300/h8300.md (ors code_iterator): New.
11265 (bsetqi_msx, bnotqi_msx patterns and splitters): Consolidate into
11266 a single pattern and single splitter.
11267 (bsethi_msx, bnothi_msx patterns): Consolidate into a single pattern.
11268 (iorqi3_1, xorqi3_1): Likewise.
11269 (iorqi3, xorqi3 expanders): Similarly.
11270
11271 * config/h8300/h8300.md (movmd_internal_normal): Consolidated with
11272 (movmd_internal) into a single pattern using the P mode iterator.
11273 (movmd splitters): Similarly.
11274 (stpcpy_internal_normal, stpcpy_internal): Similarly for thes patterns.
11275 (movsd splitters): Similarly.
11276
11277 * config/h8300/h8300.c (h8300_insn_length_from_table): Consolidate
11278 ADDB, ADDW and ADDL into a single ADD attribute which selects the
11279 right table based on the size of the operand.
11280 * config/h8300/h8300.md (length_table): Corresponding changes. All
11281 references to "addb", "addw" and "addl" changed to "add".
11282 (btst patterns): Merge two variants into a single pattern.
11283 (tstqi, tsthi): Likewise.
11284 (addhi3_incdec, addsi3_incdec): Likewise.
11285 (subhi3_h8300hs, subsi3_h8300hs): Likewise.
11286 (mulhi3, mulsi3): Likewise.
11287 (udivhi3, udivsi3): Likewise.
11288 (divhi3, divsi3): Likewise.
11289 (andorqi3, andorhi3, andorsi3): Likewise.
11290
11291 2018-07-03 Uros Bizjak <ubizjak@gmail.com>
11292
11293 PR target/85694
11294 * config/i386/sse.md (uavg<mode>3_ceil): New expander.
11295 (<sse2_avx2>_uavg<mode>3<mask_name>): Simplify expander.
11296
11297 2018-07-03 Richard Sandiford <richard.sandiford@arm.com>
11298
11299 PR tree-optimization/85694
11300 * config/aarch64/iterators.md (HADD, RHADD): New int iterators.
11301 (u): Handle UNSPEC_SHADD, UNSPEC_UHADD, UNSPEC_SRHADD and
11302 UNSPEC_URHADD.
11303 * config/aarch64/aarch64-simd.md (<u>avg<mode>3_floor)
11304 (<u>avg<mode>3_ceil): New patterns.
11305
11306 2018-07-03 David Malcolm <dmalcolm@redhat.com>
11307
11308 * gcc.dg/vect/slp-perm-1.c: Remove "note: " prefix from
11309 scan-tree-dump directive.
11310 * gcc.dg/vect/slp-perm-2.c: Likewise.
11311 * gcc.dg/vect/slp-perm-3.c: Likewise.
11312 * gcc.dg/vect/slp-perm-5.c: Likewise.
11313 * gcc.dg/vect/slp-perm-6.c: Likewise.
11314 * gcc.dg/vect/slp-perm-7.c: Likewise.
11315 * gcc.dg/vect/slp-perm-8.c: Likewise.
11316
11317 2018-07-03 Marek Polacek <polacek@redhat.com>
11318
11319 PR middle-end/86202
11320 * gimple-fold.c (size_must_be_zero_p): Check the type of the size.
11321
11322 2018-07-03 Richard Biener <rguenther@suse.de>
11323
11324 PR ipa/86389
11325 * tree-ssa-structalias.c (find_func_clobbers): Properly
11326 handle indirect calls.
11327
11328 2018-07-03 Jeff Law <law@redhat.com>
11329
11330 * config/h8300/h8300.md (HSI, QHSI, QHSIF): New mode iterators.
11331 (shifts): New code iterator.
11332 (movqi, movhi, movsi, movsf expanders): Consolidate into a single
11333 expander. Fix HImode handling on H8/SX.
11334 (addqi3, addhi3, addsi3 expanders): Consolidate into a single expander.
11335 (subqi3, subhi3, subsi3 expanders): Likewise.
11336 (andqi3, andhi3, andsi3 expanders): Likewise.
11337 (iorqi3, iorhi3, iorsi3 expanders): Likewise.
11338 (xorqi3, xorhi3, xorsi3 expanders): Likewise.
11339 (negqi2, neghi2, negsi2, negsf2 expanders): Likewise.
11340 (one_cmplqi2, one_cmplhi2, one_cmplsi2): Likewise.
11341 (zero_extendqihi2, zero_extendqisi2): Likewise.
11342 (extendqihi2, extendqisi2): Likewise.
11343 (rotlqi3, rotlhi3, rotlsi3): Likewise.
11344 (neghi2_h8300, negsi2_h8300): Likewise for these patterns.
11345 (rotlqi3_1, rotlhi3_1): Likewise.
11346 (logicalhi3_sn, logicalsi3_sn): Likewise.
11347 (logicalhi3, logicalsi3): Likewise.
11348
11349 2018-07-03 Richard Sandiford <richard.sandiford@arm.com>
11350
11351 * tree-vect-patterns.c (vect_recog_rotate_pattern)
11352 (vect_recog_vector_vector_shift_pattern, vect_recog_divmod_pattern)
11353 (vect_recog_mixed_size_cond_pattern, adjust_bool_pattern_cast)
11354 (adjust_bool_pattern, vect_recog_bool_pattern): Pass the vector
11355 type to append_pattern_def_seq instead of creating a stmt_vec_info
11356 directly.
11357 (build_mask_conversion): Likewise. Remove vinfo argument.
11358 (vect_add_conversion_to_patterm): Likewise, renaming to...
11359 (vect_add_conversion_to_pattern): ...this.
11360 (vect_recog_mask_conversion_pattern): Update call to
11361 build_mask_conversion. Pass the vector type to
11362 append_pattern_def_seq here too.
11363 (vect_recog_gather_scatter_pattern): Update call to
11364 vect_add_conversion_to_pattern.
11365
11366 2018-07-03 Richard Sandiford <richard.sandiford@arm.com>
11367
11368 * tree-vect-patterns.c (new_pattern_def_seq): Delete.
11369 (vect_recog_dot_prod_pattern, vect_recog_sad_pattern)
11370 (vect_recog_widen_op_pattern, vect_recog_over_widening_pattern)
11371 (vect_recog_rotate_pattern, vect_synth_mult_by_constant): Don't set
11372 STMT_VINFO_PATTERN_DEF_SEQ to null here.
11373 (vect_recog_pow_pattern, vect_recog_vector_vector_shift_pattern)
11374 (vect_recog_mixed_size_cond_pattern, vect_recog_bool_pattern): Use
11375 append_pattern_def_seq instead of new_pattern_def_seq.
11376 (vect_recog_divmod_pattern): Do both of the above.
11377 (vect_pattern_recog_1): Assert that STMT_VINO_PATTERN_DEF_SEQ
11378 is null.
11379
11380 2018-07-03 Richard Sandiford <richard.sandiford@arm.com>
11381
11382 * tree-vect-patterns.c (vect_recog_dot_prod_pattern):
11383 (vect_recog_sad_pattern, vect_recog_widen_op_pattern)
11384 (vect_recog_widen_mult_pattern, vect_recog_pow_pattern):
11385 (vect_recog_widen_sum_pattern, vect_recog_over_widening_pattern)
11386 (vect_recog_average_pattern, vect_recog_cast_forwprop_pattern)
11387 (vect_recog_widen_shift_pattern, vect_recog_rotate_pattern)
11388 (vect_recog_vector_vector_shift_pattern, vect_synth_mult_by_constant)
11389 (vect_recog_mult_pattern, vect_recog_divmod_pattern)
11390 (vect_recog_mixed_size_cond_pattern, vect_recog_bool_pattern)
11391 (vect_recog_mask_conversion_pattern): Replace vec<gimple *>
11392 parameter with a single stmt_vec_info.
11393 (vect_recog_func_ptr): Likewise.
11394 (vect_recog_gather_scatter_pattern): Likewise, folding in...
11395 (vect_try_gather_scatter_pattern): ...this.
11396 (vect_pattern_recog_1): Remove stmts_to_replace and just pass
11397 the stmt_vec_info of the statement to be matched. Don't clear
11398 STMT_VINFO_RELATED_STMT.
11399 (vect_pattern_recog): Update call accordingly.
11400
11401 2018-07-03 Richard Sandiford <richard.sandiford@arm.com>
11402
11403 PR tree-optimization/85694
11404 * doc/md.texi (avgM3_floor, uavgM3_floor, avgM3_ceil)
11405 (uavgM3_ceil): Document new optabs.
11406 * doc/sourcebuild.texi (vect_avg_qi): Document new target selector.
11407 * internal-fn.def (IFN_AVG_FLOOR, IFN_AVG_CEIL): New internal
11408 functions.
11409 * optabs.def (savg_floor_optab, uavg_floor_optab, savg_ceil_optab)
11410 (savg_ceil_optab): New optabs.
11411 * tree-vect-patterns.c (vect_recog_average_pattern): New function.
11412 (vect_vect_recog_func_ptrs): Add it.
11413 * tree-vect-stmts.c (vectorizable_call): Get the type of the zero
11414 constant directly from the associated lhs.
11415
11416 2018-07-03 Richard Sandiford <richard.sandiford@arm.com>
11417
11418 * tree-vect-patterns.c (vect_split_statement): New function.
11419 (vect_convert_input): Use it to try to split an existing cast.
11420
11421 2018-07-03 Richard Sandiford <richard.sandiford@arm.com>
11422
11423 * poly-int.h (print_hex): New function.
11424 * dumpfile.h (dump_dec, dump_hex): Declare.
11425 * dumpfile.c (dump_dec, dump_hex): New poly_wide_int functions.
11426 * tree-vectorizer.h (_stmt_vec_info): Add min_output_precision,
11427 min_input_precision, operation_precision and operation_sign.
11428 * tree-vect-patterns.c (vect_get_range_info): New function.
11429 (vect_same_loop_or_bb_p, vect_single_imm_use)
11430 (vect_operation_fits_smaller_type): Delete.
11431 (vect_look_through_possible_promotion): Add an optional
11432 single_use_p parameter.
11433 (vect_recog_over_widening_pattern): Rewrite to use new
11434 stmt_vec_info infomration. Handle one operation at a time.
11435 (vect_recog_cast_forwprop_pattern, vect_narrowable_type_p)
11436 (vect_truncatable_operation_p, vect_set_operation_type)
11437 (vect_set_min_input_precision): New functions.
11438 (vect_determine_min_output_precision_1): Likewise.
11439 (vect_determine_min_output_precision): Likewise.
11440 (vect_determine_precisions_from_range): Likewise.
11441 (vect_determine_precisions_from_users): Likewise.
11442 (vect_determine_stmt_precisions, vect_determine_precisions): Likewise.
11443 (vect_vect_recog_func_ptrs): Put over_widening first.
11444 Add cast_forwprop.
11445 (vect_pattern_recog): Call vect_determine_precisions.
11446
11447 2018-07-03 Richard Sandiford <richard.sandiford@arm.com>
11448
11449 * tree-vect-patterns.c (vect_mark_pattern_stmts): Remove pattern
11450 statements that have been replaced by further pattern statements.
11451 (vect_pattern_recog_1): Clear STMT_VINFO_PATTERN_DEF_SEQ on failure.
11452
11453 2018-07-03 Richard Biener <rguenther@suse.de>
11454
11455 * tree-vect-stmts.c (vect_is_simple_use): Consolidate dumping,
11456 always set *dt. Dump vectype in vectype overload.
11457 * dumpfile.h (dump_gimple_expr): New function.
11458 (dump_gimple_expr_loc): Likewise.
11459 * dumpfile.c (dump_gimple_expr): New function.
11460 (dump_gimple_expr_loc): Likewise.
11461
11462 2018-07-02 Jeff Law <law@redhat.com>
11463
11464 * config/h8300/h8300.md (movqi_h8300, movqi_h8300hs): Consolidate
11465 the H8/300, H8/300H and H8/S variants into a single pattern.
11466 (movhi_h8300, movqi_h8300hs): Similarly.
11467 (pushqi_h8300hs, pushhi_h8300hs): Consolidate into a single pattern.
11468 (QHI mode iterator): New.
11469
11470 * config/h8300/h8300.md: Remove trailing whitespace.
11471
11472 2018-07-02 Jim Wilson <jimw@sifive.com>
11473
11474 * config/riscv/riscv.c (riscv_expand_epilogue): Use emit_jump_insn
11475 instead of emit_insn for interrupt returns.
11476 * config/riscv/riscv.md (riscv_met): Add (return) to rtl.
11477 (riscv_sret, riscv_uret): Likewise.
11478
11479 2018-07-02 David Malcolm <dmalcolm@redhat.com>
11480
11481 * pretty-print.c (selftest::test_pp_format): Move save and restore
11482 of quotes to class auto_fix_quotes, and add an instance.
11483 * selftest.c: Include "intl.h".
11484 (selftest::auto_fix_quotes::auto_fix_quotes): New ctor.
11485 (selftest::auto_fix_quotes::~auto_fix_quotes): New dtor.
11486 * selftest.h (selftest::auto_fix_quotes): New class.
11487
11488 2018-07-02 Richard Henderson <richard.henderson@linaro.org>
11489
11490 * config/aarch64/aarch64-protos.h, config/aarch64/aarch64.c
11491 (aarch64_sve_prepare_conditional_op): Remove.
11492 * config/aarch64/aarch64-sve.md (cond_<SVE_INT_BINARY><SVE_I>):
11493 Allow aarch64_simd_reg_or_zero as select operand; remove
11494 the aarch64_sve_prepare_conditional_op call.
11495 (cond_<SVE_INT_BINARY_SD><SVE_SDI>): Likewise.
11496 (cond_<SVE_COND_FP_BINARY><SVE_F>): Likewise.
11497 (*cond_<SVE_INT_BINARY><SVE_I>_z): New pattern.
11498 (*cond_<SVE_INT_BINARY_SD><SVE_SDI>_z): New pattern.
11499 (*cond_<SVE_COND_FP_BINARY><SVE_F>_z): New pattern.
11500 (*cond_<SVE_INT_BINARY><SVE_I>_any): New pattern.
11501 (*cond_<SVE_INT_BINARY_SD><SVE_SDI>_any): New pattern.
11502 (*cond_<SVE_COND_FP_BINARY><SVE_F>_any): New pattern
11503 and a splitters to match all of the *_any patterns.
11504 * config/aarch64/predicates.md (aarch64_sve_any_binary_operator): New.
11505
11506 * config/aarch64/iterators.md (SVE_INT_BINARY_REV): Remove.
11507 (SVE_COND_FP_BINARY_REV): Remove.
11508 (sve_int_op_rev, sve_fp_op_rev): New.
11509 * config/aarch64/aarch64-sve.md (*cond_<SVE_INT_BINARY><SVE_I>_0): New.
11510 (*cond_<SVE_INT_BINARY_SD><SVE_SDI>_0): New.
11511 (*cond_<SVE_COND_FP_BINARY><SVE_F>_0): New.
11512 (*cond_<SVE_INT_BINARY><SVE_I>_2): Rename, add movprfx alternative.
11513 (*cond_<SVE_INT_BINARY_SD><SVE_SDI>_2): Similarly.
11514 (*cond_<SVE_COND_FP_BINARY><SVE_F>_2): Similarly.
11515 (*cond_<SVE_INT_BINARY><SVE_I>_3): Similarly; use sve_int_op_rev.
11516 (*cond_<SVE_INT_BINARY_SD><SVE_SDI>_3): Similarly.
11517 (*cond_<SVE_COND_FP_BINARY><SVE_F>_3): Similarly; use sve_fp_op_rev.
11518
11519 * config/aarch64/aarch64-sve.md (cond_<SVE_COND_FP_BINARY><SVE_F>):
11520 Remove match_dup 1 from the inner unspec.
11521 (*cond_<SVE_COND_FP_BINARY><SVE_F>): Likewise.
11522
11523 * config/aarch64/aarch64.md (movprfx): New attr.
11524 (length): Default movprfx to 8.
11525 * config/aarch64/aarch64-sve.md (*mul<SVE_I>3): Add movprfx alt.
11526 (*madd<SVE_I>, *msub<SVE_I): Likewise.
11527 (*<su>mul<SVE_I>3_highpart): Likewise.
11528 (*<SVE_INT_BINARY_SD><SVE_SDI>3): Likewise.
11529 (*v<ASHIFT><SVE_I>3): Likewise.
11530 (*<su><MAXMIN><SVE_I>3): Likewise.
11531 (*<su><MAXMIN><SVE_F>3): Likewise.
11532 (*fma<SVE_F>4, *fnma<SVE_F>4): Likewise.
11533 (*fms<SVE_F>4, *fnms<SVE_F>4): Likewise.
11534 (*div<SVE_F>4): Likewise.
11535
11536 2018-07-02 Richard Sandiford <richard.sandiford@arm.com>
11537
11538 * tree-vect-patterns.c (vect_recog_widen_shift_pattern): Fix typo
11539 in dump string.
11540
11541 2018-07-02 Richard Biener <rguenther@suse.de>
11542
11543 PR tree-optimization/86363
11544 * tree-ssa-sccvn.c (vn_reference_lookup_3): Check the
11545 memset argument refers to a non-variable address.
11546
11547 2018-07-02 Aldy Hernandez <aldyh@redhat.com>
11548
11549 * tree-vrp.c (extract_range_from_binary_expr_1): Abstract a lot of the
11550 {PLUS,MINUS}_EXPR code to...
11551 (adjust_symbolic_bound): ...here,
11552 (combine_bound): ...here,
11553 (set_value_range_with_overflow): ...and here.
11554
11555 2018-07-02 Aldy Hernandez <aldyh@redhat.com>
11556
11557 * tree-vrp.c (extract_range_from_unary_expr): Abstract ABS_EXPR
11558 code...
11559 (extract_range_from_abs_expr): ...here.
11560
11561 2018-07-02 Eric Botcazou <ebotcazou@adacore.com>
11562
11563 * config/i386/i386.c (ix86_finalize_stack_frame_flags): Do not overrule
11564 -fno-omit-frame-pointer when not optimizing.
11565
11566 2018-07-02 Martin Liska <mliska@suse.cz>
11567
11568 PR ipa/86279
11569 * ipa-pure-const.c (malloc_candidate_p): Revert usage of ::get.
11570 (propagate_nothrow): Likewise.
11571
11572 2018-07-02 Martin Liska <mliska@suse.cz>
11573
11574 PR ipa/86323
11575 * ipa-inline.c (early_inliner): Revert wrongly added ::get call.
11576
11577 2018-07-02 David Malcolm <dmalcolm@redhat.com>
11578
11579 * dumpfile.c (dump_generic_expr_loc): Undo removal of this
11580 function in r262149, changing "loc" param from source_location to
11581 const dump_location_t &.
11582 * dumpfile.h (dump_generic_expr_loc): Undo removal of this
11583 declaration, as above.
11584
11585 2018-07-01 Paul Koning <ni1d@arrl.net>
11586
11587 * common/config/pdp11/pdp11-common.c (pdp11_handle_option): Handle
11588 -munit-asm, -mgnu-asm, -mdec-asm.
11589 * config/pdp11/pdp11-protos.h (pdp11_gen_int_label): New.
11590 (pdp11_output_labelref): New.
11591 (pdp11_output_def): New.
11592 (pdp11_output_addr_vec_elt): New.
11593 * config/pdp11/pdp11.c: Use tab between opcode and operands. Use
11594 %# and %@ format codes.
11595 (pdp11_option_override): New.
11596 (TARGET_ASM_FILE_START_FILE_DIRECTIVE): Define.
11597 (pdp11_output_ident): New.
11598 (pdp11_asm_named_section): New.
11599 (pdp11_asm_init_sections): New.
11600 (pdp11_file_start): New.
11601 (pdp11_file_end): New.
11602 (output_ascii): Use .ascii/.asciz for -mdec-asm.
11603 (pdp11_asm_print_operand): Update %# and %$ for -mdec-asm. Add
11604 %o, like %c but octal.
11605 (pdp11_option_override): New.
11606 * config/pdp11/pdp11.h (TEXT_SECTION_ASM_OP): Update for
11607 -mdec-asm.
11608 (DATA_SECTION_ASM_OP): Ditto.
11609 (READONLY_DATA_SECTION_ASM_OP): New.
11610 (IS_ASM_LOGICAL_LINE_SEPARATOR): New.
11611 (ASM_GENERATE_INTERNAL_LABEL): Use new function.
11612 (ASM_OUTPUT_LABELREF): Ditto.
11613 (ASM_OUTPUT_DEF): Ditto.
11614 (ASM_OUTPUT_EXTERNAL): New.
11615 (ASM_OUTPUT_SOURCE_FILENAME): New.
11616 (ASM_OUTPUT_ADDR_VEC_ELT): Use new function.
11617 (ASM_OUTPUT_SKIP): Update for -mdec-asm.
11618 * config/pdp11/pdp11.md: Use tab between opcode and operands. Use
11619 %# and %@ format codes.
11620 * config/pdp11/pdp11.opt (mgnu-asm): New.
11621 (mdec-asm): Conflicts with -mgnu-asm and -munix-asm.
11622 (munix-asm): Conflicts with -mdec-asm and -mgnu-asm.
11623 * doc/invoke.txt (PDP-11 Options): Add -mgnu-asm.
11624
11625 2018-07-01 Aldy Hernandez <aldyh@redhat.com>
11626
11627 * tree-ssa-threadupdate.c (mark_threaded_blocks): Avoid
11628 dereferencing path[] beyond its length.
11629 (debug_path): New.
11630 (debug_all_paths): New.
11631 (rewire_first_differing_edge): New.
11632 (adjust_paths_after_duplication): New.
11633 (duplicate_thread_path): Call adjust_paths_after_duplication.
11634 Add new argument.
11635 (thread_through_all_blocks): Add new argument to
11636 duplicate_thread_path.
11637
11638 2018-06-30 Jim Wilson <jimw@sifive.com>
11639
11640 * config/riscv/predicates.md (p2m1_shift_operand): New.
11641 (high_mask_shift_operand): New.
11642 * config/riscv/riscv.md (lshrsi3_zero_extend_3+1): New combiner
11643 pattern using p2m1_shift_operand.
11644 (lshsi3_zero_extend_3+2): New combiner pattern using
11645 high_mask_shift_operand.
11646
11647 2018-06-30 Richard Sandiford <richard.sandiford@arm.com>
11648
11649 * tree-vect-patterns.c (vect_get_external_def_edge): New function,
11650 split out from...
11651 (vect_recog_rotate_pattern): ...here.
11652 (vect_convert_input): Try to insert casts of invariants in the
11653 preheader.
11654 * tree-vect-loop-manip.c (vect_loop_versioning): Don't require the
11655 preheader to be empty.
11656
11657 2018-06-30 Richard Sandiford <richard.sandiford@arm.com>
11658
11659 * tree-vect-patterns.c (append_pattern_def_seq): Take an optional
11660 vector type. If given, install it in the new statement's
11661 STMT_VINFO_VECTYPE.
11662 (vect_element_precision): New function.
11663 (vect_unpromoted_value): New struct.
11664 (vect_unpromoted_value::vect_unpromoted_value): New function.
11665 (vect_unpromoted_value::set_op): Likewise.
11666 (vect_look_through_possible_promotion): Likewise.
11667 (vect_joust_widened_integer, vect_joust_widened_type): Likewise.
11668 (vect_widened_op_tree, vect_convert_input): Likewise.
11669 (vect_convert_inputs, vect_convert_output): Likewise.
11670 (vect_recog_dot_prod_pattern): Use vect_look_through_possible_promotion
11671 to handle the optional cast of the multiplication result and
11672 vect_widened_op_tree to detect the widened multiplication itself.
11673 Do not require the input and output of promotion casts to have
11674 the same sign, but base the signedness of the operation on the
11675 input rather than the result. If the pattern includes two
11676 promotions, check that those promotions have the same sign.
11677 Do not restrict the MULT_EXPR handling to a double-width result;
11678 handle quadruple-width results and wider. Use vect_convert_inputs
11679 to convert the inputs to the common type.
11680 (vect_recog_sad_pattern): Use vect_look_through_possible_promotion
11681 to handle the optional cast of the ABS result. Also allow a sign
11682 change or a sign extension between the ABS and MINUS.
11683 Use vect_widened_op_tree to detect the widened subtraction and use
11684 vect_convert_inputs to convert the inputs to the common type.
11685 (vect_handle_widen_op_by_const): Delete.
11686 (vect_recog_widen_op_pattern): New function.
11687 (vect_recog_widen_mult_pattern): Use it.
11688 (vect_recog_widen_shift_pattern): Likewise.
11689 (vect_recog_widen_sum_pattern): Use
11690 vect_look_through_possible_promotion to handle the promoted
11691 PLUS_EXPR operand.
11692
11693 2018-06-30 Richard Sandiford <richard.sandiford@arm.com>
11694
11695 * gimple-iterator.c (gsi_for_stmt): Add a new overload that takes
11696 the containing gimple_seq *.
11697 * gimple-iterator.h (gsi_for_stmt): Declare it.
11698 * tree-vect-patterns.c (vect_recog_dot_prod_pattern)
11699 (vect_recog_sad_pattern, vect_recog_widen_sum_pattern)
11700 (vect_recog_widen_shift_pattern, vect_recog_rotate_pattern)
11701 (vect_recog_vector_vector_shift_pattern, vect_recog_divmod_pattern)
11702 (vect_recog_mask_conversion_pattern): Remove STMT_VINFO_IN_PATTERN_P
11703 checks.
11704 (vect_init_pattern_stmt, vect_set_pattern_stmt): New functions,
11705 split out from...
11706 (vect_mark_pattern_stmts): ...here. Handle cases in which the
11707 statement being replaced is part of an existing pattern
11708 definition sequence, inserting the new pattern statements before
11709 the original one.
11710 (vect_pattern_recog_1): Don't return a bool. If the statement
11711 is already part of a pattern, instead apply pattern matching
11712 to the pattern definition statements. Don't clear the
11713 STMT_VINFO_RELATED_STMT if is_pattern_stmt_p.
11714 (vect_pattern_recog): Don't break after the first match;
11715 continue processing the pattern definition statements instead.
11716 Don't bail out for STMT_VINFO_IN_PATTERN_P here.
11717
11718 2018-06-30 Richard Sandiford <richard.sandiford@arm.com>
11719
11720 * tree-vect-patterns.c (vect_reassociating_reduction_p): New function.
11721 (vect_recog_dot_prod_pattern, vect_recog_sad_pattern)
11722 (vect_recog_widen_sum_pattern): Use it.
11723
11724 2018-06-30 Richard Sandiford <richard.sandiford@arm.com>
11725
11726 * tree-vect-loop.c (vectorizable_reduction): Assert that the
11727 phi is not a pattern statement and has not been replaced by
11728 a pattern statement.
11729 * tree-vect-patterns.c (type_conversion_p): Don't check
11730 STMT_VINFO_IN_PATTERN_P.
11731 (vect_recog_vector_vector_shift_pattern): Likewise.
11732 (vect_recog_dot_prod_pattern): Expect vect_is_simple_use to return
11733 the pattern statement rather than the original statement; check
11734 directly for a WIDEN_MULT_EXPR here.
11735 * tree-vect-slp.c (vect_get_and_check_slp_defs): Expect
11736 vect_is_simple_use to return the pattern statement rather
11737 than the original statement; use is_pattern_stmt_p to check
11738 for such a pattern statement.
11739 * tree-vect-stmts.c (process_use): Expect vect_is_simple_use
11740 to return the pattern statement rather than the original statement;
11741 don't do the same transformation here.
11742 (vect_is_simple_use): If the defining statement has been replaced
11743 by a pattern statement, return the pattern statement instead.
11744 Remove the corresponding (local) transformation from the vectype
11745 overload.
11746
11747 2018-06-30 Richard Sandiford <richard.sandiford@arm.com>
11748
11749 * tree-vectorizer.h (vect_is_simple_use): Move the gimple ** to the
11750 end and default to null.
11751 * tree-vect-loop.c (vect_create_epilog_for_reduction)
11752 (vectorizable_reduction): Update calls accordingly, dropping the
11753 gimple ** argument if the passed-back statement isn't needed.
11754 * tree-vect-patterns.c (vect_get_internal_def, type_conversion_p)
11755 (vect_recog_rotate_pattern): Likewise.
11756 (vect_recog_mask_conversion_pattern): Likewise.
11757 * tree-vect-slp.c (vect_get_and_check_slp_defs): Likewise.
11758 (vect_mask_constant_operand_p): Likewise.
11759 * tree-vect-stmts.c (is_simple_and_all_uses_invariant, process_use):
11760 (vect_model_simple_cost, vect_get_vec_def_for_operand): Likewise.
11761 (get_group_load_store_type, get_load_store_type): Likewise.
11762 (vect_check_load_store_mask, vect_check_store_rhs): Likewise.
11763 (vectorizable_call, vectorizable_simd_clone_call): Likewise.
11764 (vectorizable_conversion, vectorizable_assignment): Likewise.
11765 (vectorizable_shift, vectorizable_operation): Likewise.
11766 (vectorizable_store, vect_is_simple_cond): Likewise.
11767 (vectorizable_condition, vectorizable_comparison): Likewise.
11768 (get_same_sized_vectype, vect_get_mask_type_for_stmt): Likewise.
11769 (vect_is_simple_use): Rename the def_stmt argument to def_stmt_out
11770 and move it to the end. Cope with null def_stmt_outs.
11771
11772 2018-06-30 Bernd Edlinger <bernd.edlinger@hotmail.de>
11773
11774 * Makefile.in (FLAGS_TO_PASS): Add RANLIB_FOR_TARGET.
11775
11776 2018-06-29 Jeff Law <law@redhat.com>
11777
11778 * config/v850/v850.c (v850_legitimate_address_p): Handle large
11779 displacements for TARGET_V850E2V3 and newer.
11780 (TARGET_LRA_P): Remove. Defaults to LRA now.
11781 * config/v850/v850.md (sign23byte_load): Remove.
11782 (unsign23byte_load, sign23hword_load, unsign23hword_load): Likewise.
11783 (23word_load, 23byte_store, 23hword_store, 23word_store): Likewise.
11784
11785 2018-06-29 Martin Liska <mliska@suse.cz>
11786
11787 PR lto/85759
11788 * coverage.c (coverage_init): Mangle full path name.
11789 * doc/invoke.texi: Document the change.
11790 * gcov-io.c (mangle_path): New.
11791 * gcov-io.h (mangle_path): Likewise.
11792 * gcov.c (mangle_name): Use mangle_path for path mangling.
11793
11794 2018-06-29 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
11795
11796 * config/arm/arm.c (output_move_double): Don't allow STRD instructions
11797 if starting source register is not even.
11798
11799 2018-06-29 Martin Liska <mliska@suse.cz>
11800
11801 PR tree-optimization/86263
11802 * tree-switch-conversion.c (switch_decision_tree::try_switch_expansion):
11803 Make edge redirection.
11804
11805 2018-06-29 David Malcolm <dmalcolm@redhat.com>
11806
11807 * dumpfile.c (dump_loc): Add indentation based on scope depth.
11808 (dump_scope_depth): New variable.
11809 (get_dump_scope_depth): New function.
11810 (dump_begin_scope): New function.
11811 (dump_end_scope): New function.
11812 * dumpfile.h (get_dump_scope_depth): New declaration.
11813 (dump_begin_scope): New declaration.
11814 (dump_end_scope): New declaration.
11815 (class auto_dump_scope): New class.
11816 (AUTO_DUMP_SCOPE): New macro.
11817 * tree-vectorizer.h (DUMP_VECT_SCOPE): Reimplement in terms of
11818 AUTO_DUMP_SCOPE.
11819
11820 2018-06-29 Richard Biener <rguenther@suse.de>
11821
11822 * tree-vect-data-refs.c (vect_analyze_data_ref_dependences): Assert
11823 compute_all_dependences succeeds.
11824 * tree-vect-loop.c (vect_get_datarefs_in_loop): Fail early if we
11825 exceed --param loop-max-datarefs-for-datadeps.
11826
11827 2018-06-29 Jakub Jelinek <jakub@redhat.com>
11828
11829 * config/rs6000/t-rs6000: Append rs6000-modes.h to TM_H.
11830
11831 2018-06-28 Uros Bizjak <ubizjak@gmail.com>
11832
11833 PR target/86348
11834 * config/i386/sse.md (*vec_extractv4si_0_zext_sse4): Use
11835 alternative 0 in preferred_for_speed attribute.
11836
11837 2018-06-28 Paul Koning <ni1d@arrl.net>
11838
11839 * config/pdp11/pdp11-protos.h (pdp11_shift_length): New function.
11840 * config/pdp11/pdp11.c (pdp11_shift_length): New function.
11841 * config/pdp11/pdp11.h (ADJUST_INSN_LENGTH): Remove.
11842 * config/pdp11/pdp11.md: Correct "length" attribute calculation
11843 for shift insn patterns.
11844
11845 2018-06-28 David Malcolm <dmalcolm@redhat.com>
11846
11847 * cgraph.c (cgraph_node::get_body): Replace assignments to
11848 "dump_file" with calls to set_dump_file.
11849 * dumpfile.c (alt_dump_file): Make static, and group with...
11850 (alt_flags): ...this definition.
11851 (dumps_are_enabled): New variable.
11852 (refresh_dumps_are_enabled): New function.
11853 (set_dump_file): New function.
11854 (set_alt_dump_file): New function.
11855 (gcc::dump_manager::dump_start): Replace assignments to
11856 "dump_file" and "alt_dump_file" with calls to set_dump_file and
11857 set_alt_dump_file.
11858 (gcc::dump_manager::dump_finish): Likewise.
11859 * dumpfile.h (alt_dump_file): Delete decl.
11860 (dumps_are_enabled): New variable decl.
11861 (set_dump_file): New function decl.
11862 (dump_enabled_p): Rewrite in terms of new "dumps_are_enabled"
11863 global.
11864 * tree-nested.c (lower_nested_functions): Replace assignments to
11865 "dump_file" with calls to set_dump_file.
11866
11867 2018-06-28 Eric Botcazou <ebotcazou@adacore.com>
11868
11869 * tree-cfg.c (verify_gimple_in_cfg): Call verify_location on the
11870 goto_locus of each outgoing edge of each basic block.
11871
11872 2018-06-28 Richard Biener <rguenther@suse.de>
11873
11874 * dwarf2out.c (decl_scope_table): Remove.
11875 (push_decl_scope): Likewise.
11876 (pop_decl_scope): Likewise.
11877 (gen_type_die_for_member): Do not call push/pop_decl_scope.
11878 (gen_struct_or_union_type_die): Likewise.
11879 (gen_tagged_type_die): Likewise.
11880 (dwarf2out_init): Do not initialize decl_scope_table.
11881 (dwarf2out_c_finalize): Do not free it.
11882
11883 2018-06-28 Richard Biener <rguenther@suse.de>
11884
11885 * dwarf2out.c (gen_subprogram_die): Use is_unit_die when
11886 deciding whether to not re-use a DIE.
11887
11888 2018-06-28 Richard Biener <rguenther@suse.de>
11889
11890 * dwarf2out.c (gen_subprogram_die): Always re-use DIEs with an
11891 DW_AT_abstract_origin attribute.
11892
11893 2018-06-28 Martin Liska <mliska@suse.cz>
11894
11895 * tree-switch-conversion.c (jump_table_cluster::can_be_handled):
11896 Use newly introduced constants.
11897 * tree-switch-conversion.h (struct jump_table_cluster):
11898 Define max_ratio_for_size and max_ratio_for_speed.
11899
11900 2018-06-28 Martin Liska <mliska@suse.cz>
11901
11902 * tree-switch-conversion.c (jump_table_cluster::find_jump_tables):
11903 Add new checking assert to catch invalid state.
11904 (jump_table_cluster::can_be_handled): Handle single case
11905 clusters.
11906 (jump_table_cluster::is_beneficial): Bail out for such case.
11907 (bit_test_cluster::find_bit_tests):
11908 Add new checking assert to catch invalid state.
11909 (bit_test_cluster::can_be_handled): Handle single case
11910 clusters.
11911 (bit_test_cluster::is_beneficial): Bail out for such case.
11912 (switch_decision_tree::analyze_switch_statement):
11913 Fix comment.
11914
11915 2018-06-28 Martin Liska <mliska@suse.cz>
11916
11917 * common.opt: Introduce -completion option.
11918 * gcc.c (driver_handle_option): Handle it.
11919 (driver::main): Print completions if completion
11920 is set.
11921 * opt-suggestions.c (option_proposer::get_completions):
11922 New function.
11923 (option_proposer::suggest_completion): Likewise.
11924 (option_proposer::find_param_completions): Likewise.
11925 (verify_autocompletions): Likewise.
11926 (test_completion_valid_options): Likewise.
11927 (test_completion_valid_params): Likewise.
11928 (in_completion_p): Likewise.
11929 (empty_completion_p): Likewise.
11930 (test_completion_partial_match): Likewise.
11931 (test_completion_garbage): Likewise.
11932 (opt_proposer_c_tests): Likewise.
11933 * opt-suggestions.h: Declare new functions.
11934 * opts.c (common_handle_option): Handle OPT__completion_.
11935 * selftest-run-tests.c (selftest::run_tests): Add
11936 opt_proposer_c_tests.
11937 * selftest.c (assert_str_startswith): New.
11938 * selftest.h (assert_str_startswith): Likewise.
11939 (opt_proposer_c_tests): New.
11940 (ASSERT_STR_STARTSWITH): Likewise.
11941
11942 2018-06-28 Martin Liska <mliska@suse.cz>
11943
11944 * Makefile.in: Add opt-suggestions.o.
11945 * gcc-main.c: Include opt-suggestions.h.
11946 * gcc.c (driver::driver): Likewise.
11947 (driver::~driver): Remove m_option_suggestions.
11948 (driver::build_option_suggestions): Moved to option_proposer.
11949 (driver::suggest_option): Likewise.
11950 (driver::handle_unrecognized_options): Use option_proposer.
11951 * gcc.h (class driver): Add new memver m_option_proposer.
11952 * opt-suggestions.c: New file.
11953 * opt-suggestions.h: New file.
11954
11955 2018-06-28 Martin Liska <mliska@suse.cz>
11956
11957 * vec.h (class auto_string_vec): New (moved from auto_argvec).
11958 (auto_string_vec::~auto_string_vec): Likewise.
11959
11960 2018-06-28 Eric Botcazou <ebotcazou@adacore.com>
11961
11962 * tree-inline.h (struct copy_body_data): Move remapping_type_depth and
11963 prevent_decl_creation_for_types fields up and add reset_location field.
11964 * tree-inline.c (remap_gimple_stmt): Force input_location on the new
11965 statement if id->reset_location is true.
11966 (copy_edges_for_bb): Do not set goto_locus on the new edges if
11967 id->reset_location is true.
11968 (copy_phis_for_bb): Force input_location on the arguments if
11969 id->reset_location is true.
11970 (expand_call_inline): Set id->reset_location if DECL_IGNORED_P
11971 is set on the function to be inlined.
11972
11973 2018-06-27 Stephan Bergmann <sbergman@redhat.com>
11974
11975 * doc/invoke.texi (Debugging Options): Add -gsplit-dwarf.
11976
11977 2018-06-27 Dimitar Dimitrov <dimitar@dinux.eu>
11978
11979 * lra-eliminations.c (update_reg_eliminate): Mark all spanning hard
11980 registers for Pmode.
11981 * lra-lives.c (check_pseudos_live_through_calls): Mark all spanning
11982 hard registers for the clobbered pseudo.
11983
11984 2018-06-27 Paul Koning <ni1d@arrl.net>
11985
11986 * common/config/pdp11/pdp11-common.c (pdp11_handle_option): Handle
11987 mutually exclusive options.
11988 * config/pdp11/constraints.md (h): New constraint.
11989 (O): Update definition to match shift code generation.
11990 (D): New constraint.
11991 * config/pdp11/pdp11-modes.def (CCNZ): Define mode.
11992 (CCFP): Remove.
11993 * config/pdp11/pdp11-protos.h (int_no_side_effect_operand): New
11994 function.
11995 (output_jump): Change arguments.
11996 (pdp11_fixed_cc_regs): New function.
11997 (pdp11_cc_mode): Ditto.
11998 (pdp11_expand_shift): Ditto.
11999 (pdp11_assemble_shift): Ditto.
12000 (pdp11_small_shift): Ditto.
12001 (pdp11_branch_cost): Remove.
12002 * config/pdp11/pdp11.c (pdp11_assemble_integer): Remove comments
12003 from output.
12004 (pdp11_register_move_cost): Update for CC registers.
12005 (pdp11_rtx_costs): Add case for LSHIFTRT.
12006 (pdp11_output_jump): Add CCNZ mode conditional branches.
12007 (notice_update_cc_on_set): Remove.
12008 (pdp11_cc_mode): New function.
12009 (simple_memory_operand): Correct pre/post decrement case.
12010 (no_side_effect_operand): New function.
12011 (pdp11_regno_reg_class): Add CC_REGS class.
12012 (pdp11_fixed_cc_regs): New function.
12013 (pdp11_small_shift): New function.
12014 (pdp11_expand_shift): New function to expand shift insns.
12015 (pdp11_assemble_shift): New function to output shifts.
12016 (pdp11_branch_cost): Remove.
12017 (pdp11_modes_tieable_p): Make QI/HI modes tieable.
12018 * config/pdp11/pdp11.h (SIZE_TYPE): Ensure 16-bit type.
12019 (WCHAR_TYPE): Ditto.
12020 (PTRDIFF_TYPE): Ditto.
12021 (ADJUST_INSN_LENGTH): New macro.
12022 (FIXED_REGISTERS): Add CC registers.
12023 (CALL_USED_REGISTERS): Ditto.
12024 (reg_class): Ditto.
12025 (REG_CLASS_NAMES): Ditto.
12026 (REG_CLASS_CONTENTS): Ditto.
12027 (SELECT_CC_MODE): Use new function.
12028 (TARGET_FLAGS_REGNUM): New macro.
12029 (TARGET_FIXED_CONDITION_CODE_REGS): Ditto.
12030 (cc0_reg_rtx): Remove.
12031 (CC_STATUS_MDEP): Remove.
12032 (CC_STATUS_MDEFP_INIT): Remove.
12033 (CC_IN_FPU): Remove.
12034 (NOTICE_UPDATE_CC): Remove.
12035 (REGISTER_NAMES): Add CC registers.
12036 (BRANCH_COST): Change to constant 1.
12037 * config/pdp11/pdp11.md: Rewrite for CCmode condition code
12038 handling.
12039 * config/pdp11/pdp11.opt (mbcopy): Remove.
12040 (mbcopy-builtin): Remove.
12041 (mbranch-cheap): Remove.
12042 (mbranch-expensive): Remove.
12043 * config/pdp11/predicates.md (expand_shift_operand): Update to
12044 match shift code generation.
12045 (ccnz_operator): New predicate.
12046 * doc/invoke.texi (PDP-11 Options): Remove deleted options
12047 -mbcopy, -mbcopy-builtin, -mbranch-cheap, -mbranch-expensive.
12048 Remove non-existent option -mabshi, -mno-abshi. Document mutually
12049 exclusive options.
12050 * doc/md.texi (PDP-11): Document new D and h constraints. Update
12051 description of O constraint.
12052
12053 2018-06-27 Jeff Law <law@redhat.com>
12054 Austin Law <austinklaw@gmail.com>
12055
12056 * config/v850/v850.md (addsi3_set_flags): New pattern.
12057 (subsi3_set_flags, negsi2_set_flags, andsi3_set_flags): Likewise.
12058 (iorsi3_set_flags, xorsi3_set_flags, one_cmplsi2_set_flags): Likewise.
12059 (zero_extendhisi2_v850_set_flags): Likewise.
12060 (zero_extendqisi2_v850_set_flags): Likewise.
12061 (ashlsi3_set_flags, ashlsi3_v850e2_set_flags): Likewise.
12062 (lshrsi3_set_flags, lshrsi3_v850e2_set_flags): Likewise.
12063 (ashrsi3_set_flags, ashrsi3_v850e2_set_flags): Likewise.
12064
12065 * config/v850/v850-protos.h (notice_update_cc): Remove.
12066 * config/v850/v850.c (v850_compare_op0, v850_compare_op1): Remove.
12067 (v850_print_operand): Handle 'D' and "d".
12068 (v850_select_cc_mode): Remove ATTRIBUTE_UNUSED for last argument.
12069 Add handling of arithmetic/logical operations compared against zero.
12070 (v850_gen_float_compare): Remove ATTRIBUTE_UNUSED for last argument.
12071 Do not look at v850_compare_op, instead get mode from last argument.
12072 (v850_gen_compare): Remove
12073 (increment_stack): Use addsi3_clobber_flags to avoid splitting failure
12074 after reload for prologue insns.
12075 (expand_prologue): Account for CLOBBER of CC_REGNUM in various
12076 patterns.
12077 (construct_save_jarl): Likewise.
12078 (TARGET_FLAGS_REGNUM): Define.
12079 * config/v850/v850.h (v850_compare_op0, v850_compare_op1): Remove.
12080 (NOTICE_UPDATE_CC): Remove.
12081 * config/v850/v850.md (v850_tst1): Use (reg:CCZ CC_REGNUM) rather
12082 than cc0. Conditionalize on reload_completed.
12083 (cmpsi_insn, setfcc_insn): Likewise.
12084 (tst1 splitter): Turn into define_and_split which sets the flags
12085 after reload.
12086 (cstoresi4, cbranchsf4, cbranchdf4, cbranchsi4_insn): Likewise.
12087 (cbranchsi4, branch_normal, branch_invert): Do not expose cc0 here.
12088 (cstoresf4, cstoredf4): Clobber the flags.
12089 (cmpsi, cmpsf, cmpdf): Remove expanders.
12090 (setf_insn): Remove pattern.
12091 (addsi3): Turn into define_and_split which clobbers the flags after
12092 reload and a suitable pattern (addsi3_clobber_flags) for use after
12093 reload.
12094 (subsi3, negsi2, andsi3, iorsi3, xorsi3, one_cmplsi2) Likewise.
12095 (ashlsi3, ashlsi3_v850e2, lshrsi3, lsh4si3_v850e2): Likewise.
12096 (ashrsi3, ashrsi3_v850e2): Likewise.
12097 (bins): Clobber the flags.
12098 (movsicc_normal_cc, movsicc_normal, movsicc_tst1): Likewise.
12099 (movsicc_tst1_revesed, sasf, swap and rotate patterns): Likewise.
12100 (fix_loop_counter, call_internal_short, call_internal_long): Likewise.
12101 (call_value_internal_short, call_value_internal_long): Likewise.
12102 (callt_save_interrupt, callt_return_interrupt): Likewise.
12103 (save_interrupt, return_interrupt): Likewise.
12104 (callt_save_all_interrupt, save_all_interrupt): Likewise.
12105 (_save_all_interrupt, callt_restore_all_interrupt): Likewise.
12106 (restore_all_interrupt, _restore_all_interrupt): Likewise.
12107 (All FP comparisons): Only allow after reload has completed.
12108 (trfsr): Likewise.
12109 (divh, divhu): Tweak output template.
12110 (branch_z_normal, branch_z_invert): Remove
12111 (branch_nz_normal, branch_nz_invert): Likewise.
12112 (extendhisi_insn, extendqisi_insn): Do not clobber flags.
12113
12114 * config/v850/v850-modes.def (CCZ, CCNZ): Add new modes.
12115 * config/v850/v850.c (notice_update_cc): Remove.
12116 * config/v850/v850.h (CC_OVERFLOW_UNUSABLE): Remove
12117 (CC_NO_CARRY): Likewise.
12118 (NOTICE_UPDATE_CC): Define to nothing.
12119 * config/v850/v850.md: Remove block comment on cc0 handling
12120 Remove "cc" attribute from all patterns. Remove cc_status handling
12121 from all patterns. Minor formatting fixes.
12122
12123 2018-06-27 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
12124
12125 * config/aarch64/aarch64-cores.def (cortex-a76): New entry.
12126 (cortex-a76.cortex-a55): Likewise.
12127 * config/aarch64/aarch64-tune.md: Regenerate.
12128 * doc/invoke.texi (AArch64 Options): Document cortex-a76 and
12129 cortex-a76.cortex-a55.
12130
12131 2018-06-27 Jeff Law <law@redhat.com>
12132
12133 * config/v850/t-v850 (MULTILIB_OPTIONS): Remove 8byte-align.
12134 (MULTILIB_DIRNAMES): Similarly.
12135
12136 2018-06-27 Eric Botcazou <ebotcazou@adacore.com>
12137
12138 * gimple.h (gimple_return_retbnd): Delete.
12139 (gimple_return_set_retbnd): Likewise.
12140 * cgraphunit.c (cgraph_node::expand_thunk): Remove call to
12141 gimple_return_set_retbnd.
12142 * gimple-pretty-print.c (dump_gimple_return): Remove call to
12143 gimple_return_retbnd and adjust.
12144 * tree-inline.h (struct copy_body_data): Remove retbnd field.
12145 * tree-inline.c (remap_gimple_stmt): Remove handling of retbnd.
12146 Explicitly return NULL in a couple more cases. Move assertion
12147 on debug statements and remove unreachable code.
12148 (reset_debug_binding): Do not test id->retbnd.
12149 (expand_call_inline): Do not set it.
12150
12151 2018-06-27 Rasmus Villemoes <rv@rasmusvillemoes.dk>
12152
12153 * configure.ac: Add --disable-gcov option.
12154 * configure: Regenerate.
12155 * Makefile.in: Honour @enable_gcov@.
12156 * doc/install.texi: Document --disable-gcov.
12157
12158 2018-06-27 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
12159
12160 * config/arm/arm-cpus.in (cortex-a76): New entry.
12161 (cortex-a76.cortex-a55): Likewise.
12162 * config/arm/arm-tables.opt: Regenerate.
12163 * config/arm/arm-tune.md: Likewise.
12164 * config/arm/driver-arm.c (arm_cpu_table): Add Cortex-A76 entry.
12165 * doc/invoke.texi (ARM Options): Document cortex-a76 and
12166 cortex-a76.cortex-a55.
12167
12168 2018-06-27 Tamar Christina <tamar.christina@arm.com>
12169
12170 PR target/85769
12171 * config/aarch64/aarch64.md (*movhf_aarch64): Add dup v0.4h pattern.
12172
12173 2018-06-27 Siddhesh Poyarekar <siddhesh@sourceware.org>
12174
12175 * config/aarch64/aarch64.h (CALL_USE_REGISTERS): Fix obsolete
12176 comment.
12177 (EPILOGUE_USES): Likewise.
12178
12179 2018-06-26 Eric Botcazou <ebotcazou@adacore.com>
12180
12181 * tree-inline.c (remap_location): New function extracted from...
12182 (copy_edges_for_bb): Add ID parameter. Remap goto_locus.
12183 (copy_phis_for_bb): ...here. Call remap_location.
12184 (copy_cfg_body): Adjust call to copy_edges_for_bb.
12185
12186 2018-06-26 Aaron Sawdey <acsawdey@linux.ibm.com>
12187
12188 * config/rs6000/rs6000-string.c (expand_block_clear): Don't use
12189 unaligned vsx for 16B memset.
12190
12191 2018-06-26 Segher Boessenkool <segher@kernel.crashing.org>
12192
12193 PR target/86285
12194 * config/rs6000/rs6000.c (rs6000_init_builtins): Do not set
12195 ieee128_float_type_node to long_double_type_node unless
12196 TARGET_LONG_DOUBLE_128 is set.
12197
12198 2018-06-26 David Malcolm <dmalcolm@redhat.com>
12199
12200 * cfgloop.c (get_loop_location): Convert return type from
12201 location_t to dump_user_location_t, replacing INSN_LOCATION lookups
12202 by implicit construction from rtx_insn *, and using
12203 dump_user_location_t::from_function_decl for the fallback case.
12204 * cfgloop.h (get_loop_location): Convert return type from
12205 location_t to dump_user_location_t.
12206 * cgraphunit.c (walk_polymorphic_call_targets): Update call to
12207 dump_printf_loc to pass in a dump_location_t rather than a
12208 location_t, via the gimple stmt.
12209 * coverage.c (get_coverage_counts): Update calls to
12210 dump_printf_loc to pass in dump_location_t rather than a
12211 location_t.
12212 * doc/optinfo.texi (Dump types): Convert example of
12213 dump_printf_loc from taking "locus" to taking "insn". Update
12214 description of the "_loc" calls to cover dump_location_t.
12215 * dumpfile.c: Include "backend.h", "gimple.h", "rtl.h", and
12216 "selftest.h".
12217 (dump_user_location_t::dump_user_location_t): New constructors,
12218 from gimple *stmt and rtx_insn *.
12219 (dump_user_location_t::from_function_decl): New function.
12220 (dump_loc): Make static.
12221 (dump_gimple_stmt_loc): Convert param "loc" from location_t to
12222 const dump_location_t &.
12223 (dump_generic_expr_loc): Delete.
12224 (dump_printf_loc): Convert param "loc" from location_t to
12225 const dump_location_t &.
12226 (selftest::test_impl_location): New function.
12227 (selftest::dumpfile_c_tests): New function.
12228 * dumpfile.h: Include "profile-count.h".
12229 (class dump_user_location_t): New class.
12230 (struct dump_impl_location_t): New struct.
12231 (class dump_location_t): New class.
12232 (dump_printf_loc): Convert 2nd param from source_location to
12233 const dump_location_t &.
12234 (dump_generic_expr_loc): Delete.
12235 (dump_gimple_stmt_loc): Convert 2nd param from source_location to
12236 const dump_location_t &.
12237 * gimple-fold.c (fold_gimple_assign): Update call to
12238 dump_printf_loc to pass in a dump_location_t rather than a
12239 location_t, via the gimple stmt.
12240 (gimple_fold_call): Likewise.
12241 * gimple-loop-interchange.cc
12242 (loop_cand::analyze_iloop_reduction_var): Update for change to
12243 check_reduction_path.
12244 (tree_loop_interchange::interchange): Update for change to
12245 find_loop_location.
12246 * graphite-isl-ast-to-gimple.c (scop_to_isl_ast): Update for
12247 change in return-type of find_loop_location.
12248 (graphite_regenerate_ast_isl): Likewise.
12249 * graphite-optimize-isl.c (optimize_isl): Likewise.
12250 * graphite.c (graphite_transform_loops): Likewise.
12251 * ipa-devirt.c (ipa_devirt): Update call to dump_printf_loc to
12252 pass in a dump_location_t rather than a location_t, via the
12253 gimple stmt.
12254 * ipa-prop.c (ipa_make_edge_direct_to_target): Likewise.
12255 * ipa.c (walk_polymorphic_call_targets): Likewise.
12256 * loop-unroll.c (report_unroll): Convert "locus" param from
12257 location_t to dump_location_t.
12258 (decide_unrolling): Update for change to get_loop_location's
12259 return type.
12260 * omp-grid.c (struct grid_prop): Convert field "target_loc" from
12261 location_t to dump_user_location_t.
12262 (grid_find_single_omp_among_assignments_1): Updates calls to
12263 dump_printf_loc to pass in a dump_location_t rather than a
12264 location_t, via the gimple stmt.
12265 (grid_parallel_clauses_gridifiable): Convert "tloc" from
12266 location_t to dump_location_t. Updates calls to dump_printf_loc
12267 to pass in a dump_location_t rather than a location_t, via the
12268 gimple stmt.
12269 (grid_inner_loop_gridifiable_p): Likewise.
12270 (grid_dist_follows_simple_pattern): Likewise.
12271 (grid_gfor_follows_tiling_pattern): Likewise.
12272 (grid_target_follows_gridifiable_pattern): Likewise.
12273 (grid_attempt_target_gridification): Convert initialization
12274 of local "grid" from memset to zero-initialization; FIXME: does
12275 this require C++11? Update call to dump_printf_loc to pass in a
12276 optinfo_location rather than a location_t, via the gimple stmt.
12277 * profile.c (read_profile_edge_counts): Updates call to
12278 dump_printf_loc to pass in a dump_location_t rather than a
12279 location_t
12280 (compute_branch_probabilities): Likewise.
12281 * selftest-run-tests.c (selftest::run_tests): Call
12282 dumpfile_c_tests.
12283 * selftest.h (dumpfile_c_tests): New decl.
12284 * tree-loop-distribution.c (pass_loop_distribution::execute):
12285 Update for change in return type of find_loop_location.
12286 * tree-parloops.c (parallelize_loops): Likewise.
12287 * tree-ssa-loop-ivcanon.c (try_unroll_loop_completely): Convert
12288 "locus" from location_t to dump_user_location_t.
12289 (canonicalize_loop_induction_variables): Likewise.
12290 * tree-ssa-loop-ivopts.c (tree_ssa_iv_optimize_loop): Update
12291 for change in return type of find_loop_location.
12292 * tree-ssa-loop-niter.c (number_of_iterations_exit): Update call
12293 to dump_printf_loc to pass in a dump_location_t rather than a
12294 location_t, via the stmt.
12295 * tree-ssa-sccvn.c (eliminate_dom_walker::before_dom_children):
12296 Likewise.
12297 * tree-vect-loop-manip.c (find_loop_location): Convert return
12298 type from source_location to dump_user_location_t.
12299 (vect_do_peeling): Update for above change.
12300 (vect_loop_versioning): Update for change in type of
12301 vect_location.
12302 * tree-vect-loop.c (check_reduction_path): Convert "loc" param
12303 from location_t to dump_user_location_t.
12304 (vect_estimate_min_profitable_iters): Update for change in type
12305 of vect_location.
12306 * tree-vect-slp.c (vect_print_slp_tree): Convert param "loc" from
12307 location_t to dump_location_t.
12308 (vect_slp_bb): Update for change in type of vect_location.
12309 * tree-vectorizer.c (vect_location): Convert from source_location
12310 to dump_user_location_t.
12311 (try_vectorize_loop_1): Update for change in vect_location's type.
12312 (vectorize_loops): Likewise.
12313 (increase_alignment): Likewise.
12314 * tree-vectorizer.h (vect_location): Convert from source_location
12315 to dump_user_location_t.
12316 (find_loop_location): Convert return type from source_location to
12317 dump_user_location_t.
12318 (check_reduction_path): Convert 1st param from location_t to
12319 dump_user_location_t.
12320 * value-prof.c (check_counter): Update call to dump_printf_loc to
12321 pass in a dump_user_location_t rather than a location_t; update
12322 call to error_at for change in type of "locus".
12323 (check_ic_target): Update call to dump_printf_loc to
12324 pass in a dump_user_location_t rather than a location_t, via the
12325 call_stmt.
12326
12327 2018-06-26 Robin Dapp <rdapp@linux.vnet.ibm.com>
12328
12329 * config/s390/s390.h (enum processor_flags): Do not use
12330 default tune parameter when -march was specified.
12331
12332 2018-06-26 Jakub Jelinek <jakub@redhat.com>
12333
12334 PR target/86314
12335 * config/i386/i386.md (setcc + movzbl to xor + setcc peephole2s):
12336 Check reg_overlap_mentioned_p in addition to reg_set_p with the same
12337 operands.
12338
12339 2018-06-26 Richard Biener <rguenther@suse.de>
12340
12341 PR tree-optimization/86287
12342 PR bootstrap/86316
12343 * tree-vect-loop.c (vect_transform_loop_stmt): Fix read-after-free.
12344 (vect_analyze_loop): Initialize n_stmts.
12345
12346 2018-06-26 Richard Biener <rguenther@suse.de>
12347
12348 PR middle-end/86271
12349 * fold-const.c (fold_convertible_p): Pointer extension
12350 isn't valid.
12351
12352 2018-06-26 Alexandre Oliva <aoliva@redhat.com>
12353
12354 PR debug/86064
12355 * dwarf2out.c (loc_list_has_views): Adjust comments.
12356 (dw_loc_list): Split single cross-partition range with
12357 nonzero locview.
12358
12359 2018-06-25 Jeff Law <law@redhat.com>
12360
12361 * common/config/v850/v850-common.c (TARGET_DEFAULT_TARGET_FLAGS): Turn
12362 on -mbig-switch by default.
12363
12364 * config/v850/predicates.md (const_float_1_operand): Fix match_code
12365 test.
12366 (const_float_0_operand): Remove unused predicate.
12367 * config/v850/v850.md (define_constants): Remove UNSPEC_LOOP.
12368 (define_c_enum unspec): Add LOOP, RCP and RSQRT constants.
12369 (recipsf2): New expander. Original pattern now called
12370 (recipsf2_insn).
12371 (recipdf2, recipdf2_insn): Similarly.
12372 (rsqrtsf2, rsqrtsf2_insn): Similarly
12373 (rsqrtdf2, rsqrtdf2_insn): Similarly
12374
12375 2018-06-26 Gerald Pfeifer <gerald@pfeifer.com>
12376
12377 * ginclude/stddef.h: Remove an obsolete comment on FreeBSD 5.
12378 Simplify logic for FreeBSD (twice).
12379
12380 2018-06-25 Martin Sebor <msebor@redhat.com>
12381
12382 PR tree-optimization/86204
12383 * tree-ssa-strlen.c (handle_builtin_strlen): Avoid storing
12384 a strnlen result if it's less than the length of the string.
12385
12386 2018-06-25 Martin Sebor <msebor@redhat.com>
12387
12388 PR tree-optimization/85700
12389 * gimple-fold.c (gimple_fold_builtin_strncat): Adjust comment.
12390 * tree-ssa-strlen.c (is_strlen_related_p): Handle integer subtraction.
12391 (maybe_diag_stxncpy_trunc): Distinguish strncat from strncpy.
12392
12393 2018-06-25 Martin Sebor <msebor@redhat.com>
12394
12395 * doc/extend.texi (Zero-length arrays): Update and clarify.
12396
12397 2018-06-25 Michael Meissner <meissner@linux.ibm.com>
12398
12399 * config.gcc (powerpc64le*): Revert January 16th, 2018 patch that
12400 added IEEE/IBM long double multilib support on PowerPC little
12401 endian Linux systems.
12402 * config/rs6000/linux64.h (MULTILIB_DEFAULTS_IEEE): Likewise.
12403 (MULTILIB_DEFAULTS): Likewise.
12404 * config/rs6000/rs6000.c (rs6000_option_override_internal):
12405 Likewise.
12406 * config/rs6000/rs6000.h (TARGET_IEEEQUAD_MULTILIB): Likewise.
12407 * config/rs6000/t-ldouble-linux64le-ibm: Delete, no longer used.
12408 * config/rs6000/t-ldouble-linux64le-ieee: Delete, no longer used.
12409
12410 2018-06-25 Alexander Monakov <amonakov@ispras.ru>
12411
12412 PR middle-end/86311
12413 * sort.cc (REORDER_23): Avoid memcpy with same destination and source.
12414 (REORDER_45): Likewise.
12415
12416 2018-06-25 Jeff Law <law@redhat.com>
12417
12418 * config/v850/v850.md (divmodhi4): Make sure to sign extend the
12419 dividend to 32 bits. Adjust length.
12420 (udivmodhi4): Cleanup output template. Fix length.
12421
12422 2018-06-25 Carl Love <cel@us.ibm.com>
12423
12424 * config/rs6000/vsx.md: Change word selector to prefered location.
12425
12426 2018-06-25 Richard Biener <rguenther@suse.de>
12427
12428 PR tree-optimization/86304
12429 * tree-vectorizer.c (vectorize_loops): Walk over new possibly
12430 epilogue-if-converted loops as well.
12431
12432 2018-06-25 Jan Hubicka <hubicka@ucw.cz>
12433
12434 * lto-section-out.c (lto_begin_section): Do not print section
12435 name for noaddr and unnumbered dumps.
12436
12437 2018-06-25 Richard Biener <rguenther@suse.de>
12438
12439 * tree-vectorizer.h (struct vec_info_shared): New structure
12440 with parts split out from struct vec_info and loop_nest from
12441 struct _loop_vec_info.
12442 (struct vec_info): Adjust accordingly.
12443 (struct _loop_vec_info): Likewise.
12444 (LOOP_VINFO_LOOP_NEST): Adjust.
12445 (LOOP_VINFO_DATAREFS): Likewise.
12446 (LOOP_VINFO_DDRS): Likewise.
12447 (struct _bb_vec_info): Likewise.
12448 (BB_VINFO_DATAREFS): Likewise.
12449 (BB_VINFO_DDRS): Likewise.
12450 (struct _stmt_vec_info): Add dr_aux member.
12451 (DR_VECT_AUX): Adjust to refer to member of DR_STMTs vinfo.
12452 (DR_MISALIGNMENT_UNINITIALIZED): New.
12453 (set_dr_misalignment): Adjust.
12454 (dr_misalignment): Assert misalign isn't DR_MISALIGNMENT_UNINITIALIZED.
12455 (vect_analyze_loop): Adjust prototype.
12456 (vect_analyze_loop_form): Likewise.
12457 * tree-vect-data-refs.c (vect_analyze_data_ref_dependences):
12458 Compute dependences lazily.
12459 (vect_record_base_alignments): Use shared datarefs/ddrs.
12460 (vect_verify_datarefs_alignment): Likewise.
12461 (vect_analyze_data_refs_alignment): Likewise.
12462 (vect_analyze_data_ref_accesses): Likewise.
12463 (vect_analyze_data_refs): Likewise.
12464 * tree-vect-loop.c (_loop_vec_info::_loop_vec_info): Add
12465 constructor parameter for shared part.
12466 (vect_analyze_loop_form): Pass in shared part and adjust.
12467 (vect_analyze_loop_2): Pass in storage for the number of
12468 stmts. Move loop nest finding to the caller. Compute
12469 datarefs lazily.
12470 (vect_analyze_loop): Pass in shared part.
12471 (vect_transform_loop): Verify shared datarefs are unchanged.
12472 * tree-vect-slp.c (_bb_vec_info::_bb_vec_info): Add
12473 constructor parameter for shared part.
12474 (vect_slp_analyze_bb_1): Pass in shared part and adjust.
12475 (vect_slp_bb): Verify shared datarefs are unchanged before
12476 transform.
12477 * tree-vect-stmts.c (ensure_base_align): Adjust for DR_AUX
12478 change.
12479 (new_stmt_vec_info): Initialize DR_AUX misalignment to
12480 DR_MISALIGNMENT_UNINITIALIZED.
12481 * tree-vectorizer.c (vec_info::vec_info): Add constructor
12482 parameter for shared part.
12483 (vec_info::~vec_info): Adjust.
12484 (vec_info_shared::vec_info_shared): New.
12485 (vec_info_shared::~vec_info_shared): Likewise.
12486 (vec_info_shared::save_datarefs): Likewise.
12487 (vec_info_shared::check_datarefs): Likewise.
12488 (try_vectorize_loop_1): Construct shared part live for analyses
12489 of a single loop for multiple vector sizes.
12490 * tree-parloops.c (gather_scalar_reductions): Adjust.
12491
12492 2018-06-25 Richard Biener <rguenther@suse.de>
12493
12494 * tree-vect-data-refs.c (vect_find_stmt_data_reference): Modify
12495 DR for SIMD lane accesses here and mark DR with (void *)-1 aux.
12496 (vect_analyze_data_refs): Remove similar code from here and
12497 simplify accordingly.
12498
12499 2018-06-25 Richard Biener <rguenther@suse.de>
12500
12501 * tree-vect-data-refs.c (vect_check_gather_scatter): Fail
12502 for reverse storage order accesses rather than asserting
12503 they cannot happen here.
12504
12505 2018-06-25 Tom de Vries <tdevries@suse.de>
12506
12507 PR debug/86257
12508 * config/i386/i386.md (define_insn "*tls_global_dynamic_64_<mode>"):
12509 Use data16 instead of .byte for insn prefix.
12510
12511 2018-06-25 Andreas Krebbel <krebbel@linux.ibm.com>
12512
12513 PR C++/86082
12514 * parser.c (make_char_string_pack): Pass this literal chars
12515 through cpp_interpret_string.
12516 (cp_parser_userdef_numeric_literal): Check the result of
12517 make_char_string_pack.
12518
12519 2018-06-24 Maya Rashish <coypu@sdf.org>
12520
12521 * ginclude/stddef.h: Simplify conditions around avoiding
12522 re-definition of __size_t.
12523
12524 2018-06-22 Jan Hubicka <hubicka@ucw.cz>
12525
12526 * lto-streamer-out.c (tree_is_indexable): Make LABEL_DECL nonindexable
12527 unless it is forced or nonlocal; assert that we stream no IMPORTED_DECL.
12528
12529 2018-06-22 Maya Rashish <coypu@sdf.org>
12530
12531 * doc/invoke.texi (mno-fancy-math-387): Update for changes
12532 made to OpenBSD and NetBSD through the years.
12533
12534 2018-06-22 Kelvin Nilsen <kelvin@gcc.gnu.org>
12535
12536 * config/rs6000/rs6000-c.c (altivec_overloaded_builtins): Change
12537 behavior of vec_pack (vector double, vector double) to match
12538 behavior of vec_float2 (vector double, vector double).
12539
12540 2018-06-22 Olivier Hainque <hainque@adacore.com>
12541
12542 * gimplify.c (gimplify_function_tree): Prevent creation
12543 of a trampoline for the address of the current function
12544 passed to entry/exit instrumentation hooks.
12545
12546 2018-06-22 Aaron Sawdey <acsawdey@linux.ibm.com>
12547
12548 PR target/86222
12549 * config/rs6000/rs6000-string.c (expand_strn_compare): Handle -m32
12550 correctly.
12551
12552 2018-06-22 Martin Liska <mliska@suse.cz>
12553
12554 PR tree-optimization/86263
12555 * tree-switch-conversion.c (jump_table_cluster::find_jump_tables):
12556 Bail out if is_enabled is false.
12557 * tree-switch-conversion.h (jump_table_cluster::is_enabled):
12558 New declaration.
12559 (jump_table_cluster::is_enabled): New function.
12560
12561 2018-06-22 Jan Hubicka <hubicka@ucw.cz>
12562
12563 * lto-streamer-out.c (DFS::DFS_write_tree_body): Do not stream
12564 BINFO_BASE_ACCESSES and BINFO_VPTR_FIELD.
12565 * tree-streamer-in.c (streamer_read_tree_bitfields): Likewise.
12566 (lto_input_ts_binfo_tree_pointers): Likewise.
12567 * tree-streamer-out.c (streamer_write_tree_bitfields,
12568 write_ts_binfo_tree_pointers): Likewise.
12569 * tree.c (free_lang_data_in_binfo): Clear BINFO_VPTR_FIELD.
12570
12571 2018-06-22 Jan Hubicka <hubicka@ucw.cz>
12572
12573 * tree.c (free_lang_data_in_type): Free all TYPE_VFIELDs.
12574
12575 2018-06-22 Martin Liska <mliska@suse.cz>
12576
12577 * symbol-summary.h (get): Make it pure and inline move
12578 functionality from ::get function.
12579 (get): Remove and inline into ::get and ::get_create.
12580 (get_create): Move code from ::get function.
12581
12582 2018-06-22 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
12583
12584 PR target/85994
12585 * config/i386/sol2.h (CPP_SPEC): Don't pass -P for
12586 -x assembler-with-cpp.
12587
12588 2018-06-22 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
12589
12590 * config/sol2.h (TARGET_OS_CPP_BUILTINS): Define
12591 _FILE_OFFSET_BITS=64 for C++.
12592
12593 2018-06-21 Michael Meissner <meissner@linux.ibm.com>
12594
12595 * config/rs6000/rs6000.md (extendtfif2): Add missing 128-bit
12596 conversion insn that shows up when pr85657-3.c is compiled using
12597 IEEE 128-bit long double.
12598 (neg<mode>2_internal): Use the correct mode to check whether the
12599 mode is IBM extended.
12600 * config/rs6000/rs6000.c (init_float128_ieee): Prevent complex
12601 multiply and divide external functions from being created more
12602 than once.
12603
12604 2018-06-21 Eric Botcazou <ebotcazou@adacore.com>
12605
12606 * cfgrtl.c (fixup_reorder_chain): Do not emit NOPs in DECL_IGNORED_P
12607 functions.
12608 (rtl_merge_blocks): Likewise. Do not emit a NOP if the location of
12609 the edge can be forwarded.
12610 (cfg_layout_merge_blocks): Likewise.
12611
12612 2018-06-21 Eric Botcazou <ebotcazou@adacore.com>
12613
12614 * except.c (finish_eh_generation): Commit edge insertions only after
12615 the EH edges have been redirected from post-landing to landing pads.
12616
12617 2018-06-21 Eric Botcazou <ebotcazou@adacore.com>
12618
12619 * tree-nested.c (get_frame_type): Use create_tmp_var_raw instead of
12620 create_tmp_var_for to create the FRAME decl.
12621 (finalize_nesting_tree_1): Do not unchain the FRAME decl.
12622
12623 2018-06-21 Eric Botcazou <ebotcazou@adacore.com>
12624
12625 * tree-inline.c (copy_edges_for_bb): Minor tweak.
12626 (maybe_move_debug_stmts_to_successors): Also reset the locus of the
12627 debug statement when resetting its value.
12628 (expand_call_inline): Copy the locus of the call onto the assignment
12629 of the return value, if any. Use local variable in more cases.
12630
12631 2018-06-21 Martin Liska <mliska@suse.cz>
12632
12633 * ipa-pure-const.c (propagate_nothrow): Use
12634 funct_state_summaries->get.
12635 (dump_malloc_lattice): Likewise.
12636 (propagate_malloc): Likewise.
12637
12638 2018-06-21 Richard Biener <rguenther@suse.de>
12639
12640 * lto-streamer-out.c (DFS::DFS_write_tree_body): Update outdated
12641 comment. Follow BLOCK_ABSTRACT_ORIGIN unconditionally.
12642 * tree-streamer-in.c (lto_input_ts_block_tree_pointers): Update
12643 comment.
12644 * tree-streamer-out.c (write_ts_block_tree_pointers): Stream
12645 BLOCK_ABSTRACT_ORIGIN unconditionally.
12646
12647 2018-06-21 David Malcolm <dmalcolm@redhat.com>
12648
12649 * ipa-cp.c (ipcp_driver): Set edge_clone_summaries to NULL after
12650 deleting it.
12651 * ipa-reference.c (ipa_reference_c_finalize): Delete
12652 ipa_ref_opt_sum_summaries and set it to NULL.
12653
12654 2018-06-21 Tom de Vries <tdevries@suse.de>
12655
12656 PR tree-optimization/85859
12657 * tree-ssa-tail-merge.c (stmt_local_def): Copy gimple_is_call
12658 test with comment from bb_no_side_effects_p.
12659
12660 2018-06-21 Richard Biener <rguenther@suse.de>
12661
12662 PR tree-optimization/86232
12663 * tree-ssa-loop-niter.c (number_of_iterations_popcount): Adjust
12664 max for constant niter.
12665
12666 2018-06-21 Andre Vieira <andre.simoesdiasvieira@arm.com>
12667
12668 * config/aarch64/aarch64-simd.md
12669 (*aarch64_crypto_aes<aes_op>v16qi_xor_combine): New.
12670
12671 2018-06-21 Andre Vieira <andre.simoesdiasvieira@arm.com>
12672
12673 * config/aarch64/aarch64-simd.md (aarch64_crypto_aes<aes_op>v16qi):
12674 Make opernads of the unspec commutative.
12675
12676 2018-06-21 Richard Biener <rguenther@suse.de>
12677
12678 * tree-data-ref.c (dr_step_indicator): Handle NULL DR_STEP.
12679 * tree-vect-data-refs.c (vect_analyze_possibly_independent_ddr):
12680 Avoid calling vect_mark_for_runtime_alias_test with gathers or scatters.
12681 (vect_analyze_data_ref_dependence): Re-order checks to deal with
12682 NULL DR_STEP.
12683 (vect_record_base_alignments): Do not record base alignment
12684 for gathers or scatters.
12685 (vect_compute_data_ref_alignment): Drop return value that is always
12686 true. Bail out early for gathers or scatters.
12687 (vect_enhance_data_refs_alignment): Bail out early for gathers
12688 or scatters.
12689 (vect_find_same_alignment_drs): Likewise.
12690 (vect_analyze_data_refs_alignment): Remove dead code.
12691 (vect_slp_analyze_and_verify_node_alignment): Likewise.
12692 (vect_analyze_data_refs): For possible gathers or scatters do
12693 not create an alternate DR, just check their possible validity
12694 and mark them. Adjust DECL_NONALIASED handling to not rely
12695 on DR_BASE_ADDRESS.
12696 * tree-vect-loop-manip.c (vect_update_inits_of_drs): Do not
12697 update inits of gathers or scatters.
12698 * tree-vect-patterns.c (vect_recog_mask_conversion_pattern):
12699 Also copy gather/scatter flag to pattern vinfo.
12700
12701 2018-06-20 Kelvin Nilsen <kelvin@gcc.gnu.org>
12702
12703 * config/rs6000/rs6000-c.c (altivec_overloaded_builtins): Change
12704 behavior of vec_packsu (vector unsigned long long, vector unsigned
12705 long long) to match behavior of vec_packs with same signature.
12706
12707 2018-06-20 Chung-Lin Tang <cltang@codesourcery.com>
12708 Thomas Schwinge <thomas@codesourcery.com>
12709 Cesar Philippidis <cesar@codesourcery.com>
12710
12711 * gimplify.c (gimplify_scan_omp_clauses): Add support for
12712 OMP_CLAUSE_{IF_PRESENT,FINALIZE}.
12713 (gimplify_adjust_omp_clauses): Likewise.
12714 (gimplify_oacc_declare_1): Add support for GOMP_MAP_RELEASE, remove
12715 support for GOMP_MAP_FORCE_{ALLOC,TO,FROM,TOFROM}.
12716 (gimplify_omp_target_update): Update handling of acc update and
12717 enter/exit data.
12718 * omp-low.c (install_var_field): Remove unused parameter
12719 base_pointers_restrict.
12720 (scan_sharing_clauses): Remove base_pointers_restrict parameter.
12721 Update call to install_var_field. Handle OMP_CLAUSE_{IF_PRESENT,
12722 FINALIZE}
12723 (omp_target_base_pointers_restrict_p): Delete.
12724 (scan_omp_target): Update call to scan_sharing_clauses.
12725 * tree-core.h (enum omp_clause_code): Add OMP_CLAUSE_{IF_PRESENT,
12726 FINALIZE}.
12727 * tree-nested.c (convert_nonlocal_omp_clauses): Handle
12728 OMP_CLAUSE_{IF_PRESENT,FINALIZE}.
12729 (convert_local_omp_clauses): Likewise.
12730 * tree-pretty-print.c (dump_omp_clause): Likewise.
12731 * tree.c (omp_clause_num_ops): Add entries for OMP_CLAUSE_{IF_PRESENT,
12732 FINALIZE}.
12733 (omp_clause_code_name): Likewise.
12734
12735 2018-06-20 Jakub Jelinek <jakub@redhat.com>
12736
12737 PR debug/86194
12738 * var-tracking.c (use_narrower_mode_test): Check if shift amount can
12739 be narrowed.
12740
12741 PR tree-optimization/86231
12742 * tree-vrp.c (union_ranges): For ( [ ) ] or ( )[ ] range and
12743 anti-range don't overwrite *vr0min before using it to compute *vr0max.
12744
12745 2018-06-20 Tom de Vries <tdevries@suse.de>
12746
12747 PR tree-optimization/86097
12748 * tree-ssa-loop-manip.c (canonicalize_loop_ivs): Also convert *nit to
12749 iv type if signedness of iv type is not the same as that of *nit.
12750
12751 2018-06-20 Jakub Jelinek <jakub@redhat.com>
12752
12753 * cfgrtl.c (rtl_verify_edges): Formatting fix. If bb->preds has any
12754 EDGE_EH edges, verify they are all EDGE_EH.
12755
12756 2018-06-20 Maya Rashish <coypu@sdf.org>
12757
12758 * ginclude/stddef.h: Limit #include <machine/ansi.h> to NetBSD.
12759
12760 2018-06-20 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
12761
12762 * config/aarch64/aarch64-tuning-flags.def (no_ldp_stp_qregs): New.
12763 * config/aarch64/aarch64.c (xgene1_tunings): Add
12764 AARCH64_EXTRA_TUNE_NO_LDP_STP_QREGS to tune_flags.
12765 (aarch64_mode_valid_for_sched_fusion_p):
12766 Allow 16-byte modes.
12767 (aarch64_classify_address): Allow 16-byte modes for load_store_pair_p.
12768 * config/aarch64/aarch64-ldpstp.md: Add peepholes for LDP STP of
12769 128-bit modes.
12770 * config/aarch64/aarch64-simd.md (load_pair<VQ:mode><VQ2:mode>):
12771 New pattern.
12772 (vec_store_pair<VQ:mode><VQ2:mode>): Likewise.
12773 * config/aarch64/iterators.md (VQ2): New mode iterator.
12774
12775 2018-06-20 Martin Liska <mliska@suse.cz>
12776
12777 * tree-switch-conversion.c (jump_table_cluster::can_be_handled):
12778 Change default ratio from 10 to 8.
12779
12780 2018-06-20 Martin Liska <mliska@suse.cz>
12781
12782 * tree-switch-conversion.c (jump_table_cluster::find_jump_tables):
12783 New.
12784 (bit_test_cluster::find_bit_tests): Likewise.
12785 (switch_decision_tree::analyze_switch_statement): Find clusters.
12786 * tree-switch-conversion.h (struct jump_table_cluster): Document
12787 hierarchy.
12788
12789 2018-06-20 Martin Liska <mliska@suse.cz>
12790
12791 * tree-switch-conversion.c (switch_conversion::collect):
12792 Record m_uniq property.
12793 (switch_conversion::expand): Bail out for special conditions.
12794 (group_cluster::~group_cluster): New.
12795 (group_cluster::group_cluster): Likewise.
12796 (group_cluster::dump): Likewise.
12797 (jump_table_cluster::emit): New.
12798 (switch_decision_tree::fix_phi_operands_for_edges): New.
12799 (struct case_node): Remove struct.
12800 (jump_table_cluster::can_be_handled): New.
12801 (case_values_threshold): Moved to header.
12802 (reset_out_edges_aux): Likewise.
12803 (jump_table_cluster::is_beneficial): New.
12804 (bit_test_cluster::can_be_handled): Likewise.
12805 (add_case_node): Remove.
12806 (bit_test_cluster::is_beneficial): New.
12807 (case_bit_test::cmp): New.
12808 (bit_test_cluster::emit): New.
12809 (expand_switch_as_decision_tree_p): Remove.
12810 (bit_test_cluster::hoist_edge_and_branch_if_true): New.
12811 (fix_phi_operands_for_edge): Likewise.
12812 (switch_decision_tree::analyze_switch_statement): New.
12813 (compute_cases_per_edge): Move ...
12814 (switch_decision_tree::compute_cases_per_edge): ... here.
12815 (try_switch_expansion): Likewise.
12816 (switch_decision_tree::try_switch_expansion): Likewise.
12817 (record_phi_operand_mapping): Likewise.
12818 (switch_decision_tree::record_phi_operand_mapping): Likewise.
12819 (emit_case_decision_tree): Likewise.
12820 (switch_decision_tree::emit): Likewise.
12821 (balance_case_nodes): Likewise.
12822 (switch_decision_tree::balance_case_nodes): Likewise.
12823 (dump_case_nodes): Likewise.
12824 (switch_decision_tree::dump_case_nodes): Likewise.
12825 (emit_jump): Likewise.
12826 (switch_decision_tree::emit_jump): Likewise.
12827 (emit_cmp_and_jump_insns): Likewise.
12828 (switch_decision_tree::emit_cmp_and_jump_insns): Likewise.
12829 (emit_case_nodes): Likewise.
12830 (switch_decision_tree::emit_case_nodes): Likewise.
12831 (conditional_probability): Remove.
12832 * tree-switch-conversion.h (enum cluster_type): New.
12833 (PRINT_CASE): New.
12834 (struct cluster): Likewise.
12835 (cluster::cluster): Likewise.
12836 (struct simple_cluster): Likewise.
12837 (simple_cluster::simple_cluster): Likewise.
12838 (struct group_cluster): Likewise.
12839 (struct jump_table_cluster): Likewise.
12840 (struct bit_test_cluster): Likewise.
12841 (struct min_cluster_item): Likewise.
12842 (struct case_tree_node): Likewise.
12843 (case_tree_node::case_tree_node): Likewise.
12844 (jump_table_cluster::case_values_threshold): Likewise.
12845 (struct case_bit_test): Likewise.
12846 (struct switch_decision_tree): Likewise.
12847 (struct switch_conversion): Likewise.
12848 (switch_decision_tree::reset_out_edges_aux): Likewise.
12849
12850 2018-06-20 Martin Liska <mliska@suse.cz>
12851
12852 * tree-switch-conversion.c (MAX_CASE_BIT_TESTS): Remove.
12853 (hoist_edge_and_branch_if_true): Likewise.
12854 (expand_switch_using_bit_tests_p): Likewise.
12855 (struct case_bit_test): Likewise.
12856 (case_bit_test_cmp): Likewise.
12857 (emit_case_bit_tests): Likewise.
12858 (switch_conversion::switch_conversion): New class.
12859 (struct switch_conv_info): Remove old struct.
12860 (collect_switch_conv_info): More to ...
12861 (switch_conversion::collect): ... this.
12862 (check_range): Likewise.
12863 (switch_conversion::check_range): Likewise.
12864 (check_all_empty_except_final): Likewise.
12865 (switch_conversion::check_all_empty_except_final): Likewise.
12866 (check_final_bb): Likewise.
12867 (switch_conversion::check_final_bb): Likewise.
12868 (create_temp_arrays): Likewise.
12869 (switch_conversion::create_temp_arrays): Likewise.
12870 (free_temp_arrays): Likewise.
12871 (gather_default_values): Likewise.
12872 (switch_conversion::gather_default_values): Likewise.
12873 (build_constructors): Likewise.
12874 (switch_conversion::build_constructors): Likewise.
12875 (constructor_contains_same_values_p): Likewise.
12876 (switch_conversion::contains_same_values_p): Likewise.
12877 (array_value_type): Likewise.
12878 (switch_conversion::array_value_type): Likewise.
12879 (build_one_array): Likewise.
12880 (switch_conversion::build_one_array): Likewise.
12881 (build_arrays): Likewise.
12882 (switch_conversion::build_arrays): Likewise.
12883 (gen_def_assigns): Likewise.
12884 (switch_conversion::gen_def_assigns): Likewise.
12885 (prune_bbs): Likewise.
12886 (switch_conversion::prune_bbs): Likewise.
12887 (fix_phi_nodes): Likewise.
12888 (switch_conversion::fix_phi_nodes): Likewise.
12889 (gen_inbound_check): Likewise.
12890 (switch_conversion::gen_inbound_check): Likewise.
12891 (process_switch): Use the newly created class.
12892 (switch_conversion::expand): New.
12893 (switch_conversion::~switch_conversion): New.
12894 * tree-switch-conversion.h: New file.
12895
12896 2018-06-20 Richard Sandiford <richard.sandiford@arm.com>
12897
12898 * tree-vectorizer.h (NUM_PATTERNS, vect_recog_func_ptr): Move to
12899 tree-vect-patterns.c.
12900 * tree-vect-patterns.c (vect_supportable_direct_optab_p): New function.
12901 (vect_recog_dot_prod_pattern): Use it. Remove the type_in argument.
12902 (vect_recog_sad_pattern): Likewise.
12903 (vect_recog_widen_sum_pattern): Likewise.
12904 (vect_recog_pow_pattern): Likewise. Check for a null vectype.
12905 (vect_recog_widen_shift_pattern): Remove the type_in argument.
12906 (vect_recog_rotate_pattern): Likewise.
12907 (vect_recog_mult_pattern): Likewise.
12908 (vect_recog_vector_vector_shift_pattern): Likewise.
12909 (vect_recog_divmod_pattern): Likewise.
12910 (vect_recog_mixed_size_cond_pattern): Likewise.
12911 (vect_recog_bool_pattern): Likewise.
12912 (vect_recog_mask_conversion_pattern): Likewise.
12913 (vect_try_gather_scatter_pattern): Likewise.
12914 (vect_recog_widen_mult_pattern): Likewise. Check for a null vectype.
12915 (vect_recog_over_widening_pattern): Likewise.
12916 (vect_recog_gather_scatter_pattern): Likewise.
12917 (vect_recog_func_ptr): Move from tree-vectorizer.h
12918 (vect_vect_recog_func_ptrs): Move further down the file.
12919 (vect_recog_func): Likewise. Remove the third argument.
12920 (NUM_PATTERNS): Define based on vect_vect_recog_func_ptrs.
12921 (vect_pattern_recog_1): Expect the pattern function to do any
12922 necessary target tests. Also expect it to provide a vector type.
12923 Remove the type_in handling.
12924
12925 2018-06-20 Richard Sandiford <richard.sandiford@arm.com>
12926
12927 * tree-vect-patterns.c (vect_pattern_detected): New function.
12928 (vect_recog_dot_prod_patternm, vect_recog_sad_pattern)
12929 (vect_recog_widen_mult_pattern, vect_recog_widen_sum_pattern)
12930 (vect_recog_over_widening_pattern, vect_recog_widen_shift_pattern
12931 (vect_recog_rotate_pattern, vect_recog_vector_vector_shift_pattern)
12932 (vect_recog_mult_pattern, vect_recog_divmod_pattern)
12933 (vect_recog_mixed_size_cond_pattern, vect_recog_bool_pattern)
12934 (vect_recog_mask_conversion_pattern)
12935 (vect_try_gather_scatter_pattern): Likewise.
12936
12937 2018-06-20 Richard Sandiford <richard.sandiford@arm.com>
12938
12939 * tree-vect-patterns.c (vect_get_internal_def): New function.
12940 (vect_recog_dot_prod_pattern, vect_recog_sad_pattern)
12941 (vect_recog_vector_vector_shift_pattern, check_bool_pattern)
12942 (search_type_for_mask_1): Use it.
12943
12944 2018-06-20 Richard Sandiford <richard.sandiford@arm.com>
12945
12946 * tree-vect-patterns.c (vect_recog_dot_prod_pattern): Remove
12947 redundant WIDEN_SUM_EXPR handling.
12948 (vect_recog_sad_pattern): Likewise.
12949
12950 2018-06-20 Richard Sandiford <richard.sandiford@arm.com>
12951
12952 * tree-vect-patterns.c (vect_recog_dot_prod_pattern): Remove
12953 redundant check that the types of a PLUS_EXPR or MULT_EXPR agree.
12954 (vect_recog_sad_pattern): Likewise PLUS_EXPR, ABS_EXPR and MINUS_EXPR.
12955 (vect_recog_widen_mult_pattern): Likewise MULT_EXPR.
12956 (vect_recog_widen_sum_pattern): Likewise PLUS_EXPR.
12957
12958 2018-06-20 Richard Sandiford <richard.sandiford@arm.com>
12959
12960 * tree-vect-stmts.c (vectorizable_call): Make sure that we
12961 use the stmt_vec_info of the original bb statement for the
12962 new zero assignment, even if the call is part of a pattern.
12963
12964 2018-06-20 Richard Sandiford <richard.sandiford@arm.com>
12965
12966 * tree-vectorizer.h (_stmt_vec_info): Note above pattern_def_seq
12967 that the sequence is attached to the original statement rather
12968 than the pattern statement.
12969 * tree-vect-loop.c (vect_determine_vf_for_stmt): Take the
12970 PATTERN_DEF_SEQ from the original statement rather than
12971 the main pattern statement.
12972 * tree-vect-stmts.c (free_stmt_vec_info): Likewise.
12973 * tree-vect-patterns.c (vect_recog_dot_prod_pattern): Likewise.
12974 (vect_mark_pattern_stmts): Don't copy the PATTERN_DEF_SEQ.
12975
12976 2018-06-20 Richard Sandiford <richard.sandiford@arm.com>
12977
12978 * tree-vect-stmts.c (vect_analyze_stmt): Move the handling of pattern
12979 definition statements before the early exit for statements that aren't
12980 live or relevant.
12981 * tree-vect-loop.c (vect_transform_loop_stmt): New function,
12982 split out from...
12983 (vect_transform_loop): ...here. Process pattern definition
12984 statements without first checking whether the main pattern
12985 statement is live or relevant.
12986
12987 2018-06-19 Eric Botcazou <ebotcazou@adacore.com>
12988
12989 * tree-cfgcleanup.c (tree_forwarder_block_p): Do not return false at
12990 -O0 if the locus represent UNKNOWN_LOCATION but have different values.
12991
12992 2018-06-19 Aaron Sawdey <acsawdey@linux.ibm.com>
12993
12994 * config/rs6000/rs6000-string.c (select_block_compare_mode): Check
12995 TARGET_EFFICIENT_OVERLAPPING_UNALIGNED here instead of in caller.
12996 (do_and3, do_and3_mask, do_compb3, do_rotl3): New functions.
12997 (expand_block_compare): Change select_block_compare_mode call.
12998 (expand_strncmp_align_check): Use new functions, fix comment.
12999 (emit_final_str_compare_gpr): New function.
13000 (expand_strn_compare): Refactor and clean up code.
13001 * config/rs6000/vsx.md (vsx_mov<mode>_64bit): Remove *.
13002
13003 2018-06-19 Tony Reix <tony.reix@atos.com>
13004 Damien Bergamini <damien.bergamini@atos.com>
13005 David Edelsohn <dje.gcc@gmail.com>
13006
13007 * collect2.c (static_obj): New variable.
13008 (static_libs): New variable.
13009 (is_in_list): Uncomment declaration.
13010 (main): Track AIX libraries linked statically.
13011 (is_in_list): Uncomment definition.
13012 (scan_prog_file): Don't add AIX shared libraries initializer
13013 to constructor list if linking statically.
13014
13015 2018-06-19 Max Filippov <jcmvbkbc@gmail.com>
13016
13017 * config/xtensa/xtensa.md (UNSPEC_FRAME_BLOCKAGE): New unspec
13018 constant.
13019 (allocate_stack, frame_blockage, *frame_blockage): New patterns.
13020
13021 2018-06-19 Jan Hubicka <hubicka@ucw.cz>
13022
13023 * tree.c (find_decls_types_r): Remove all non-VAR_DECLs from
13024 blocks.
13025
13026 2018-06-19 Martin Liska <mliska@suse.cz>
13027
13028 * config/i386/i386.c (ix86_can_inline_p): Do not use
13029 ipa_fn_summaries::get_create.
13030 * ipa-cp.c (ipcp_cloning_candidate_p): Replace get_create with
13031 get.
13032 (devirtualization_time_bonus): Likewise.
13033 (ipcp_propagate_stage): Likewise.
13034 * ipa-fnsummary.c (redirect_to_unreachable): Likewise.
13035 (edge_set_predicate): Likewise.
13036 (evaluate_conditions_for_known_args): Likewise.
13037 (evaluate_properties_for_edge): Likewise.
13038 (ipa_call_summary::reset): Tranform to ...
13039 (ipa_call_summary::~ipa_call_summary): ... this.
13040 (ipa_fn_summary::reset): Transform to ...
13041 (ipa_fn_summary::~ipa_fn_summary): ... this.
13042 (ipa_fn_summary_t::remove): Rename to ...
13043 (ipa_fn_summary_t::remove_callees): ... this.
13044 (ipa_fn_summary_t::duplicate): Use placement new
13045 instead of memory copy.
13046 (ipa_call_summary_t::duplicate): Likewise.
13047 (ipa_call_summary_t::remove): Remove.
13048 (dump_ipa_call_summary): Change get_create to get.
13049 (ipa_dump_fn_summary): Dump only when summary exists.
13050 (analyze_function_body): Use symbol_summary::get instead
13051 of get_create.
13052 (compute_fn_summary): Likewise.
13053 (estimate_edge_devirt_benefit): Likewise.
13054 (estimate_edge_size_and_time): Likewise.
13055 (inline_update_callee_summaries): Likewise.
13056 (remap_edge_change_prob): Likewise.
13057 (remap_edge_summaries): Likewise.
13058 (ipa_merge_fn_summary_after_inlining): Likewise.
13059 (write_ipa_call_summary): Likewise.
13060 (ipa_fn_summary_write): Likewise.
13061 (ipa_free_fn_summary): Likewise.
13062 * ipa-fnsummary.h (struct GTY): Add new ctor and copy ctor.
13063 (struct ipa_call_summary): Likewise.
13064 * ipa-icf.c (sem_function::merge): Use symbol_summary::get instead
13065 of get_create.
13066 * ipa-inline-analysis.c (do_estimate_edge_time): Likewise.
13067 (estimate_size_after_inlining): Likewise.
13068 (estimate_growth): Likewise.
13069 (growth_likely_positive): Likewise.
13070 * ipa-inline-transform.c (clone_inlined_nodes): Likewise.
13071 (inline_call): Likewise.
13072 * ipa-inline.c (caller_growth_limits): Likewise.
13073 (can_inline_edge_p): Likewise.
13074 (can_inline_edge_by_limits_p): Likewise.
13075 (compute_uninlined_call_time): Likewise.
13076 (compute_inlined_call_time): Likewise.
13077 (want_inline_small_function_p): Likewise.
13078 (edge_badness): Likewise.
13079 (update_caller_keys): Likewise.
13080 (update_callee_keys): Likewise.
13081 (inline_small_functions): Likewise.
13082 (inline_to_all_callers_1): Likewise.
13083 (dump_overall_stats): Likewise.
13084 (early_inline_small_functions): Likewise.
13085 (early_inliner): Likewise.
13086 * ipa-profile.c (ipa_propagate_frequency_1): Likewise.
13087 * ipa-prop.c (ipa_make_edge_direct_to_target): Likewise.
13088 * ipa-pure-const.c (malloc_candidate_p): Likewise.
13089 * ipa-split.c (execute_split_functions): Likewise.
13090 * symbol-summary.h: Likewise.
13091 * tree-sra.c (ipa_sra_preliminary_function_checks): Likewise.
13092
13093 2018-06-19 Richard Biener <rguenther@suse.de>
13094
13095 * tree-vectorizer.c (try_vectorize_loop_1): Split out of ...
13096 (vectorize_loops): ... here. Fix dbgcnt handling.
13097 (try_vectorize_loop): Wrap try_vectorize_loop_1.
13098
13099 2018-06-19 Segher Boessenkool <segher@kernel.crashing.org>
13100
13101 PR target/86197
13102 * config/rs6000/rs6000.md (rs6000_discover_homogeneous_aggregate): An
13103 ieee128 argument takes up only one (vector) register, not two (floating
13104 point) registers.
13105
13106 2018-06-19 Eric Botcazou <ebotcazou@adacore.com>
13107
13108 * gimplify.c (gimplify_init_constructor): Really never clear for an
13109 incomplete constructor if CONSTRUCTOR_NO_CLEARING is set.
13110
13111 2018-06-19 Richard Biener <rguenther@suse.de>
13112
13113 PR tree-optimization/86179
13114 * tree-vect-patterns.c (vect_pattern_recog_1): Clean up
13115 after failed recognition.
13116
13117 2018-06-18 Martin Sebor <msebor@redhat.com>
13118
13119 PR middle-end/85602
13120 * calls.c (maybe_warn_nonstring_arg): Handle strncat.
13121 * tree-ssa-strlen.c (is_strlen_related_p): Make extern.
13122 Handle integer subtraction.
13123 (maybe_diag_stxncpy_trunc): Handle nonstring source arguments.
13124 * tree-ssa-strlen.h (is_strlen_related_p): Declare.
13125
13126 2018-06-18 David Malcolm <dmalcolm@redhat.com>
13127
13128 * config/frv/frv-protos.h (frv_ifcvt_modify_insn): Strengthen 3rd
13129 param from rtx to rtx_insn *.
13130 * config/frv/frv.c (frv_ifcvt_add_insn): Likewise for "insn"
13131 param.
13132 (frv_ifcvt_modify_insn): Likwise.
13133 (frv_ifcvt_modify_final): Likwise for local "existing_insn",
13134 adding an as_a <rtx_insn *> cast. Likewise for local "insn".
13135 * config/mips/mips.c (r10k_insert_cache_barriers): Add an
13136 as_a <rtx_insn *> cast to local "unprotected_region" once
13137 it's been established that it's not NULL or pc_rtx.
13138 * config/nds32/nds32-relax-opt.c (nds32_group_insns): Strengthen
13139 param "sethi" from rtx to rtx_insn *.
13140 (nds32_group_float_insns): Likewise for param "insn".
13141 * config/vax/vax-protos.h (vax_output_int_add): Likewise for 1st
13142 param.
13143 (vax_output_int_subtract): Likewise.
13144 * config/vax/vax.c (vax_output_int_add): Likewise for param
13145 "insn".
13146 (vax_output_int_subtract): Likewise.
13147 * emit-rtl.c (set_insn_deleted): Likewise, removing cast.
13148 (emit_pattern_after): Likewise for param "after".
13149 (emit_insn_after): Likewise.
13150 (emit_jump_insn_after): Likewise.
13151 (emit_call_insn_after): Likewise.
13152 (emit_debug_insn_after): Likewise.
13153 (emit_pattern_before): Likewise for param "before".
13154 (emit_insn_before): Likewise.
13155 (emit_jump_insn_before): Likewise.
13156 * final.c (get_insn_template): Likewise for param "insn", removing
13157 a cast.
13158 * output.h (get_insn_template): Likewise for 2nd param.
13159 * rtl.h (emit_insn_before): Likewise.
13160 (emit_jump_insn_before): Likewise.
13161 (emit_debug_insn_before_noloc): Likewise.
13162 (emit_insn_after): Likewise.
13163 (emit_jump_insn_after): Likewise.
13164 (emit_call_insn_after): Likewise.
13165 (emit_debug_insn_after): Likewise.
13166 (set_insn_deleted): Likewise for param.
13167
13168 2018-06-18 Michael Meissner <meissner@linux.ibm.com>
13169
13170 PR target/85358
13171 * config/rs6000/rs6000-modes.def (toplevel): Rework the 128-bit
13172 floating point modes, so that IFmode is numerically greater than
13173 TFmode, which is greater than KFmode using FRACTIONAL_FLOAT_MODE
13174 to declare the ordering. This prevents IFmode from being
13175 converted to TFmode when long double is IEEE 128-bit on an ISA 3.0
13176 machine. Include rs6000-modes.h to share the fractional values
13177 between genmodes* and the rest of the compiler.
13178 (IFmode): Likewise.
13179 (KFmode): Likewise.
13180 (TFmode): Likewise.
13181 * config/rs6000/rs6000-modes.h: New file.
13182 * config/rs6000/rs6000.c (rs6000_debug_reg_global): Change the
13183 meaning of rs6000_long_double_size so that 126..128 selects an
13184 appropriate 128-bit floating point type.
13185 (rs6000_option_override_internal): Likewise.
13186 * config/rs6000/rs6000.h (toplevel): Include rs6000-modes.h.
13187 (TARGET_LONG_DOUBLE_128): Change the meaning of
13188 rs6000_long_double_size so that 126..128 selects an appropriate
13189 128-bit floating point type.
13190 (LONG_DOUBLE_TYPE_SIZE): Update comment.
13191 * config/rs6000/rs6000.md (trunciftf2): Correct the modes of the
13192 source and destination to match the standard usage.
13193 (truncifkf2): Likewise.
13194 (copysign<mode>3, IEEE iterator): Rework copysign of float128 on
13195 ISA 2.07 to use an explicit clobber, instead of passing in a
13196 temporary.
13197 (copysign<mode>3_soft): Likewise.
13198
13199 2018-06-18 David Malcolm <dmalcolm@redhat.com>
13200
13201 * tree-vect-data-refs.c (vect_analyze_data_ref_dependences):
13202 Replace dump_printf_loc call with DUMP_VECT_SCOPE.
13203 (vect_slp_analyze_instance_dependence): Likewise.
13204 (vect_enhance_data_refs_alignment): Likewise.
13205 (vect_analyze_data_refs_alignment): Likewise.
13206 (vect_slp_analyze_and_verify_instance_alignment
13207 (vect_analyze_data_ref_accesses): Likewise.
13208 (vect_prune_runtime_alias_test_list): Likewise.
13209 (vect_analyze_data_refs): Likewise.
13210 * tree-vect-loop-manip.c (vect_update_inits_of_drs): Likewise.
13211 * tree-vect-loop.c (vect_determine_vectorization_factor): Likewise.
13212 (vect_analyze_scalar_cycles_1): Likewise.
13213 (vect_get_loop_niters): Likewise.
13214 (vect_analyze_loop_form_1): Likewise.
13215 (vect_update_vf_for_slp): Likewise.
13216 (vect_analyze_loop_operations): Likewise.
13217 (vect_analyze_loop): Likewise.
13218 (vectorizable_induction): Likewise.
13219 (vect_transform_loop): Likewise.
13220 * tree-vect-patterns.c (vect_pattern_recog): Likewise.
13221 * tree-vect-slp.c (vect_analyze_slp): Likewise.
13222 (vect_make_slp_decision): Likewise.
13223 (vect_detect_hybrid_slp): Likewise.
13224 (vect_slp_analyze_operations): Likewise.
13225 (vect_slp_bb): Likewise.
13226 * tree-vect-stmts.c (vect_mark_stmts_to_be_vectorized): Likewise.
13227 (vectorizable_bswap): Likewise.
13228 (vectorizable_call): Likewise.
13229 (vectorizable_simd_clone_call): Likewise.
13230 (vectorizable_conversion): Likewise.
13231 (vectorizable_assignment): Likewise.
13232 (vectorizable_shift): Likewise.
13233 (vectorizable_operation): Likewise.
13234 * tree-vectorizer.h (DUMP_VECT_SCOPE): New macro.
13235
13236 2018-06-18 Martin Sebor <msebor@redhat.com>
13237
13238 PR tree-optimization/81384
13239 * builtin-types.def (BT_FN_SIZE_CONST_STRING_SIZE): New.
13240 * builtins.c (expand_builtin_strnlen): New function.
13241 (expand_builtin): Call it.
13242 (fold_builtin_n): Avoid setting TREE_NO_WARNING.
13243 * builtins.def (BUILT_IN_STRNLEN): New.
13244 * calls.c (maybe_warn_nonstring_arg): Handle BUILT_IN_STRNLEN.
13245 Warn for bounds in excess of maximum object size.
13246 * tree-ssa-strlen.c (maybe_set_strlen_range): Return tree representing
13247 single-value ranges. Handle strnlen.
13248 (handle_builtin_strlen): Handle strnlen.
13249 (strlen_check_and_optimize_stmt): Same.
13250 * doc/extend.texi (Other Builtins): Document strnlen.
13251
13252 2018-06-18 Maya Rashish <coypu@sdf.org>
13253
13254 * config/alpha/openbsd.h (TARGET_DEFAULT): Define.
13255 (LINK_SPEC, STARTFILE_SPEC, ENDFILE_SPEC): Likewise.
13256 (INTMAX_TYPE, UINTMAX_TYPE, WINT_TYPE): Likewise.
13257
13258 * config/alpha/elf.h (STARTFILE_SPEC, ENDFILE_SPEC): Move from
13259 here to ...
13260 * config/alpha/linux.h (STARTFILE_SPEC, ENDFILE_SPEC): Here.
13261
13262 2018-06-18 Prathamesh Kulkarni <prathamesh.kulkarni@linaro.org>
13263
13264 * tree.c (escaped_string::escape): Replace cast to char * by
13265 const_cast<char *> (unescaped).
13266
13267 2018-06-18 Nick Clifton <nickc@redhat.com>
13268
13269 PR 84195
13270 * tree.c (escaped_string): New class. Converts an unescaped
13271 string into its escaped equivalent.
13272 (warn_deprecated_use): Use the new class to convert the
13273 deprecation message, if present.
13274 (test_escaped_strings): New self test.
13275 (test_c_tests): Add test_escaped_strings.
13276 * doc/extend.texi (deprecated): Add a note that the
13277 deprecation message is affected by the -fmessage-length
13278 option, and that control characters will be escaped.
13279 (#pragma GCC error): Document this pragma.
13280 (#pragma GCC warning): Likewise.
13281 * doc/invoke.texi (-fmessage-length): Document this option's
13282 effect on the #warning and #error preprocessor directives and
13283 the deprecated attribute.
13284
13285 2018-06-18 Eric Botcazou <ebotcazou@adacore.com>
13286
13287 * tree.c (decl_value_expr_lookup): Revert latest change.
13288 (decl_value_expr_insert): Likewise.
13289
13290 2018-06-17 Eric Botcazou <ebotcazou@adacore.com>
13291
13292 * gimplify.c (nonlocal_vlas): Delete.
13293 (nonlocal_vla_vars): Likewise.
13294 (gimplify_var_or_parm_decl): Do not add debug VAR_DECLs for non-local
13295 referenced VLAs.
13296 (gimplify_body): Do not create and destroy nonlocal_vlas.
13297 * tree-nested.c: Include diagnostic.h.
13298 (use_pointer_in_frame): Tweak.
13299 (lookup_field_for_decl): Add assertion and declare the transformation.
13300 (convert_nonlocal_reference_op) <PARM_DECL>: Rework and issue an
13301 internal error when the reference is in a wrong context. Do not
13302 create a debug decl by default.
13303 (note_nonlocal_block_vlas): Delete.
13304 (convert_nonlocal_reference_stmt) <GIMPLE_BIND>: Do not call it.
13305 (convert_local_reference_op) <PARM_DECL>: Skip the frame decl. Do not
13306 create a debug decl by default.
13307 (convert_gimple_call) <GIMPLE_CALL>: Issue an internal error when the
13308 call is in a wrong context.
13309 (fixup_vla_decls): New function.
13310 (finalize_nesting_tree_1): Adjust comment. Call fixup_vla_decls if no
13311 debug variables were created.
13312 * tree.c (decl_value_expr_lookup): Add checking assertion.
13313 (decl_value_expr_insert): Likewise.
13314
13315 2018-06-16 Kugan Vivekanandarajah <kuganv@linaro.org>
13316
13317 PR middle-end/82479
13318 * ipa-fnsummary.c (will_be_nonconstant_expr_predicate): Handle CALL_EXPR.
13319 * tree-scalar-evolution.c (interpret_expr): Likewise.
13320 (expression_expensive_p): Likewise.
13321 * tree-ssa-loop-ivopts.c (contains_abnormal_ssa_name_p): Likewise.
13322 * tree-ssa-loop-niter.c (number_of_iterations_popcount): New.
13323 (number_of_iterations_exit_assumptions): Use number_of_iterations_popcount.
13324 (ssa_defined_by_minus_one_stmt_p): New.
13325
13326 2018-06-16 Kugan Vivekanandarajah <kuganv@linaro.org>
13327
13328 PR middle-end/64946
13329 * cfgexpand.c (expand_debug_expr): Hande ABSU_EXPR.
13330 * config/i386/i386.c (ix86_add_stmt_cost): Likewise.
13331 * dojump.c (do_jump): Likewise.
13332 * expr.c (expand_expr_real_2): Check operand type's sign.
13333 * fold-const.c (const_unop): Handle ABSU_EXPR.
13334 (fold_abs_const): Likewise.
13335 * gimple-pretty-print.c (dump_unary_rhs): Likewise.
13336 * gimple-ssa-backprop.c (backprop::process_assign_use): Likesie.
13337 (strip_sign_op_1): Likesise.
13338 * match.pd: Add new pattern to generate ABSU_EXPR.
13339 * optabs-tree.c (optab_for_tree_code): Handle ABSU_EXPR.
13340 * tree-cfg.c (verify_gimple_assign_unary): Likewise.
13341 * tree-eh.c (operation_could_trap_helper_p): Likewise.
13342 * tree-inline.c (estimate_operator_cost): Likewise.
13343 * tree-pretty-print.c (dump_generic_node): Likewise.
13344 * tree-vect-patterns.c (vect_recog_sad_pattern): Likewise.
13345 * tree.def (ABSU_EXPR): New.
13346
13347 2018-06-16 Jakub Jelinek <jakub@redhat.com>
13348
13349 PR middle-end/86095
13350 * common.opt (Wunsafe-loop-optimizations): Add Ignore, remove Var,
13351 documented as preserved for backward compatibility only.
13352 * doc/invoke.texi: Remove -Wunsafe-loop-optimizations documentation.
13353
13354 PR rtl-optimization/86108
13355 * bb-reorder.c (create_forwarder_block): Renamed to ...
13356 (create_eh_forwarder_block): ... this. Split OLD_BB after labels and
13357 jump from new landing pad to the second part.
13358 (sjlj_fix_up_crossing_landing_pad, dw2_fix_up_crossing_landing_pad):
13359 Adjust callers.
13360
13361 2018-06-15 Jakub Jelinek <jakub@redhat.com>
13362
13363 PR middle-end/85878
13364 * expr.c (expand_assignment): Remove now redundant COMPLEX_MODE_P
13365 check from first store_expr, use to_mode instead of GET_MODE (to_rtx).
13366 Only call store_expr for halves if the mode is the same.
13367
13368 PR middle-end/86123
13369 * match.pd ((X / Y) == 0 -> X < Y): Don't transform complex divisions.
13370 Fix up comment formatting.
13371
13372 2018-06-15 Bernd Edlinger <bernd.edlinger@hotmail.de>
13373
13374 * typed-splay-tree.h (typed_splay_tree::remove): New function.
13375 (typed_splay_tree::closure,
13376 typed_splay_tree::inner_foreach_fn, typed_splay_tree::m_inner): Deleted.
13377 (typed_splay_tree::typed_splay_tree,
13378 typed_splay_tree::operator =): Declared private.
13379 (typed_splay_tree::splay_tree_key, typed_splay_tree::splay_tree_value,
13380 typed_splay_tree::splay_tree_node_s, typed_splay_tree::KDEL,
13381 typed_splay_tree::VDEL, typed_splay_tree::splay_tree_delete_helper,
13382 typed_splay_tree::rotate_left, typed_splay_tree::rotate_right,
13383 typed_splay_tree::splay_tree_splay,
13384 typed_splay_tree::splay_tree_foreach_helper,
13385 typed_splay_tree::splay_tree_insert,
13386 typed_splay_tree::splay_tree_remove,
13387 typed_splay_tree::splay_tree_lookup,
13388 typed_splay_tree::splay_tree_predecessor,
13389 typed_splay_tree::splay_tree_successor,
13390 typed_splay_tree::splay_tree_min,
13391 typed_splay_tree::splay_tree_max): Took over from splay-tree.c/.h.
13392 (typed_splay_tree::root, typed_splay_tree::comp,
13393 typed_splay_tree::delete_key,
13394 typed_splay_tree::delete_value): New data members.
13395 * typed-splay-tree.c (selftest::test_str_to_int): Add a test for
13396 typed_splay_tree::remove.
13397
13398 2018-06-15 Matthew Fortune <matthew.fortune@mips.com>
13399
13400 * config/mips/mips.h (ASM_SPEC): Pass through -mcrc, -mno-crc,
13401 -mginv and -mno-ginv to the assembler.
13402 * config/mips/mips.opt (-mcrc): New option.
13403 (-mginv): Likewise.
13404 * doc/invoke.text (-mcrc): Document.
13405 (-mginv): Likewise.
13406
13407 2018-06-15 Nick Clifton <nickc@redhat.com>
13408
13409 PR 84195
13410 * tree.c (escaped_string): New class. Converts an unescaped
13411 string into its escaped equivalent.
13412 (warn_deprecated_use): Use the new class to convert the
13413 deprecation message, if present.
13414 (test_escaped_strings): New self test.
13415 (test_c_tests): Add test_escaped_strings.
13416 * doc/extend.texi (deprecated): Add a note that the
13417 deprecation message is affected by the -fmessage-length
13418 option, and that control characters will be escaped.
13419 (#pragma GCC error): Document this pragma.
13420 (#pragma GCC warning): Likewise.
13421 * doc/invoke.texi (-fmessage-length): Document this option's
13422 effect on the #warning and #error preprocessor directives and
13423 the deprecated attribute.
13424
13425 2018-06-15 Richard Biener <rguenther@suse.de>
13426
13427 * tree-vect-slp.c (vect_slp_bb): Dump MSG_OPTIMIZED_LOCATIONS
13428 here, also noting vector size used.
13429 * tree-vectorizer.c (vectorize_loops): Adjust. Note vector
13430 size used in MSG_OPTIMIZED_LOCATIONS dump.
13431 (pass_slp_vectorize::execute): Adjust.
13432
13433 2018-06-15 Claudiu Zissulescu <claziss@synopsys.com>
13434
13435 PR target/85968
13436 * config/arc/arc.c (arc_return_address_register): Fix
13437 if-condition.
13438
13439 2018-06-15 Richard Biener <rguenther@suse.de>
13440
13441 PR middle-end/86159
13442 * tree-cfg.c (gimplify_build3): Do not strip sign conversions,
13443 leave useless conversion stripping to force_gimple_operand_gsi.
13444 (gimplify_build2): Likewise.
13445 (gimplify_build1): Likewise.
13446
13447 2018-06-15 Richard Biener <rguenther@suse.de>
13448
13449 PR middle-end/86076
13450 * tree-cfg.c (move_stmt_op): unshare invariant addresses
13451 before adjusting their block.
13452
13453 2018-06-15 Sebastian Huber <sebastian.huber@embedded-brains.de>
13454
13455 * config.gcc (riscv*-*-elf* | riscv*-*-rtems*): Use custom
13456 multilibs for *-*-rtems*.
13457 * config/riscv/t-rtems: New file.
13458
13459 2018-06-14 Jakub Jelinek <jakub@redhat.com>
13460
13461 PR middle-end/86122
13462 * match.pd ((A +- CST1) +- CST2): Punt if last resort
13463 unsigned_type_for returns NULL.
13464
13465 PR target/85945
13466 * lower-subreg.c (find_decomposable_subregs): Don't decompose float
13467 subregs of multi-word pseudos unless the float mode has word size.
13468
13469 2018-06-14 Richard Biener <rguenther@suse.de>
13470
13471 PR middle-end/86139
13472 * tree-vect-generic.c (build_word_mode_vector_type): Remove
13473 duplicate and harmful type_hash_canon.
13474 * tree.c (type_hash_canon): Assert we didn't find ourselves.
13475
13476 2018-06-14 Richard Biener <rguenther@suse.de>
13477
13478 PR ipa/86124
13479 * tree-ssa-struct-alias.c (create_variable_info_for): Handle
13480 NULL cgraph_node.
13481
13482 2018-06-14 Sebastian Huber <sebastian.huber@embedded-brains.de>
13483
13484 * config/rtems.h (STDINT_LONG32): Define.
13485
13486 2018-06-13 Matthew Fortune <matthew.fortune@mips.com>
13487 Prachi Godbole <prachi.godbole@imgtec.com>
13488
13489 * config/mips/mips-cpus.def: Define P6600.
13490 * config/mips/mips-tables.opt: Regenerate.
13491 * config/mips/mips.c (mips_ucbranch_type): New enum.
13492 (mips_rtx_cost_data): Add support for P6600.
13493 (mips_issue_rate): Likewise.
13494 (mips_multipass_dfa_lookahead): Likewise.
13495 (mips_avoid_hazard): Likewise.
13496 (mips_reorg_process_insns): Likewise.
13497 (mips_classify_branch_p6600): New function.
13498 * config/mips/mips.h (TUNE_P6600): New define.
13499 (MIPS_ISA_LEVEL_SPEC): Infer mips64r6 from p6600.
13500 (ENABLE_LD_ST_PAIRS): Enable load/store bonding for p6600.
13501 * config/mips/mips.md: Include p6600.md.
13502 (processor): Add p6600.
13503 * config/mips/p6600.md: New file.
13504 * doc/invoke.texi: Add p6600 to supported architectures.
13505
13506 2018-06-13 Martin Sebor <msebor@redhat.com>
13507
13508 PR tree-optimization/86114
13509 * gimple-fold.c (gimple_fold_builtin_strlen): Only handle LHS
13510 of integer types.
13511 * tree-ssa-strlen.c (maybe_set_strlen_range): Same.
13512
13513 2018-06-13 Richard Biener <rguenther@suse.de>
13514
13515 * tree-vect-patterns.c (vect_recog_vector_vector_shift_pattern):
13516 Properly set vector type of the intermediate stmt.
13517 * tree-vect-stmts.c (vectorizable_operation): The destination
13518 var always has vectype_out type.
13519
13520 2018-06-13 Jeff Law <law@redhat.com>
13521
13522 * config/rl78/rl78.c (move_elim_pass): Use TDF_NONE rather than
13523 integer 0 for argument to print_rtl_with_bb.
13524 (rl78_reorg): Likewise.
13525
13526 2018-06-13 David Malcolm <dmalcolm@redhat.com>
13527
13528 * config/arc/arc.c (hwloop_optimize): Strengthen local "end_label"
13529 from rtx to rtx_insn *.
13530 * config/bfin/bfin.c (hwloop_optimize): Likewise for local
13531 "label".
13532 (add_sched_insns_for_speculation): Likewise for local "target",
13533 converting usage of JUMP_LABEL to JUMP_LABEL_AS_INSN.
13534 * config/c6x/c6x.c (reorg_split_calls): Strengthen param "call_labels"
13535 from rtx_insn ** to rtx_code_label **.
13536 (reorg_emit_nops): Likewise.
13537 (c6x_reorg): Likewise for local "call_labels".
13538 * config/sh/sh-protos.h (get_dest_uid): Strengthen 1st param from
13539 rtx to rtx_insn *.
13540 * config/sh/sh.c (dump_table): Strengthen local "lab" from rtx to
13541 rtx_code_label *, adding safe_as_a <rtx_code_label *> casts to
13542 the loops over LABEL_REFS.
13543 (fixup_addr_diff_vecs): Add as_a <rtx_insn *> to usage of
13544 braf_label.
13545 (barrier_align): Convert usage of JUMP_LABEL to JUMP_LABEL_AS_INSN.
13546 (get_dest_uid): Strengthen param "label" from rtx to rtx_insn *.
13547 (split_branches): Strengthen local "olabel" from rtx to
13548 rtx_insn *, adding a safe_as_a cast.
13549 * emit-rtl.c (next_real_insn): Strengthen param from "rtx"
13550 to "rtx_insn *".
13551 (add_insn_after): Likewise for first two params.
13552 (add_insn_before): Likewise.
13553 (remove_insn): Likewise for param.
13554 (emit_pattern_before_noloc): Likewise for second and third params.
13555 (emit_jump_insn_before_noloc): Convert NULL_RTX to NULL.
13556 (emit_call_insn_before_noloc): Likewise.
13557 (emit_debug_insn_before_noloc): Strengthen "before" param from "rtx"
13558 to "rtx_insn *".
13559 (emit_barrier_before): Likewise.
13560 (emit_label_before): Strengthen "label" param from "rtx" to
13561 "rtx_code_label *". Strengthen "before" param from "rtx" to
13562 "rtx_insn *".
13563 (emit_insn_after_1): Strengthen "after" param from "rtx" to
13564 "rtx_insn *".
13565 (emit_pattern_after_noloc): Likewise.
13566 (emit_insn_after_noloc): Likewise.
13567 (emit_jump_insn_after_noloc): Likewise.
13568 (emit_call_insn_after_noloc): Likewise.
13569 (emit_debug_insn_after_noloc): Likewise.
13570 (emit_barrier_after): Likewise.
13571 (emit_label_after): Likewise for both params.
13572 (emit_pattern_after_setloc): Likewise for "after" param. Convert
13573 "loc" param from "int" to "location_t".
13574 (emit_insn_after_setloc): Likewise.
13575 (emit_jump_insn_after_setloc): Likewise.
13576 (emit_call_insn_after_setloc): Likewise.
13577 (emit_debug_insn_after_setloc): Likewise.
13578 (emit_pattern_before_setloc): Likewise for "before" param. Convert
13579 "loc" param from "int" to "location_t".
13580 (emit_pattern_before): Convert NULL_RTX to NULL.
13581 (emit_insn_before_setloc): Convert "loc" param from "int" to
13582 "location_t".
13583 (emit_jump_insn_before_setloc): Likewise.
13584 (emit_call_insn_before_setloc): Likewise.
13585 (emit_debug_insn_before_setloc): Strengthen "before" param from rtx to
13586 rtx_insn *. Convert "loc" param from "int" to "location_t".
13587 * rtl.h (emit_insn_before_setloc, emit_jump_insn_before_setloc,
13588 emit_call_insn_before_setloc, emit_debug_insn_before_setloc):
13589 Convert 3rd param from "int" to "location_t".
13590 (emit_barrier_before, emit_barrier_after, next_real_insn):
13591 Strengthen param from rtx to rtx_insn *.
13592 (emit_label_before): Strengthen 1st param from "rtx" to
13593 "rtx_code_label *". Strengthen 2nd param from "rtx" to
13594 "rtx_insn *".
13595 (emit_insn_after_noloc, emit_jump_insn_after_noloc,
13596 emit_call_insn_after_noloc, emit_debug_insn_after_noloc):
13597 Strengthen 2nd param from "rtx" to "rtx_insn *".
13598 (emit_insn_after_setloc, emit_jump_insn_after_setloc)
13599 emit_call_insn_after_setloc, emit_debug_insn_after_setloc):
13600 Likewise. Convert 3rd param from "int" to "location_t".
13601 (emit_label_after): Strengthen 1st param from "rtx" to
13602 "rtx_code_label *".
13603 (next_real_insn, remove_insn): Strengthen param from "rtx" to
13604 "rtx_insn *".
13605 (add_insn_before, add_insn_after): Strengthen 1st and 2nd params
13606 from "rtx" to "rtx_insn *".
13607
13608 2018-06-13 Jan Hubicka <hubicka@gcc.gnu.org>
13609
13610 * cgraph.c (cgraph_node::get_untransformed_body): Dump function
13611 bodies streamed in with -Q.
13612 * dumpfile.c (dump_files): Add lto-stream-out dump file.
13613 * dumpfile.h (tree_dump_index): Add lto_stream_out.
13614 * gimple-streamer-out.c: Include gimple-pretty-print.h
13615 (output_bb): Dump stmts streamed.
13616 * lto-section-out.c: Include print-tree.h
13617 (lto_begin_section): Dump sections created.
13618 (lto_output_decl_index): Dump decl encoded.
13619 * lto-streamer-out.c: Include print-tree.h
13620 (create_output_block): Dump output block created.
13621 (DFS::DFS_write_tree_body): Dump DFS SCCs streamed.
13622 (output_function): Dump function output.
13623 (output_constructor): Dump constructor streamed.
13624 (write_global_stream): Output indexes encoded.
13625 (produce_asm_for_decls): Dump streams encoded.
13626 * lto-streamer.c (streamer_dump_file): New global var.
13627 * lto-streamer.h (streamer_dump_file): Declare.
13628 * passes.c (ipa_write_summaries): Initialize streamer dump.
13629 * varpool.c (varpool_node::get_constructor): Dump constructors streamed
13630 in.
13631
13632 2018-06-13 Eric Botcazou <ebotcazou@adacore.com>
13633
13634 PR target/86048
13635 * config/i386/winnt.c (i386_pe_seh_cold_init): Do not emit negative
13636 offsets for register save directives. Emit a second batch of save
13637 directives, if need be, when the function accesses prior frames.
13638
13639 2018-06-12 Claudiu Zissulescu <claziss@synopsys.com>
13640
13641 * config/arc/fpu.md (fmasf4): Force operand to register.
13642 (fnmasf4): Likewise.
13643
13644 2018-06-12 Claudiu Zissulescu <claziss@synopsys.com>
13645
13646 * config/arc/arc-protos.h (arc_pad_return): Remove.
13647 * config/arc/arc.c (machine_function): Remove force_short_suffix
13648 and size_reason.
13649 (arc_print_operand): Adjust printing of '&'.
13650 (arc_verify_short): Remove conditional printing of short suffix.
13651 (arc_final_prescan_insn): Remove reference to size_reason.
13652 (pad_return): New function.
13653 (arc_reorg): Call pad_return.
13654 (arc_pad_return): Remove.
13655 (arc_init_machine_status): Remove reference to force_short_suffix.
13656 * config/arc/arc.md (vunspec): Add VUNSPEC_ARC_BLOCKAGE.
13657 (attr length): When attribute iscompact is true force to 2
13658 regardless; in the case of maybe check if we want to force the
13659 instruction to have 4 bytes length.
13660 (nopv): Change it to generate 4 byte long nop as well.
13661 (blockage): New pattern.
13662 (simple_return): Remove call to arc_pad_return.
13663 (p_return_i): Likewise.
13664
13665 2018-06-12 Claudiu Zissulescu <claziss@synopsys.com>
13666
13667 * config/arc/elf.h (LINK_GCC_C_SEQUENCE_SPEC): Define.
13668
13669 2018-06-12 Claudiu Zissulescu <claziss@synopsys.com>
13670
13671 * config/arc/builtins.def (SYNC): SYNC instruction is valid on all
13672 ARC cores.
13673
13674 2018-06-12 Claudiu Zissulescu <claziss@synopsys.com>
13675
13676 * config/arc/arc.c (atomic_exchangesi): EX instruction is default
13677 for ARC700 and ARCv2.
13678
13679 2018-06-13 Chenghua Xu <paul.hua.gm@gmail.com>
13680
13681 PR target/86076
13682 * config/mips/loongson.md (vec_setv4hi): Gen_lowpart for
13683 operands[2] instead of operands[1].
13684
13685
13686 2018-06-12 Richard Sandiford <richard.sandiford@linaro.org>
13687
13688 * lra-constraints.c (simplify_operand_subreg): In the paradoxical
13689 case, check whether the outer register overlaps an unallocatable
13690 register, not just whether it fits the required class.
13691
13692 2018-06-12 Richard Sandiford <richard.sandiford@linaro.org>
13693
13694 * poly-int.h (can_div_trunc_p): Add new overload in which all values
13695 are poly_ints.
13696 * alias.c (get_addr): Extend CONST_INT handling to poly_int_rtx_p.
13697 (memrefs_conflict_p): Likewise.
13698 (init_alias_analysis): Likewise.
13699 * cfgexpand.c (expand_debug_expr): Likewise.
13700 * combine.c (combine_simplify_rtx, force_int_to_mode): Likewise.
13701 * cse.c (fold_rtx): Likewise.
13702 * explow.c (adjust_stack, anti_adjust_stack): Likewise.
13703 * expr.c (emit_block_move_hints): Likewise.
13704 (clear_storage_hints, push_block, emit_push_insn): Likewise.
13705 (store_expr_with_bounds, reduce_to_bit_field_precision): Likewise.
13706 (emit_group_load_1): Use rtx_to_poly_int64 for group offsets.
13707 (emit_group_store): Likewise.
13708 (find_args_size_adjust): Use strip_offset. Use rtx_to_poly_int64
13709 to read the PRE/POST_MODIFY increment.
13710 * calls.c (store_one_arg): Use strip_offset.
13711 * rtlanal.c (rtx_addr_can_trap_p_1): Extend CONST_INT handling to
13712 poly_int_rtx_p.
13713 (set_noop_p): Use rtx_to_poly_int64 for the elements selected
13714 by a VEC_SELECT.
13715 * simplify-rtx.c (avoid_constant_pool_reference): Use strip_offset.
13716 (simplify_binary_operation_1): Extend CONST_INT handling to
13717 poly_int_rtx_p.
13718 * var-tracking.c (compute_cfa_pointer): Take a poly_int64 rather
13719 than a HOST_WIDE_INT.
13720 (hard_frame_pointer_adjustment): Change from HOST_WIDE_INT to
13721 poly_int64.
13722 (adjust_mems, add_stores): Update accodingly.
13723 (vt_canonicalize_addr): Track polynomial offsets.
13724 (emit_note_insn_var_location): Likewise.
13725 (vt_add_function_parameter): Likewise.
13726 (vt_initialize): Likewise.
13727
13728 2018-06-12 Jeff Law <law@redhat.com>
13729
13730 * config.gcc (alpha*-*-freebsd*): Remove.
13731 * config/alpha/freebsd.h: Remove.
13732
13733 2018-06-12 David Malcolm <dmalcolm@redhat.com>
13734
13735 PR other/69968
13736 * spellcheck-tree.c (levenshtein_distance): Rename to...
13737 (get_edit_distance): ...this, and update for underlying renaming.
13738 * spellcheck-tree.h (levenshtein_distance): Rename to...
13739 (get_edit_distance): ...this.
13740 * spellcheck.c (levenshtein_distance): Rename to...
13741 (get_edit_distance): ...this. Convert from Levenshtein distance
13742 to Damerau-Levenshtein distance by supporting transpositions of
13743 adjacent characters. Rename "v1" to "v_next" and "v0" to
13744 "v_one_ago".
13745 (selftest::levenshtein_distance_unit_test_oneway): Rename to...
13746 (selftest::test_edit_distance_unit_test_oneway): ...this, and
13747 update for underlying renaming.
13748 (selftest::levenshtein_distance_unit_test): Rename to...
13749 (selftest::test_get_edit_distance_unit): ...this, and update for
13750 underlying renaming.
13751 (selftest::test_find_closest_string): Add example from PR 69968
13752 where transposition helps
13753 (selftest::test_metric_conditions): Update for renaming.
13754 (selftest::test_metric_conditions): Likewise.
13755 (selftest::spellcheck_c_tests): Likewise.
13756 * spellcheck.h (levenshtein_distance): Rename both overloads to...
13757 (get_edit_distance): ...this.
13758 (best_match::consider): Update for renaming.
13759
13760 2018-06-12 Martin Sebor <msebor@redhat.com>
13761
13762 PR tree-optimization/85259
13763 * builtins.c (compute_objsize): Handle constant offsets.
13764 * gimple-ssa-warn-restrict.c (maybe_diag_offset_bounds): Return
13765 true iff a warning has been issued.
13766 * gimple.h (gimple_nonartificial_location): New function.
13767 * tree-ssa-strlen.c (maybe_diag_stxncpy_trunc): Call
13768 gimple_nonartificial_location and handle -Wno-system-headers.
13769 (handle_builtin_stxncpy): Same.
13770
13771 2018-06-12 Martin Sebor <msebor@redhat.com>
13772
13773 PR c/85931
13774 * fold-const.c (operand_equal_p): Handle SAVE_EXPR.
13775
13776 2018-06-12 Will Schmidt <will_schmidt@vnet.ibm.com>
13777
13778 * config/rs6000/rs6000-c.c (altivec_overloaded_builtins): Add
13779 BUILTIN_VEC_XST entries for pointer to double and long long.
13780
13781 2018-06-12 H.J. Lu <hongjiu.lu@intel.com>
13782
13783 PR target/85990
13784 * config/i386/gnu-user.h (TARGET_THREAD_SPLIT_STACK_OFFSET):
13785 Update comments.
13786 * config/i386/gnu-user64.h (TARGET_THREAD_SPLIT_STACK_OFFSET):
13787 Likewise.
13788
13789 2018-06-12 Martin Liska <mliska@suse.cz>
13790
13791 * doc/options.texi: Document IntegerRange.
13792
13793 2018-06-12 Martin Liska <mliska@suse.cz>
13794
13795 * config/i386/i386.opt: Make MPX-related options as Deprecated.
13796 * opt-functions.awk: Handle Deprecated flag.
13797 * opts-common.c (decode_cmdline_option): Handle cl_deprecated
13798 and report error.
13799 (read_cmdline_option): Report warning for a deprecated option.
13800 * opts.h (struct cl_option): Add new field cl_deprecated.
13801 (CL_ERR_DEPRECATED): New.
13802
13803 2018-06-12 Martin Liska <mliska@suse.cz>
13804
13805 * doc/options.texi: Document Deprecated option flag.
13806
13807 2018-06-12 Claudiu Zissulescu <claziss@synopsys.com>
13808
13809 * config/arc/arc-arch.h (arc_extras): New enum.
13810 (arc_cpu_t):Add field extra.
13811 (arc_cpu_types): Consider the extras.
13812 * config/arc/arc-cpus.def: Add extras info.
13813 * config/arc/arc-opts.h (processor_type): Consider extra field.
13814 * config/arc/arc.c (arc_override_options): Handle extra field.
13815
13816 2018-06-12 Claudiu Zissulescu <claziss@synopsys.com>
13817
13818 * config/arc/arc-arch.h: Update ARC_OPTX macro.
13819 * config/arc/arc-options.def (ARC_OPTX): Introduce a new doc
13820 field.
13821 * config/arc/arc.c (arc_init): Update pic warning.
13822 (irq_range): Update irq range parsing warnings.
13823 (arc_override_options): Update various warning messages.
13824 (arc_handle_aux_attribute): Likewise.
13825
13826 2018-06-12 Robert Suchanek <robert.suchanek@mips.com>
13827
13828 * config/mips/i6400.md (i6400_fpu_fadd): Remove frint.
13829
13830 2018-06-12 Jozef Lawrynowicz <jozef.l@mittosystems.com>
13831
13832 * doc/sourcebuild.texi: Document usage of line number 0 in verify
13833 compiler messages directives.
13834
13835 2018-06-12 Matthew Fortune <mfortune@gmail.com>
13836
13837 * config/mips/mips-cpus.def: New MIPS_CPU for i6500.
13838 * config/mips/mips-tables.opt: Regenerate.
13839 * config/mips/mips.h (MIPS_ISA_LEVEL_SPEC): Mark i6500 as
13840 mips64r6.
13841 * doc/invoke.texi: Document -march=i6500.
13842
13843 2018-06-12 Prachi Godbole <prachi.godbole@imgtec.com>
13844
13845 * config/mips/i6400.md (i6400_gpmuldiv): Remove cpu_unit.
13846 (i6400_gpmul): Add cpu_unit.
13847 (i6400_gpdiv): Likewise.
13848 (i6400_msa_add_d): Update reservations.
13849 (i6400_msa_int_add) Likewise.
13850 (i6400_msa_short_logic3) Likewise.
13851 (i6400_msa_short_logic2) Likewise.
13852 (i6400_msa_short_logic) Likewise.
13853 (i6400_msa_move) Likewise.
13854 (i6400_msa_cmp) Likewise.
13855 (i6400_msa_short_float2) Likewise.
13856 (i6400_msa_div_d) Likewise.
13857 (i6400_msa_long_logic1) Likewise.
13858 (i6400_msa_long_logic2) Likewise.
13859 (i6400_msa_mult) Likewise.
13860 (i6400_msa_long_float2) Likewise.
13861 (i6400_msa_long_float4) Likewise.
13862 (i6400_msa_long_float5) Likewise.
13863 (i6400_msa_long_float8) Likewise.
13864 (i6400_fpu_fadd): Include frint type.
13865 (i6400_fpu_store): New define_insn_reservation.
13866 (i6400_fpu_load): Likewise.
13867 (i6400_fpu_move): Likewise.
13868 (i6400_fpu_fcmp): Likewise.
13869 (i6400_fpu_fmadd): Likewise.
13870 (i6400_int_mult): Include imul3nc type and update reservation.
13871 (i6400_int_div): Include idiv3 type and update reservation.
13872 (i6400_int_load): Update to check type not move_type.
13873 (i6400_int_store): Likewise.
13874 (i6400_int_prefetch): Set zero latency.
13875
13876 2018-06-12 Eric Botcazou <ebotcazou@adacore.com>
13877
13878 * gcc.c: Document new %@{...} sequence.
13879 (LINK_COMMAND_SPEC): Use it for the -L switches.
13880 (cpp_unique_options): Use it for the -I switches.
13881 (at_file_argbuf): New global variable.
13882 (in_at_file): Likewise.
13883 (alloc_args): Create at_file_argbuf.
13884 (clear_args): Truncate at_file_argbuf.
13885 (store_arg): If in_at_file, push the argument onto at_file_argbuf.
13886 (open_at_file): New function.
13887 (close_at_file): Likewise.
13888 (create_at_file): Delete.
13889 (do_spec_1) <'i'>: Use open_at_file/close_at_file.
13890 <'o'>: Likewise.
13891 <'@'>: New case.
13892 (validate_switches_from_spec): Deal with %@{...} sequence.
13893 (validate_switches): Likewise.
13894 (driver::finalize): Call clear_args.
13895
13896 2018-06-11 Rasmus Villemoes <rasmus.villemoes@prevas.dk>
13897
13898 * config/vx-common.h (USE_TM_CLONE_REGISTRY): #define to 0.
13899
13900 2018-06-11 Martin Sebor <msebor@redhat.com>
13901
13902 * doc/invoke.texi (-Wall): List -Wc++17-compat.
13903 (Wno-class-memaccess): Add @opindex.
13904 (Wno-templates, Wno-multiple-inheritance): Same.
13905 (Wno-virtual-inheritance, Wno-namespaces): Same.
13906 (Wno-pedantic, Wno-chkp, Wcoverage-mismatch): Same.
13907 (Wno-format-overflow, Wno-format-truncation): Same.
13908 (Wno-unused-local-typedefs, Walloc-size-larger-than): Same.
13909 (Wno-alloc-size-larger-than, Wframe-larger-than): Same
13910 (Wno-stack-usage, Wno-c++-compat, Wno-c++11-compat): Same.
13911 (Wno-c++14-compat, Wno-c++17-compat, Wno-openmp-simd): Same.
13912 (Wno-unsuffixed-float-constants, Wno-addr-space-convert): Same.
13913 (Wno-misspelled-isr): Same.
13914
13915 2018-06-11 Martin Sebor <msebor@redhat.com>
13916
13917 * PR tree-optimization/86083
13918 * tree-ssa-strlen.c (handle_char_store): Use tree_expr_nonzero_p.
13919
13920 2018-06-11 Zhouyi Zhou <zhouzhouyi@gmail.com>
13921
13922 * tree-eh.c (lower_eh_constructs_2): Add a comma to comment.
13923
13924 2018-06-11 Segher Boessenkool <segher@kernel.crashing.org>
13925
13926 PR target/85755
13927 * config/rs6000/rs6000.md (*movdi_internal32): Put constraint modifiers
13928 on the correct operand.
13929 (*movdi_internal64): Ditto.
13930
13931 2018-06-11 Martin Liska <mliska@suse.cz>
13932
13933 PR tree-optimization/86089
13934 * tree-ssa-strlen.c (get_string_length): Move back removed hunk.
13935
13936 2018-06-11 Julia Koval <julia.koval@intel.com>
13937
13938 * config/i386/vaesintrin.h (_mm_aesdec_epi128, _mm_aesdeclast_epi128)
13939 _mm_aesenc_epi128, _mm_aesenclast_epi128: Remove.
13940 * config/i386/vpclmulqdqintrin.h (_mm_clmulepi64_epi128): Remove.
13941
13942 2018-06-11 Olivier Hainque <hainque@adacore.com>
13943
13944 * dwarf2out.c (gen_compile_unit_die): Fallout to DW_LANG_Ada83
13945 for Ada with strict dwarf2.
13946
13947 2018-06-08 Peter Bergner <bergner@vnet.ibm.com>
13948
13949 PR target/85755
13950 * config/rs6000/rs6000.c (mem_operand_gpr): Enable PRE_INC and PRE_DEC
13951 addresses.
13952
13953 2018-06-08 Jan Hubicka <hubicka@ucw.cz>
13954
13955 * dumpfile.c (FIRST_ME_AUTO_NUMBERED_DUMP): Bump to 4.
13956
13957 2018-06-08 David Edelsohn <dje.gcc@gmail.com>
13958
13959 * config/rs6000/rs6000.c (rs6000_passes_ieee128): Protect with #if
13960 TARGET_ELF.
13961
13962 2018-06-08 Martin Liska <mliska@suse.cz>
13963
13964 * tree-cfg.h (debug_function): Fix argument type to match
13965 implementation.
13966
13967 2018-06-08 Martin Liska <mliska@suse.cz>
13968
13969 * config/powerpcspe/powerpcspe.c (rs6000_xcoff_visibility):
13970 Remove usage of MPX-related (and removed) fields.
13971 * config/rs6000/rs6000.c (rs6000_xcoff_visibility): Likewise.
13972
13973 2018-06-08 David Malcolm <dmalcolm@redhat.com>
13974
13975 * cfg.c (debug): Use TDF_NONE rather than 0.
13976 * cfghooks.c (debug): Likewise.
13977 * dumpfile.c (DUMP_FILE_INFO): Likewise; also for OPTGROUP.
13978 (struct dump_option_value_info): Convert to...
13979 (struct kv_pair): ...this template type.
13980 (dump_options): Convert to kv_pair<dump_flags_t>; use TDF_NONE
13981 rather than 0.
13982 (optinfo_verbosity_options): Likewise.
13983 (optgroup_options): Convert to kv_pair<optgroup_flags_t>; use
13984 OPTGROUP_NONE.
13985 (gcc::dump_manager::dump_register): Use optgroup_flags_t rather
13986 than int for "optgroup_flags" param.
13987 (dump_generic_expr_loc): Use dump_flags_t rather than int for
13988 "dump_kind" param.
13989 (dump_dec): Likewise.
13990 (dump_finish): Use TDF_NONE rather than 0.
13991 (gcc::dump_manager::opt_info_enable_passes): Use optgroup_flags_t
13992 rather than int for "optgroup_flags" param. Use TDF_NONE rather
13993 than 0. Update for change to option_ptr.
13994 (opt_info_switch_p_1): Convert "optgroup_flags" param from int *
13995 to optgroup_flags_t *. Use TDF_NONE and OPTGROUP_NONE rather than
13996 0. Update for changes to optinfo_verbosity_options and
13997 optgroup_options.
13998 (opt_info_switch_p): Convert optgroup_flags from int to
13999 optgroup_flags_t.
14000 (dump_basic_block): Use dump_flags_t rather than int
14001 for "dump_kind" param.
14002 * dumpfile.h (TDF_ADDRESS, TDF_SLIM, TDF_RAW, TDF_DETAILS,
14003 TDF_STATS, TDF_BLOCKS, TDF_VOPS, TDF_LINENO, TDF_UID)
14004 TDF_STMTADDR, TDF_GRAPH, TDF_MEMSYMS, TDF_RHS_ONLY, TDF_ASMNAME,
14005 TDF_EH, TDF_NOUID, TDF_ALIAS, TDF_ENUMERATE_LOCALS, TDF_CSELIB,
14006 TDF_SCEV, TDF_GIMPLE, TDF_FOLDING, MSG_OPTIMIZED_LOCATIONS,
14007 MSG_MISSED_OPTIMIZATION, MSG_NOTE, MSG_ALL, TDF_COMPARE_DEBUG,
14008 TDF_NONE): Convert from macros to...
14009 (enum dump_flag): ...this new enum.
14010 (dump_flags_t): Update to use enum.
14011 (operator|, operator&, operator~, operator|=, operator&=):
14012 Implement for dump_flags_t.
14013 (OPTGROUP_NONE, OPTGROUP_IPA, OPTGROUP_LOOP, OPTGROUP_INLINE,
14014 OPTGROUP_OMP, OPTGROUP_VEC, OPTGROUP_OTHER, OPTGROUP_ALL):
14015 Convert from macros to...
14016 (enum optgroup_flag): ...this new enum.
14017 (optgroup_flags_t): New typedef.
14018 (operator|, operator|=): Implement for optgroup_flags_t.
14019 (struct dump_file_info): Convert field "alt_flags" to
14020 dump_flags_t. Convert field "optgroup_flags" to
14021 optgroup_flags_t.
14022 (dump_basic_block): Use dump_flags_t rather than int for param.
14023 (dump_generic_expr_loc): Likewise.
14024 (dump_dec): Likewise.
14025 (dump_register): Convert param "optgroup_flags" to
14026 optgroup_flags_t.
14027 (opt_info_enable_passes): Likewise.
14028 * early-remat.c (early_remat::dump_edge_list): Use TDF_NONE rather
14029 than 0.
14030 * gimple-pretty-print.c (debug): Likewise.
14031 * gimple-ssa-store-merging.c (bswap_replace): Likewise.
14032 (merged_store_group::apply_stores): Likewise.
14033 * gimple-ssa-strength-reduction.c (insert_initializers): Likewise.
14034 * gimple.c (verify_gimple_pp): Likewise.
14035 * graphite-poly.c (print_pbb_body): Likewise.
14036 * passes.c (pass_manager::register_one_dump_file): Convert
14037 local "optgroup_flags" to optgroup_flags_t.
14038 * print-tree.c (print_node): Use TDF_NONE rather than 0.
14039 (debug): Likewise.
14040 (debug_body): Likewise.
14041 * tree-pass.h (struct pass_data): Convert field "optgroup_flags"
14042 to optgroup_flags_t.
14043 * tree-pretty-print.c (print_struct_decl): Use TDF_NONE rather
14044 than 0.
14045 * tree-ssa-math-opts.c (convert_mult_to_fma_1): Likewise.
14046 (convert_mult_to_fma): Likewise.
14047 * tree-ssa-reassoc.c (undistribute_ops_list): Likewise.
14048 * tree-ssa-sccvn.c (vn_eliminate): Likewise.
14049 * tree-vect-data-refs.c (dump_lower_bound): Convert param
14050 "dump_kind" to dump_flags_t.
14051
14052 2018-06-08 Segher Boessenkool <segher@kernel.crashing.org>
14053
14054 * config/rs6000/rs6000.c (min, max): Delete.
14055
14056 2018-06-08 Segher Boessenkool <segher@kernel.crashing.org>
14057
14058 * doc/invoke.texi (RS/6000 and PowerPC Options): Delete mention of
14059 -mabi=spe and -mabi=no-spe.
14060
14061 2018-06-08 Martin Liska <mliska@suse.cz>
14062
14063 * ipa-pure-const.c (propagate_pure_const): Use ::get at places
14064 where we expect an existing summary.
14065
14066 2018-06-08 Martin Liska <mliska@suse.cz>
14067
14068 * ipa-inline-analysis.c (simple_edge_hints): Use ::get method.
14069 * ipa-inline.h (estimate_edge_growth): Likewise.
14070
14071 2018-06-08 Martin Liska <mliska@suse.cz>
14072
14073 * cgraph.c (function_version_hasher::hash): Use
14074 cgraph_node::get_uid ().
14075 (function_version_hasher::equal):
14076 * cgraph.h (cgraph_node::get_uid): New method.
14077 * ipa-inline.c (update_caller_keys): Use
14078 cgraph_node::get_uid ().
14079 (update_callee_keys): Likewise.
14080 * ipa-utils.c (searchc): Likewise.
14081 (ipa_reduced_postorder): Likewise.
14082 * lto-cgraph.c (input_node): Likewise.
14083 * passes.c (is_pass_explicitly_enabled_or_disabled): Likewise.
14084 * symbol-summary.h (symtab_insertion): Likewise.
14085 (symtab_removal): Likewise.
14086 (symtab_duplication): Likewise.
14087 * tree-pretty-print.c (dump_function_header): Likewise.
14088 * tree-sra.c (convert_callers_for_node): Likewise.
14089
14090 2018-06-08 Martin Liska <mliska@suse.cz>
14091
14092 * cgraph.c (symbol_table::create_edge): Always assign a new
14093 unique number.
14094 (symbol_table::free_edge): Do not recycle numbers.
14095 * cgraph.h (cgraph_edge::get): New method.
14096 * symbol-summary.h (symtab_removal): Use it.
14097 (symtab_duplication): Likewise.
14098 (call_summary::hashable_uid): Remove.
14099
14100 2018-06-08 Martin Liska <mliska@suse.cz>
14101
14102 * ipa-inline-analysis.c (inline_edge_removal_hook): Remove.
14103 (initialize_growth_caches): Remove.
14104 (free_growth_caches): Likewise.
14105 (do_estimate_edge_time): Use edge_growth_cache.
14106 (do_estimate_edge_size): Likewise.
14107 (do_estimate_edge_hints): Likewise.
14108 * ipa-inline.c (reset_edge_caches): Likewise.
14109 (recursive_inlining): Likewise.
14110 (inline_small_functions): Likewise.
14111 * ipa-inline.h (initialize_growth_caches): Remove.
14112 (estimate_edge_size): Likewise.
14113 (estimate_edge_time): Likewise.
14114 (estimate_edge_hints): Likewise.
14115 (reset_edge_growth_cache): Likewise.
14116 * symbol-summary.h (call_summary::remove): New method.
14117
14118 2018-06-08 Martin Liska <mliska@suse.cz>
14119
14120 * ipa-cp.c (class edge_clone_summary): New summary.
14121 (grow_edge_clone_vectors): Remove.
14122 (ipcp_edge_duplication_hook): Remove.
14123 (class edge_clone_summary_t): New call_summary class.
14124 (ipcp_edge_removal_hook): Remove.
14125 (edge_clone_summary_t::duplicate): New function.
14126 (get_next_cgraph_edge_clone): Use edge_clone_summaries.
14127 (create_specialized_node): Likewise.
14128 (ipcp_driver): Initialize edge_clone_summaries and do not
14129 register hooks.
14130
14131 2018-06-08 Martin Liska <mliska@suse.cz>
14132
14133 * symbol-summary.h (get): New function.
14134 (call_summary::m_initialize_when_cloning): New class member.
14135
14136 2018-06-08 Martin Liska <mliska@suse.cz>
14137
14138 * cgraph.c (cgraph_node::remove): Do not recycle uid.
14139 * cgraph.h (symbol_table::release_symbol): Do not pass uid.
14140 (symbol_table::allocate_cgraph_symbol): Do not set uid.
14141 * passes.c (uid_hash_t): Record removed_nodes by their uids.
14142 (remove_cgraph_node_from_order): Use the removed_nodes set.
14143 (do_per_function_toporder): Likwise.
14144 * symbol-summary.h (symtab_insertion): Use cgraph_node::uid
14145 instead of summary_uid.
14146 (symtab_removal): Likewise.
14147 (symtab_duplication): Likewise.
14148
14149 2018-06-08 Martin Liska <mliska@suse.cz>
14150
14151 * ipa-cp.c (ipcp_store_bits_results): Use
14152 ipcp_transformation_sum.
14153 (ipcp_store_vr_results): Likewise.
14154 * ipa-prop.c (ipcp_grow_transformations_if_necessary): Renamed
14155 to ...
14156 (ipcp_transformation_initialize): ... this.
14157 (ipa_set_node_agg_value_chain):
14158 (ipa_node_params_t::duplicate): Use ipcp_transformation_sum.
14159 (write_ipcp_transformation_info): Likewise.
14160 (read_ipcp_transformation_info): Likewise.
14161 (ipcp_update_bits): Likewise.
14162 (ipcp_update_vr): Likewise.
14163 (ipcp_transform_function): Likewise.
14164 * ipa-prop.h: Rename ipcp_transformation_summary to
14165 ipcp_transformation.
14166 (class ipcp_transformation_t): New function summary.
14167 (ipcp_get_transformation_summary): Use ipcp_transformation_sum.
14168 (ipa_get_agg_replacements_for_node): Likewise.
14169
14170 2018-06-08 Martin Liska <mliska@suse.cz>
14171
14172 * ipa-pure-const.c (struct funct_state_d): Do it class instead
14173 of struct.
14174 (class funct_state_summary_t): New function_summary class.
14175 (has_function_state): Remove.
14176 (get_function_state): Likewise.
14177 (set_function_state): Likewise.
14178 (add_new_function): Likewise.
14179 (funct_state_summary_t::insert): New function.
14180 (duplicate_node_data): Remove.
14181 (remove_node_data): Remove.
14182 (funct_state_summary_t::duplicate): New function.
14183 (register_hooks): Create new funct_state_summaries.
14184 (pure_const_generate_summary): Use it.
14185 (pure_const_write_summary): Likewise.
14186 (pure_const_read_summary): Likewise.
14187 (propagate_pure_const): Likewise.
14188 (propagate_nothrow): Likewise.
14189 (dump_malloc_lattice): Likewise.
14190 (propagate_malloc): Likewise.
14191 (execute): Do not register hooks, just remove summary
14192 instead.
14193 (pass_ipa_pure_const::pass_ipa_pure_const): Simplify
14194 constructor.
14195
14196 2018-06-08 Martin Liska <mliska@suse.cz>
14197
14198 * ipa-reference.c (remove_node_data): Remove.
14199 (duplicate_node_data): Likewise.
14200 (class ipa_ref_var_info_summary_t): New class.
14201 (class ipa_ref_opt_summary_t): Likewise.
14202 (get_reference_vars_info): Use ipa_ref_var_info_summaries.
14203 (get_reference_optimization_summary): Use
14204 ipa_ref_opt_sum_summaries.
14205 (set_reference_vars_info): Remove.
14206 (set_reference_optimization_summary): Likewise.
14207 (ipa_init): Create summaries.
14208 (init_function_info): Use function summary.
14209 (ipa_ref_opt_summary_t::duplicate): New function.
14210 (ipa_ref_opt_summary_t::remove): New function.
14211 (get_read_write_all_from_node): Fix GNU coding style.
14212 (propagate): Use function summary.
14213 (write_node_summary_p): Fix GNU coding style.
14214 (stream_out_bitmap): Likewise.
14215 (ipa_reference_read_optimization_summary): Use function summary.
14216 (ipa_reference_c_finalize): Do not release hooks.
14217
14218 2018-06-08 Martin Liska <mliska@suse.cz>
14219
14220 * ipa-fnsummary.c (dump_ipa_call_summary): Use ::get method.
14221 (analyze_function_body): Extract multiple calls of get_create.
14222 * ipa-inline-analysis.c (simple_edge_hints): Likewise.
14223 * ipa-inline.c (recursive_inlining): Use ::get method.
14224 * ipa-inline.h (estimate_edge_growth): Likewise.
14225
14226 2018-06-08 Martin Liska <mliska@suse.cz>
14227
14228 * hsa-common.h (enum hsa_function_kind): Rename HSA_NONE to
14229 HSA_INVALID.
14230 (hsa_function_summary::hsa_function_summary): Use the new enum
14231 value.
14232 (hsa_gpu_implementation_p): Use hsa_summaries::get.
14233 * hsa-gen.c (hsa_get_host_function): Likewise.
14234 (get_brig_function_name): Likewise.
14235 * ipa-hsa.c (process_hsa_functions): Likewise.
14236 (ipa_hsa_write_summary): Likewise.
14237 * symbol-summary.h (symtab_duplication): Use ::get function/
14238 (get): New function.
14239
14240 2018-06-08 Martin Liska <mliska@suse.cz>
14241
14242 * config/i386/i386.c (ix86_can_inline_p): Use get_create instead
14243 of get.
14244 * hsa-common.c (hsa_summary_t::link_functions): Likewise.
14245 (hsa_register_kernel): Likewise.
14246 * hsa-common.h (hsa_gpu_implementation_p): Likewise.
14247 * hsa-gen.c (hsa_get_host_function): Likewise.
14248 (get_brig_function_name): Likewise.
14249 (generate_hsa): Likewise.
14250 (pass_gen_hsail::execute): Likewise.
14251 * ipa-cp.c (ipcp_cloning_candidate_p): Likewise.
14252 (devirtualization_time_bonus): Likewise.
14253 (ipcp_propagate_stage): Likewise.
14254 * ipa-fnsummary.c (redirect_to_unreachable): Likewise.
14255 (edge_set_predicate): Likewise.
14256 (evaluate_conditions_for_known_args): Likewise.
14257 (evaluate_properties_for_edge): Likewise.
14258 (ipa_fn_summary::reset): Likewise.
14259 (ipa_fn_summary_t::duplicate): Likewise.
14260 (dump_ipa_call_summary): Likewise.
14261 (ipa_dump_fn_summary): Likewise.
14262 (analyze_function_body): Likewise.
14263 (compute_fn_summary): Likewise.
14264 (estimate_edge_devirt_benefit): Likewise.
14265 (estimate_edge_size_and_time): Likewise.
14266 (estimate_calls_size_and_time): Likewise.
14267 (estimate_node_size_and_time): Likewise.
14268 (inline_update_callee_summaries): Likewise.
14269 (remap_edge_change_prob): Likewise.
14270 (remap_edge_summaries): Likewise.
14271 (ipa_merge_fn_summary_after_inlining): Likewise.
14272 (ipa_update_overall_fn_summary): Likewise.
14273 (read_ipa_call_summary): Likewise.
14274 (inline_read_section): Likewise.
14275 (write_ipa_call_summary): Likewise.
14276 (ipa_fn_summary_write): Likewise.
14277 (ipa_free_fn_summary): Likewise.
14278 * ipa-hsa.c (process_hsa_functions): Likewise.
14279 (ipa_hsa_write_summary): Likewise.
14280 (ipa_hsa_read_section): Likewise.
14281 * ipa-icf.c (sem_function::merge): Likewise.
14282 * ipa-inline-analysis.c (simple_edge_hints): Likewise.
14283 (do_estimate_edge_time): Likewise.
14284 (estimate_size_after_inlining): Likewise.
14285 (estimate_growth): Likewise.
14286 (growth_likely_positive): Likewise.
14287 * ipa-inline-transform.c (clone_inlined_nodes): Likewise.
14288 (inline_call): Likewise.
14289 * ipa-inline.c (caller_growth_limits): Likewise.
14290 (can_inline_edge_p): Likewise.
14291 (can_inline_edge_by_limits_p): Likewise.
14292 (compute_uninlined_call_time): Likewise.
14293 (compute_inlined_call_time): Likewise.
14294 (want_inline_small_function_p): Likewise.
14295 (edge_badness): Likewise.
14296 (update_caller_keys): Likewise.
14297 (update_callee_keys): Likewise.
14298 (recursive_inlining): Likewise.
14299 (inline_small_functions): Likewise.
14300 (inline_to_all_callers_1): Likewise.
14301 (dump_overall_stats): Likewise.
14302 (early_inline_small_functions): Likewise.
14303 (early_inliner): Likewise.
14304 * ipa-inline.h (estimate_edge_growth): Likewise.
14305 * ipa-profile.c (ipa_propagate_frequency_1): Likewise.
14306 * ipa-prop.c (ipa_make_edge_direct_to_target): Likewise.
14307 * ipa-prop.h (IPA_NODE_REF): Likewise.
14308 (IPA_EDGE_REF): Likewise.
14309 * ipa-pure-const.c (malloc_candidate_p): Likewise.
14310 (propagate_malloc): Likewise.
14311 * ipa-split.c (execute_split_functions): Likewise.
14312 * symbol-summary.h: Rename get to get_create.
14313 (get): Likewise.
14314 (get_create): Likewise.
14315 * tree-sra.c (ipa_sra_preliminary_function_checks): Likewise.
14316
14317 2018-06-08 Martin Liska <mliska@suse.cz>
14318
14319 * symbol-summary.h (release): Move definition out of class
14320 declaration.
14321 (symtab_removal): Likewise.
14322 (symtab_duplication): Likewise.
14323
14324 2018-06-08 Martin Liska <mliska@suse.cz>
14325
14326 * symbol-summary.h (function_summary): Move constructor
14327 implementation out of class declaration.
14328 (release): Likewise.
14329 (symtab_insertion): Likewise.
14330 (symtab_removal): Likewise.
14331 (symtab_duplication): Likewise.
14332 (get): Likewise.
14333
14334 2018-06-08 Martin Liska <mliska@suse.cz>
14335
14336 * Makefile.in: Remove support for MPX (macros, related functions,
14337 fields in cgraph_node, ...).
14338 * builtin-types.def (BT_BND): Likewise.
14339 (BT_FN_BND_CONST_PTR): Likewise.
14340 (BT_FN_CONST_PTR_BND): Likewise.
14341 (BT_FN_VOID_PTR_BND): Likewise.
14342 (BT_FN_BND_CONST_PTR_SIZE): Likewise.
14343 (BT_FN_VOID_CONST_PTR_BND_CONST_PTR): Likewise.
14344 * builtins.c (expand_builtin_memcpy_with_bounds): Likewise.
14345 (expand_builtin_mempcpy_with_bounds): Likewise.
14346 (expand_builtin_memset_with_bounds): Likewise.
14347 (expand_builtin_memset_args): Likewise.
14348 (std_expand_builtin_va_start): Likewise.
14349 (expand_builtin): Likewise.
14350 (expand_builtin_with_bounds): Likewise.
14351 * builtins.def (DEF_BUILTIN_CHKP): Likewise.
14352 (DEF_LIB_BUILTIN_CHKP): Likewise.
14353 (DEF_EXT_LIB_BUILTIN_CHKP): Likewise.
14354 (DEF_CHKP_BUILTIN): Likewise.
14355 (BUILT_IN_MEMCPY): Likewise.
14356 (BUILT_IN_MEMMOVE): Likewise.
14357 (BUILT_IN_MEMPCPY): Likewise.
14358 (BUILT_IN_MEMSET): Likewise.
14359 (BUILT_IN_STPCPY): Likewise.
14360 (BUILT_IN_STRCAT): Likewise.
14361 (BUILT_IN_STRCHR): Likewise.
14362 (BUILT_IN_STRCPY): Likewise.
14363 (BUILT_IN_STRLEN): Likewise.
14364 (BUILT_IN_MEMCPY_CHK): Likewise.
14365 (BUILT_IN_MEMMOVE_CHK): Likewise.
14366 (BUILT_IN_MEMPCPY_CHK): Likewise.
14367 (BUILT_IN_MEMSET_CHK): Likewise.
14368 (BUILT_IN_STPCPY_CHK): Likewise.
14369 (BUILT_IN_STRCAT_CHK): Likewise.
14370 (BUILT_IN_STRCPY_CHK): Likewise.
14371 * calls.c (store_bounds): Likewise.
14372 (emit_call_1): Likewise.
14373 (special_function_p): Likewise.
14374 (maybe_warn_nonstring_arg): Likewise.
14375 (initialize_argument_information): Likewise.
14376 (finalize_must_preallocate): Likewise.
14377 (compute_argument_addresses): Likewise.
14378 (expand_call): Likewise.
14379 * cfgexpand.c (expand_call_stmt): Likewise.
14380 (expand_return): Likewise.
14381 (expand_gimple_stmt_1): Likewise.
14382 (pass_expand::execute): Likewise.
14383 * cgraph.c (cgraph_edge::redirect_call_stmt_to_callee): Likewise.
14384 (cgraph_node::remove): Likewise.
14385 (cgraph_node::dump): Likewise.
14386 (cgraph_node::verify_node): Likewise.
14387 * cgraph.h (chkp_function_instrumented_p): Likewise.
14388 (symtab_node::get_alias_target): Likewise.
14389 (cgraph_node::can_remove_if_no_direct_calls_and_refs_p): Likewise.
14390 (cgraph_local_p): Likewise.
14391 * cgraphbuild.c (cgraph_edge::rebuild_edges): Likewise.
14392 (cgraph_edge::rebuild_references): Likewise.
14393 * cgraphunit.c (varpool_node::finalize_decl): Likewise.
14394 (walk_polymorphic_call_targets): Likewise.
14395 (cgraph_node::expand_thunk): Likewise.
14396 (symbol_table::output_weakrefs): Likewise.
14397 * common/config/i386/i386-common.c (OPTION_MASK_ISA2_GENERAL_REGS_ONLY_UNSET): Likewise.
14398 (ix86_handle_option): Likewise.
14399 * config/i386/constraints.md: Likewise.
14400 * config/i386/i386-builtin-types.def (BND): Likewise.
14401 (VOID): Likewise.
14402 (PVOID): Likewise.
14403 (ULONG): Likewise.
14404 * config/i386/i386-builtin.def (BDESC_END): Likewise.
14405 (BDESC_FIRST): Likewise.
14406 (BDESC): Likewise.
14407 * config/i386/i386-c.c (ix86_target_macros_internal): Likewise.
14408 * config/i386/i386-protos.h (ix86_bnd_prefixed_insn_p): Likewise.
14409 * config/i386/i386.c (enum reg_class): Likewise.
14410 (ix86_target_string): Likewise.
14411 (ix86_option_override_internal): Likewise.
14412 (ix86_conditional_register_usage): Likewise.
14413 (ix86_valid_target_attribute_inner_p): Likewise.
14414 (ix86_set_indirect_branch_type): Likewise.
14415 (ix86_set_current_function): Likewise.
14416 (ix86_function_arg_regno_p): Likewise.
14417 (init_cumulative_args): Likewise.
14418 (ix86_function_arg_advance): Likewise.
14419 (ix86_function_arg): Likewise.
14420 (ix86_pass_by_reference): Likewise.
14421 (ix86_function_value_regno_p): Likewise.
14422 (ix86_function_value_1): Likewise.
14423 (ix86_function_value_bounds): Likewise.
14424 (ix86_return_in_memory): Likewise.
14425 (ix86_setup_incoming_vararg_bounds): Likewise.
14426 (ix86_va_start): Likewise.
14427 (indirect_thunk_need_prefix): Likewise.
14428 (print_reg): Likewise.
14429 (ix86_print_operand): Likewise.
14430 (ix86_expand_call): Likewise.
14431 (ix86_output_function_return): Likewise.
14432 (reg_encoded_number): Likewise.
14433 (BDESC_VERIFYS): Likewise.
14434 (ix86_init_mpx_builtins): Likewise.
14435 (ix86_init_builtins): Likewise.
14436 (ix86_emit_cmove): Likewise.
14437 (ix86_emit_move_max): Likewise.
14438 (ix86_expand_builtin): Likewise.
14439 (ix86_builtin_mpx_function): Likewise.
14440 (ix86_get_arg_address_for_bt): Likewise.
14441 (ix86_load_bounds): Likewise.
14442 (ix86_store_bounds): Likewise.
14443 (ix86_load_returned_bounds): Likewise.
14444 (ix86_store_returned_bounds): Likewise.
14445 (ix86_class_likely_spilled_p): Likewise.
14446 (ix86_hard_regno_mode_ok): Likewise.
14447 (x86_order_regs_for_local_alloc): Likewise.
14448 (ix86_mitigate_rop): Likewise.
14449 (ix86_bnd_prefixed_insn_p): Likewise.
14450 (ix86_mpx_bound_mode): Likewise.
14451 (ix86_make_bounds_constant): Likewise.
14452 (ix86_initialize_bounds): Likewise.
14453 (TARGET_LOAD_BOUNDS_FOR_ARG): Likewise.
14454 (TARGET_STORE_BOUNDS_FOR_ARG): Likewise.
14455 (TARGET_LOAD_RETURNED_BOUNDS): Likewise.
14456 (TARGET_STORE_RETURNED_BOUNDS): Likewise.
14457 (TARGET_CHKP_BOUND_MODE): Likewise.
14458 (TARGET_BUILTIN_CHKP_FUNCTION): Likewise.
14459 (TARGET_CHKP_FUNCTION_VALUE_BOUNDS): Likewise.
14460 (TARGET_CHKP_MAKE_BOUNDS_CONSTANT): Likewise.
14461 (TARGET_CHKP_INITIALIZE_BOUNDS): Likewise.
14462 * config/i386/i386.h (TARGET_MPX): Likewise.
14463 (TARGET_MPX_P): Likewise.
14464 (VALID_BND_REG_MODE): Likewise.
14465 (FIRST_BND_REG): Likewise.
14466 (LAST_BND_REG): Likewise.
14467 (enum reg_class): Likewise.
14468 (BND_REG_P): Likewise.
14469 (BND_REGNO_P): Likewise.
14470 (BNDmode): Likewise.
14471 (ADJUST_INSN_LENGTH): Likewise.
14472 * config/i386/i386.md: Likewise.
14473 * config/i386/i386.opt: Likewise.
14474 * config/i386/linux-common.h (LIBMPX_LIBS): Likewise.
14475 (defined): Likewise.
14476 (LINK_MPX): Likewise.
14477 (MPX_SPEC): Likewise.
14478 (LIBMPX_SPEC): Likewise.
14479 (LIBMPXWRAPPERS_SPEC): Likewise.
14480 (CHKP_SPEC): Likewise.
14481 * config/i386/predicates.md: Likewise.
14482 * dbxout.c (dbxout_type): Likewise.
14483 * doc/extend.texi: Likewise.
14484 * doc/invoke.texi: Likewise.
14485 * doc/md.texi: Likewise.
14486 * doc/tm.texi: Likewise.
14487 * doc/tm.texi.in: Likewise.
14488 * dwarf2out.c (is_base_type): Likewise.
14489 (gen_formal_types_die): Likewise.
14490 (gen_subprogram_die): Likewise.
14491 (gen_type_die_with_usage): Likewise.
14492 (gen_decl_die): Likewise.
14493 (dwarf2out_late_global_decl): Likewise.
14494 * expr.c (expand_assignment): Likewise.
14495 (emit_storent_insn): Likewise.
14496 (store_expr_with_bounds): Likewise.
14497 (store_expr): Likewise.
14498 (expand_expr_real_1): Likewise.
14499 * expr.h (store_expr_with_bounds): Likewise.
14500 * function.c (use_register_for_decl): Likewise.
14501 (struct bounds_parm_data): Likewise.
14502 (assign_parms_augmented_arg_list): Likewise.
14503 (assign_parm_find_entry_rtl): Likewise.
14504 (assign_parm_is_stack_parm): Likewise.
14505 (assign_parm_load_bounds): Likewise.
14506 (assign_bounds): Likewise.
14507 (assign_parms): Likewise.
14508 (expand_function_start): Likewise.
14509 * gcc.c (CHKP_SPEC): Likewise.
14510 * gimple-fold.c (gimple_fold_builtin_memory_op): Likewise.
14511 * gimple-ssa-warn-restrict.c (builtin_access::builtin_access): Likewise.
14512 (wrestrict_dom_walker::check_call): Likewise.
14513 * gimple.c (gimple_build_call_from_tree): Likewise.
14514 * gimple.h (enum gf_mask): Likewise.
14515 (gimple_call_with_bounds_p): Likewise.
14516 (gimple_call_set_with_bounds): Likewise.
14517 * gimplify.c (gimplify_init_constructor): Likewise.
14518 * ipa-cp.c (initialize_node_lattices): Likewise.
14519 (propagate_constants_across_call): Likewise.
14520 (find_more_scalar_values_for_callers_subset): Likewise.
14521 * ipa-hsa.c (process_hsa_functions): Likewise.
14522 * ipa-icf-gimple.c (func_checker::compare_gimple_call): Likewise.
14523 * ipa-icf.c (sem_function::merge): Likewise.
14524 * ipa-inline.c (early_inliner): Likewise.
14525 * ipa-pure-const.c (warn_function_noreturn): Likewise.
14526 (warn_function_cold): Likewise.
14527 (propagate_pure_const): Likewise.
14528 * ipa-ref.h (enum GTY): Likewise.
14529 * ipa-split.c (find_retbnd): Likewise.
14530 (consider_split): Likewise.
14531 (split_function): Likewise.
14532 * ipa-visibility.c (cgraph_externally_visible_p): Likewise.
14533 * ipa.c (walk_polymorphic_call_targets): Likewise.
14534 (symbol_table::remove_unreachable_nodes): Likewise.
14535 (process_references): Likewise.
14536 (cgraph_build_static_cdtor_1): Likewise.
14537 * lto-cgraph.c (lto_output_node): Likewise.
14538 (output_refs): Likewise.
14539 (compute_ltrans_boundary): Likewise.
14540 (input_overwrite_node): Likewise.
14541 (input_node): Likewise.
14542 (input_cgraph_1): Likewise.
14543 * params.def (PARAM_CHKP_MAX_CTOR_SIZE): Likewise.
14544 * passes.c (pass_manager::execute_early_local_passes): Likewise.
14545 (class pass_chkp_instrumentation_passes): Likewise.
14546 (make_pass_chkp_instrumentation_passes): Likewise.
14547 * passes.def: Likewise.
14548 * rtl.h (struct GTY): Likewise.
14549 (CALL_EXPR_WITH_BOUNDS_P): Likewise.
14550 * stor-layout.c (layout_type): Likewise.
14551 * symtab.c: Likewise.
14552 * target.def: Likewise.
14553 * targhooks.c (default_chkp_bound_type): Likewise.
14554 (default_chkp_bound_mode): Likewise.
14555 (default_builtin_chkp_function): Likewise.
14556 (default_chkp_function_value_bounds): Likewise.
14557 (default_chkp_make_bounds_constant): Likewise.
14558 (default_chkp_initialize_bounds): Likewise.
14559 * targhooks.h (default_chkp_bound_type): Likewise.
14560 (default_chkp_bound_mode): Likewise.
14561 (default_builtin_chkp_function): Likewise.
14562 (default_chkp_function_value_bounds): Likewise.
14563 (default_chkp_make_bounds_constant): Likewise.
14564 (default_chkp_initialize_bounds): Likewise.
14565 * toplev.c (compile_file): Likewise.
14566 (process_options): Likewise.
14567 * tree-core.h (DEF_BUILTIN): Likewise.
14568 (DEF_BUILTIN_CHKP): Likewise.
14569 * tree-inline.c (declare_return_variable): Likewise.
14570 (remap_gimple_stmt): Likewise.
14571 (copy_bb): Likewise.
14572 (initialize_inlined_parameters): Likewise.
14573 (expand_call_inline): Likewise.
14574 * tree-pass.h (make_pass_ipa_chkp_versioning): Likewise.
14575 (make_pass_ipa_chkp_early_produce_thunks): Likewise.
14576 (make_pass_ipa_chkp_produce_thunks): Likewise.
14577 (make_pass_chkp): Likewise.
14578 (make_pass_chkp_opt): Likewise.
14579 (make_pass_chkp_instrumentation_passes): Likewise.
14580 * tree-pretty-print.c (dump_generic_node): Likewise.
14581 * tree-ssa-ccp.c (insert_clobber_before_stack_restore): Likewise.
14582 * tree-ssa-dce.c (propagate_necessity): Likewise.
14583 (eliminate_unnecessary_stmts): Likewise.
14584 * tree-ssa-pre.c (create_expression_by_pieces): Likewise.
14585 * tree-ssa-sccvn.c (copy_reference_ops_from_call): Likewise.
14586 * tree-ssa-sccvn.h: Likewise.
14587 * tree-ssa-strlen.c (get_string_length): Likewise.
14588 (valid_builtin_call): Likewise.
14589 (adjust_last_stmt): Likewise.
14590 (handle_builtin_strchr): Likewise.
14591 (handle_builtin_strcpy): Likewise.
14592 (handle_builtin_stxncpy): Likewise.
14593 (handle_builtin_memcpy): Likewise.
14594 (handle_builtin_strcat): Likewise.
14595 (strlen_check_and_optimize_stmt): Likewise.
14596 * tree-stdarg.c (expand_ifn_va_arg_1): Likewise.
14597 * tree-streamer-in.c: Likewise.
14598 * tree-streamer.c (record_common_node): Likewise.
14599 * tree.c (tree_code_size): Likewise.
14600 (wide_int_to_tree_1): Likewise.
14601 (type_contains_placeholder_1): Likewise.
14602 (build_common_tree_nodes): Likewise.
14603 * tree.def (POINTER_BOUNDS_TYPE): Likewise.
14604 * tree.h (POINTER_BOUNDS_TYPE_P): Likewise.
14605 (POINTER_BOUNDS_P): Likewise.
14606 (BOUNDED_TYPE_P): Likewise.
14607 (BOUNDED_P): Likewise.
14608 (CALL_WITH_BOUNDS_P): Likewise.
14609 (pointer_bounds_type_node): Likewise.
14610 * value-prof.c (gimple_ic): Likewise.
14611 * var-tracking.c (vt_add_function_parameters): Likewise.
14612 * varasm.c (make_decl_rtl): Likewise.
14613 (assemble_start_function): Likewise.
14614 (output_constant): Likewise.
14615 (maybe_assemble_visibility): Likewise.
14616 * varpool.c (ctor_for_folding): Likewise.
14617 * chkp-builtins.def: Remove.
14618 * ipa-chkp.c: Remove.
14619 * ipa-chkp.h: Remove.
14620 * rtl-chkp.c: Remove.
14621 * rtl-chkp.h: Remove.
14622 * tree-chkp-opt.c: Remove.
14623 * tree-chkp.c: Remove.
14624 * tree-chkp.h: Remove.
14625
14626 2018-06-07 Carl Love <cel@us.ibm.com>
14627
14628 * config/rs6000/vsx.md (vextract_fp_from_shorth,
14629 vextract_fp_from_shortl): Add BE support.
14630
14631 2018-06-07 Paul Koning <ni1d@arrl.net>
14632
14633 * compare-elim.c (try_merge_compare): Don't merge compare if
14634 address contains a side effect.
14635 (try_eliminate_compare): Likewise.
14636
14637 2018-06-07 Olga Makhotina <olga.makhotina@intel.com>
14638
14639 * config.gcc: Support "tremont".
14640 * config/i386/driver-i386.c (host_detect_local_cpu): Detect "tremont".
14641 * config/i386/i386-c.c (ix86_target_macros_internal): Handle
14642 PROCESSOR_TREMONT.
14643 * config/i386/i386.c (m_TREMONT): Define.
14644 (processor_target_table): Add "tremont".
14645 (PTA_TREMONT): Define.
14646 (ix86_lea_outperforms): Add TARGET_TREMONT.
14647 (get_builtin_code_for_version): Handle PROCESSOR_TREMONT.
14648 (fold_builtin_cpu): Add M_INTEL_TREMONT, replace M_INTEL_GOLDMONT
14649 and M_INTEL_GOLDMONT_PLUS.
14650 (fold_builtin_cpu): Add "tremont".
14651 (ix86_add_stmt_cost): Add TARGET_TREMONT.
14652 (ix86_option_override_internal): Add "tremont".
14653 * config/i386/i386.h (processor_costs): Define TARGET_TREMONT.
14654 (processor_type): Add PROCESSOR_TREMONT.
14655 * config/i386/x86-tune.def: Add m_TREMONT.
14656 * doc/invoke.texi: Add tremont as x86 -march=/-mtune= CPU type.
14657
14658 2018-06-07 Jozef Lawrynowicz <jozef.l@mittosystems.com>
14659
14660 * config/msp430/msp430.c (msp430_mcu_name): Set the "i" in the
14661 symbol defined for msp430i* devices to be lower case.
14662
14663 2018-06-07 Richard Biener <rguenther@suse.de>
14664
14665 * graphite-sese-to-poly.c (extract_affine): Avoid unneded
14666 wrapping. Properly wrap the result of a BIT_NOT_EXPR.
14667 Properly wrap signed arithmetic if overflow wraps.
14668
14669 2018-06-07 Jakub Jelinek <jakub@redhat.com>
14670
14671 PR tree-optimization/69615
14672 * tree-ssa-reassoc.c (optimize_range_tests_var_bound): If rhs2 is lhs
14673 of a cast from a same precision integral SSA_NAME in a bb dominated
14674 by first_bb, retry with rhs2 set to the rhs1 of the cast. Don't emit
14675 cast to utype if rhs2 has already a compatible type.
14676
14677 2018-06-07 Richard Biener <rguenther@suse.de>
14678
14679 PR tree-optimization/85935
14680 * graphite-scop-detection.c (find_params_in_bb): Analyze
14681 condition operands with respect to the correct loop. Assert
14682 the analysis doesn't fail.
14683
14684 2018-06-04 Carl Love <cel@us.ibm.com>
14685
14686 * config/rs6000/vsx.md (first_match_index_<mode>): Calculate index
14687 using natural element order. Use gen_lshrsi3 instead of gen_ashrsi3
14688 as it is slightly cheaper.
14689 (first_match_or_eos_index_<mode>):
14690 Calculate index using natural element order.
14691 (first_match_index_<mode>):
14692 Calculate index using natural element order.
14693 (first_match_or_eos_index_<mode>):
14694 Calculate index using natural order.
14695 (define_insn vclzlsbb): Change to define_insn vclzlsbb_<mode>.
14696 for BE and LE modes.
14697 * config/rs6000/rs6000-c.c: Rename P9V_BUILTIN_VCLZLSBB,
14698 P9V_BUILTIN_VCLZLSBB_V16QI.
14699 * config/rs6000/rs6000-builtin.def: Make VCLZLSBB mode
14700 specific.
14701
14702 2018-06-06 Kelvin Nilsen <kelvin@gcc.gnu.org>
14703
14704 * doc/extend.texi (PowerPC AltiVec Built-in Functions): Adjust
14705 indentation and line wrap for many prototypes. Add missing
14706 @smallexample directives around block of prototypes for vec_xl and
14707 vec_xst.
14708
14709 2018-06-05 Michael Meissner <meissner@linux.ibm.com>
14710
14711 * config/rs6000/rs6000.c (rs6000_passes_ieee128): New boolean to
14712 track if we pass or return IEEE 128-bit floating point.
14713 (ieee128_mangling_gcc_8_1): New boolean to say whether to generate
14714 C++ mangling that is compatible with GCC 8.1.
14715 (TARGET_ASM_GLOBALIZE_DECL_NAME): Override target hook.
14716 (init_cumulative_args): Note if we pass or return IEEE 128-bit
14717 floating point types.
14718 (rs6000_function_arg_advance_1): Likewise.
14719 (rs6000_mangle_type): Optionally generate mangled names that match
14720 what GCC 8.1 generated for IEEE 128-bit floating point types.
14721 (rs6000_globalize_decl_name): If we have an external function that
14722 passes or returns IEEE 128-bit types, generate a weak reference
14723 from the mangled name used in GCC 8.1 to the current mangled
14724 name.
14725 (rs6000_init_builtins): Make __ibm128 use the long double type if
14726 long double is IBM extended double. Make __float128 use the long
14727 double type if long double is IEEE 128-bit.
14728
14729 PR target/85657
14730 * config/rs6000/rs6000-builtin.def (BU_IBM128_2): New helper
14731 macro for __ibm128 built-in functions.
14732 (PACK_IF): Add __ibm128 pack/unpack functions.
14733 (UNPACK_IF): Likewise.
14734 * config/rs6000/rs6000.c (rs6000_builtin_mask_calculate): Do not
14735 enable long double built-in functions if long double is IEEE
14736 128-bit floating point.
14737 (rs6000_invalid_builtin): Update long double built-in function
14738 error message.
14739 (rs6000_expand_builtin): For PACK_IF and UNPACK_IF built-in
14740 functions, adjust the built-in function to use the long double
14741 built-in function if __ibm128 and long double are the same type.
14742 * doc/extend.texi (PowerPC builtins): Update documention for
14743 __builtin_{,un}pack_longdouble. Add documentation for
14744 __builtin_{,un}pack_ibm128.
14745
14746 2018-06-06 Jim Wilson <jimw@sifive.com>
14747
14748 * config/riscv/riscv.c (enum riscv_privilege_levels): New.
14749 (struct machine_function): New field interrupt_mode.
14750 (riscv_handle_type_attribute): New function. Add forward declaration.
14751 (riscv_attribute_table) <interrupt>: Use riscv_handle_type_attribute.
14752 (riscv_expand_epilogue): Check interrupt_mode field.
14753 (riscv_set_current_function): Check interrupt attribute args and
14754 set interrupt_mode field.
14755 * config/riscv/riscv.md (UNSPECV_SRET, UNSPECV_URET): New.
14756 (riscv_sret, riscv_uret): New.
14757 * doc/extend.texi (RISC-V Function Attributes) <interrupt>: Document
14758 new arguments to interrupt attribute.
14759
14760 2018-06-06 Peter Bergner <bergner@vnet.ibm.com>
14761
14762 PR target/63177
14763 * /config/rs6000/rs6000.h (ASM_CPU_SPEC): Add support for -mpower9.
14764 Don't handle -mcpu=power8 if -mpower9-vector is also used.
14765
14766 2018-06-06 Kelvin Nilsen <kelvin@gcc.gnu.org>
14767
14768 * config/rs6000/rs6000-builtin.def (VSX_BUILTIN_VEC_LD,
14769 VSX_BUILTIN_VEC_ST): Add comment to explain non-traditional uses.
14770 * config/rs6000/rs6000-c.c (altivec_overloaded_builtins): Remove
14771 several redundant entries.
14772
14773 2018-06-06 David Malcolm <dmalcolm@redhat.com>
14774
14775 * config/i386/i386-protos.h (ix86_expand_call): Strengthen return
14776 type from "rtx" to "rtx_insn *".
14777 * config/i386/i386.c (ix86_expand_split_stack_prologue): Likewise
14778 for local "call_insn", removing cast.
14779 (ix86_expand_call): Likewise, introducing a "call_insn" local.
14780
14781 2018-06-06 Eric Botcazou <ebotcazou@adacore.com>
14782
14783 PR tree-optimization/86066
14784 * gimple-ssa-store-merging.c (process_store): Do not bypass BIT_NOT_EXPR
14785 for BIT_INSERT_EXPR stores.
14786
14787 2018-06-06 Richard Biener <rguenther@suse.de>
14788
14789 PR tree-optimization/86062
14790 * tree-ssa-sccvn.c (vn_reference_lookup_3): Handle arbitrary
14791 component refs ontop
14792 of to be offsetted base.
14793
14794 2018-06-06 Jozef Lawrynowicz <jozef.l@mittosystems.com>
14795
14796 * config/msp430/msp430.c (msp430_attr): Allow interrupt handlers
14797 to be static and remove check on interrupt attribute name.
14798
14799 2018-06-05 Kelvin Nilsen <kelvin@gcc.gnu.org>
14800
14801 * doc/extend.texi (PowerPC AltiVec Built-in Functions): Remove
14802 volatile qualifier from vec_lvsl and vec_lvsr argument prototypes.
14803
14804 2018-06-05 Steve Ellcey <sellcey@cavium.com>
14805
14806 PR target/79924
14807 * config/aarch64/aarch64-protos.h (aarch64_err_no_fpadvsimd): Remove
14808 second argument.
14809 * config/aarch64/aarch64-protos..c (aarch64_err_no_fpadvsimd):
14810 Remove second argument, change how error is called.
14811 (aarch64_layout_arg): Remove second argument from
14812 aarch64_err_no_fpadvsimd call.
14813 (aarch64_init_cumulative_args): Ditto.
14814 (aarch64_gimplify_va_arg_expr): Ditto.
14815 * config/aarch64/aarch64.md (mov<mode>): Ditto.
14816
14817 2018-06-05 Uros Bizjak <ubizjak@gmail.com>
14818
14819 * config/i386/i386.md (simple_return_indirect_internal): New expander.
14820 (*simple_return_indirect_internal<mode>): Rename from
14821 simple_return_indirect_internal. Use W mode iterator.
14822 (rstorssp): New expander.
14823 (*rstorssp<mode>): Rename from rstorssp. Use P mode iterator.
14824 (clrssbsy): New expander.
14825 (*clrssbsy<mode>): Rename from clrssbsy. Use P mode iterator.
14826
14827 2018-06-05 Andre Vieira <andre.simoesdiasvieira@arm.com>
14828
14829 * config/arm/arm_cmse.h (cmse_nsfptr_create): Change typeof to
14830 __typeof__.
14831 (cmse_check_pointed_object): Likewise.
14832
14833 2018-06-05 Martin Liska <mliska@suse.cz>
14834
14835 PR gcov-profile/47618
14836 * doc/invoke.texi: Document how -fprofile-dir format
14837 is extended.
14838
14839 2018-06-05 Richard Biener <rguenther@suse.de>
14840
14841 * tree-cfgcleanup.c (cleanup_control_flow_pre): For edge
14842 removal pretend DOM info isn't available so we do not update
14843 it and only remove edges, not dominated blocks. Actually free
14844 DOM info in case we removed something. Remove unreachable blocks.
14845 (mfb_keep_latches): Work with either DOM info or marked backedges.
14846 (cleanup_tree_cfg_noloop): Do not remove unreachable blocks
14847 first. Mark backedges if DOM info isn't available.
14848 (Re-)compute DOM info after cleanup_control_flow_pre.
14849
14850 2018-06-05 Richard Biener <rguenther@suse.de>
14851
14852 * tree-cfg.c (struct locus_discrim_map): Store line, not location.
14853 (locus_discrim_hasher::hash): Adjust.
14854 (locus_discrim_hasher::equal): Likewise.
14855 (next_discriminator_for_locus): Work on line directly.
14856 (same_line_p): Pass in expanded locus1 as well.
14857 (assign_discriminators): Avoid redundant location expansions.
14858
14859 2018-06-05 Richard Biener <rguenther@suse.de>
14860
14861 PR tree-optimization/86046
14862 * tree-ssa.c (maybe_optimize_var): Clear DECL_GIMPLE_REG_P
14863 if required after clearing TREE_ADDRESSABLE.
14864
14865 2018-06-05 Richard Biener <rguenther@suse.de>
14866
14867 PR tree-optimization/86047
14868 * tree-ssa-loop.c (for_each_index): Glob handling of all
14869 decls and constants and really handle all of them.
14870
14871 2018-06-05 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
14872
14873 PR target/81497
14874 * config/arm/arm-builtins.c (arm_type_qualifiers): Add
14875 qualifier_void_pointer and qualifier_const_void_pointer.
14876 (arm_ldc_qualifiers, arm_stc_qualifiers): Use the above.
14877 (arm_init_builtins): Handle the above.
14878 * config/arm/arm_acle.h (__arm_cdp, __arm_ldc, __arm_ldcl, __arm_stc,
14879 __arm_stcl, __arm_mcr, __arm_cdp2, __arm_ldc2, __arm_ldcl2, __arm_stc2,
14880 __arm_stcl2,__arm_mcr2, __arm_mcrr, __arm_mcrr2): Remove return for
14881 void intrinsics.
14882
14883 2018-06-05 Martin Liska <mliska@suse.cz>
14884
14885 * auto-profile.c (read_autofdo_file): Do not use
14886 gcov_ctr_summary struct.
14887 (afdo_callsite_hot_enough_for_early_inline): Likewise.
14888 * coverage.c (struct counts_entry): Likewise.
14889 (read_counts_file): Read just single summary entry.
14890 (get_coverage_counts): Use gcov_summary struct.
14891 * coverage.h (get_coverage_counts): Likewise.
14892 * gcov-dump.c (dump_working_sets): Likewise.
14893 (tag_summary): Dump just single summary.
14894 * gcov-io.c (gcov_write_summary): Write just histogram
14895 summary.
14896 (gcov_read_summary): Read just single summary.
14897 (compute_working_sets): Use gcov_summary struct.
14898 * gcov-io.h (GCOV_TAG_SUMMARY_LENGTH): Remove usage
14899 of GCOV_COUNTERS_SUMMABLE.
14900 (GCOV_COUNTERS_SUMMABLE): Remove.
14901 (GCOV_FIRST_VALUE_COUNTER): Replace with
14902 GCOV_COUNTER_V_INTERVAL.
14903 (struct gcov_ctr_summary): Remove.
14904 (struct gcov_summary): Directly use fields of former
14905 gcov_ctr_summary.
14906 (compute_working_sets): Use gcov_summary struct.
14907 * gcov.c (read_count_file): Do not use ctrs fields.
14908 * lto-cgraph.c (merge_profile_summaries): Use gcov_summary
14909 struct.
14910 * lto-streamer.h (struct GTY): Make profile_info gcov_summary
14911 struct.
14912 * profile.c: Likewise.
14913 * profile.h: Likewise.
14914
14915 2018-06-05 Martin Liska <mliska@suse.cz>
14916
14917 PR gcov-profile/84846
14918 * gcov.c (output_lines): Print working directory only
14919 in intermediate format.
14920
14921 2018-06-05 Andreas Krebbel <krebbel@linux.ibm.com>
14922
14923 * config/s390/s390-builtin-types.def: Add void function type.
14924 * config/s390/s390-builtins.def: Use the function type for the
14925 tbeginc builtin.
14926
14927 2018-06-04 Jim Wilson <jimw@sifive.com>
14928
14929 * config/riscv/riscv-protos.h (riscv_expand_epilogue): Change bool arg
14930 to int.
14931 * config/riscv/riscv.c (riscv_for_each_saved_reg): New args epilogue
14932 and maybe_eh_return. Change regno to unsigned int. Use new args to
14933 handle EH_RETURN_DATA_REGNO registers properly.
14934 (riscv_expand_prologue): Pass new args to riscv_for_each_saved_reg.
14935 (riscv_expand_epilogue): Update comment. Change argument name and
14936 type. Update code to use new name and type. Pass new args to
14937 riscv_for_each_saved_reg. Only use EH_RETURN_STACKADJ_RTX when
14938 EXCEPTION_RETURN.
14939 * config/riscv/riscv.md (NORMAL_RETURN): New.
14940 (SIBCALL_RETURN, EXCEPTION_RETURN): New.
14941 (epilogue, sibcall_epilogue): Update riscv_expand_epilogue arg.
14942 (eh_return): Call gen_eh_return_internal and emit barrier.
14943 (eh_return_internal): Call riscv_expand_epilogue.
14944
14945 2018-06-04 Eric Botcazou <ebotcazou@adacore.com>
14946
14947 * gimple-ssa-store-merging.c (struct merged_store_group): Move up
14948 bit_insertion field and declare can_be_merged_into method.
14949 (merged_store_group::can_be_merged_into): New method.
14950 (imm_store_chain_info::coalesce_immediate): Call it to decide whether
14951 consecutive non-overlapping stores can be merged. Turn MEM_REF stores
14952 into BIT_INSERT_EXPR stores if the group contains a non-MEM_REF store.
14953
14954 2018-06-04 Richard Biener <rguenther@suse.de>
14955
14956 PR tree-optimization/85955
14957 * builtins.c (fold_builtin_sincos): Convert pointers to
14958 destination to appropriate type before dereferencing.
14959
14960 2018-06-04 Segher Boessenkool <segher@kernel.crashing.org>
14961
14962 * config/rs6000/rs6000.md (abs<mode>2 for FLOAT128): Handle IFmode.
14963
14964 2018-06-04 Richard Sandiford <richard.sandiford@linaro.org>
14965
14966 * expr.c (expand_expr_real_1): Force the operand into memory if
14967 its TYPE_MODE is BLKmode and if there is no integer mode for
14968 the number of bits being extracted.
14969
14970 2018-06-04 Jakub Jelinek <jakub@redhat.com>
14971
14972 PR target/85832
14973 PR target/86036
14974 * config/i386/sse.md (<avx512>_eq<mode>3<mask_scalar_merge_name>_1):
14975 Use vptestnm rather than vptestm in (=Yc,v,C) variant.
14976
14977 2018-06-04 Richard Biener <rguenther@suse.de>
14978
14979 * tree-cfgcleanup.c (cleanup_tree_cfg_1): Fold into...
14980 (cleanup_tree_cfg_noloop): ... single caller. Do
14981 start_recording_case_labels later.
14982
14983 2018-06-04 Sebastian Peryt <sebastian.peryt@intel.com>
14984
14985 * config/i386/cldemoteintrin.h: Change define from _X86INTRIN_H_INCLUDED
14986 to _IMMINTRIN_H_INCLUDED.
14987 * config/i386/pconfigintrin.h: Ditto.
14988 * config/i386/waitpkgintrin.h: Ditto.
14989 * config/i386/immintrin.h: Add includes for sgxintrin.h,
14990 pconfigintrin.h, waitpkgintrin.h and cldemoteintrin.h.
14991 * config/i386/x86intrin.h: Remove includes for mintrin.h, xmmintrin.h,
14992 emmintrin.h, pmmintrin.h, tmmintrin.h, smmintrin.h, wmmintrin.h,
14993 bmiintrin.h, bmi2intrin.h, lzcntintrin.h, sgxintrin.h, pconfigintrin.h,
14994 waitpkgintrin.h and cldemoteintrin.h.
14995
14996 2018-06-04 Richard Biener <rguenther@suse.de>
14997
14998 PR tree-optimization/86038
14999 * tracer.c (find_best_successor): Check probability for
15000 being initialized, bail out if not.
15001
15002 2018-06-04 Richard Earnshaw <rearnsha@arm.com>
15003
15004 PR target/86003
15005 * config/arm/arm-cpus.in (ALL_QUIRKS): Add xscale feature to the list
15006 of bits to ignore when comparing architectures.
15007
15008 2018-06-04 Jakub Jelinek <jakub@redhat.com>
15009
15010 PR tree-optimization/69615
15011 * fold-const.c (merge_ranges): If range1 is - [x, x] and x is the
15012 maximum or minimum of the type, try to merge it also as if
15013 range1 is + [-, x - 1] or + [x + 1, -].
15014
15015 PR c++/86025
15016 * tree.c (inchash::add_expr): Handle IDENTIFIER_NODE.
15017
15018 2018-06-03 Eric Botcazou <ebotcazou@adacore.com>
15019
15020 PR tree-optimization/86034
15021 * gimple-ssa-store-merging.c (output_merged_store): Convert the RHS to
15022 the unsigned bitfield type in a bit insertion sequence if it does not
15023 have a larger precision than the bitfield size.
15024 (process_store): Also bypass widening conversions for BIT_INSERT_EXPR.
15025
15026 2018-06-03 Kito Cheng <kito.cheng@gmail.com>
15027
15028 * config/nds32/nds32-peephole2.md: Add new patterns for code size.
15029
15030 2018-06-03 Chung-Ju Wu <jasonwucj@gmail.com>
15031
15032 * config/nds32/nds32-opts.h (nds32_arch_type): Add ARCH_V3J.
15033 * config/nds32/nds32.c (nds32_option_override): Consider ARCH_V3J.
15034 * config/nds32/nds32.h (TARGET_ISA_V3): Add ARCH_V3J checking.
15035 * config/nds32/nds32.opt (march): Add enum value Value(ARCH_V3J).
15036
15037 2018-06-03 Chung-Ju Wu <jasonwucj@gmail.com>
15038
15039 * common/config/nds32/nds32-common.c (nds32_option_optimization_table):
15040 Disable -fdelete-null-pointer-checks for ELF toolchain.
15041
15042 2018-06-02 Chung-Ju Wu <jasonwucj@gmail.com>
15043 Kito Cheng <kito.cheng@gmail.com>
15044
15045 * config.gcc (nds32*): Use nds32-linux.opt and nds32-elf.opt.
15046 (nds32le-*-*, nds32be-*-*): Integrate checking process.
15047 (nds32*-*-*): Add glibc and uclibc conditions.
15048 * common/config/nds32/nds32-common.c (nds32_except_unwind_info): New.
15049 (TARGET_EXCEPT_UNWIND_INFO): Define.
15050 * config/nds32/elf.h: New file.
15051 * config/nds32/linux.h: New file.
15052 * config/nds32/nds32-elf.opt: New file.
15053 * config/nds32/nds32-linux.opt: New file.
15054 * config/nds32/nds32-fp-as-gp.c
15055 (pass_nds32_fp_as_gp::gate): Consider TARGET_LINUX_ABI.
15056 * config/nds32/nds32.c (nds32_conditional_register_usage): Consider
15057 TARGET_LINUX_ABI.
15058 (nds32_asm_file_end): Ditto.
15059 (nds32_print_operand): Ditto.
15060 (nds32_insert_attributes): Ditto.
15061 (nds32_init_libfuncs): New function.
15062 (TARGET_HAVE_TLS): Define.
15063 (TARGET_INIT_LIBFUNCS): Define.
15064 * config/nds32/nds32.h (TARGET_DEFAULT_RELAX): Apply different relax
15065 spec content.
15066 (TARGET_ELF): Apply different mcmodel setting.
15067 (LINK_SPEC, LIB_SPEC, STARTFILE_SPEC, ENDFILE_SPEC): The content has
15068 been migrated into elf.h and linux.h files.
15069 * config/nds32/nds32.md (add_pc): Consider TARGET_LINUX_ABI.
15070 * config/nds32/nds32.opt (mvh): Consider TARGET_LINUX_ABI.
15071 (mcmodel): The content has been migrated into nds32-elf.opt and
15072 nds32-linux.opt files.
15073 * config/nds32/t-elf: New file.
15074 * config/nds32/t-linux: New file.
15075
15076 2018-06-02 Chung-Ju Wu <jasonwucj@gmail.com>
15077 Shiva Chen <shiva0217@gmail.com>
15078
15079 * config/nds32/constants.md (unspec_volatile_element): Add
15080 UNSPEC_VOLATILE_OMIT_FP_BEGIN and UNSPEC_VOLATILE_OMIT_FP_END.
15081 * config/nds32/nds32-fp-as-gp.c: New implementation of fp_as_gp
15082 optimization.
15083 * config/nds32/nds32-protos.h (nds32_naked_function_p): Declare.
15084 (make_pass_nds32_fp_as_gp): Declare.
15085 * config/nds32/nds32.c (nds32_register_passes): Add fp_as_gp as one
15086 optmization pass.
15087 (nds32_asm_function_end_prologue): Remove unused asm output.
15088 (nds32_asm_function_begin_epilogue): Remove unused asm output.
15089 (nds32_asm_file_start): Output necessary fp_as_gp information.
15090 (nds32_option_override): Adjust register usage.
15091 (nds32_expand_prologue): Consider fp_as_gp situation.
15092 (nds32_expand_prologue_v3push): Consider fp_as_gp situation.
15093 * config/nds32/nds32.md (prologue): Check fp_as_gp_p and naked_p.
15094 (epilogue): Ditto.
15095 (return): Ditto.
15096 (simple_return): Ditto.
15097 (omit_fp_begin): Output special directive for fp_as_gp.
15098 (omit_fp_end): Output special directive for fp_as_gp.
15099 * config/nds32/nds32.opt (mfp-as-gp, mno-fp-as-gp, mforce-fp-as-gp,
15100 mforbid-fp-as-gp): New options.
15101
15102 2018-06-01 Mark Wielaard <mark@klomp.org>
15103
15104 * dwarf2out.c (dwarf2out_finish): Remove generation of
15105 DW_AT_loclists_base.
15106
15107 2018-06-01 Eric Botcazou <ebotcazou@adacore.com>
15108
15109 * gimple-ssa-store-merging.c: Include gimple-fold.h.
15110 (struct store_immediate_info): Document BIT_INSERT_EXPR stores.
15111 (struct merged_store_group): Add bit_insertion field.
15112 (dump_char_array): Use standard hexadecimal format.
15113 (merged_store_group::merged_store_group): Set bit_insertion to false.
15114 (merged_store_group::apply_stores): Use optimal buffer size. Deal
15115 with BIT_INSERT_EXPR stores. Move up code updating the mask and
15116 also print the mask in the dump file.
15117 (pass_store_merging::gate): Minor tweak.
15118 (imm_store_chain_info::coalesce_immediate): Fix wrong association
15119 of stores with groups in dump. Allow coalescing of BIT_INSERT_EXPR
15120 stores with INTEGER_CST stores.
15121 (count_multiple_uses) <BIT_INSERT_EXPR>: New case.
15122 (imm_store_chain_info::output_merged_store): Add try_bitpos variable
15123 and use it throughout. Generate bit insertion sequences if need be.
15124 (pass_store_merging::process_store): Remove redundant condition.
15125 Record stores from a SSA name to a bit-field with BIT_INSERT_EXPR.
15126
15127 2018-06-01 Segher Boessenkool <segher@kernel.crashing.org>
15128
15129 * config/rs6000/rs6000.c (rs6000_mangle_type): Change the mangling of
15130 the 128-bit floating point types. Fix function comment.
15131
15132 2018-06-01 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
15133
15134 * config/aarch64/aarch64-simd.md
15135 (aarch64_simd_vec_unpack<su>_lo_<mode>): Use UXTL and SXTL assembler
15136 mnemonics.
15137 (aarch64_simd_vec_unpack<su>_hi_<mode>): Use UXTL2 and SXTL2 assembler
15138 mnemonics.
15139
15140 2018-06-01 Richard Sandiford <richard.sandiford@linaro.org>
15141
15142 PR tree-optimization/85989
15143 * gimple-ssa-backprop.c (backprop::m_visited_phis): New member
15144 variable.
15145 (backprop::intersect_uses): Check it when deciding whether this
15146 is a backedge reference.
15147 (backprop::process_block): Add each phi to m_visited_phis
15148 after visiting it, then clear it at the end.
15149
15150 2018-06-01 Richard Biener <rguenther@suse.de>
15151
15152 * tree-vectorizer.h (vect_dr_stmt): New function.
15153 (vect_get_load_cost): Adjust.
15154 (vect_get_store_cost): Likewise.
15155 * tree-vect-data-refs.c (vect_analyze_data_ref_dependence):
15156 Use vect_dr_stmt instead of DR_SMTT.
15157 (vect_record_base_alignments): Likewise.
15158 (vect_calculate_target_alignment): Likewise.
15159 (vect_compute_data_ref_alignment): Likewise and make static.
15160 (vect_update_misalignment_for_peel): Likewise.
15161 (vect_verify_datarefs_alignment): Likewise.
15162 (vector_alignment_reachable_p): Likewise.
15163 (vect_get_data_access_cost): Likewise. Pass down
15164 vinfo to vect_get_load_cost/vect_get_store_cost instead of DR.
15165 (vect_get_peeling_costs_all_drs): Likewise.
15166 (vect_peeling_hash_get_lowest_cost): Likewise.
15167 (vect_enhance_data_refs_alignment): Likewise.
15168 (vect_find_same_alignment_drs): Likewise.
15169 (vect_analyze_data_refs_alignment): Likewise.
15170 (vect_analyze_group_access_1): Likewise.
15171 (vect_analyze_group_access): Likewise.
15172 (vect_analyze_data_ref_access): Likewise.
15173 (vect_analyze_data_ref_accesses): Likewise.
15174 (vect_vfa_segment_size): Likewise.
15175 (vect_small_gap_p): Likewise.
15176 (vectorizable_with_step_bound_p): Likewise.
15177 (vect_prune_runtime_alias_test_list): Likewise.
15178 (vect_analyze_data_refs): Likewise.
15179 (vect_supportable_dr_alignment): Likewise.
15180 * tree-vect-loop-manip.c (get_misalign_in_elems): Likewise.
15181 (vect_gen_prolog_loop_niters): Likewise.
15182 * tree-vect-loop.c (vect_analyze_loop_2): Likewise.
15183 * tree-vect-patterns.c (vect_recog_bool_pattern): Do not
15184 modify DR_STMT.
15185 (vect_recog_mask_conversion_pattern): Likewise.
15186 (vect_try_gather_scatter_pattern): Likewise.
15187 * tree-vect-stmts.c (vect_model_store_cost): Pass stmt_info
15188 to vect_get_store_cost.
15189 (vect_get_store_cost): Get stmt_info instead of DR.
15190 (vect_model_load_cost): Pass stmt_info to vect_get_load_cost.
15191 (vect_get_load_cost): Get stmt_info instead of DR.
15192
15193 2018-06-01 Richard Biener <rguenther@suse.de>
15194
15195 PR middle-end/86017
15196 * gimple-fold.c (var_decl_component_p): Also allow offsetted
15197 vars wrapped in MEM_REFs.
15198
15199 2018-06-01 Richard Sandiford <richard.sandiford@linaro.org>
15200
15201 * config/aarch64/aarch64.c (aarch64_ira_change_pseudo_allocno_class):
15202 Fix subreg tests so that we only return a choice between
15203 GENERAL_REGS and FP_REGS if the original classes included both.
15204
15205 2018-06-01 Richard Biener <rguenther@suse.de>
15206
15207 PR ipa/85960
15208 * tree-ssa-structalias.c (get_function_part_constraint):
15209 Handle NULL fi->decl.
15210 (find_func_aliases_for_call): Properly handle indirect
15211 fi from direct call.
15212 (find_func_clobbers): Likewise.
15213 (ipa_pta_execute): Likewise.
15214 (create_variable_info_for): For functions that are ifunc_resolver
15215 resolve to a varinfo that contains the result of the resolver call.
15216 (associate_varinfo_to_alias): Do not treat ifunc resolvers as
15217 aliases.
15218
15219 2018-05-31 Michael Collison <michael.collison@arm.com>
15220
15221 * config/aarch64/aarch64.md:
15222 (*fix_to_zero_extenddfdi2): New pattern.
15223 * gcc.target/aarch64/fix_extend1.c: New testcase.
15224
15225 2018-05-31 Qing Zhao <qing.zhao@oracle.com>
15226
15227 PR middle-end/78809
15228 PR middle-end/83026
15229 * builtins.c (expand_builtin): Add the handling of BUILT_IN_STRCMP_EQ
15230 and BUILT_IN_STRNCMP_EQ.
15231 * builtins.def: Add new builtins BUILT_IN_STRCMP_EQ and
15232 BUILT_IN_STRNCMP_EQ.
15233 * gimple-fold.c (gimple_fold_builtin_string_compare): Add the
15234 handling of BUILTIN_IN_STRCMP_EQ and BUILT_IN_STRNCMP_EQ.
15235 (gimple_fold_builtin): Likewise.
15236 * tree-ssa-strlen.c (compute_string_length): New function.
15237 (determine_min_obsize): New function.
15238 (handle_builtin_string_cmp): New function to handle calls to
15239 string compare functions.
15240 (strlen_optimize_stmt): Add handling to builtin string compare
15241 calls.
15242 * tree-ssa-structalias.c (find_func_aliases_for_builtin_call):
15243 Add the handling of BUILT_IN_STRCMP_EQ and BUILT_IN_STRNCMP_EQ.
15244 * tree.c (build_common_builtin_nodes): Add new defines of
15245 BUILT_IN_STRNCMP_EQ and BUILT_IN_STRCMP_EQ.
15246
15247 2018-05-31 Jakub Jelinek <jakub@redhat.com>
15248
15249 PR target/85984
15250 * bb-reorder.c (pass_partition_blocks::gate): Return false for
15251 functions with naked attribute.
15252
15253 2018-05-31 Uros Bizjak <ubizjak@gmail.com>
15254
15255 * config/i386/sse.md (avx_vec_concat<mode>):
15256 Substitute concat_tg_mode mode attribute with xtg_mode.
15257 (<mask_codefor>avx512dq_broadcast<mode><mask_name>_1): Ditto.
15258 (concat_tg_mode): Remove mode attribute.
15259
15260 2018-05-31 Martin Sebor <msebor@redhat.com>
15261
15262 PR c/82063
15263 * calls.c (alloc_max_size): Correct a logic error/typo.
15264 Treat excessive arguments as infinite. Warn for invalid arguments.
15265 * doc/invoke.texi (-Walloc-size-larger-than): Update.
15266
15267 2018-05-31 H.J. Lu <hongjiu.lu@intel.com>
15268
15269 PR target/85829
15270 * config/i386/x86-tune.def: Re-enable partial_reg_dependency
15271 and movx for Haswell.
15272
15273 2018-05-31 Chung-Lin Tang <cltang@codesourcery.com>
15274 Cesar Philippidis <cesar@codesourcery.com>
15275
15276 PR middle-end/85879
15277 * gimplify.c (gimplify_adjust_omp_clauses): Add 'remove = true'
15278 when emitting error on private/firstprivate reductions.
15279 * omp-low.c (lower_omp_target): Avoid reference-type processing
15280 on pointers for firstprivate clause.
15281
15282 2018-05-31 Sameera Deshpande <sameera.deshpande@linaro.org>
15283
15284 * config/aarch64/aarch64-simd-builtins.def (ld1x3): New.
15285 (st1x2): Likewise.
15286 (st1x3): Likewise.
15287 * config/aarch64/aarch64-simd.md
15288 (aarch64_ld1x3<VALLDIF:mode>): New pattern.
15289 (aarch64_ld1_x3_<mode>): Likewise
15290 (aarch64_st1x2<VALLDIF:mode>): Likewise
15291 (aarch64_st1_x2_<mode>): Likewise
15292 (aarch64_st1x3<VALLDIF:mode>): Likewise
15293 (aarch64_st1_x3_<mode>): Likewise
15294 * config/aarch64/arm_neon.h (vld1_u8_x3): New function.
15295 (vld1_s8_x3): Likewise.
15296 (vld1_u16_x3): Likewise.
15297 (vld1_s16_x3): Likewise.
15298 (vld1_u32_x3): Likewise.
15299 (vld1_s32_x3): Likewise.
15300 (vld1_u64_x3): Likewise.
15301 (vld1_s64_x3): Likewise.
15302 (vld1_f16_x3): Likewise.
15303 (vld1_f32_x3): Likewise.
15304 (vld1_f64_x3): Likewise.
15305 (vld1_p8_x3): Likewise.
15306 (vld1_p16_x3): Likewise.
15307 (vld1_p64_x3): Likewise.
15308 (vld1q_u8_x3): Likewise.
15309 (vld1q_s8_x3): Likewise.
15310 (vld1q_u16_x3): Likewise.
15311 (vld1q_s16_x3): Likewise.
15312 (vld1q_u32_x3): Likewise.
15313 (vld1q_s32_x3): Likewise.
15314 (vld1q_u64_x3): Likewise.
15315 (vld1q_s64_x3): Likewise.
15316 (vld1q_f16_x3): Likewise.
15317 (vld1q_f32_x3): Likewise.
15318 (vld1q_f64_x3): Likewise.
15319 (vld1q_p8_x3): Likewise.
15320 (vld1q_p16_x3): Likewise.
15321 (vld1q_p64_x3): Likewise.
15322 (vst1_s64_x2): Likewise.
15323 (vst1_u64_x2): Likewise.
15324 (vst1_f64_x2): Likewise.
15325 (vst1_s8_x2): Likewise.
15326 (vst1_p8_x2): Likewise.
15327 (vst1_s16_x2): Likewise.
15328 (vst1_p16_x2): Likewise.
15329 (vst1_s32_x2): Likewise.
15330 (vst1_u8_x2): Likewise.
15331 (vst1_u16_x2): Likewise.
15332 (vst1_u32_x2): Likewise.
15333 (vst1_f16_x2): Likewise.
15334 (vst1_f32_x2): Likewise.
15335 (vst1_p64_x2): Likewise.
15336 (vst1q_s8_x2): Likewise.
15337 (vst1q_p8_x2): Likewise.
15338 (vst1q_s16_x2): Likewise.
15339 (vst1q_p16_x2): Likewise.
15340 (vst1q_s32_x2): Likewise.
15341 (vst1q_s64_x2): Likewise.
15342 (vst1q_u8_x2): Likewise.
15343 (vst1q_u16_x2): Likewise.
15344 (vst1q_u32_x2): Likewise.
15345 (vst1q_u64_x2): Likewise.
15346 (vst1q_f16_x2): Likewise.
15347 (vst1q_f32_x2): Likewise.
15348 (vst1q_f64_x2): Likewise.
15349 (vst1q_p64_x2): Likewise.
15350 (vst1_s64_x3): Likewise.
15351 (vst1_u64_x3): Likewise.
15352 (vst1_f64_x3): Likewise.
15353 (vst1_s8_x3): Likewise.
15354 (vst1_p8_x3): Likewise.
15355 (vst1_s16_x3): Likewise.
15356 (vst1_p16_x3): Likewise.
15357 (vst1_s32_x3): Likewise.
15358 (vst1_u8_x3): Likewise.
15359 (vst1_u16_x3): Likewise.
15360 (vst1_u32_x3): Likewise.
15361 (vst1_f16_x3): Likewise.
15362 (vst1_f32_x3): Likewise.
15363 (vst1_p64_x3): Likewise.
15364 (vst1q_s8_x3): Likewise.
15365 (vst1q_p8_x3): Likewise.
15366 (vst1q_s16_x3): Likewise.
15367 (vst1q_p16_x3): Likewise.
15368 (vst1q_s32_x3): Likewise.
15369 (vst1q_s64_x3): Likewise.
15370 (vst1q_u8_x3): Likewise.
15371 (vst1q_u16_x3): Likewise.
15372 (vst1q_u32_x3): Likewise.
15373 (vst1q_u64_x3): Likewise.
15374 (vst1q_f16_x3): Likewise.
15375 (vst1q_f32_x3): Likewise.
15376 (vst1q_f64_x3): Likewise.
15377 (vst1q_p64_x3): Likewise.
15378
15379 2018-05-30 Jozef Lawrynowicz <jozef.l@mittosystems.com>
15380
15381 * config/msp430/msp430.c (msp430_output_labelref): Prepend
15382 user_label_prefix to name.
15383
15384 * tree-core.h: Update comment about the format of NAME string
15385 passed to handler in attribute_spec.
15386
15387 * config/msp430/msp430.md: Remove erroneous subreg expression from
15388 zero_extendqisi2 insn pattern. Remove msp430x ISA restriction on
15389 zero_extend{q,h}isi2.
15390
15391 2018-05-30 Borislav Petkov <bp@suse.de>
15392
15393 * doc/extend.texi: Document some architecture specific
15394 constraints and sort entries.
15395
15396 2018-05-30 Martin Sebor <msebor@redhat.com>
15397
15398 PR middle-end/85369
15399 * builtins.c (expand_builtin_stpcpy_1): New function.
15400 (expand_builtin_stpcpy): Call it, and call maybe_warn_nonstring_arg
15401 only if the former succeeds.
15402
15403 2018-05-31 Sameera Deshpande <sameera.deshpande@linaro.org>
15404
15405 * config/aarch64/aarch64-cores.def (saphira) : Add support for ARMv8.4
15406 in saphira.
15407
15408 2018-05-30 Jan Hubicka <hubicka@ucw.cz>
15409
15410 * doc/invoke.texi (-flinker-output): Document
15411
15412 2018-05-30 Jan Hubicka <hubicka@ucw.cz>
15413
15414 * passes.c (ipa_write_summaries): Only modify statements if body
15415 is in memory.
15416 * cgraphunit.c (ipa_passes): Also produce intermeidate code when
15417 incrementally linking.
15418 (ipa_passes): Likewise.
15419 * lto-cgraph.c (lto_output_node): When incrementally linking do not
15420 pass down resolution info.
15421 * common.opt (flag_incremental_link): Update info.
15422 * gcc.c (plugin specs): Turn flinker-output=* to
15423 -plugin-opt=-linker-output-known
15424 * toplev.c (compile_file): Also cut compilation when doing incremental
15425 link.
15426 * flag-types. (enum lto_partition_model): Add
15427 LTO_LINKER_OUTPUT_NOLTOREL.
15428 (invoke.texi): Add -flinker-output docs.
15429 * ipa.c (symbol_table::remove_unreachable_nodes): Handle LTO incremental
15430 link same way as WPA; do not stream in dead initializers.
15431
15432 * dwarf2out.c (dwarf2out_die_ref_for_decl,
15433 darf2out_register_external_decl): Support incremental link.
15434
15435 2018-05-30 Jan Hubicka <hubicka@ucw.cz>
15436
15437 * lto-opts.c (lto_write_options): Skip OPT_dumpdir, OPT_fresolution_.
15438
15439 2018-05-30 Jan Hubicka <hubicka@ucw.cz>
15440
15441 * lto-wrapper.c (debug_objcopy): Add rename parameter; pass
15442 it down to simple_object_copy_lto_debug_sections.
15443 (run_gcc): Determine incremental LTO link time and configure
15444 lto1 into non-wpa mode, disable renaming of debug sections.
15445
15446 2018-05-30 Kelvin Nilsen <kelvin@gcc.gnu.org>
15447
15448 * doc/extend.texi (PowerPC AltiVec Built-in Functions): Remove
15449 descriptions of various incorrectly documented functions.
15450
15451 2018-05-30 Andre Vieira <andre.simoesdiasvieira@arm.com>
15452
15453 Revert:
15454 * config/aarch64/predicates.md (aarch64_mem_pair_lanes_operand): Make
15455 address check not strict.
15456
15457 2018-05-30 Richard Biener <rguenther@suse.de>
15458
15459 PR tree-optimization/85964
15460 * tracer.c (better_p): Drop initialized count check, we only
15461 call the function with initialized counts now.
15462 (find_best_successor): Do find a best edge if one
15463 has uninitialized count.
15464 (find_best_predecessor): Likewise. Do BB frequency check only
15465 if count is initialized.
15466
15467 2017-05-30 Jackson Woodruff <jackson.woodruff@arm.com>
15468
15469 * config/aarch64/aarch64.c (aarch64_host_wide_int_compare): New.
15470 (aarch64_ldrstr_offset_compare): New.
15471 (aarch64_operands_adjust_ok_for_ldpstp): Update to consider all
15472 load/store orderings.
15473 (aarch64_gen_adjusted_ldpstp): Likewise.
15474
15475 2018-05-30 Wilco Dijkstra <wdijkstr@arm.com>
15476
15477 * config/aarch64/aarch64.c (aarch64_ira_change_pseudo_allocno_class):
15478 Check for subset of GENERAL_REGS and FP_REGS.
15479 * config/aarch64/aarch64-simd.md (aarch64_get_lane): Increase cost of
15480 r=w alternative.
15481
15482 2018-05-30 Richard Sandiford <richard.sandiford@linaro.org>
15483
15484 * alias.c (adjust_offset_for_component_ref): Use poly_int_tree_p
15485 and wi::to_poly_offset. Add the current offset and then check
15486 whether the sum fits, rather than using an unchecked addition of
15487 a checked term. Check for a shwi rather than a uhwi.
15488 * expr.c (get_bit_range): Use tree_to_poly_uint64.
15489 (store_constructor): Use poly_int_tree_p.
15490 (expand_expr_real_1): Likewise.
15491 * function.c (assign_temp): Likewise.
15492 * fold-const.c (const_binop): Use poly_int_tree_p and
15493 wi::to_poly_offset.
15494 (fold_indirect_ref_1): Likewise. Use multiple_p to attempt an exact
15495 division.
15496 * ipa-icf-gimple.c (func_checker::compare_operand): Use
15497 to_poly_offset for MEM offsets.
15498 * ipa-icf.c (sem_variable::equals): Likewise.
15499 * stor-layout.c (compute_record_mode): Use poly_int_tree_p.
15500 * tree-ssa-sccvn.c (ao_ref_init_from_vn_reference): Use
15501 wi::to_poly_offset for BIT_FIELD_REF offsets.
15502 (vn_reference_maybe_forwprop_address): Use poly_int_tree_p and
15503 wi::to_poly_offset.
15504 * var-tracking.c (emit_note_insn_var_location): Use
15505 tree_to_poly_uint64.
15506
15507 2018-05-29 Jim Wilson <jimw@sifive.com>
15508
15509 * config/riscv/riscv.c (riscv_interrupt_type): Fix comment typo.
15510
15511 2018-05-29 Uros Bizjak <ubizjak@gmail.com>
15512
15513 PR target/85950
15514 * config/i386/i386.md (l<rounding_insn><MODEF:mode><SWI48:mode>2):
15515 Enable for TARGET_SSE4_1 and generate rounds{s,d} and cvtts{s,d}2si{,q}
15516 sequence.
15517 (sse4_1_round<mode>2): Use nonimmediate_operand
15518 for operand 1 predicate.
15519
15520 2018-05-29 Martin Sebor <msebor@redhat.com>
15521 Richard Biener <rguenther@suse.de>
15522
15523 PR testsuite/85888
15524 * calls.c (get_size_range): Call determine_value_range instead
15525 of get_value_range..
15526 * tree-vrp.h (determine_value_range): Declared new function.
15527 * tree-vrp.c (determine_value_range_1, determine_value_range): New.
15528
15529 2018-05-29 Richard Biener <rguenther@suse.de>
15530
15531 * tree-vect-data-refs.c (vect_preserves_scalar_order_p): Make
15532 sure to use non-pattern stmts for get_earlier_stmt arguments.
15533 * tree-vectorizer.h (get_earlier_stmt): Assert we do not get
15534 called on pattern stmts.
15535 (get_later_stmt): Likewise.
15536
15537 2018-05-29 Martin Liska <mliska@suse.cz>
15538
15539 PR gcov-profile/85759
15540 * doc/gcov.texi: Document GCOV_ERROR_FILE and GCOV_EXIT_AT_ERROR
15541 env variables.
15542
15543 2018-05-29 Jakub Jelinek <jakub@redhat.com>
15544
15545 * tree-cfg.c (verify_gimple_assign_unary): Add checking for
15546 VEC_UNPACK_*_EXPR.
15547 (verify_gimple_assign_binary): Check TYPE_VECTOR_SUBPARTS for
15548 VEC_PACK_*_EXPR.
15549
15550 PR target/85918
15551 * tree.def (VEC_UNPACK_FIX_TRUNC_HI_EXPR, VEC_UNPACK_FIX_TRUNC_LO_EXPR,
15552 VEC_PACK_FLOAT_EXPR): New tree codes.
15553 * tree-pretty-print.c (op_code_prio): Handle
15554 VEC_UNPACK_FIX_TRUNC_HI_EXPR and VEC_UNPACK_FIX_TRUNC_LO_EXPR.
15555 (dump_generic_node): Handle VEC_UNPACK_FIX_TRUNC_HI_EXPR,
15556 VEC_UNPACK_FIX_TRUNC_LO_EXPR and VEC_PACK_FLOAT_EXPR.
15557 * tree-inline.c (estimate_operator_cost): Likewise.
15558 * gimple-pretty-print.c (dump_binary_rhs): Handle VEC_PACK_FLOAT_EXPR.
15559 * fold-const.c (const_binop): Likewise.
15560 (const_unop): Handle VEC_UNPACK_FIX_TRUNC_HI_EXPR and
15561 VEC_UNPACK_FIX_TRUNC_LO_EXPR.
15562 * tree-cfg.c (verify_gimple_assign_unary): Likewise.
15563 (verify_gimple_assign_binary): Handle VEC_PACK_FLOAT_EXPR.
15564 * cfgexpand.c (expand_debug_expr): Handle VEC_UNPACK_FIX_TRUNC_HI_EXPR,
15565 VEC_UNPACK_FIX_TRUNC_LO_EXPR and VEC_PACK_FLOAT_EXPR.
15566 * expr.c (expand_expr_real_2): Likewise.
15567 * optabs.def (vec_packs_float_optab, vec_packu_float_optab,
15568 vec_unpack_sfix_trunc_hi_optab, vec_unpack_sfix_trunc_lo_optab,
15569 vec_unpack_ufix_trunc_hi_optab, vec_unpack_ufix_trunc_lo_optab): New
15570 optabs.
15571 * optabs.c (expand_widen_pattern_expr): For
15572 VEC_UNPACK_FIX_TRUNC_HI_EXPR and VEC_UNPACK_FIX_TRUNC_LO_EXPR use
15573 sign from result type rather than operand's type.
15574 (expand_binop_directly): For vec_packu_float_optab and
15575 vec_packs_float_optab allow result type to be different from operand's
15576 type.
15577 * optabs-tree.c (optab_for_tree_code): Handle
15578 VEC_UNPACK_FIX_TRUNC_HI_EXPR, VEC_UNPACK_FIX_TRUNC_LO_EXPR and
15579 VEC_PACK_FLOAT_EXPR. Formatting fixes.
15580 * tree-vect-generic.c (expand_vector_operations_1): Handle
15581 VEC_UNPACK_FIX_TRUNC_HI_EXPR, VEC_UNPACK_FIX_TRUNC_LO_EXPR and
15582 VEC_PACK_FLOAT_EXPR.
15583 * tree-vect-stmts.c (supportable_widening_operation): Handle
15584 FIX_TRUNC_EXPR.
15585 (supportable_narrowing_operation): Handle FLOAT_EXPR.
15586 * config/i386/i386.md (fixprefix, floatprefix): New code attributes.
15587 * config/i386/sse.md (*float<floatunssuffix>v2div2sf2): Rename to ...
15588 (float<floatunssuffix>v2div2sf2): ... this. Formatting fix.
15589 (vpckfloat_concat_mode, vpckfloat_temp_mode, vpckfloat_op_mode): New
15590 mode attributes.
15591 (vec_pack<floatprefix>_float_<mode>): New expander.
15592 (vunpckfixt_mode, vunpckfixt_model, vunpckfixt_extract_mode): New mode
15593 attributes.
15594 (vec_unpack_<fixprefix>fix_trunc_lo_<mode>,
15595 vec_unpack_<fixprefix>fix_trunc_hi_<mode>): New expanders.
15596 * doc/md.texi (vec_packs_float_@var{m}, vec_packu_float_@var{m},
15597 vec_unpack_sfix_trunc_hi_@var{m}, vec_unpack_sfix_trunc_lo_@var{m},
15598 vec_unpack_ufix_trunc_hi_@var{m}, vec_unpack_ufix_trunc_lo_@var{m}):
15599 Document.
15600 * doc/generic.texi (VEC_UNPACK_FLOAT_HI_EXPR,
15601 VEC_UNPACK_FLOAT_LO_EXPR): Fix pasto in description.
15602 (VEC_UNPACK_FIX_TRUNC_HI_EXPR, VEC_UNPACK_FIX_TRUNC_LO_EXPR,
15603 VEC_PACK_FLOAT_EXPR): Document.
15604
15605 2018-05-29 Richard Biener <rguenther@suse.de>
15606
15607 * tree-vectorizer.h (struct vec_info): Add stmt_vec_infos
15608 member.
15609 (stmt_vec_info_vec): Make pointer.
15610 (init_stmt_vec_info_vec): Remove.
15611 (free_stmt_vec_info_vec): Likewise.
15612 (set_stmt_vec_info_vec): New function.
15613 (free_stmt_vec_infos): Likewise.
15614 (vinfo_for_stmt): Adjust for stmt_vec_info_vec indirection.
15615 (set_vinfo_for_stmt): Likewise.
15616 (get_earlier_stmt): Likewise.
15617 (get_later_stmt): Likewise.
15618 * tree-vectorizer.c (stmt_vec_info_vec): Make pointer.
15619 (vec_info::vec_info): Allocate stmt_vec_infos and set the global.
15620 (vec_info::~vec_info): Free stmt_vec_infos.
15621 (vectorize_loops): Set the global stmt_vec_info_vec to NULL.
15622 Remove old init_stmt_vec_info_vec/free_stmt_vec_info_vec calls.
15623 (pass_slp_vectorize::execute): Likewise.
15624 * tree-vect-stmts.c (init_stmt_vec_info_vec): Remove.
15625 (free_stmt_vec_info_vec): Likewise.
15626 (set_stmt_vec_info_vec): New function.
15627 (free_stmt_vec_infos): Likewise.
15628 * tree-vect-loop.c (_loop_vec_info::~_loop_vec_info): Set
15629 the global stmt_vec_info_vec.
15630 * tree-parloops.c (gather_scalar_reductions): Use
15631 set_stmt_vec_info_vec/free_stmt_vec_infos and maintain a local
15632 vector.
15633
15634 2018-05-29 Richard Biener <rguenther@suse.de>
15635
15636 * dominance.c (iterate_fix_dominators): Push/pop TV_DOMINANCE.
15637
15638 2018-05-29 Martin Liska <mliska@suse.cz>
15639 David Malcolm <dmalcolm@redhat.com>
15640
15641 * vec.c (test_reverse): New.
15642 (vec_c_tests): Add new test.
15643 * vec.h (vl_ptr>::reverse): New function.
15644
15645 2018-05-29 Gerald Pfeifer <gerald@pfeifer.com>
15646
15647 * config.gcc: Identify FreeBSD 3.x and 4.x as unsupported.
15648
15649 * config/freebsd-spec.h (FBSD_LIB_SPEC): Only consider FreeBSD 5
15650 and later.
15651
15652 2018-05-28 Bernd Edlinger <bernd.edlinger@hotmail.de>
15653
15654 * tree-dump.c (dump_node): Use splay_tree_delete_pointers.
15655
15656 2018-05-28 Richard Biener <rguenther@suse.de>
15657
15658 PR tree-optimization/85933
15659 * tree-vect-data-refs.c (vect_record_base_alignments): Only
15660 look at stmts marked as vectorizable.
15661
15662 2018-05-28 Richard Biener <rguenther@suse.de>
15663
15664 PR tree-optimization/85934
15665 * tree-vect-generic.c (expand_vector_operations_1): Hoist
15666 vector boolean check before scalar optimization.
15667
15668 2018-05-28 Jakub Jelinek <jakub@redhat.com>
15669
15670 * doc/invoke.texi (ARM Options): Use @item instead of @itemx
15671 for armv5te.
15672
15673 2018-05-28 Mark Wielaard <mark@klomp.org>
15674
15675 * dwarf2asm.c (dw2_asm_output_delta_uleb128): Add brackets around lab2
15676 if it is an expression containing a minus sign.
15677
15678 2018-05-27 John David Anglin <danglin@gcc.gnu.org>
15679
15680 * config/pa/pa-linux.h (NEED_INDICATE_EXEC_STACK): Define to 0.
15681
15682 2018-05-27 Paul Koning <ni1d@arrl.net>
15683
15684 * config/pdp11/pdp11.md (truncsihi2): Remove.
15685
15686 2018-05-27 Monk Chiang <sh.chiang04@gmail.com>
15687 Chung-Ju Wu <jasonwucj@gmail.com>
15688
15689 * config/nds32/nds32-intrinsic.md (unaligned_storedi): Modify patterns
15690 implementation.
15691 (unaligned_store_dw): Ditto.
15692 * config/nds32/nds32-memory-manipulation.c
15693 (nds32_expand_movmemsi_loop_known_size): Refactoring implementation.
15694 (nds32_gen_dup_4_byte_to_word_value): Rename to ...
15695 (nds32_gen_dup_4_byte_to_word_value_aux): ... this.
15696 (emit_setmem_word_loop): Rename to ...
15697 (emit_setmem_doubleword_loop): ... this.
15698 (nds32_gen_dup_4_byte_to_word_value): New function.
15699 (nds32_gen_dup_8_byte_to_double_word_value): New function.
15700 (nds32_expand_setmem_loop): Refine implementation.
15701 (nds32_expand_setmem_loop_v3m): Ditto.
15702 * config/nds32/nds32-multiple.md (unaligned_store_update_base_dw): New
15703 pattern.
15704
15705 2018-05-27 Chung-Ju Wu <jasonwucj@gmail.com>
15706
15707 * config/nds32/nds32.md (bswapsi2, bswaphi2): New patterns.
15708
15709 2018-05-27 Chung-Ju Wu <jasonwucj@gmail.com>
15710
15711 * config/nds32/nds32.c (nds32_attribute_table): Add "no_prologue".
15712 (nds32_init_machine_status): Initialize machine->attr_naked_p and
15713 machine->attr_no_prologue_p.
15714 (nds32_compute_stack_frame): Check "naked" and "no_prologue" attributes.
15715 (nds32_naked_function_p): Handle "naked" and "no_prologue" attributes.
15716 (nds32_expand_epilogue): Consider attr_naked_p.
15717 (nds32_expand_epilogue_v3pop): Likewise.
15718 (nds32_can_use_return_insn): Likewise.
15719 * config/nds32/nds32.h (machine_function): Add attr_naked_p and
15720 attr_no_prologue_p fields.
15721 * config/nds32/nds32.opt (mret-in-naked-func): New option.
15722
15723 2018-05-27 Jakub Jelinek <jakub@redhat.com>
15724
15725 PR target/85918
15726 * config/i386/i386.md (fixunssuffix, floatunssuffix): New code
15727 attributes.
15728 * config/i386/sse.md
15729 (<floatsuffix>float<sseintvecmodelower><mode>2<mask_name><round_name>):
15730 Rename to ...
15731 (float<floatunssuffix><sseintvecmodelower><mode>2<mask_name><round_name>):
15732 ... this.
15733 (<floatsuffix>float<sselongvecmodelower><mode>2<mask_name><round_name>):
15734 Rename to ...
15735 (float<floatunssuffix><sselongvecmodelower><mode>2<mask_name><round_name>):
15736 ... this.
15737 (*<floatsuffix>floatv2div2sf2): Rename to ...
15738 (*float<floatunssuffix>v2div2sf2): ... this.
15739 (<floatsuffix>floatv2div2sf2_mask): Rename to ...
15740 (float<floatunssuffix>v2div2sf2_mask): ... this.
15741 (*<floatsuffix>floatv2div2sf2_mask_1): Rename to ...
15742 (*float<floatunssuffix>v2div2sf2_mask_1): ... this.
15743 (<fixsuffix>fix_truncv8dfv8si2<mask_name><round_saeonly_name>): Rename
15744 to ...
15745 (fix<fixunssuffix>_truncv8dfv8si2<mask_name><round_saeonly_name>):
15746 ... this.
15747 (<fixsuffix>fix_trunc<mode><sseintvecmodelower>2<mask_name><round_saeonly_name>):
15748 Rename to ...
15749 (fix<fixunssuffix>_trunc<mode><sseintvecmodelower>2<mask_name><round_saeonly_name>):
15750 ... this.
15751 (<fixsuffix>fix_trunc<mode><sselongvecmodelower>2<mask_name><round_saeonly_name>):
15752 Rename to ...
15753 (fix<fixunssuffix>_trunc<mode><sselongvecmodelower>2<mask_name><round_saeonly_name>):
15754 ... this.
15755 (<fixsuffix>fix_truncv2sfv2di2<mask_name>): Rename to ...
15756 (fix<fixunssuffix>_truncv2sfv2di2<mask_name>): ... this.
15757 (vec_pack_ufix_trunc_<mode>): Use gen_fixuns_truncv8dfv8si2 instead of
15758 gen_ufix_truncv8dfv8si2.
15759 * config/i386/i386-builtin.def (__builtin_ia32_cvttpd2uqq256_mask,
15760 __builtin_ia32_cvttpd2uqq128_mask, __builtin_ia32_cvttps2uqq256_mask,
15761 __builtin_ia32_cvttps2uqq128_mask, __builtin_ia32_cvtuqq2ps256_mask,
15762 __builtin_ia32_cvtuqq2ps128_mask, __builtin_ia32_cvtuqq2pd256_mask,
15763 __builtin_ia32_cvtuqq2pd128_mask, __builtin_ia32_cvttpd2udq512_mask,
15764 __builtin_ia32_cvtuqq2ps512_mask, __builtin_ia32_cvtuqq2pd512_mask,
15765 __builtin_ia32_cvttps2uqq512_mask, __builtin_ia32_cvttpd2uqq512_mask):
15766 Use fixuns instead ufix or floatuns instead ufloat in CODE_FOR_ names.
15767
15768 2018-05-24 H.J. Lu <hongjiu.lu@intel.com>
15769
15770 PR target/85900
15771 PR target/85345
15772 * varasm.c (assemble_alias): Lookup ifunc attribute on error.
15773
15774 2018-05-25 Jim Wilson <jimw@sifive.com>
15775
15776 * config/riscv/riscv-protos.h (riscv_epilogue_uses): New.
15777 * config/riscv/riscv.c (struct machine_function): Add
15778 interrupt_handler_p and attribute_checked_p fields.
15779 (riscv_attribute_table): Add interrupt.
15780 (riscv_interrupt_type_p): New.
15781 (riscv_save_reg_p): Save extra regs for interrupt handler.
15782 (riscv_use_save_libcall): Return false for interrupt handler.
15783 (riscv_first_stack_step): Add forward declaration.
15784 (riscv_compute_frame_info): New local interrupt_save_t1. Set it
15785 for interrupt handler with large frame. Use it for saved reg list.
15786 (riscv_expand_prologue): Move flag_stack_usage_info support to
15787 eliminate duplication.
15788 (riscv_expand_epilogue): Generate mret for interrupt handler.
15789 (riscv_epilogue_uses): New.
15790 (riscv_can_use_return_insn): Return false for interrupt handler.
15791 (riscv_function_ok_for_sibcall): Likewise.
15792 (riscv_set_current_function): Add interrupt handler support.
15793 * config/riscv/riscv.h (EPILOGUE_USES): Call riscv_epilogue_uses.
15794 * config/riscv/riscv.md (UNSPECV_MRET): New.
15795 (GP_REGNUM): New.
15796 (riscv_frflags, riscv_fsflags): Use tab after opcode.
15797 (riscv_mret): New.
15798 * doc/extend.texi (RISC-V Function Attributes) <interrupt>: New.
15799
15800 2018-05-25 Bill Schmidt <wschmidt@linux.ibm.com>
15801
15802 PR tree-optimization/85712
15803 * gimple-ssa-strength-reduction.c (replace_one_candidate): Skip if
15804 this candidate has already been replaced in-situ by a copy.
15805
15806 2018-05-25 Jason Merrill <jason@redhat.com>
15807
15808 PR c++/80485 - inline function non-zero address.
15809 * symtab.c (nonzero_address): Check DECL_COMDAT.
15810
15811 2018-05-25 Uros Bizjak <ubizjak@gmail.com>
15812
15813 PR target/83628
15814 * config/alpha/alpha.md (ashlsi3): New insn pattern.
15815 (*ashlsi_se): Rename from *ashldi_se. Define as sign
15816 extension of SImode operation. Use const123_operand predicate.
15817 (*saddsi_1): Remove.
15818 (*saddl_se_1): Ditto.
15819 (*ssubsi_1): Ditto.
15820 (*ssubl_se_1): Ditto.
15821 * config/alpha/predicates.md (const123_operand): New predicate.
15822 * config/alpha/constraints.md (P): Use IN_RANGE.
15823
15824 2018-05-25 Richard Biener <rguenther@suse.de>
15825
15826 * tree-ssa-alias.h (refs_may_alias_p): Add tbaa_p bool parameter,
15827 defaulted to true.
15828 (ref_maybe_used_by_stmt_p): Likewise.
15829 (stmt_may_clobber_ref_p): Likewise.
15830 (stmt_may_clobber_ref_p_1): Likewise.
15831 * tree-ssa-alias.c (refs_may_alias_p): Add tbaa_p bool parameter
15832 and pass it along.
15833 (ref_maybe_used_by_stmt_p): Likewise.
15834 (stmt_may_clobber_ref_p): Likewise.
15835 (stmt_may_clobber_ref_p_1): Likewise.
15836 * tree-vect-data-refs.c (vect_slp_analyze_node_dependences): Use
15837 the alias oracle to disambiguate DRs with stmts DR analysis
15838 couldn't handle.
15839 (vect_analyze_data_refs): Do not give up on not analyzable
15840 DRs for BB vectorization. Remove code truncating the dataref
15841 vector.
15842
15843 2018-05-25 Jakub Jelinek <jakub@redhat.com>
15844
15845 PR target/85832
15846 * config/i386/sse.md (<avx512>_eq<mode>3<mask_scalar_merge_name>_1):
15847 Add (=Yk,v,C) variant using vptestm insn. Use TARGET_AVX512BW
15848 in test instead of TARGET_AVX512F for VI12_AVX512VL iterator.
15849
15850 2018-05-25 Richard Biener <rguenther@suse.de>
15851
15852 * tree-vect-data-refs.c (vect_find_stmt_data_reference): New
15853 function, combining stmt data ref gathering and fatal analysis
15854 parts.
15855 (vect_analyze_data_refs): Remove now redudnant code and simplify.
15856 * tree-vect-loop.c (vect_get_datarefs_in_loop): Factor out from
15857 vect_analyze_loop_2 and use vect_find_stmt_data_reference.
15858 * tree-vect-slp.c (vect_slp_bb): Use vect_find_stmt_data_reference.
15859 * tree-vectorizer.h (vect_find_stmt_data_reference): Declare.
15860
15861 2018-05-25 Bin Cheng <bin.cheng@arm.com>
15862
15863 PR tree-optimization/85720
15864 * tree-loop-distribution.c (break_alias_scc_partitions): Don't merge
15865 SCC if all partitions are builtins.
15866 (version_loop_by_alias_check): New parameter. Generate cancelable
15867 runtime alias check if all partitions are builtins.
15868 (distribute_loop): Update call to above function.
15869
15870 2018-05-25 Bin Cheng <bin.cheng@arm.com>
15871
15872 * tree-outof-ssa.c (tree-ssa.h, tree-dfa.h): Include header files.
15873 (create_default_def, for_all_parms): Moved from tree-ssa-coalesce.c.
15874 (parm_default_def_partition_arg): Ditto.
15875 (set_parm_default_def_partition): Ditto.
15876 (get_parm_default_def_partitions): Ditto and make it static.
15877 (get_undefined_value_partitions): Ditto and make it static.
15878 (remove_ssa_form): Refactor call to init_var_map here.
15879 * tree-ssa-coalesce.c (build_ssa_conflict_graph): Support live range
15880 computation for loop region.
15881 (coalesce_partitions, compute_optimized_partition_bases): Ditto.
15882 (register_default_def): Delete.
15883 (for_all_parms, create_default_def): Move to tree-outof-ssa.c.
15884 (parm_default_def_partition_arg): Ditto.
15885 (set_parm_default_def_partition): Ditto.
15886 (get_parm_default_def_partitions): Ditto and make it static.
15887 (get_undefined_value_partitions): Ditto and make it static.
15888 (coalesce_with_default, coalesce_with_default): Update comment.
15889 (create_coalesce_list_for_region): New func factored out from
15890 create_outofssa_var_map.
15891 (populate_coalesce_list_for_outofssa): New func factored out from
15892 create_outofssa_var_map and coalesce_ssa_name.
15893 (create_outofssa_var_map): Delete.
15894 (coalesce_ssa_name): Refactor to support live range computation.
15895 * tree-ssa-coalesce.h (coalesce_ssa_name): Change decl.
15896 (get_parm_default_def_partitions): Delete.
15897 (get_undefined_value_partitions): Ditto.
15898 * tree-ssa-live.c (init_var_map, delete_var_map): Support live range
15899 computation for loop region.
15900 (new_tree_live_info, loe_visit_block): Ditto.
15901 (live_worklist, set_var_live_on_entry): Ditto.
15902 (calculate_live_on_exit, verify_live_on_entry): Ditto.
15903 * tree-ssa-live.h (struct _var_map): New fields.
15904 (init_var_map): Change decl.
15905 (region_contains_p): New.
15906
15907 2018-05-25 Bin Cheng <bin.cheng@arm.com>
15908
15909 * tree-ssa-live.h (live_merge_and_clear): Delete.
15910
15911 2018-05-25 Richard Biener <rguenther@suse.de>
15912
15913 PR c++/85912
15914 * tree-dump.c (dequeue_and_dump): Remove access to removed
15915 operand 2 of a SWITCH_EXPR.
15916
15917 2018-05-25 Richard Sandiford <richard.sandiford@linaro.org>
15918
15919 * doc/sourcebuild.texi (vect_double_cond_arith): Include
15920 multiplication and division.
15921 * doc/md.texi (cond_mul@var{m}, cond_div@var{m}, cond_mod@var{m})
15922 (cond_udiv@var{m}, cond_umod@var{m}): Document.
15923 * optabs.def (cond_smul_optab, cond_sdiv_optab, cond_smod_optab)
15924 (cond_udiv_optab, cond_umod_optab): New optabs.
15925 * internal-fn.def (IFN_COND_MUL, IFN_COND_DIV, IFN_COND_MOD)
15926 (IFN_COND_RDIV): New internal functions.
15927 * internal-fn.c (get_conditional_internal_fn): Handle TRUNC_DIV_EXPR,
15928 TRUNC_MOD_EXPR and RDIV_EXPR.
15929 * match.pd (UNCOND_BINARY, COND_BINARY): Handle them.
15930 * config/aarch64/iterators.md (UNSPEC_COND_MUL, UNSPEC_COND_DIV):
15931 New unspecs.
15932 (SVE_INT_BINARY): Include mult.
15933 (SVE_COND_FP_BINARY): Include UNSPEC_MUL and UNSPEC_DIV.
15934 (optab, sve_int_op): Handle mult.
15935 (optab, sve_fp_op, commutative): Handle UNSPEC_COND_MUL and
15936 UNSPEC_COND_DIV.
15937 * config/aarch64/aarch64-sve.md (cond_<optab><mode>): New pattern
15938 for SVE_INT_BINARY_SD.
15939
15940 2018-05-25 Richard Sandiford <richard.sandiford@linaro.org>
15941
15942 * config/aarch64/iterators.md (SVE_INT_BINARY_SD): New code iterator.
15943 (optab, sve_int_op): Handle div and udiv.
15944 * config/aarch64/aarch64-sve.md (<optab><mode>3): New expander
15945 for SVE_INT_BINARY_SD.
15946 (*<optab><mode>3): New insn for the same.
15947
15948 2018-05-25 Richard Sandiford <richard.sandiford@linaro.org>
15949
15950 * tree-vect-patterns.c: Include predict.h.
15951 (vect_recog_divmod_pattern): Restrict check for division support
15952 to when optimizing for size.
15953
15954 2018-05-25 Richard Sandiford <richard.sandiford@linaro.org>
15955
15956 * doc/sourcebuild.texi (vect_double_cond_arith: Document.
15957 * gimple-match.h (gimple_match_op::MAX_NUM_OPS): Bump to 4.
15958 (gimple_match_op::gimple_match_op): Add an overload for 4 operands.
15959 (gimple_match_op::set_op): Likewise.
15960 (gimple_resimplify4): Declare.
15961 * genmatch.c (get_operand_type): Handle CFN_COND_* functions.
15962 (expr::gen_transform): Likewise.
15963 (decision_tree::gen): Generate a simplification routine for 4 operands.
15964 * gimple-match-head.c (gimple_simplify): Add an overload for
15965 4 operands. In the top-level function, handle up to 4 call
15966 arguments and call gimple_resimplify4.
15967 (gimple_resimplify4): New function.
15968 (build_call_internal): Pass a fourth operand.
15969 (maybe_push_to_seq): Likewise.
15970 * match.pd (UNCOND_BINARY, COND_BINARY): New operator lists.
15971 Fold VEC_COND_EXPRs of an operation and a default value into
15972 an IFN_COND_* function if possible.
15973 * config/aarch64/iterators.md (UNSPEC_COND_MAX, UNSPEC_COND_MIN):
15974 New unspecs.
15975 (SVE_COND_FP_BINARY): Include them.
15976 (optab, sve_fp_op): Handle them.
15977 (SVE_INT_BINARY_REV): New code iterator.
15978 (SVE_COND_FP_BINARY_REV): New int iterator.
15979 (commutative): New int attribute.
15980 * config/aarch64/aarch64-protos.h (aarch64_sve_prepare_conditional_op):
15981 Declare.
15982 * config/aarch64/aarch64.c (aarch64_sve_prepare_conditional_op): New
15983 function.
15984 * config/aarch64/aarch64-sve.md (cond_<optab><mode>): Use it.
15985 (*cond_<optab><mode>): New patterns for reversed operands.
15986
15987 2018-05-25 Richard Biener <rguenther@suse.de>
15988
15989 * tree-vectorizer.h (STMT_VINFO_GROUP_*, GROUP_*): Remove.
15990 (DR_GROUP_*): New, assert we have non-NULL ->data_ref_info.
15991 (REDUC_GROUP_*): New, assert we have NULL ->data_ref_info.
15992 (STMT_VINFO_GROUPED_ACCESS): Adjust.
15993 * tree-vect-data-refs.c (everywhere): Adjust users.
15994 * tree-vect-loop.c (everywhere): Likewise.
15995 * tree-vect-slp.c (everywhere): Likewise.
15996 * tree-vect-stmts.c (everywhere): Likewise.
15997 * tree-vect-patterns.c (vect_reassociating_reduction_p): Likewise.
15998
15999 2018-05-25 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
16000
16001 * configure.ac (gcc_cv_as_section_has_e): Move to common section.
16002 Rename to...
16003 (gcc_cv_as_section_exclude): ... this.
16004 Try Solaris as #exclude syntax.
16005 * configure: Regenerate.
16006 * config.in: Regenerate.
16007 * config/i386/i386.c (i386_solaris_elf_named_section): Handle
16008 SECTION_EXCLUDE.
16009 * config/sparc/sparc.c (sparc_solaris_elf_asm_named_section)
16010 [HAVE_GAS_SECTION_EXCLUDE]: Handle SECTION_EXCLUDE.
16011
16012 * varasm.c (default_elf_asm_named_section): Don't check if
16013 HAVE_GAS_SECTION_EXCLUDE is defined.
16014
16015 2018-05-25 Richard Sandiford <richard.sandiford@linaro.org>
16016
16017 * doc/md.texi: Update the documentation of the cond_* optabs
16018 to mention the new final operand. Fix GET_MODE_NUNITS call.
16019 Describe the scalar case too.
16020 * internal-fn.def (IFN_EXTRACT_LAST): Change type to fold_left.
16021 * internal-fn.c (expand_cond_unary_optab_fn): Expect 3 operands
16022 instead of 2.
16023 (expand_cond_binary_optab_fn): Expect 4 operands instead of 3.
16024 (get_conditional_internal_fn): Update comment.
16025 * tree-vect-loop.c (vectorizable_reduction): Pass the original
16026 accumulator value as a final argument to conditional functions.
16027 * config/aarch64/aarch64-sve.md (cond_<optab><mode>): Turn into
16028 a define_expand and add an "else" operand. Assert for now that
16029 the else operand is equal to operand 2. Use SVE_INT_BINARY and
16030 SVE_COND_FP_BINARY instead of SVE_COND_INT_OP and SVE_COND_FP_OP.
16031 (*cond_<optab><mode>): New patterns.
16032 * config/aarch64/iterators.md (UNSPEC_COND_SMAX, UNSPEC_COND_UMAX)
16033 (UNSPEC_COND_SMIN, UNSPEC_COND_UMIN, UNSPEC_COND_AND, UNSPEC_COND_ORR)
16034 (UNSPEC_COND_EOR): Delete.
16035 (optab): Remove associated mappings.
16036 (SVE_INT_BINARY): New code iterator.
16037 (sve_int_op): Remove int attribute and add "minus" to the code
16038 attribute.
16039 (SVE_COND_INT_OP): Delete.
16040 (SVE_COND_FP_OP): Rename to...
16041 (SVE_COND_FP_BINARY): ...this.
16042
16043 2018-05-25 Richard Sandiford <richard.sandiford@linaro.org>
16044
16045 * optabs.c (can_reuse_operands_p): New function.
16046 (maybe_legitimize_operands): Try to reuse the results for
16047 earlier operands.
16048
16049 2018-05-24 Uros Bizjak <ubizjak@gmail.com>
16050
16051 * config/i386/sse.md (cvtusi2<ssescalarmodesuffix>64<round_name>):
16052 Add {q} suffix to insn mnemonic.
16053
16054 2018-05-23 Jozef Lawrynowicz <jozef.l@mittosystems.com>
16055
16056 * config/msp430/msp430.c (TARGET_WARN_FUNC_RETURN): Define.
16057 (msp430_warn_func_return): New.
16058
16059 2018-05-24 Roger Sayle <roger@nextmovesoftware.com>
16060
16061 * fold-const.c (tree_nonzero_bits): New function.
16062 * fold-const.h (tree_nonzero_bits): Likewise.
16063 * match.pd (POPCOUNT): New patterns to fold BUILTIN_POPCOUNT and
16064 friends. POPCOUNT(x&1) => x&1, POPCOUNT(x)==0 => x==0, etc.
16065
16066 2018-05-24 H.J. Lu <hongjiu.lu@intel.com>
16067
16068 PR target/85900
16069 PR target/85345
16070 * varasm.c (assemble_alias): Check ifunc_resolver only on
16071 FUNCTION_DECL.
16072
16073 2018-05-24 Uros Bizjak <ubizjak@gmail.com>
16074
16075 PR target/85903
16076 * config/i386/sse.md (movdi_to_sse): Do not generate pseudo
16077 when memory input operand is handled.
16078
16079 2018-05-24 Luis Machado <luis.machado@linaro.org>
16080
16081 * config/aarch64/aarch64.c (qdf24xx_addrcost_table): New static
16082 global.
16083 (qdf24xx_tunings) <addr_costs>: Set to qdf24xx_addrcost_table.
16084
16085 2018-05-24 Richard Sandiford <richard.sandiford@linaro.org>
16086
16087 * match.pd: Delay FMA folds until after vectorization.
16088
16089 2018-05-24 Andre Vieira <andre.simoesdiasvieira@arm.com>
16090
16091 PR target/83009
16092 * config/aarch64/predicates.md (aarch64_mem_pair_lanes_operand): Make
16093 address check not strict.
16094
16095 2018-05-24 Richard Sandiford <richard.sandiford@linaro.org>
16096
16097 * gimple-match.h (gimple_match_op): New class.
16098 (mprts_hook): Replace parameters with a gimple_match_op *.
16099 (maybe_build_generic_op): Likewise.
16100 (gimple_simplified_result_is_gimple_val): Replace parameters with
16101 a const gimple_match_op *.
16102 (gimple_simplify): Replace code_helper * and tree * parameters with
16103 a gimple_match_op * parameter.
16104 (gimple_resimplify1): Replace code_helper *, tree and tree *
16105 parameters with a gimple_match_op * parameter.
16106 (gimple_resimplify2): Likewise.
16107 (gimple_resimplify3): Likewise.
16108 (maybe_push_res_to_seq): Replace code_helper, tree and tree *
16109 parameters with a gimple_match_op * parameter.
16110 * gimple-match-head.c (gimple_simplify): Change prototypes of
16111 auto-generated functions to take a gimple_match_op * instead of
16112 separate code_helper * and tree * parameters. Make the same
16113 change in the top-level overload and update calls to the
16114 gimple_resimplify routines. Update calls to the auto-generated
16115 functions and to maybe_push_res_to_seq in the publicly-facing
16116 operation-specific gimple_simplify overloads.
16117 (gimple_match_op::MAX_NUM_OPS): Define.
16118 (gimple_resimplify1): Replace rcode and ops with a single res_op
16119 parameter. Update call to gimple_simplify.
16120 (gimple_resimplify2): Likewise.
16121 (gimple_resimplify3): Likewise.
16122 (mprts_hook): Replace parameters with a gimple_match_op *.
16123 (maybe_build_generic_op): Likewise.
16124 (build_call_internal): Replace type, nargs and ops with
16125 a gimple_match_op *.
16126 (maybe_push_res_to_seq): Replace res_code, type and ops parameters
16127 with a single gimple_match_op *. Update calls to mprts_hook,
16128 build_call_internal and gimple_simplified_result_is_gimple_val.
16129 Factor out code that is common to the tree_code and combined_fn cases.
16130 * genmatch.c (expr::gen_transform): Replace tem_code and
16131 tem_ops with a gimple_match_op called tem_op. Update calls
16132 to the gimple_resimplify functions and maybe_push_res_to_seq.
16133 (dt_simplify::gen_1): Manipulate res_op instead of res_code and
16134 res_ops. Update call to the gimple_resimplify functions.
16135 (dt_simplify::gen): Pass res_op instead of res_code and res_ops.
16136 (decision_tree::gen): Make the functions take a gimple_match_op *
16137 called res_op instead of separate res_code and res_ops parameters.
16138 Update call accordingly.
16139 * gimple-fold.c (replace_stmt_with_simplification): Replace rcode
16140 and ops with a single res_op parameter. Update calls to
16141 maybe_build_generic_op and maybe_push_res_to_seq.
16142 (fold_stmt_1): Update calls to gimple_simplify and
16143 replace_stmt_with_simplification.
16144 (gimple_fold_stmt_to_constant_1): Update calls to gimple_simplify
16145 and gimple_simplified_result_is_gimple_val.
16146 * tree-cfgcleanup.c (cleanup_control_expr_graph): Update call to
16147 gimple_simplify.
16148 * tree-ssa-sccvn.c (vn_lookup_simplify_result): Replace parameters
16149 with a gimple_match_op *.
16150 (vn_nary_build_or_lookup): Likewise. Update call to
16151 vn_nary_build_or_lookup_1.
16152 (vn_nary_build_or_lookup_1): Replace rcode, type and ops with a
16153 gimple_match_op *. Update calls to the gimple_resimplify routines
16154 and to gimple_simplified_result_is_gimple_val.
16155 (vn_nary_simplify): Update call to vn_nary_build_or_lookup_1.
16156 Use gimple_match_op::MAX_NUM_OPS instead of a hard-coded 3.
16157 (vn_reference_lookup_3): Update call to vn_nary_build_or_lookup.
16158 (visit_nary_op): Likewise.
16159 (visit_reference_op_load): Likewise.
16160
16161 2018-05-23 Luis Machado <luis.machado@linaro.org>
16162
16163 * tree-ssa-loop-prefetch.c (should_issue_prefetch_p): Use correct type
16164 modifier for printing the step amount.
16165
16166 2018-05-23 Jozef Lawrynowicz <jozef.l@somniumtech.com>
16167
16168 PR target/78849
16169 * tree.c (build_common_tree_nodes): Dont set TYPE_SIZE for __intN
16170 types.
16171
16172 2018-05-23 Segher Boessenkool <segher@kernel.crashing.org>
16173
16174 * doc/sourcebuild.texi (Endianness): New subsubsection.
16175
16176 2018-05-23 Luis Machado <luis.machado@linaro.org>
16177
16178 * config/aarch64/aarch64-protos.h (cpu_prefetch_tune)
16179 <prefetch_dynamic_strides>: New const bool field.
16180 * config/aarch64/aarch64.c (generic_prefetch_tune): Update to include
16181 prefetch_dynamic_strides.
16182 (exynosm1_prefetch_tune): Likewise.
16183 (thunderxt88_prefetch_tune): Likewise.
16184 (thunderx_prefetch_tune): Likewise.
16185 (thunderx2t99_prefetch_tune): Likewise.
16186 (qdf24xx_prefetch_tune): Likewise. Set prefetch_dynamic_strides to
16187 false.
16188 (aarch64_override_options_internal): Update to set
16189 PARAM_PREFETCH_DYNAMIC_STRIDES.
16190 * doc/invoke.texi (prefetch-dynamic-strides): Document new option.
16191 * params.def (PARAM_PREFETCH_DYNAMIC_STRIDES): New.
16192 * params.h (PARAM_PREFETCH_DYNAMIC_STRIDES): Define.
16193 * tree-ssa-loop-prefetch.c (should_issue_prefetch_p): Account for
16194 prefetch-dynamic-strides setting.
16195
16196 2018-05-23 Luis Machado <luis.machado@linaro.org>
16197
16198 * config/aarch64/aarch64-protos.h (cpu_prefetch_tune)
16199 <minimum_stride>: New const int field.
16200 * config/aarch64/aarch64.c (generic_prefetch_tune): Update to include
16201 minimum_stride field defaulting to -1.
16202 (exynosm1_prefetch_tune): Likewise.
16203 (thunderxt88_prefetch_tune): Likewise.
16204 (thunderx_prefetch_tune): Likewise.
16205 (thunderx2t99_prefetch_tune): Likewise.
16206 (qdf24xx_prefetch_tune) <minimum_stride>: Set to 2048.
16207 <default_opt_level>: Set to 3.
16208 (aarch64_override_options_internal): Update to set
16209 PARAM_PREFETCH_MINIMUM_STRIDE.
16210 * doc/invoke.texi (prefetch-minimum-stride): Document new option.
16211 * params.def (PARAM_PREFETCH_MINIMUM_STRIDE): New.
16212 * params.h (PARAM_PREFETCH_MINIMUM_STRIDE): Define.
16213 * tree-ssa-loop-prefetch.c (should_issue_prefetch_p): Return false if
16214 stride is constant and is below the minimum stride threshold.
16215
16216 2018-05-23 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
16217
16218 * config/arm/arm-cpus.in (mode26): Delete.
16219 (armv4): Delete mode26 reference.
16220 * config/arm/arm.c (arm_configure_build_target): Delete use of
16221 isa_bit_mode26.
16222
16223 2018-05-23 Uros Bizjak <ubizjak@gmail.com>
16224
16225 * config/i386/i386.md (*floatuns<SWI48:mode><MODEF:mode>2_avx512):
16226 New insn pattern.
16227 (floatunssi<mode>2): Also enable for AVX512F and TARGET_SSE_MATH.
16228 Rewrite expander pattern. Emit gen_floatunssi<mode>2_i387_with_xmm
16229 for non-SSE modes.
16230 (floatunsdisf2): Rewrite expander pattern. Hanlde TARGET_AVX512F.
16231 (floatunsdidf2): Ditto.
16232
16233 2018-05-23 Uros Bizjak <ubizjak@gmail.com>
16234
16235 * config/i386/i386.md (fixuns_trunc<mode>di2): New insn pattern.
16236 (fixuns_trunc<mode>si2_avx512f): Ditto.
16237 (*fixuns_trunc<mode>si2_avx512f_zext): Ditto.
16238 (fixuns_trunc<mode>si2): Also enable for AVX512F and TARGET_SSE_MATH.
16239 Emit fixuns_trunc<mode>si2_avx512f for AVX512F targets.
16240
16241 2018-05-23 Alexander Monakov <amonakov@ispras.ru>
16242
16243 PR rtl-optimization/79985
16244 * df-scan.c (df_insn_refs_collect): Remove special case for
16245 global registers and asm statements.
16246
16247 2018-05-23 Alexander Monakov <amonakov@ispras.ru>
16248
16249 * extend.texi (Global Register Variables): Rewrite the bullet list.
16250 Note that the register is available for allocation. Note that access
16251 via inline asm must use constraints. Add note about async-signal
16252 handlers. Remove paragraph about automagic register selection.
16253
16254 2018-05-23 Richard Biener <rguenther@suse.de>
16255
16256 * tree-ssa-sccvn.c (vn_reference_lookup_3): Remove restriction
16257 of fixed offset from memset VN.
16258
16259 2018-05-23 Bill Schmidt <wschmidt@linux.ibm.com>
16260
16261 * gimple-ssa-strength-reduction.c (struct slsr_cand_d): Add
16262 first_interp field.
16263 (alloc_cand_and_find_basis): Initialize first_interp field.
16264 (slsr_process_mul): Modify first_interp field.
16265 (slsr_process_add): Likewise.
16266 (slsr_process_cast): Modify first_interp field for each new
16267 interpretation.
16268 (slsr_process_copy): Likewise.
16269 (dump_candidate): Dump first_interp field.
16270 (replace_mult_candidate): Process all interpretations, not just
16271 subsequent ones.
16272 (replace_rhs_if_not_dup): Likewise.
16273 (replace_one_candidate): Likewise.
16274
16275 2018-05-23 Wilco Dijkstra <wdijkstr@arm.com>
16276
16277 * config/aarch64/aarch64.c (aarch64_use_frame_pointer):
16278 Add new boolean.
16279 (aarch64_needs_frame_chain): New function.
16280 (aarch64_parse_override_string): Set aarch64_use_frame_pointer.
16281
16282 2018-05-23 Sudakshina Das <sudi.das@arm.com>
16283
16284 PR target/84882
16285 * common/config/aarch64/aarch64-common.c (aarch64_handle_option):
16286 Check val before adding MASK_STRICT_ALIGN to opts->x_target_flags.
16287 * config/aarch64/aarch64.opt (mstrict-align): Remove RejectNegative.
16288 * config/aarch64/aarch64.c (aarch64_attributes): Mark allow_neg
16289 as true for strict-align.
16290 (aarch64_can_inline_p): Perform checks even when callee has no
16291 attributes to check for strict alignment.
16292 * doc/extend.texi (AArch64 Function Attributes): Document
16293 no-strict-align.
16294 * doc/invoke.texi: (AArch64 Options): Likewise.
16295
16296 2018-05-23 Richard Sandiford <richard.sandiford@linaro.org>
16297
16298 PR tree-optimization/85853
16299 * tree-vect-slp.c (vect_slp_analyze_node_operations): Split out
16300 the handling of the root of the node to...
16301 (vect_slp_analyze_node_operations_1): ...this new function,
16302 and run the whole thing with the child nodes' def types
16303 set according to their SLP node's def type.
16304
16305 2018-05-23 Richard Biener <rguenther@suse.de>
16306
16307 PR middle-end/85874
16308 * tree-data-ref.c (create_runtime_alias_checks): Defer
16309 and ignore overflow warnings.
16310
16311 2018-05-23 Yury Gribov <tetra2005@gmail.com>
16312
16313 PR tree-optimization/85822
16314 * tree-vrp.c (is_masked_range_test): Fix handling of negative
16315 constants.
16316
16317 2018-05-23 Richard Biener <rguenther@suse.de>
16318
16319 * tree-ssa-sccvn.c (vn_reference_lookup_3): Handle arbitrary
16320 memset constants via native_interpret_expr.
16321
16322 2018-05-22 H.J. Lu <hongjiu.lu@intel.com>
16323
16324 PR target/85345
16325 * cgraph.h (cgraph_node::create): Set ifunc_resolver for ifunc
16326 attribute.
16327 (cgraph_node::create_alias): Likewise.
16328 (cgraph_node::get_availability): Check ifunc_resolver instead
16329 of looking up ifunc attribute.
16330 * cgraphunit.c (maybe_diag_incompatible_alias): Likewise.
16331 * varasm.c (do_assemble_alias): Likewise.
16332 (assemble_alias): Likewise.
16333 (default_binds_local_p_3): Likewise.
16334 * cgraph.h (cgraph_node): Add ifunc_resolver.
16335 (cgraph_node::only_called_directly_or_aliased_p): Return false
16336 for IFUNC resolver.
16337 * lto-cgraph.c (input_node): Set ifunc_resolver for ifunc
16338 attribute.
16339 * symtab.c (symtab_node::verify_base): Verify that ifunc_resolver
16340 is equivalent to lookup_attribute ("ifunc", DECL_ATTRIBUTES (decl)).
16341 (symtab_node::binds_to_current_def_p): Check ifunc_resolver
16342 instead of looking up ifunc attribute.
16343
16344 2018-05-22 Luis Machado <luis.machado@linaro.org>
16345
16346 * config/aarch64/aarch64.md (*ashift<mode>_extv_bfiz): New pattern.
16347
16348 2018-05-22 Martin Sebor <msebor@redhat.com>
16349
16350 PR middle-end/85359
16351 * builtins.c (expand_builtin_strcpy): Call maybe_warn_nonstring_arg
16352 only when expasion succeeds.
16353 (expand_builtin_strcmp): Same.
16354 (expand_builtin_strncmp): Same.
16355
16356 2018-05-22 Martin Sebor <msebor@redhat.com>
16357
16358 * calls.c (maybe_warn_nonstring_arg): Fix a typo in a comment.
16359
16360 2018-05-22 Jackson Woodruff <jackson.woodruff@arm.com>
16361 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
16362
16363 * config/aarch64/aarch64-ldpstp.md: Replace uses of
16364 aarch64_mem_pair_operand with memory_operand and delete operand swapping
16365 code.
16366 * config/aarch64/aarch64.c (aarch64_operands_ok_for_ldpstp):
16367 Add check for legitimate_address.
16368 (aarch64_gen_adjusted_ldpstp): Swap operands where appropriate.
16369 (aarch64_swap_ldrstr_operands): New.
16370 * config/aarch64/aarch64-protos.h (aarch64_swap_ldrstr_operands):
16371 Define prototype.
16372
16373 2018-05-22 Jackson Woodruff <jackson.woodruff@arm.com>
16374 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
16375
16376 * config/aarch64/aarch64.md: New patterns to generate stp
16377 and ldp.
16378 (store_pair_sw, store_pair_dw): New patterns to generate stp for
16379 single words and double words.
16380 (load_pair_sw, load_pair_dw): Likewise.
16381 (store_pair_sf, store_pair_df, store_pair_si, store_pair_di):
16382 Delete.
16383 (load_pair_sf, load_pair_df, load_pair_si, load_pair_di):
16384 Delete.
16385 * config/aarch64/aarch64-ldpstp.md: Modify peephole
16386 for different mode ldpstp and add peephole for merged zero stores.
16387 Likewise for loads.
16388 * config/aarch64/aarch64.c (aarch64_operands_ok_for_ldpstp):
16389 Add size check.
16390 (aarch64_gen_store_pair): Rename calls to match new patterns.
16391 (aarch64_gen_load_pair): Rename calls to match new patterns.
16392 * config/aarch64/aarch64-simd.md (load_pair<mode>): Rename to...
16393 (load_pair<DREG:mode><DREG2:mode>): ... This.
16394 (store_pair<mode>): Rename to...
16395 (vec_store_pair<DREG:mode><DREG2:mode>): ... This.
16396 * config/aarch64/iterators.md (DREG, DREG2, DX2, SX, SX2, DSX):
16397 New mode iterators.
16398 (V_INT_EQUIV): Handle SImode.
16399 * config/aarch64/predicates.md (aarch64_reg_zero_or_fp_zero):
16400 New predicate.
16401
16402 2018-05-22 Martin Sebor <msebor@redhat.com>
16403
16404 PR c/85623
16405 * calls.c (maybe_warn_nonstring_arg): Use string length to set
16406 or ajust the presumed bound on an operation to avoid unnecessary
16407 warnings.
16408
16409 2018-05-22 Martin Sebor <msebor@redhat.com>
16410
16411 PR tree-optimization/85826
16412 * gimple-ssa-warn-restrict.c (builtin_memref::builtin_memref): Avoid
16413 assuming that a DECL necesarily has a constant size.
16414
16415 2018-05-22 Richard Sandiford <richard.sandiford@linaro.org>
16416
16417 PR middle-end/85862
16418 * internal-fn.c (expand_direct_optab_fn): Cope with a null lhs.
16419
16420 2018-05-22 Richard Biener <rguenther@suse.de>
16421
16422 PR tree-optimization/85834
16423 * tree-ssa-sccvn.c (vn_reference_lookup_3): Properly handle
16424 non-constant and non-zero memset arguments.
16425
16426 2018-05-22 Martin Liska <mliska@suse.cz>
16427
16428 PR ipa/85607
16429 * ipa-icf.c (sem_item::add_type): Do not ICE for incomplete types.
16430
16431 2018-05-22 Richard Biener <rguenther@suse.de>
16432
16433 PR tree-optimization/85863
16434 * tree-vect-stmts.c (vect_is_simple_cond): Only widen invariant
16435 comparisons when vectype is specified.
16436 (vectorizable_condition): Do not specify vectype for
16437 vect_is_simple_cond when SLP vectorizing.
16438
16439 2018-05-21 Michael Meissner <meissner@linux.ibm.com>
16440
16441 PR target/85657
16442 * config/rs6000/rs6000-c.c (rs6000_cpu_cpp_builtins): Do not
16443 define __ibm128 as long double.
16444 * config/rs6000/rs6000.c (rs6000_init_builtins): Create __ibm128
16445 as a distinct type when IEEE 128-bit support is enabled.
16446 (init_float128_ieee): Fix up conversions between IFmode and IEEE
16447 128-bit types to use the correct functions.
16448 (rs6000_expand_float128_convert): Use explicit FLOAT_EXTEND to
16449 convert between 128-bit floating point types that have different
16450 modes but the same representation, instead of using gen_lowpart to
16451 makean alias.
16452 * config/rs6000/rs6000.md (IFKF): New iterator for IFmode and
16453 KFmode.
16454 (IFKF_reg): New attributes to give the register constraints for
16455 IFmode and KFmode.
16456 (extend<mode>tf2_internal): New insns to mark an explicit
16457 conversion between 128-bit floating point types that have a
16458 different mode but share the same representation.
16459
16460 2018-05-21 Richard Sandiford <richard.sandiford@linaro.org>
16461
16462 PR tree-optimization/85814
16463 * tree-ssa-strlen.c (get_stridx_plus_constant): Cope with
16464 a null return from get_strinfo when unsharing the next
16465 strinfo in the chain.
16466
16467 2018-05-21 Vladimir Mezentsev <vladimir.mezentsev@oracle.com>
16468
16469 PR gcc/84923
16470 * varasm.c (weak_finish): Clean up weak_decls.
16471
16472 2018-05-21 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
16473
16474 * config/aarch64/aarch64.md ("unspec"): Define UNSPEC_SABAL,
16475 UNSPEC_SABDL2, UNSPEC_SADALP, UNSPEC_UABAL, UNSPEC_UABDL2,
16476 UNSPEC_UADALP values.
16477 * config/aarch64/iterators.md (ABAL): New int iterator.
16478 (ABDL2): Likewise.
16479 (ADALP): Likewise.
16480 (sur): Add mappings for the above.
16481 * config/aarch64/aarch64-simd.md (aarch64_<sur>abdl2<mode>_3):
16482 New define_insn.
16483 (aarch64_<sur>abal<mode>_4): Likewise.
16484 (aarch64_<sur>adalp<mode>_3): Likewise.
16485 (<sur>sadv16qi): New define_expand.
16486
16487 2018-05-21 Alexander Nesterovskiy <alexander.nesterovskiy@intel.com>
16488
16489 * config/i386/i386.md (*movsf_internal): AVX falsedep fix.
16490 (*movdf_internal): Ditto.
16491 (*rcpsf2_sse): Ditto.
16492 (*rsqrtsf2_sse): Ditto.
16493 (*sqrt<mode>2_sse): Ditto.
16494
16495 2018-05-21 Tamar Christina <tamar.christina@arm.com>
16496
16497 * config/aarch64/aarch64-simd.md (aarch64_eor3qv8hi): Change to
16498 eor3q<mode>4.
16499 (aarch64_bcaxqv8hi): Change to bcaxq<mode>4.
16500 * config/aarch64/aarch64-simd-builtins.def (veor3q_u8, veor3q_u32,
16501 veor3q_u64, veor3q_s8, veor3q_s16, veor3q_s32, veor3q_s64, vbcaxq_u8,
16502 vbcaxq_u32, vbcaxq_u64, vbcaxq_s8, vbcaxq_s16, vbcaxq_s32,
16503 vbcaxq_s64): New.
16504 * config/aarch64/arm_neon.h: Likewise.
16505 * config/aarch64/iterators.md (VQ_I): New.
16506
16507 2018-05-21 Alexey Brodkin <abrodkin@synopsys.com>
16508
16509 * config.gcc: Add arc/t-multilib-linux to tmake_file for
16510 arc*-*-linux*.
16511 * config/arc/t-multilib-linux: Specify MULTILIB_OPTIONS and
16512 MULTILIB_DIRNAMES
16513
16514 2018-05-20 Chung-Ju Wu <jasonwucj@gmail.com>
16515
16516 * config/nds32/constraints.md (S): New constraint.
16517 * config/nds32/nds32.md (call_internal): Use constraint S.
16518 (call_value_internal): Likewise.
16519 (sibcall_internal): Likewise.
16520 (sibcall_value_internal): Likewise.
16521
16522 2018-05-20 Kito Cheng <kito.cheng@gmail.com>
16523 Chung-Ju Wu <jasonwucj@gmail.com>
16524
16525 * config/nds32/nds32.c (nds32_register_move_cost): Take garywolf cpu
16526 into consideration.
16527
16528 2018-05-20 Kito Cheng <kito.cheng@gmail.com>
16529 Chung-Ju Wu <jasonwucj@gmail.com>
16530
16531 * config/nds32/nds32-cost.c (rtx_cost_model_t): New structure.
16532 (insn_size_16bit, insn_size_32bit): New variables for cost evaluation.
16533 (nds32_rtx_costs_impl): Simplify.
16534 (nds32_address_cost_impl): Simplify.
16535 (nds32_init_rtx_costs): New function.
16536 (nds32_rtx_costs_speed_prefer): Likewise.
16537 (nds32_rtx_costs_size_prefer): Likewise.
16538 (nds32_address_cost_speed_prefer): Likewise.
16539 (nds32_address_cost_speed_fwprop): Likewise.
16540 (nds32_address_cost_size_prefer): Likewise.
16541 * config/nds32/nds32-protos.h (nds32_init_rtx_costs): Declare.
16542 * config/nds32/nds32.c (nds32_option_override): Use
16543 nds32_init_rtx_costs function.
16544
16545 2018-05-20 Chung-Ju Wu <jasonwucj@gmail.com>
16546
16547 * config/nds32/nds32.c (nds32_asm_file_start): Output pipeline model.
16548 * config/nds32/nds32.h (TARGET_PIPELINE_N7): Define.
16549 (TARGET_PIPELINE_N8): Likewise.
16550 (TARGET_PIPELINE_N10): Likewise.
16551 (TARGET_PIPELINE_N13): Likewise.
16552 (TARGET_PIPELINE_GRAYWOLF): Likewise.
16553
16554 2018-05-19 Monk Chiang <sh.chiang04@gmail.com>
16555
16556 * config/nds32/nds32-fpu.md: Update copyright year.
16557
16558 2018-05-19 Chung-Ju Wu <jasonwucj@gmail.com>
16559
16560 * config/nds32/nds32.h (ASM_SPEC): Adjust spec rule.
16561
16562 2018-05-19 Chung-Ju Wu <jasonwucj@gmail.com>
16563
16564 * config/nds32/nds32.c
16565 (nds32_md_asm_adjust): Consider flag_inline_asm_r15 variable.
16566 * config/nds32/nds32.opt (minline-asm-r15): New option.
16567
16568 2018-05-19 Chung-Ju Wu <jasonwucj@gmail.com>
16569
16570 * common/config/nds32/nds32-common.c (TARGET_DEFAULT_TARGET_FLAGS): Add
16571 MASK_HW_ABS.
16572 * config/nds32/nds32.md (abssi2): New pattern.
16573
16574 2018-05-19 Uros Bizjak <ubizjak@gmail.com>
16575
16576 * config/i386/i386.md (rex64namesuffix): New mode attribute.
16577 * config/i386/sse.md (sse_cvtsi2ss<rex64namesuffix><round_name>):
16578 Merge insn pattern from sse_cvtsi2ss<round_name> and
16579 sse_cvtsi2ssq<round_name> using SWI48 mode iterator.
16580 (sse_cvtss2si<rex64namesuffix><round_name>): Merge insn pattern
16581 from sse_cvtss2si<round_name> and sse_cvtss2siq<round_name>
16582 using SWI48 mode iterator.
16583 (sse_cvtss2si<rex64namesuffix>_2): Merge insn pattern from
16584 sse_cvtss2si_2 and sse_cvtss2siq_2 using SWI48 mode iterator.
16585 (sse_cvttss2si<rex64namesuffix><round_saeonly_name>): Merge insn
16586 pattern from sse_cvttss2si<round_saeonly_name>
16587 and sse_cvttss2siq<round_saeonly_name> using SWI48 mode iterator.
16588 (avx512f_vcvtss2usi<rex64namesuffix><round_name>): Merge insn pattern
16589 from avx512f_vcvtss2usi<round_name> and avx512f_vcvtss2usiq<round_name>
16590 using SWI48 mode iterator.
16591 (avx512f_vcvttss2usi<rex64namesuffix><round_saeonly_name>): Merge
16592 insn pattern from avx512f_vcvttss2usi<round_saeonly_name> and
16593 avx512f_vcvttss2usiq<round_saeonly_name> using SWI48 mode iterator.
16594 (avx512f_vcvtsd2usi<rex64namesuffix><round_name>): Merge insn pattern
16595 from avx512f_vcvtsd2usi<round_name> and avx512f_vcvtsd2usiq<round_name>
16596 using SWI48 mode iterator.
16597 (avx512f_vcvttsd2usi<rex64namesuffix><round_saeonly_name>): Merge
16598 insn pattern from avx512f_vcvttsd2usi<round_saeonly_name> and
16599 avx512f_vcvttsd2usiq<round_saeonly_name> using SWI48 mode iterator.
16600 (sse2_cvtsd2si<rex64namesuffix><round_name>): Merge insn pattern from
16601 sse2_cvtsd2si<round_name> and sse2_cvtsd2siq<round_name> using
16602 SWI48 mode iterator.
16603 (sse2_cvtsd2si<rex64namesuffix>_2): Merge insn pattern from
16604 sse2_cvtsd2si_2 and sse2_cvtsd2siq_2 using SWI48 mode iterator.
16605 (sse_cvttsd2si<rex64namesuffix><round_saeonly_name>): Merge insn
16606 pattern from sse_cvttsd2si<round_saeonly_name>
16607 and sse_cvttsd2siq<round_saeonly_name> using SWI48 mode iterator.
16608
16609 2018-05-19 Chung-Ju Wu <jasonwucj@gmail.com>
16610
16611 * config/nds32/nds32-md-auxiliary.c
16612 (nds32_valid_smw_lwm_base_p): Refine.
16613 (nds32_output_smw_single_word): Refine.
16614 (nds32_output_smw_double_word): New.
16615 * config/nds32/nds32-protos.h (nds32_output_smw_double_word): New.
16616
16617 2018-05-19 Chung-Ju Wu <jasonwucj@gmail.com>
16618
16619 * config/nds32/nds32-md-auxiliary.c (nds32_output_stack_push): Refine.
16620 (nds32_output_stack_pop): Refine.
16621 (nds32_expand_unaligned_load): Refine.
16622 (nds32_expand_unaligned_store): Refine.
16623
16624 2018-05-19 Kuan-Lin Chen <kuanlinchentw@gmail.com>
16625 Chung-Ju Wu <jasonwucj@gmail.com>
16626
16627 * config/nds32/constants.md: Add TP_REGNUM constant.
16628 (unspec_element): Add UNSPEC_GOTINIT, UNSPEC_GOT, UNSPEC_GOTOFF,
16629 UNSPEC_PLT, UNSPEC_TLSGD, UNSPEC_TLSLD, UNSPEC_TLSIE, UNSPEC_TLSLE and
16630 UNSPEC_ADD32.
16631 * config/nds32/nds32-doubleword.md: Consider flag_pic.
16632 * config/nds32/nds32-dspext.md (mov<mode>): Expand TLS and PIC cases.
16633 * config/nds32/nds32-predicates.c (nds32_const_unspec_p): New.
16634 * config/nds32/nds32-md-auxiliary.c: Implementation that support TLS
16635 and PIC code generation.
16636 * config/nds32/nds32-protos.h: Declarations that support TLS and PIC
16637 code generation.
16638 * config/nds32/nds32-relax-opt.c: Consider TLS and PIC for relax
16639 optimization.
16640 * config/nds32/nds32.md: Support TLS and PIC.
16641 * config/nds32/nds32.c: Support TLS and PIC.
16642 * config/nds32/nds32.h (nds32_relax_insn_type): New enum type.
16643 * config/nds32/predicates.md (nds32_nonunspec_symbolic_operand): New
16644 predicate.
16645
16646 2018-05-19 Chung-Ju Wu <jasonwucj@gmail.com>
16647
16648 * config/nds32/nds32-predicates.c (const_vector_to_hwint): Use machine
16649 mode with E_ prefix.
16650
16651 2018-05-19 Kuan-Lin Chen <kuanlinchentw@gmail.com>
16652 Chung-Ju Wu <jasonwucj@gmail.com>
16653
16654 * config/nds32/constants.md (unspec_element): Add UNSPEC_ICT.
16655 * config/nds32/nds32-md-auxiliary.c
16656 (symbolic_reference_mentioned_p): New.
16657 (nds32_legitimize_ict_address): New.
16658 (nds32_expand_ict_move): New.
16659 (nds32_indirect_call_referenced_p): New.
16660 (nds32_symbol_binds_local_p): Delete.
16661 (nds32_long_call_p): Modify.
16662 * config/nds32/nds32-opts.h (nds32_ict_model_type): New enum type.
16663 * config/nds32/nds32-protos.h
16664 (symbolic_reference_mentioned_p): Declare.
16665 (nds32_legitimize_ict_address): Declare.
16666 (nds32_expand_ict_move): Declare.
16667 (nds32_indirect_call_referenced_p): Declare.
16668 * config/nds32/nds32-relax-opt.c (nds32_ict_const_p): New.
16669 (nds32_relax_group): Use nds32_ict_const_p as condition.
16670 * config/nds32/nds32.c (nds32_attribute_table): Add "indirect_call".
16671 (nds32_asm_file_start): Output ict_model directive in asm code.
16672 (nds32_legitimate_address_p): Consider indirect call.
16673 (nds32_print_operand): Consider indirect call.
16674 (nds32_print_operand_address): Consider indirect call.
16675 (nds32_insert_attributes): Handle "indirect_call" attribute.
16676 (TARGET_LEGITIMATE_ADDRESS_P): Define.
16677 (TARGET_LEGITIMATE_CONSTANT_P): Define.
16678 (TARGET_CANNOT_FORCE_CONST_MEM): Define.
16679 (TARGET_DELEGITIMIZE_ADDRESS): Define.
16680 (TARGET_ASM_OUTPUT_ADDR_CONST_EXTRA): Define.
16681 * config/nds32/nds32.h (SYMBOLIC_CONST_P): Define.
16682 (TARGET_ICT_MODEL_SMALL): Define.
16683 (TARGET_ICT_MODEL_LARGE): Define.
16684 * config/nds32/nds32.md (movsi): Consider ict model.
16685 (call, call_value): Consider ict model.
16686 (sibcall, sibcall_value): Consider ict model.
16687 * config/nds32/nds32.opt (mict-model): New option.
16688 * config/nds32/predicates.md (nds32_symbolic_operand): Consider ict
16689 model.
16690
16691 2018-05-18 Kito Cheng <kito.cheng@gmail.com>
16692 Monk Chiang <sh.chiang04@gmail.com>
16693 Jim Wilson <jimw@sifive.com>
16694
16695 * common/config/riscv/riscv-common.c (riscv_parse_arch_string):
16696 Add support to parse rv32e*. Clear MASK_RVE for rv32i and rv64i.
16697 * config.gcc (riscv*-*-*): Add support for rv32e* and ilp32e.
16698 * config/riscv/riscv-c.c (riscv_cpu_cpp_builtins): Define
16699 __riscv_32e when TARGET_RVE. Handle ABI_ILP32E as soft-float ABI.
16700 * config/riscv/riscv-opts.h (riscv_abi_type): Add ABI_ILP32E.
16701 * config/riscv/riscv.c (riscv_compute_frame_info): When TARGET_RVE,
16702 compute save_libcall_adjustment properly.
16703 (riscv_option_override): Call error if TARGET_RVE and not ABI_ILP32E.
16704 (riscv_conditional_register_usage): Handle TARGET_RVE and ABI_ILP32E.
16705 * config/riscv/riscv.h (UNITS_PER_FP_ARG): Handle ABI_ILP32E.
16706 (STACK_BOUNDARY, ABI_STACK_BOUNDARY): Handle TARGET_RVE.
16707 (GP_REG_LAST, MAX_ARGS_IN_REGISTERS): Likewise.
16708 (ABI_SPEC): Handle mabi=ilp32e.
16709 * config/riscv/riscv.opt (abi_type): Add ABI_ILP32E.
16710 (RVE): Add RVE mask.
16711 * doc/invoke.texi (RISC-V options) <-mabi>: Add ilp32e info.
16712 <-march>: Add rv32e as an example.
16713
16714 2018-05-18 Marc Glisse <marc.glisse@inria.fr>
16715
16716 PR c++/82899
16717 * tree-ssa-structalias.c (create_variable_info_for_1): Extra argument.
16718 (intra_create_variable_infos): Handle C++ constructors.
16719
16720 2018-05-18 Martin Liska <mliska@suse.cz>
16721
16722 * passes.def: Remove a redundant pass.
16723
16724 2018-05-18 Eric Botcazou <ebotcazou@adacore.com>
16725
16726 PR bootstrap/85838
16727 * config/sparc/sparc.c (sparc_expand_builtin): Always initialize op[0].
16728
16729 2018-05-18 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
16730
16731 * config/arm/arm-cpus.in (armv3m, mode32): Delete features.
16732 (ARMv4): Update.
16733 (ARMv2, ARMv3, ARMv3m): Delete fgroups.
16734 (ARMv6m): Update.
16735 (armv2, armv2a, armv3, armv3m): Delete architectures.
16736 (arm2, arm250, arm3, arm6, arm60, arm600, arm610, arm620,
16737 arm7, arm7d, arm7di, arm70, arm700, arm700i, arm710, arm720,
16738 arm710c, arm7100, arm7500, arm7500fe, arm7m, arm7dm, arm7dmi):
16739 Delete cpus.
16740 * config/arm/arm.md (maddsidi4): Remove check for arm_arch3m.
16741 (*mulsidi3adddi): Likewise.
16742 (mulsidi3): Likewise.
16743 (*mulsidi3_nov6): Likewise.
16744 (umulsidi3): Likewise.
16745 (umulsidi3_nov6): Likewise.
16746 (umaddsidi4): Likewise.
16747 (*umulsidi3adddi): Likewise.
16748 (smulsi3_highpart): Likewise.
16749 (*smulsi3_highpart_nov6): Likewise.
16750 (umulsi3_highpart): Likewise.
16751 (*umulsi3_highpart_nov6): Likewise.
16752 * config/arm/arm.h (arm_arch3m): Delete.
16753 * config/arm/arm.c (arm_arch3m): Delete.
16754 (arm_option_override_internal): Update armv3-related comment.
16755 (arm_configure_build_target): Delete use of isa_bit_mode32.
16756 (arm_option_reconfigure_globals): Delete set of arm_ach3m.
16757 (arm_rtx_costs_internal): Delete check of arm_arch3m.
16758 * config/arm/arm-fixed.md (mulsq3): Delete check for arm_arch3m.
16759 (mulsa3): Likewise.
16760 (mulusa3): Likewise.
16761 * config/arm/arm-protos.h (arm_arch3m): Delete.
16762 * config/arm/arm-tables.opt: Regenerate.
16763 * config/arm/arm-tune.md: Likewise.
16764 * config/arm/t-arm-elf (all_early_nofp): Delete mentions of
16765 deleted architectures.
16766
16767 2018-05-18 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
16768
16769 * config/arm/arm-cpus.in (armv5, armv5e): Delete features.
16770 (armv5t, armv5te): New features.
16771 (ARMv5, ARMv5e): Delete fgroups.
16772 (ARMv5t, ARMv5te): Adjust for above changes.
16773 (ARMv6m): Likewise.
16774 (armv5, armv5e): Delete arches.
16775 * config/arm/arm.md (*call_reg_armv5): Use arm_arch5t instead of
16776 arm_arch5.
16777 (*call_reg_arm): Likewise.
16778 (*call_value_reg_armv5): Likewise.
16779 (*call_value_reg_arm): Likewise.
16780 (*call_symbol): Likewise.
16781 (*call_value_symbol): Likewise.
16782 (*sibcall_insn): Likewise.
16783 (*sibcall_value_insn): Likewise.
16784 (clzsi2): Likewise.
16785 (prefetch): Likewise.
16786 (define_split and define_peephole2 dependent on arm_arch5):
16787 Likewise.
16788 * config/arm/arm.h (TARGET_LDRD): Use arm_arch5te instead of
16789 arm_arch5e.
16790 (TARGET_ARM_QBIT): Likewise.
16791 (TARGET_DSP_MULTIPLY): Likewise.
16792 (enum base_architecture): Delete BASE_ARCH_5, BASE_ARCH_5E.
16793 (arm_arch5, arm_arch5e): Delete.
16794 (arm_arch5t, arm_arch5te): Declare.
16795 * config/arm/arm.c (arm_arch5, arm_arch5e): Delete.
16796 (arm_arch5t): Declare.
16797 (arm_option_reconfigure_globals): Update for the above.
16798 (arm_options_perform_arch_sanity_checks): Update comment, replace
16799 use of arm_arch5 with arm_arch5t.
16800 (use_return_insn): Likewise.
16801 (arm_emit_call_insn): Likewise.
16802 (output_return_instruction): Likewise.
16803 (arm_final_prescan_insn): Likewise.
16804 (arm_coproc_builtin_available): Likewise.
16805 * config/arm/arm-c.c (arm_cpu_builtins): Replace arm_arch5 and
16806 arm_arch5e with arm_arch5t and arm_arch5te.
16807 * config/arm/arm-protos.h (arm_arch5, arm_arch5e): Delete.
16808 (arm_arch5t, arm_arch5te): Declare.
16809 * config/arm/arm-tables.opt: Regenerate.
16810 * config/arm/t-arm-elf: Remove references to armv5, armv5e.
16811 * config/arm/t-multilib: Likewise.
16812 * config/arm/thumb1.md (*call_reg_thumb1_v5): Check arm_arch5t
16813 instead of arm_arch5.
16814 (*call_reg_thumb1): Likewise.
16815 (*call_value_reg_thumb1_v5): Likewise.
16816 (*call_value_reg_thumb1): Likewise.
16817 * config/arm/vxworks.h (TARGET_OS_CPP_BUILTINS): Remove now
16818 unreachable path.
16819 * doc/invoke.texi (ARM Options): Remove references to armv5, armv5e.
16820
16821 2018-05-18 Martin Liska <mliska@suse.cz>
16822
16823 PR gcov-profile/84846
16824 * doc/gcov.texi: Document -t option of gcov tool.
16825
16826 2018-05-18 Martin Liska <mliska@suse.cz>
16827
16828 PR gcov-profile/84846
16829 * gcov.c (print_usage): Add new -t option.
16830 (process_args): Handle the option.
16831 (generate_results): Use stdout as output when requested by
16832 the option.
16833
16834 2018-05-18 Martin Liska <mliska@suse.cz>
16835
16836 PR gcov-profile/84846
16837 * coverage.c (coverage_init): Write PWD to .gcno file.
16838 * doc/gcov.texi: Document how working directory is printed.
16839 * gcov-dump.c (dump_gcov_file): Print PWD.
16840 * gcov.c (output_intermediate_file): Likewise.
16841 (read_graph_file): Read PWD string.
16842 (output_lines): Print PWD.
16843
16844 2018-05-18 Prathamesh Kulkarni <prathamesh.kulkarni@linaro.org>
16845
16846 PR middle-end/85817
16847 * ipa-pure-const.c (malloc_candidate_p): Remove the check integer_zerop
16848 for retval and return false if all args to phi are zero.
16849
16850 2018-05-18 Richard Biener <rguenther@suse.de>
16851
16852 * gimple-ssa-evrp.c (class evrp_folder): Add simplify_stmt_using_ranges
16853 method.
16854 (evrp_dom_walker::before_dom_children): Call it.
16855
16856 2018-05-18 Richard Biener <rguenther@suse.de>
16857
16858 * tree-dfa.c (get_ref_base_and_extent): Use range-info to refine
16859 results when processing array refs with variable index.
16860
16861 2018-05-18 Toon Moene <toon@moene.org>
16862
16863 * doc/invoke.texi: Move -floop-unroll-and-jam documentation
16864 directly after that of -floop-interchange. Indicate that both
16865 options are enabled by default when specifying -O3.
16866
16867 2018-05-18 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
16868
16869 * config/aarch64/aarch64-simd.md (vec_set<mode>): Use VALL_F16 mode
16870 iterator. Delete separate integer-mode vec_set<mode> expander.
16871 (aarch64_simd_vec_setv2di): Delete.
16872 (vec_setv2di): Delete.
16873 (aarch64_simd_vec_set<mode>): Delete all other patterns with that name.
16874 Use VALL_F16 mode iterator. Add LD1 alternative and use vwcore for
16875 the "w, r" alternative.
16876
16877 2018-05-18 Martin Liska <mliska@suse.cz>
16878
16879 * passes.def: Add pass_lower_switch and pass_lower_switch_O0.
16880 * tree-pass.h (make_pass_lower_switch_O0): New function.
16881 * tree-switch-conversion.c (node_has_low_bound): Remove.
16882 (node_has_high_bound): Likewise.
16883 (node_is_bounded): Likewise.
16884 (class pass_lower_switch): Make it a template type and create
16885 two instances.
16886 (pass_lower_switch::execute): Add template argument.
16887 (make_pass_lower_switch): New function.
16888 (make_pass_lower_switch_O0): New function.
16889 (do_jump_if_equal): Remove.
16890 (emit_case_nodes): Simplify to just handle all 3 cases and leave
16891 all the hard work to tree optimization passes.
16892
16893 2018-05-18 Martin Liska <mliska@suse.cz>
16894
16895 * dbgcnt.c (limit_low): Renamed from limit.
16896 (limit_high): New variable.
16897 (dbg_cnt_is_enabled): Check for upper limit.
16898 (dbg_cnt): Adjust dumping.
16899 (dbg_cnt_set_limit_by_index): Add new argument for high
16900 value.
16901 (dbg_cnt_set_limit_by_name): Likewise.
16902 (dbg_cnt_process_single_pair): Parse new format.
16903 (dbg_cnt_process_opt): Use strtok.
16904 (dbg_cnt_list_all_counters): Remove 'value' and add
16905 'limit_high'.
16906 * doc/invoke.texi: Document changes.
16907
16908 2018-05-18 Richard Sandiford <richard.sandiford@linaro.org>
16909
16910 * doc/sourcebuild.texi (scalar_all_fma): Document.
16911 * tree.def (FMA_EXPR): Delete.
16912 * internal-fn.def (FMA, FMS, FNMA, FNMS): New internal functions.
16913 * internal-fn.c (ternary_direct): New macro.
16914 (expand_ternary_optab_fn): Likewise.
16915 (direct_ternary_optab_supported_p): Likewise.
16916 * Makefile.in (build/genmatch.o): Depend on case-fn-macros.h.
16917 * builtins.c (fold_builtin_fma): Delete.
16918 (fold_builtin_3): Don't call it.
16919 * cfgexpand.c (expand_debug_expr): Remove FMA_EXPR handling.
16920 * expr.c (expand_expr_real_2): Likewise.
16921 * fold-const.c (operand_equal_p): Likewise.
16922 (fold_ternary_loc): Likewise.
16923 * gimple-pretty-print.c (dump_ternary_rhs): Likewise.
16924 * gimple.c (DEFTREECODE): Likewise.
16925 * gimplify.c (gimplify_expr): Likewise.
16926 * optabs-tree.c (optab_for_tree_code): Likewise.
16927 * tree-cfg.c (verify_gimple_assign_ternary): Likewise.
16928 * tree-eh.c (operation_could_trap_p): Likewise.
16929 (stmt_could_throw_1_p): Likewise.
16930 * tree-inline.c (estimate_operator_cost): Likewise.
16931 * tree-pretty-print.c (dump_generic_node): Likewise.
16932 (op_code_prio): Likewise.
16933 * tree-ssa-loop-im.c (stmt_cost): Likewise.
16934 * tree-ssa-operands.c (get_expr_operands): Likewise.
16935 * tree.c (commutative_ternary_tree_code, add_expr): Likewise.
16936 * fold-const-call.h (fold_fma): Delete.
16937 * fold-const-call.c (fold_const_call_ssss): Handle CFN_FMS,
16938 CFN_FNMA and CFN_FNMS.
16939 (fold_fma): Delete.
16940 * genmatch.c (combined_fn): New enum.
16941 (commutative_ternary_tree_code): Remove FMA_EXPR handling.
16942 (commutative_op): New function.
16943 (commutate): Use it. Handle more than 2 operands.
16944 (dt_operand::gen_gimple_expr): Use commutative_op.
16945 (parser::parse_expr): Allow :c to be used with non-binary
16946 operators if the commutative operand is known.
16947 * gimple-ssa-backprop.c (backprop::process_builtin_call_use): Handle
16948 CFN_FMS, CFN_FNMA and CFN_FNMS.
16949 (backprop::process_assign_use): Remove FMA_EXPR handling.
16950 * hsa-gen.c (gen_hsa_insns_for_operation_assignment): Likewise.
16951 (gen_hsa_fma): New function.
16952 (gen_hsa_insn_for_internal_fn_call): Use it for IFN_FMA, IFN_FMS,
16953 IFN_FNMA and IFN_FNMS.
16954 * match.pd: Add folds for IFN_FMS, IFN_FNMA and IFN_FNMS.
16955 * gimple-fold.h (follow_all_ssa_edges): Declare.
16956 * gimple-fold.c (follow_all_ssa_edges): New function.
16957 * tree-ssa-math-opts.c (convert_mult_to_fma_1): Use the
16958 gimple_build interface and use follow_all_ssa_edges to fold the result.
16959 (convert_mult_to_fma): Use direct_internal_fn_suppoerted_p
16960 instead of checking for optabs directly.
16961 * config/i386/i386.c (ix86_add_stmt_cost): Recognize FMAs as calls
16962 rather than FMA_EXPRs.
16963 * config/rs6000/rs6000.c (rs6000_gimple_fold_builtin): Create a
16964 call to IFN_FMA instead of an FMA_EXPR.
16965
16966 2018-05-17 Jim Wilson <jimw@sifive.com>
16967
16968 * expr.c (do_tablejump): When converting index to Pmode, if we have a
16969 sign extended promoted subreg, and the range does not have the sign bit
16970 set, then do a sign extend.
16971
16972 * config/riscv/riscv.c (riscv_extend_comparands): In unsigned QImode
16973 test, check for sign extended subreg and/or constant operands, and
16974 do a sign extend in that case.
16975
16976 2018-05-17 Steve Ellcey <sellcey@cavium.com>
16977
16978 * config/aarch64/thunderx2t99.md (thunderx2t99_ls_both): Delete.
16979 (thunderx2t99_multiple): Delete psuedo-units from used cpus.
16980 Add untyped.
16981 (thunderx2t99_alu_shift): Remove alu_shift_reg, alus_shift_reg.
16982 Change logics_shift_reg to logics_shift_imm.
16983 (thunderx2t99_fp_loadpair_basic): Delete.
16984 (thunderx2t99_fp_storepair_basic): Delete.
16985 (thunderx2t99_asimd_int): Add neon_sub and neon_sub_q types.
16986 (thunderx2t99_asimd_polynomial): Delete.
16987 (thunderx2t99_asimd_fp_simple): Add neon_fp_mul_s_scalar_q
16988 and neon_fp_mul_d_scalar_q.
16989 (thunderx2t99_asimd_fp_conv): Add *int_to_fp* types.
16990 (thunderx2t99_asimd_misc): Delete neon_dup and neon_dup_q.
16991 (thunderx2t99_asimd_recip_step): Add missing *sqrt* types.
16992 (thunderx2t99_asimd_lut): Add missing tbl types.
16993 (thunderx2t99_asimd_ext): Delete.
16994 (thunderx2t99_asimd_load1_1_mult): Delete.
16995 (thunderx2t99_asimd_load1_2_mult): Delete.
16996 (thunderx2t99_asimd_load1_ldp): New.
16997 (thunderx2t99_asimd_load1): New.
16998 (thunderx2t99_asimd_load2): Add missing *load2* types.
16999 (thunderx2t99_asimd_load3): New.
17000 (thunderx2t99_asimd_load4): New.
17001 (thunderx2t99_asimd_store1_1_mult): Delete.
17002 (thunderx2t99_asimd_store1_2_mult): Delete.
17003 (thunderx2t99_asimd_store2_mult): Delete.
17004 (thunderx2t99_asimd_store2_onelane): Delete.
17005 (thunderx2t99_asimd_store_stp): New.
17006 (thunderx2t99_asimd_store1): New.
17007 (thunderx2t99_asimd_store2): New.
17008 (thunderx2t99_asimd_store3): New.
17009 (thunderx2t99_asimd_store4): New.
17010
17011 2018-05-17 Jerome Lambourg <lambourg@adacore.com>
17012
17013 * config/arm/arm_cmse.h (cmse_nsfptr_create, cmse_is_nsfptr): Remove
17014 #include <stdint.h>. Replace intptr_t with __INTPTR_TYPE__.
17015
17016 2018-05-17 Pat Haugen <pthaugen@us.ibm.com>
17017 Segher Boessenkool <segher@kernel.crashing.org>
17018
17019 PR target/85698
17020 * config/rs6000/rs6000.c (rs6000_output_move_128bit): Check dest
17021 operand.
17022
17023 2018-05-17 Richard Biener <rguenther@suse.de>
17024
17025 * tree-ssa-dse.c (dse_classify_store): Fix iterator increment
17026 for pruning loop and prune defs feeding only already visited PHIs.
17027
17028 2018-05-17 Richard Biener <rguenther@suse.de>
17029
17030 * tree-ssa-sccvn.c (vn_reference_lookup_3): Improve memset handling.
17031
17032 2018-05-17 Bin Cheng <bin.cheng@arm.com>
17033 Richard Biener <rguenther@suse.de>
17034
17035 PR tree-optimization/85793
17036 * tree-vect-stmts.c (vectorizable_load): Handle 1 element-wise load
17037 for VMAT_ELEMENTWISE.
17038
17039 2018-05-17 Richard Sandiford <richard.sandiford@linaro.org>
17040
17041 * internal-fn.h (lookup_internal_fn): Declare
17042 * internal-fn.c (lookup_internal_fn): New function.
17043 * gimple.c (gimple_build_call_from_tree): Handle calls to
17044 internal functions.
17045 * gimple-pretty-print.c (dump_gimple_call): Print "." before
17046 internal function names.
17047 * tree-pretty-print.c (dump_generic_node): Likewise.
17048 * tree-ssa-scopedtables.c (expr_hash_elt::print): Likewise.
17049
17050 2018-05-17 Richard Sandiford <richard.sandiford@linaro.org>
17051
17052 * gimple-fold.h (gimple_build): Make the function forms take
17053 combined_fn rather than built_in_function.
17054 (gimple_simplify): Likewise.
17055 * gimple-match-head.c (gimple_simplify): Likewise.
17056 * gimple-fold.c (gimple_build): Likewise.
17057 * tree-vect-loop.c (get_initial_def_for_reduction): Use gimple_build
17058 rather than gimple_build_call_internal.
17059 (get_initial_defs_for_reduction): Likewise.
17060 (vect_create_epilog_for_reduction): Likewise.
17061 (vectorizable_live_operation): Likewise.
17062
17063 2018-05-17 Martin Liska <mliska@suse.cz>
17064
17065 * gimple-ssa-sprintf.c (format_directive): Do not use
17066 space in between 'G_' and '('.
17067
17068 2018-05-17 Jakub Jelinek <jakub@redhat.com>
17069
17070 PR target/85323
17071 * config/i386/i386.c (ix86_fold_builtin): Handle masked shifts
17072 even if the mask is not all ones.
17073
17074 PR target/85323
17075 * config/i386/i386.c (ix86_fold_builtin): Fold shift builtins by
17076 vector.
17077 (ix86_gimple_fold_builtin): Likewise.
17078
17079 PR target/85323
17080 * config/i386/i386.c: Include tree-vector-builder.h.
17081 (ix86_vector_shift_count): New function.
17082 (ix86_fold_builtin): Fold shift builtins by scalar count.
17083 (ix86_gimple_fold_builtin): Likewise.
17084
17085 * config/i386/avx512fintrin.h (_mm512_set_epi16, _mm512_set_epi8,
17086 _mm512_setzero): New intrinsics.
17087
17088 2018-05-17 James Greenhalgh <james.greenhalgh@arm.com>
17089 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
17090
17091 * config/aarch64/aarch64.c (aarch64_expand_vector_init): Modify
17092 code generation for cases where splatting a value is not useful.
17093 * simplify-rtx.c (simplify_ternary_operation): Simplify
17094 vec_merge across a vec_duplicate and a paradoxical subreg forming
17095 a vector mode to a vec_concat.
17096
17097 2018-05-17 Olga Makhotina <olga.makhotina@intel.com>
17098
17099 * config.gcc: Support "goldmont-plus".
17100 * config/i386/driver-i386.c (host_detect_local_cpu): Detect
17101 "goldmont-plus".
17102 * config/i386/i386-c.c (ix86_target_macros_internal): Handle
17103 PROCESSOR_GOLDMONT_PLUS.
17104 * config/i386/i386.c (m_GOLDMONT_PLUS): Define.
17105 (processor_target_table): Add "goldmont-plus".
17106 (PTA_GOLDMONT_PLUS): Define.
17107 (ix86_lea_outperforms): Add TARGET_GOLDMONT_PLUS.
17108 (get_builtin_code_for_version): Handle PROCESSOR_GOLDMONT_PLUS.
17109 (fold_builtin_cpu): Add M_INTEL_GOLDMONT_PLUS.
17110 (fold_builtin_cpu): Add "goldmont-plus".
17111 (ix86_add_stmt_cost): Add TARGET_GOLDMONT_PLUS.
17112 (ix86_option_override_internal): Add "goldmont-plus".
17113 * config/i386/i386.h (processor_costs): Define TARGET_GOLDMONT_PLUS.
17114 (processor_type): Add PROCESSOR_GOLDMONT_PLUS.
17115 * config/i386/x86-tune.def: Add m_GOLDMONT_PLUS.
17116 * doc/invoke.texi: Add goldmont-plus as x86 -march=/-mtune= CPU type.
17117
17118 2018-05-17 Richard Biener <rguenther@suse.de>
17119
17120 PR tree-optimization/85757
17121 * tree-ssa-dse.c (dse_classify_store): Record a PHI def and
17122 remove defs that only feed that PHI from further processing.
17123
17124 2018-05-16 Jim Wilson <jimw@sifive.com>
17125
17126 * config/riscv/riscv.md (<optab>si3_mask, <optab>si3_mask_1): Prepend
17127 asterisk to name.
17128 (<optab>di3_mask, <optab>di3_mask_1): Likewise.
17129
17130 2018-05-16 Mark Wielaard <mark@klomp.org>
17131
17132 * dwarf2out.c (count_index_strings): New function.
17133 (output_indirect_strings): Call count_index_strings and generate
17134 header for dwarf_version >= 5.
17135
17136 2018-05-16 Mark Wielaard <mark@klomp.org>
17137
17138 * dwarf2out.c (dwarf_FORM): New function.
17139 (set_indirect_string): Use dwarf_FORM.
17140 (reset_indirect_string): Likewise.
17141 (size_of_die): Likewise.
17142 (value_format): Likewise.
17143 (output_die): Likewise.
17144 (add_skeleton_AT_string): Likewise.
17145 (output_macinfo_op): Likewise.
17146 (index_string): Likewise.
17147 (output_index_string_offset): Likewise.
17148 (output_index_string): Likewise.
17149 (count_index_strings): Likewise.
17150
17151 2018-05-16 Carl Love <cel@us.ibm.com>
17152
17153 * config/rs6000/rs6000.md (prefetch): Generate ISA 2.06 instructions
17154 dcbt and dcbtstt with TH=16 if operands[2] is 0 and Power 8 or newer.
17155
17156 2018-05-16 Martin Jambor <mjambor@suse.cz>
17157
17158 * ipa-prop.c (ipa_free_all_edge_args): Remove.
17159 * ipa-prop.h (ipa_free_all_edge_args): Likewise.
17160
17161 2018-05-16 Wilco Dijkstra <wdijkstr@arm.com>
17162
17163 * config/aarch64/aarch64.md (fma<mode>4): Change into expand pattern.
17164 (fnma<mode>4): Likewise.
17165 (fms<mode>4): Likewise.
17166 (fnms<mode>4): Likewise.
17167 (aarch64_fma<mode>4): Rename insn, reorder accumulator operand.
17168 (aarch64_fnma<mode>4): Likewise.
17169 (aarch64_fms<mode>4): Likewise.
17170 (aarch64_fnms<mode>4): Likewise.
17171 (aarch64_fnmadd<mode>4): Likewise.
17172
17173 2018-05-16 Jason Merrill <jason@redhat.com>
17174
17175 * tree.c (warn_deprecated_use): Return bool. Simplify logic.
17176
17177 2018-05-16 Richard Biener <rguenther@suse.de>
17178
17179 * tree-vectorizer.h (struct stmt_info_for_cost): Add where member.
17180 (dump_stmt_cost): Declare.
17181 (add_stmt_cost): Dump cost we add.
17182 (add_stmt_costs): New function.
17183 (vect_model_simple_cost, vect_model_store_cost, vect_model_load_cost):
17184 No longer exported.
17185 (vect_analyze_stmt): Adjust prototype.
17186 (vectorizable_condition): Likewise.
17187 (vectorizable_live_operation): Likewise.
17188 (vectorizable_reduction): Likewise.
17189 (vectorizable_induction): Likewise.
17190 * tree-vect-loop.c (vect_analyze_loop_operations): Create local
17191 cost vector to pass to vectorizable_ and record afterwards.
17192 (vect_model_reduction_cost): Take cost vector argument and adjust.
17193 (vect_model_induction_cost): Likewise.
17194 (vectorizable_reduction): Likewise.
17195 (vectorizable_induction): Likewise.
17196 (vectorizable_live_operation): Likewise.
17197 * tree-vect-slp.c (vect_create_new_slp_node): Initialize
17198 SLP_TREE_NUMBER_OF_VEC_STMTS.
17199 (vect_analyze_slp_cost_1): Remove.
17200 (vect_analyze_slp_cost): Likewise.
17201 (vect_slp_analyze_node_operations): Take visited args and
17202 a target cost vector. Avoid processing already visited stmt sets.
17203 (vect_slp_analyze_operations): Use a local cost vector to gather
17204 costs and register those of non-discarded instances.
17205 (vect_bb_vectorization_profitable_p): Use add_stmt_costs.
17206 (vect_schedule_slp_instance): Remove copying of
17207 SLP_TREE_NUMBER_OF_VEC_STMTS. Instead assert that it is not
17208 zero.
17209 * tree-vect-stmts.c (record_stmt_cost): Remove path directly
17210 adding cost. Record cost entry location.
17211 (vect_prologue_cost_for_slp_op): Function to compute cost of
17212 a constant or invariant generated for SLP vect in the prologue,
17213 split out from vect_analyze_slp_cost_1.
17214 (vect_model_simple_cost): Make static. Adjust for SLP costing.
17215 (vect_model_promotion_demotion_cost): Likewise.
17216 (vect_model_store_cost): Likewise, make static.
17217 (vect_model_load_cost): Likewise.
17218 (vectorizable_bswap): Add cost vector arg and adjust.
17219 (vectorizable_call): Likewise.
17220 (vectorizable_simd_clone_call): Likewise.
17221 (vectorizable_conversion): Likewise.
17222 (vectorizable_assignment): Likewise.
17223 (vectorizable_shift): Likewise.
17224 (vectorizable_operation): Likewise.
17225 (vectorizable_store): Likewise.
17226 (vectorizable_load): Likewise.
17227 (vectorizable_condition): Likewise.
17228 (vectorizable_comparison): Likewise.
17229 (can_vectorize_live_stmts): Likewise.
17230 (vect_analyze_stmt): Likewise.
17231 (vect_transform_stmt): Adjust calls to vectorizable_*.
17232 * tree-vectorizer.c: Include gimple-pretty-print.h.
17233 (dump_stmt_cost): New function.
17234
17235 2018-05-16 Richard Biener <rguenther@suse.de>
17236
17237 * params.def (PARAM_DSE_MAX_ALIAS_QUERIES_PER_STORE): New param.
17238 * doc/invoke.texi (dse-max-alias-queries-per-store): Document.
17239 * tree-ssa-dse.c: Include tree-ssa-loop.h.
17240 (check_name): New callback.
17241 (dse_classify_store): Track cycles via a visited bitmap of PHI
17242 defs and simplify handling of in-loop and across loop dead stores
17243 and properly fail for loop-variant refs. Handle byte-tracking with
17244 multiple defs. Use PARAM_DSE_MAX_ALIAS_QUERIES_PER_STORE for
17245 limiting the walk.
17246
17247 2018-05-16 Richard Sandiford <richard.sandiford@linaro.org>
17248
17249 * tree-vectorizer.h (vect_get_vector_types_for_stmt): Declare.
17250 (vect_get_mask_type_for_stmt): Likewise.
17251 * tree-vect-slp.c (vect_two_operations_perm_ok_p): New function,
17252 split out from...
17253 (vect_build_slp_tree_1): ...here. Use vect_get_vector_types_for_stmt
17254 to determine the statement's vector type and the vector type that
17255 should be used for calculating nunits. Deal with cases in which
17256 the type has to be deferred.
17257 (vect_slp_analyze_node_operations): Use vect_get_vector_types_for_stmt
17258 and vect_get_mask_type_for_stmt to calculate STMT_VINFO_VECTYPE.
17259 * tree-vect-loop.c (vect_determine_vf_for_stmt_1)
17260 (vect_determine_vf_for_stmt): New functions, split out from...
17261 (vect_determine_vectorization_factor): ...here.
17262 * tree-vect-stmts.c (vect_get_vector_types_for_stmt)
17263 (vect_get_mask_type_for_stmt): New functions, split out from
17264 vect_determine_vectorization_factor.
17265
17266 2018-05-16 Richard Biener <rguenther@suse.de>
17267
17268 * tree-cfg.c (verify_gimple_assign_ternary): Properly
17269 verify the [VEC_]COND_EXPR embedded comparison.
17270
17271 2018-05-15 Martin Sebor <msebor@redhat.com>
17272
17273 PR tree-optimization/85753
17274 * gimple-ssa-warn-restrict.c (builtin_memref::builtin_memref): Handle
17275 RECORD_TYPE in addition to ARRAY_TYPE.
17276
17277 2018-05-15 Martin Sebor <msebor@redhat.com>
17278
17279 PR middle-end/85643
17280 * calls.c (get_attr_nonstring_decl): Handle MEM_REF.
17281
17282 2018-05-15 Richard Biener <rguenther@suse.de>
17283
17284 * tree-ssa-dse.c (dse_classify_store): Remove use_stmt parameter,
17285 add by_clobber_p one. Change algorithm to collect all defs
17286 representing uses we need to walk and try reducing them to
17287 a single one before failing.
17288 (dse_dom_walker::dse_optimize_stmt): Adjust.
17289
17290 2018-05-13 Mark Wielaard <mark@klomp.org>
17291
17292 * dwarf2out.c (dwarf_OP): Handle DW_OP_addrx and DW_OP_constx.
17293 (size_of_loc_descr): Likewise.
17294 (output_loc_operands): Likewise.
17295 (output_loc_operands_raw): Likewise.
17296 (dw_addr_op): Use dwarf_OP () for DW_OP_constx and DW_OP_addrx.
17297 (resolve_addr_in_expr): Handle DW_OP_addrx and DW_OP_constx.
17298 (hash_loc_operands): Likewise.
17299 (compare_loc_operands): Likewise.
17300
17301 2018-05-14 Mark Wielaard <mark@klomp.org>
17302
17303 * dwarf2out.c (count_index_addrs): New function.
17304 (dwarf2out_finish): Use count_index_addrs to calculate addrs_length.
17305
17306 2018-05-15 Prathamesh Kulkarni <prathamesh.kulkarni@linaro.org>
17307
17308 PR tree-optimization/83648
17309 * ipa-pure-const.c (malloc_candidate_p): Allow function with NULL
17310 return value as malloc candidate.
17311
17312 2018-05-15 Prathamesh Kulkarni <prathamesh.kulkarni@linaro.org>
17313
17314 PR ipa/85734
17315 * ipa-pure-const.c (warn_function_malloc): Pass value of known_finite
17316 param as true in call to suggest_attribute.
17317
17318 2018-05-14 Segher Boessenkool <segher@kernel.crashing.org>
17319
17320 * doc/invoke.texi (RS/6000 and PowerPC Options): Delete @itemx for
17321 -mreadonly-in-sdata.
17322
17323 2018-05-14 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
17324
17325 * config/aarch64/aarch64-simd.md (*aarch64_crypto_aese_fused):
17326 New pattern.
17327 (aarch64_crypto_aesd_fused): Likewise.
17328
17329 2018-05-14 Wilco Dijkstra <wdijkstr@arm.com>
17330
17331 * config/aarch64/aarch64.md (mov<mode>): Remove '*' in alternatives.
17332 (movsi_aarch64): Likewise.
17333 (load_pairsi): Likewise.
17334 (load_pairdi): Likewise.
17335 (store_pairsi): Likewise.
17336 (store_pairdi): Likewise.
17337 (load_pairsf): Likewise.
17338 (load_pairdf): Likewise.
17339 (store_pairsf): Likewise.
17340 (store_pairdf): Likewise.
17341 (zero_extend): Likewise.
17342 (trunc): Swap alternatives.
17343 (fcvt_target): Add '?' to prefer w over r.
17344
17345 2018-05-14 Jakub Jelinek <jakub@redhat.com>
17346
17347 PR target/85756
17348 * config/i386/i386.md: Disallow non-commutative arithmetics in
17349 last twpeephole for mem {+,-,&,|,^}= x; mem != 0 after cmpelim
17350 optimization. Use COMMUTATIVE_ARITH_P test rather than != MINUS
17351 in the peephole2 before it.
17352
17353 2018-05-14 Sebastian Peryt <sebastian.peryt@intel.com>
17354
17355 * common/config/i386/i386-common.c (OPTION_MASK_ISA_CLDEMOTE_SET,
17356 OPTION_MASK_ISA_CLDEMOTE_UNSET): New defines.
17357 (ix86_handle_option): Handle -mcldemote.
17358 * config.gcc: New header.
17359 * config/i386/cldemoteintrin.h: New file.
17360 * config/i386/cpuid.h (bit_CLDEMOTE): New bit.
17361 * config/i386/driver-i386.c (host_detect_local_cpu): Detect
17362 -mcldemote.
17363 * config/i386/i386-c.c (ix86_target_macros_internal): Handle
17364 OPTION_MASK_ISA_CLDEMOTE.
17365 * config/i386/i386.c (ix86_target_string): Add -mcldemote.
17366 (ix86_valid_target_attribute_inner_p): Ditto.
17367 (enum ix86_builtins): Add IX86_BUILTIN_CLDEMOTE.
17368 (ix86_init_mmx_sse_builtins): Define __builtin_ia32_cldemote.
17369 (ix86_expand_builtin): Expand IX86_BUILTIN_CLDEMOTE.
17370 * config/i386/i386.h (TARGET_CLDEMOTE, TARGET_CLDEMOTE_P): New.
17371 * config/i386/i386.md (UNSPECV_CLDEMOTE): New.
17372 (cldemote): New.
17373 * config/i386/i386.opt: Add -mcldemote.
17374 * config/i386/x86intrin.h: New header.
17375 * doc/invoke.texi: Add -mcldemote.
17376
17377 2018-05-14 Richard Biener <rguenther@suse.de>
17378
17379 * doc/match-and-simplify.texi: Adjust :s documentation.
17380
17381 2018-05-14 Alexander Monakov <amonakov@ispras.ru>
17382
17383 * sort.cc (REORDER_23): Pass the type for the temporaries instead of
17384 intended memcpy size.
17385 (REORDER_45): Likewise.
17386
17387 2018-05-13 Alexander Monakov <amonakov@ispras.ru>
17388
17389 * sort.cc: New file.
17390 * system.h [!CHECKING_P] (qsort): Redirect to gcc_qsort.
17391 * vec.c (qsort_chk): Use gcc_qsort.
17392 * Makefile.in (OBJS-libcommon): Add sort.o.
17393 (build/sort.o): New target. Use it...
17394 (BUILD_RTL): ... here, and...
17395 (build/gencfn-macros): ... here, and...
17396 (build/genmatch): ... here.
17397
17398 2018-05-13 Kito Cheng <kito.cheng@gmail.com>
17399 Chung-Ju Wu <jasonwucj@gmail.com>
17400
17401 * config.gcc (nds32*-*-*): Check that n15 is valid to --with-cpu.
17402 * config/nds32/nds32-graywolf.md: New file.
17403 * config/nds32/nds32-opts.h (nds32_cpu_type): Add CPU_GRAYWOLF.
17404 * config/nds32/nds32-pipelines-auxiliary.c: Implementation for n15
17405 pipeline.
17406 * config/nds32/nds32-protos.h: More declarations for n15 pipeline.
17407 * config/nds32/nds32-utils.c: More implementations for n15 pipeline.
17408 * config/nds32/nds32.md (pipeline_model): Add graywolf.
17409 * config/nds32/nds32.opt (mcpu): Support n15 pipeline cpus.
17410 * config/nds32/pipelines.md: Include n15 settings.
17411
17412 2018-05-13 Kito Cheng <kito.cheng@gmail.com>
17413 Chung-Ju Wu <jasonwucj@gmail.com>
17414
17415 * config.gcc (nds32*-*-*): Check that n12/n13 are valid to --with-cpu.
17416 * config/nds32/nds32-n13.md: New file.
17417 * config/nds32/nds32-opts.h (nds32_cpu_type): Add CPU_N12 and CPU_N13.
17418 * config/nds32/nds32-pipelines-auxiliary.c: Implementation for n12/n13
17419 pipeline.
17420 * config/nds32/nds32-protos.h: More declarations for n12/n13 pipeline.
17421 * config/nds32/nds32.md (pipeline_model): Add n13.
17422 * config/nds32/nds32.opt (mcpu): Support n12/n13 pipeline cpus.
17423 * config/nds32/pipelines.md: Include n13 settings.
17424
17425 2018-05-13 Kito Cheng <kito.cheng@gmail.com>
17426 Chung-Ju Wu <jasonwucj@gmail.com>
17427
17428 * config.gcc (nds32*-*-*): Check that n10/d10 are valid to --with-cpu.
17429 * config/nds32/nds32-n10.md: New file.
17430 * config/nds32/nds32-opts.h (nds32_cpu_type): Add CPU_N10.
17431 * config/nds32/nds32-pipelines-auxiliary.c: Implementation for n10
17432 pipeline.
17433 * config/nds32/nds32-protos.h: More declarations for n10 pipeline.
17434 * config/nds32/nds32-utils.c: More implementations for n10 pipeline.
17435 * config/nds32/nds32.md (pipeline_model): Add n10.
17436 * config/nds32/nds32.opt (mcpu): Support n10 pipeline cpus.
17437 * config/nds32/pipelines.md: Include n10 settings.
17438
17439 2018-05-13 Monk Chiang <sh.chiang04@gmail.com>
17440 Kito Cheng <kito.cheng@gmail.com>
17441 Chung-Ju Wu <jasonwucj@gmail.com>
17442
17443 * config.gcc (nds32be-*-*): Handle --with-ext-dsp.
17444 * config/nds32/constants.md (unspec_element, unspec_volatile_element):
17445 Add enum values for DSP extension instructions.
17446 * config/nds32/constraints.md (Iu06, IU06, CVp5, CVs5, CVs2, CVhi):
17447 New constraints.
17448 * config/nds32/iterators.md (shifts, shiftrt, sat_plus, all_plus,
17449 sat_minus, all_minus, plus_minus, extend, sumax, sumin, sumin_max):
17450 New code iterators.
17451 (su, zs, uk, opcode, add_rsub, add_sub): New code attributes.
17452 * config/nds32/nds32-dspext.md: New file for DSP implementation.
17453 * config/nds32/nds32-intrinsic.c: Implementation of DSP extension.
17454 * config/nds32/nds32-intrinsic.md: Likewise.
17455 * config/nds32/nds32_intrinsic.h: Likewise.
17456 * config/nds32/nds32-md-auxiliary.c: Likewise.
17457 * config/nds32/nds32-memory-manipulation.c: Consider DSP extension.
17458 * config/nds32/nds32-predicates.c (const_vector_to_hwint): New.
17459 (nds32_valid_CVp5_p, nds32_valid_CVs5_p): New.
17460 (nds32_valid_CVs2_p, nds32_valid_CVhi_p): New.
17461 * config/nds32/nds32-protos.h: New declarations for DSP extension.
17462 * config/nds32/nds32-utils.c (extract_mac_non_acc_rtx): New case
17463 TYPE_DMAC in switch statement.
17464 * config/nds32/nds32.c: New checking and implementation for DSP
17465 extension instructions.
17466 * config/nds32/nds32.h: Likewise.
17467 * config/nds32/nds32.md: Likewise.
17468 * config/nds32/nds32.opt (mhw-abs, mext-dsp): New options.
17469 * config/nds32/predicates.md: Implement new predicates for DSP
17470 extension.
17471
17472 2018-05-11 Michael Meissner <meissner@linux.vnet.ibm.com>
17473
17474 * config/rs6000/rs6000.md (mov<mode>_softfloat, FMOVE32):
17475 Reformat alternatives and attributes so it is easier to identify
17476 which constraints/attributes go with which instruction.
17477 (mov<mode>_hardfloat32, FMOVE64): Likewise.
17478 (mov<mode>_softfloat32, FMOVE64): Likewise.
17479 (mov<mode>_hardfloat64, FMOVE64): Likewise.
17480 (mov<mode>_softfloat64, FMOVE64): Likewise.
17481
17482 2018-05-11 Kelvin Nilsen <kelvin@gcc.gnu.org>
17483
17484 * doc/extend.texi (PowerPC Built-in Functions): Rename this
17485 subsection.
17486 (Basic PowerPC Built-in Functions): The new name of the
17487 subsection previously known as "PowerPC Built-in Functions".
17488 (Basic PowerPC Built-in Functions Available on all Configurations):
17489 New subsubsection.
17490 (Basic PowerPC Built-in Functions Available on ISA 2.05): Likewise.
17491 (Basic PowerPC Built-in Functions Available on ISA 2.06): Likewise.
17492 (Basic PowerPC Built-in Functions Available on ISA 2.07): Likewise.
17493 (Basic PowerPC Built-in Functions Available on ISA 3.0): Likewise.
17494
17495 2018-05-11 Martin Jambor <mjambor@suse.cz>
17496
17497 PR ipa/85655
17498 * ipa-cp.c (intersect_with_plats): Check that the lattice contains
17499 single const.
17500
17501 2018-05-11 Richard Earnshaw <rearnsha@arm.com>
17502
17503 PR target/85733
17504 * config/arm/arm-cpus.in (fgroup ARMv6m): Add be8 feature.
17505
17506 2018-05-11 Sebastian Peryt <sebastian.peryt@intel.com>
17507
17508 * common/config/i386/i386-common.c (OPTION_MASK_ISA_WAITPKG_SET,
17509 OPTION_MASK_ISA_WAITPKG_UNSET): New defines.
17510 (ix86_handle_option): Handle -mwaitpkg.
17511 * config.gcc: New header.
17512 * config/i386/cpuid.h (bit_WAITPKG): New bit.
17513 * config/i386/driver-i386.c (host_detect_local_cpu): Detect -mwaitpkg.
17514 * config/i386/i386-builtin-types.def ((UINT8, UNSIGNED, UINT64)): New
17515 function type.
17516 * config/i386/i386-c.c (ix86_target_macros_internal): Handle
17517 OPTION_MASK_ISA_WAITPKG.
17518 * config/i386/i386.c (ix86_target_string): Add -mwaitpkg.
17519 (ix86_option_override_internal): Add PTA_WAITPKG.
17520 (ix86_valid_target_attribute_inner_p): Add -mwaitpkg.
17521 (enum ix86_builtins): Add IX86_BUILTIN_UMONITOR, IX86_BUILTIN_UMWAIT,
17522 IX86_BUILTIN_TPAUSE.
17523 (ix86_init_mmx_sse_builtins): Define __builtin_ia32_umonitor,
17524 __builtin_ia32_umwait and __builtin_ia32_tpause.
17525 (ix86_expand_builtin): Expand IX86_BUILTIN_UMONITOR,
17526 IX86_BUILTIN_UMWAIT, IX86_BUILTIN_TPAUSE.
17527 * config/i386/i386.h (TARGET_WAITPKG, TARGET_WAITPKG_P): New.
17528 * config/i386/i386.md (UNSPECV_UMWAIT, UNSPECV_UMONITOR,
17529 UNSPECV_TPAUSE): New.
17530 (umwait, umwait_rex64, umonitor_<mode>, tpause, tpause_rex64): New.
17531 * config/i386/i386.opt: Add -mwaitpkg.
17532 * config/i386/waitpkgintrin.h: New file.
17533 * config/i386/x86intrin.h: New header.
17534 * doc/invoke.texi: Add -mwaitpkg.
17535
17536 2018-05-11 Richard Earnshaw <rearnsha@arm.com>
17537
17538 PR target/85606
17539 * config/arm/arm-cpus.in: Add comment that ARMv6-m and ARMv6S-m are now
17540 equivalent.
17541 (cortex-m0): Use armv6s-m isa.
17542 (cortex-m0plus): Likewise.
17543 (cortex-m1): Likewise.
17544 (cortex-m0.small-multiply): Likewise.
17545 (cortex-m0plus.small-multiply): Likewise.
17546 (cortex-m1.small-multiply): Likewise.
17547
17548 2018-05-11 Allan Sandfeld Jensen <allan.jensen@qt.io>
17549 Jakub Jelinek <jakub@redhat.com>
17550
17551 PR tree-optimization/85692
17552 * tree-ssa-forwprop.c (simplify_vector_constructor): Try two
17553 source permute as well.
17554
17555 2018-05-11 Martin Liska <mliska@suse.cz>
17556
17557 PR sanitizer/85556
17558 * doc/extend.texi: Document LLVM style format for no_sanitize
17559 attribute.
17560
17561 2018-05-10 Michael Meissner <meissner@linux.vnet.ibm.com>
17562
17563 * config/rs6000/rs6000.c (mode_supports_dq_form): Rename
17564 mode_supports_vsx_dform_quad to mode_supports_dq_form.
17565 (mode_supports_vsx_dform_quad): Likewise.
17566 (mode_supports_vmx_dform): Move these functions to be next to the
17567 other mode_supports functions.
17568 (mode_supports_dq_form): Likewise.
17569 (quad_address_p): Change calls of mode_supports_vsx_dform_quad to
17570 mode_supports_dq_form.
17571 (reg_offset_addressing_ok_p): Likewise.
17572 (offsettable_ok_by_alignment): Likewise.
17573 (rs6000_legitimate_offset_address_p): Likewise.
17574 (legitimate_lo_sum_address_p): Likewise.
17575 (rs6000_legitimize_address): Likewise.
17576 (rs6000_legitimize_reload_address): Likewise.
17577 (rs6000_secondary_reload_inner): Likewise.
17578 (rs6000_preferred_reload_class): Likewise.
17579 (rs6000_output_move_128bit): Likewise.
17580
17581 2018-05-10 Uros Bizjak <ubizjak@gmail.com>
17582
17583 * config/i386/i386.c (ix86_expand_builtin) <case IX86_BUILTIN_RDPID>:
17584 Generate SImode target register for null target.
17585 <case IX86_BUILTIN_XGETBV>: Ditto.
17586 <case IX86_BUILTIN_XSETBV>: Optimize LSHIFTRT generation.
17587 * config/i386/xsaveintrin.h (_xgetbv): Add missing return.
17588
17589 2018-05-10 Carl Love <cel@us.ibm.com>
17590
17591 * config/rs6000/rs6000.md (prefetch): Generate ISA 2.06 instructions
17592 dcbtt and dcbtstt if operands[2] is 0.
17593
17594 2018-05-10 Uros Bizjak <ubizjak@gmail.com>
17595
17596 PR target/85693
17597 * config/i386/sse.md (usadv64qi): New expander.
17598
17599 2018-05-10 Segher Boessenkool <segher@kernel.crashing.org>
17600
17601 * config/rs6000/altivec.md (altivec_vmrghb, altivec_vmrghh,
17602 altivec_vmrghw, altivec_vmrglb, altivec_vmrglh, altivec_vmrglw): Remove
17603 -maltivec=be support.
17604 (vec_widen_umult_even_v16qi, vec_widen_smult_even_v16qi,
17605 vec_widen_umult_even_v8hi, vec_widen_smult_even_v8hi,
17606 vec_widen_umult_even_v4si, vec_widen_smult_even_v4si,
17607 vec_widen_umult_odd_v16qi, vec_widen_smult_odd_v16qi,
17608 vec_widen_umult_odd_v8hi, vec_widen_smult_odd_v8hi,
17609 vec_widen_umult_odd_v4si, vec_widen_smult_odd_v4si, altivec_vpkpx,
17610 altivec_vpks<VI_char>ss, altivec_vpks<VI_char>us,
17611 altivec_vpku<VI_char>us, altivec_vpku<VI_char>um, altivec_vsum2sws,
17612 altivec_vsumsws): Adjust.
17613 (altivec_vspltb *altivec_vspltb_internal, altivec_vsplth,
17614 *altivec_vsplth_internal, altivec_vspltw, *altivec_vspltw_internal,
17615 altivec_vspltsf, *altivec_vspltsf_internal): Remove -maltivec=be
17616 support.
17617 (altivec_vperm_<mode>, altivec_vperm_<mode>_uns,
17618 altivec_vupkhs<VU_char>, altivec_vupkls<VU_char>, altivec_vupkhpx,
17619 altivec_vupklpx, altivec_lvsl, altivec_lvsr): Adjust.
17620 (altivec_lve<VI_char>x): Delete expand.
17621 (*altivec_lve<VI_char>x_internal): Rename to...
17622 (altivec_lve<VI_char>x): ... this.
17623 (altivec_lvxl_<mode>): Delete expand.
17624 (*altivec_lvxl_<mode>_internal): Rename to ...
17625 (altivec_lvxl_<mode>): ... this.
17626 (altivec_stvxl_<mode>): Delete expand.
17627 (*altivec_stvxl_<mode>_internal): Rename to ...
17628 (altivec_stvxl_<mode>): ... this.
17629 (altivec_stve<VI_char>x): Delete expand.
17630 (*altivec_stve<VI_char>x_internal): Rename to ...
17631 (altivec_stve<VI_char>x): ... this.
17632 (doublee<mode>2, unsdoubleev4si2, doubleo<mode>2, unsdoubleov4si2,
17633 doubleh<mode>2, unsdoublehv4si2, doublel<mode>2, unsdoublelv4si2,
17634 reduc_plus_scal_<mode>): Adjust.
17635 * config/rs6000/rs6000-c.c (rs6000_target_modify_macros): Adjust
17636 comment.
17637 (rs6000_cpu_cpp_builtins): Adjust.
17638 (altivec_resolve_overloaded_builtin): Remove -maltivec=be support.
17639 * config/rs6000/rs6000-protos.h (altivec_expand_lvx_be,
17640 altivec_expand_stvx_be, altivec_expand_stvex_be): Delete.
17641 * config/rs6000/rs6000.c (rs6000_option_override_internal): Remove
17642 -maltivec=be support.
17643 (rs6000_split_vec_extract_var): Adjust.
17644 (rs6000_split_v4si_init): Adjust.
17645 (swap_selector_for_mode): Delete.
17646 (altivec_expand_lvx_be, altivec_expand_stvx_be,
17647 altivec_expand_stvex_be): Delete.
17648 (altivec_expand_lv_builtin, altivec_expand_stv_builtin): Remove
17649 -maltivec=be support.
17650 (rs6000_gimple_fold_builtin): Ditto.
17651 (rs6000_generate_float2_double_code, rs6000_generate_float2_code):
17652 Adjust.
17653 * config/rs6000/rs6000.h (VECTOR_ELT_ORDER_BIG): Delete.
17654 (TARGET_DIRECT_MOVE_64BIT): Adjust.
17655 * config/rs6000/rs6000.md (split for extendsidi2 for vectors): Adjust.
17656 * config/rs6000/rs6000.opt (maltivec=le, maltivec=be): Delete.
17657 * config/rs6000/vsx.md (floate<mode>, unsfloatev2di, floato<mode>,
17658 unsfloatov2di, vsignedo_v2df, vsignede_v2df, vunsignedo_v2df,
17659 vunsignede_v2df, vsx_extract_<mode>_p9, *vsx_extract_si,
17660 *vsx_extract_<mode>_p8, *vsx_extract_si_<uns>float_df,
17661 *vsx_extract_si_<uns>float_<mode>, vsx_set_<mode>_p9, vsx_set_v4sf_p9,
17662 *vsx_insert_extract_v4sf_p9, *vsx_insert_extract_v4sf_p9_2, and an
17663 anonymous split): Adjust.
17664 (vsx_mergel_<mode>, vsx_mergeh_<mode>): Remove -maltivec=be support.
17665 (vsx_xxspltd_<mode>, extract4b, insert4b): Adjust.
17666
17667 2018-05-10 Eric Botcazou <ebotcazou@adacore.com>
17668
17669 * configure.ac (gcc_gxx_include_dir_add_sysroot): Set it to 1 only
17670 when --with-gxx-include-dir is also specified.
17671 * configure: Regenerate.
17672
17673 2018-05-09 Jim Wilson <jimw@sifive.com>
17674
17675 PR target/84797
17676 * config.gcc (riscv*-*-*): Handle --with-multilib-list.
17677 * config/riscv/t-withmultilib: New.
17678 * config/riscv/withmultilib.h: New.
17679 * doc/install.texi: Document RISC-V --with-multilib-list support.
17680
17681 2018-05-09 Richard Biener <rguenther@suse.de>
17682
17683 * tree-vect-slp.c (vect_bb_slp_scalar_cost): Fill a cost
17684 vector.
17685 (vect_bb_vectorization_profitable_p): Adjust. Compute
17686 actual scalar cost using the cost vector and the add_stmt_cost
17687 machinery.
17688
17689 2018-05-09 Segher Boessenkool <segher@kernel.crashing.org>
17690
17691 PR rtl-optimization/85645
17692 * config/rs6000/rs6000.c (rs6000_emit_prologue_components): Put a SET
17693 in the REG_CFA_REGISTER note for LR, don't leave it empty.
17694
17695 2018-05-09 Segher Boessenkool <segher@kernel.crashing.org>
17696
17697 PR rtl-optimization/85645
17698 * shrink-wrap.c (spread_components): Return a boolean saying if
17699 anything was changed.
17700 (try_shrink_wrapping_separate): Iterate spread_components until
17701 nothing changes anymore.
17702
17703 2018-05-09 Segher Boessenkool <segher@kernel.crashing.org>
17704
17705 PR rtl-optimization/85645
17706 * regrename.c (build_def_use): Also kill the chains that include the
17707 destination of a REG_CFA_REGISTER note.
17708
17709 2018-05-09 Segher Boessenkool <segher@kernel.crashing.org>
17710
17711 PR rtl-optimization/85645
17712 * regcprop.c (copyprop_hardreg_forward_1): Don't propagate into an
17713 insn that has a REG_CFA_REGISTER note.
17714
17715 2018-05-09 Richard Sandiford <richard.sandiford@linaro.org>
17716
17717 * cfgexpand.c (expand_clobber): New function.
17718 (expand_gimple_stmt_1): Use it.
17719 * tree-vect-stmts.c (vect_clobber_variable): New function,
17720 split out from...
17721 (vectorizable_simd_clone_call): ...here.
17722 (vectorizable_store): Emit a clobber either side of an
17723 IFN_STORE_LANES sequence.
17724 (vectorizable_load): Emit a clobber after an IFN_LOAD_LANES sequence.
17725
17726 2018-05-09 Tom de Vries <tom@codesourcery.com>
17727
17728 PR target/85626
17729 * config/nvptx/nvptx.md (define_insn "trap", define_insn "trap_if_true")
17730 (define_insn "trap_if_false"): Add exit after trap.
17731
17732 2018-05-09 Eric Botcazou <ebotcazou@adacore.com>
17733
17734 PR rtl-optimization/85638
17735 * bb-reorder.c: Include common/common-target.h.
17736 (create_forwarder_block): New function extracted from...
17737 (fix_up_crossing_landing_pad): ...here. Rename into...
17738 (dw2_fix_up_crossing_landing_pad): ...this.
17739 (sjlj_fix_up_crossing_landing_pad): New function.
17740 (find_rarely_executed_basic_blocks_and_crossing_edges): In SJLJ mode,
17741 call sjlj_fix_up_crossing_landing_pad if there are incoming EH edges
17742 from both partitions and exit the loop after one iteration.
17743
17744 2018-05-08 Kelvin Nilsen <kelvin@gcc.gnu.org>
17745
17746 Revert:
17747 * doc/extend.texi (PowerPC Built-in Functions): Rename this
17748 subsection.
17749 (Basic PowerPC Built-in Functions): The new name of the
17750 subsection previously known as "PowerPC Built-in Functions".
17751 (Basic PowerPC Built-in Functions Available on all Configurations):
17752 New subsubsection.
17753 (Basic PowerPC Built-in Functions Available on ISA 2.05): New
17754 subsubsection.
17755 (Basic PowerPC Built-in Functions Available on ISA 2.06): New
17756 subsubsection.
17757 (Basic PowerPC Built-in Functions Available on ISA 2.07): New
17758 subsubsection.
17759 (Basic PowerPC Built-in Functions Available on ISA 3.0): New
17760 subsubsection.
17761
17762 2018-05-08 Jim Wilson <jimw@sifive.com>
17763
17764 * config/riscv/linux.h (MUSL_ABI_SUFFIX): Delete unnecessary backslash.
17765 (LD_EMUL_SUFFIX): New.
17766 (LINK_SPEC): Use it.
17767
17768 2018-05-08 Kelvin Nilsen <kelvin@gcc.gnu.org>
17769
17770 * doc/extend.texi (PowerPC Built-in Functions): Rename this
17771 subsection.
17772 (Basic PowerPC Built-in Functions): The new name of the
17773 subsection previously known as "PowerPC Built-in Functions".
17774 (Basic PowerPC Built-in Functions Available on all Configurations):
17775 New subsubsection.
17776 (Basic PowerPC Built-in Functions Available on ISA 2.05): New
17777 subsubsection.
17778 (Basic PowerPC Built-in Functions Available on ISA 2.06): New
17779 subsubsection.
17780 (Basic PowerPC Built-in Functions Available on ISA 2.07): New
17781 subsubsection.
17782 (Basic PowerPC Built-in Functions Available on ISA 3.0): New
17783 subsubsection.
17784
17785 2018-05-08 Jakub Jelinek <jakub@redhat.com>
17786
17787 PR target/85683
17788 * config/i386/i386.md: Add peepholes for mem {+,-,&,|,^}= x; mem != 0
17789 after cmpelim optimization.
17790
17791 2018-05-08 Olga Makhotina <olga.makhotina@intel.com>
17792
17793 * config.gcc: Support "goldmont".
17794 * config/i386/driver-i386.c (host_detect_local_cpu): Detect "goldmont".
17795 * config/i386/i386-c.c (ix86_target_macros_internal): Handle
17796 PROCESSOR_GOLDMONT.
17797 * config/i386/i386.c (m_GOLDMONT): Define.
17798 (processor_target_table): Add "goldmont".
17799 (PTA_GOLDMONT): Define.
17800 (ix86_lea_outperforms): Add TARGET_GOLDMONT.
17801 (get_builtin_code_for_version): Handle PROCESSOR_GOLDMONT.
17802 (fold_builtin_cpu): Add M_INTEL_GOLDMONT.
17803 (fold_builtin_cpu): Add "goldmont".
17804 (ix86_add_stmt_cost): Add TARGET_GOLDMONT.
17805 (ix86_option_override_internal): Add "goldmont".
17806 * config/i386/i386.h (processor_costs): Define TARGET_GOLDMONT.
17807 (processor_type): Add PROCESSOR_GOLDMONT.
17808 * config/i386/i386.md: Add CPU "glm".
17809 * config/i386/glm.md: New file.
17810 * config/i386/x86-tune.def: Add m_GOLDMONT.
17811 * doc/invoke.texi: Add goldmont as x86 -march=/-mtune= CPU type.
17812
17813 2018-05-08 Jakub Jelinek <jakub@redhat.com>
17814
17815 PR target/85572
17816 * config/i386/i386.c (ix86_expand_sse2_abs): Handle E_V2DImode and
17817 E_V4DImode.
17818 * config/i386/sse.md (abs<mode>2): Use VI_AVX2 iterator instead of
17819 VI1248_AVX512VL_AVX512BW. Handle V2DImode and V4DImode if not
17820 TARGET_AVX512VL using ix86_expand_sse2_abs. Formatting fixes.
17821
17822 PR target/85317
17823 * config/i386/i386.c (ix86_fold_builtin): Handle
17824 IX86_BUILTIN_{,P}MOVMSK{PS,PD,B}{,128,256}.
17825
17826 PR target/85480
17827 * config/i386/sse.md (ssequaterinsnmode): New mode attribute.
17828 (*<extract_type>_vinsert<shuffletype><extract_suf>_0): New pattern.
17829
17830 2018-05-08 Richard Earnshaw <rearnsha@arm.com>
17831
17832 PR target/85658
17833 * config/arm/parsecpu.awk (check_cpu): Fix operator precedence.
17834 (check_arch): Likewise.
17835 (check_fpu): Return the result rather than printing it.
17836 (end arch): Fix operator precedence.
17837 (end cpu): Likewise.
17838 (END): Print the result from check_fpu.
17839
17840 2018-05-08 Richard Sandiford <richard.sandiford@linaro.org>
17841 Alan Hayward <alan.hayward@arm.com>
17842 David Sherwood <david.sherwood@arm.com>
17843
17844 * config/aarch64/aarch64-sve.md (*pred_cmp<cmp_op><mode>_combine)
17845 (*pred_cmp<cmp_op><mode>, *fcm<cmp_op><mode>_and_combine)
17846 (*fcmuo<mode>_and_combine, *fcm<cmp_op><mode>_and)
17847 (*fcmuo<mode>_and): New patterns.
17848
17849 2018-05-08 Richard Sandiford <richard.sandiford@linaro.org>
17850
17851 * config/aarch64/iterators.md (UNSPEC_COND_LO, UNSPEC_COND_LS)
17852 (UNSPEC_COND_HI, UNSPEC_COND_HS, UNSPEC_COND_UO): Delete.
17853 (SVE_INT_CMP, SVE_FP_CMP): New code iterators.
17854 (cmp_op, sve_imm_con): New code attributes.
17855 (SVE_COND_INT_CMP, imm_con): Delete.
17856 (cmp_op): Remove above unspecs from int attribute.
17857 * config/aarch64/aarch64-sve.md (*vec_cmp<cmp_op>_<mode>): Rename
17858 to...
17859 (*cmp<cmp_op><mode>): ...this. Use UNSPEC_MERGE_PTRUE instead of
17860 comparison-specific unspecs.
17861 (*vec_cmp<cmp_op>_<mode>_ptest): Rename to...
17862 (*cmp<cmp_op><mode>_ptest): ...this and adjust likewise.
17863 (*vec_cmp<cmp_op>_<mode>_cc): Rename to...
17864 (*cmp<cmp_op><mode>_cc): ...this and adjust likewise.
17865 (*vec_fcm<cmp_op><mode>): Rename to...
17866 (*fcm<cmp_op><mode>): ...this and adjust likewise.
17867 (*vec_fcmuo<mode>): Rename to...
17868 (*fcmuo<mode>): ...this and adjust likewise.
17869 (*pred_fcm<cmp_op><mode>): New pattern.
17870 * config/aarch64/aarch64.c (aarch64_emit_unop, aarch64_emit_binop)
17871 (aarch64_emit_sve_ptrue_op, aarch64_emit_sve_ptrue_op_cc): New
17872 functions.
17873 (aarch64_unspec_cond_code): Remove handling of LTU, GTU, LEU, GEU
17874 and UNORDERED.
17875 (aarch64_gen_unspec_cond, aarch64_emit_unspec_cond): Delete.
17876 (aarch64_emit_sve_predicated_cond): New function.
17877 (aarch64_expand_sve_vec_cmp_int): Use aarch64_emit_sve_ptrue_op_cc.
17878 (aarch64_emit_unspec_cond_or): Replace with...
17879 (aarch64_emit_sve_or_conds): ...this new function. Use
17880 aarch64_emit_sve_ptrue_op for the individual comparisons and
17881 aarch64_emit_binop to OR them together.
17882 (aarch64_emit_inverted_unspec_cond): Replace with...
17883 (aarch64_emit_sve_inverted_cond): ...this new function. Use
17884 aarch64_emit_sve_ptrue_op for the comparison and
17885 aarch64_emit_unop to invert the result.
17886 (aarch64_expand_sve_vec_cmp_float): Update after the above
17887 changes. Use aarch64_emit_sve_ptrue_op for native comparisons.
17888
17889 2018-05-07 Nathan Sidwell <nathan@acm.org>
17890
17891 * doc/invoke.texi (C++ Dialect Options): Remove -ffor-scope.
17892 * doc/extend.texi (Deprecated Features): Remove -fno-for-scope
17893 (Backwards Compatibility): Likewise.
17894
17895 2018-05-07 Luis Machado <luis.machado@linaro.org>
17896
17897 PR bootstrap/85681
17898 Revert:
17899 2018-05-07 Luis Machado <luis.machado@linaro.org>
17900
17901 * config/aarch64/aarch64-protos.h (cpu_prefetch_tune)
17902 <prefetch_dynamic_strides>: New const bool field.
17903 * config/aarch64/aarch64.c (generic_prefetch_tune): Update to include
17904 prefetch_dynamic_strides.
17905 (exynosm1_prefetch_tune): Likewise.
17906 (thunderxt88_prefetch_tune): Likewise.
17907 (thunderx_prefetch_tune): Likewise.
17908 (thunderx2t99_prefetch_tune): Likewise.
17909 (qdf24xx_prefetch_tune): Likewise. Set prefetch_dynamic_strides
17910 to false.
17911 (aarch64_override_options_internal): Update to set
17912 PARAM_PREFETCH_DYNAMIC_STRIDES.
17913 * doc/invoke.texi (prefetch-dynamic-strides): Document new option.
17914 * params.def (PARAM_PREFETCH_DYNAMIC_STRIDES): New.
17915 * params.h (PARAM_PREFETCH_DYNAMIC_STRIDES): Define.
17916 * tree-ssa-loop-prefetch.c (should_issue_prefetch_p): Account for
17917 prefetch-dynamic-strides setting.
17918
17919 2018-05-07 Luis Machado <luis.machado@linaro.org>
17920
17921 * config/aarch64/aarch64-protos.h (cpu_prefetch_tune)
17922 <minimum_stride>: New const int field.
17923 * config/aarch64/aarch64.c (generic_prefetch_tune): Update to include
17924 minimum_stride field.
17925 (exynosm1_prefetch_tune): Likewise.
17926 (thunderxt88_prefetch_tune): Likewise.
17927 (thunderx_prefetch_tune): Likewise.
17928 (thunderx2t99_prefetch_tune): Likewise.
17929 (qdf24xx_prefetch_tune): Likewise. Set minimum_stride to 2048.
17930 (aarch64_override_options_internal): Update to set
17931 PARAM_PREFETCH_MINIMUM_STRIDE.
17932 * doc/invoke.texi (prefetch-minimum-stride): Document new option.
17933 * params.def (PARAM_PREFETCH_MINIMUM_STRIDE): New.
17934 * params.h (PARAM_PREFETCH_MINIMUM_STRIDE): Define.
17935 * tree-ssa-loop-prefetch.c (should_issue_prefetch_p): Return false if
17936 stride is constant and is below the minimum stride threshold.
17937
17938 2018-05-07 Luis Machado <luis.machado@linaro.org>
17939
17940 * config/aarch64/aarch64.c (qdf24xx_prefetch_tune) <l2_cache_size>: Set
17941 to 512.
17942
17943 2018-05-07 Luis Machado <luis.machado@linaro.org>
17944
17945 * config/aarch64/aarch64-protos.h (cpu_prefetch_tune)
17946 <prefetch_dynamic_strides>: New const bool field.
17947 * config/aarch64/aarch64.c (generic_prefetch_tune): Update to include
17948 prefetch_dynamic_strides.
17949 (exynosm1_prefetch_tune): Likewise.
17950 (thunderxt88_prefetch_tune): Likewise.
17951 (thunderx_prefetch_tune): Likewise.
17952 (thunderx2t99_prefetch_tune): Likewise.
17953 (qdf24xx_prefetch_tune): Likewise. Set prefetch_dynamic_strides
17954 to false.
17955 (aarch64_override_options_internal): Update to set
17956 PARAM_PREFETCH_DYNAMIC_STRIDES.
17957 * doc/invoke.texi (prefetch-dynamic-strides): Document new option.
17958 * params.def (PARAM_PREFETCH_DYNAMIC_STRIDES): New.
17959 * params.h (PARAM_PREFETCH_DYNAMIC_STRIDES): Define.
17960 * tree-ssa-loop-prefetch.c (should_issue_prefetch_p): Account for
17961 prefetch-dynamic-strides setting.
17962
17963 2018-05-07 Luis Machado <luis.machado@linaro.org>
17964
17965 * config/aarch64/aarch64-protos.h (cpu_prefetch_tune)
17966 <minimum_stride>: New const int field.
17967 * config/aarch64/aarch64.c (generic_prefetch_tune): Update to include
17968 minimum_stride field.
17969 (exynosm1_prefetch_tune): Likewise.
17970 (thunderxt88_prefetch_tune): Likewise.
17971 (thunderx_prefetch_tune): Likewise.
17972 (thunderx2t99_prefetch_tune): Likewise.
17973 (qdf24xx_prefetch_tune): Likewise. Set minimum_stride to 2048.
17974 (aarch64_override_options_internal): Update to set
17975 PARAM_PREFETCH_MINIMUM_STRIDE.
17976 * doc/invoke.texi (prefetch-minimum-stride): Document new option.
17977 * params.def (PARAM_PREFETCH_MINIMUM_STRIDE): New.
17978 * params.h (PARAM_PREFETCH_MINIMUM_STRIDE): Define.
17979 * tree-ssa-loop-prefetch.c (should_issue_prefetch_p): Return false if
17980 stride is constant and is below the minimum stride threshold.
17981
17982 2018-05-06 Jakub Jelinek <jakub@redhat.com>
17983
17984 PR c++/85659
17985 * cfgexpand.c (expand_asm_stmt): Don't create a temporary if
17986 the type is addressable. Don't force op into register if it has
17987 BLKmode.
17988
17989 2018-05-05 Roland McGrath <mcgrathr@google.com>
17990
17991 PR other/77609
17992 * varasm.c (default_section_type_flags): Set SECTION_NOTYPE for
17993 any section for which we don't know a specific type it should have,
17994 regardless of name. Previously this was done only for the exact
17995 names ".init_array", ".fini_array", and ".preinit_array".
17996 (default_elf_asm_named_section): Add comment about
17997 relationship with default_section_type_flags and SECTION_NOTYPE.
17998 (get_section): Don't consider it a type conflict if one side has
17999 SECTION_NOTYPE and the other doesn't, as long as neither has the
18000 SECTION_BSS et al used in the default_section_type_flags logic.
18001
18002 2018-05-05 Tom de Vries <tom@codesourcery.com>
18003
18004 PR target/85653
18005 * config/nvptx/nvptx.c (WORKAROUND_PTXJIT_BUG_3): Define.
18006 (workaround_barsyncs): New function.
18007 (nvptx_reorg): Use workaround_barsyncs.
18008 * config/nvptx/nvptx.md (define_c_enum "unspecv"): Add UNSPECV_MEMBAR.
18009 (define_expand "nvptx_membar_cta"): New define_expand.
18010 (define_insn "*nvptx_membar_cta"): New insn.
18011
18012 2018-05-04 Pekka Jääskeläinen <pekka.jaaskelainen@parmance.com>
18013
18014 * brig-builtins.def: Add consts to ptrs etc. in BRIG builtin defs.
18015 To improve optimization opportunities.
18016 * builtin-types.def: The new needed builtin types for the above.
18017
18018 2018-05-04 Richard Biener <rguenther@suse.de>
18019
18020 * bb-reorder.c (sanitize_hot_paths): Release hot_bbs_to_check.
18021 * gimple-ssa-store-merging.c
18022 (imm_store_chain_info::output_merged_store): Remove redundant create,
18023 release split_store vector contents on failure.
18024 * tree-vect-slp.c (vect_schedule_slp_instance): Avoid leaking
18025 scalar stmt vector on cache hit.
18026
18027 2018-05-04 Segher Boessenkool <segher@kernel.crashing.org>
18028
18029 * common/config/rs6000/rs6000-common.c (rs6000_handle_option): Remove
18030 Xilinx FP support.
18031 * config.gcc (powerpc-xilinx-eabi*): Remove.
18032 * config/rs6000/predicates.md (easy_fp_constant): Remove Xilinx FP
18033 support.
18034 (fusion_addis_mem_combo_load): Ditto.
18035 * config/rs6000/rs6000-c.c (rs6000_target_modify_macros): Remove Xilinx
18036 FP support.
18037 (rs6000_cpu_cpp_builtins): Ditto.
18038 * config/rs6000/rs6000-linux.c
18039 (rs6000_linux_float_exceptions_rounding_supported_p): Ditto.
18040 * config/rs6000/rs6000-opts.h (enum fpu_type_t): Delete.
18041 * config/rs6000/rs6000.c (rs6000_debug_reg_global): Remove Xilinx FP
18042 support.
18043 (rs6000_setup_reg_addr_masks): Ditto.
18044 (rs6000_init_hard_regno_mode_ok): Ditto.
18045 (rs6000_option_override_internal): Ditto.
18046 (legitimate_lo_sum_address_p): Ditto.
18047 (rs6000_legitimize_address): Ditto.
18048 (rs6000_legitimize_reload_address): Ditto.
18049 (rs6000_legitimate_address_p): Ditto.
18050 (abi_v4_pass_in_fpr): Ditto.
18051 (setup_incoming_varargs): Ditto.
18052 (rs6000_gimplify_va_arg): Ditto.
18053 (rs6000_split_multireg_move): Ditto.
18054 (rs6000_savres_strategy): Ditto.
18055 (rs6000_emit_prologue_components): Ditto.
18056 (rs6000_emit_epilogue_components): Ditto.
18057 (rs6000_emit_prologue): Ditto.
18058 (rs6000_emit_epilogue): Ditto.
18059 (rs6000_elf_file_end): Ditto.
18060 (rs6000_function_value): Ditto.
18061 (rs6000_libcall_value): Ditto.
18062 * config/rs6000/rs6000.h: Ditto.
18063 (TARGET_MINMAX_SF, TARGET_MINMAX_DF): Delete, merge to ...
18064 (TARGET_MINMAX): ... this. New.
18065 (TARGET_SF_FPR, TARGET_DF_FPR, TARGET_SF_INSN, TARGET_DF_INSN): Delete.
18066 * config/rs6000/rs6000.md: Remove Xilinx FP support.
18067 (*movsi_internal1_single): Delete.
18068 * config/rs6000/rs6000.opt (msingle-float, mdouble-float, msimple-fpu,
18069 mfpu=, mxilinx-fpu): Delete.
18070 * config/rs6000/singlefp.h: Delete.
18071 * config/rs6000/sysv4.h: Remove Xilinx FP support.
18072 * config/rs6000/t-rs6000: Ditto.
18073 * config/rs6000/t-xilinx: Delete.
18074 * config/rs6000/titan.md: Adjust for fp_type removal.
18075 * config/rs6000/vsx.md: Remove Xilinx FP support.
18076 (VStype_simple): Delete.
18077 (VSfptype_simple, VSfptype_mul, VSfptype_div, VSfptype_sqrt): Delete.
18078 * config/rs6000/xfpu.h: Delete.
18079 * config/rs6000/xfpu.md: Delete.
18080 * config/rs6000/xilinx.h: Delete.
18081 * config/rs6000/xilinx.opt: Delete.
18082 * doc/invoke.texi (RS/6000 and PowerPC Options): Remove
18083 -msingle-float, -mdouble-float, -msimple-fpu, -mfpu=, and -mxilinx-fpu.
18084
18085 2018-05-04 Tom de Vries <tom@codesourcery.com>
18086
18087 PR libgomp/85639
18088 * builtins.c (expand_builtin_goacc_parlevel_id_size): Handle null target
18089 if ignore == 0.
18090
18091 2018-05-04 Richard Biener <rguenther@suse.de>
18092
18093 PR middle-end/85627
18094 * tree-complex.c (update_complex_assignment): We are always in SSA form.
18095 (expand_complex_div_wide): Likewise.
18096 (expand_complex_operations_1): Likewise.
18097 (expand_complex_libcall): Preserve EH info of the original stmt.
18098 (tree_lower_complex): Handle removed blocks.
18099 * tree.c (build_common_builtin_nodes): Do not set ECF_NOTRHOW
18100 on complex multiplication and division libcall builtins.
18101
18102 2018-05-04 Richard Biener <rguenther@suse.de>
18103
18104 PR middle-end/85574
18105 * fold-const.c (negate_expr_p): Restrict negation of operand
18106 zero of a division to when we know that can happen without
18107 overflow.
18108 (fold_negate_expr_1): Likewise.
18109
18110 2018-05-04 Jakub Jelinek <jakub@redhat.com>
18111
18112 PR libstdc++/85466
18113 * real.h (real_nextafter): Declare.
18114 * real.c (real_nextafter): New function.
18115 * fold-const-call.c (fold_const_nextafter): New function.
18116 (fold_const_call_sss): Call it for CASE_CFN_NEXTAFTER and
18117 CASE_CFN_NEXTTOWARD.
18118 (fold_const_call_1): For CASE_CFN_NEXTTOWARD call fold_const_call_sss
18119 even when arg1_mode is different from arg0_mode.
18120
18121 2018-05-03 Nathan Sidwell <nathan@acm.org>
18122
18123 * doc/extend.texi (Deprecated Features): Remove
18124 -ffriend-injection.
18125 (Backwards Compatibility): Likewise.
18126 * doc/invoke.texi (C++ Language Options): Likewise.
18127 (C++ Dialect Options): Likewise.
18128
18129 2018-05-03 Jakub Jelinek <jakub@redhat.com>
18130
18131 PR target/85530
18132 * config/i386/avx512fintrin.h (_mm512_mullox_epi64,
18133 _mm512_mask_mullox_epi64): New intrinsics.
18134
18135 2018-05-03 Tom de Vries <tom@codesourcery.com>
18136
18137 PR testsuite/85106
18138 * doc/sourcebuild.texi (Commands for use in dg-final, Scan optimization
18139 dump files): Add offload-tree.
18140
18141 2018-05-03 Richard Biener <rguenther@suse.de>
18142
18143 PR tree-optimization/85615
18144 * tree-ssa-threadupdate.c (thread_block_1): Only allow exits
18145 to loops not nested in BBs loop father to avoid creating multi-entry
18146 loops.
18147
18148 2018-05-03 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
18149
18150 PR tree-optimization/70291
18151 * tree-complex.c (expand_complex_libcall): Add type, inplace_p
18152 arguments. Change return type to tree. Emit libcall as a new
18153 statement rather than replacing existing one when inplace_p is true.
18154 (expand_complex_multiplication_components): New function.
18155 (expand_complex_multiplication): Expand floating-point complex
18156 multiplication using the above.
18157 (expand_complex_division): Rename inner_type parameter to type.
18158 Update expand_complex_libcall call-site.
18159 (expand_complex_operations_1): Update expand_complex_multiplication
18160 and expand_complex_division call-sites.
18161
18162 2018-05-02 Jakub Jelinek <jakub@redhat.com>
18163
18164 PR target/85582
18165 * config/i386/i386.md (*ashl<dwi>3_doubleword_mask,
18166 *ashl<dwi>3_doubleword_mask_1, *<shift_insn><dwi>3_doubleword_mask,
18167 *<shift_insn><dwi>3_doubleword_mask_1): In condition require that
18168 the highest significant bit of the shift count mask is clear. In
18169 check whether and[sq]i3 is needed verify that all significant bits
18170 of the shift count other than the highest are set.
18171
18172 2018-05-02 Tom de Vries <tom@codesourcery.com>
18173
18174 PR libgomp/82428
18175 * builtins.def (DEF_GOACC_BUILTIN_ONLY): Define.
18176 * omp-builtins.def (BUILT_IN_GOACC_PARLEVEL_ID)
18177 (BUILT_IN_GOACC_PARLEVEL_SIZE): New builtin.
18178 * builtins.c (expand_builtin_goacc_parlevel_id_size): New function.
18179 (expand_builtin): Call expand_builtin_goacc_parlevel_id_size.
18180 * doc/extend.texi (Other Builtins): Add __builtin_goacc_parlevel_id and
18181 __builtin_goacc_parlevel_size.
18182
18183 2018-05-02 Richard Biener <rguenther@suse.de>
18184
18185 PR tree-optimization/85597
18186 * tree-vect-stmts.c (vectorizable_operation): For ternary SLP
18187 do not use split vect_get_vec_defs call but call vect_get_slp_defs
18188 directly.
18189
18190 2018-05-02 Tom de Vries <tom@codesourcery.com>
18191
18192 PR testsuite/85106
18193 * doc/sourcebuild.texi (Commands for use in dg-final, Scan optimization
18194 dump files): Add ltrans-tree.
18195
18196 2018-05-02 Tom de Vries <tom@codesourcery.com>
18197
18198 PR testsuite/85106
18199 * doc/sourcebuild.texi (Commands for use in dg-final, Scan optimization
18200 dump files): Add wpa-ipa.
18201
18202 2018-05-02 Segher Boessenkool <segher@kernel.crashing.org>
18203
18204 * config.gcc (powerpc*-*-*): Remove paired.h. Unsupport the
18205 powerpc*-*-linux*paired* target.
18206 * config/rs6000/750cl.h: Delete.
18207 * config/rs6000/paired.h: Delete.
18208 * config/rs6000/paired.md: Delete.
18209 * config/rs6000/predicates.md (easy_vector_constant): Remove paired
18210 float support.
18211 * config/rs6000/rs6000-builtin.def: Remove paired float support.
18212 * config/rs6000/rs6000-c.c (rs6000_target_modify_macros): Update
18213 comment. Remove paired float support.
18214 * config/rs6000/rs6000-modes.def: Remove V2SF and V2SI.
18215 * config/rs6000/rs6000-opts.h (enum rs6000_vector): Delete
18216 VECTOR_PAIRED.
18217 * config/rs6000/rs6000-protos.h (paired_expand_vector_init,
18218 paired_emit_vector_cond_expr, paired_expand_vector_move): Delete
18219 declarations.
18220 * config/rs6000/rs6000.c: Remove paired float support.
18221 (paired_expand_vector_init, paired_expand_vector_move,
18222 paired_emit_vector_compare, paired_emit_vector_cond_expr,
18223 (paired_expand_lv_builtin, paired_expand_stv_builtin,
18224 paired_expand_builtin, paired_expand_predicate_builtin,
18225 paired_init_builtins): Delete.
18226 * config/rs6000/rs6000.h: Remove paired float support.
18227 * config/rs6000/rs6000.md: Remove paired float support.
18228 (move_from_CR_ov_bit): Delete.
18229 * config/rs6000/rs6000.opt (mpaired): Delete.
18230 * config/rs6000/t-rs6000: Remove paired.md from MD_INCLUDES.
18231 * doc/invoke.texi (RS/6000 and PowerPC Options): Delete -mpaired.
18232
18233 2018-05-02 Richard Biener <rguenther@suse.de>
18234
18235 PR middle-end/85567
18236 * gimplify.c (gimplify_save_expr): When in SSA form allow
18237 SAVE_EXPRs to compute to SSA vars.
18238
18239 2018-05-02 Jakub Jelinek <jakub@redhat.com>
18240
18241 PR target/85582
18242 * config/i386/i386.md (*ashl<dwi>3_doubleword_mask,
18243 *ashl<dwi>3_doubleword_mask_1, *<shift_insn><dwi>3_doubleword_mask,
18244 *<shift_insn><dwi>3_doubleword_mask_1): If and[sq]i3 is needed, don't
18245 clobber operands[2], instead use a new pseudo. Formatting fixes.
18246
18247 2018-05-02 Richard Sandiford <richard.sandiford@linaro.org>
18248
18249 PR tree-optimization/85586
18250 * tree-vect-data-refs.c (vect_analyze_data_ref_dependence): Only
18251 exit early for statements in the same group if the accesses are
18252 not strided.
18253
18254 2018-05-02 Tom de Vries <tom@codesourcery.com>
18255
18256 PR lto/85451
18257 * lto-wrapper.c (compile_offload_image): Add "could not find mkoffload"
18258 error message.
18259
18260 2018-05-01 Marc Glisse <marc.glisse@inria.fr>
18261
18262 PR tree-optimization/85143
18263 * match.pd (A<B&A<C): Extend to BIT_IOR_EXPR.
18264
18265 2018-05-01 Tom de Vries <tom@codesourcery.com>
18266
18267 PR lto/85451
18268 * config/nvptx/mkoffload.c (main): Suggest using -B in "offload compiler
18269 not found" error message.
18270
18271 2018-05-01 Tom de Vries <tom@codesourcery.com>
18272
18273 PR other/83786
18274 * vec.h (VEC_ORDERED_REMOVE_IF, VEC_ORDERED_REMOVE_IF_FROM_TO): Define.
18275 * vec.c (test_ordered_remove_if): New function.
18276 (vec_c_tests): Call test_ordered_remove_if.
18277 * dwarf2cfi.c (connect_traces): Use VEC_ORDERED_REMOVE_IF_FROM_TO.
18278 * lto-streamer-out.c (prune_offload_funcs): Use VEC_ORDERED_REMOVE_IF.
18279 * tree-vect-patterns.c (vect_pattern_recog_1): Use
18280 VEC_ORDERED_REMOVE_IF.
18281
18282 2018-05-01 Prathamesh Kulkarni <prathamesh.kulkarni@linaro.org>
18283
18284 PR tree-optimization/82665
18285 * vr-values.c (vr_values::extract_range_from_binary_expr): Handle
18286 pointer subtraction where arguments come from a memchr call.
18287
18288 2018-05-01 Jakub Jelinek <jakub@redhat.com>
18289
18290 * configure.ac (LD_AS_NEEDED_OPTION, LD_NO_AS_NEEDED_OPTION): Use
18291 --push-state --as-needed and --pop-state instead of --as-needed and
18292 --no-as-needed if ld supports it.
18293 * configure: Regenerated.
18294
18295 PR web/85578
18296 * doc/install.texi2html: Replace _002d with - and _002a with * in
18297 generated html files using sed.
18298
18299 2018-04-30 David Malcolm <dmalcolm@redhat.com>
18300
18301 PR c++/85523
18302 * gcc-rich-location.c (blank_line_before_p): New function.
18303 (use_new_line): New function.
18304 (gcc_rich_location::add_fixit_insert_formatted): New function.
18305 * gcc-rich-location.h
18306 (gcc_rich_location::add_fixit_insert_formatted): New function.
18307
18308 2018-04-30 David Malcolm <dmalcolm@redhat.com>
18309
18310 * selftest.c (assert_streq): Rename "expected" and "actual" to
18311 "val1" and "val2". Extend NULL-handling to cover both inputs
18312 symmetrically, while still requiring both to be non-NULL for a pass.
18313 * selftest.h (assert_streq): Rename "expected" and "actual" to
18314 "val1" and "val2".
18315 (ASSERT_EQ): Likewise.
18316 (ASSERT_EQ_AT): Likewise.
18317 (ASSERT_KNOWN_EQ): Likewise.
18318 (ASSERT_KNOWN_EQ_AT): Likewise.
18319 (ASSERT_NE): Likewise.
18320 (ASSERT_MAYBE_NE): Likewise.
18321 (ASSERT_MAYBE_NE_AT): Likewise.
18322 (ASSERT_STREQ): Likewise. Clarify that both must be non-NULL for
18323 the assertion to pass.
18324 (ASSERT_STREQ_AT): Likewise.
18325
18326 2018-04-30 Jonathan Wakely <jwakely@redhat.com>
18327
18328 * doc/invoke.texi (-fpie, -fPIE): Fix grammar and clarify
18329 interaction with -pie.
18330
18331 2018-04-30 David Malcolm <dmalcolm@redhat.com>
18332
18333 * selftest.h: Fix alphabetization of per-source-file selftest
18334 declarations.
18335
18336 2018-04-30 Jason Merrill <jason@redhat.com>
18337
18338 PR c++/61982 - dead stores to destroyed objects.
18339 * gimplify.c (gimplify_modify_expr): Simplify complex lvalue on LHS
18340 of clobber.
18341
18342 2018-04-30 Jason Merrill <jason@redhat.com>
18343
18344 * tree.c (build_clobber): New.
18345 * tree.h: Declare it.
18346 * gimplify.c (gimplify_bind_expr, gimplify_target_expr): Use it.
18347
18348 2018-04-30 David Malcolm <dmalcolm@redhat.com>
18349
18350 * diagnostic-show-locus.c (layout::layout): Update for
18351 location_get_source_line returning a char_span.
18352 (struct char_span): Move to input.h.
18353 (struct correction): Update for fields in char_span becoming
18354 private.
18355 (struct source_line): Update for location_get_source_line
18356 returning a char_span.
18357 (layout::print_line): Likewise.
18358 * edit-context.c (edited_file::print_content): Likewise.
18359 (edited_file::print_diff_hunk): Likewise.
18360 (edited_file::print_run_of_changed_lines): Likewise.
18361 (edited_file::get_num_lines): Likewise.
18362 (edited_line::edited_line): Likewise.
18363 * final.c (asm_show_source): Likewise.
18364 * input.c (location_get_source_line): Convert return type
18365 from const char * to char_span, losing the final "line_len"
18366 param.
18367 (dump_location_info): Update for the above.
18368 (get_substring_ranges_for_loc): Likewise. Use a char_span
18369 when handling the literal within the line.
18370 (test_reading_source_line): Update for location_get_source_line
18371 returning a char_span.
18372 * input.h (class char_span): Move here from
18373 diagnostic-show-locus.c, converting from a struct to a class.
18374 Make data members private.
18375 (char_span::operator bool): New.
18376 (char_span::length): New.
18377 (char_span::get_buffer): New.
18378 (char_span::operator[]): New.
18379 (char_span::subspan): Make const.
18380 (char_span::xstrdup): New.
18381 (location_get_source_line): Convert return type from const char *
18382 to char_span, losing the final "line_size" param.
18383
18384 2018-04-30 Jan Hubicka <jh@suse.cz>
18385
18386 * lto-wrapper.c (ltrans_priorities): New static var.
18387 (cmp_priority): New.
18388 (run_gcc): Read priorities and if doing parallel build order
18389 the Makefile by them.
18390
18391 2018-04-30 David Malcolm <dmalcolm@redhat.com>
18392
18393 * input.h (builtins_location_check): Convert to a STATIC_ASSERT.
18394
18395 2018-04-30 Richard Biener <rguenther@suse.de>
18396
18397 * tree-cfg.c (verify_address): Remove base argument, add
18398 flag whether to check TREE_ADDRESSABLE and do that.
18399 (verify_expr): Remove.
18400 (verify_types_in_gimple_reference): Add pieces from verify_expr.
18401 (verify_gimple_assign_single): Likewise.
18402 (verify_gimple_switch): Likewise.
18403 (verify_expr_location_1): Dereference tp once. Add (disabled)
18404 piece from verify_expr.
18405 (verify_gimple_in_cfg): Do not call verify_expr on all ops.
18406
18407 2018-04-30 Claudiu Zissulescu <claziss@synopsys.com>
18408
18409 * config/arc/linux.h (CLEAR_INSN_CACHE): Define.
18410
18411 2018-04-30 Claudiu Zissulescu <claziss@synopsys.com>
18412
18413 * config/arc/arc-protos.h (prepare_extend_operands): Remove.
18414 (small_data_pattern): Likewise.
18415 (arc_rewrite_small_data): Likewise.
18416 * config/arc/arc.c (LEGITIMATE_SMALL_DATA_OFFSET_P): Remove.
18417 (LEGITIMATE_SMALL_DATA_ADDRESS_P): Likewise.
18418 (get_symbol_alignment): New function.
18419 (legitimate_small_data_address_p): Likewise.
18420 (legitimate_scaled_address): Update, call
18421 legitimate_small_data_address_p.
18422 (output_sdata): New static variable.
18423 (arc_print_operand): Update how we handle small data operands.
18424 (arc_print_operand_address): Likewise.
18425 (arc_legitimate_address_p): Update, use
18426 legitimate_small_data_address_p.
18427 (arc_rewrite_small_data_p): Remove.
18428 (arc_rewrite_small_data_1): Likewise.
18429 (arc_rewrite_small_data): Likewise.
18430 (small_data_pattern): Likewise.
18431 (compact_sda_memory_operand): Update to use
18432 legitimate_small_data_address_p and get_symbol_alignment.
18433 (prepare_move_operands): Don't rewite sdata pattern.
18434 (prepare_extend_operands): Remove.
18435 * config/arc/arc.md (zero_extendqihi2): Don't rewrite sdata
18436 pattern.
18437 (zero_extendqisi2): Likewise.
18438 (zero_extendhisi2): Likewise.
18439 (extendqihi2): Likewise.
18440 (extendqisi2): Likewise.
18441 (extendhisi2): Likewise.
18442 (addsi3): Likewise.
18443 (subsi3): Likewise.
18444 (andsi3): Likewise.
18445 * config/arc/constraints.md (Usd): Change it to memory constraint.
18446
18447 2018-04-30 Claudiu Zissulescu <claziss@synopsys.com>
18448
18449 * config/arc/arc.c (arc_split_move): Allow signed 6-bit constants
18450 as source of std instructions.
18451 * config/arc/arc.md (movsi_insn): Update pattern predicate to
18452 allow 6-bit constants as source for store instructions.
18453 (movdi_insn): Update instruction pattern to allow 6-bit constants
18454 as source for store instructions.
18455
18456 2018-04-30 Jonathan Wakely <jwakely@redhat.com>
18457
18458 * doc/invoke.texi (-fdebug-types-section): Fix grammar.
18459
18460 2018-04-30 Nathan Sidwell <nathan@acm.org>
18461 Sandra Loosemore <sandra@codesourcery.com>
18462
18463 * dumpfile.c (dump_open): Allow '-' for stdout.
18464 * doc/invoke.texi (Developer Options): Document dump filename
18465 determination early. Document stdin/stdout selection.
18466
18467 2018-04-30 Andrew Sadek <andrew.sadek.se@gmail.com>
18468
18469 Microblaze Target: PIC data text relative
18470
18471 * config/microblaze/microblaze.opt: add new option -mpic-data-text-rel.
18472 * config/microblaze/microblaze-protos.h (microblaze_constant_address_p):
18473 Add declaration.
18474 * config/microblaze/microblaze.h (microblaze_constant_address_p):
18475 CONSTANT_ADDRESS_P definition to microblaze_constant_address_p.
18476 * config/microblaze/microblaze.c (TARGET_PIC_DATA_TEXT_REL):
18477 New addressing mode for data-text relative position indepenedent code.
18478 (microblaze_classify_unspec): add 'UNSPEC_TEXT' case ->
18479 'ADDRESS_SYMBOLIC_TXT_REL'.
18480 (microblaze_classify_address): Add handling for UNSPEC + CONST_INT.
18481 (microblaze_legitimate_pic_operand): Exclude function calls from
18482 pic operands in case of TARGET_PIC_DATA_TEXT_REL option.
18483 (microblaze_legitimize_address): Generate 'UNSPEC_TEXT' for all possible
18484 addresses cases.
18485 (microblaze_address_insns): Add 'ADDRESS_SYMBOLIC_TXT_REL' case.
18486 (print_operand): Add 'ADDRESS_SYMBOLIC_TXT_REL' case.
18487 (print_operand_address): Add 'ADDRESS_SYMBOLIC_TXT_REL' case + handling
18488 for 'address + offset'.
18489 (microblaze_expand_prologue): Add new function prologue call for
18490 'r20' assignation.
18491 (microblaze_asm_generate_pic_addr_dif_vec): Override new target hook
18492 'TARGET_ASM_GENERATE_PIC_ADDR_DIFF_VEC' to disable address diff vector
18493 table in case of TARGET_PIC_DATA_TEXT_REL.
18494 (expand_pic_symbol_ref): Add handling for 'UNSPEC_TEXT'.
18495 * config/microblaze/microblaze.md (TARGET_PIC_DATA_TEXT_REL):
18496 Add new macros 'UNSPEC_TEXT',
18497 'UNSPEC_SET_TEXT' + add rule for setting r20 in function prologue
18498 + exclude function calls from 'UNSPEC_PLT' in case of data text
18499 relative mode.
18500 * doc/tm.texi.in (TARGET_ASM_GENERATE_PIC_ADDR_DIFF_VEC): Add
18501 new target hook for generating address diff vector tables in case of
18502 flag_pic.
18503 * doc/tm.texi : Regenerate.
18504 * stmt.c (TARGET_ASM_GENERATE_PIC_ADDR_DIFF_VEC): Append new condition
18505 'targetm.asm_out.generate_pic_addr_diff_vec' to flag_pic in case
18506 of addr diff vector generation.
18507 * target.def (TARGET_ASM_GENERATE_PIC_ADDR_DIFF_VEC): Add
18508 target hook definition.
18509 * targhooks.h, targhooks.c (TARGET_ASM_GENERATE_PIC_ADDR_DIFF_VEC):
18510 Add default function for generate_pic_addr_diff_vec -> flag_pic.
18511 * doc/invoke.texi (Add new pic option): Add new microblaze pic
18512 option for data text relative.
18513
18514 2018-04-30 Richard Biener <rguenther@suse.de>
18515
18516 * tree-chrec.h (evolution_function_is_constant_p): Remove
18517 redundant check.
18518 * tree-cfg.c (tree_node_can_be_shared): Re-order checks.
18519
18520 2018-04-30 Richard Biener <rguenther@suse.de>
18521
18522 PR bootstrap/85571
18523 * dwarf2out.c (gen_producer_string): Ignore -fchecking[=].
18524
18525 2018-04-30 Richard Biener <rguenther@suse.de>
18526
18527 PR tree-optimization/28364
18528 PR tree-optimization/85275
18529 * tree-ssa-loop-ch.c (ch_base::copy_headers): Stop after
18530 copying first exit test.
18531
18532 2018-04-28 Mark Wielaard <mark@klomp.org>
18533
18534 * dwarf2out.c (dwarf2out_finish): Add .debug_addr table header for
18535 dwarf_version >= 5.
18536 (dwarf_AT): Handle DW_AT_addr_base.
18537 (add_top_level_skeleton_die_attrs): Use dwarf_AT for DW_AT_addr_base.
18538
18539 2018-04-28 Uros Bizjak <ubizjak@gmail.com>
18540
18541 PR target/84431
18542 * config/i386/i386.md (*ashl<dwi>3_doubleword_mask): New pattern.
18543 (*ashl<dwi>3_doubleword_mask_1): Ditto.
18544 (*<shift_insn><dwi>3_doubleword_mask): Ditto.
18545 (*<shift_insn><dwi>3_doubleword_mask_1): Ditto.
18546
18547 2018-04-28 Richard Biener <rguenther@suse.de>
18548
18549 * tree-cfg.c (verify_gimple_phi): Take a gphi * argument.
18550 (verify_gimple_in_cfg): Rename visited_stmts to visited_throwing_stmts
18551 to reflect use. Only add interesting stmts.
18552
18553 2018-04-27 Martin Jambor <mjambor@suse.cz>
18554
18555 PR ipa/85549
18556 * ipa-cp.c (find_aggregate_values_for_callers_subset): Make sure
18557 the jump function allows for passing through aggregate values.
18558
18559 2018-04-27 David Malcolm <dmalcolm@redhat.com>
18560
18561 * input.h (in_system_header_at): Convert from macro to inline
18562 function.
18563 (from_macro_expansion_at): Likewise.
18564 (from_macro_definition_at): Likewise.
18565
18566 2018-04-27 Jeff Law <law@redhat.com>
18567
18568 * config.gcc: Mark tile* targets as deprecated/obsolete.
18569
18570 2018-04-27 Richard Biener <rguenther@suse.de>
18571
18572 * config/aarch64/aarch64.c: Simplify ap.__stack advance and
18573 fix for ILP32.
18574
18575 2018-04-27 Richard Biener <rguenther@suse.de>
18576
18577 * tree-cfg.c (verify_expr): Make dead code hit gcc_unreachable.
18578
18579 2018-04-27 Uros Bizjak <ubizjak@gmail.com>
18580
18581 * config/i386/i386.md (*movti_internal): Substitute Ye constraint
18582 with Yd constraint. Set "preferred_for_speed" attribute from
18583 TARGET_INTER_UNIT_MOVES_{FROM,TO}_VEC for alternatives
18584 with Yd constraint.
18585 (*movdi_internal): Ditto.
18586 (movti_interunit splitters): Remove
18587 TARGET_INTER_UNIT_MOVES_{FROM,TO}_VEC from insn condition.
18588 (movdi_interunit splitters): Ditto.
18589 * config/i386/constraints.md (Ye): Remove.
18590 (Yd): Do not depend on TARGET_INTER_UNIT_MOVES_{FROM,TO}_VEC.
18591
18592 2018-04-27 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
18593
18594 PR target/85512
18595 * config/aarch64/constraints.md (Usg): Limit to 31.
18596 (Usj): Limit to 63.
18597
18598 2018-04-27 Jakub Jelinek <jakub@redhat.com>
18599
18600 PR tree-optimization/85529
18601 * tree-ssa-reassoc.c (optimize_range_tests_var_bound): Add FIRST_BB
18602 argument. Don't call get_nonzero_bits if opcode is ERROR_MARK_NODE,
18603 rhs2 def stmt's bb is dominated by first_bb and it isn't an obvious
18604 zero extension or masking of the MSB bit.
18605 (optimize_range_tests): Add FIRST_BB argument, pass it through
18606 to optimize_range_tests_var_bound.
18607 (maybe_optimize_range_tests, reassociate_bb): Adjust
18608 optimize_range_tests callers.
18609
18610 2018-04-26 Richard Biener <rguenther@suse.de>
18611 Jakub Jelinek <jakub@redhat.com>
18612
18613 * cgraph.h (symbol_table): Just declare debug method here.
18614 * symtab.c (symbol_table::debug): Define.
18615
18616 2018-04-26 Eric Botcazou <ebotcazou@adacore.com>
18617
18618 * loop-invariant.c (may_assign_reg_p): Return false for frame pointer.
18619
18620 2018-04-26 Uros Bizjak <ubizjak@gmail.com>
18621
18622 * config/i386/i386.md ("isa" attribute): Add x64_sse2.
18623 ("enabled" attribute): Handle x64_sse2 "isa" attribute.
18624 (*movdi_internal): Substitute Yi and Yj constraint with x
18625 and Ym and Yn constraint with y constraint. Update "isa"
18626 attribute and set "preferred_for_speed" attribute from
18627 TARGET_INTER_UNIT_MOVES_{FROM,TO}_VEC for updated alternatives.
18628 (*movsi_internal): Ditto.
18629 (*movdf_internal): Ditto.
18630 (*movsf_internal): Ditto.
18631 (*zero_extendsidi2): Ditto.
18632 * config/i386/sse.md (vec_set<mode>_0): Ditto.
18633 (sse2_loadld): Ditto.
18634 (*vec_extract<ssevecmodelower>_0): Ditto.
18635 (*vec_extractv4si_0_zext_sse4): Ditto.
18636 (vec_concatv2di): Ditto.
18637 (*vec_dup<mode>): Ditto.
18638 * config/i386/mmx.md (*mov<mode>_internal): Ditto.
18639 * config/i386/constraints.md (Yi): Remove.
18640 (Yj): Remove.
18641 (Ym): Remove.
18642 (Yn): Remove.
18643
18644 2018-04-26 Nathan Sidwell <nathan@acm.org>
18645
18646 * dumpfile.c (dump_open): New.
18647 (dump_open_alternate_stream, dump_start, dump_begin): Call it.
18648 (dump_finish): Detect stdio/stderr by value not name.
18649
18650 2018-04-26 Jonathan Wakely <jwakely@redhat.com>
18651
18652 * doc/invoke.texi (-Wreturn-type): Document default status for C++.
18653
18654 2018-04-26 Tom de Vries <tom@codesourcery.com>
18655
18656 PR target/84952
18657 * config/nvptx/nvptx.c (verify_neutering_jumps)
18658 (verify_neutering_labels): New function
18659 (nvptx_single): Use verify_neutering_jumps and verify_neutering_labels.
18660
18661 2018-04-26 Tom de Vries <tom@codesourcery.com>
18662
18663 PR target/84025
18664 * config/nvptx/nvptx.c (needs_neutering_p): New function.
18665 (nvptx_single): Use needs_neutering_p to skip over insns that do not
18666 need neutering.
18667
18668 2018-04-26 Richard Biener <rguenther@suse.de>
18669 Tom de Vries <tom@codesourcery.com>
18670
18671 PR lto/85422
18672 * lto-streamer-out.c (output_function): Fixup loops if required to match
18673 discovery done in the reader.
18674
18675 2018-04-26 Richard Biener <rguenther@suse.de>
18676
18677 PR tree-optimization/85116
18678 * tree-ssa-loop-ch.c (do_while_loop_p): A do-while loop should
18679 have a loop exit from the single latch predecessor. Remove
18680 case of header with just condition.
18681 (ch_base::copy_headers): Exclude infinite loops from any
18682 processing.
18683 (pass_ch::execute): Record exits.
18684
18685 2018-04-26 Richard Biener <rguenther@suse.de>
18686
18687 * tree-vect-data-refs.c (vect_get_data_access_cost): Get
18688 prologue cost vector and pass it to vect_get_load_cost.
18689 (vect_get_peeling_costs_all_drs): Likewise.
18690 (vect_peeling_hash_get_lowest_cost): Likewise.
18691 (vect_enhance_data_refs_alignment): Likewise.
18692
18693 2018-04-26 Richard Biener <rguenther@suse.de>
18694
18695 PR middle-end/85450
18696 * tree-cfg.c (verify_gimple_assign_unary): Restore proper
18697 checking of integer<->pointer conversions.
18698 * omp-expand.c (expand_omp_for_static_nochunk): Avoid
18699 sign-/zero-extending pointer types.
18700 (expand_omp_for_static_chunk): Likewise.
18701
18702 2018-03-22 Hans-Peter Nilsson <hp@axis.com>
18703 Jean Lee <xiaoyur347@gmail.com>
18704
18705 * config/mips/mips.c (mips_asan_shadow_offset): New function.
18706 (TARGET_ASAN_SHADOW_OFFSET): Define.
18707 * config/mips/mips.h (FRAME_GROWS_DOWNWARD): Augment to also be
18708 true for -fsanitize=address.
18709
18710 2018-04-25 Mark Wielaard <mark@klomp.org>
18711
18712 * dwarf2out.c (file_info_cmp): Sort longer dir prefixes before
18713 shorter ones.
18714
18715 2018-04-25 Jakub Jelinek <jakub@redhat.com>
18716
18717 * config/i386/i386.md (*x86_mov<mode>cc_0_m1): Use type "alu1" rather
18718 than "alu", remove explicit "memory" and "imm_disp" attributes.
18719 (*x86_mov<mode>cc_0_m1_se, *x86_mov<mode>cc_0_m1_neg): Likewise.
18720
18721 PR middle-end/85414
18722 * simplify-rtx.c (simplify_unary_operation_1) <case SIGN_EXTEND,
18723 case ZERO_EXTEND>: Pass SUBREG_REG (op) rather than op to
18724 gen_lowpart_no_emit.
18725
18726 2018-04-25 Sebastian Peryt <sebastian.peryt@intel.com>
18727
18728 PR target/85473
18729 * config/i386/i386.c (ix86_expand_builtin): Change memory
18730 operand to XI, extend p0 to Pmode.
18731 * config/i386/i386.md: Change unspec volatile and operand
18732 1 mode to XI, change operand 0 mode to P.
18733
18734 2018-04-25 Chung-Ju Wu <jasonwucj@gmail.com>
18735
18736 * config/nds32/nds32-predicates.c (nds32_can_use_bclr_p): Mask with
18737 GET_MODE_MASK before any checking.
18738 (nds32_can_use_bset_p): Likewise.
18739 (nds32_can_use_btgl_p): Likewise.
18740
18741 2018-04-25 Chung-Ju Wu <jasonwucj@gmail.com>
18742
18743 * config/nds32/nds32-doubleword.md: New define_split pattern for
18744 illegal register number.
18745
18746 2018-04-25 Chung-Ju Wu <jasonwucj@gmail.com>
18747
18748 * config/nds32/nds32.c (nds32_print_operand): Set op_value ealier.
18749
18750 2018-04-25 Chung-Ju Wu <jasonwucj@gmail.com>
18751
18752 * config/nds32/nds32.h (ASM_APP_ON): Add missing newline character.
18753
18754 2018-04-25 Richard Biener <rguenther@suse.de>
18755
18756 * lto-streamer.h (LTO_major_version): Bump to 8.
18757
18758 2018-04-25 Jakub Jelinek <jakub@redhat.com>
18759
18760 * BASE-VER: Set to 9.0.0.
18761
18762 2018-04-24 Segher Boessenkool <segher@kernel.crashing.org>
18763
18764 * config/rs6000/rs6000.c (init_float128_ieee): Fix spelling mistakes
18765 in __abskf2 and __powikf2.
18766
18767 2018-04-24 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
18768
18769 PR target/85512
18770 * config/aarch64/constraints.md (Usg, Usj): New constraints.
18771 * config/aarch64/iterators.md (cmode_simd): New mode attribute.
18772 * config/aarch64/aarch64.md (*aarch64_ashr_sisd_or_int_<mode>3):
18773 Use the above on operand 2. Reindent.
18774 (*aarch64_lshr_sisd_or_int_<mode>3): Likewise.
18775
18776 2018-04-24 H.J. Lu <hongjiu.lu@intel.com>
18777
18778 PR target/85485
18779 * common/config/i386/i386-common.c (ix86_handle_option): Don't
18780 handle OPT_mcet.
18781 * config/i386/i386.opt (mcet): Removed.
18782 * doc/install.texi: Remove -mcet documentation.
18783 * doc/invoke.texi: Likewise.
18784
18785 2018-04-24 H.J. Lu <hongjiu.lu@intel.com>
18786
18787 PR target/85485
18788 * doc/install.texi: Remove -mcet from bootstrap-cet.
18789
18790 2018-04-24 Jakub Jelinek <jakub@redhat.com>
18791
18792 PR target/85511
18793 * config/i386/i386.c (ix86_init_mmx_sse_builtins): Don't define
18794 __builtin_ia32_readeflags_u32 and __builtin_ia32_writeeflags_u32
18795 if TARGET_64BIT.
18796
18797 PR target/85503
18798 * config/rs6000/rs6000-p8swap.c (const_load_sequence_p): Punt if
18799 const_vector is not CONST_VECTOR or SYMBOL_REF for a constant pool
18800 containing a CONST_VECTOR.
18801
18802 2018-04-24 Cesar Philippidis <cesar@codesourcery.com>
18803
18804 * doc/install.texi: Update newlib dependency for nvptx.
18805
18806 2018-04-24 Jakub Jelinek <jakub@redhat.com>
18807
18808 PR target/85508
18809 * config/i386/i386.c (ix86_expand_vector_init_one_var): Use UINTVAL
18810 instead of INTVAL when shifting x left.
18811
18812 2018-04-24 Andreas Krebbel <krebbel@linux.ibm.com>
18813
18814 PR tree-optimization/85478
18815 * tree-vect-loop.c (vect_analyze_loop_2): Do not call
18816 vect_grouped_store_supported for single element vectors.
18817
18818 2018-04-24 Richard Biener <rguenther@suse.de>
18819
18820 PR target/85491
18821 * config/i386/i386.c (ix86_add_stmt_cost): Restrict strided
18822 load cost increase to the case of non-constant step.
18823
18824 2018-04-24 Jakub Jelinek <jakub@redhat.com>
18825
18826 PR target/84828
18827 * reg-stack.c (move_for_stack_reg): Don't fail assertion about dead
18828 destination if any_malformed_asm.
18829
18830 2018-04-23 Eric Botcazou <ebotcazou@adacore.com>
18831
18832 PR middle-end/85496
18833 * expr.c (store_field): In the bitfield case, if the value comes from
18834 a function call and is returned in registers by means of a PARALLEL,
18835 do not change the mode of the temporary unless BLKmode and VOIDmode.
18836
18837 2018-04-23 Andrey Belevantsev <abel@ispras.ru>
18838
18839 PR rtl-optimization/85423
18840 * sel-sched-ir.c (has_dependence_note_mem_dep): Only discard
18841 dependencies to debug insns when the previous insn is non-debug.
18842
18843 2018-04-23 Claudiu Zissulescu <claziss@synopsys.com>
18844
18845 * config/arc/arc.md ("vunspec"): Delete it, unify all the unspec
18846 enums into a single definition.
18847 (fls): Fix predicates and printing.
18848 (seti): Likewise.
18849
18850 2018-04-23 Claudiu Zissulescu <claziss@synopsys.com>
18851
18852 * config/arc/arc-protos.h (check_if_valid_sleep_operand): Remove.
18853 * config/arc/arc.c (arc_expand_builtin): Sleep accepts registers
18854 and short u6 immediate.
18855 (check_if_valid_sleep_operand): Remove.
18856 * config/arc/arc.md (Sleep): Accepts registers and u6 immediates.
18857
18858 2018-04-22 Chung-Ju Wu <jasonwucj@gmail.com>
18859
18860 * config/nds32/nds32.c (nds32_compute_stack_frame): Consider
18861 flag_always_save_lp condition.
18862 * config/nds32/nds32.opt (malways-save-lp): New option.
18863
18864 2018-04-22 Shiva Chen <shiva0217@gmail.com>
18865
18866 * config/nds32/nds32-protos.h (nds32_use_load_post_increment): Declare.
18867 * config/nds32/nds32.c (nds32_use_load_post_increment): New.
18868 * config/nds32/nds32.h
18869 (USE_LOAD_POST_INCREMENT, USE_LOAD_POST_DECREMENT): Define.
18870 (USE_STORE_POST_INCREMENT, USE_STORE_POST_DECREMENT): Define.
18871
18872 2018-04-22 Shiva Chen <shiva0217@gmail.com>
18873
18874 * config/nds32/nds32-protos.h (nds32_ls_333_p): Remove.
18875 * config/nds32/nds32.c (nds32_ls_333_p): Remove.
18876
18877 2018-04-22 Shiva Chen <shiva0217@gmail.com>
18878 Chung-Ju Wu <jasonwucj@gmail.com>
18879
18880 * config/nds32/nds32-protos.h (nds32_case_vector_shorten_mode):
18881 Declare.
18882 * config/nds32/nds32.c (nds32_case_vector_shorten_mode): New function.
18883 * config/nds32/nds32.h (CASE_VECTOR_SHORTEN_MODE): Modify.
18884
18885 2018-04-22 Chung-Ju Wu <jasonwucj@gmail.com>
18886
18887 * config/nds32/nds32.c (nds32_compute_stack_frame): Fix wrong value.
18888
18889 2018-04-22 Chung-Ju Wu <jasonwucj@gmail.com>
18890
18891 * config/nds32/nds32-protos.h (nds32_data_alignment,
18892 nds32_local_alignment): Declare.
18893 * config/nds32/nds32.c (nds32_data_alignment, nds32_constant_alignment,
18894 nds32_local_alignment): New functions.
18895 (TARGET_CONSTANT_ALIGNMENT): Define.
18896 * config/nds32/nds32.h (DATA_ALIGNMENT, LOCAL_ALIGNMENT): Define.
18897
18898 2018-04-22 Chung-Ju Wu <jasonwucj@gmail.com>
18899
18900 * config/nds32/nds32.c
18901 (TARGET_HARD_REGNO_MODE_OK): Move to the bottom of file.
18902 (TARGET_MODES_TIEABLE_P): Likewise.
18903
18904 2018-04-22 Chung-Ju Wu <jasonwucj@gmail.com>
18905
18906 * config/nds32/nds32.c (nds32_asm_file_start): Display optimization
18907 level Ofast and Og.
18908
18909 2018-04-22 Monk Chiang <sh.chiang04@gmail.com>
18910 Chung-Ju Wu <jasonwucj@gmail.com>
18911
18912 * config/nds32/constants.md (unspec_volatile_element): Add enum values
18913 for unaligned access.
18914 * config/nds32/nds32-intrinsic.c: Implementation of expanding
18915 unaligned access.
18916 * config/nds32/nds32-intrinsic.md: Likewise.
18917 * config/nds32/nds32_intrinsic.h: Likewise.
18918 * config/nds32/nds32.h (nds32_builtins): Likewise.
18919 * config/nds32/nds32.opt (munaligned-access): New option.
18920 * config/nds32/nds32.c (nds32_asm_file_start): Display
18921 flag_unaligned_access status.
18922
18923 2018-04-20 Kito Cheng <kito.cheng@gmail.com>
18924
18925 * config/riscv/elf.h (LINK_SPEC): Pass --no-relax if
18926 -mno-relax is present.
18927 * config/riscv/linux.h (LINK_SPEC): Ditto.
18928
18929 2018-04-20 Martin Sebor <msebor@redhat.com>
18930
18931 PR c/85365
18932 * gimple-fold.c (gimple_fold_builtin_strcpy): Suppress -Wrestrict
18933 for null pointers.
18934 (gimple_fold_builtin_stxcpy_chk): Same.
18935 * gimple-ssa-warn-restrict.c (check_bounds_or_overlap): Same.
18936
18937 2018-04-20 Michael Meissner <meissner@linux.ibm.com>
18938
18939 PR target/85456
18940 * config/rs6000/rs6000.c (init_float128_ieee): Add support to call
18941 __powikf2 when long double is IEEE 128-bit.
18942
18943 2018-04-20 Kito Cheng <kito.cheng@gmail.com>
18944
18945 * config/riscv/riscv.c (riscv_first_stack_step): Round up min
18946 step to make sure stack always aligned.
18947
18948 2018-04-20 Carl Love <cel@us.ibm.com>
18949
18950 PR target/83402
18951 * config/rs6000/rs6000-c.c (rs6000_gimple_fold_builtin): Add
18952 size check for arg0.
18953
18954 2018-04-20 Nathan Sidwell <nathan@codesourcery.com>
18955 Tom de Vries <tom@codesourcery.com>
18956
18957 PR target/85445
18958 * config/nvptx/nvptx.c (nvptx_emit_forking, nvptx_emit_joining):
18959 Emit insns for calls too.
18960 (nvptx_find_par): Always look for worker-level predecessor insn.
18961 (nvptx_propagate): Add is_call parm, return bool. Copy frame for
18962 calls.
18963 (nvptx_vpropagate, nvptx_wpropagate): Adjust.
18964 (nvptx_process_pars): Propagate frames for calls.
18965
18966 2018-04-20 H.J. Lu <hongjiu.lu@intel.com>
18967
18968 PR target/85469
18969 * common/config/i386/i386-common.c (OPTION_MASK_ISA_IBT_SET):
18970 Removed.
18971 (OPTION_MASK_ISA_IBT_UNSET): Likewise.
18972 (ix86_handle_option): Don't handle OPT_mibt.
18973 * config/i386/cet.h: Check __CET__ instead of __IBT__ and
18974 __SHSTK__.
18975 * config/i386/driver-i386.c (host_detect_local_cpu): Remove
18976 has_ibt and ibt.
18977 * config/i386/i386-c.c (ix86_target_macros_internal): Don't
18978 check OPTION_MASK_ISA_IBT nor flag_cf_protection.
18979 (ix86_target_macros): Define __CET__ with flag_cf_protection
18980 for -fcf-protection.
18981 * config/i386/i386.c (isa2_opts): Remove -mibt.
18982 * config/i386/i386.h (TARGET_IBT): Removed.
18983 (TARGET_IBT_P): Likewise.
18984 (ix86_valid_target_attribute_inner_p): Don't check OPT_mibt.
18985 * config/i386/i386.md (nop_endbr): Don't check TARGET_IBT.
18986 * config/i386/i386.opt (mcet): Update help message.
18987 (mshstk): Likewise.
18988 (mibt): Removed.
18989 * doc/invoke.texi: Remove -mibt. Document __CET__. Document
18990 -mcet as an alias for -mshstk.
18991
18992 2018-04-20 Richard Biener <rguenther@suse.de>
18993
18994 PR middle-end/85475
18995 * match.pd ((X * CST) * Y -> (X * Y) * CST): Avoid exponential
18996 complexity by forcing a single use of the multiply operand.
18997
18998 2018-04-20 Martin Jambor <mjambor@suse.cz>
18999
19000 ipa/85449
19001 * ipa-cp.c (cgraph_edge_brings_value_p): Move check for self-feeding
19002 recursion dependency to only apply to non-clones.
19003
19004 2018-04-20 Martin Jambor <mjambor@suse.cz>
19005
19006 ipa/85447
19007 * ipa-cp.c (create_specialized_node): Check that clones of
19008 self-recursive edges exist during IPA-CP.
19009
19010 2018-04-19 Toon Moene <toon@moene.org>
19011
19012 * doc/invoke.texi: Add -floop-unroll-and-jam to options enabled
19013 by -O3.
19014
19015 2018-04-19 Jakub Jelinek <jakub@redhat.com>
19016
19017 PR tree-optimization/85467
19018 * fold-const.c (fold_ternary_loc) <case BIT_FIELD_REF>: Use
19019 VECTOR_TYPE_P macro. If type is vector type, VIEW_CONVERT_EXPR the
19020 VECTOR_CST element to type.
19021
19022 2018-04-19 H.J. Lu <hongjiu.lu@intel.com>
19023
19024 PR target/85397
19025 * config/i386/i386.h (STACK_SAVEAREA_MODE): New.
19026 * config/i386/i386.md (builtin_setjmp_setup): Removed.
19027 (builtin_longjmp): Likewise.
19028 (save_stack_nonlocal): New pattern.
19029 (restore_stack_nonlocal): Likewise.
19030
19031 2018-04-19 H.J. Lu <hongjiu.lu@intel.com>
19032
19033 PR target/85404
19034 * config/i386/cet.c (file_end_indicate_exec_stack_and_cet):
19035 Replace ASM_OUTPUT_LABEL with fprintf.
19036
19037 2018-04-19 H.J. Lu <hongjiu.lu@intel.com>
19038
19039 PR target/85417
19040 * config/i386/cet.c (file_end_indicate_exec_stack_and_cet):
19041 Check flag_cf_protection instead of TARGET_IBT and TARGET_SHSTK.
19042 * config/i386/i386-c.c (ix86_target_macros_internal): Also
19043 define __IBT__ and __SHSTK__ for -fcf-protection.
19044 * config/i386/i386.c (pass_insert_endbranch::gate): Don't check
19045 TARGET_IBT.
19046 (ix86_trampoline_init): Likewise.
19047 (x86_output_mi_thunk): Likewise.
19048 (ix86_notrack_prefixed_insn_p): Likewise.
19049 (ix86_option_override_internal): Don't disallow -fcf-protection.
19050 * config/i386/i386.md (rdssp<mode>): Also enable for
19051 -fcf-protection.
19052 (incssp<mode>): Likewise.
19053 (nop_endbr): Likewise.
19054 * config/i386/i386.opt (mcet): Change help message to built-in
19055 functions only.
19056 (mibt): Likewise.
19057 (mshstk): Likewise.
19058 * doc/invoke.texi: Remove -mcet, -mibt and -mshstk condition
19059 on -fcf-protection. Change -mcet, -mibt and -mshstk to only
19060 enable CET built-in functions.
19061
19062 2018-04-19 Sebastian Peryt <sebastian.peryt@intel.com>
19063
19064 * common/config/i386/i386-common.c
19065 (OPTION_MASK_ISA_MOVDIRI_SET, OPTION_MASK_ISA_MOVDIR64B_SET,
19066 OPTION_MASK_ISA_MOVDIRI_UNSET,
19067 OPTION_MASK_ISA_MOVDIR64B_UNSET): New defines.
19068 (ix86_handle_option): Handle -mmovdiri and -mmovdir64b.
19069 * config.gcc (movdirintrin.h): New header.
19070 * config/i386/cpuid.h (bit_MOVDIRI,
19071 bit_MOVDIR64B): New bits.
19072 * config/i386/driver-i386.c (host_detect_local_cpu): Detect -mmovdiri
19073 and -mmvodir64b.
19074 * config/i386/i386-builtin-types.def ((VOID, PUNSIGNED, UNSIGNED),
19075 (VOID, PVOID, PCVOID)): New function types.
19076 * config/i386/i386-builtin.def (__builtin_ia32_directstoreu_u32,
19077 __builtin_ia32_directstoreu_u64,
19078 __builtin_ia32_movdir64b): New builtins.
19079 * config/i386/i386-c.c (__MOVDIRI__, __MOVDIR64B__): New.
19080 * config/i386/i386.c (ix86_target_string): Added -mmovdir64b
19081 and -mmovdiri.
19082 (ix86_valid_target_attribute_inner_p): Ditto.
19083 (ix86_expand_special_args_builtin): Added VOID_FTYPE_PUNSIGNED_UNSIGNED
19084 and VOID_FTYPE_PUNSIGNED_UNSIGNED.
19085 (ix86_expand_builtin): Expand IX86_BUILTIN_MOVDIR64B.
19086 * config/i386/i386.h (TARGET_MOVDIRI, TARGET_MOVDIRI_P,
19087 TARGET_MOVDIR64B, TARGET_MOVDIR64B_P): New.
19088 * config/i386/i386.md (UNSPECV_MOVDIRI, UNSPECV_MOVDIR64B): New.
19089 (movdiri<mode>, movdir64b_<mode>): New.
19090 * config/i386/i386.opt: Add -mmovdiri and -mmovdir64b.
19091 * config/i386/immintrin.h: Include movdirintrin.h.
19092 * config/i386/movdirintrin.h: New file.
19093 * doc/invoke.texi: Added -mmovdiri and -mmovdir64b.
19094
19095 2018-04-19 Richard Biener <rguenther@suse.de>
19096
19097 PR middle-end/85455
19098 * cfg.c (clear_bb_flags): When loop state says we have
19099 marked irreducible regions also preserve BB_IRREDUCIBLE_LOOP.
19100
19101 2018-04-19 Richard Biener <rguenther@suse.de>
19102
19103 PR tree-optimization/84737
19104 * tree-vect-data-refs.c (vect_copy_ref_info): New function
19105 copying restrict info.
19106 (vect_setup_realignment): Use it.
19107 * tree-vectorizer.h (vect_copy_ref_info): Declare.
19108 * tree-vect-stmts.c (vectorizable_store): Copy ref info from
19109 the first DR to all generated stores.
19110 (vectorizable_load): Likewise for loads.
19111
19112 2018-04-19 Jakub Jelinek <jakub@redhat.com>
19113
19114 PR tree-optimization/85446
19115 * match.pd ((intptr_t) x eq/ne CST to x eq/ne (typeof x) cst): Require
19116 the integral and pointer types to have the same precision.
19117
19118 * doc/install.texi: Document --disable-cet being the default and
19119 --enable-cet=auto.
19120
19121 2018-04-18 Martin Liska <mliska@suse.cz>
19122
19123 * ipa-devirt.c (odr_subtypes_equivalent_p): Fix GNU coding
19124 style.
19125
19126 2018-04-18 Martin Liska <mliska@suse.cz>
19127
19128 Revert
19129 2018-03-02 Eric Botcazou <ebotcazou@adacore.com>
19130
19131 PR ipa/83983
19132 * ipa-devirt.c (odr_subtypes_equivalent_p): Get the ODR type of both
19133 arguments if they are comparable.
19134
19135 2018-04-18 Martin Liska <mliska@suse.cz>
19136
19137 Revert
19138 2018-03-13 Eric Botcazou <ebotcazou@adacore.com>
19139
19140 PR lto/84805
19141 * ipa-devirt.c (odr_subtypes_equivalent_p): Do not get the ODR type of
19142 incomplete types.
19143
19144 2018-04-18 H.J. Lu <hongjiu.lu@intel.com>
19145
19146 PR target/85388
19147 * config/i386/i386.c (ix86_expand_split_stack_prologue): Insert
19148 ENDBR after calling __morestack.
19149
19150 2018-04-18 David Malcolm <dmalcolm@redhat.com>
19151
19152 PR jit/85384
19153 * configure.ac (gcc-driver-name.h): Honor --with-gcc-major-version
19154 by using gcc_base_ver to generate a gcc_driver_version, and use
19155 it when generating GCC_DRIVER_NAME.
19156 * configure: Regenerate.
19157
19158 2018-04-18 Jakub Jelinek <jakub@redhat.com>
19159
19160 PR target/81084
19161 * config.gcc: Obsolete powerpc*-*-*spe*.
19162
19163 2018-04-17 Jakub Jelinek <jakub@redhat.com>
19164
19165 PR debug/84637
19166 * dbxout.c (dbxout_int): Perform negation in unsigned int type.
19167 (stabstr_D): Change type of unum from unsigned int to
19168 unsigned HOST_WIDE_INT. Perform negation in unsigned HOST_WIDE_INT
19169 type.
19170
19171 2018-04-17 Jim Wilson <jimw@sifive.com>
19172
19173 PR 84856
19174 * config/riscv/riscv.c (riscv_compute_frame_info): Add calls to
19175 RISCV_STACK_ALIGN when using outgoing_args_size and pretend_args_size.
19176 Set arg_pointer_offset after using pretend_args_size.
19177
19178 2018-04-17 Jakub Jelinek <jakub@redhat.com>
19179
19180 PR rtl-optimization/85431
19181 * dse.c (record_store): Ignore zero width stores.
19182
19183 PR sanitizer/85230
19184 * asan.c (handle_builtin_stack_restore): Adjust comment. Emit
19185 __asan_allocas_unpoison call and last_alloca_addr = new_sp before
19186 __builtin_stack_restore rather than after it.
19187 * builtins.c (expand_asan_emit_allocas_unpoison): Pass
19188 arg1 + (virtual_dynamic_stack_rtx - stack_pointer_rtx) as second
19189 argument instead of virtual_dynamic_stack_rtx.
19190
19191 2018-04-17 Kelvin Nilsen <kelvin@gcc.gnu.org>
19192
19193 * config/rs6000/rs6000-protos.h (rs6000_builtin_is_supported_p):
19194 New prototype.
19195 * config/rs6000/rs6000-c.c (altivec_resolve_overloaded_builtin):
19196 Add note to error message to explain internal mapping of overloaded
19197 built-in function name to non-overloaded built-in function name.
19198 * config/rs6000/rs6000.c (rs6000_builtin_is_supported_p): New
19199 function.
19200
19201 2018-04-17 Michael Meissner <meissner@linux.vnet.ibm.com>
19202
19203 PR target/85424
19204 * config/rs6000/rs6000.md (pack<mode>): Do not try handle a pack
19205 where the inputs overlap with the output.
19206
19207 2018-04-17 Jakub Jelinek <jakub@redhat.com>
19208
19209 * config/i386/sse.md (vec_extract_lo_<mode><mask_name>): Add
19210 (=v, v) alternative and explicit "memory" attribute.
19211 (vec_extract_lo_<mode><mask_name>): Likewise. Also add
19212 "type", "prefix", "prefix_extra", "length_immediate" and "mode"
19213 attributes.
19214 (vec_extract_lo_<mode><mask_name>): Add (=v, v) alternative and use
19215 "sselog1" type instead of "sselog".
19216 (vec_extract_hi_<mode><mask_name>): Use "sselog1" type instead of
19217 "sselog". Remove explicit "memory" attribute.
19218 (vec_extract_lo_v32hi): Add (=v, v) alternative and explicit "memory",
19219 "type", "prefix", "prefix_extra", "length_immediate" and "mode"
19220 attributes.
19221 (vec_extract_hi_v32hi): Merge all alternatives into one, use
19222 "sselog1" type instead of "sselog". Remove explicit "memory"
19223 attribute.
19224 (vec_extract_hi_v16hi): Merge each pair of alternatives into one,
19225 use "sselog1" type instead of "sselog". Remove explicit "memory"
19226 attribute.
19227 (vec_extract_lo_v64qi): Add (=v, v) alternative and explicit "memory",
19228 "type", "prefix", "prefix_extra", "length_immediate" and "mode"
19229 attributes.
19230 (vec_extract_hi_v64qi): Merge all alternatives into one, use
19231 "sselog1" type instead of "sselog". Remove explicit "memory"
19232 attribute.
19233 (vec_extract_hi_v32qi): Merge each pair of alternatives into one,
19234 use "sselog1" type instead of "sselog". Remove explicit "memory"
19235 attribute.
19236
19237 PR target/85430
19238 * config/i386/i386.md (*ashlqi3_1_slp): Use alu1 type instead of alu.
19239
19240 PR middle-end/85414
19241 * rtlhooks.c (gen_lowpart_if_possible): Don't call gen_lowpart_SUBREG
19242 on a SUBREG.
19243
19244 2018-04-17 Martin Jambor <mjambor@suse.cz>
19245
19246 PR ipa/85421
19247 * ipa-cp.c (create_specialized_node): Call
19248 expand_all_artificial_thunks if necessary.
19249
19250 2018-04-17 Martin Liska <mliska@suse.cz>
19251
19252 PR lto/85405
19253 * ipa-devirt.c (odr_types_equivalent_p): Remove trailing
19254 in message, remote space in between '_G' and '('.
19255
19256 2018-04-17 Jakub Jelinek <jakub@redhat.com>
19257
19258 PR target/85281
19259 * config/i386/sse.md (reduces<mode><mask_scalar_name>,
19260 avx512f_vmcmp<mode>3<round_saeonly_name>,
19261 avx512f_vmcmp<mode>3_mask<round_saeonly_name>,
19262 avx512f_sgetexp<mode><mask_scalar_name><round_saeonly_scalar_name>,
19263 avx512f_rndscale<mode><round_saeonly_name>,
19264 avx512dq_ranges<mode><mask_scalar_name><round_saeonly_scalar_name>,
19265 avx512f_vgetmant<mode><mask_scalar_name><round_saeonly_scalar_name>):
19266 Use %<iptr>2 instead of %2 for -masm=intel.
19267 (avx512f_vcvtss2usi<round_name>, avx512f_vcvtss2usiq<round_name>,
19268 avx512f_vcvttss2usi<round_saeonly_name>,
19269 avx512f_vcvttss2usiq<round_saeonly_name>): Use %k1 instead of %1 for
19270 -masm=intel.
19271 (avx512f_vcvtsd2usi<round_name>, avx512f_vcvtsd2usiq<round_name>,
19272 avx512f_vcvttsd2usi<round_saeonly_name>,
19273 avx512f_vcvttsd2usiq<round_saeonly_name>, ufloatv2siv2df2<mask_name>):
19274 Use %q1 instead of %1 for -masm=intel.
19275 (avx512f_sfixupimm<mode><sd_maskz_name><round_saeonly_name>,
19276 avx512f_sfixupimm<mode>_mask<round_saeonly_name>): Use %<iptr>3 instead
19277 of %3 for -masm=intel.
19278 (sse2_shufpd_v2df_mask): Fix a typo, change %{6%} to %{%6%} for
19279 -masm=intel.
19280 (*avx512vl_<code>v2div2qi2_store): Use %w0 instead of %0 for
19281 -masm=intel.
19282 (*avx512vl_<code><mode>v4qi2_store): Use %k0 instead of %0 for
19283 -masm=intel.
19284 (avx512vl_<code><mode>v4qi2_mask_store): Use a single pattern with
19285 %k0 and %1 for -masm=intel rather than two patterns, one with %0 and
19286 %g1.
19287 (*avx512vl_<code><mode>v8qi2_store): Use %q0 instead of %0 for
19288 -masm=intel.
19289 (avx512vl_<code><mode>v8qi2_mask_store): Use a single pattern with
19290 %q0 and %1 for -masm=intel rather than two patterns, one with %0 and
19291 %g1 and one with %0 and %1.
19292 (avx512er_vmrcp28<mode><round_saeonly_name>,
19293 avx512er_vmrsqrt28<mode><round_saeonly_name>): Use %<iptr>1 instead of
19294 %1 for -masm=intel.
19295 (avx5124fmaddps_4fmaddps_mask, avx5124fmaddps_4fmaddss_mask,
19296 avx5124fmaddps_4fnmaddps_mask, avx5124fmaddps_4fnmaddss_mask,
19297 avx5124vnniw_vp4dpwssd_mask, avx5124vnniw_vp4dpwssds_mask): Swap order
19298 of %0 and %{%4%} for -masm=intel.
19299 (avx5124fmaddps_4fmaddps_maskz, avx5124fmaddps_4fmaddss_maskz,
19300 avx5124fmaddps_4fnmaddps_maskz, avx5124fmaddps_4fnmaddss_maskz,
19301 avx5124vnniw_vp4dpwssd_maskz, avx5124vnniw_vp4dpwssds_maskz): Swap
19302 order of %0 and %{%5%}%{z%} for -masm=intel.
19303
19304 2018-04-17 Jan Hubicka <jh@suse.cz>
19305
19306 PR lto/85405
19307 * ipa-devirt.c (odr_types_equivalent_p): Handle bit fields.
19308
19309 2018-04-17 Martin Liska <mliska@suse.cz>
19310
19311 PR ipa/85329
19312 * multiple_target.c (create_dispatcher_calls): Set apostrophes
19313 for target_clone error message. Make default implementation
19314 clone to be a local declaration.
19315 (separate_attrs): Add new argument and check for an empty
19316 string.
19317 (expand_target_clones): Handle it.
19318 (ipa_target_clone): Make redirection just for target_clones
19319 functions.
19320
19321 2018-04-16 Cesar Philippidis <cesar@codesourcery.com>
19322 Tom de Vries <tom@codesourcery.com>
19323
19324 PR middle-end/84955
19325 * omp-expand.c (expand_oacc_for): Add dummy false branch for
19326 tiled basic blocks without omp continue statements.
19327
19328 2018-04-16 Aaron Sawdey <acsawdey@linux.ibm.com>
19329
19330 PR target/83660
19331 * config/rs6000/rs6000-c.c (altivec_resolve_overloaded_builtin): Mark
19332 vec_extract expression as having side effects to make sure it gets
19333 a cleanup point.
19334
19335 2018-04-16 H.J. Lu <hongjiu.lu@intel.com>
19336
19337 PR target/85403
19338 * config/i386/i386.c (get_builtin_code_for_version): Check
19339 error_mark_node.
19340
19341 2018-04-16 Olga Makhotina <olga.makhotina@intel.com>
19342
19343 PR target/84331
19344 * config.gcc: Support "skylake".
19345 * config/i386/i386-c.c (ix86_target_macros_internal): Handle
19346 PROCESSOR_SKYLAKE.
19347 * config/i386/i386.c (m_SKYLAKE): Define.
19348 (processor_target_table): Add "skylake".
19349 (ix86_option_override_internal): Add "skylake".
19350 (get_builtin_code_for_version): Handle PROCESSOR_SKYLAKE,
19351 PROCESSOR_CANNONLAKE.
19352 (get_builtin_code_for_version): Fix priority for
19353 PROCESSOR_ICELAKE_CLIENT, PROCESSOR_ICELAKE_SERVER,
19354 PROCESSOR_SKYLAKE-AVX512.
19355 * config/i386/i386.h (processor_costs): Define TARGET_SKYLAKE.
19356 (processor_type): Add PROCESSOR_SKYLAKE.
19357
19358 2018-04-16 Paolo Carlini <paolo.carlini@oracle.com>
19359 Jason Merrill <jason@redhat.com>
19360
19361 PR c++/85112
19362 * convert.c (convert_to_integer_1): Use direct recursion for
19363 enumeral types and types with a precision less than the number
19364 of bits in their mode.
19365
19366 2018-04-16 Julia Koval <julia.koval@intel.com>
19367
19368 PR target/84413
19369 * config/i386/x86-tune.def (X86_TUNE_SSE_UNALIGNED_LOAD_OPTIMAL,
19370 X86_TUNE_SSE_UNALIGNED_STORE_OPTIMAL): Add m_SKYLAKE_AVX512
19371
19372 2018-04-14 Segher Boessenkool <segher@kernel.crashing.org>
19373
19374 PR target/85293
19375 * config/rs6000/rs6000.opt (mdirect-move): Make deprecated.
19376 * doc/invoke.texi (RS/6000 and PowerPC Options): Remove -mdirect-move
19377 and -mno-direct-move.
19378
19379 2018-04-13 Paul A. Clarke <pc@us.ibm.com>
19380
19381 PR target/83402
19382 * config/rs6000/emmintrin.h (_mm_slli_epi{16,32,64}):
19383 Ensure that vec_splat_s32 is only called with 0 <= shift < 16.
19384 Ensure negative shifts result in {0}.
19385
19386 2018-04-13 Vladimir Makarov <vmakarov@redhat.com>
19387
19388 PR rtl-optimization/79916
19389 * config/rs6000/rs6000.c (rs6000_emit_move): Use assigned hard
19390 regs (if any) to define how to gnerate SD moves when LRA is in
19391 progress.
19392
19393 2018-04-13 Jakub Jelinek <jakub@redhat.com>
19394
19395 PR rtl-optimization/85393
19396 * except.h (expand_dw2_landing_pad_for_region): Remove declaration.
19397 * except.c (expand_dw2_landing_pad_for_region): Make static.
19398 * bb-reorder.c (fix_up_crossing_landing_pad): In new_bb emit just
19399 a label and unconditional jump to old_bb, rather than
19400 expand_dw2_landing_pad_for_region insn(s) and jump to single_succ
19401 basic block.
19402
19403 PR rtl-optimization/85376
19404 * simplify-rtx.c (simplify_const_unary_operation): For CLZ and CTZ and
19405 zero op0, if C?Z_DEFINED_VALUE_AT_ZERO is false, return NULL_RTX
19406 instead of a specific value.
19407
19408 2018-04-13 Jan Hubicka <hubicka@ucw.cz>
19409 Bin Cheng <bin.cheng@arm.com>
19410
19411 PR tree-optimization/82965
19412 PR tree-optimization/83991
19413 * cfgloopanal.c (expected_loop_iterations_unbounded): Add
19414 by_profile_only parameter.
19415 * cfgloopmanip.c (scale_loop_profile): Further scale loop's profile
19416 information if the loop was predicted to iterate too many times.
19417 * cfgloop.h (expected_loop_iterations_unbounded): Update prototype
19418
19419 2018-04-13 Jan Hubicka <hubicka@ucw.cz>
19420
19421 PR lto/71991
19422 * config/i386/i386.c (ix86_can_inline_p): Allow safe transitions for
19423 always inline.
19424
19425 2018-04-13 Martin Liska <mliska@suse.cz>
19426 Jakub Jelinek <jakub@redhat.com>
19427
19428 PR middle-end/81657
19429 * expr.h (enum block_op_methods): Add BLOCK_OP_NO_LIBCALL_RET.
19430 * expr.c (emit_block_move_hints): Handle BLOCK_OP_NO_LIBCALL_RET.
19431 * builtins.c (expand_builtin_memory_copy_args): Use
19432 BLOCK_OP_NO_LIBCALL_RET method for mempcpy with non-ignored target,
19433 handle dest_addr == pc_rtx.
19434
19435 2018-04-12 Segher Boessenkool <segher@kernel.crashing.org>
19436
19437 PR target/85291
19438 * config/rs6000/rs6000.md (fix_trunc<mode>si2): Use legacy code if
19439 asked to not generate direct moves.
19440 (fix_trunc<mode>si2_stfiwx): Similar.
19441 (fix_trunc<mode>si2_internal): Similar.
19442
19443 2018-04-12 Jakub Jelinek <jakub@redhat.com>
19444
19445 PR debug/83157
19446 * var-tracking.c (add_stores): Handle STRICT_LOW_PART SET_DEST.
19447 * cselib.c (cselib_record_sets): For STRICT_LOW_PART dest,
19448 lookup if dest in some wider mode is known to be const0_rtx and
19449 if so, record permanent equivalence for it to be ZERO_EXTEND of
19450 the narrower mode destination.
19451
19452 2018-04-12 Cesar Philippidis <cesar@codesourcery.com>
19453
19454 * lto-streamer-out.c (output_function): Revert 259346.
19455 * omp-expand.c (expand_oacc_for): Likewise.
19456
19457 2018-04-12 Alexander Monakov <amonakov@ispras.ru>
19458
19459 PR rtl-optimization/85354
19460 * sel-sched-ir.c (sel_init_pipelining): Move cfg_cleanup call...
19461 * sel-sched.c (sel_global_init): ... here.
19462
19463 2018-04-12 Eric Botcazou <ebotcazou@adacore.com>
19464
19465 PR target/85238
19466 * lto-wrapper.c (debug_objcopy): Open the files in binary mode.
19467 * dwarf2out.c (dwarf2out_early_finish): Do not generate assembly in LTO
19468 mode for PE-COFF targets.
19469 * config/i386/i386-protos.h (i386_pe_asm_lto_start): Declare.
19470 (i386_pe_asm_lto_end): Likewise.
19471 * config/i386/cygming.h (TARGET_ASM_LTO_START): Define.
19472 (TARGET_ASM_LTO_END): Likewise.
19473 * config/i386/winnt.c (saved_debug_info_level): New static variable.
19474 (i386_pe_asm_lto_start): New function.
19475 (i386_pe_asm_lto_end): Likewise.
19476
19477 2018-04-12 Cesar Philippidis <cesar@codesourcery.com>
19478 Richard Biener <rguenther@suse.de>
19479
19480 PR middle-end/84955
19481 * lto-streamer-out.c (output_function): Fix CFG loop state before
19482 streaming out.
19483 * omp-expand.c (expand_oacc_for): Handle calls to internal
19484 functions like regular functions.
19485
19486 2018-04-12 Richard Biener <rguenther@suse.de>
19487
19488 PR lto/85371
19489 * dwarf2out.c (init_sections_and_labels): Use debug_line_section[_label]
19490 for the early LTO debug to properly generate references to it
19491 during DIE emission. Do not re-use that for the skeleton for
19492 split-dwarf.
19493 (dwarf2out_early_finish): Likewise.
19494
19495 2018-04-12 Jakub Jelinek <jakub@redhat.com>
19496
19497 PR target/85328
19498 * config/i386/sse.md
19499 (<mask_codefor>avx512dq_vextract<shuffletype>64x2_1<mask_name> split,
19500 <mask_codefor>avx512f_vextract<shuffletype>32x4_1<mask_name> split,
19501 vec_extract_lo_<mode><mask_name> split, vec_extract_lo_v32hi,
19502 vec_extract_lo_v64qi): For non-AVX512VL if input is xmm16+ reg
19503 and output is a reg, avoid creating invalid lowpart subreg, but
19504 instead split into a 512-bit move. Don't split if not AVX512VL,
19505 input is xmm16+ reg and output is a mem.
19506 (vec_extract_lo_<mode><mask_name>, vec_extract_lo_v32hi,
19507 vec_extract_lo_v64qi): Don't require split if not AVX512VL, input is
19508 xmm16+ reg and output is a mem.
19509
19510 2018-04-12 Andreas Krebbel <krebbel@linux.vnet.ibm.com>
19511
19512 * config/s390/s390.c (s390_output_indirect_thunk_function): Check
19513 also for flag_dwarf2_cfi_asm.
19514
19515 2018-04-12 Jakub Jelinek <jakub@redhat.com>
19516
19517 PR rtl-optimization/85342
19518 * regcprop.c (copyprop_hardreg_forward_1): Remove replaced array, use
19519 a bool scalar var inside of the loop instead. Don't try to update
19520 recog_data.operand after failed apply_change_group.
19521
19522 2018-04-12 Tom de Vries <tom@codesourcery.com>
19523
19524 PR target/85296
19525 * config/nvptx/nvptx.c (flexible_array_member_type_p): New function.
19526 (nvptx_assemble_decl_begin): Add undefined param. Declare undefined
19527 array with flexible array member as array without given dimension.
19528 (nvptx_assemble_undefined_decl): Set nvptx_assemble_decl_begin call
19529 argument for undefined param to true.
19530
19531 2018-04-11 Aaron Sawdey <acsawdey@linux.ibm.com>
19532
19533 PR target/85321
19534 * doc/invoke.texi (RS/6000 and PowerPC Options): Document options
19535 -mcall- and -mtraceback=. Remove options -mabi=spe and -mabi=no-spe
19536 from PowerPC section.
19537 * config/rs6000/sysv4.opt (mcall-): Improve help text.
19538 * config/rs6000/rs6000.opt (mblock-compare-inline-limit=): Trim
19539 help text that is too long.
19540 * config/rs6000/rs6000.opt (mblock-compare-inline-loop-limit=): Trim
19541 help text that is too long.
19542 * config/rs6000/rs6000.opt (mstring-compare-inline-limit=): Trim
19543 help text that is too long.
19544
19545 2018-04-11 Uros Bizjak <ubizjak@gmail.com>
19546
19547 * config/alpha/alpha.md (stack_probe_internal): Rename
19548 from "probe_stack". Update all callers.
19549
19550 2018-04-11 Alexander Monakov <amonakov@ispras.ru>
19551
19552 PR rtl-optimization/84566
19553 * sched-deps.c (sched_analyze_insn): Check deps->readonly when invoking
19554 sched_macro_fuse_insns.
19555
19556 2018-04-11 Alexander Monakov <amonakov@ispras.ru>
19557
19558 PR target/84301
19559 * sched-rgn.c (add_branch_dependences): Move sel_sched_p check here...
19560 (compute_block_dependences): ... from here.
19561
19562 2018-04-11 Jakub Jelinek <jakub@redhat.com>
19563
19564 PR tree-optimization/85331
19565 * vec-perm-indices.h (vec_perm_indices::clamp): Change input type
19566 from int to HOST_WIDE_INT.
19567
19568 2018-04-11 Martin Jambor <mjambor@suse.cz>
19569
19570 PR ipa/84149
19571 * ipa-cp.c (propagate_vals_across_pass_through): Expand comment.
19572 (cgraph_edge_brings_value_p): New parameter dest_val, check if it is
19573 not the same as the source val.
19574 (cgraph_edge_brings_value_p): New parameter.
19575 (gather_edges_for_value): Pass destination value to
19576 cgraph_edge_brings_value_p.
19577 (perhaps_add_new_callers): Likewise.
19578 (get_info_about_necessary_edges): Likewise and exclude values brought
19579 only by self-recursive edges.
19580 (create_specialized_node): Redirect only clones of self-calling edges.
19581 (+self_recursive_pass_through_p): New function.
19582 (find_more_scalar_values_for_callers_subset): Use it.
19583 (find_aggregate_values_for_callers_subset): Likewise.
19584 (known_aggs_to_agg_replacement_list): Removed.
19585 (decide_whether_version_node): Re-calculate known constants for all
19586 remaining context clones.
19587
19588 2018-04-11 Richard Biener <rguenther@suse.de>
19589
19590 PR lto/85339
19591 * dwarf2out.c (dwarf2out_finish): Remove DW_AT_stmt_list attribute
19592 from early DWARF output.
19593 (dwarf2out_early_finish): Output line info unconditionally into
19594 early DWARF and add reference to it.
19595
19596 2018-04-11 Jakub Jelinek <jakub@redhat.com>
19597
19598 PR target/85281
19599 * config/i386/sse.md (iptr): Add V16SFmode and V8DFmode cases.
19600 (<avx512>_vec_dup<mode><mask_name>): Use a single pattern for modes
19601 other than V2DFmode using iptr mode attribute.
19602 (<avx512>_vec_dup<mode><mask_name>): Use iptr mode attribute.
19603
19604 2018-04-11 Alexander Monakov <amonakov@ispras.ru>
19605
19606 PR rtl-optimization/84659
19607 * sel-sched-ir.c (sel_init_pipelining): Invoke cleanup_cfg.
19608
19609 2018-04-11 Jakub Jelinek <jakub@redhat.com>
19610
19611 PR debug/85302
19612 * dwarf2out.c (skip_loc_list_entry): Don't call size_of_locs if
19613 SIZEP is NULL.
19614 (output_loc_list): Pass address of a dummy size variable even in the
19615 locview handling loop.
19616 (index_location_lists): Add comment on why skip_loc_list_entry can't
19617 call size_of_locs.
19618
19619 2018-04-11 Thomas Preud'homme <thomas.preudhomme@arm.com>
19620
19621 PR target/85261
19622 * config/arm/arm-builtins.c (arm_expand_builtin): Force input operand
19623 into register.
19624
19625 2018-04-10 Aaron Sawdey <acsawdey@linux.ibm.com>
19626
19627 PR target/85321
19628 * doc/invoke.texi (RS/6000 and PowerPC Options): Document options
19629 -mblock-compare-inline-limit, -mblock-compare-inline-loop-limit,
19630 and -mstring-compare-inline-limit.
19631
19632 2018-04-10 Segher Boessenkool <segher@kernel.crashing.org>
19633
19634 PR target/85287
19635 * config/rs6000/rs6000.md (allocate_stack): Put the residual size
19636 for stack clash protection in a register whenever we need it to be in
19637 a register.
19638
19639 2018-04-10 Segher Boessenkool <segher@kernel.crashing.org>
19640
19641 * common/config/rs6000/rs6000-common.c (rs6000_option_init_struct):
19642 Enable -fasynchronous-unwind-tables by default if OBJECT_FORMAT_ELF.
19643
19644 2018-04-10 Segher Boessenkool <segher@kernel.crashing.org>
19645
19646 PR target/85321
19647 * config/rs6000/rs6000.opt (mtraceback=): Show the allowed values in
19648 the help text.
19649 (mlong-double-): Ditto.
19650 * config/rs6000/sysv4.opt (msdata=): Ditto.
19651 (mtls-size=): Ditto.
19652
19653 2018-04-10 Kelvin Nilsen <kelvin@gcc.gnu.org>
19654
19655 * config/rs6000/rs6000-c.c (altivec_overloaded_builtins): Remove
19656 erroneous entries for
19657 "vector int vec_ldl (int, long int *)", and
19658 "vector unsigned int vec_ldl (int, unsigned long int *)".
19659 Add comments and entries for
19660 "vector bool char vec_ldl (int, bool char *)",
19661 "vector bool short vec_ldl (int, bool short *)",
19662 "vector bool int vec_ldl (int, bool int *)",
19663 "vector bool long long vec_ldl (int, bool long long *)",
19664 "vector pixel vec_ldl (int, pixel *)",
19665 "vector long long vec_ldl (int, long long *)",
19666 "vector unsigned long long vec_ldl (int, unsigned long long *)".
19667 * config/rs6000/rs6000.c (rs6000_init_builtins): Initialize new
19668 type tree bool_long_long_type_node and correct definition of
19669 bool_V2DI_type_node to make reference to this new type tree.
19670 (rs6000_mangle_type): Replace erroneous reference to
19671 bool_long_type_node with bool_long_long_type_node.
19672 * config/rs6000/rs6000.h (enum rs6000_builtin_type_index): Add
19673 comments to emphasize sign distinctions for char and int types and
19674 replace RS6000_BTI_bool_long constant with
19675 RS6000_BTI_bool_long_long constant. Also add comment to restrict
19676 use of RS6000_BTI_pixel.
19677 (bool_long_type_node): Remove this macro definition.
19678 (bool_long_long_type_node): New macro definition
19679
19680 2018-04-10 Jakub Jelinek <jakub@redhat.com>
19681
19682 PR rtl-optimization/85300
19683 * combine.c (subst): Handle subst of CONST_SCALAR_INT_P new_rtx also
19684 into FLOAT and UNSIGNED_FLOAT like ZERO_EXTEND, return a CLOBBER if
19685 simplify_unary_operation fails.
19686
19687 2018-04-10 Martin Liska <mliska@suse.cz>
19688
19689 * gdbhooks.py: Add pretty-printers for varpool_node, symtab_node,
19690 cgraph_edge and ipa_ref.
19691
19692 2018-04-10 Jakub Jelinek <jakub@redhat.com>
19693
19694 PR target/85177
19695 PR target/85255
19696 * config/i386/sse.md
19697 (<extract_type>_vinsert<shuffletype><extract_suf>_mask): Fix
19698 computation of the VEC_MERGE selector from mask.
19699 (<extract_type>_vinsert<shuffletype><extract_suf>_1<mask_name>):
19700 Fix decoding of the VEC_MERGE selector into mask.
19701
19702 2018-04-10 Richard Sandiford <richard.sandiford@linaro.org>
19703
19704 PR tree-optimization/85286
19705 * tree-vect-data-refs.c (vect_get_smallest_scalar_type):
19706
19707 2018-04-10 Richard Sandiford <richard.sandiford@linaro.org>
19708
19709 * final.c (final_1): Set insn_last_address as well as
19710 insn_current_address.
19711
19712 2018-04-10 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
19713
19714 PR target/85173
19715 * explow.c (emit_stack_probe): Call validize_mem on memory location
19716 before passing it to gen_probe_stack. Create address operand and
19717 legitimize it for the probe_stack_address case.
19718
19719 2018-04-09 Jan Hubicka <jh@suse.cz>
19720
19721 PR lto/85078
19722 * ipa-devirt.c (rebuild_type_inheritance-hash): New.
19723 * ipa-utils.h (rebuild_type_inheritance-hash): Declare.
19724 * tree.c (free_lang_data_in_type): Fix handling of binfos;
19725 walk basetypes.
19726 (free_lang_data): Rebuild type inheritance graph.
19727
19728 2018-04-09 Martin Sebor <msebor@redhat.com>
19729
19730 * invoke.texi (-finline-small-functions): Mention other optimization
19731 options.
19732 (-findirect-inlining, -fpartial-inlining): Same.
19733 (-finline-functions-called-once): Same.
19734 (-freorder-blocks-and-partition): Same.
19735
19736 2018-04-09 Jan Hubicka <jh@suse.cz>
19737
19738 PR rtl/84058
19739 * cfgcleanup.c (try_forward_edges): Do not give up on crossing
19740 jumps; choose last target that matches the criteria (i.e.
19741 no partition changes for non-crossing jumps).
19742 * cfgrtl.c (cfg_layout_redirect_edge_and_branch): Add basic
19743 support for redirecting crossing jumps to non-crossing.
19744
19745 2018-04-09 Alexey Brodkin <abrodkin@synopsys.com>
19746
19747 * config/arc/arc.c (arc_expand_prologue): Set stack usage info
19748 also for naked functions.
19749
19750 2018-04-09 Claudiu Zissulescu <claziss@synopsys.com>
19751
19752 * config/arc/arc.md (add_shift): New pattern.
19753 (add_shift2): Likewise.
19754 (sub_shift): Likewise.
19755 (sub_shift_cmp0_noout): Likewise.
19756 (compare_si_ashiftsi): Likewise.
19757 (xbfu_cmp0_noout): New combine pattern.
19758 (xbfu_cmp0"): Likewise.
19759 (movsi_set_cc_insn): Place the predicable variant first.
19760 (commutative_binary_cmp0_noout): Remove clobber.
19761 (commutative_binary_cmp0): New pattern.
19762 (noncommutative_binary_cmp0): Likewise.
19763 (noncommutative_binary_cmp0_noout): Likewise.
19764 (noncommutative_binary_comparison_result_used): Removed.
19765 (rsub_cmp0): New pattern.
19766 (rsub_cmp0_noout): Likewise.
19767 (extzvsi): Changed, keep only meaningful variants.
19768 (SQH, SEZ): New iterators.
19769 (SQH_postfix): New mode attribute.
19770 (SEZ_prefix): New code attribute.
19771 (<SEZ_prefix>xt<SQH_postfix>_cmp0_noout): New instruction pattern.
19772 (<SEZ_prefix>xt<SQH_postfix>_cmp0): Likewise.
19773 * config/arc/predicates.md (cc_set_register): Use CC_REG instead
19774 of numerical value.
19775 (noncommutative_operator): Check the availability of barrel
19776 shifter option.
19777
19778 2018-04-09 Richard Biener <rguenther@suse.de>
19779
19780 PR tree-optimization/85284
19781 * tree-ssa-loop-niter.c (number_of_iterations_exit_assumptions):
19782 Only use the niter constraining form of simple_iv when the exit
19783 is always executed.
19784
19785 2018-04-09 Tom de Vries <tom@codesourcery.com>
19786
19787 PR target/84041
19788 * config/nvptx/nvptx.md (define_c_enum "unspecv"): Add UNSPECV_MEMBAR.
19789 (define_expand "*memory_barrier"): New define_expand.
19790 (define_insn "memory_barrier"): New insn.
19791
19792 2018-04-09 Andrey Belevantsev <abel@ispras.ru>
19793
19794 PR rtl-optimization/80463
19795 PR rtl-optimization/83972
19796 PR rtl-optimization/83480
19797
19798 * sel-sched-ir.c (has_dependence_note_mem_dep): Take into account the
19799 correct producer for the insn.
19800 (tidy_control_flow): Fixup seqnos in case of debug insns.
19801
19802 2018-04-09 Andrey Belevantsev <abel@ispras.ru>
19803
19804 PR rtl-optimization/83913
19805
19806 * sel-sched-ir.c (merge_expr_data): Choose the middle between two
19807 different sched-times when merging exprs.
19808
19809 2018-04-09 Andrey Belevantsev <abel@ispras.ru>
19810
19811 PR rtl-optimization/83962
19812
19813 * sel-sched-ir.c (tidy_control_flow): Correct the order in which we call
19814 tidy_fallthru_edge and tidy_control_flow.
19815
19816 2018-04-09 Andrey Belevantsev <abel@ispras.ru>
19817
19818 PR rtl-optimization/83530
19819
19820 * sel-sched.c (force_next_insn): New global variable.
19821 (remove_insn_for_debug): When force_next_insn is true, also leave only
19822 next insn in the ready list.
19823 (sel_sched_region): When the region wasn't scheduled, make another pass
19824 over it with force_next_insn set to 1.
19825
19826 2018-04-08 Monk Chiang <sh.chiang04@gmail.com>
19827
19828 * config.gcc (nds32le-*-*, nds32be-*-*): Add nds32/nds32_intrinsic.h
19829 into tm_file.
19830 * config/nds32/constants.md (unspec_volatile_element): Add enum values
19831 for interrupt control.
19832 * config/nds32/nds32-intrinsic.c: Implementation of intrinsic
19833 functions for interrupt control.
19834 * config/nds32/nds32-intrinsic.md: Likewise.
19835 * config/nds32/nds32_intrinsic.h: Likewise.
19836 * config/nds32/nds32.h (nds32_builtins): Likewise.
19837
19838 2018-04-08 Chung-Ju Wu <jasonwucj@gmail.com>
19839
19840 * config/nds32/nds32.c (nds32_init_machine_status,
19841 nds32_legitimate_index_p, nds32_legitimate_address_p): Consider
19842 strict_aligned_p field.
19843 (nds32_expand_to_rtl_hook): New function.
19844 (TARGET_EXPAND_TO_RTL_HOOK): Define.
19845 * config/nds32/nds32.h (machine_function): Add strict_aligned_p field.
19846
19847 2018-04-08 Kito Cheng <kito.cheng@gmail.com>
19848 Chung-Ju Wu <jasonwucj@gmail.com>
19849
19850 * config.gcc (nds32*-*-*): Check that n7 is valid to --with-cpu.
19851 * config/nds32/nds32-n7.md: New file.
19852 * config/nds32/nds32-opts.h (nds32_cpu_type): Add CPU_N7.
19853 * config/nds32/nds32-pipelines-auxiliary.c: Implementation for n7
19854 pipeline.
19855 * config/nds32/nds32-protos.h: More declarations for n7 pipeline.
19856 * config/nds32/nds32.md (pipeline_model): Add n7.
19857 * config/nds32/nds32.opt (mcpu): Support n7 pipeline cpus.
19858 * config/nds32/pipelines.md: Include n7 settings.
19859
19860 2018-04-08 Kito Cheng <kito.cheng@gmail.com>
19861 Chung-Ju Wu <jasonwucj@gmail.com>
19862
19863 * config.gcc (nds32*-*-*): Check that e8 is valid to --with-cpu.
19864 * config/nds32/nds32-e8.md: New file.
19865 * config/nds32/nds32-opts.h (nds32-cpu_type): Add CPU_E8.
19866 * config/nds32/nds32-pipelines-auxiliary.c: Implementation for e8
19867 pipeline.
19868 * config/nds32/nds32-protos.h: More declarations for e8 pipeline.
19869 * config/nds32/nds32.md (pipeline_model): Add e8.
19870 * config/nds32/nds32.opt (mcpu): Support e8 pipeline cpus.
19871 * config/nds32/pipelines.md: Include e8 settings.
19872
19873 2018-04-08 Kito Cheng <kito.cheng@gmail.com>
19874 Chung-Ju Wu <jasonwucj@gmail.com>
19875
19876 * config.gcc (nds32*-*-*): Check that n6/n8/s8 are valid to --with-cpu.
19877 * config/nds32/nds32-n8.md: New file.
19878 * config/nds32/nds32-opts.h (nds32_cpu_type): Add CPU_N6 and CPU_N8.
19879 * config/nds32/nds32-pipelines-auxiliary.c: Implementation for n8
19880 pipeline.
19881 * config/nds32/nds32-protos.h: More declarations for n8 pipeline.
19882 * config/nds32/nds32-utils.c: More implementations for n8 pipeline.
19883 * config/nds32/nds32.md (pipeline_model): Add n8.
19884 * config/nds32/nds32.opt (mcpu): Support n8 pipeline cpus.
19885 * config/nds32/pipelines.md: Include n8 settings.
19886
19887 2018-04-08 Kito Cheng <kito.cheng@gmail.com>
19888 Chung-Ju Wu <jasonwucj@gmail.com>
19889
19890 * config.gcc (nds32*): Add nds32-utils.o into extra_objs.
19891 * config/nds32/nds32-n9-2r1w.md: New file.
19892 * config/nds32/nds32-n9-3r2w.md: New file.
19893 * config/nds32/nds32-opts.h (nds32_cpu_type, nds32_mul_type,
19894 nds32_register_ports): New or modify for cpu n9.
19895 * config/nds32/nds32-pipelines-auxiliary.c: Implementation for n9
19896 pipeline.
19897 * config/nds32/nds32-protos.h: More declarations for n9 pipeline.
19898 * config/nds32/nds32-utils.c: New file.
19899 * config/nds32/nds32.h (TARGET_PIPELINE_N9, TARGET_PIPELINE_SIMPLE,
19900 TARGET_MUL_SLOW): Define.
19901 * config/nds32/nds32.md (pipeline_model): New attribute.
19902 * config/nds32/nds32.opt (mcpu, mconfig-mul, mconfig-register-ports):
19903 New options that support cpu n9.
19904 * config/nds32/pipelines.md: Include n9 settings.
19905 * config/nds32/t-nds32 (nds32-utils.o): Add dependency.
19906
19907 2018-04-08 Chung-Ju Wu <jasonwucj@gmail.com>
19908
19909 * config/nds32/nds32-md-auxiliary.c (output_cond_branch): Output align
19910 information if necessary.
19911 (output_cond_branch_compare_zero): Likewise.
19912 * config/nds32/nds32.c (nds32_adjust_insn_length): Consider align case.
19913 (nds32_target_alignment): Refine for alignment.
19914 * config/nds32/nds32.h (NDS32_ALIGN_P): Define.
19915 (FUNCTION_BOUNDARY): Modify.
19916 * config/nds32/nds32.md (call_internal, call_value_internal): Consider
19917 align case.
19918 * config/nds32/nds32.opt (malways-align, malign-functions): New.
19919
19920 2018-04-08 Monk Chiang <sh.chiang04@gmail.com>
19921
19922 * config/nds32/constants.md (unspec_volatile_element): Add values for
19923 TLB operation and data prefetch.
19924 * config/nds32/nds32-intrinsic.c: Implementation of intrinsic
19925 functions for TLB operation and data prefetch.
19926 * config/nds32/nds32-intrinsic.md: Likewise.
19927 * config/nds32/nds32_intrinsic.h: Likewise.
19928 * config/nds32/nds32.c (nds32_dpref_names): Likewise.
19929 (nds32_print_operand): Likewise.
19930 * config/nds32/nds32.h (nds32_builtins): Likewise.
19931
19932 2018-04-07 Thomas Koenig <tkoenig@gcc.gnu.org>
19933 Andrew Pinski <pinsika@gcc.gnu.org>
19934
19935 PR middle-end/82976
19936 * match.pd: Use constant_boolean_node of correct type instead of
19937 boolean_true_node or boolean_false_node for simplifying
19938 pointer comparisons to zero.
19939
19940 2018-04-07 Jakub Jelinek <jakub@redhat.com>
19941
19942 PR tree-optimization/80021
19943 * tree.c (verify_type_variant): Make error call in verify_variant_match
19944 translatable and remove final full stop.
19945
19946 2018-04-07 Chung-Ju Wu <jasonwucj@gmail.com>
19947
19948 * config/nds32/constants.md (unspec_volatile_element): Add
19949 UNSPEC_VOLATILE_EH_RETURN.
19950 * config/nds32/nds32-md-auxiliary.c (nds32_output_stack_push,
19951 nds32_output_stack_pop): Support dwarf exception handling process.
19952 * config/nds32/nds32-protos.h (nds32_dynamic_chain_address): Declare.
19953 * config/nds32/nds32.c (nds32_init_machine_status): Support dwarf
19954 exception handling process.
19955 (nds32_compute_stack_frame): Likewise.
19956 (nds32_return_addr_rtx): Likewise.
19957 (nds32_initial_elimination_offset): Likewise.
19958 (nds32_expand_prologue): Likewise.
19959 (nds32_expand_epilogue): Likewise.
19960 (nds32_dynamic_chain_address): New function.
19961 * config/nds32/nds32.h (machine_function): Add fields for dwarf
19962 exception handling.
19963 (DYNAMIC_CHAIN_ADDRESS): Define.
19964 (EH_RETURN_DATA_REGNO): Define.
19965 (EH_RETURN_STACKADJ_RTX): Define.
19966 * config/nds32/nds32.md (eh_return, nds32_eh_return): Implement
19967 patterns for dwarf exception handling.
19968
19969 2018-04-07 Chung-Ju Wu <jasonwucj@gmail.com>
19970
19971 * config/nds32/nds32.h: Clean up obsolete macros.
19972
19973 2018-04-07 Monk Chiang <sh.chiang04@gmail.com>
19974
19975 * config/nds32/constants.md (unspec_element, unspec_volatile_element):
19976 Add enum values for particular instructions.
19977 * config/nds32/nds32-intrinsic.c: Implementation of expanding
19978 particular intrinsic functions.
19979 * config/nds32/nds32-intrinsic.md: Likewise.
19980 * config/nds32/nds32_intrinsic.h: Likewise.
19981 * config/nds32/nds32.h (nds32_builtins): Likewise.
19982 * config/nds32/nds32.md (type): Add pbsad and pbsada.
19983 (btst, ave): New patterns for particular instructions.
19984
19985 2018-04-07 Monk Chiang <sh.chiang04@gmail.com>
19986
19987 * config/nds32/constants.md (unspec_element, unspec_volatile_element):
19988 Add enum values for atomic load/store and memory sync.
19989 * config/nds32/nds32-intrinsic.c: Implementation for atomic load/store
19990 and memory sync.
19991 * config/nds32/nds32-intrinsic.md: Likewise.
19992 * config/nds32/nds32_intrinsic.h: Likewise.
19993 * config/nds32/nds32.h (nds32_builtins): Likewise.
19994
19995 2018-04-07 Jakub Jelinek <jakub@redhat.com>
19996
19997 PR tree-optimization/85257
19998 * fold-const.c (native_encode_vector): If not all elts could fit
19999 and off is -1, return 0 rather than offset.
20000 * tree-ssa-sccvn.c (vn_reference_lookup_3): Pass
20001 (offseti - offset2) / BITS_PER_UNIT as 4th argument to
20002 native_encode_expr. Verify len * BITS_PER_UNIT >= maxsizei. Don't
20003 adjust buffer in native_interpret_expr call.
20004
20005 2018-04-07 Monk Chiang <sh.chiang04@gmail.com>
20006
20007 * config/nds32/constants.md (unspec_volatile_element): Add cache
20008 control enum values.
20009 * config/nds32/nds32-intrinsic.c: Add cache control expand functions.
20010 * config/nds32/nds32-intrinsic.md: Add cache control patterns.
20011 * config/nds32/nds32.c (nds32_cctl_names): New.
20012 (nds32_print_operand): Handle cache control register names.
20013 * config/nds32/nds32.h (nds32_builtins): New enum values.
20014 * config/nds32/nds32_intrinsic.h: Add cache control enum types and
20015 macros.
20016 * config/nds32/nds32.md (type): Add mmu.
20017 * config/nds32/pipelines.md (simple_insn): Add mmu.
20018
20019 2018-04-07 Chung-Ju Wu <jasonwucj@gmail.com>
20020
20021 * config/nds32/nds32.md (type): Remove call.
20022 * config/nds32/pipelines.md (simple_insn): Likewise.
20023
20024 2018-04-07 Monk Chiang <sh.chiang04@gmail.com>
20025
20026 * config/nds32/constants.md (unspec_volatile_element): Add
20027 UNSPEC_VOLATILE_FMFCSR, UNSPEC_VOLATILE_FMTCSR and
20028 UNSPEC_VOLATILE_FMFCFG.
20029 * config/nds32/nds32-intrinsic.c (bdesc_noarg): New builtin
20030 description for fmfcfg and fmfcsr.
20031 (bdesc_1arg): Add fmtcsr.
20032 (bdesc_2arg): Add fcpynss, fcpyss, fcpynsd and fcpysd.
20033 (nds32_expand_builtin_impl): Deal with FPU intrinsic functions.
20034 * config/nds32/nds32-intrinsic.md (unspec_fcpynsd, unspec_fcpysd,
20035 unspec_fcpynss, unspec_fcpysd, unspec_fcpyss, unspec_fmfcsr,
20036 unspec_fmfcfg): New patterns.
20037 * config/nds32/nds32.h (nds32_builtins): Add NDS32_BUILTIN_FMFCFG,
20038 NDS32_BUILTIN_FMFCSR, NDS32_BUILTIN_FMTCSR, NDS32_BUILTIN_FCPYNSS,
20039 NDS32_BUILTIN_FCPYSS,NDS32_BUILTIN_FCPYNSD and NDS32_BUILTIN_FCPYSD.
20040 * config/nds32/nds32_intrinsic.h (__nds32__fcpynsd, __nds32__fcpynss,
20041 __nds32__fcpysd, __nds32__fcpyss, __nds32__fmfcsr, __nds32__fmtcsr,
20042 __nds32__fmfcfg): Define.
20043
20044 2018-04-07 Monk Chiang <sh.chiang04@gmail.com>
20045
20046 * config/nds32/nds32.c (nds32_intrinsic_register_names): Add more
20047 intrinsic register names.
20048 * config/nds32/nds32_intrinsic.h (nds32_intrinsic_registers): Add more
20049 intrinsic register enum values and macros.
20050
20051 2018-04-07 Chung-Ju Wu <jasonwucj@gmail.com>
20052
20053 * config/nds32/nds32.c (nds32_legitimate_index_p): Modify condition
20054 for load/store addressing form.
20055 (nds32_print_operand_address): Likewise.
20056
20057 2018-04-06 Eric Botcazou <ebotcazou@adacore.com>
20058
20059 PR target/85196
20060 * config/sparc/sparc.c (sparc_expand_move): Deal with symbolic operands
20061 based on LABEL_REF. Remove useless assertion.
20062 (pic_address_needs_scratch): Fix formatting.
20063 (sparc_legitimize_pic_address): Minor tweaks.
20064 (sparc_delegitimize_address): Adjust assertion accordingly.
20065 * config/sparc/sparc.md (movsi_pic_label_ref): Change label_ref_operand
20066 into symbolic_operand.
20067 (movsi_high_pic_label_ref): Likewise.
20068 (movsi_lo_sum_pic_label_ref): Likewise.
20069 (movdi_pic_label_ref): Likewise.
20070 (movdi_high_pic_label_ref): Likewise.
20071 (movdi_lo_sum_pic_label_ref): Likewise.
20072
20073 2018-04-06 Amaan Cheval <amaan.cheval@gmail.com>
20074
20075 * config.gcc (x86_64-*-rtems*): Add rtems.h to tm_file for
20076 custom LIB_SPEC setup.
20077
20078 2018-04-06 Ruslan Bukin <br@bsdpad.com>
20079 Kito Cheng <kito.cheng@gmail.com>
20080
20081 * config.gcc (riscv*-*-freebsd*): Add RISC-V FreeBSD support.
20082 * config/riscv/freebsd.h: New.
20083
20084 2018-04-06 Chung-Ju Wu <jasonwucj@gmail.com>
20085
20086 * config/nds32/nds32.c (nds32_adjust_insn_length): Refine.
20087 * config/nds32/nds32.h (ADJUST_INSN_LENGTH): Change the location in
20088 file.
20089
20090 2018-04-06 Chung-Ju Wu <jasonwucj@gmail.com>
20091 Kito Cheng <kito.cheng@gmail.com>
20092
20093 * config/nds32/nds32-md-auxiliary.c (nds32_output_return,
20094 nds32_output_call, nds32_symbol_binds_local_p): New functions.
20095 * config/nds32/nds32-protos.h (nds32_output_call,
20096 nds32_output_return): Declare.
20097 * config/nds32/nds32.md: Refine all the call and return patterns.
20098
20099 2018-04-06 Jakub Jelinek <jakub@redhat.com>
20100
20101 PR debug/85252
20102 * dwarf2out.c (rtl_for_decl_init): For STRING_CST initializer only
20103 build CONST_STRING if TYPE_MAX_VALUE is non-NULL and is INTEGER_CST.
20104
20105 PR rtl-optimization/84872
20106 * cfgloopmanip.c (create_preheader): Use make_forwarder_block even if
20107 nentry == 1 when CP_FALLTHRU_PREHEADERS and single_entry is
20108 EDGE_CROSSING edge.
20109
20110 2018-04-06 Tamar Christina <tamar.christina@arm.com>
20111
20112 * expr.c (copy_blkmode_to_reg): Revert 254862.
20113 * doc/sourcebuild.texi (word_mode_no_slow_unalign): Likewise.
20114
20115 2018-04-06 Richard Biener <rguenther@suse.de>
20116
20117 PR middle-end/85244
20118 * tree-dfa.c (get_ref_base_and_extent): Reset seen_variable_array_ref
20119 after seeing a component reference with an adjacent field. Treat
20120 refs to arrays at struct end of external decls similar to
20121 refs to unconstrained commons.
20122
20123 2018-04-06 Jakub Jelinek <jakub@redhat.com>
20124
20125 PR sanitizer/85213
20126 * fold-const.c (twoval_comparison_p): Remove SAVE_P argument and don't
20127 look through SAVE_EXPRs with non-side-effects argument. Adjust
20128 recursive calls.
20129 (fold_comparison): Adjust twoval_comparison_p caller, don't handle
20130 save_p here.
20131
20132 2018-04-06 Richard Biener <rguenther@suse.de>
20133
20134 PR middle-end/85180
20135 * alias.c (find_base_term): New wrapper around find_base_term
20136 unwinding CSELIB_VAL_PTR changes.
20137 (find_base_term): Do not restore CSELIB_VAL_PTR during the
20138 recursion.
20139
20140 2018-04-06 Andreas Krebbel <krebbel@linux.vnet.ibm.com>
20141
20142 * config/s390/s390.c (s390_z10_optimize_cmp): Expand dedicated NOP
20143 instructions.
20144 * config/s390/s390.md (UNSPECV_NOP_LR_0, UNSPECV_NOP_LR_1): New
20145 constant definitions.
20146 ("nop"): lr 0,0 -> nopr r0
20147 ("nop_lr0", "nop_lr1"): New insn definitions.
20148
20149 2018-04-06 Chung-Ju Wu <jasonwucj@gmail.com>
20150
20151 * config/nds32/nds32.md (*stack_push, *stack_pop): Use
20152 NDS32_V3PUSH_AVAILABLE_P macro.
20153
20154 2018-04-06 Monk Chiang <sh.chiang04@gmail.com>
20155 Chung-Ju Wu <jasonwucj@gmail.com>
20156
20157 * config.gcc (nds32*-*-*): Add v2j v3f v3s checking.
20158 (nds32*-*-*): Add float and fpu_config into supported_defaults.
20159 * common/config/nds32/nds32-common.c (TARGET_DEFAULT_TARGET_FLAGS):
20160 Include TARGET_DEFAULT_FPU_ISA and TARGET_DEFAULT_FPU_FMA.
20161 * config/nds32/constants.md (unspec_element): Add UNSPEC_COPYSIGN,
20162 UNSPEC_FCPYNSD, UNSPEC_FCPYNSS, UNSPEC_FCPYSD and UNSPEC_FCPYSS.
20163 * config/nds32/constraints.md: New constraints and checking for hard
20164 float configuration.
20165 * config/nds32/iterators.md: New mode iterator and attribute for hard
20166 float configuration.
20167 * config/nds32/nds32-doubleword.md: Use hard float alternatives and
20168 patterns.
20169 * config/nds32/nds32-fpu.md: New file.
20170 * config/nds32/nds32-md-auxiliary.c: New functions and checkings to
20171 deal with hard float code generation.
20172 * config/nds32/nds32-opts.h (nds32_arch_type): Add ARCH_V3F and
20173 ARCH_V3S.
20174 (abi_type, float_reg_number): New enum type.
20175 * config/nds32/nds32-predicates.c: New predicates for hard float.
20176 * config/nds32/nds32-protos.h: Declare functions for hard float.
20177 * config/nds32/nds32.c: Implementation for hard float configuration.
20178 * config/nds32/nds32.h: Definitions for hard float configuration.
20179 * config/nds32/nds32.md: Include hard float machine description and
20180 modify patterns for hard float configuration.
20181 * config/nds32/nds32.opt: New options for hard float configuration.
20182 * config/nds32/predicates.md: New predicates for hard float
20183 configuration.
20184
20185 2018-04-06 Kuan-Lin Chen <kuanlinchentw@gmail.com>
20186
20187 * common/config/nds32/nds32-common.c
20188 (nds32_option_optimization_table): Enable -mreleax-hint by default.
20189
20190 2018-04-05 Jakub Jelinek <jakub@redhat.com>
20191
20192 PR middle-end/85195
20193 * match.pd (BIT_FIELD_REF CONSTRUCTOR@0 @1 @2): Use view_convert around
20194 CONSTRUCTOR_ELT (ctor, ...)->value.
20195
20196 2018-04-05 Uros Bizjak <ubizjak@gmail.com>
20197
20198 PR target/85193
20199 * config/i386/i386.md (define_attr "memory"): Handle rotate1 type.
20200
20201 2018-04-05 Tom de Vries <tom@codesourcery.com>
20202
20203 PR target/85204
20204 * config/nvptx/nvptx.c (nvptx_single): Fix neutering of bb with only
20205 cond jump.
20206
20207 2018-04-05 Shiva Chen <shiva0217@gmail.com>
20208 Kito Cheng <kito.cheng@gmail.com>
20209
20210 * config/nds32/constraints.md (U33): Fine-tune checking condition.
20211 * config/nds32/nds32-md-auxiliary.c (nds32_mem_format): Ditto.
20212 * config/nds32/nds32.h (nds32_16bit_address_type): Add
20213 ADDRESS_POST_MODIFY_LO_REG_IMM3U.
20214
20215 2018-04-05 Shiva Chen <shiva0217@gmail.com>
20216 Kito Cheng <kito.cheng@gmail.com>
20217
20218 * config/nds32/constraints.md (Ufe): New memory constraint.
20219 * config/nds32/nds32-md-auxiliary.c (nds32_mem_format,
20220 nds32_output_16bit_load): Consider r8 register for lwi45.fe format.
20221 * config/nds32/nds32.c (nds32_print_operand): Output lwi45.fe
20222 operands.
20223 * config/nds32/nds32.h (nds32_16bit_address_type): Add ADDRESS_R8_IMM7U.
20224 * config/nds32/nds32.md (*mov<mode>): Adjust pattern.
20225
20226 2018-04-05 Chung-Ju Wu <jasonwucj@gmail.com>
20227
20228 * config/nds32/nds32.md: Use optimize_size in the condition for
20229 alu-shift instructions.
20230
20231 2018-04-05 Chung-Ju Wu <jasonwucj@gmail.com>
20232
20233 * config/nds32/nds32.md (divsi4, udivsi4): New patterns.
20234
20235 2018-04-05 Chung-Ju Wu <jasonwucj@gmail.com>
20236
20237 * config/nds32/nds32.md (negsi2): Refine pattern.
20238
20239 2018-04-05 Kito Cheng <kito.cheng@gmail.com>
20240 Chung-Ju Wu <jasonwucj@gmail.com>
20241
20242 * config/nds32/iterators.md (shift_rotate): New code iterator.
20243 (shift): New code attribute.
20244 * config/nds32/nds32-md-auxiliary.c (nds32_expand_constant): New.
20245 * config/nds32/nds32-protos.h (nds32_expand_constant): Declare.
20246 * config/nds32/nds32.c (nds32_print_operand): Deal with more cases.
20247 * config/nds32/nds32.md (addsi3, *add_srli): Refine implementation for
20248 bit-wise operations.
20249 (andsi3, *andsi3): Ditto.
20250 (iorsi3, *iorsi3, *or_slli, *or_srli): Ditto.
20251 (xorsi3, *xorsi3, *xor_slli, *xor_srli): Ditto.
20252 (<shift>si3, *ashlsi3, *ashrsi3, *lshrsi3, *rotrsi3): Ditto.
20253 * config/nds32/predicates.md (nds32_rimm5u_operand, nds32_and_operand,
20254 nds32_ior_operand, nds32_xor_operand): New predicates.
20255
20256 2018-04-05 Chung-Ju Wu <jasonwucj@gmail.com>
20257
20258 * config/nds32/nds32.md (add<mode>3, sub<mode>3): Rename to ...
20259 (addsi3, subsi3): ... this.
20260
20261 2018-04-05 Chung-Ju Wu <jasonwucj@gmail.com>
20262
20263 * config/nds32/nds32.md (*sub_srli, *and_slli): Fine-tune predicator.
20264
20265 2018-04-05 Chung-Ju Wu <jasonwucj@gmail.com>
20266
20267 * config/nds32/nds32.md: Adjust indention.
20268
20269 2018-04-05 Kito Cheng <kito.cheng@gmail.com>
20270
20271 * config/nds32/nds32.md (feature): New attribute.
20272
20273 2018-04-05 Chung-Ju Wu <jasonwucj@gmail.com>
20274
20275 * config/nds32/nds32.md (subtype): New attribute.
20276
20277 2018-04-04 Thomas Preud'homme <thomas.preudhomme@arm.com>
20278
20279 PR target/85203
20280 * config/arm/arm-builtins.c (arm_expand_builtin): Change
20281 expansion to perform a bitwise AND of the argument followed by a
20282 boolean negation of the result.
20283
20284 2018-04-04 Peter Bergner <bergner@vnet.ibm.com>
20285
20286 PR rtl-optimization/84878
20287 * ddg.c (add_cross_iteration_register_deps): Use DF_REF_BB to determine
20288 the basic block. Assert the use reference is not artificial and that
20289 it has an associated insn.
20290
20291 2018-04-04 Michael Matz <matz@suse.de>
20292
20293 * builtins.c (compute_objsize): Pass correct operand
20294 to array_at_struct_end_p.
20295
20296 2018-04-04 Richard Biener <rguenther@suse.de>
20297
20298 PR lto/85176
20299 * dwarf2out.c (dwarf2out_register_external_die): Peel namespaces
20300 from contexts for DINFO_LEVEL_TERSE and below.
20301
20302 2018-04-04 Kito Cheng <kito.cheng@gmail.com>
20303
20304 * config/nds32/nds32-doubleword.md (move_<mode>): Require
20305 resiter_operand condition.
20306 * config/nds32/nds32.md (*move<mode>): Ditto.
20307
20308 2018-04-04 Kito Cheng <kito.cheng@gmail.com>
20309 Monk Chiang <sh.chiang04@gmail.com>
20310
20311 * config/nds32/nds32.md (movmisalign<mode>): New pattern.
20312
20313 2018-04-04 Chung-Ju Wu <jasonwucj@gmail.com>
20314
20315 * config/nds32/nds32.md (movqi, movhi): Merge into mov<mode>.
20316
20317 2018-04-04 Chung-Ju Wu <jasonwucj@gmail.com>
20318 Kito Cheng <kito.cheng@gmail.com>
20319
20320 * config/nds32/nds32-md-auxiliary.c (nds32_inverse_cond_code,
20321 nds32_cond_code_str, output_cond_branch,
20322 output_cond_branch_compare_zero, nds32_expand_cbranch,
20323 nds32_expand_cstore, nds32_expand_movcc,
20324 nds32_output_cbranchsi4_equality_zero,
20325 nds32_output_cbranchsi4_equality_reg,
20326 nds32_output_cbranchsi4_equality_reg_or_const_int,
20327 nds32_output_cbranchsi4_greater_less_zero: New functions.
20328 * config/nds32/nds32-protos.h (nds32_expand_cbranch,
20329 nds32_expand_cstore, nds32_expand_movcc,
20330 nds32_output_cbranchsi4_equality_zero,
20331 nds32_output_cbranchsi4_equality_reg,
20332 nds32_output_cbranchsi4_equality_reg_or_const_int,
20333 nds32_output_cbranchsi4_greater_less_zero): Declare.
20334 * config/nds32/predicates.md (nds32_movecc_comparison_operator,
20335 nds32_rimm11s_operand): New predicates.
20336 * config/nds32/nds32.h (nds32_expand_result_type): New enum type.
20337 * config/nds32/nds32.md: Rewrite all the branch and conditional move
20338 patterns.
20339
20340 2018-04-04 Kito Cheng <kito.cheng@gmail.com>
20341
20342 * config/nds32/nds32-doubleword.md: Refine all the instruction type.
20343 * config/nds32/nds32.md: Ditto.
20344 * config/nds32/pipelines.md: Ditto.
20345
20346 2018-04-04 Richard Biener <rguenther@suse.de>
20347
20348 PR tree-optimization/85168
20349 * tree-ssa-sccvn.c (vn_reference_maybe_forwprop_address): Avoid
20350 propagating abnormals.
20351
20352 2018-04-04 Chung-Ju Wu <jasonwucj@gmail.com>
20353
20354 * config/nds32/nds32.md (enabled): Use yes/no for this attribute.
20355
20356 2018-04-04 Chung-Ju Wu <jasonwucj@gmail.com>
20357 Kito Cheng <kito.cheng@gmail.com>
20358
20359 * config/nds32/nds32-md-auxiliary.c (nds32_long_call_p): New function.
20360 * config/nds32/nds32-protos.h (nds32_long_call_p): Declare.
20361 * config/nds32/nds32.c (nds32_function_ok_for_sibcall): New function.
20362 (TARGET_FUNCTION_OK_FOR_SIBCALL): Define.
20363 * config/nds32/nds32.md (sibcall_internal): New.
20364 (sibcall_register): Remove.
20365 (sibcall_immediate): Remove.
20366 (sibcall_value_internal): New.
20367 (sibcall_value_register): Remove.
20368 (sibcall_value_immediate): Remove.
20369 * config/nds32/predicates.md (nds32_general_register_operand): New.
20370 (nds32_call_address_operand): New.
20371
20372 2018-04-03 Jakub Jelinek <jakub@redhat.com>
20373
20374 PR rtl-optimization/85167
20375 * shrink-wrap.c (move_insn_for_shrink_wrap): Don't set bb_uses and
20376 bb_defs if *split_p, instead preinitialize it to NULL.
20377
20378 PR tree-optimization/85156
20379 * builtins.c (fold_builtin_expect): Use save_expr on arg1 to avoid
20380 evaluating the argument multiple times.
20381
20382 2018-04-03 Bill Schmidt <wschmidt@linux.ibm.com>
20383
20384 * config/rs6000/emmintrin.h (_mm_cvtpd_epi32): Use __vector rather
20385 than vector.
20386 (_mm_cvtpd_ps): Likewise.
20387 (_mm_cvttpd_epi32): Likewise.
20388 * config/rs6000/mmintrin.h (_mm_unpacklo_pi8): Likewise.
20389 * config/rs6000/xmmintrin.h: For strict-ANSI C++ or C11, undefine
20390 vector, pixel, and bool following altivec.h include.
20391
20392 2018-04-03 Martin Sebor <msebor@redhat.com>
20393
20394 * doc/extend.texi (Common Function Attributes): Clarify.
20395 (const attribute): Likewise.
20396 (pure attribute): Likewise.
20397
20398 2018-04-03 Jakub Jelinek <jakub@redhat.com>
20399
20400 PR target/85169
20401 * config/i386/i386.c (ix86_expand_vector_set): Use
20402 HOST_WIDE_INT_1U << elt instead of 1 << elt. Formatting fix.
20403
20404 2018-04-03 Uros Bizjak <ubizjak@gmail.com>
20405
20406 * config/i386/i386.c (emit_i387_cw_initialization): Always use logic
20407 instructions when changing rounding bits to preserve precision bits
20408 in the x87 control word.
20409
20410 2018-04-03 Martin Liska <mliska@suse.cz>
20411
20412 PR tree-optimization/82491
20413 * rtl.h (strip_offset_and_add): Replace += suboffset with
20414 poly_uint64 () + suboffset.
20415
20416 2018-03-29 Martin Liska <mliska@suse.cz>
20417 Martin Jambor <mjambor@suse.cz>
20418
20419 PR ipa/84947
20420 * ipa-cp.c (propagate_bits_across_jump_function): Bail out if
20421 param_type is not an integral or pointer type.
20422
20423 2018-04-03 Richard Biener <rguenther@suse.de>
20424
20425 * sese.h (recompute_all_dominators): Remove.
20426
20427 2018-04-02 Martin Sebor <msebor@redhat.com>
20428
20429 * doc/invoke.texi (-Wrestrict): Fix typos.
20430
20431 2018-04-02 Jim Wilson <jimw@sifive.com>
20432
20433 * config/riscv/riscv.h (SHIFT_COUNT_TRUNCATED): Set to zero.
20434 * config/riscv/riscv.md (<optab>si3): Use QImode shift count.
20435 (<optab>di3, <optab>si3_extend): Likewise.
20436 (<optab>si3_mask, <optab>si3_mask_1): New.
20437 (<optab>di3_mask, <optab>di3_mask_1): New.
20438 (<optab>si3_extend_mask, <optab>si3_extend_mask_1): New.
20439 (lshrsi3_zero_extend_1): Use VOIDmode shift count.
20440 * config/riscv/sync.md (atomic_test_and_set): Emit QImode shift count.
20441
20442 2018-04-02 Gerald Pfeifer <gerald@pfeifer.com>
20443
20444 * doc/cpp.texi (Variadic Macros): Fix line continuation in an
20445 example.
20446
20447 2018-04-02 Chung-Ju Wu <jasonwucj@gmail.com>
20448
20449 * config/nds32/nds32.c (TARGET_CANONICALIZE_COMPARISON): Define.
20450 (nds32_canonicalize_comparison): New function.
20451
20452 2018-04-01 Chung-Ju Wu <jasonwucj@gmail.com>
20453 Kito Cheng <kito.cheng@gmail.com>
20454 Kuan-Lin Chen <kuanlinchentw@gmail.com>
20455
20456 * config.gcc (nds32): Add nds32-relax-opt.o into extra_objs.
20457 * config/nds32/constants.md (unspec_volatile_element): Add
20458 UNSPEC_VOLATILE_RELAX_GROUP.
20459 * config/nds32/nds32-relax-opt.c: New file.
20460 * config/nds32/nds32-predicates.c
20461 (nds32_symbol_load_store_p): New function.
20462 * config/nds32/nds32-protos.h
20463 (nds32_symbol_load_store_p): Declare function.
20464 (make_pass_nds32_relax_opt): Declare new rtl pass function.
20465 * config/nds32/nds32.c
20466 (nds32_register_pass): New function to register pass.
20467 (nds32_register_passes): New function to register passes.
20468 * config/nds32/nds32.md (relax_group): New pattern.
20469 * config/nds32/nds32.opt (mrelax-hint): New option.
20470 * config/nds32/t-nds32 (nds32-relax-opt.o): New dependency.
20471
20472 2018-04-01 Kito Cheng <kito.cheng@gmail.com>
20473
20474 * config/nds32/t-nds32: Modify files dependency.
20475
20476 2018-04-01 Chung-Ju Wu <jasonwucj@gmail.com>
20477
20478 * config/nds32/nds32.h (FUNCTION_PROFILER): Output newline character.
20479 (PROFILE_HOOK): Define its implementation.
20480
20481 2018-04-01 Chung-Ju Wu <jasonwucj@gmail.com>
20482
20483 * config/nds32/nds32.h (WCHAR_TYPE, WCHAR_TYPE_SIZE): Use unsigned int
20484 type and 32-bit size.
20485
20486 2018-04-01 Jakub Jelinek <jakub@redhat.com>
20487
20488 PR middle-end/85090
20489 * config/i386/sse.md (V): Add V64QI and V32HI for TARGET_AVX512F.
20490 (V_128_256): New mode iterator.
20491 (*avx512dq_vextract<shuffletype>64x2_1 splitter): New define_split.
20492 (*avx512f_vextract<shuffletype>32x4_1 splitter): Likewise.
20493 (xop_pcmov_<mode><avxsizesuffix>): Use V_128_256 mode iterator instead
20494 of V.
20495 * config/i386/i386.c (ix86_expand_vector_set): Improve V32HImode and
20496 V64QImode expansion for !TARGET_AVX512BW && TARGET_AVX512F.
20497
20498 2018-03-31 Segher Boessenkool <segher@kernel.crashing.org>
20499
20500 PR target/83315
20501 * config/rs6000/xmmintrin.h (_mm_set_ps, _mm_max_ps): Handle (quiet)
20502 NaN inputs correctly.
20503
20504 2018-03-30 Peter Bergner <bergner@vnet.ibm.com>
20505
20506 PR target/80546
20507 * config/rs6000/vsx.md (??r): New mode attribute.
20508 (*vsx_mov<mode>_64bit): Use it.
20509 (*vsx_mov<mode>_32bit): Likewise.
20510
20511 2018-03-30 Martin Sebor <msebor@redhat.com>
20512
20513 PR tree-optimization/84818
20514 * builtins.c (check_access): Use warning_n.
20515
20516 2018-03-30 Aaron Sawdey <acsawdey@linux.vnet.ibm.com>
20517
20518 PR target/83822
20519 * config/rs6000/rs6000-string.c (expand_compare_loop): Fix redundant
20520 condition.
20521 * config/rs6000/rs6000-c.c (rs6000_cpu_cpp_builtins): Fix redundant
20522 condition.
20523
20524 2018-03-30 Julia Koval <julia.koval@intel.com>
20525
20526 PR target/84413
20527 * x86-tune.def (movx, partial_reg_dependency): Enable for
20528 m_SKYLAKE_AVX512.
20529
20530 2018-03-29 Vladimir Makarov <vmakarov@redhat.com>
20531
20532 PR inline-asm/84985
20533 * lra-constraints.c (process_alt_operands): Move setting
20534 this_alternative_matches below.
20535
20536 2018-03-29 Martin Liska <mliska@suse.cz>
20537
20538 PR lto/84995.
20539 * doc/invoke.texi: Document how LTO works with debug info.
20540 Describe auto-load support of binutils. Mention 'x86-64'
20541 as valid option value of -march option.
20542
20543 2018-03-29 Jakub Jelinek <jakub@redhat.com>
20544
20545 * config/i386/sse.md (<avx512>_blendm<mode>): Use <sseintprefix>.
20546
20547 PR c/85094
20548 * fold-const.c (operand_equal_p): Handle DEBUG_BEGIN_STMT.
20549 For STATEMENT_LIST, pass down OEP_LEXICOGRAPHIC and maybe
20550 OEP_NO_HASH_CHECK for recursive call, to avoid exponential
20551 checking.
20552
20553 2018-03-28 Peter Bergner <bergner@vnet.ibm.com>
20554
20555 PR target/84912
20556 * config/rs6000/rs6000.h (RS6000_BTM_POWERPC64): New define.
20557 (RS6000_BTM_COMMON): Add RS6000_BTM_POWERPC64.
20558 * config/rs6000/rs6000.c (rs6000_builtin_mask_calculate): Add support
20559 for RS6000_BTM_POWERPC64.
20560 (rs6000_invalid_builtin): Add handling for RS6000_BTM_POWERPC64
20561 (rs6000_builtin_mask_names): Add RS6000_BTM_POWERPC64.
20562 * config/rs6000/rs6000-builtin.def (BU_P7_POWERPC64_MISC_2): New macro
20563 definition.
20564 (DIVDE): Use it.
20565 (DIVDEU): Likewise.
20566
20567 2018-03-28 Carl Love <cel@us.ibm.com>
20568
20569 Revert
20570 2017-09-27 Carl Love <cel@us.ibm.com>
20571
20572 * config/rs6000/rs6000-builtin.def (BU_FP_1MISC_1): Add define macro.
20573 (FCTID, FCTIW): Add BU_FP_MISC_1 macro expansion for builtins.
20574 * config/rs6000/rs6000.md (lrintsfsi2): Add define_insn for the
20575 fctiw instruction.
20576
20577 2018-03-28 Bill Schmidt <wschmidt@linux.vnet.ibm.com>
20578
20579 * config/rs6000/xmmintrin.h (_mm_max_pi16): Use __vector __bool
20580 instead of __vector bool.
20581 (_mm_max_pu8): Likewise.
20582 (_mm_min_pi16): Likewise.
20583
20584 2018-03-28 Peter Bergner <bergner@vnet.ibm.com>
20585
20586 PR target/84912
20587 * config/rs6000/rs6000-builtin.def (DIVWEO): Delete macro expansion.
20588 (DIVWEUO): Likewise.
20589 (DIVDEO): Likewise.
20590 (DIVDEUO): Likewise.
20591 * config/rs6000/rs6000.c (builtin_function_type): Remove support for
20592 DIVWEUO and DIVDEUO.
20593 * config/rs6000/rs6000.md (UNSPEC_DIVEO, UNSPEC_DIVEUO): Delete unspecs.
20594 (UNSPEC_DIV_EXTEND): Remove deleted unspecs.
20595 (div_extend): Likewise.
20596 * doc/extend.texi (__builtin_divweo): Remove documentation for deleted
20597 builtin function.
20598 (__builtin_divweuo): Likewise.
20599 (__builtin_divdeo): Likewise.
20600 (__builtin_divdeuo): Likewise.
20601
20602 2018-03-28 Jakub Jelinek <jakub@redhat.com>
20603
20604 PR target/85095
20605 * config/i386/i386.md (*add<mode>3_carry_0, *addsi3_carry_zext_0,
20606 *sub<mode>3_carry_0, *subsi3_carry_zext_0): New patterns.
20607
20608 PR tree-optimization/82004
20609 * gimple-match-head.c (optimize_pow_to_exp): New function.
20610 * match.pd (pow(C,x) -> exp(log(C)*x)): Wrap with #if GIMPLE.
20611 Don't fold to exp if optimize_pow_to_exp is false.
20612
20613 2018-03-28 Martin Liska <mliska@suse.cz>
20614
20615 PR other/84819
20616 * calls.c (initialize_argument_information): Fix trailing space.
20617 * common.opt: Fix typo and provide better explanation for
20618 -fsanitize-coverage option.
20619 * config/i386/i386.opt: Fix typo.
20620
20621 2018-03-28 Jakub Jelinek <jakub@redhat.com>
20622 Martin Liska <mliska@suse.cz>
20623
20624 PR sanitizer/85081
20625 * gimplify.c (asan_poison_variable): Don't do the check for
20626 gimplify_omp_ctxp here.
20627 (gimplify_decl_expr): Do it here.
20628 (gimplify_target_expr): Likewise.
20629
20630 2018-03-28 Martin Liska <mliska@suse.cz>
20631
20632 PR target/84988
20633 * config/i386/i386.c (ix86_function_arg_advance): Do not call
20634 chkp_type_bounds_count if MPX is not enabled.
20635
20636 2018-03-27 Chung-Ju Wu <jasonwucj@gmail.com>
20637
20638 * config/nds32/nds32.h (BRANCH_COST): Adjust cost.
20639
20640 2018-03-27 Michael Meissner <meissner@linux.vnet.ibm.com>
20641
20642 PR target/84914
20643 * config/rs6000/rs6000.c (create_complex_muldiv): New helper
20644 function to create the function decl for complex long double
20645 multiply and divide for -mabi=ieeelongdouble.
20646 (init_float128_ieee): Call it.
20647
20648 2018-03-27 H.J. Lu <hongjiu.lu@intel.com>
20649
20650 PR target/85044
20651 * config/i386/i386.c (ix86_trampoline_init): Insert ENDBR for
20652 -fcf-protection=branch -mibt.
20653 * config/i386/i386.h (TRAMPOLINE_SIZE): Increased by 4 bytes.
20654
20655 2018-03-27 Ramana Radhakrishnan <ramana.radhakrishnan@arm.com>
20656
20657 PR target/81863
20658 * config/arm/arm.c (arm_valid_symbolic_address): Handle
20659 arm_word_relocations.
20660
20661 2018-03-27 Cesar Philippidis <cesar@codesourcery.com>
20662
20663 PR target/85056
20664 * config/nvptx/nvptx.c (nvptx_assemble_decl_begin): Add '[]' to
20665 extern array declarations.
20666
20667 2018-03-27 Richard Biener <rguenther@suse.de>
20668
20669 PR middle-end/84067
20670 * match.pd ((A * C) +- (B * C) -> (A+-B) * C): Guard with
20671 explicit single_use checks.
20672
20673 2018-03-27 Richard Biener <rguenther@suse.de>
20674
20675 PR tree-optimization/85082
20676 * tree-ssa-sccvn.c (vn_reference_lookup_or_insert_for_pieces):
20677 Valueize the VUSE.
20678
20679 2018-03-27 Ramana Radhakrishnan <ramana.radhakrishnan@arm.com>
20680
20681 * config.gcc (aarch64*-*-linux*): New TARGET_DEFAULT_ASYNC_UNWIND_TABLES
20682 * common/config/aarch64/aarch64-common.c (aarch64_optimization_table[]):
20683 Turn on fasynchronous-unwind-tables and funwind-tables.
20684
20685 2018-03-26 Uros Bizjak <ubizjak@gmail.com>
20686
20687 PR target/85073
20688 * config/i386/i386.md (*bmi_blsr_<mode>_cmp): New insn pattern.
20689 (*bmi_blsr_<mode>_ccz): Ditto.
20690
20691 2018-03-26 Tom de Vries <tom@codesourcery.com>
20692
20693 PR tree-optimization/85063
20694 * omp-general.c (offloading_function_p): New function. Factor out
20695 of ...
20696 * omp-offload.c (pass_omp_target_link::gate): ... here.
20697 * omp-general.h (offloading_function_p): Declare.
20698 * tree-switch-conversion.c (build_one_array): Mark CSWTCH.x variable
20699 with attribute omp declare target for offloading functions.
20700
20701 2018-03-24 Richard Sandiford <richard.sandiford@linaro.org>
20702
20703 PR tree-optimization/84005
20704 * tree-data-ref.h (get_base_for_alignment): Declare.
20705 * tree-data-ref.c (get_base_for_alignment_1): New function.
20706 (get_base_for_alignment): Likewise.
20707 * tree-vect-data-refs.c (vect_compute_data_ref_alignment): Use
20708 get_base_for_alignment to find a suitable base object, instead
20709 of always using drb->base_address.
20710
20711 2018-03-23 Jakub Jelinek <jakub@redhat.com>
20712
20713 PR inline-asm/85022
20714 * emit-rtl.c (init_emit_regs): Indicate that VOIDmode MEMs don't have
20715 known size by default.
20716
20717 2018-03-23 Vladimir Makarov <vmakarov@redhat.com>
20718
20719 PR inline-asm/85030
20720 * lra-constraints.c (process_alt_operands): Don't match BLKmode
20721 and non BLKmode operands.
20722
20723 2018-03-23 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
20724
20725 PR target/85026
20726 * config/arm/arm.md (unaligned_loadhis): Remove first alternative.
20727 Clean up attributes.
20728
20729 2018-03-23 Richard Biener <rguenther@suse.de>
20730
20731 PR debug/85020
20732 * dwarf2out.c (rtl_for_decl_location): Do not generate RTL early when
20733 we are going to emit early debug for LTO.
20734
20735 2018-03-23 Jakub Jelinek <jakub@redhat.com>
20736
20737 PR inline-asm/85034
20738 * function.c (match_asm_constraints_1): Don't optimize if input
20739 doesn't satisfy general_operand predicate for output's mode.
20740
20741 PR inline-asm/85022
20742 * alias.c (write_dependence_p): Don't require for x_canonicalized
20743 non-VOIDmode if x has VOIDmode.
20744
20745 PR sanitizer/85029
20746 * sanopt.c (maybe_optimize_ubsan_ptr_ifn): If DECL_REGISTER (base),
20747 just don't try to optimize it rather than assert it never happens.
20748
20749 2018-03-22 Kelvin Nilsen <kelvin@gcc.gnu.org>
20750
20751 * config/rs6000/rs6000-builtin.def: Remove various BU_ALTIVEC_X
20752 macro expansions for definition of ST_INTERNAL_<mode> and
20753 LD_INTERNAL_<mode> builtins.
20754 * config/rs6000/rs6000-protos.h (rs6000_address_for_altivec):
20755 Remove prototype.
20756 * config/rs6000/rs6000.c (altivec_expand_ld_builtin): Delete this
20757 function.
20758 (altivec_expand_st_builtin): Likewise.
20759 (altivec_expand_builtin): Remove calls to deleted functions.
20760 (rs6000_address_for_altivec): Delete this function.
20761 * config/rs6000/vector.md: Remove expands for
20762 vector_altivec_load_<mode> and vector_altivec_store_<mode>.
20763
20764 2018-03-22 Sudakshina Das <sudi.das@arm.com>
20765
20766 PR target/84826
20767 * config/arm/arm.h (machine_function): Add static_chain_stack_bytes.
20768 * config/arm/arm.c (arm_compute_static_chain_stack_bytes): Avoid
20769 re-computing once computed.
20770 (arm_expand_prologue): Compute machine->static_chain_stack_bytes.
20771 (arm_init_machine_status): Initialize
20772 machine->static_chain_stack_bytes.
20773
20774 2018-03-22 Kelvin Nilsen <kelvin@gcc.gnu.org>
20775
20776 PR target/84760
20777 * doc/extend.texi: Add four new prototypes for vec_ld.
20778 * config/rs6000/rs6000-builtin.def (LVX_V1TI): Reorder symbol
20779 definitions for more logical presentation.
20780 * config/rs6000/rs6000-c.c: (altivec_overloaded_builtins): Add
20781 entries for V1TI variants of __builtin_altivec_ld builtin.
20782 * config/rs6000/rs6000.c: (altivec_expand_lv_builtin): Add test and
20783 handling of V1TI variant of LVX icode pattern.
20784 (altivec_expand_builtin): Add case for ALTIVEC_BUILTIN_LVX_V1TI.
20785 (rs6000_gimple_fold_builtin): Likewise.
20786 (altivec_init_builtins): Add code to define
20787 __builtin_altivec_lvx_v1ti function.
20788
20789 2018-03-22 Jakub Jelinek <jakub@redhat.com>
20790
20791 PR inline-asm/84941
20792 * function.c (match_asm_constraints_1): Don't do the optimization
20793 if input isn't a REG, SUBREG, MEM or constant.
20794
20795 2018-03-22 Tom de Vries <tom@codesourcery.com>
20796
20797 PR tree-optimization/84956
20798 * tree-ssa-tail-merge.c (find_clusters_1): Skip bbs with
20799 bb_has_abnormal_pred.
20800
20801 2018-03-22 Jakub Jelinek <jakub@redhat.com>
20802
20803 PR sanitizer/85018
20804 * dwarf2asm.c (dw2_output_indirect_constant_1): Set
20805 DECL_INITIAL (decl) to decl at the end.
20806 * varasm.c (use_blocks_for_decl_p): Revert the 2018-03-20 change,
20807 adjust the comment.
20808
20809 2018-03-21 Joseph Myers <joseph@codesourcery.com>
20810
20811 * doc/extend.texi (__builtin_tgmath): Document when complex
20812 integer types are treated as _Complex _Float64.
20813
20814 2018-03-21 Tom de Vries <tom@codesourcery.com>
20815
20816 * doc/extend.texi (__builtin_extend_pointer): Remove pasto.
20817
20818 2018-03-21 Jakub Jelinek <jakub@redhat.com>
20819
20820 PR tree-optimization/84960
20821 * tree-cfg.c (remove_bb): Don't move forced labels into bb->prev_bb
20822 if it is ENTRY block, move them into single succ of ENTRY in that case.
20823
20824 2018-03-21 Richard Sandiford <richard.sandiford@linaro.org>
20825
20826 PR tree-optimization/84811
20827 * poly-int.h (poly_span_traits): Remove the T3 parameter and
20828 promote HOST_WIDE_INT T2 - T1 results to unsigned HOST_WIDE_INT.
20829 (maybe_in_range_p, known_in_range_p, ranges_known_overlap_p):
20830 (known_subrange_p): Update accordingly. Cast each value involved
20831 in the size comparison, rather than casting the result of the
20832 subtraction.
20833
20834 2018-03-21 Jakub Jelinek <jakub@redhat.com>
20835
20836 PR tree-optimization/84982
20837 * gimple-ssa-store-merging.c (invert_op): Handle boolean inversion
20838 by flipping the least significant bit rather than all bits from
20839 bitpos to bitpos + bitsize - 1.
20840
20841 2018-03-21 Nathan Sidwell <nathan@acm.org>
20842
20843 * doc/extend.texi (Deprecated Features): Remove mention of
20844 long-deleted deprecations.
20845
20846 2018-03-21 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
20847
20848 PR jit/84288
20849 * configure.ac (gcc_cv_ld_soname) <*-*-solaris2*>: Set.
20850 * configure: Regenerate.
20851
20852 2018-03-21 Tom de Vries <tom@codesourcery.com>
20853
20854 PR tree-optimization/83126
20855 * tree-parloops.c (num_phis): New function.
20856 (gen_parallel_loop): Detect and handle canonicalize_loop_ivs failure.
20857
20858 2018-03-21 Nathan Sidwell <nathan@acm.org>
20859
20860 * doc/extend.texi (Deprecated Features): Update deprecated flags,
20861 mention anon-struct/union members and trailing attributes.
20862
20863 2018-03-21 Bin Cheng <bin.cheng@arm.com>
20864
20865 PR tree-optimization/84969
20866 * tree-loop-distribution.c (fuse_memset_builtins): Don't reorder
20867 builtin memset partitions if they set different rhs values.
20868
20869 2018-03-21 Jakub Jelinek <jakub@redhat.com>
20870
20871 PR rtl-optimization/84989
20872 * simplify-rtx.c (simplify_unary_operation_1): Don't try to simplify
20873 VEC_DUPLICATE with scalar result mode.
20874
20875 2018-03-21 Martin Liska <mliska@suse.cz>
20876
20877 PR ipa/84963
20878 * ipa-icf.c (sem_item_optimizer::fixup_points_to_sets): Remove
20879 not intended return statement.
20880
20881 2018-03-21 Martin Liska <mliska@suse.cz>
20882
20883 PR target/84988
20884 * tree-chkp.c (CHKP_ARRAY_MAX_CHECK_STEPS): Define a new macro.
20885 (chkp_find_bound_slots_1): Limit number of iterations.
20886
20887 2018-03-20 David H. Gutteridge <dhgutteridge@sympatico.ca>
20888
20889 PR target/84838
20890 * Minor grammar fixes for x86 options.
20891
20892 2018-03-20 Jakub Jelinek <jakub@redhat.com>
20893
20894 PR debug/84875
20895 * dce.c (delete_unmarked_insns): Don't remove frame related noop moves
20896 holding REG_CFA_RESTORE notes, instead turn them into a USE.
20897
20898 2018-03-20 Peter Bergner <bergner@vnet.ibm.com>
20899
20900 PR target/83789
20901 * config/rs6000/altivec.md (altivec_lvx_<mode>_2op): Delete define_insn.
20902 (altivec_lvx_<mode>_1op): Likewise.
20903 (altivec_stvx_<mode>_2op): Likewise.
20904 (altivec_stvx_<mode>_1op): Likewise.
20905 (altivec_lvx_<VM2:mode>): New define_expand.
20906 (altivec_stvx_<VM2:mode>): Likewise.
20907 (altivec_lvx_<VM2:mode>_2op_<P:mptrsize>): New define_insn.
20908 (altivec_lvx_<VM2:mode>_1op_<P:mptrsize>): Likewise.
20909 (altivec_stvx_<VM2:mode>_2op_<P:mptrsize>): Likewise.
20910 (altivec_stvx_<VM2:mode>_1op_<P:mptrsize>): Likewise.
20911 * config/rs6000/rs6000-p8swap.c (rs6000_gen_stvx): Use new expanders.
20912 (rs6000_gen_lvx): Likewise.
20913 * config/rs6000/rs6000.c (altivec_expand_lv_builtin): Likewise.
20914 (altivec_expand_stv_builtin): Likewise.
20915 (altivec_expand_builtin): Likewise.
20916 * config/rs6000/vector.md: Likewise.
20917
20918 2018-03-20 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
20919
20920 PR target/82518
20921 * config/arm/arm.c (arm_array_mode_supported_p): Return false for
20922 BYTES_BIG_ENDIAN.
20923
20924 2018-03-20 Richard Biener <rguenther@suse.de>
20925
20926 PR target/84986
20927 * config/i386/i386.c (ix86_add_stmt_cost): Only cost
20928 sign-conversions as zero, fall back to standard scalar_stmt
20929 cost for the rest.
20930
20931 2018-03-20 Martin Liska <mliska@suse.cz>
20932
20933 PR ipa/84825
20934 * predict.c (rebuild_frequencies): Handle case when we have
20935 PROFILE_ABSENT, but flag_guess_branch_prob is false.
20936
20937 2018-03-20 Jakub Jelinek <jakub@redhat.com>
20938
20939 PR target/84990
20940 * dwarf2asm.c (dw2_output_indirect_constant_1): Temporarily turn off
20941 flag_section_anchors.
20942 * varasm.c (use_blocks_for_decl_p): Remove hack for
20943 dw2_force_const_mem.
20944
20945 PR target/84845
20946 * config/aarch64/aarch64.md (*aarch64_reg_<mode>3_neg_mask2): Rename
20947 to ...
20948 (*aarch64_<optab>_reg_<mode>3_neg_mask2): ... this. If pseudos can't
20949 be created, use lowpart_subreg of operands[0] rather than operands[0]
20950 itself.
20951 (*aarch64_reg_<mode>3_minus_mask): Rename to ...
20952 (*aarch64_ashl_reg_<mode>3_minus_mask): ... this.
20953 (*aarch64_<optab>_reg_di3_mask2): Use const_int_operand predicate
20954 and n constraint instead of aarch64_shift_imm_di and Usd.
20955 (*aarch64_reg_<optab>_minus<mode>3): Rename to ...
20956 (*aarch64_<optab>_reg_minus<mode>3): ... this.
20957
20958 2018-03-20 Sudakshina Das <sudi.das@arm.com>
20959
20960 PR target/82989
20961 * config/arm/neon.md (ashldi3_neon): Update ?s for constraints
20962 to favor GPR over NEON registers.
20963 (<shift>di3_neon): Likewise.
20964
20965 2018-03-20 Tom de Vries <tom@codesourcery.com>
20966
20967 PR target/84952
20968 * config/nvptx/nvptx.c (nvptx_single): Don't neuter bar.sync.
20969 (nvptx_process_pars): Emit bar.sync asap and alap.
20970
20971 2018-03-20 Tom de Vries <tom@codesourcery.com>
20972
20973 PR target/84954
20974 * config/nvptx/nvptx.c (prevent_branch_around_nothing): Also update
20975 seen_label if seen_label is already set.
20976
20977 2018-03-20 Jakub Jelinek <jakub@redhat.com>
20978
20979 PR target/84945
20980 * config/i386/i386.c (fold_builtin_cpu): For features above 31
20981 use __cpu_features2 variable instead of __cpu_model.__cpu_features[0].
20982 Use 1U instead of 1. Formatting fixes.
20983
20984 PR c/84953
20985 * builtins.c (fold_builtin_strpbrk): For strpbrk(x, "") use type
20986 instead of TREE_TYPE (s1) for the return value.
20987
20988 2018-03-19 Jakub Jelinek <jakub@redhat.com>
20989
20990 PR tree-optimization/84946
20991 * gimple-ssa-store-merging.c (mem_valid_for_store_merging): Compute
20992 bitsize + bitsize in poly_uint64 rather than poly_int64.
20993
20994 PR sanitizer/78651
20995 * dwarf2asm.c: Include fold-const.c.
20996 (dw2_output_indirect_constant_1): Set DECL_INITIAL (decl) to ADDR_EXPR
20997 of decl rather than decl itself.
20998
20999 PR rtl-optimization/84643
21000 * memmodel.h (enum memmodel): Add MEMMODEL_MAX enumerator.
21001
21002 2018-03-19 Maxim Ostapenko <m.ostapenko@samsung.com>
21003
21004 PR sanitizer/78651
21005 * dwarf2asm.c (dw2_output_indirect_constant_1): Disable ASan before
21006 calling assemble_variable.
21007
21008 2018-03-19 Sudakshina Das <sudi.das@arm.com>
21009
21010 PR target/81647
21011 * config/aarch64/aarch64-simd.md (vec_cmp<mode><v_int_equiv>): Modify
21012 instructions for UNLT, UNLE, UNGT, UNGE, UNEQ, UNORDERED and ORDERED.
21013
21014 2018-03-19 Jim Wilson <jimw@sifive.com>
21015
21016 PR bootstrap/84856
21017 * config/riscv/riscv.c (riscv_function_arg_boundary): Use
21018 PREFERRED_STACK_BOUNDARY instead of STACK_BOUNDARY.
21019 (riscv_first_stack_step): Likewise.
21020 (riscv_option_override): Use STACK_BOUNDARY instead of
21021 MIN_STACK_BOUNDARY.
21022 * config/riscv/riscv.h (STACK_BOUNDARY): Renamed from
21023 MIN_STACK_BOUNDARY.
21024 (BIGGEST_ALIGNMENT): Set to 128.
21025 (PREFERRED_STACK_BOUNDARY): Renamed from STACK_BOUNDARY.
21026 (RISCV_STACK_ALIGN): Use PREFERRED_STACK_BOUNDARY instead of
21027 STACK_BOUNDARY.
21028
21029 2018-03-19 Richard Biener <rguenther@suse.de>
21030
21031 PR tree-optimization/84933
21032 * tree-vrp.c (set_and_canonicalize_value_range): Treat out-of-bound
21033 values as -INF/INF when canonicalizing an ANTI_RANGE to a RANGE.
21034
21035 2018-03-19 Richard Biener <rguenther@suse.de>
21036
21037 PR tree-optimization/84859
21038 * tree-ssa-phiopt.c (single_trailing_store_in_bb): New function.
21039 (cond_if_else_store_replacement): Perform sinking operation on
21040 single-store BBs regardless of MAX_STORES_TO_SINK setting.
21041 Generalize what a BB with a single eligible store is.
21042
21043 2018-03-19 Richard Biener <rguenther@suse.de>
21044
21045 PR tree-optimization/84929
21046 * tree-data-ref.c (analyze_siv_subscript_cst_affine): Guard
21047 chrec_is_positive against non-chrec arg.
21048
21049 2018-03-19 Tamar Christina <tamar.christina@arm.com>
21050
21051 PR target/84711
21052 * config/arm/arm.c (arm_can_change_mode_class): revert r258554.
21053
21054 2018-03-18 Martin Liska <mliska@suse.cz>
21055
21056 PR rtl-optimization/84635
21057 * regrename.c (build_def_use): Use matches_mode only when
21058 matches >= 0.
21059
21060 2018-03-18 Richard Sandiford <richard.sandiford@linaro.org>
21061
21062 PR tree-optimization/84913
21063 * tree-vect-loop.c (vectorizable_reduction): Don't try to
21064 vectorize chains of COND_EXPRs.
21065
21066 2018-03-18 Chung-Ju Wu <jasonwucj@gmail.com>
21067
21068 * config/nds32/nds32.h (MAX_REGS_PER_ADDRESS): Fix the value.
21069
21070 2018-03-18 Chung-Ju Wu <jasonwucj@gmail.com>
21071
21072 * config/nds32/nds32.h (LOGICAL_OP_NON_SHORT_CIRCUIT): Define.
21073
21074 2018-03-18 Chung-Ju Wu <jasonwucj@gmail.com>
21075
21076 * config/nds32/nds32.h (CLZ_DEFINED_VALUE_AT_ZERO): Define.
21077
21078 2018-03-17 Chung-Ju Wu <jasonwucj@gmail.com>
21079 Kito Cheng <kito.cheng@gmail.com>
21080
21081 * config/nds32/nds32-protos.h (nds32_adjust_reg_alloc_order): Declare.
21082 * config/nds32/nds32.c (nds32_reg_alloc_order_for_speed): New array.
21083 (nds32_adjust_reg_alloc_order): New function.
21084 * config/nds32/nds32.h (ADJUST_REG_ALLOC_ORDER): Define.
21085
21086 2018-03-17 Kito Cheng <kito.cheng@gmail.com>
21087
21088 * config/nds32/nds32.c (nds32_asm_output_mi_thunk,
21089 nds32_print_operand, nds32_print_operand_address): Use
21090 HOST_WIDE_INT_PRINT_DEC instead.
21091
21092 2018-03-17 Chung-Ju Wu <jasonwucj@gmail.com>
21093
21094 * config/nds32/nds32.c (nds32_register_priority): Modify cost.
21095
21096 2018-03-17 Jakub Jelinek <jakub@redhat.com>
21097
21098 PR target/84902
21099 * config/i386/i386.c (initial_ix86_tune_features,
21100 initial_ix86_arch_features): Use unsigned HOST_WIDE_INT rather than
21101 unsigned long long.
21102 (set_ix86_tune_features): Change ix86_tune_mask from unsigned int
21103 to unsigned HOST_WIDE_INT, initialize to HOST_WIDE_INT_1U << ix86_tune
21104 rather than 1u << ix86_tune. Formatting fix.
21105 (ix86_option_override_internal): Change ix86_arch_mask from
21106 unsigned int to unsigned HOST_WIDE_INT, initialize to
21107 HOST_WIDE_INT_1U << ix86_arch rather than 1u << ix86_arch.
21108 (ix86_function_specific_restore): Likewise.
21109
21110 2018-03-16 Jakub Jelinek <jakub@redhat.com>
21111
21112 PR target/84899
21113 * postreload.c (reload_combine_recognize_pattern): Perform
21114 INTVAL addition in unsigned HOST_WIDE_INT type to avoid UB and
21115 truncate_int_for_mode the result for the destination's mode.
21116
21117 PR c/84909
21118 * hsa-gen.c (mem_type_for_type): Fix comment typo.
21119 * tree-vect-loop-manip.c (vect_create_cond_for_niters_checks):
21120 Likewise.
21121 * gimple-ssa-warn-restrict.c (builtin_memref::set_base_and_offset):
21122 Likewise.
21123
21124 2018-03-16 Vladimir Makarov <vmakarov@redhat.com>
21125
21126 PR target/84876
21127 * lra-assigns.c (lra_split_hard_reg_for): Don't use
21128 regno_allocno_class_array and sorted_pseudos.
21129 * lra-constraints.c (spill_hard_reg_in_range): Ignore hard regs in
21130 insns where regno is used.
21131
21132 2018-03-16 Martin Liska <mliska@suse.cz>
21133
21134 PR ipa/84833
21135 * multiple_target.c (create_dispatcher_calls): Redirect
21136 reference in the symbol table.
21137
21138 2018-03-16 Martin Liska <mliska@suse.cz>
21139
21140 PR ipa/84722
21141 * multiple_target.c (create_dispatcher_calls): Redirect also
21142 an alias.
21143
21144 2018-03-16 Jakub Jelinek <jakub@redhat.com>
21145
21146 PR c++/79937
21147 PR c++/82410
21148 * tree.h (TARGET_EXPR_NO_ELIDE): Define.
21149 * gimplify.c (gimplify_modify_expr_rhs): Don't elide TARGET_EXPRs with
21150 TARGET_EXPR_NO_ELIDE flag set unless *expr_p is INIT_EXPR.
21151
21152 2018-03-16 Julia Koval <julia.koval@intel.com>
21153
21154 * doc/invoke.texi (Skylake Server): Add CLWB.
21155 Cannonlake): Remove CLWB.
21156
21157 2018-03-16 Jakub Jelinek <jakub@redhat.com>
21158
21159 PR tree-optimization/84841
21160 * tree-ssa-reassoc.c (INTEGER_CONST_TYPE): Change to 1 << 4 from
21161 1 << 3.
21162 (FLOAT_ONE_CONST_TYPE): Define.
21163 (constant_type): Return FLOAT_ONE_CONST_TYPE for -1.0 and 1.0.
21164 (sort_by_operand_rank): Put entries with higher constant_type last
21165 rather than first to match comments.
21166
21167 2018-03-15 Sandra Loosemore <sandra@codesourcery.com>
21168
21169 * config/nios2/nios2.md (movsi_internal): Fix thinko in
21170 split predicate.
21171
21172 2018-03-15 Jakub Jelinek <jakub@redhat.com>
21173
21174 PR c++/79085
21175 * calls.c (expand_call): For TREE_ADDRESSABLE rettype ignore alignment
21176 check and use address of target always.
21177
21178 2018-03-15 H.J. Lu <hongjiu.lu@intel.com>
21179
21180 PR target/84574
21181 * config/i386/i386.c (indirect_thunk_needed): Update comments.
21182 (indirect_thunk_bnd_needed): Likewise.
21183 (indirect_thunks_used): Likewise.
21184 (indirect_thunks_bnd_used): Likewise.
21185 (indirect_return_needed): New.
21186 (indirect_return_bnd_needed): Likewise.
21187 (output_indirect_thunk_function): Add a bool argument for
21188 function return.
21189 (output_indirect_thunk_function): Don't generate alias for
21190 function return thunk.
21191 (ix86_code_end): Call output_indirect_thunk_function to generate
21192 function return thunks.
21193 (ix86_output_function_return): Set indirect_return_bnd_needed
21194 and indirect_return_needed instead of indirect_thunk_bnd_needed
21195 and indirect_thunk_needed.
21196
21197 2018-03-15 Olga Makhotina <olga.makhotina@intel.com>
21198
21199 * config/i386/sgxintrin.h (_enclv_u32): New intrinsic.
21200 (__enclv_bc, __enclv_cd, __enclv_generic): New definitions.
21201 (ERDINFO, ETRACKC, ELDBC, ELDUC): New leaves.
21202
21203 2018-03-15 David Malcolm <dmalcolm@redhat.com>
21204 Paul Hua <paul.hua.gm@gmail.com>
21205
21206 PR c/84852
21207 * gcc.dg/fixits-pr84852-1.c: Fix filename in dg-regexp.
21208
21209 2018-03-15 Segher Boessenkool <segher@kernel.crashing.org>
21210
21211 * config/rs6000/rs6000.c (abi_v4_pass_in_fpr): Add back the
21212 TARGET_DOUBLE_FLOAT and TARGET_SINGLE_FLOAT conditions on the DFmode
21213 resp. SFmode cases.
21214
21215 2018-03-15 Tamar Christina <tamar.christina@arm.com>
21216
21217 PR target/84711
21218 * config/arm/arm.c (arm_can_change_mode_class): Use GET_MODE_UNIT_SIZE
21219 instead of GET_MODE_SIZE when comparing Units.
21220
21221 2018-03-15 Vladimir Mezentsev <vladimir.mezentsev@oracle.com>
21222
21223 PR target/68256
21224 * varasm.c (hash_section): Return an unchangeble hash value
21225 * config/aarch64/aarch64.c (aarch64_use_blocks_for_constant_p):
21226 Return !aarch64_can_use_per_function_literal_pools_p ().
21227
21228 2018-03-15 Jakub Jelinek <jakub@redhat.com>
21229
21230 PR target/84860
21231 * optabs.c (emit_conditional_move): Pass address of cmode's copy
21232 rather than address of cmode as last argument to prepare_cmp_insn.
21233
21234 2018-03-15 Julia Koval <julia.koval@intel.com>
21235
21236 * config/i386/i386.c (F_AVX512VBMI2, F_GFNI, F_VPCLMULQDQ,
21237 F_AVX512VNNI, F_AVX512BITALG): New.
21238
21239 2018-03-14 John David Anglin <danglin@gcc.gnu.org>
21240
21241 PR target/83451
21242 * config/pa/pa.c (pa_emit_move_sequence): Always emit secondary reload
21243 insn for floating-point loads and stores.
21244
21245 2018-03-14 Carl Love <cel@us.ibm.com>
21246
21247 * config/rs6000/rs6000-c.c: Add macro definitions for
21248 ALTIVEC_BUILTIN_VEC_PERMXOR.
21249 * config/rs6000/rs6000.h: Add #define for vec_permxor builtin.
21250 * config/rs6000/rs6000-builtin.def: Add macro expansions for VPERMXOR.
21251 * config/rs6000/altivec.md (altivec_vpermxor): New define expand.
21252 * config/rs6000/rs6000-p8swap.c (rtx_is_swappable_p): Add case
21253 UNSPEC_VPERMXOR.
21254 * config/doc/extend.texi: Add prototypes for vec_permxor.
21255
21256 2018-03-14 David Malcolm <dmalcolm@redhat.com>
21257
21258 PR c/84852
21259 * diagnostic-show-locus.c (class layout_point): Convert m_line
21260 from int to linenum_type.
21261 (line_span::comparator): Use linenum "compare" function when
21262 comparing line numbers.
21263 (test_line_span): New function.
21264 (layout_range::contains_point): Convert param "row" from int to
21265 linenum_type.
21266 (layout_range::intersects_line_p): Likewise.
21267 (layout::will_show_line_p): Likewise.
21268 (layout::print_source_line): Likewise.
21269 (layout::should_print_annotation_line_p): Likewise.
21270 (layout::print_annotation_line): Likewise.
21271 (layout::print_leading_fixits): Likewise.
21272 (layout::annotation_line_showed_range_p): Likewise.
21273 (struct line_corrections): Likewise for field m_row.
21274 (line_corrections::line_corrections): Likewise for param "row".
21275 (layout::print_trailing_fixits): Likewise.
21276 (layout::get_state_at_point): Likewise.
21277 (layout::get_x_bound_for_row): Likewise.
21278 (layout::print_line): Likewise.
21279 (diagnostic_show_locus): Likewise for locals "last_line" and "row".
21280 (selftest::diagnostic_show_locus_c_tests): Call test_line_span.
21281 * input.c (selftest::test_linenum_comparisons): New function.
21282 (selftest::input_c_tests): Call it.
21283 * selftest.c (selftest::test_assertions): Test ASSERT_GT,
21284 ASSERT_GT_AT, ASSERT_LT, and ASSERT_LT_AT.
21285 * selftest.h (ASSERT_GT): New macro.
21286 (ASSERT_GT_AT): New macro.
21287 (ASSERT_LT): New macro.
21288 (ASSERT_LT_AT): New macro.
21289
21290 2018-03-14 Segher Boessenkool <segher@kernel.crashing.org>
21291
21292 PR rtl-optimization/84780
21293 * combine.c (distribute_links): Don't make a link based on pc_rtx.
21294
21295 2018-03-14 Martin Liska <mliska@suse.cz>
21296
21297 * tree.c (record_node_allocation_statistics): Use
21298 get_stats_node_kind.
21299 (get_stats_node_kind): New function extracted from
21300 record_node_allocation_statistics.
21301 (free_node): Use get_stats_node_kind.
21302
21303 2018-03-14 Richard Biener <rguenther@suse.de>
21304
21305 * tree-ssa-pre.c (compute_antic_aux): Remove code that asserts
21306 that the value-set of ANTIC_IN doesn't grow.
21307
21308 Revert
21309 * tree-ssa-pre.c (struct bb_bitmap_sets): Add visited_with_visited_succs
21310 member.
21311 (BB_VISITED_WITH_VISITED_SUCCS): New define.
21312 (compute_antic): Initialize BB_VISITED_WITH_VISITED_SUCCS.
21313
21314 2018-03-14 Julia Koval <julia.koval@intel.com>
21315
21316 * config.gcc (icelake-client, icelake-server): New.
21317 (icelake): Remove.
21318 * config/i386/i386.c (initial_ix86_tune_features): Extend to 64 bit.
21319 (initial_ix86_arch_features): Ditto.
21320 (PTA_SKYLAKE): Add SGX.
21321 (PTA_ICELAKE): Remove.
21322 (PTA_ICELAKE_CLIENT): New.
21323 (PTA_ICELAKE_SERVER): New.
21324 (ix86_option_override_internal): Split up icelake on icelake client and
21325 icelake server.
21326 (get_builtin_code_for_version): Ditto.
21327 (fold_builtin_cpu): Ditto.
21328 * config/i386/driver-i386.c (config/i386/driver-i386.c): Ditto.
21329 * config/i386/i386-c.c (ix86_target_macros_internal): Ditto
21330 * config/i386/i386.h (processor_type): Ditto.
21331 * doc/invoke.texi: Ditto.
21332
21333 2018-03-14 Jakub Jelinek <jakub@redhat.com>
21334
21335 PR sanitizer/83392
21336 * sanopt.c (maybe_optimize_ubsan_ptr_ifn): Handle also
21337 INTEGER_CST offset, add it together with bitpos / 8 and
21338 sign extend based on POINTER_SIZE.
21339
21340 PR target/84844
21341 Revert
21342 2017-04-20 Uros Bizjak <ubizjak@gmail.com>
21343
21344 PR target/78090
21345 * config/i386/constraints.md (Yc): New register constraint.
21346 * config/i386/i386.md (*float<SWI48:mode><MODEF:mode>2_mixed):
21347 Use Yc constraint for alternative 2 of operand 0. Remove
21348 preferred_for_speed attribute.
21349
21350 2018-03-14 Richard Biener <rguenther@suse.de>
21351
21352 PR tree-optimization/84830
21353 * tree-ssa-pre.c (compute_antic_aux): Intersect the new ANTIC_IN
21354 with the old one to avoid oscillations.
21355
21356 2018-03-13 Vladimir Makarov <vmakarov@redhat.com>
21357
21358 PR target/83712
21359 * lra-assigns.c (find_all_spills_for): Ignore uninteresting
21360 pseudos.
21361 (assign_by_spills): Return a flag of reload assignment failure.
21362 Do not process the reload assignment failures. Do not spill other
21363 reload pseudos if they has the same reg class. Update n if
21364 necessary.
21365 (lra_assign): Add a return arg. Set up from the result of
21366 assign_by_spills call.
21367 (find_reload_regno_insns, lra_split_hard_reg_for): New functions.
21368 * lra-constraints.c (split_reg): Add a new arg. Use it instead of
21369 usage_insns if it is not NULL.
21370 (spill_hard_reg_in_range): New function.
21371 (split_if_necessary, inherit_in_ebb): Pass a new arg to split_reg.
21372 * lra-int.h (spill_hard_reg_in_range, lra_split_hard_reg_for): New
21373 function prototypes.
21374 (lra_assign): Change prototype.
21375 * lra.c (lra): Add code to deal with fails by splitting hard reg
21376 live ranges.
21377
21378 2018-03-01 Palmer Dabbelt <palmer@sifive.com>
21379
21380 * config/riscv/riscv.opt (mrelax): New option.
21381 * config/riscv/riscv.c (riscv_file_start): Emit ".option
21382 "norelax" when riscv_mrelax is disabled.
21383 * doc/invoke.texi (RISC-V): Document "-mrelax" and "-mno-relax".
21384
21385 2018-03-13 Aaron Sawdey <acsawdey@linux.vnet.ibm.com>
21386
21387 PR target/84743
21388 * config/rs6000/rs6000.c (rs6000_reassociation_width): Disable parallel
21389 reassociation for int modes.
21390
21391 2018-03-13 Richard Sandiford <richard.sandiford@linaro.org>
21392
21393 * tree-vect-loop-manip.c (vect_maybe_permute_loop_masks):
21394 Reverse the choice between VEC_UNPACK_LO_EXPR and VEC_UNPACK_HI_EXPR
21395 for big-endian.
21396 * config/aarch64/iterators.md (hi_lanes_optab): New int attribute.
21397 * config/aarch64/aarch64-sve.md
21398 (*aarch64_sve_<perm_insn><perm_hilo><mode>): Rename to...
21399 (aarch64_sve_<perm_insn><perm_hilo><mode>): ...this.
21400 (*extend<mode><Vwide>2): Rename to...
21401 (aarch64_sve_extend<mode><Vwide>2): ...this.
21402 (vec_unpack<su>_<perm_hilo>_<mode>): Turn into a define_expand,
21403 renaming the old pattern to...
21404 (aarch64_sve_punpk<perm_hilo>_<mode>): ...this. Only define
21405 unsigned packs.
21406 (vec_unpack<su>_<perm_hilo>_<SVE_BHSI:mode>): Turn into a
21407 define_expand, renaming the old pattern to...
21408 (aarch64_sve_<su>unpk<perm_hilo>_<SVE_BHSI:mode>): ...this.
21409 (*vec_unpacku_<perm_hilo>_<mode>_no_convert): Delete.
21410 (vec_unpacks_<perm_hilo>_<mode>): Take BYTES_BIG_ENDIAN into
21411 account when deciding which SVE instruction the optab should use.
21412 (vec_unpack<su_optab>_float_<perm_hilo>_vnx4si): Likewise.
21413
21414 2018-03-13 Richard Sandiford <richard.sandiford@linaro.org>
21415
21416 * config/aarch64/aarch64.md (V4_REGNUM, V8_REGNUM, V12_REGNUM)
21417 (V20_REGNUM, V24_REGNUM, V28_REGNUM, P1_REGNUM, P2_REGNUM, P3_REGNUM)
21418 (P4_REGNUM, P5_REGNUM, P6_REGNUM, P8_REGNUM, P9_REGNUM, P10_REGNUM)
21419 (P11_REGNUM, P12_REGNUM, P13_REGNUM, P14_REGNUM): New define_constants.
21420 (tlsdesc_small_<mode>): Turn a define_expand and use
21421 tlsdesc_small_sve_<mode> for SVE. Rename original define_insn to...
21422 (tlsdesc_small_advsimd_<mode>): ...this.
21423 (tlsdesc_small_sve_<mode>): New pattern.
21424
21425 2018-03-13 Richard Sandiford <richard.sandiford@linaro.org>
21426
21427 * config/aarch64/iterators.md (UNSPEC_SMUL_HIGHPART)
21428 (UNSPEC_UMUL_HIGHPART): New constants.
21429 (MUL_HIGHPART): New int iteraor.
21430 (su): Handle UNSPEC_SMUL_HIGHPART and UNSPEC_UMUL_HIGHPART.
21431 * config/aarch64/aarch64-sve.md (<su>mul<mode>3_highpart): New
21432 define_expand.
21433 (*<su>mul<mode>3_highpart): New define_insn.
21434
21435 2018-03-13 Eric Botcazou <ebotcazou@adacore.com>
21436
21437 PR lto/84805
21438 * ipa-devirt.c (odr_subtypes_equivalent_p): Do not get the ODR type of
21439 incomplete types.
21440
21441 2018-03-13 Martin Liska <mliska@suse.cz>
21442
21443 PR ipa/84658.
21444 * (sem_item_optimizer::sem_item_optimizer): Initialize new
21445 vector.
21446 (sem_item_optimizer::~sem_item_optimizer): Release it.
21447 (sem_item_optimizer::merge_classes): Register variable aliases.
21448 (sem_item_optimizer::fixup_pt_set): New function.
21449 (sem_item_optimizer::fixup_points_to_sets): Likewise.
21450 * ipa-icf.h: Declare new variables and functions.
21451
21452 2018-03-13 Jakub Jelinek <jakub@redhat.com>
21453
21454 PR middle-end/84834
21455 * match.pd ((A & C) != 0 ? D : 0): Use INTEGER_CST@2 instead of
21456 integer_pow2p@2 and test integer_pow2p in condition.
21457 (A < 0 ? C : 0): Similarly for @1.
21458
21459 PR middle-end/84831
21460 * stmt.c (parse_output_constraint): If the CONSTRAINT_LEN (*p, p)
21461 characters starting at p contain '\0' character, don't look beyond
21462 that.
21463
21464 PR target/84827
21465 * config/i386/i386.md (round<mode>2): For 387 fancy math, disable
21466 pattern if -ftrapping-math -fno-fp-int-builtin-inexact.
21467
21468 PR target/84828
21469 * reg-stack.c (change_stack): Change update_end var from int to
21470 rtx_insn *, if non-NULL don't update just BB_END (current_block), but
21471 also call set_block_for_insn on the newly added insns and rescan.
21472
21473 PR target/84786
21474 * config/i386/sse.md (sse2_loadhpd): Use Yv constraint rather than v
21475 on the last operand.
21476
21477 PR c++/84704
21478 * tree.c (stabilize_reference_1): Return save_expr (e) for
21479 STATEMENT_LIST even if it doesn't have side-effects.
21480
21481 2018-03-12 Jonathan Wakely <jwakely@redhat.com>
21482
21483 * doc/invoke.texi (-mclflushopt): Fix spelling of option.
21484
21485 2018-03-12 Renlin Li <renlin.li@arm.com>
21486
21487 * config/aarch64/aarch64.md (movhf_aarch64): Fix mode argument to
21488 aarch64_output_scalar_simd_mov_immediate.
21489
21490 2018-03-12 Martin Sebor <msebor@redhat.com>
21491
21492 PR tree-optimization/83456
21493 * gimple-fold.c (gimple_fold_builtin_memory_op): Avoid warning
21494 for perfectly overlapping calls to memcpy.
21495 (gimple_fold_builtin_memory_chk): Same.
21496 (gimple_fold_builtin_strcpy): Handle no-warning.
21497 (gimple_fold_builtin_stxcpy_chk): Same.
21498 * tree-ssa-strlen.c (maybe_diag_stxncpy_trunc): Handle no-warning.
21499
21500 2018-03-12 Segher Boessenkool <segher@kernel.crashing.org>
21501
21502 * config/rs6000/rs6000.c (abi_v4_pass_in_fpr): Add bool "named"
21503 parameter. Use it for SFmode.
21504 (rs6000_function_arg_advance_1): Adjust.
21505 (rs6000_function_arg): Adjust.
21506 (rs6000_gimplify_va_arg): Pass false for that new parameter.
21507
21508 2018-03-12 Segher Boessenkool <segher@kernel.crashing.org>
21509
21510 PR rtl-optimization/84169
21511 PR rtl-optimization/84780
21512 * combine.c (can_combine_p): Check for a 2-insn combination whether
21513 the destination register is used between the two insns, too.
21514
21515 2018-03-12 Richard Biener <rguenther@suse.de>
21516
21517 PR tree-optimization/84803
21518 * tree-if-conv.c (ifcvt_memrefs_wont_trap): Don't do anything
21519 for refs DR analysis didn't process.
21520
21521 2018-03-12 Richard Biener <rguenther@suse.de>
21522
21523 PR tree-optimization/84777
21524 * tree-ssa-loop-ch.c (should_duplicate_loop_header_p): For
21525 force-vectorize loops ignore whether we are optimizing for size.
21526
21527 2018-03-12 Chung-Ju Wu <jasonwucj@gmail.com>
21528
21529 * config/nds32/nds32.c (nds32_md_asm_adjust): New function.
21530 (TARGET_MD_ASM_ADJUST): Define.
21531
21532 2018-03-12 Monk Chiang <sh.chiang04@gmail.com>
21533 Kito Cheng <kito.cheng@gmail.com>
21534 Chung-Ju Wu <jasonwucj@gmail.com>
21535
21536 * config/nds32/nds32.c (nds32_compute_stack_frame,
21537 nds32_emit_stack_push_multiple, nds32_emit_stack_pop_multiple,
21538 nds32_emit_stack_v3push, nds32_emit_stack_v3pop,
21539 nds32_emit_adjust_frame, nds32_expand_prologue, nds32_expand_epilogue,
21540 nds32_expand_prologue_v3push, nds32_expand_epilogue_v3pop): Refine.
21541 * config/nds32/nds32.h (NDS32_FIRST_CALLEE_SAVE_GPR_REGNUM,
21542 NDS32_LAST_CALLEE_SAVE_GPR_REGNUM, NDS32_V3PUSH_AVAILABLE_P): New.
21543 * config/nds32/nds32.md (prologue, epilogue): Use macro
21544 NDS32_V3PUSH_AVAILABLE_P to do checking.
21545
21546 2018-03-11 Jakub Jelinek <jakub@redhat.com>
21547
21548 PR debug/58150
21549 * dwarf2out.c (gen_enumeration_type_die): Don't guard adding
21550 DW_AT_declaration for ENUM_IS_OPAQUE on -gdwarf-4 or -gno-strict-dwarf,
21551 but on TYPE_SIZE. Don't do anything for ENUM_IS_OPAQUE if not creating
21552 a new die. Don't set TREE_ASM_WRITTEN if ENUM_IS_OPAQUE. Guard
21553 addition of most attributes on !orig_type_die or the attribute not
21554 being present already. Assert TYPE_VALUES is NULL for ENUM_IS_OPAQUE.
21555
21556 2018-03-11 Kito Cheng <kito.cheng@gmail.com>
21557 Chung-Ju Wu <jasonwucj@gmail.com>
21558
21559 * config/nds32/nds32.c (nds32_cpu_cpp_builtins): Modify to define
21560 __NDS32_VH__ macro.
21561 * config/nds32/nds32.opt (mvh): New option.
21562
21563 2018-03-11 Kito Cheng <kito.cheng@gmail.com>
21564 Chung-Ju Wu <jasonwucj@gmail.com>
21565
21566 * config/nds32/nds32-protos.h (nds32_cpu_cpp_builtins): Declare
21567 function.
21568 * config/nds32/nds32.c (nds32_cpu_cpp_builtins): New function.
21569 * config/nds32/nds32.h (TARGET_CPU_CPP_BUILTINS): Modify its
21570 definition.
21571
21572 2018-03-11 Kito Cheng <kito.cheng@gmail.com>
21573 Chung-Ju Wu <jasonwucj@gmail.com>
21574
21575 * config/nds32/nds32-memory-manipulation.c (nds32_expand_strlen): New
21576 function.
21577 * config/nds32/nds32-multiple.md (strlensi): New pattern.
21578 * config/nds32/nds32-protos.h (nds32_expand_strlen): Declare function.
21579
21580 2018-03-11 Monk Chiang <sh.chiang04@gmail.com>
21581 Kito Cheng <kito.cheng@gmail.com>
21582 Chung-Ju Wu <jasonwucj@gmail.com>
21583
21584 * config/nds32/constants.md (unspec_element): Add UNSPEC_FFB,
21585 UNSPEC_FFMISM and UNSPEC_FLMISM.
21586 * config/nds32/nds32-intrinsic.c (bdesc_2arg): Add builtin description
21587 for ffb, ffmism and flmism.
21588 * config/nds32/nds32-intrinsic.md (unspec_ffb): Define new pattern.
21589 (unspec_ffmism): Ditto.
21590 (unspec_flmism): Ditto.
21591 (nds32_expand_builtin_impl): Check if string extension is available.
21592 * config/nds32/nds32.h (nds32_builtins): Add NDS32_BUILTIN_FFB,
21593 NDS32_BUILTIN_FFMISM and NDS32_BUILTIN_FLMISM.
21594
21595 2018-03-10 Vladimir Makarov <vmakarov@redhat.com>
21596
21597 Reverting patch:
21598 2018-03-09 Vladimir Makarov <vmakarov@redhat.com>
21599
21600 PR target/83712
21601 * lra-assigns.c (assign_by_spills): Return a flag of reload
21602 assignment failure. Do not process the reload assignment
21603 failures. Do not spill other reload pseudos if they has the same
21604 reg class.
21605 (lra_assign): Add a return arg. Set up from the result of
21606 assign_by_spills call.
21607 (find_reload_regno_insns, lra_split_hard_reg_for): New functions.
21608 * lra-constraints.c (split_reg): Add a new arg. Use it instead of
21609 usage_insns if it is not NULL.
21610 (spill_hard_reg_in_range): New function.
21611 (split_if_necessary, inherit_in_ebb): Pass a new arg to split_reg.
21612 * lra-int.h (spill_hard_reg_in_range, lra_split_hard_reg_for): New
21613 function prototypes.
21614 (lra_assign): Change prototype.
21615 * lra.c (lra): Add code to deal with fails by splitting hard reg
21616 live ranges.
21617
21618 2018-03-10 H.J. Lu <hongjiu.lu@intel.com>
21619
21620 PR target/84807
21621 * config/i386/i386.opt: Replace Enforcment with Enforcement.
21622
21623 2018-03-10 Alexandre Oliva <aoliva@redhat.com>
21624
21625 PR debug/84620
21626 * dwarf2out.h (dw_val_class): Add dw_val_class_symview.
21627 (dw_val_node): Add val_symbolic_view.
21628 * dwarf2out.c (dw_line_info_table): Add symviews_since_reset.
21629 (symview_upper_bound): New.
21630 (new_line_info_table): Initialize symviews_since_reset.
21631 (dwarf2out_source_line): Count symviews_since_reset and set
21632 symview_upper_bound.
21633 (dw_val_equal_p): Handle symview.
21634 (add_AT_symview): New.
21635 (print_dw_val): Handle symview.
21636 (attr_checksum, attr_checksum_ordered): Likewise.
21637 (same_dw_val_p, size_of_die): Likewise.
21638 (value_format, output_die): Likewise.
21639 (add_high_low_attributes): Use add_AT_symview for entry_view.
21640 (dwarf2out_finish): Reset symview_upper_bound, clear
21641 zero_view_p.
21642
21643 2018-03-09 Peter Bergner <bergner@vnet.ibm.com>
21644
21645 PR target/83969
21646 * config/rs6000/rs6000.c (rs6000_offsettable_memref_p): New prototype.
21647 Add strict argument and use it.
21648 (rs6000_split_multireg_move): Update for new strict argument.
21649 (mem_operand_gpr): Disallow all non-offsettable addresses.
21650 * config/rs6000/rs6000.md (*movdi_internal64): Use YZ constraint.
21651
21652 2018-03-09 Jakub Jelinek <jakub@redhat.com>
21653
21654 PR target/84772
21655 * config/rs6000/rs6000.c (rs6000_gimplify_va_arg): Mark va_arg_tmp
21656 temporary TREE_ADDRESSABLE before gimplification of BUILT_IN_MEMCPY.
21657 * config/powerpcspe/powerpcspe.c (rs6000_gimplify_va_arg): Likewise.
21658
21659 PR c++/84767
21660 * tree-inline.c (copy_tree_body_r): For INDIRECT_REF of a remapped
21661 decl, use remap_type if we want to use the type.
21662
21663 2018-03-09 Martin Sebor <msebor@redhat.com>
21664
21665 PR tree-optimization/84526
21666 * gimple-ssa-warn-restrict.c (builtin_memref::set_base_and_offset):
21667 Remove dead code.
21668 (builtin_access::generic_overlap): Be prepared to handle non-array
21669 base objects.
21670
21671 2018-03-09 Alexandre Oliva <aoliva@redhat.com>
21672
21673 PR rtl-optimization/84682
21674 * lra-constraints.c (process_address_1): Check is_address flag
21675 for address constraints.
21676 (process_alt_operands): Likewise.
21677 * lra.c (lra_set_insn_recog_data): Pass asm operand locs to
21678 preprocess_constraints.
21679 * recog.h (preprocess_constraints): Add oploc parameter.
21680 Adjust callers.
21681 * recog.c (preprocess_constraints): Test address_operand for
21682 CT_ADDRESS constraints.
21683
21684 2018-03-09 Vladimir Makarov <vmakarov@redhat.com>
21685
21686 PR target/83712
21687 * lra-assigns.c (assign_by_spills): Return a flag of reload
21688 assignment failure. Do not process the reload assignment
21689 failures. Do not spill other reload pseudos if they has the same
21690 reg class.
21691 (lra_assign): Add a return arg. Set up from the result of
21692 assign_by_spills call.
21693 (find_reload_regno_insns, lra_split_hard_reg_for): New functions.
21694 * lra-constraints.c (split_reg): Add a new arg. Use it instead of
21695 usage_insns if it is not NULL.
21696 (spill_hard_reg_in_range): New function.
21697 (split_if_necessary, inherit_in_ebb): Pass a new arg to split_reg.
21698 * lra-int.h (spill_hard_reg_in_range, lra_split_hard_reg_for): New
21699 function prototypes.
21700 (lra_assign): Change prototype.
21701 * lra.c (lra): Add code to deal with fails by splitting hard reg
21702 live ranges.
21703
21704 2018-03-09 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
21705
21706 PR target/83193
21707 * common/config/arm/arm-common.c (arm_parse_arch_option_name):
21708 Accept complain bool parameter. Only emit errors if it is true.
21709 (arm_parse_cpu_option_name): Likewise.
21710 (arm_target_thumb_only): Adjust callers of the above.
21711 * config/arm/arm-protos.h (arm_parse_cpu_option_name): Adjust
21712 prototype to take a default true bool parameter.
21713 (arm_parse_arch_option_name): Likewise.
21714
21715 2018-03-09 David Malcolm <dmalcolm@redhat.com>
21716 Francois-Xavier Coudert <fxcoudert@gcc.gnu.org>
21717
21718 PR jit/64089
21719 PR jit/84288
21720 * Makefile.in (LD_VERSION_SCRIPT_OPTION, LD_SONAME_OPTION): New.
21721 * configure: Regenerate.
21722 * configure.ac ("linker --version-script option"): New.
21723 ("linker soname option"): New.
21724
21725 2018-03-09 Richard Biener <rguenther@suse.de>
21726
21727 PR tree-optimization/84775
21728 * tree-if-conv.c (add_bb_predicate_gimplified_stmts): Delink
21729 immediate uses of predicate stmts and mark them modified.
21730
21731 Revert
21732 PR tree-optimization/84178
21733 * tree-if-conv.c (combine_blocks): Move insert_gimplified_predicates
21734 to caller.
21735 (version_loop_for_if_conversion): Delay update_ssa call.
21736 (tree_if_conversion): Delay update_ssa until after predicate
21737 insertion.
21738
21739 2018-03-09 Eric Botcazou <ebotcazou@adacore.com>
21740
21741 PR target/84763
21742 * config/i386/winnt.c (i386_pe_seh_cold_init): Use small pre-allocation
21743 when the function accesses prior frames.
21744
21745 2018-03-08 Jakub Jelinek <jakub@redhat.com>
21746
21747 PR debug/84456
21748 * dwarf2out.c (dw_loc_list): If list && loc_list->first->next, call
21749 gen_llsym, otherwise call maybe_gen_llsym.
21750
21751 PR inline-asm/84742
21752 * recog.c (asm_operand_ok): Return 0 if multi-character constraint
21753 has ',' character inside of it.
21754
21755 2018-03-08 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
21756
21757 PR target/84748
21758 * config/aarch64/aarch64.md (*compare_cstore<mode>_insn): Mark pattern
21759 as clobbering CC_REGNUM.
21760
21761 2018-03-08 Richard Biener <rguenther@suse.de>
21762
21763 PR middle-end/84552
21764 * tree-scalar-evolution.c: Include tree-into-ssa.h.
21765 (follow_copies_to_constant): Do not follow SSA names registered
21766 for update.
21767
21768 2018-03-08 Richard Biener <rguenther@suse.de>
21769
21770 PR tree-optimization/84178
21771 * tree-if-conv.c (combine_blocks): Move insert_gimplified_predicates
21772 to caller.
21773 (version_loop_for_if_conversion): Delay update_ssa call.
21774 (tree_if_conversion): Delay update_ssa until after predicate
21775 insertion.
21776
21777 2018-03-08 David Malcolm <dmalcolm@redhat.com>
21778
21779 PR tree-optimization/84178
21780 * tree-if-conv.c (release_bb_predicate): Remove the
21781 the assertion that the stmts have NULL use_ops.
21782 Discard the statements, asserting that they haven't
21783 yet been added to a BB.
21784
21785 2018-03-08 Richard Biener <rguenther@suse.de>
21786
21787 PR tree-optimization/84746
21788 * tree-ssa-pre.c (find_leader_in_sets): Deal with SET1 being NULL.
21789 (phi_translate): Pass in destination ANTIC_OUT set.
21790 (phi_translate_1): Likewise. For a simplified result lookup
21791 a leader in ANTIC_OUT and AVAIL_OUT, not the ANTIC_IN sets.
21792 (phi_translate_set): Adjust.
21793 (do_pre_regular_insertion): Likewise.
21794 (do_pre_partial_partial_insertion): Likewise.
21795
21796 2018-03-08 Martin Liska <mliska@suse.cz>
21797
21798 PR gcov-profile/84735
21799 * doc/gcov.texi: Document usage of profile files.
21800 * gcov-io.h: Document changes in the format.
21801
21802 2018-03-08 Alexandre Oliva <aoliva@redhat.com>
21803
21804 PR debug/84404
21805 PR debug/84408
21806 * dwarf2out.c (struct dw_line_info_table): Update comments for
21807 view == -1.
21808 (FORCE_RESET_NEXT_VIEW): New.
21809 (FORCE_RESETTING_VIEW_P): New.
21810 (RESETTING_VIEW_P): Check for -1 too.
21811 (ZERO_VIEW_P): Likewise.
21812 (new_line_info_table): Force-reset next view.
21813 (dwarf2out_begin_function): Likewise.
21814 (dwarf2out_source_line): Simplify zero_view_p initialization.
21815 Test FORCE_RESETTING_VIEW_P and RESETTING_VIEW_P instead of
21816 view directly. Omit view when omitting .loc at line 0.
21817
21818 2018-03-08 Jakub Jelinek <jakub@redhat.com>
21819
21820 PR tree-optimization/84740
21821 * tree-switch-conversion.c (process_switch): Call build_constructors
21822 only if info.phi_count is non-zero.
21823
21824 PR tree-optimization/84739
21825 * tree-tailcall.c (find_tail_calls): Check call arguments against
21826 DECL_ARGUMENTS (current_function_decl) rather than
21827 DECL_ARGUMENTS (func) when checking for tail recursion.
21828
21829 2018-03-07 Jakub Jelinek <jakub@redhat.com>
21830
21831 * doc/contrib.texi: Add entries for Martin Liska, David Malcolm,
21832 Marek Polacek, extend Vladimir Makarov's, Jonathan Wakely's and
21833 Volker Reichelt's entry and add entries for people that perform
21834 GCC fuzzy testing and report numerous bugs.
21835
21836 2018-03-07 Segher Boessenkool <segher@kernel.crashing.org>
21837
21838 PR target/82411
21839 * config/rs6000/rs6000.c (rs6000_elf_in_small_data_p): Don't put
21840 readonly data in sdata, if that is disabled.
21841 * config/rs6000/sysv4.opt (mreadonly-in-sdata): New option.
21842 * doc/invoke.texi (RS/6000 and PowerPC Options): Document
21843 -mreadonly-in-sdata option.
21844
21845 2018-03-07 Martin Sebor <msebor@redhat.com>
21846
21847 PR tree-optimization/84468
21848 * tree-ssa-strlen.c (maybe_diag_stxncpy_trunc): Consider successor
21849 basic block when looking for nul assignment.
21850
21851 2018-03-07 Eric Botcazou <ebotcazou@adacore.com>
21852
21853 PR target/84277
21854 * except.h (output_function_exception_table): Adjust prototype.
21855 * except.c (output_function_exception_table): Remove FNNAME parameter
21856 and add SECTION parameter. Ouput one part of the table at a time.
21857 * final.c (final_scan_insn_1) <NOTE_INSN_SWITCH_TEXT_SECTIONS>: Output
21858 the first part of the exception table and emit unwind directives.
21859 * config/i386/i386-protos.h (i386_pe_end_cold_function): Declare.
21860 (i386_pe_seh_cold_init): Likewise.
21861 * config/i386/cygming.h (ASM_DECLARE_COLD_FUNCTION_NAME): New macro.
21862 (ASM_DECLARE_COLD_FUNCTION_SIZE): Likewise.
21863 * config/i386/i386.c (x86_expand_epilogue): Fix wording in comment.
21864 (ix86_output_call_insn): Emit a nop in one more case for SEH.
21865 * config/i386/winnt.c: Include except.h.
21866 (struct seh_frame_state): Add reg_offset, after_prologue and
21867 in_cold_section fields.
21868 (i386_pe_seh_end_prologue): Set seh->after_prologue.
21869 (i386_pe_seh_cold_init): New function.
21870 (i386_pe_seh_fini): Add COLD parameter and bail out if it is not equal
21871 to seh->in_cold_section.
21872 (seh_emit_push): Record the offset of the push.
21873 (seh_emit_save): Record the offet of the save.
21874 (i386_pe_seh_unwind_emit): Deal with NOTE_INSN_SWITCH_TEXT_SECTIONS.
21875 Test seh->after_prologue to disregard the epilogue.
21876 (i386_pe_end_function): Pass FALSE to i386_pe_seh_fini.
21877 (i386_pe_end_cold_function): New function.
21878
21879 2018-03-07 Jakub Jelinek <jakub@redhat.com>
21880
21881 PR fortran/84565
21882 * config/aarch64/predicates.md (aarch64_simd_reg_or_zero): Use
21883 aarch64_simd_or_scalar_imm_zero rather than aarch64_simd_imm_zero.
21884
21885 PR c++/84704
21886 * gimple-expr.c (create_tmp_var_raw): Set DECL_NAMELESS flag
21887 on tmp_var.
21888 * tree-pretty-print.c (dump_decl_name): For TDF_COMPARE_DEBUG,
21889 don't print names of DECL_NAMELESS DECL_IGNORED_P decls.
21890
21891 PR middle-end/84723
21892 * multiple_target.c: Include tree-inline.h and intl.h.
21893 (expand_target_clones): Diagnose and fail if node->definition and
21894 !tree_versionable_function_p (node->decl).
21895
21896 2018-03-06 John David Anglin <danglin@gcc.gnu.org>
21897
21898 * config/pa/pa.h (ASM_GENERATE_INTERNAL_LABEL): Revise to use
21899 sprint_ul.
21900 (ASM_OUTPUT_ADDR_VEC_ELT): Revise for above change.
21901 (ASM_OUTPUT_ADDR_DIFF_ELT): Likewise.
21902 * config/pa/pa64-hpux.h (ASM_GENERATE_INTERNAL_LABEL): Revise as above.
21903
21904 2018-03-06 Jakub Jelinek <jakub@redhat.com>
21905
21906 PR target/84710
21907 * combine.c (try_combine): Use reg_or_subregno instead of handling
21908 just paradoxical SUBREGs and REGs.
21909
21910 2018-03-06 Claudiu Zissulescu <claziss@synopsys.com>
21911
21912 * config/arc/arc.c (arc_finalize_pic): Remove function.
21913 (arc_must_save_register): We use single base PIC register, remove
21914 checks to save/restore the PIC register.
21915 (arc_expand_prologue): Likewise.
21916 * config/arc/arc-protos.h (arc_set_default_type_attributes):
21917 Remove.
21918 (arc_verify_short): Likewise.
21919 (arc_attr_type): Likewise.
21920 * config/arc/arc.c (arc_set_default_type_attributes): Remove.
21921 (walk_stores): Likewise.
21922 (arc_address_cost): Make it static.
21923 (arc_verify_short): Likewise.
21924 (branch_dest): Likewise.
21925 (arc_attr_type): Likewise.
21926 * config/arc/arc.c (TARGET_ADJUST_INSN_LENGTH): Remove.
21927 (TARGET_INSN_LENGTH_PARAMETERS): Likewise.
21928 (arc_final_prescan_insn): Remove inserting the nops due to
21929 hardware hazards. It is done in reorg step.
21930 (insn_length_variant_t): Remove.
21931 (insn_length_parameters_t): Likewise.
21932 (arc_insn_length_parameters): Likewise.
21933 (arc_get_insn_variants): Likewise.
21934 * config/arc/arc.h (TARGET_UPSIZE_DBR): Remove.
21935
21936 2018-03-06 Jakub Jelinek <jakub@redhat.com>
21937
21938 PR inline-asm/84683
21939 * reg-stack.c (move_for_stack_reg): If any_malformed_asm, avoid
21940 assertion failure.
21941
21942 PR tree-optimization/84687
21943 * omp-simd-clone.c (simd_clone_create): Clear DECL_BUILT_IN_CLASS
21944 on new_node->decl.
21945 * match.pd (pow(C,x)*expN(y) -> expN(logN(C)*x+y)): New optimization.
21946
21947 2018-03-05 Bill Schmidt <wschmidt@linux.vnet.ibm.com>
21948
21949 * config/rs6000/rs6000-builtin.def (rs6000_speculation_barrier):
21950 Rename to ppc_speculation_barrier.
21951 * config/rs6000/rs6000.c (rs6000_init_builtins): Rename builtin to
21952 __builtin_ppc_speculation_barrier.
21953
21954 2018-03-05 Jakub Jelinek <jakub@redhat.com>
21955
21956 PR target/84700
21957 * combine.c (combine_simplify_rtx): Don't try to simplify if
21958 if_then_else_cond returned non-NULL, but either true_rtx or false_rtx
21959 are equal to x.
21960
21961 2018-03-05 Segher Boessenkool <segher@kernel.crashing.org>
21962
21963 * config/rs6000/rs6000.c (rs6000_loop_align): Don't align tiny loops
21964 to 32 bytes when compiling for POWER9.
21965
21966 2018-03-05 Jakub Jelinek <jakub@redhat.com>
21967
21968 PR target/84564
21969 * config/i386/i386.c (ix86_function_ok_for_sibcall): Check for
21970 regparm >= 3 with no arg reg available also for calls with
21971 flag_force_indirect_call. Pass decl to ix86_function_regparm.
21972
21973 PR target/84524
21974 * config/i386/sse.md (*<code><mode>3): Replace <mask_prefix3> with
21975 orig,vex.
21976 (*<plusminus_insn><mode>3): Likewise. Remove <mask_operand3> uses.
21977
21978 2018-03-05 Peter Bergner <bergner@vnet.ibm.com>
21979
21980 PR target/84264
21981 * config/rs6000/vector.md (mov<mode>): Disallow altivec memory operands.
21982
21983 2018-03-05 Richard Biener <rguenther@suse.de>
21984
21985 PR tree-optimization/84486
21986 * tree-ssa-pre.c (create_expression_by_pieces): Remove dead code.
21987 When inserting a __builtin_assume_aligned call set the LHS
21988 SSA name alignment info accordingly.
21989
21990 2018-03-05 Wilco Dijkstra <wdijkstr@arm.com>
21991
21992 PR tree-optimization/84114
21993 * config/aarch64/aarch64.c (aarch64_reassociation_width)
21994 Avoid reassociation of FLOAT_MODE addition.
21995
21996 2018-03-05 Olga Makhotina <olga.makhotina@intel.com>
21997
21998 * common/config/i386/i386-common.c (OPTION_MASK_ISA_PCONFIG_SET,
21999 OPTION_MASK_ISA_PCONFIG_UNSET, OPTION_MASK_ISA_WBNOINVD_SET,
22000 OPTION_MASK_ISA_WBNOINVD_UNSET): New definitions.
22001 (ix86_handle_option): Handle -mpconfig and -mwbnoinvd.
22002 * config.gcc (pconfigintrin.h, wbnoinvdintrin.h) : Add headers.
22003 * config/i386/cpuid.h (bit_PCONFIG, bit_WBNOINVD): New.
22004 * config/i386/driver-i386.c (host_detect_local_cpu): Detect -mpconfig
22005 and -mwbnoinvd.
22006 * config/i386/i386-builtin.def (__builtin_ia32_wbnoinvd,
22007 __builtin_ia32_wbinvd): New builtins.
22008 (SPECIAL_ARGS2): New.
22009 * config/i386/i386-c.c (__WBNOINVD__, __PCONFIG__): New.
22010 (SPECIAL_ARGS2): New.
22011 * config/i386/i386.c (ix86_target_string): Add -mpconfig and -mwbnoinvd.
22012 (ix86_valid_target_attribute_inner_p): Ditto.
22013 (ix86_init_mmx_sse_builtins): Add special_args2.
22014 * config/i386/i386.h (TARGET_PCONFIG, TARGET_PCONFIG_P, TARGET_WBNOINVD,
22015 TARGET_WBNOINVD_P): New.
22016 * config/i386/i386.md (UNSPECV_WBINVD, UNSPECV_WBNOINVD): New.
22017 (define_insn "wbinvd", define_insn "wbnoinvd"): New.
22018 * config/i386/i386.opt: Add -mpconfig and -mwbnoinvd.
22019 * config/i386/immintrin.h (_wbinvd): New intrinsic.
22020 * config/i386/pconfigintrin.h: New file.
22021 * config/i386/wbnoinvdintrin.h: Ditto.
22022 * config/i386/x86intrin.h: Add headers pconfigintrin.h and
22023 wbnoinvdintrin.h.
22024 * doc/invoke.texi (-mpconfig, -mwbnoinvd): New.
22025
22026 2018-03-05 Richard Biener <rguenther@suse.de>
22027
22028 PR tree-optimization/84670
22029 * tree-ssa-pre.c (struct bb_bitmap_sets): Add visited_with_visited_succs
22030 member.
22031 (BB_VISITED_WITH_VISITED_SUCCS): New define.
22032 (compute_antic): Initialize BB_VISITED_WITH_VISITED_SUCCS.
22033 (compute_antic_aux): Only assert the number of values in ANTIC_IN
22034 doesn't grow if all successors (recursively) were visited at least
22035 once.
22036
22037 2018-03-05 Richard Biener <rguenther@suse.de>
22038
22039 PR tree-optimization/84650
22040 * tree-ssa-loop-im.c (pass_lim::execute): Reset the SCEV cache
22041 if executed in the loop pipeline.
22042
22043 2018-03-05 Sandra Loosemore <sandra@codesourcery.com>
22044
22045 * doc/configfiles.texi (Configuration Files): Move info about
22046 conditionalizing $target-protos.h to...
22047 * doc/sourcebuild.texi (Back End): Here. Explain how $target.h
22048 differs from $target-protos.h.
22049
22050 2018-03-05 Kito Cheng <kito.cheng@gmail.com>
22051 Chung-Ju Wu <jasonwucj@gmail.com>
22052
22053 * config/nds32/nds32-protos.h (nds32_expand_setmem): Declare.
22054 * config/nds32/nds32-multiple.md (setmemsi): Define.
22055 * config/nds32/nds32-memory-manipulation.c
22056 (nds32_gen_dup_4_byte_to_word_value): New.
22057 (emit_setmem_word_loop): New.
22058 (emit_setmem_byte_loop): New.
22059 (nds32_expand_setmem_loop): New.
22060 (nds32_expand_setmem_loop_v3m): New.
22061 (nds32_expand_setmem_unroll): New.
22062 (nds32_expand_setmem): New.
22063
22064 2018-03-04 Kito Cheng <kito.cheng@gmail.com>
22065 Chung-Ju Wu <jasonwucj@gmail.com>
22066
22067 * config/nds32/nds32-memory-manipulation.c
22068 (nds32_emit_load_store): New.
22069 (nds32_emit_post_inc_load_store): New.
22070 (nds32_emit_mem_move): New.
22071 (nds32_emit_mem_move_block): New.
22072 (nds32_expand_movmemsi_loop_unknown_size): New.
22073 (nds32_expand_movmemsi_loop_known_size): New.
22074 (nds32_expand_movmemsi_loop): New.
22075 (nds32_expand_movmemsi_unroll): New.
22076 (nds32_expand_movmemqi): Rename ...
22077 (nds32_expand_movmemsi): ... to this.
22078 * config/nds32/nds32-multiple.md (movmemqi): Rename ...
22079 (movmemsi): ... to this.
22080 * config/nds32/nds32-protos.h (nds32_expand_movmemqi): Rename ...
22081 (nds32_expand_movmemsi): ... to this.
22082
22083 2018-03-04 Kito Cheng <kito.cheng@gmail.com>
22084 Monk Chiang <sh.chiang04@gmail.com>
22085 Chung-Ju Wu <jasonwucj@gmail.com>
22086
22087 * config/nds32/nds32-protos.h
22088 (nds32_expand_load_multiple): New arguments.
22089 (nds32_expand_store_multiple): Ditto.
22090 (nds32_valid_multiple_load_store): Rename ...
22091 (nds32_valid_multiple_load_store_p): ... to this.
22092 * config/nds32/nds32-memory-manipulation.c
22093 (nds32_expand_load_multiple): Refine implementation.
22094 (nds32_expand_store_multiple): Ditto.
22095 * config/nds32/nds32-multiple.md
22096 (load_multiple): Update nds32_expand_load_multiple interface.
22097 (store_multiple): Update nds32_expand_store_multiple interface.
22098 * config/nds32/nds32-predicates.c
22099 (nds32_valid_multiple_load_store): Rename ...
22100 (nds32_valid_multiple_load_store_p): ... to this and refine
22101 implementation.
22102 * config/nds32/predicates.md
22103 (nds32_load_multiple_and_update_address_operation): New predicate.
22104 (nds32_store_multiple_and_update_address_operation): New predicate.
22105
22106 2018-03-04 Kito Cheng <kito.cheng@gmail.com>
22107 Chung-Ju Wu <jasonwucj@gmail.com>
22108
22109 * config/nds32/nds32.md (type): Add load_multiple and store_multiple.
22110 (combo): New attribute.
22111 * config/nds32/nds32-multiple.md: Refine patterns with new attributes.
22112
22113 2018-03-03 Chung-Ju Wu <jasonwucj@gmail.com>
22114
22115 * config/nds32/nds32.opt: Change -mcmodel= default value.
22116
22117 2018-03-03 Kito Cheng <kito.cheng@gmail.com>
22118 Monk Chiang <sh.chiang04@gmail.com>
22119 Chung-Ju Wu <jasonwucj@gmail.com>
22120
22121 * config/nds32/constants.md (unspec_element): New enum.
22122 * config/nds32/constraints.md (Umw): New constraint.
22123 * config/nds32/nds32-intrinsic.c: Add more builtin functions.
22124 * config/nds32/nds32-intrinsic.md: Likewise.
22125 * config/nds32/nds32-md-auxiliary.c (nds32_regno_to_enable4): New.
22126 (nds32_valid_smw_lwm_base_p): New.
22127 (nds32_output_smw_single_word): New.
22128 (nds32_output_lmw_single_word): New.
22129 (nds32_expand_unaligned_load): New.
22130 (nds32_expand_unaligned_store): New.
22131 * config/nds32/nds32-protos.h (nds32_valid_smw_lwm_base_p): Declare.
22132 (nds32_output_smw_single_word): Declare.
22133 (nds32_output_lmw_single_word): Declare.
22134 (nds32_expand_unaligned_load): Declare.
22135 (nds32_expand_unaligned_store): Declare.
22136 * config/nds32/nds32.h (nds32_builtins): Add NDS32_BUILTIN_UALOAD_HW,
22137 NDS32_BUILTIN_UALOAD_W, NDS32_BUILTIN_UALOAD_DW,
22138 NDS32_BUILTIN_UASTORE_HW, NDS32_BUILTIN_UASTORE_W,
22139 NDS32_BUILTIN_UASTORE_DW.
22140 * config/nds32/predicates.md (nds32_lmw_smw_base_operand): New
22141 predicate.
22142
22143 2018-03-03 Monk Chiang <sh.chiang04@gmail.com>
22144 Kito Cheng <kito.cheng@gmail.com>
22145 Chung-Ju Wu <jasonwucj@gmail.com>
22146
22147 * config/nds32/nds32-intrinsic.c
22148 (nds32_expand_builtin_null_ftype_reg): Delete.
22149 (nds32_expand_builtin_reg_ftype_imm): Ditto.
22150 (nds32_expand_builtin_null_ftype_reg_imm): Ditto.
22151 (nds32_read_argument): New.
22152 (nds32_legitimize_target): Ditto.
22153 (nds32_legitimize_argument): Ditto.
22154 (nds32_check_constant_argument): Ditto.
22155 (nds32_expand_unop_builtin): Ditto.
22156 (nds32_expand_unopimm_builtin): Ditto.
22157 (nds32_expand_binop_builtin): Ditto.
22158 (nds32_builtin_decl_impl): Ditto.
22159 (builtin_description): Ditto.
22160 (nds32_expand_builtin_impl): Rewrite with new infrastructure.
22161 (nds32_init_builtins_impl): Ditto.
22162 * config/nds32/nds32.c (TARGET_BUILTIN_DECL): Define.
22163 (nds32_builtin_decl): New.
22164 * config/nds32/nds32.h (nds32_builtins): Add NDS32_BUILTIN_COUNT.
22165 * config/nds32/nds32-protos.h (nds32_builtin_decl_impl): Declare.
22166
22167 2018-03-02 Jeff Law <law@redhat.com>
22168
22169 * reorg.c (stop_search_p): Handle DEBUG_INSN.
22170 (redundant_insn, fill_simple_delay_slots): Likewise.
22171 (fill_slots_from_thread): Likewise.
22172 * resource.c (mark_referenced_resources): Likewise.
22173 (mark_set_resources, find_dead_or_set_registers): Likewise.
22174
22175 2018-03-02 Jakub Jelinek <jakub@redhat.com>
22176
22177 * substring-locations.h (format_warning_va): Formatting fix for
22178 ATTRIBUTE_GCC_DIAG.
22179 (format_warning_at_substring): Fix up ATTRIBUTE_GCC_DIAG second
22180 argument.
22181 (format_warning_n_va, format_warning_at_substring_n): New prototypes.
22182 * substring-locations.c: Include intl.h.
22183 (format_warning_va): Turned into small wrapper around
22184 format_warning_n_va, renamed to ...
22185 (format_warning_n_va): ... this, add N and PLURAL_GMSGID arguments,
22186 rename GMSGID to SINGULAR_GMSGID, if SINGULAR_GMSGID != PLURAL_GMSGID,
22187 use ngettext.
22188 (format_warning_at_substring_n): New function.
22189 * gimple-ssa-sprintf.c: Remove GCC diagnostic ignored pragma.
22190 (fmtwarn): Add ATTRIBUTE_GCC_DIAG. Turn into a copy of
22191 format_warning_at_substring with just a shorter name instead of
22192 const function pointer.
22193 (fmtwarn_n): New function.
22194 (maybe_warn, format_directive, parse_directive): Use fmtwarn_n where
22195 appropriate, get rid of all the fmtstr temporaries, move conditionals
22196 with G_() wrapped string literals directly into fmtwarn arguments,
22197 cast dir.len to (int), formatting fixes.
22198
22199 2018-03-02 Thomas Schwinge <thomas@codesourcery.com>
22200
22201 * doc/invoke.texi: Remove "Cilk Plus" references.
22202
22203 2018-03-02 Jakub Jelinek <jakub@redhat.com>
22204 Richard Biener <rguenther@suse.de>
22205
22206 PR ipa/84628
22207 * expr.c (expand_expr_real_1) <case CALL_EXPR>: Don't emit diagnostics
22208 for error or warning attributes if CALL_FROM_THUNK_P is set.
22209 Formatting fixes.
22210
22211 2018-03-02 Jakub Jelinek <jakub@redhat.com>
22212
22213 PR target/56540
22214 * config/pa/pa.h (TARGET_CPU_CPP_BUILTINS): Predefine
22215 __SIZEOF_128__ macro if HPUX_LONG_DOUBLE_LIBRARY.
22216
22217 PR target/56540
22218 * config/ia64/ia64.h (TARGET_CPU_CPP_BUILTINS): Predefine
22219 __SIZEOF_{FPREG,FLOAT{80,128}}__ macros.
22220
22221 * predict.c (test_prediction_value_range): Use PROB_UNINITIALIZED
22222 instead of -1U in last predictors element's probability member.
22223
22224 2018-03-02 Eric Botcazou <ebotcazou@adacore.com>
22225
22226 PR ipa/83983
22227 * ipa-devirt.c (odr_subtypes_equivalent_p): Get the ODR type of both
22228 arguments if they are comparable.
22229
22230 2018-03-02 Richard Sandiford <richard.sandiford@linaro.org>
22231
22232 PR tree-optimization/84634
22233 * tree-vect-stmts.c (vectorizable_store, vectorizable_load): Replace
22234 masks and masked_loop_p with a single loop_masks, making sure it's
22235 null for bb vectorization.
22236
22237 2018-03-02 Richard Sandiford <richard.sandiford@linaro.org>
22238
22239 * tree-vect-data-refs.c (vect_analyze_data_ref_dependence)
22240 (vect_analyze_data_ref_access): Use loop->safe_len rather than
22241 loop->force_vectorize to check whether there is no alias.
22242
22243 2018-03-02 Jakub Jelinek <jakub@redhat.com>
22244
22245 PR target/84614
22246 * rtl.h (prev_real_nondebug_insn, next_real_nondebug_insn): New
22247 prototypes.
22248 * emit-rtl.c (next_real_insn, prev_real_insn): Fix up function
22249 comments.
22250 (next_real_nondebug_insn, prev_real_nondebug_insn): New functions.
22251 * cfgcleanup.c (try_head_merge_bb): Use prev_real_nondebug_insn
22252 instead of a loop around prev_real_insn.
22253 * combine.c (move_deaths): Use prev_real_nondebug_insn instead of
22254 prev_real_insn.
22255
22256 PR inline-asm/84625
22257 * config/i386/i386.c (ix86_print_operand): Use conditional
22258 output_operand_lossage instead of gcc_assert if CONST_VECTOR is not
22259 zero vector.
22260
22261 2018-03-02 Richard Biener <rguenther@suse.de>
22262
22263 PR tree-optimization/84427
22264 * tree-ssa-pre.c (bitmap_remove_expr_from_set): Remove.
22265 (bitmap_set_subtract_values): Rewrite to handle multiple
22266 exprs per value.
22267 (clean): Likewise.
22268 (prune_clobbered_mems): Likewise.
22269 (phi_translate): Take edge instead of pred/phiblock.
22270 (phi_translate_1): Likewise.
22271 (phi_translate_set): Likewise. Insert all translated
22272 exprs for a value into the set, keeping possibly multiple
22273 expressions per value.
22274 (compute_antic_aux): Adjust for phi_translate changes.
22275 When intersecting union the expressions and prune those
22276 not in the final value set, keeping possibly multiple
22277 expressions per value. Do not use value-insertion
22278 for unioning ANTIC_OUT U EXP_GEN - TMP_GEN but merge
22279 all expressions. Add verification that the value-sets
22280 only shrink during iteration.
22281 (compute_partial_antic_aux): Adjust for the phi_translate changes.
22282 (do_pre_regular_insertion): Likewise.
22283 (do_pre_partial_partial_insertion): Likewise.
22284
22285 2018-03-02 Richard Biener <rguenther@suse.de>
22286
22287 PR target/82005
22288 * config/darwin.c (saved_debug_info_level): New static global.
22289 (darwin_asm_lto_start): Disable debug info generation for LTO out.
22290 (darwin_asm_lto_end): Restore debug info generation settings.
22291
22292 2018-03-01 Martin Liska <mliska@suse.cz>
22293
22294 PR sanitizer/82484
22295 * sanopt.c (sanitize_rewrite_addressable_params): Do not handle
22296 volatile arguments.
22297
22298 2018-03-01 Richard Biener <rguenther@suse.de>
22299
22300 PR debug/84645
22301 * dwarf2out.c (gen_variable_die): Properly handle late VLA
22302 type annotation with LTO when debug was disabled at compile-time.
22303
22304 2018-03-01 Matthew Fortune <mfortune@gmail.com>
22305
22306 * config/mips/mips.c (mips_final_prescan_insn): Fix incorrect
22307 XINT with INTVAL.
22308 (mips_final_postscan_insn): Likewise.
22309
22310 2018-03-01 Richard Sandiford <richard.sandiford@linaro.org>
22311
22312 PR rtl-optimization/84528
22313 * alias.c (init_alias_target): Add commentary.
22314 (init_alias_analysis): Only give HARD_FRAME_POINTER_REGNUM
22315 a unique base value if the frame pointer is not eliminated
22316 to the stack pointer.
22317
22318 2018-03-01 Tom de Vries <tom@codesourcery.com>
22319
22320 PR rtl-optimization/83327
22321 * lra-int.h (hard_regs_spilled_into): Declare.
22322 * lra.c (hard_regs_spilled_into): Define.
22323 (init_reg_info): Init hard_regs_spilled_into.
22324 * lra-spills.c (assign_spill_hard_regs): Update hard_regs_spilled_into.
22325 * lra-lives.c (make_hard_regno_born, make_hard_regno_dead)
22326 (process_bb_lives): Handle hard_regs_spilled_into.
22327 (lra_create_live_ranges_1): Before doing liveness propagation, clear
22328 regs in all_hard_regs_bitmap if set in hard_regs_spilled_into.
22329
22330 2018-02-28 David Edelsohn <dje.gcc@gmail.com>
22331
22332 * config.gcc (powerpc-ibm-aix7.1.*): New stanza.
22333 (powerpc-ibm-aix[789]*): Default to AIX 7.2.
22334 * config/rs6000/aix71.h (TARGET_DEFAULT): Revert to Power4 ISA.
22335 * config/rs6000/aix72.h: New file.
22336
22337 2018-02-28 Jakub Jelinek <jakub@redhat.com>
22338
22339 * gimple-ssa-warn-restrict.c (maybe_diag_overlap): Use warning_n
22340 instead of warning_at with conditional singular and plural messages
22341 where possible.
22342
22343 PR target/52991
22344 * stor-layout.c (update_alignment_for_field): For
22345 targetm.ms_bitfield_layout_p (rli->t), if !is_bitfield
22346 && !DECL_PACKED (field), do the alignment update, just use
22347 only desired_align instead of MAX (type_align, desired_align)
22348 as the alignment.
22349 (place_field): Don't do known_align < desired_align handling
22350 early if targetm.ms_bitfield_layout_p (rli->t) and rli->prev_field
22351 is non-NULL, instead do it after rli->prev_field handling and
22352 only if not within a bitfield word. For DECL_PACKED (field)
22353 use type_align of BITS_PER_UNIT.
22354
22355 2018-02-28 Eric Botcazou <ebotcazou@adacore.com>
22356
22357 * config/aarch64/aarch64.c (aarch64_emit_probe_stack_range): Remove
22358 superfluous parentheses and trailing spaces.
22359
22360 2018-02-28 Richard Biener <rguenther@suse.de>
22361
22362 PR tree-optimization/84584
22363 * graphite-scop-detection.c (scop_detection::add_scop): Discard
22364 SCoPs with fake exit edge.
22365
22366 2018-02-28 Martin Liska <mliska@suse.cz>
22367
22368 PR testsuite/84597
22369 * timevar.c (timer::print): Fix format to properly print 100%
22370 values.
22371
22372 2018-02-28 Richard Biener <rguenther@suse.de>
22373
22374 PR middle-end/84607
22375 * genmatch.c (capture_info::walk_match): Do not mark
22376 captured expressions without operands as expr_p given
22377 they act more like predicates and should be subject to
22378 "lost tail" side-effect preserving.
22379
22380 2018-02-28 Alexandre Oliva <aoliva@redhat.com>
22381
22382 PR rtl-optimization/81611
22383 * auto-inc-dec.c (attempt_change): Move dead note from
22384 mem_insn if it's the next use of regno
22385 (find_address): Take address use of reg holding
22386 non-incremented value. Add parm to limit search to the named
22387 reg only.
22388 (merge_in_block): Attempt to use a mem insn that is the next
22389 use of the original regno.
22390
22391 2018-02-27 Martin Sebor <msebor@redhat.com>
22392
22393 PR c++/83871
22394 * doc/invoke.texi (-Wmissing-attributes): New option.
22395 * print-tree.c (print_node): Handle DECL_UNINLINABLE.
22396
22397 2018-02-27 Martin Sebor <msebor@redhat.com>
22398
22399 PR translation/84207
22400 * diagnostic-core.h (warning_n, error_n, inform_n): Change
22401 n argument to unsigned HOST_WIDE_INT.
22402 * diagnostic.c (warning_n, error_n, inform_n): Ditto.
22403 (diagnostic_n_impl): Ditto. Handle arguments in excess of LONG_MAX.
22404 * gimple-ssa-sprintf.c (format_directive): Simplify inform_n call.
22405 * tree-ssa-strlen.c (maybe_diag_stxncpy_trunc): Use warning_n.
22406
22407 2018-02-27 Richard Biener <rguenther@suse.de>
22408
22409 PR tree-optimization/84512
22410 * tree-vect-loop.c (vect_compute_single_scalar_iteration_cost):
22411 Do not use the estimate returned from record_stmt_cost for
22412 the scalar iteration cost but sum properly using add_stmt_cost.
22413
22414 2018-02-27 Richard Biener <rguenther@suse.de>
22415
22416 PR tree-optimization/84466
22417 * graphite-scop-detection.c (scop_detection::stmt_simple_for_scop_p):
22418 Adjust last change to less strictly validate use operands.
22419
22420 2018-02-27 Martin Liska <mliska@suse.cz>
22421
22422 PR gcov-profile/84548
22423 * gcov.c (process_file): Allow partial overlap and consider it
22424 also as group functions.
22425 (output_lines): Properly calculate range of lines for a group.
22426
22427 2018-02-27 Martin Liska <mliska@suse.cz>
22428
22429 * timevar.c (timer::print_row): Remove 'usr', 'sys', 'wall' and
22430 'ggc' suffixes. Change first column width.
22431 (timer::print): Fix formatting of the column.
22432
22433 2018-02-27 Alexandre Oliva <aoliva@redhat.com>
22434
22435 * tree-ssa-live.c (remove_unused_scope_block_p): Do not
22436 preserve inline entry blocks for the sake of debug inline
22437 entry point markers alone.
22438 (remove_unused_locals): Suggest in comments a better place to
22439 force the preservation of inline entry blocks that are
22440 otherwise unused, but do not preserve them.
22441
22442 2018-02-26 H.J. Lu <hongjiu.lu@intel.com>
22443
22444 * config/i386/i386.c (ix86_output_indirect_jmp): Update comments.
22445
22446 2018-02-26 H.J. Lu <hongjiu.lu@intel.com>
22447
22448 PR target/84039
22449 * config/i386/constraints.md (Bs): Replace
22450 ix86_indirect_branch_register with
22451 TARGET_INDIRECT_BRANCH_REGISTER.
22452 (Bw): Likewise.
22453 * config/i386/i386.md (indirect_jump): Likewise.
22454 (tablejump): Likewise.
22455 (*sibcall_memory): Likewise.
22456 (*sibcall_value_memory): Likewise.
22457 Peepholes of indirect call and jump via memory: Likewise.
22458 (*sibcall_GOT_32): Disallowed for TARGET_INDIRECT_BRANCH_REGISTER.
22459 (*sibcall_value_GOT_32): Likewise.
22460 * config/i386/predicates.md (indirect_branch_operand): Likewise.
22461 (GOT_memory_operand): Likewise.
22462 (call_insn_operand): Likewise.
22463 (sibcall_insn_operand): Likewise.
22464 (GOT32_symbol_operand): Likewise.
22465 * config/i386/i386.h (TARGET_INDIRECT_BRANCH_REGISTER): New.
22466
22467 2018-02-26 Eric Botcazou <ebotcazou@adacore.com>
22468
22469 PR rtl-optimization/83496
22470 * reorg.c (steal_delay_list_from_target): Change REDUNDANT array from
22471 booleans to RTXes. Call fix_reg_dead_note on every non-null element.
22472 (steal_delay_list_from_fallthrough): Call fix_reg_dead_note on a
22473 redundant insn, if any.
22474 (relax_delay_slots): Likewise.
22475 (update_reg_unused_notes): Rename REDUNDANT_INSN to OTHER_INSN.
22476
22477 2018-02-26 Richard Sandiford <richard.sandiford@linaro.org>
22478
22479 PR tree-optimization/83965
22480 * tree-vect-patterns.c (vect_reassociating_reduction_p): Assume
22481 that grouped statements are part of a reduction chain. Return
22482 true if the statement is not marked as a reduction itself but
22483 is part of a group.
22484 (vect_recog_dot_prod_pattern): Don't check whether the statement
22485 is part of a group here.
22486 (vect_recog_sad_pattern): Likewise.
22487 (vect_recog_widen_sum_pattern): Likewise.
22488
22489 2018-02-26 Eric Botcazou <ebotcazou@adacore.com>
22490
22491 PR debug/84545
22492 * final.c (rest_of_clean_state): Also look for calls inside sequences.
22493
22494 2018-02-26 H.J. Lu <hongjiu.lu@intel.com>
22495
22496 PR target/84530
22497 * config/i386/i386-protos.h (ix86_output_indirect_jmp): Remove
22498 the bool argument.
22499 (ix86_output_indirect_function_return): New prototype.
22500 (ix86_split_simple_return_pop_internal): Likewise.
22501 * config/i386/i386.c (indirect_return_via_cx): New.
22502 (indirect_return_via_cx_bnd): Likewise.
22503 (indirect_thunk_name): Handle return va CX_REG.
22504 (output_indirect_thunk_function): Create alias for
22505 __x86_return_thunk_[re]cx and __x86_return_thunk_[re]cx_bnd.
22506 (ix86_output_indirect_jmp): Remove the bool argument.
22507 (ix86_output_indirect_function_return): New function.
22508 (ix86_split_simple_return_pop_internal): Likewise.
22509 * config/i386/i386.md (*indirect_jump): Don't pass false
22510 to ix86_output_indirect_jmp.
22511 (*tablejump_1): Likewise.
22512 (simple_return_pop_internal): Change it to define_insn_and_split.
22513 Call ix86_split_simple_return_pop_internal to split it for
22514 -mfunction-return=.
22515 (simple_return_indirect_internal): Call
22516 ix86_output_indirect_function_return instead of
22517 ix86_output_indirect_jmp.
22518
22519 2018-02-26 Jakub Jelinek <jakub@redhat.com>
22520
22521 PR bootstrap/84405
22522 * vec.h (vec_default_construct): For BROKEN_VALUE_INITIALIZATION use
22523 memset and value initialization afterwards.
22524
22525 2018-02-26 Christophe Lyon <christophe.lyon@linaro.org>
22526
22527 * Makefile.in (lto-wrapper): Use ALL_LINKERFLAGS.
22528
22529 2018-02-26 Ramana Radhakrishnan <ramana.radhakrishnan@arm.com>
22530
22531 PR target/84521
22532 * common/config/aarch64/aarch64-common.c
22533 (aarch_option_optimization_table[]): Switch
22534 off fomit-frame-pointer
22535
22536 2018-02-26 Kito Cheng <kito.cheng@gmail.com>
22537 Chung-Ju Wu <jasonwucj@gmail.com>
22538
22539 * config/nds32/nds32-multiple.md (load_multiple): Disallow
22540 volatile memory.
22541 (store_multiple): Ditto.
22542
22543 2018-02-26 Kito Cheng <kito.cheng@gmail.com>
22544
22545 * config.gcc: Add --with-cpu support for nds32 target.
22546 * config/nds32/nds32-opts.h (nds32_cpu_type): New.
22547 * config/nds32/nds32.opt: Add -mcpu= option.
22548
22549 2018-02-25 Segher Boessenkool <segher@kernel.crashing.org>
22550
22551 * config/rs6000/rs6000.opt (mvrsave=no, mvrsave=yes, isel=no,
22552 isel=yes): Warn for these deprecated options.
22553
22554 2018-02-23 David Edelsohn <dje.gcc@gmail.com>
22555
22556 * config/rs6000/aix71.h (TARGET_DEFAULT): Change to
22557 ISA_2_5_MASKS_EMBEDDED.
22558
22559 2018-02-23 Jakub Jelinek <jakub@redhat.com>
22560
22561 * ipa-prop.c (ipa_vr_ggc_hash_traits::hash): Hash p->min and
22562 p->max as pointers rather than using iterative_hash_expr.
22563
22564 2018-02-23 Carl Love <cel@us.ibm.com>
22565
22566 * config/rs6000/rs6000-builtin.def: Change VSIGNED2 and VUNSIGNED2
22567 macro expansions from BU_VSX_2 to BU_P8V_VSX_2 and BU_VSX_OVERLOAD_2 to
22568 BU_P8V_OVERLOAD_2.
22569 * config/rs6000/rs6000-c.c: Change VSX_BUILTIN_VEC_VSIGNED2 to
22570 P8V_BUILTIN_VEC_VSIGNED2. Change VSX_BUILTIN_VEC_VUNSIGNED2 to
22571 P8V_BUILTIN_VEC_VUNSIGNED2.
22572
22573 2018-02-22 Vladimir Makarov <vmakarov@redhat.com>
22574
22575 PR target/81572
22576 * lra-int.h (LRA_UNKNOWN_ALT, LRA_NON_CLOBBERED_ALT): New macros.
22577 * lra.c (lra_set_insn_recog_data, lra_update_insn_recog_data): Use
22578 LRA_UNKNOWN_ALT.
22579 * lra-constraints.c (curr_insn_transform): Set up
22580 LRA_NON_CLOBBERED_ALT for moves processed on the fast path. Use
22581 LRA_UNKNOWN_ALT.
22582 (remove_inheritance_pseudos): Use LRA_UNKNOWN_ALT.
22583 * lra-eliminations.c (spill_pseudos): Ditto.
22584 (process_insn_for_elimination): Ditto.
22585 * lra-lives.c (reg_early_clobber_p): Use the new macros.
22586 * lra-spills.c (spill_pseudos): Use LRA_UNKNOWN_ALT and
22587 LRA_NON_CLOBBERED_ALT.
22588
22589 2018-02-22 Martin Sebor <msebor@redhat.com>
22590
22591 PR tree-optimization/84480
22592 * gimple-fold.c (gimple_fold_builtin_strcpy): Move warnings
22593 to maybe_diag_stxncpy_trunc. Call it.
22594 * tree-ssa-strlen.c (maybe_diag_stxncpy_trunc): Integrate warnings
22595 from gimple_fold_builtin_strcpy. Print inlining stack.
22596 (handle_builtin_stxncpy): Print inlining stack.
22597 * tree-ssa-strlen.h (maybe_diag_stxncpy_trunc): Declare.
22598
22599 2018-02-22 H.J. Lu <hongjiu.lu@intel.com>
22600
22601 PR target/84176
22602 * config/i386/i386.c (ix86_set_indirect_branch_type): Issue an
22603 error when -mindirect-branch=thunk-extern, -fcf-protection=branch
22604 and -fcheck-pointer-bounds are used together.
22605 (indirect_thunk_prefix): New enum.
22606 (indirect_thunk_need_prefix): New function.
22607 (indirect_thunk_name): Replace need_bnd_p with need_prefix. Use
22608 "_nt" instead of "_bnd" for NOTRACK prefix.
22609 (output_indirect_thunk): Replace need_bnd_p with need_prefix.
22610 (output_indirect_thunk_function): Likewise.
22611 (): Likewise.
22612 (ix86_code_end): Update output_indirect_thunk_function calls.
22613 (ix86_output_indirect_branch_via_reg): Replace
22614 ix86_bnd_prefixed_insn_p with indirect_thunk_need_prefix.
22615 (ix86_output_indirect_branch_via_push): Likewise.
22616 (ix86_output_function_return): Likewise.
22617 * doc/invoke.texi: Document -mindirect-branch=thunk-extern is
22618 incompatible with -fcf-protection=branch and
22619 -fcheck-pointer-bounds.
22620
22621 2018-02-22 Steve Ellcey <sellcey@cavium.com>
22622
22623 PR target/83335
22624 * config/aarch64/aarch64.c (aarch64_print_address_internal):
22625 Change gcc_assert call to output_operand_lossage.
22626
22627 2018-02-22 Steve Ellcey <sellcey@cavium.com>
22628
22629 * doc/extend.texi (__builtin_extend_pointer): Document builtin.
22630
22631 2018-02-22 DJ Delorie <dj@redhat.com>
22632 Sebastian Perta <sebastian.perta@renesas.com>
22633 Oleg Endo <olegendo@gcc.gnu.org>
22634
22635 * config/rx/rx.c (rx_rtx_costs): New function.
22636 (TARGET_RTX_COSTS): Override to use rx_rtx_costs.
22637
22638 2018-02-22 Thomas Preud'homme <thomas.preudhomme@arm.com>
22639
22640 * config/arm/t-multilib: Map Armv8-R to Armv7 multilibs.
22641
22642 2018-02-22 Martin Liska <mliska@suse.cz>
22643
22644 PR driver/83193
22645 * common/config/arm/arm-common.c (arm_print_hint_for_cpu_option):
22646 Add "native" as a possible value.
22647
22648 2018-02-22 Martin Liska <mliska@suse.cz>
22649
22650 PR driver/83193
22651 * config/i386/i386.c (ix86_option_override_internal):
22652 Add "native" as a possible value for -march and -mtune.
22653
22654 2018-02-22 Jakub Jelinek <jakub@redhat.com>
22655
22656 PR target/84502
22657 * stor-layout.c (finalize_type_size): Propagate TYPE_EMPTY_P flag
22658 to all type variants.
22659
22660 PR tree-optimization/84503
22661 * gimple-ssa-store-merging.c (merged_store_group::merge_into): Compute
22662 width as info->bitpos + info->bitsize - start.
22663 (merged_store_group::merge_overlapping): Simplify width computation.
22664 (check_no_overlap): New function.
22665 (imm_store_chain_info::try_coalesce_bswap): Compute expected
22666 start + width and last_order of the group, fail if check_no_overlap
22667 fails.
22668 (imm_store_chain_info::coalesce_immediate_stores): Don't merge info
22669 to group if check_no_overlap fails.
22670
22671 2018-02-21 Segher Boessenkool <segher@kernel.crashing.org>
22672
22673 * config/rs6000/altivec.md: Delete contraint arguments to
22674 define_expand, define_split, and define_peephole2, and in
22675 define_insn_and_split if always unused.
22676 * config/rs6000/darwin.md: Ditto.
22677 * config/rs6000/dfp.md: Ditto.
22678 * config/rs6000/rs6000.md: Ditto.
22679 * config/rs6000/sync.md: Ditto.
22680 * config/rs6000/vector.md: Ditto.
22681 * config/rs6000/vsx.md: Ditto.
22682
22683 2018-02-21 Segher Boessenkool <segher@kernel.crashing.org>
22684
22685 * config/rs6000/altivec.md: Write output control strings as braced
22686 blocks instead of double-quoted strings.
22687 * config/rs6000/darwin.md: Ditto.
22688 * config/rs6000/rs6000.md: Ditto.
22689 * config/rs6000/vector.md: Ditto.
22690 * config/rs6000/vsx.md: Ditto.
22691
22692 2018-02-21 Jason Merrill <jason@redhat.com>
22693
22694 PR c++/84314 - ICE with templates and fastcall attribute.
22695 * attribs.c (build_type_attribute_qual_variant): Remove assert.
22696
22697 2018-02-21 Jan Hubicka <hubicka@ucw.cz>
22698
22699 * ipa-cp.c (determine_versionability): Fix comment typos.
22700
22701 2018-02-21 Jan Hubicka <hubicka@ucw.cz>
22702
22703 PR c/84229
22704 * ipa-cp.c (determine_versionability): Do not version functions caling
22705 va_arg_pack.
22706
22707 2018-02-21 Martin Liska <mliska@suse.cz>
22708
22709 PR driver/83193
22710 * config/aarch64/aarch64.c (aarch64_print_hint_for_core_or_arch):
22711 Add "native" as a possible value.
22712 * config/aarch64/aarch64.h (HAVE_LOCAL_CPU_DETECT): Define
22713 the macro when native cpu detection is available.
22714
22715 2018-02-21 Martin Liska <mliska@suse.cz>
22716
22717 PR driver/83193
22718 * common/config/arm/arm-common.c (arm_print_hint_for_arch_option):
22719 Add "native" as a possible value.
22720 * config/arm/arm.h (HAVE_LOCAL_CPU_DETECT): Define the macro
22721 when native cpu detection is available.
22722
22723 2018-02-21 Jakub Jelinek <jakub@redhat.com>
22724 Martin Sebor <msebor@redhat.com>
22725
22726 PR tree-optimization/84478
22727 * gimple-fold.h (get_range_strlen): Add a bool argument defaulted to
22728 false.
22729 * gimple-fold.c (get_range_strlen): Make minlen const and assume it
22730 can't be NULL. Change FUZZY from bool to int, for 1 add PHI/COND_EXPR
22731 support which is conservatively correct, for 2 only stay conservative
22732 for maxlen. Formatting and comment capitalization fixes. Add STRICT
22733 argument to the 2 argument get_range_strlen, adjust 6 arg
22734 get_range_strlen caller and clear minmaxlen[0] and [1] if it returned
22735 false.
22736 (get_maxval_strlen): Adjust 6 arg get_range_strlen caller.
22737 (gimple_fold_builtin_strlen): Pass true as last argument to
22738 get_range_strlen.
22739
22740 2018-02-20 Martin Sebor <msebor@redhat.com>
22741
22742 PR middle-end/84095
22743 * gimple-ssa-warn-restrict.c (builtin_memref::extend_offset_range): New.
22744 (builtin_memref::set_base_and_offset): Same. Handle inner references.
22745 (builtin_memref::builtin_memref): Factor out parts into
22746 set_base_and_offset and call it.
22747
22748 2018-02-20 Richard Sandiford <richard.sandiford@linaro.org>
22749
22750 PR middle-end/84406
22751 * optabs-query.c (find_widening_optab_handler_and_mode): If from_mode
22752 is a scalar_int_mode, assert that to_mode is a scalar_int_mode with
22753 greater precision. If to_mode is a MODE_PARTIAL_INT, stop the
22754 search at the associated MODE_INT.
22755
22756 2018-02-20 Jeff Law <law@redhat.com>
22757
22758 PR middle-end/82123
22759 PR tree-optimization/81592
22760 PR middle-end/79257
22761 * gimple-ssa-sprintf.c (format_integer): Query EVRP range analyzer
22762 for range data rather than using global data.
22763 * gimple-ssa-sprintf.c (get_int_range): Query EVRP range analyzer for
22764 range data rather than using global data.
22765 * gimple-ssa-sprintf.c (get_int_range): Accept vr_values parameter
22766 pass it to children as needed.
22767 (struct directive::fmtresult): Similarly.
22768 (struct directive::set_width): Similarly.
22769 (struct directive::set_precision): Similarly.
22770 (format_integer, format_directive, parse_directive): Similarly.
22771 (format_none): Accept unnamed vr_values parameter.
22772 (format_percent, format_floating, format_character): Similarly.
22773 (format_string, format_plain): Similarly.
22774 * gimple-ssa-sprintf.c (sprintf_dom_walker::handle_gimple_call): Query
22775 the EVRP range analyzer for range data rather than using global data.
22776 * gimple-ssa-sprintf.c: Include alloc-pool.h, vr-values.h and
22777 gimple-ssa-evrp-analyze.h
22778 (class sprintf_dom_walker): Add after_dom_children member function.
22779 Add evrp_range_analyzer member.
22780 (sprintf_dom_walker::before_dom_children): Call into the EVRP
22781 range analyzer as needed.
22782 (sprintf_dom_walker::after_dom_children): New member function.
22783 * gimple-ssa-evrp-analyze.c (evrp_range_analyzer::enter): Do nothing
22784 if not optimizing.
22785 (evrp_range_analyzer::record_ranges_from_stmt): Likewise.
22786 (evrp_range_analyzer::pop_to_marker): Likewise.
22787
22788 2018-02-20 Richard Sandiford <richard.sandiford@linaro.org>
22789
22790 PR tree-optimization/84419
22791 * internal-fn.c (expand_call_mem_ref): Create a TARGET_MEM_REF
22792 with the required type if its current type is compatible but
22793 different.
22794
22795 2018-02-20 Jakub Jelinek <jakub@redhat.com>
22796
22797 PR middle-end/82004
22798 * match.pd (pow(C,x) -> exp(log(C)*x)): Delay all folding until
22799 after vectorization.
22800
22801 2018-02-20 Martin Liska <mliska@suse.cz>
22802
22803 PR driver/83193
22804 * config/aarch64/aarch64.c (aarch64_print_hint_for_core_or_arch): Print
22805 possible values if we don't have a hint.
22806
22807 2018-02-20 Martin Liska <mliska@suse.cz>
22808
22809 PR c/84310
22810 PR target/79747
22811 * final.c (shorten_branches): Build align_tab array with one
22812 more element.
22813 * opts.c (finish_options): Add alignment option limit check.
22814 (MAX_CODE_ALIGN): Likewise.
22815 (MAX_CODE_ALIGN_VALUE): Likewise.
22816 * doc/invoke.texi: Document maximum allowed option value for
22817 all -falign-* options.
22818
22819 2018-02-19 Jakub Jelinek <jakub@redhat.com>
22820
22821 PR target/84146
22822 * reg-notes.def (REG_CALL_ARG_LOCATION): New reg note.
22823 * insn-notes.def (NOTE_INSN_CALL_ARG_LOCATION): Remove.
22824 * var-tracking.c (emit_note_insn_var_location): Remove all references
22825 to NOTE_INSN_CALL_ARG_LOCATION.
22826 (emit_notes_in_bb): Emit arguments as REG_CALL_ARG_LOCATION note on
22827 the CALL_INSN rather than separate NOTE_INSN_CALL_ARG_LOCATION note.
22828 Use copy_rtx_if_shared.
22829 * dwarf2out.c (gen_subprogram_die): Use XEXP with 0 instead of
22830 NOTE_VAR_LOCATION on ca_loc->call_arg_loc_note.
22831 (dwarf2out_var_location): Remove handling of
22832 NOTE_INSN_CALL_ARG_LOCATION, instead handle REG_CALL_ARG_LOCATION note
22833 on call_insn.
22834 * final.c (final_scan_insn): Remove all references to
22835 NOTE_INSN_CALL_ARG_LOCATION.
22836 (rest_of_clean_state): Likewise. Remove REG_CALL_ARG_LOCATION notes
22837 before dumping final insns.
22838 * except.c (emit_note_eh_region_end): Remove all references to
22839 NOTE_INSN_CALL_ARG_LOCATION.
22840 * config/alpha/alpha.c (alpha_pad_function_end): Likewise.
22841 * config/c6x/c6x.c (c6x_gen_bundles): Likewise.
22842 * config/arc/arc.c (hwloop_optimize): Likewise.
22843 * config/arm/arm.c (create_fix_barrier): Likewise.
22844 * config/s390/s390.c (s390_chunkify_start): Likewise.
22845 * config/sh/sh.c (find_barrier): Likewise.
22846 * config/i386/i386.c (rest_of_insert_endbranch,
22847 ix86_seh_fixup_eh_fallthru): Likewise.
22848 * config/xtensa/xtensa.c (hwloop_optimize): Likewise.
22849 * config/iq2000/iq2000.c (final_prescan_insn): Likewise.
22850 * config/frv/frv.c (frv_function_prologue): Likewise.
22851 * emit-rtl.c (try_split): Likewise. Copy over REG_CALL_ARG_LOCATION
22852 reg note.
22853 (note_outside_basic_block_p): Remove all references to
22854 NOTE_INSN_CALL_ARG_LOCATION.
22855 * gengtype.c (adjust_field_rtx_def): Likewise.
22856 * print-rtl.c (rtx_writer::print_rtx_operand_code_0, print_insn):
22857 Likewise.
22858 * jump.c (cleanup_barriers, delete_related_insns): Likewise.
22859 * cfgrtl.c (force_nonfallthru_and_redirect): Likewise.
22860
22861 PR c++/84444
22862 * builtins.c (builtin_mathfn_code): Don't check if CALL_EXPR_FN (t)
22863 is ADDR_EXPR.
22864
22865 PR tree-optimization/84452
22866 * tree-vect-patterns.c (vect_recog_pow_pattern): Don't call
22867 expand_simd_clones if targetm.simd_clone.compute_vecsize_and_simdlen
22868 is NULL.
22869
22870 2018-02-19 Martin Liska <mliska@suse.cz>
22871
22872 PR sanitizer/82183
22873 * passes.def: Put pass_sancov_O0 before pass_lower_switch with -O0.
22874
22875 2018-02-19 Martin Liska <mliska@suse.cz>
22876 Richard Sandiford <richard.sandiford@linaro.org>
22877
22878 PR tree-optimization/82491
22879 * gimple-fold.c (get_base_constructor): Make earlier bail out
22880 to prevent ubsan.
22881
22882 2018-02-19 Carl Love <cel@us.ibm.com>
22883
22884 * config/rs6000/rs6000-builtin.def: Change NEG macro expansions from
22885 BU_ALTIVEC_A to BU_P8V_AV_1 and BU_ALTIVEC_OVERLOAD_1 to
22886 BU_P8V_OVERLOAD_1.
22887 * config/rs6000/rs6000-c.c: Change ALTIVEC_BUILTIN_VEC_NEG to
22888 P8V_BUILTIN_VEC_NEG.
22889
22890 2018-02-19 Sebastian Perta <sebastian.perta@renesas.com>
22891
22892 * config/rl78/rl78.md (movdf): New define expand.
22893
22894 2018-02-19 Martin Liska <mliska@suse.cz>
22895
22896 PR other/80589
22897 * doc/invoke.texi: Fix typo.
22898 * params.def (PARAM_MAX_LOOP_HEADER_INSNS): Likewise.
22899
22900 2018-02-18 Segher Boessenkool <segher@kernel.crashing.org>
22901
22902 * config/rs6000/rs6000.c (rs6000_option_override_internal): Don't
22903 handle rs6000_single_float and rs6000_double_float specially for
22904 e500 family CPUs.
22905
22906 2018-02-16 Jeff Law <law@redhat.com>
22907
22908 * config/rx/rx.c (add_pop_cfi_notes): New function.;
22909 (pop_regs): Use it.
22910
22911 2018-02-16 Jakub Jelinek <jakub@redhat.com>
22912
22913 PR ipa/84425
22914 * ipa-inline.c (inline_small_functions): Fix a typo.
22915
22916 2018-02-16 Nathan Sidwell <nathan@acm.org>
22917
22918 * doc/extend.texi (Backwards Compatibility): Americanize 'behaviour'.
22919
22920 2018-02-16 Carl Love <cel@us.ibm.com>
22921
22922 * config/rs6000/rs6000-builtin.def: Add BU_P8V_VSX_2 macro definition.
22923 Change FLOAT2 expansions from BU_VSX_2 to BU_P8V_VSX_2 and
22924 from BU_VSX_OVERLOAD_2 to BU_P8V_OVERLOAD_2.
22925 * config/rs6000/rs6000-c.c: Changed macro VSX_BUILTIN_VEC_FLOAT2
22926 expansion to P8V_BUILTIN_VEC_FLOAT2.
22927
22928 2018-02-16 Vladimir Makarov <vmakarov@redhat.com>
22929
22930 PR rtl-optimization/70023
22931 * lra-constraints.c (inherit_in_ebb): Take hard reg mode of
22932 src_regno into account.
22933
22934 2018-02-16 Carl Love <cel@us.ibm.com>
22935
22936 * config/rs6000/altivec.h: Remove vec_vextract4b and vec_vinsert4b.
22937 * config/rs6000/rs6000-builtin.def: Remove macro expansion for
22938 VEXTRACT4B, VINSERT4B, VINSERT4B_DI and VEXTRACT4B.
22939 * config/rs6000/rs6000.c: Remove case statements for
22940 P9V_BUILTIN_VEXTRACT4B, P9V_BUILTIN_VEC_VEXTRACT4B,
22941 P9V_BUILTIN_VINSERT4B, P9V_BUILTIN_VINSERT4B_DI,
22942 and P9V_BUILTIN_VEC_VINSERT4B.
22943 * config/rs6000/rs6000-c.c (altivec_expand_builtin): Remove entries for
22944 P9V_BUILTIN_VEC_VEXTRACT4B and P9V_BUILTIN_VEC_VINSERT4B.
22945 * config/rs6000/vsx.md:
22946 * doc/extend.texi: Remove vec_vextract4b, non ABI definitions for
22947 vec_insert4b.
22948
22949 2018-02-16 Carl Love <cel@us.ibm.com>
22950
22951 * config/rs6000/altivec.h: Add builtin names vec_extract4b
22952 vec_insert4b.
22953 * config/rs6000/rs6000-builtin.def: Add INSERT4B and EXTRACT4B
22954 definitions.
22955 * config/rs6000/rs6000-c.c: Add the definitions for
22956 P9V_BUILTIN_VEC_EXTRACT4B and P9V_BUILTIN_VEC_INSERT4B.
22957 * config/rs6000/rs6000.c (altivec_expand_builtin): Add
22958 P9V_BUILTIN_EXTRACT4B and P9V_BUILTIN_INSERT4B case statements.
22959 * config/rs6000/vsx.md: Add define_insn extract4b. Add define_expand
22960 definition for insert4b and define insn *insert3b_internal.
22961 * doc/extend.texi: Add documentation for vec_extract4b.
22962
22963 2018-02-16 Nathan Sidwell <nathan@acm.org>
22964
22965 * doc/extend.texi (Backwards Compatibility): Mention friend
22966 injection. Note for-scope is deprecated.
22967 * doc/invoke.texi (-ffriend-injection): Deprecate.
22968
22969 2018-02-16 Segher Boessenkool <segher@kernel.crashing.org>
22970
22971 * combine.c (try_combine): When adjusting LOG_LINKS for the destination
22972 that moved to I2, also allow destinations that are a paradoxical
22973 subreg (instead of a normal reg).
22974
22975 2018-02-16 Oleg Endo <olegendo@gcc.gnu.org>
22976
22977 PR target/83831
22978 * config/rx/rx.c (rx_fuse_in_memory_bitop): Convert shift operand
22979 to QImode.
22980
22981 2018-02-16 Richard Biener <rguenther@suse.de>
22982
22983 PR tree-optimization/84037
22984 PR tree-optimization/84016
22985 PR target/82862
22986 * config/i386/i386.c (ix86_builtin_vectorization_cost):
22987 Adjust vec_construct for the fact we need additional higher latency
22988 128bit inserts for AVX256 and AVX512 vector builds.
22989 (ix86_add_stmt_cost): Scale vector construction cost for
22990 elementwise loads.
22991
22992 2018-02-16 Richard Biener <rguenther@suse.de>
22993
22994 PR tree-optimization/84417
22995 * tree-ssa.c (non_rewritable_mem_ref_base): Properly constrain
22996 the MEM_REF offset when conversion to BIT_FIELD_REF is desired.
22997 (non_rewritable_lvalue_p): Likewise, use poly-ints.
22998
22999 2018-02-16 Martin Liska <mliska@suse.cz>
23000
23001 PR sanitizer/84307
23002 * internal-fn.def (ASAN_CHECK): Set proper flags.
23003 (ASAN_MARK): Likewise.
23004
23005 2018-02-16 Julia Koval <julia.koval@intel.com>
23006
23007 * config/i386/i386.c (ix86_option_override_internal): Remove PTA_CLWB
23008 from PTA_CANNONLAKE.
23009
23010 2018-02-16 Jakub Jelinek <jakub@redhat.com>
23011
23012 PR target/84272
23013 * config/aarch64/cortex-a57-fma-steering.c (fma_forest::merge_forest):
23014 Use ++iter rather than iter++ for std::list iterators.
23015 (func_fma_steering::dfs): Likewise. Don't delete nodes right away,
23016 defer deleting them until all nodes in the forest are processed. Do
23017 free even leaf nodes. Change to_process into auto_vec.
23018
23019 PR bootstrap/84405
23020 * system.h (BROKEN_VALUE_INITIALIZATION): Define for GCC < 4.3.
23021 * vec.h (vec_default_construct): Use memset instead of placement new
23022 if BROKEN_VALUE_INITIALIZATION is defined.
23023 * hash-table.h (hash_table<Descriptor, Allocator>::empty_slow): Use
23024 memset instead of value initialization if BROKEN_VALUE_INITIALIZATION
23025 is defined.
23026
23027 PR rtl-optimization/83723
23028 * lra-int.h (lra_substitute_pseudo): Add DEBUG_P argument.
23029 * lra.c (lra_substitute_pseudo): Likewise. If true, use
23030 gen_rtx_raw_SUBREG instead of gen_rtx_SUBREG. Pass DEBUG_P to
23031 recursive calls.
23032 (lra_substitute_pseudo_within_insn): Adjust lra_substitute_pseudo
23033 callers.
23034 * lra-constraints.c (inherit_reload_reg, split_reg): Likewise.
23035
23036 2018-02-16 Eric Botcazou <ebotcazou@adacore.com>
23037
23038 PR rtl-optimization/81443
23039 * rtlanal.c (num_sign_bit_copies1) <SUBREG>: Do not propagate results
23040 from inner REGs to paradoxical SUBREGs.
23041
23042 2018-02-16 Richard Biener <rguenther@suse.de>
23043
23044 PR tree-optimization/84399
23045 * graphite-scop-detection.c (scop_detection::stmt_simple_for_scop_p):
23046 For operands we can analyze at their definition make sure we can
23047 analyze them at each use as well.
23048
23049 2018-02-16 Richard Biener <rguenther@suse.de>
23050
23051 PR tree-optimization/84190
23052 * tree-ssa.c (non_rewritable_mem_ref_base): Do not touch
23053 volatile accesses if the decl isn't volatile.
23054
23055 2018-02-15 Jason Merrill <jason@redhat.com>
23056
23057 PR c++/84314 - ICE with templates and fastcall attribute.
23058 * attribs.c (build_type_attribute_qual_variant): Don't clobber
23059 TYPE_CANONICAL on an existing type.
23060
23061 2018-02-15 Jakub Jelinek <jakub@redhat.com>
23062
23063 PR tree-optimization/84383
23064 * tree-ssa-strlen.c (maybe_diag_stxncpy_trunc): Don't look at
23065 dstoff nor call operand_equal_p if dstbase is NULL.
23066
23067 PR tree-optimization/84334
23068 * match.pd ((A +- CST1) +- CST2 -> A + CST3): If A is
23069 also a CONSTANT_CLASS_P, punt.
23070
23071 2018-02-14 Jim Wilson <jimw@sifive.com>
23072
23073 * config/riscv/riscv.c (riscv_first_stack_step): Move locals after
23074 first SMALL_OPERAND check. New local min_second_step. Move assert
23075 to where locals are set. Add TARGET_RVC support.
23076 * config/riscv/riscv.h (C_SxSP_BITS, SWSP_REACH, SDSP_REACH): New.
23077
23078 2018-02-14 Indu Bhagat <indu.bhagat@oracle.com>
23079
23080 * doc/invoke.texi: Correct -Wformat-overflow code sample.
23081
23082 2018-02-14 Martin Sebor <msebor@redhat.com>
23083
23084 PR tree-optimization/83698
23085 * gimple-ssa-warn-restrict.c (builtin_memref::builtin_memref): For
23086 arrays constrain the offset range to their bounds.
23087 (builtin_access::strcat_overlap): Adjust the bounds of overlap offset.
23088 (builtin_access::overlap): Avoid setting the size of overlap if it's
23089 already been set.
23090 (maybe_diag_overlap): Also consider arrays when deciding what values
23091 of offsets to include in diagnostics.
23092
23093 2018-02-14 Martin Sebor <msebor@redhat.com>
23094
23095 PR c/84108
23096 * attribs.c (diag_attr_exclusions): Consider the exclusion(s)
23097 that correspond to the kind of a declaration.
23098
23099 2018-02-14 John David Anglin <danglin@gcc.gnu.org>
23100
23101 PR target/83984
23102 * config/pa/pa.md: Load address of PIC label using the linkage table
23103 if the label is nonlocal.
23104
23105 2018-02-14 Kelvin Nilsen <kelvin@gcc.gnu.org>
23106
23107 * config/rs6000/rs6000.c (rs6000_option_override_internal): Issue
23108 warning message if user requests -maltivec=be.
23109 * doc/invoke.texi: Document deprecation of -maltivec=be.
23110
23111 2018-02-14 Will Schmidt <will_schmidt@vnet.ibm.com>
23112
23113 PR target/84220
23114 * config/rs6000/rs6000-c.c: Update definitions for
23115 ALTIVEC_BUILTIN_VEC_SLD, ALTIVEC_BUILTIN_VEC_SLDW,
23116 VEC_XXSLDWI and ALTIVEC_BUILTIN_VEC_XXPERMDI builtins.
23117
23118 2018-02-14 Igor Tsimbalist <igor.v.tsimbalist@intel.com>
23119
23120 PR target/84239
23121 * config/i386/cetintrin.h: Remove _rdssp[d|q] and
23122 add _get_ssp intrinsics. Remove argument from
23123 __builtin_ia32_rdssp[d|q].
23124 * config/i386/i386-builtin-types.def: Add UINT_FTYPE_VOID.
23125 * config/i386/i386-builtin.def: Remove argument from
23126 __builtin_ia32_rdssp[d|q].
23127 * config/i386/i386.c: Use UINT_FTYPE_VOID. Use
23128 ix86_expand_special_args_builtin for _rdssp[d|q].
23129 * config/i386/i386.md: Remove argument from rdssp[si|di] insn.
23130 Clear register before usage.
23131 * doc/extend.texi: Remove argument from __builtin_ia32_rdssp[d|q].
23132 Add documentation for new _get_ssp and _inc_ssp intrinsics.
23133
23134 2018-02-14 Richard Sandiford <richard.sandiford@linaro.org>
23135
23136 PR tree-optimization/84357
23137 * tree-data-ref.c (object_address_invariant_in_loop_p): Check
23138 operand 1 of an ARRAY_REF too.
23139
23140 2018-02-14 Oleg Endo <olegendo@gcc.gnu.org>
23141
23142 PR target/83831
23143 * config/rx/rx-protos.h (rx_reg_dead_or_unused_after_insn,
23144 rx_copy_reg_dead_or_unused_notes, rx_fuse_in_memory_bitop): New
23145 declarations.
23146 (set_of_reg): New struct.
23147 (rx_find_set_of_reg, rx_find_use_of_reg): New functions.
23148 * config/rx/rx.c (rx_reg_dead_or_unused_after_insn,
23149 rx_copy_reg_dead_or_unused_notes, rx_fuse_in_memory_bitop): New
23150 functions.
23151 * config/rx/rx.md (andsi3, iorsi3, xorsi3): Convert to insn_and_split.
23152 Split into bitclr, bitset, bitinvert patterns if appropriate.
23153 (*bitset, *bitinvert, *bitclr): Convert to named insn_and_split and
23154 use rx_fuse_in_memory_bitop.
23155 (*bitset_in_memory, *bitinvert_in_memory, *bitclr_in_memory): Convert
23156 to named insn, correct maximum insn length.
23157
23158 2018-02-14 Jozef Lawrynowicz <jozefl.gcc@gmail.com>
23159
23160 PR target/79242
23161 * machmode.def: Define a complex mode for PARTIAL_INT.
23162 * genmodes.c (complex_class): Return MODE_COMPLEX_INT for
23163 MODE_PARTIAL_INT.
23164 * doc/rtl.texi: Document CSPImode.
23165 * config/msp430/msp430.c (msp430_hard_regno_nregs): Add CPSImode
23166 handling.
23167 (msp430_hard_regno_nregs_with_padding): Likewise.
23168
23169 2018-02-13 Peter Bergner <bergner@vnet.ibm.com>
23170
23171 PR target/84279
23172 * config/rs6000/rs6000.c (mem_operand_gpr): Disallow altivec addresses.
23173
23174 2018-02-13 Segher Boessenkool <segher@kernel.crashing.org>
23175
23176 PR rtl-optimization/84169
23177 * combine.c (try_combine): New variable split_i2i3. Set it to true if
23178 we generated a parallel as new i3 and we split that to new i2 and i3
23179 instructions. Handle split_i2i3 similar to swap_i2i3: scan the
23180 LOG_LINKs of i3 to see which of those need to link to i2 now. Link
23181 those to i2, not i1. Partially rewrite this scan code.
23182
23183 2018-02-13 Jakub Jelinek <jakub@redhat.com>
23184
23185 PR c/82210
23186 * stor-layout.c (place_field): For variable length fields, adjust
23187 offset_align afterwards not just based on the field's alignment,
23188 but also on the size.
23189
23190 PR middle-end/84309
23191 * match.pd (pow(C,x) -> exp(log(C)*x)): Use exp2s and log2s instead
23192 of exps and logs in the use_exp2 case.
23193
23194 2018-02-13 Jeff Law <law@redhat.com>
23195
23196 * config/rl/rl78.c (rl78_attribute_table): Fix terminator and
23197 entry for "vector".
23198
23199 * config/rl78/rl78.c (rl78_handle_func_attribute): Mark
23200 ARGS as unused.
23201
23202 2018-02-13 Alexandre Oliva <aoliva@redhat.com>
23203
23204 PR debug/84342
23205 PR debug/84319
23206 * common.opt (gas-loc-support, gas-locview-support): New.
23207 (ginline-points, ginternal-reset-location-views): New.
23208 * doc/invoke.texi: Document them. Use @itemx where intended.
23209 (gvariable-location-views): Adjust.
23210 * target.def (reset_location_view): New.
23211 * doc/tm.texi.in (DWARF2_ASM_VIEW_DEBUG_INFO): New.
23212 (TARGET_RESET_LOCATION_VIEW): New.
23213 * doc/tm.texi: Rebuilt.
23214 * dwarf2out.c (dwarf2out_default_as_loc_support): New.
23215 (dwarf2out_default_as_locview_support): New.
23216 (output_asm_line_debug_info): Use option variables.
23217 (dwarf2out_maybe_output_loclist_view_pair): Likewise.
23218 (output_loc_list): Likewise.
23219 (add_high_low_attributes): Check option variables.
23220 Don't output entry view attribute in strict mode.
23221 (gen_inlined_subroutine_die): Check option variables.
23222 (dwarf2out_inline_entry): Likewise.
23223 (init_sections_and_labels): Likewise.
23224 (dwarf2out_early_finish): Likewise.
23225 (maybe_reset_location_view): New, from...
23226 (dwarf2out_var_location): ... here. Call it.
23227 * debug.h (dwarf2out_default_as_loc_support): Declare.
23228 (dwarf2out_default_as_locview_support): Declare.
23229 * hooks.c (hook_int_rtx_insn_0): New.
23230 * hooks.h (hook_int_rtx_insn_0): Declare.
23231 * toplev.c (process_options): Take -gas-loc-support and
23232 -gas-locview-support from dwarf2out. Enable
23233 -gvariable-location-views by default only with locview
23234 assembler support. Enable -ginternal-reset-location-views by
23235 default only if the target defines the corresponding hook.
23236 Enable -ginline-points by default if location views are
23237 enabled; force it disabled if statement frontiers are
23238 disabled.
23239 * tree-inline.c (expand_call_inline): Check option variables.
23240 * tree-ssa-live.c (remove_unused_scope_block_p): Likewise.
23241
23242 2018-02-13 Richard Sandiford <richard.sandiford@linaro.org>
23243
23244 PR tree-optimization/84321
23245 * tree-vrp.c (intersect_range_with_nonzero_bits): Fix VR_ANTI_RANGE
23246 handling. Also check whether the anti-range contains any values
23247 that satisfy the mask; switch to a VR_RANGE if not.
23248
23249 2018-02-13 Paolo Bonzini <bonzini@gnu.org>
23250
23251 PR sanitizer/84340
23252 * internal-fn.def (ASAN_CHECK, ASAN_MARK): Revert changes to fnspec.
23253
23254 2018-02-13 Martin Jambor <mjambor@suse.cz>
23255
23256 PR c++/83990
23257 * ipa-param-manipulation.c (ipa_modify_call_arguments): Use location
23258 of call statements, also set location of a load to a temporary.
23259
23260 2018-02-13 Sebastian Perta <sebastian.perta@renesas.com>
23261
23262 * config/rl78/rl78.c (add_vector_labels): New function.
23263 * config/rl78/rl78.c (rl78_handle_vector_attribute): New function.
23264 * config/rl78/rl78.c (rl78_start_function): Call add_vector_labels.
23265 * config/rl78/rl78.c (rl78_handle_func_attribute): Removed the assert
23266 which checks that no arguments are passed.
23267 * config/rl78/rl78.c (rl78_attribute_table): Add "vector" attribute.
23268 * doc/extend.texi: Documentation for the new attribute.
23269
23270 2018-02-13 Andreas Schwab <schwab@suse.de>
23271
23272 * config/riscv/linux.h (CPP_SPEC): Define.
23273
23274 2018-02-13 Jakub Jelinek <jakub@redhat.com>
23275
23276 PR target/84335
23277 * config/i386/i386.c (ix86_init_mmx_sse_builtins): Pass
23278 OPTION_MASK_ISA_AES | OPTION_MASK_ISA_SSE2 instead of
23279 OPTION_MASK_ISA_AES as first argument to def_builtin_const
23280 for AES builtins. Pass OPTION_MASK_ISA_PCLMUL | OPTION_MASK_ISA_SSE2
23281 instead of OPTION_MASK_ISA_PCLMUL as first argument to
23282 def_builtin_const for __builtin_ia32_pclmulqdq128 builtin.
23283 * config/i386/wmmintrin.h: If __SSE2__ is not defined, enable it
23284 temporarily for AES and PCLMUL builtins.
23285
23286 PR tree-optimization/84339
23287 * gimple-fold.c (get_range_strlen): Set *FLEXP to true when handling
23288 ARRAY_REF where first operand is array_at_struct_end_p COMPONENT_REF.
23289 Formatting fixes.
23290
23291 PR middle-end/84309
23292 * match.pd (pow(C,x) -> exp(log(C)*x)): Optimize instead into
23293 exp2(log2(C)*x) if C is a power of 2 and c99 runtime is available.
23294 * generic-match-head.c (canonicalize_math_after_vectorization_p): New
23295 inline function.
23296 * gimple-match-head.c (canonicalize_math_after_vectorization_p): New
23297 inline function.
23298 * omp-simd-clone.h: New file.
23299 * omp-simd-clone.c: Include omp-simd-clone.h.
23300 (expand_simd_clones): No longer static.
23301 * tree-vect-patterns.c: Include fold-const-call.h, attribs.h,
23302 cgraph.h and omp-simd-clone.h.
23303 (vect_recog_pow_pattern): Optimize pow(C,x) to exp(log(C)*x).
23304 (vect_recog_widen_shift_pattern): Formatting fix.
23305 (vect_pattern_recog_1): Don't check optab for calls.
23306
23307 PR target/84336
23308 * config/i386/sse.md (<avx512>_vpermi2var<mode>3_mask): Force
23309 operands[2] into a REG before using gen_lowpart on it.
23310
23311 2018-02-12 Jeff Law <law@redhat.com>
23312
23313 PR target/83760
23314 * config/sh/sh.c (find_barrier): Consider a sibling call
23315 a barrier as well.
23316
23317 * cse.c (try_back_substitute_reg): Move any REG_ARGS_SIZE note when
23318 successfully back substituting a reg.
23319
23320 2018-02-12 Richard Biener <rguenther@suse.de>
23321
23322 PR tree-optimization/84037
23323 * tree-vect-slp.c (vect_analyze_slp_cost): Add visited
23324 parameter, move visited init to caller.
23325 (vect_slp_analyze_operations): Separate cost from validity
23326 check, initialize visited once for all instances.
23327 (vect_schedule_slp): Analyze map to CSE vectorized nodes once
23328 for all instances.
23329 * tree-vect-stmts.c (vect_model_simple_cost): Make early
23330 out an assert.
23331 (vect_model_promotion_demotion_cost): Likewise.
23332 (vectorizable_bswap): Guard cost modeling with !slp_node
23333 instead of !PURE_SLP_STMT to avoid double-counting on hybrid
23334 SLP stmts.
23335 (vectorizable_call): Likewise.
23336 (vectorizable_conversion): Likewise.
23337 (vectorizable_assignment): Likewise.
23338 (vectorizable_shift): Likewise.
23339 (vectorizable_operation): Likewise.
23340 (vectorizable_store): Likewise.
23341 (vectorizable_load): Likewise.
23342 (vectorizable_condition): Likewise.
23343 (vectorizable_comparison): Likewise.
23344
23345 2018-02-12 Paolo Bonzini <bonzini@gnu.org>
23346
23347 PR sanitizer/84307
23348 * internal-fn.def (ASAN_CHECK): Fix fnspec to account for return value.
23349 (ASAN_MARK): Fix fnspec to account for return value, change pointer
23350 argument from 'R' to 'W' so that the pointed-to datum is clobbered.
23351
23352 2018-02-08 Jan Hubicka <hubicka@ucw.cz>
23353
23354 PR middle-end/83665
23355 * params.def (inline-min-speedup): Increase from 8 to 15.
23356 (max-inline-insns-auto): Decrease from 40 to 30.
23357 * ipa-split.c (consider_split): Add some buffer for function to
23358 be considered inlining candidate.
23359 * invoke.texi (max-inline-insns-auto, inline-min-speedup): UPdate
23360 default values.
23361
23362 2018-02-12 Richard Biener <rguenther@suse.de>
23363
23364 PR tree-optimization/84037
23365 * tree-vect-slp.c (vect_build_slp_tree_2): Try swapping the
23366 matched stmts if we cannot swap the non-matched ones.
23367
23368 2018-02-12 Olga Makhotina <olga.makhotina@intel.com>
23369
23370 * config/i386/avx512fintrin.h (_mm_mask_scalef_round_sd,
23371 _mm_maskz_scalef_round_sd, _mm_mask_scalef_round_ss,
23372 _mm_maskz_scalef_round_ss): New intrinsics.
23373 (__builtin_ia32_scalefsd_round, __builtin_ia32_scalefss_round): Fix.
23374 * config/i386/i386-builtin.def (__builtin_ia32_scalefsd_round,
23375 __builtin_ia32_scalefss_round): Remove.
23376 (__builtin_ia32_scalefsd_mask_round,
23377 __builtin_ia32_scalefss_mask_round): New intrinsics.
23378 * config/i386/sse.md (vmscalef<mode><round_name>): Renamed to ...
23379 (vmscalef<mode><mask_scalar_name><round_scalar_name>): ... this.
23380 ((match_operand:VF_128 2 "<round_nimm_predicate>"
23381 "<round_constraint>")): Changed to ...
23382 ((match_operand:VF_128 2 "<round_scalar_nimm_predicate>"
23383 "<round_scalar_constraint>")): ... this.
23384 ("vscalef<ssescalarmodesuffix>\t{<round_op3>%2, %1, %0|
23385 %0, %1, %2<round_op3>}"): Changed to ...
23386 ("vscalef<ssescalarmodesuffix>\t{<round_scalar_mask_op3>%2, %1,
23387 %0<mask_scalar_operand3>|%0<mask_scalar_operand3>, %1,
23388 %2<round_scalar_mask_op3>}"): ... this.
23389 * config/i386/subst.md (round_scalar_nimm_predicate): New.
23390
23391 2018-02-12 Olga Makhotina <olga.makhotina@intel.com>
23392
23393 * config/i386/avx512fintrin.h (_mm_mask_sqrt_round_sd)
23394 (_mm_maskz_sqrt_round_sd, _mm_mask_sqrt_round_ss)
23395 (_mm_maskz_sqrt_round_ss): New intrinsics.
23396 (__builtin_ia32_sqrtsd_round, __builtin_ia32_sqrtss_round): Remove.
23397 (__builtin_ia32_sqrtsd_mask_round)
23398 (__builtin_ia32_sqrtss_mask_round): New builtins.
23399 * config/i386/i386-builtin.def (__builtin_ia32_sqrtsd_round)
23400 (__builtin_ia32_sqrtss_round): Remove.
23401 (__builtin_ia32_sqrtsd_mask_round)
23402 (__builtin_ia32_sqrtss_mask_round): New builtins.
23403 * config/i386/sse.md (vmsqrt<mode>2<round_name>): Renamed to ...
23404 (vmsqrt<mode>2<mask_scalar_name><round_scalar_name>): ... this.
23405 ((match_operand:VF_128 1 "vector_operand"
23406 "xBm,<round_constraint>")): Changed to ...
23407 ((match_operand:VF_128 1 "vector_operand"
23408 "xBm,<round_scalar_constraint>")): ... this.
23409 (vsqrt<ssescalarmodesuffix>\t{<round_op3>%1, %2, %0|
23410 %0, %2, %<iptr>1<round_op3>}): Changed to ...
23411 (vsqrt<ssescalarmodesuffix>\t{<round_scalar_mask_op3>%1, %2,
23412 %0<mask_scalar_operand3>|%0<mask_scalar_operand3>, %2,
23413 %<iptr>1<round_scalar_mask_op3>}): ... this.
23414 ((set_attr "prefix" "<round_prefix>")): Changed to ...
23415 ((set_attr "prefix" "<round_scalar_prefix>")): ... this.
23416
23417 2018-02-11 Steven Munroe <munroesj@gcc.gnu.org>
23418
23419 PR target/84266
23420 * config/rs6000/mmintrin.h (_mm_cmpeq_pi32 [_ARCH_PWR9]):
23421 Cast vec_cmpeq result to correct type.
23422 * config/rs6000/mmintrin.h (_mm_cmpgt_pi32 [_ARCH_PWR9]):
23423 Cast vec_cmpgt result to correct type.
23424
23425 2018-02-11 Alexandre Oliva <aoliva@redhat.com>
23426
23427 * final.c (final_scan_insn_1): Renamed from...
23428 (final_scan_insn): ... this. New wrapper, to recover
23429 seen from the outermost call in recursive ones.
23430 * config/sparc/sparc.c (output_return): Drop seen from call.
23431 (output_sibcall): Likewise.
23432 * config/visium/visium.c (output_branch): Likewise.
23433
23434 2018-02-10 John David Anglin <danglin@gcc.gnu.org>
23435
23436 * config/pa/pa.c (hppa_profile_hook): Mark SYMBOL_REF for _mcount as
23437 function label.
23438
23439 2018-02-10 Alan Modra <amodra@gmail.com>
23440
23441 PR target/84300
23442 * config/rs6000/rs6000.md (split_stack_return): Remove (use ..).
23443 Specify LR as an input.
23444
23445 2018-02-10 Jakub Jelinek <jakub@redhat.com>
23446
23447 PR sanitizer/83987
23448 * omp-low.c (maybe_remove_omp_member_access_dummy_vars,
23449 remove_member_access_dummy_vars): New functions.
23450 (lower_omp_for, lower_omp_taskreg, lower_omp_target,
23451 lower_omp_1, execute_lower_omp): Use them.
23452
23453 PR rtl-optimization/84308
23454 * shrink-wrap.c (spread_components): Release todo vector.
23455
23456 2018-02-09 Vladimir Makarov <vmakarov@redhat.com>
23457
23458 PR rtl-optimization/57193
23459 * ira-color.c (struct allocno_color_data): Add member
23460 conflict_allocno_hard_prefs.
23461 (update_conflict_allocno_hard_prefs): New.
23462 (bucket_allocno_compare_func): Add a preference based on
23463 conflict_allocno_hard_prefs.
23464 (push_allocno_to_stack): Update conflict_allocno_hard_prefs.
23465 (color_allocnos): Remove a dead code. Initiate
23466 conflict_allocno_hard_prefs. Call update_costs_from_prefs.
23467
23468 2018-02-09 Jakub Jelinek <jakub@redhat.com>
23469
23470 PR target/84226
23471 * config/rs6000/vsx.md (p9_xxbrq_v16qi): Change input operand
23472 constraint from =wa to wa. Avoid a subreg on the output operand,
23473 instead use a pseudo and subreg it in a move.
23474 (p9_xxbrd_<mode>): Changed to ...
23475 (p9_xxbrd_v2di): ... this insn, without VSX_D iterator.
23476 (p9_xxbrd_v2df): New expander.
23477 (p9_xxbrw_<mode>): Changed to ...
23478 (p9_xxbrw_v4si): ... this insn, without VSX_W iterator.
23479 (p9_xxbrw_v4sf): New expander.
23480
23481 2018-02-09 Sebastian Perta <sebastian.perta@renesas.com>
23482
23483 * config/rx/rx.md (movsicc): Update expander to be matched by GCC.
23484
23485 2018-02-09 Peter Bergner <bergner@vnet.ibm.com>
23486
23487 PR target/83926
23488 * config/rs6000/vsx.md (vsx_mul_v2di): Handle generating a 64-bit
23489 multiply in 32-bit mode.
23490 (vsx_div_v2di): Handle generating a 64-bit signed divide in 32-bit mode.
23491 (vsx_udiv_v2di): Handle generating a 64-bit unsigned divide in 32-bit
23492 mode.
23493
23494 2018-02-09 Sebastian Perta <sebastian.perta@renesas.com>
23495
23496 * config/rx/constraints.md (CALL_OP_SYMBOL_REF): Added new constraint
23497 to allow or block "symbol_ref" depending on the value of TARGET_JSR.
23498 * config/rx/rx.md (call_internal): Use CALL_OP_SYMBOL_REF.
23499 * config/rx/rx.md (call_value_internal): Use CALL_OP_SYMBOL_REF.
23500
23501 2018-02-09 Pierre-Marie de Rodat <derodat@adacore.com>
23502
23503 PR lto/84213
23504 * dwarf2out.c (is_trivial_indirect_ref): New function.
23505 (dwarf2out_late_global_decl): Do not generate a location
23506 attribute for variables that have a non-trivial DECL_VALUE_EXPR
23507 and that are not defined in the current unit.
23508
23509 2018-02-09 Eric Botcazou <ebotcazou@adacore.com>
23510
23511 * optabs.c (prepare_cmp_insn): Try harder to emit a direct comparison
23512 instead of a libcall for UNORDERED.
23513
23514 2018-02-09 Tamar Christina <tamar.christina@arm.com>
23515
23516 PR target/82641
23517 * config/arm/arm-c.c (arm_cpu_builtins): Un-define __ARM_FEATURE_LDREX,
23518 __ARM_ARCH_PROFILE, __ARM_ARCH_ISA_THUMB, __ARM_FP and __ARM_NEON_FP.
23519
23520 2018-02-09 Andreas Krebbel <krebbel@linux.vnet.ibm.com>
23521
23522 PR target/PR84295
23523 * config/s390/s390.c (s390_set_current_function): Invoke
23524 s390_indirect_branch_settings also if fndecl didn't change.
23525
23526 2018-02-09 Alexandre Oliva <aoliva@redhat.com>
23527
23528 * config/rs6000/rs6000.md (blockage): Set length to zero.
23529
23530 2018-02-09 Eric Botcazou <ebotcazou@adacore.com>
23531
23532 * expr.c (optimize_bitfield_assignment_op): Remove obsolete assertion.
23533
23534 2018-02-09 Jakub Jelinek <jakub@redhat.com>
23535
23536 PR sanitizer/84285
23537 * gcc.c (STATIC_LIBASAN_LIBS, STATIC_LIBTSAN_LIBS,
23538 STATIC_LIBLSAN_LIBS, STATIC_LIBUBSAN_LIBS): Handle -static like
23539 -static-lib*san.
23540
23541 PR debug/84252
23542 * var-tracking.c (vt_add_function_parameter): Punt for non-onepart
23543 PARALLEL incoming that failed vt_get_decl_and_offset check.
23544
23545 PR middle-end/84237
23546 * output.h (bss_initializer_p): Add NAMED argument, defaulted to false.
23547 * varasm.c (bss_initializer_p): Add NAMED argument, if true, ignore
23548 TREE_READONLY bit.
23549 (get_variable_section): For decls in named .bss* sections pass true as
23550 second argument to bss_initializer_p.
23551
23552 2018-02-09 Marek Polacek <polacek@redhat.com>
23553 Jakub Jelinek <jakub@redhat.com>
23554
23555 PR c++/83659
23556 * fold-const.c (fold_indirect_ref_1): Use VECTOR_TYPE_P macro.
23557 Formatting fixes. Verify first that tree_fits_poly_int64_p (op01).
23558 Sync some changes from cxx_fold_indirect_ref.
23559
23560 2018-02-09 Alexandre Oliva <aoliva@redhat.com>
23561
23562 * cfgexpand.c (expand_gimple_basic_block): Handle inline entry
23563 markers.
23564 * dwarf2out.c (dwarf2_debug_hooks): Enable inline_entry hook.
23565 (BLOCK_INLINE_ENTRY_LABEL): New.
23566 (dwarf2out_var_location): Disregard inline entry markers.
23567 (inline_entry_data): New struct.
23568 (inline_entry_data_hasher): New hashtable type.
23569 (inline_entry_data_hasher::hash): New.
23570 (inline_entry_data_hasher::equal): New.
23571 (inline_entry_data_table): New variable.
23572 (add_high_low_attributes): Add DW_AT_entry_pc and
23573 DW_AT_GNU_entry_view attributes if a pending entry is found
23574 in inline_entry_data_table. Add old entry_pc attribute only
23575 if debug nonbinding markers are disabled.
23576 (gen_inlined_subroutine_die): Set BLOCK_DIE if nonbinding
23577 markers are enabled.
23578 (block_within_block_p, dwarf2out_inline_entry): New.
23579 (dwarf2out_finish): Check that no entries remained in
23580 inline_entry_data_table.
23581 * final.c (reemit_insn_block_notes): Handle inline entry notes.
23582 (final_scan_insn, notice_source_line): Likewise.
23583 (rest_of_clean_state): Skip inline entry markers.
23584 * gimple-pretty-print.c (dump_gimple_debug): Handle inline entry
23585 markers.
23586 * gimple.c (gimple_build_debug_inline_entry): New.
23587 * gimple.h (enum gimple_debug_subcode): Add
23588 GIMPLE_DEBUG_INLINE_ENTRY.
23589 (gimple_build_debug_inline_entry): Declare.
23590 (gimple_debug_inline_entry_p): New.
23591 (gimple_debug_nonbind_marker_p): Adjust.
23592 * insn-notes.def (INLINE_ENTRY): New.
23593 * print-rtl.c (rtx_writer::print_rtx_operand_code_0): Handle
23594 inline entry marker notes.
23595 (print_insn): Likewise.
23596 * rtl.h (NOTE_MARKER_P): Add INLINE_ENTRY support.
23597 (INSN_DEBUG_MARKER_KIND): Likewise.
23598 (GEN_RTX_DEBUG_MARKER_INLINE_ENTRY_PAT): New.
23599 * tree-inline.c (expand_call_inline): Build and insert
23600 debug_inline_entry stmt.
23601 * tree-ssa-live.c (remove_unused_scope_block_p): Preserve
23602 inline entry blocks early, if nonbind markers are enabled.
23603 (dump_scope_block): Dump fragment info.
23604 * var-tracking.c (reemit_marker_as_note): Handle inline entry note.
23605 * doc/gimple.texi (gimple_debug_inline_entry_p): New.
23606 (gimple_build_debug_inline_entry): New.
23607 * doc/invoke.texi (gstatement-frontiers, gno-statement-frontiers):
23608 Enable/disable inline entry points too.
23609 * doc/rtl.texi (NOTE_INSN_INLINE_ENTRY): New.
23610 (DEBUG_INSN): Describe inline entry markers.
23611
23612 * common.opt (gvariable-location-views): New.
23613 (gvariable-location-views=incompat5): New.
23614 * config.in: Rebuilt.
23615 * configure: Rebuilt.
23616 * configure.ac: Test assembler for view support.
23617 * dwarf2asm.c (dw2_asm_output_symname_uleb128): New.
23618 * dwarf2asm.h (dw2_asm_output_symname_uleb128): Declare.
23619 * dwarf2out.c (var_loc_view): New typedef.
23620 (struct dw_loc_list_struct): Add vl_symbol, vbegin, vend.
23621 (dwarf2out_locviews_in_attribute): New.
23622 (dwarf2out_locviews_in_loclist): New.
23623 (dw_val_equal_p): Compare val_view_list of dw_val_class_view_lists.
23624 (enum dw_line_info_opcode): Add LI_adv_address.
23625 (struct dw_line_info_table): Add view.
23626 (RESET_NEXT_VIEW, RESETTING_VIEW_P): New macros.
23627 (DWARF2_ASM_VIEW_DEBUG_INFO): Define default.
23628 (zero_view_p): New variable.
23629 (ZERO_VIEW_P): New macro.
23630 (output_asm_line_debug_info): New.
23631 (struct var_loc_node): Add view.
23632 (add_AT_view_list, AT_loc_list): New.
23633 (add_var_loc_to_decl): Add view param. Test it against last.
23634 (new_loc_list): Add view params. Record them.
23635 (AT_loc_list_ptr): Handle loc and view lists.
23636 (view_list_to_loc_list_val_node): New.
23637 (print_dw_val): Handle dw_val_class_view_list.
23638 (size_of_die): Likewise.
23639 (value_format): Likewise.
23640 (loc_list_has_views): New.
23641 (gen_llsym): Set vl_symbol too.
23642 (maybe_gen_llsym, skip_loc_list_entry): New.
23643 (dwarf2out_maybe_output_loclist_view_pair): New.
23644 (output_loc_list): Output view list or entries too.
23645 (output_view_list_offset): New.
23646 (output_die): Handle dw_val_class_view_list.
23647 (output_dwarf_version): New.
23648 (output_compilation_unit_header): Use it.
23649 (output_skeleton_debug_sections): Likewise.
23650 (output_rnglists, output_line_info): Likewise.
23651 (output_pubnames, output_aranges): Update version comments.
23652 (output_one_line_info_table): Output view numbers in asm comments.
23653 (dw_loc_list): Determine current endview, pass it to new_loc_list.
23654 Call maybe_gen_llsym.
23655 (loc_list_from_tree_1): Adjust.
23656 (add_AT_location_description): Create view list attribute if
23657 needed, check it's absent otherwise.
23658 (convert_cfa_to_fb_loc_list): Adjust.
23659 (maybe_emit_file): Call output_asm_line_debug_info for test.
23660 (dwarf2out_var_location): Reset views as needed. Precompute
23661 add_var_loc_to_decl args. Call get_attr_min_length only if we have the
23662 attribute. Set view.
23663 (new_line_info_table): Reset next view.
23664 (set_cur_line_info_table): Call output_asm_line_debug_info for test.
23665 (dwarf2out_source_line): Likewise. Output view resets and labels to
23666 the assembler, or select appropriate line info opcodes.
23667 (prune_unused_types_walk_attribs): Handle dw_val_class_view_list.
23668 (optimize_string_length): Catch it. Adjust.
23669 (resolve_addr): Copy vl_symbol along with ll_symbol. Handle
23670 dw_val_class_view_list, and remove it if no longer needed.
23671 (hash_loc_list): Hash view numbers.
23672 (loc_list_hasher::equal): Compare them.
23673 (optimize_location_lists): Check whether a view list symbol is
23674 needed, and whether the locview attribute is present, and
23675 whether they match. Remove the locview attribute if no longer
23676 needed.
23677 (index_location_lists): Call skip_loc_list_entry for test.
23678 (dwarf2out_finish): Call output_asm_line_debug_info for test.
23679 Use output_dwarf_version.
23680 * dwarf2out.h (enum dw_val_class): Add dw_val_class_view_list.
23681 (struct dw_val_node): Add val_view_list.
23682 * final.c (SEEN_NEXT_VIEW): New.
23683 (set_next_view_needed): New.
23684 (clear_next_view_needed): New.
23685 (maybe_output_next_view): New.
23686 (final_start_function): Rename to...
23687 (final_start_function_1): ... this. Take pointer to FIRST,
23688 add SEEN parameter. Emit param bindings in the initial view.
23689 (final_start_function): Reintroduce SEEN-less interface.
23690 (final): Rename to...
23691 (final_1): ... this. Take SEEN parameter. Output final pending
23692 next view at the end.
23693 (final): Reintroduce seen-less interface.
23694 (final_scan_insn): Output pending next view before switching
23695 sections or ending a block. Mark the next view as needed when
23696 outputting variable locations. Notify debug backend of section
23697 changes, and of location view changes.
23698 (rest_of_handle_final): Adjust.
23699 * toplev.c (process_options): Autodetect value for debug variable
23700 location views option. Warn on incompat5 without -gdwarf-5.
23701 * doc/invoke.texi (gvariable-location-views): New.
23702 (gvariable-location-views=incompat5): New.
23703 (gno-variable-location-views): New.
23704
23705 2018-02-08 David Malcolm <dmalcolm@redhat.com>
23706
23707 PR tree-optimization/84136
23708 * tree-cfg.c (find_taken_edge_computed_goto): Remove assertion
23709 that the result of find_edge is non-NULL.
23710
23711 2018-02-08 Sergey Shalnov <sergey.shalnov@intel.com>
23712
23713 PR target/83008
23714 * config/i386/x86-tune-costs.h (skylake_cost): Fix cost of
23715 storing integer register in SImode. Fix cost of 256 and 512
23716 byte aligned SSE register store.
23717
23718 2018-02-08 Sergey Shalnov <sergey.shalnov@intel.com>
23719
23720 * config/i386/i386.c (ix86_multiplication_cost): Fix
23721 multiplication cost for TARGET_AVX512DQ.
23722
23723 2018-02-08 Marek Polacek <polacek@redhat.com>
23724
23725 PR tree-optimization/84238
23726 * tree-ssa-strlen.c (maybe_diag_stxncpy_trunc): Verify the result of
23727 get_range_strlen.
23728
23729 2018-02-08 Richard Sandiford <richard.sandiford@linaro.org>
23730
23731 PR tree-optimization/84265
23732 * tree-vect-stmts.c (vectorizable_store): Don't treat
23733 VMAT_CONTIGUOUS accesses as grouped.
23734 (vectorizable_load): Likewise.
23735
23736 2018-02-08 Richard Sandiford <richard.sandiford@linaro.org>
23737
23738 PR tree-optimization/81635
23739 * wide-int.h (wi::round_down_for_mask, wi::round_up_for_mask): Declare.
23740 * wide-int.cc (wi::round_down_for_mask, wi::round_up_for_mask)
23741 (test_round_for_mask): New functions.
23742 (wide_int_cc_tests): Call test_round_for_mask.
23743 * tree-vrp.h (intersect_range_with_nonzero_bits): Declare.
23744 * tree-vrp.c (intersect_range_with_nonzero_bits): New function.
23745 * tree-data-ref.c (split_constant_offset_1): Use it to refine the
23746 range returned by get_range_info.
23747
23748 2018-02-08 Jan Hubicka <hubicka@ucw.cz>
23749
23750 PR ipa/81360
23751 * cgraph.h (symtab_node::output_to_lto_symbol_table_p): Declare
23752 * symtab.c: Include builtins.h
23753 (symtab_node::output_to_lto_symbol_table_p): Move here
23754 from lto-streamer-out.c:output_symbol_p.
23755 * lto-streamer-out.c (write_symbol): Turn early exit to assert.
23756 (output_symbol_p): Move all logic to symtab.c
23757 (produce_symtab): Update.
23758
23759 2018-02-08 Andreas Krebbel <krebbel@linux.vnet.ibm.com>
23760
23761 * config/s390/s390-opts.h (enum indirect_branch): Define.
23762 * config/s390/s390-protos.h (s390_return_addr_from_memory)
23763 (s390_indirect_branch_via_thunk)
23764 (s390_indirect_branch_via_inline_thunk): Add function prototypes.
23765 (enum s390_indirect_branch_type): Define.
23766 * config/s390/s390.c (struct s390_frame_layout, struct
23767 machine_function): Remove.
23768 (indirect_branch_prez10thunk_mask, indirect_branch_z10thunk_mask)
23769 (indirect_branch_table_label_no, indirect_branch_table_name):
23770 Define variables.
23771 (INDIRECT_BRANCH_NUM_OPTIONS): Define macro.
23772 (enum s390_indirect_branch_option): Define.
23773 (s390_return_addr_from_memory): New function.
23774 (s390_handle_string_attribute): New function.
23775 (s390_attribute_table): Add new attribute handler.
23776 (s390_execute_label): Handle UNSPEC_EXECUTE_JUMP patterns.
23777 (s390_indirect_branch_via_thunk): New function.
23778 (s390_indirect_branch_via_inline_thunk): New function.
23779 (s390_function_ok_for_sibcall): When jumping via thunk disallow
23780 sibling call optimization for non z10 compiles.
23781 (s390_emit_call): Force indirect branch target to be a single
23782 register. Add r1 clobber for non-z10 compiles.
23783 (s390_emit_epilogue): Emit return jump via return_use expander.
23784 (s390_reorg): Handle JUMP_INSNs as execute targets.
23785 (s390_option_override_internal): Perform validity checks for the
23786 new command line options.
23787 (s390_indirect_branch_attrvalue): New function.
23788 (s390_indirect_branch_settings): New function.
23789 (s390_set_current_function): Invoke s390_indirect_branch_settings.
23790 (s390_output_indirect_thunk_function): New function.
23791 (s390_code_end): Implement target hook.
23792 (s390_case_values_threshold): Implement target hook.
23793 (TARGET_ASM_CODE_END, TARGET_CASE_VALUES_THRESHOLD): Define target
23794 macros.
23795 * config/s390/s390.h (struct s390_frame_layout)
23796 (struct machine_function): Move here from s390.c.
23797 (TARGET_INDIRECT_BRANCH_NOBP_RET)
23798 (TARGET_INDIRECT_BRANCH_NOBP_JUMP)
23799 (TARGET_INDIRECT_BRANCH_NOBP_JUMP_THUNK)
23800 (TARGET_INDIRECT_BRANCH_NOBP_JUMP_INLINE_THUNK)
23801 (TARGET_INDIRECT_BRANCH_NOBP_CALL)
23802 (TARGET_DEFAULT_INDIRECT_BRANCH_TABLE)
23803 (TARGET_INDIRECT_BRANCH_THUNK_NAME_EXRL)
23804 (TARGET_INDIRECT_BRANCH_THUNK_NAME_EX)
23805 (TARGET_INDIRECT_BRANCH_TABLE): Define macros.
23806 * config/s390/s390.md (UNSPEC_EXECUTE_JUMP)
23807 (INDIRECT_BRANCH_THUNK_REGNUM): Define constants.
23808 (mnemonic attribute): Add values which aren't recognized
23809 automatically.
23810 ("*cjump_long", "*icjump_long", "*basr", "*basr_r"): Disable
23811 pattern for branch conversion. Fix mnemonic attribute.
23812 ("*c<code>", "*sibcall_br", "*sibcall_value_br", "*return"): Emit
23813 indirect branch via thunk if requested.
23814 ("indirect_jump", "<code>"): Expand patterns for branch conversion.
23815 ("*indirect_jump"): Disable for branch conversion using out of
23816 line thunks.
23817 ("indirect_jump_via_thunk<mode>_z10")
23818 ("indirect_jump_via_thunk<mode>")
23819 ("indirect_jump_via_inlinethunk<mode>_z10")
23820 ("indirect_jump_via_inlinethunk<mode>", "*casesi_jump")
23821 ("casesi_jump_via_thunk<mode>_z10", "casesi_jump_via_thunk<mode>")
23822 ("casesi_jump_via_inlinethunk<mode>_z10")
23823 ("casesi_jump_via_inlinethunk<mode>", "*basr_via_thunk<mode>_z10")
23824 ("*basr_via_thunk<mode>", "*basr_r_via_thunk_z10")
23825 ("*basr_r_via_thunk", "return<mode>_prez10"): New pattern.
23826 ("*indirect2_jump"): Disable for branch conversion.
23827 ("casesi_jump"): Turn into expander and expand patterns for branch
23828 conversion.
23829 ("return_use"): New expander.
23830 ("*return"): Emit return via thunk and rename it to ...
23831 ("*return<mode>"): ... this one.
23832 * config/s390/s390.opt: Add new options and and enum for the
23833 option values.
23834
23835 2018-02-08 Richard Sandiford <richard.sandiford@linaro.org>
23836
23837 * lra-constraints.c (match_reload): Unconditionally use
23838 gen_lowpart_SUBREG, rather than selecting between that
23839 and equivalent gen_rtx_SUBREG code.
23840
23841 2018-02-08 Richard Biener <rguenther@suse.de>
23842
23843 PR tree-optimization/84233
23844 * tree-ssa-phiprop.c (propagate_with_phi): Use separate
23845 changed flag instead of boguously re-using phi_inserted.
23846
23847 2018-02-08 Martin Jambor <mjambor@suse.cz>
23848
23849 * hsa-gen.c (get_symbol_for_decl): Set program allocation for
23850 static local variables.
23851
23852 2018-02-08 Richard Biener <rguenther@suse.de>
23853
23854 PR tree-optimization/84278
23855 * tree-vect-stmts.c (vectorizable_store): When looking for
23856 smaller vector types to perform grouped strided loads/stores
23857 make sure the mode is supported by the target.
23858 (vectorizable_load): Likewise.
23859
23860 2018-02-08 Wilco Dijkstra <wdijkstr@arm.com>
23861
23862 * config/aarch64/aarch64.c (aarch64_components_for_bb):
23863 Increase LDP/STP opportunities by adding adjacent callee-saves.
23864
23865 2018-02-08 Wilco Dijkstra <wdijkstr@arm.com>
23866
23867 PR rtl-optimization/84068
23868 PR rtl-optimization/83459
23869 * haifa-sched.c (rank_for_schedule): Fix SCHED_PRESSURE_MODEL sorting.
23870
23871 2018-02-08 Aldy Hernandez <aldyh@redhat.com>
23872
23873 PR tree-optimization/84224
23874 * gimple-ssa-warn-alloca.c (pass_walloca::execute): Remove assert.
23875 * calls.c (gimple_alloca_call_p): Only return TRUE when we have
23876 non-zero arguments.
23877
23878 2018-02-07 Iain Sandoe <iain@codesourcery.com>
23879
23880 PR target/84113
23881 * config/rs6000/altivec.md (*restore_world): Remove LR use.
23882 * config/rs6000/predicates.md (restore_world_operation): Adjust op
23883 count, remove one USE.
23884
23885 2018-02-07 Michael Meissner <meissner@linux.vnet.ibm.com>
23886
23887 * doc/install.texi (Configuration): Document the
23888 --with-long-double-format={ibm,ieee} PowerPC configuration
23889 options.
23890
23891 PR target/84154
23892 * config/rs6000/rs6000.md (fix_trunc<SFDF:mode><QHI:mode>2):
23893 Convert from define_expand to be define_insn_and_split. Rework
23894 float/double/_Float128 conversions to QI/HI/SImode to work with
23895 both ISA 2.07 (power8) or ISA 3.0 (power9). Fix regression where
23896 conversions to QI/HImode types did a store and then a load to
23897 truncate the value. For conversions to VSX registers, don't split
23898 the insn, instead emit the code directly. Use the code iterator
23899 any_fix to combine signed and unsigned conversions.
23900 (fix<uns>_trunc<SFDF:mode>si2_p8): Likewise.
23901 (fixuns_trunc<SFDF:mode><QHI:mode>2): Likewise.
23902 (fix_trunc<IEEE128:mode><QHI:mode>2): Likewise.
23903 (fix<uns>_trunc<SFDF:mode><QHI:mode>2): Likewise.
23904 (fix_<mode>di2_hw): Likewise.
23905 (fixuns_<mode>di2_hw): Likewise.
23906 (fix_<mode>si2_hw): Likewise.
23907 (fixuns_<mode>si2_hw): Likewise.
23908 (fix<uns>_<IEEE128:mode><SDI:mode>2_hw): Likewise.
23909 (fix<uns>_trunc<IEEE128:mode><QHI:mode>2): Likewise.
23910 (fctiw<u>z_<mode>_smallint): Rename fctiw<u>z_<mode>_smallint to
23911 fix<uns>_trunc<SFDF:mode>si2_p8.
23912 (fix_trunc<SFDF:mode><QHI:mode>2_internal): Delete, no longer used.
23913 (fixuns_trunc<SFDF:mode><QHI:mode>2_internal): Likewise.
23914 (fix<uns>_<mode>_mem): Likewise.
23915 (fctiw<u>z_<mode>_mem): Likewise.
23916 (fix<uns>_<mode>_mem): Likewise.
23917 (fix<uns>_trunc<SFDF:mode><QHSI:mode>2_mem): On ISA 3.0, prevent
23918 the register allocator from doing a direct move to the GPRs to do
23919 a store, and instead use the ISA 3.0 store byte/half-word from
23920 vector register instruction. For IEEE 128-bit floating point,
23921 also optimize stores of 32-bit ints.
23922 (fix<uns>_trunc<IEEE128:mode><QHSI:mode>2_mem): Likewise.
23923
23924 2018-02-07 Alan Hayward <alan.hayward@arm.com>
23925
23926 * genextract.c (push_pathstr_operand): New function to support
23927 [a-zA-Z].
23928 (walk_rtx): Call push_pathstr_operand.
23929 (print_path): Support [a-zA-Z].
23930
23931 2018-02-07 Richard Biener <rguenther@suse.de>
23932
23933 PR tree-optimization/84037
23934 * tree-vectorizer.h (struct _loop_vec_info): Add ivexpr_map member.
23935 (cse_and_gimplify_to_preheader): Declare.
23936 (vect_get_place_in_interleaving_chain): Likewise.
23937 * tree-vect-loop.c (_loop_vec_info::_loop_vec_info): Initialize
23938 ivexpr_map.
23939 (_loop_vec_info::~_loop_vec_info): Delete it.
23940 (cse_and_gimplify_to_preheader): New function.
23941 * tree-vect-slp.c (vect_get_place_in_interleaving_chain): Export.
23942 * tree-vect-stmts.c (vectorizable_store): CSE base and steps.
23943 (vectorizable_load): Likewise. For grouped stores always base
23944 the IV on the first element.
23945 * tree-vect-loop-manip.c (vect_loop_versioning): Unshare versioning
23946 condition before gimplifying.
23947
23948 2018-02-07 Jakub Jelinek <jakub@redhat.com>
23949
23950 * tree-eh.c (operation_could_trap_helper_p): Ignore honor_trapv for
23951 *DIV_EXPR and *MOD_EXPR.
23952
23953 2018-02-07 H.J. Lu <hongjiu.lu@intel.com>
23954
23955 PR target/84248
23956 * config/i386/i386.c (ix86_option_override_internal): Mask out
23957 the CF_SET bit when checking -fcf-protection.
23958
23959 2018-02-07 Tom de Vries <tom@codesourcery.com>
23960
23961 PR libgomp/84217
23962 * omp-expand.c (expand_oacc_collapse_init): Ensure diff_type is large
23963 enough.
23964
23965 2018-02-07 Richard Biener <rguenther@suse.de>
23966
23967 PR tree-optimization/84204
23968 * tree-chrec.c (chrec_fold_plus_1): Remove size limiting in
23969 this place.
23970
23971 PR tree-optimization/84205
23972 * graphite-isl-ast-to-gimple.c (binary_op_to_tree): Also
23973 special-case isl_ast_op_zdiv_r.
23974
23975 PR tree-optimization/84223
23976 * graphite-scop-detection.c (gather_bbs::before_dom_children):
23977 Only add conditions from within the region.
23978 (gather_bbs::after_dom_children): Adjust.
23979
23980 2018-02-07 Georg-Johann Lay <avr@gjlay.de>
23981
23982 PR target/84209
23983 * config/avr/avr.h (GENERAL_REGNO_P, GENERAL_REG_P): New macros.
23984 * config/avr/avr.md: Only post-reload split REG-REG moves if
23985 either register is GENERAL_REG_P.
23986
23987 2018-02-07 Jakub Jelinek <jakub@redhat.com>
23988
23989 PR tree-optimization/84235
23990 * tree-ssa-scopedtables.c
23991 (avail_exprs_stack::simplify_binary_operation): Fir MINUS_EXPR, punt
23992 if the subtraction is performed in floating point type where NaNs are
23993 honored. For *DIV_EXPR, punt for ALL_FRACT_MODE_Ps where we can't
23994 build 1. Formatting fix.
23995
23996 2018-02-06 Jakub Jelinek <jakub@redhat.com>
23997
23998 PR target/84146
23999 * config/i386/i386.c (rest_of_insert_endbranch): Only skip
24000 NOTE_INSN_CALL_ARG_LOCATION after a call, not anything else,
24001 and skip it regardless of bb boundaries. Use CALL_P macro,
24002 don't test INSN_P (insn) together with CALL_P or JUMP_P check
24003 unnecessarily, formatting fix.
24004
24005 2018-02-06 Michael Collison <michael.collison@arm.com>
24006
24007 * config/arm/thumb2.md:
24008 (*thumb2_mov_negscc): Split only if TARGET_THUMB2 && !arm_restrict_it.
24009 (*thumb_mov_notscc): Ditto.
24010
24011 2018-02-06 Michael Meissner <meissner@linux.vnet.ibm.com>
24012
24013 PR target/84154
24014 * config/rs6000/rs6000.md (su code attribute): Use "u" for
24015 unsigned_fix, not "s".
24016
24017 2018-02-06 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
24018
24019 * configure.ac (gcc_fn_eh_frame_ro): New function.
24020 (gcc_cv_as_cfi_directive): Check both 32 and 64-bit assembler for
24021 correct .eh_frame permissions.
24022 * configure: Regenerate.
24023
24024 2018-02-06 Andrew Jenner <andrew@codeourcery.com>
24025
24026 * doc/invoke.texi: Add section for the PowerPC SPE backend. Remove
24027 irrelevant options.
24028
24029 2018-02-06 Bill Schmidt <wschmidt@linux.vnet.ibm.com>
24030
24031 * config/rs6000/rs6000.c (rs6000_option_override_internal):
24032 Display warning message for -mno-speculate-indirect-jumps.
24033
24034 2018-02-06 Andrew Jenner <andrew@codesourcery.com>
24035
24036 * config/powerpcspe/powerpcspe.opt: (msimple-fpu, mfpu) Add
24037 Undocumented.
24038 * config/powerpcspe/sysv4.opt (mbit-align): Likewise.
24039
24040 2018-02-06 Aldy Hernandez <aldyh@redhat.com>
24041
24042 PR tree-optimization/84225
24043 * tree-eh.c (find_trapping_overflow): Only call
24044 operation_no_trapping_overflow when ANY_INTEGRAL_TYPE_P.
24045
24046 2018-02-06 Igor Tsimbalist <igor.v.tsimbalist@intel.com>
24047
24048 PR target/84145
24049 * config/i386/i386.c: Reimplement the check of possible options
24050 -mibt/-mshstk conbination. Change error messages.
24051 * doc/invoke.texi: Fix a typo: remove extra '='.
24052
24053 2018-02-06 Marek Polacek <polacek@redhat.com>
24054
24055 PR tree-optimization/84228
24056 * tree-ssa-strlen.c (maybe_diag_stxncpy_trunc): Skip debug statements.
24057
24058 2018-02-06 Tamar Christina <tamar.christina@arm.com>
24059
24060 PR target/82641
24061 * config/arm/arm.c (arm_print_asm_arch_directives): Record already
24062 emitted arch directives.
24063 * config/arm/arm-c.c (arm_cpu_builtins): Undefine __ARM_ARCH and
24064 __ARM_FEATURE_COPROC before changing architectures.
24065
24066 2018-02-06 Richard Biener <rguenther@suse.de>
24067
24068 * config/i386/i386.c (print_reg): Fix typo.
24069 (ix86_loop_unroll_adjust): Do not unroll beyond the original nunroll.
24070
24071 2018-02-06 Eric Botcazou <ebotcazou@adacore.com>
24072
24073 * configure: Regenerate.
24074
24075 2018-02-05 Martin Sebor <msebor@redhat.com>
24076
24077 PR tree-optimization/83369
24078 * tree-ssa-ccp.c (pass_post_ipa_warn::execute): Use %G to print
24079 inlining context.
24080
24081 2018-02-05 Martin Liska <mliska@suse.cz>
24082
24083 * doc/invoke.texi: Cherry-pick upstream r323995.
24084
24085 2018-02-05 Richard Sandiford <richard.sandiford@linaro.org>
24086
24087 * ira.c (ira_init_register_move_cost): Adjust comment.
24088
24089 2018-02-05 Martin Liska <mliska@suse.cz>
24090
24091 PR gcov-profile/84137
24092 * doc/gcov.texi: Fix typo in documentation.
24093
24094 2018-02-05 Martin Liska <mliska@suse.cz>
24095
24096 PR gcov-profile/83879
24097 * doc/gcov.texi: Document necessity of --dynamic-list-data when
24098 using dlopen functionality.
24099
24100 2018-02-05 Olga Makhotina <olga.makhotina@intel.com>
24101
24102 * config/i386/avx512dqintrin.h (_mm_mask_range_sd, _mm_maskz_range_sd,
24103 _mm_mask_range_round_sd, _mm_maskz_range_round_sd, _mm_mask_range_ss,
24104 _mm_maskz_range_ss, _mm_mask_range_round_ss,
24105 _mm_maskz_range_round_ss): New intrinsics.
24106 (__builtin_ia32_rangesd128_round)
24107 (__builtin_ia32_rangess128_round): Remove.
24108 (__builtin_ia32_rangesd128_mask_round,
24109 __builtin_ia32_rangess128_mask_round): New builtins.
24110 * config/i386/i386-builtin.def (__builtin_ia32_rangesd128_round,
24111 __builtin_ia32_rangess128_round): Remove.
24112 (__builtin_ia32_rangesd128_mask_round,
24113 __builtin_ia32_rangess128_mask_round): New builtins.
24114 * config/i386/sse.md (ranges<mode><round_saeonly_name>): Renamed to ...
24115 (ranges<mode><mask_scalar_name><round_saeonly_scalar_name>): ... this.
24116 ((match_operand:VF_128 2 "<round_saeonly_nimm_predicate>"
24117 "<round_saeonly_constraint>")): Changed to ...
24118 ((match_operand:VF_128 2 "<round_saeonly_scalar_nimm_predicate>"
24119 "<round_saeonly_scalar_constraint>")): ... this.
24120 ("vrange<ssescalarmodesuffix>\t{%3, <round_saeonly_op4>%2, %1, %0|
24121 %0, %1, %2<round_saeonly_op4>, %3}"): Changed to ...
24122 ("vrange<ssescalarmodesuffix>\t{%3, <round_saeonly_scalar_mask_op4>%2,
24123 %1, %0<mask_scalar_operand4>|%0<mask_scalar_operand4>, %1,
24124 %2<round_saeonly_scalar_mask_op4>, %3}"): ... this.
24125
24126 2018-02-02 Andrew Jenner <andrew@codesourcery.com>
24127
24128 * config/powerpcspe/powerpcspe.opt: Add Undocumented to irrelevant
24129 options.
24130 * config/powerpcspe/powerpcspe-tables.opt (rs6000_cpu_opt_value):
24131 Remove all values except native, 8540 and 8548.
24132
24133 2018-02-02 H.J. Lu <hongjiu.lu@intel.com>
24134
24135 * config/i386/i386.c (ix86_output_function_return): Pass
24136 INVALID_REGNUM, instead of -1, as invalid register number to
24137 indirect_thunk_name and output_indirect_thunk.
24138
24139 2018-02-02 Julia Koval <julia.koval@intel.com>
24140
24141 * config.gcc: Add -march=icelake.
24142 * config/i386/driver-i386.c (host_detect_local_cpu): Detect icelake.
24143 * config/i386/i386-c.c (ix86_target_macros_internal): Handle icelake.
24144 * config/i386/i386.c (processor_costs): Add m_ICELAKE.
24145 (PTA_ICELAKE, PTA_AVX512VNNI, PTA_GFNI, PTA_VAES, PTA_AVX512VBMI2,
24146 PTA_VPCLMULQDQ, PTA_RDPID, PTA_AVX512BITALG): New.
24147 (processor_target_table): Add icelake.
24148 (ix86_option_override_internal): Handle new PTAs.
24149 (get_builtin_code_for_version): Handle icelake.
24150 (M_INTEL_COREI7_ICELAKE): New.
24151 (fold_builtin_cpu): Handle icelake.
24152 * config/i386/i386.h (TARGET_ICELAKE, PROCESSOR_ICELAKE): New.
24153 * doc/invoke.texi: Add -march=icelake.
24154
24155 2018-02-02 Julia Koval <julia.koval@intel.com>
24156
24157 * config/i386/i386.c (ix86_option_override_internal): Change flags type
24158 to wide_int_bitmask.
24159 * wide-int-bitmask.h: New.
24160
24161 2018-02-02 Igor Tsimbalist <igor.v.tsimbalist@intel.com>
24162
24163 PR target/84066
24164 * config/i386/i386.md: Replace Pmode with word_mode in
24165 builtin_setjmp_setup and builtin_longjmp to support x32.
24166
24167 2018-02-01 Peter Bergner <bergner@vnet.ibm.com>
24168
24169 PR target/56010
24170 PR target/83743
24171 * config/rs6000/driver-rs6000.c: #include "diagnostic.h".
24172 #include "opts.h".
24173 (rs6000_supported_cpu_names): New static variable.
24174 (linux_cpu_translation_table): Likewise.
24175 (elf_platform) <cpu>: Define new static variable and use it.
24176 Translate kernel AT_PLATFORM name to canonical name if needed.
24177 Error if platform name is unknown.
24178
24179 2018-02-01 Aldy Hernandez <aldyh@redhat.com>
24180
24181 PR target/84089
24182 * config/pa/predicates.md (base14_operand): Handle E_VOIDmode.
24183
24184 2018-02-01 Jeff Law <law@redhat.com>
24185
24186 PR target/84128
24187 * config/i386/i386.c (release_scratch_register_on_entry): Add new
24188 OFFSET and RELEASE_VIA_POP arguments. Use SP+OFFSET to restore
24189 the scratch if RELEASE_VIA_POP is false.
24190 (ix86_adjust_stack_and_probe_stack_clash): Un-constify SIZE.
24191 If we have to save a temporary register, decrement SIZE appropriately.
24192 Pass new arguments to release_scratch_register_on_entry.
24193 (ix86_adjust_stack_and_probe): Likewise.
24194 (ix86_emit_probe_stack_range): Pass new arguments to
24195 release_scratch_register_on_entry.
24196
24197 2018-02-01 Uros Bizjak <ubizjak@gmail.com>
24198
24199 PR rtl-optimization/84157
24200 * combine.c (change_zero_ext): Use REG_P predicate in
24201 front of HARD_REGISTER_P predicate.
24202
24203 2018-02-01 Georg-Johann Lay <avr@gjlay.de>
24204
24205 * config/avr/avr.c (avr_option_override): Move disabling of
24206 -fdelete-null-pointer-checks to...
24207 * common/config/avr/avr-common.c (avr_option_optimization_table):
24208 ...here.
24209
24210 2018-02-01 Richard Sandiford <richard.sandiford@linaro.org>
24211
24212 PR tree-optimization/81635
24213 * tree-data-ref.c (split_constant_offset_1): For types that
24214 wrap on overflow, try to use range info to prove that wrapping
24215 cannot occur.
24216
24217 2018-02-01 Renlin Li <renlin.li@arm.com>
24218
24219 PR target/83370
24220 * config/aarch64/aarch64.c (aarch64_class_max_nregs): Handle
24221 TAILCALL_ADDR_REGS.
24222 (aarch64_register_move_cost): Likewise.
24223 * config/aarch64/aarch64.h (reg_class): Rename CALLER_SAVE_REGS to
24224 TAILCALL_ADDR_REGS.
24225 (REG_CLASS_NAMES): Likewise.
24226 (REG_CLASS_CONTENTS): Rename CALLER_SAVE_REGS to
24227 TAILCALL_ADDR_REGS. Remove IP registers.
24228 * config/aarch64/aarch64.md (Ucs): Update register constraint.
24229
24230 2018-02-01 Richard Biener <rguenther@suse.de>
24231
24232 * domwalk.h (dom_walker::dom_walker): Add additional constructor
24233 for specifying RPO order and allow NULL for that.
24234 * domwalk.c (dom_walker::dom_walker): Likewise.
24235 (dom_walker::walk): Handle NULL RPO order.
24236 * tree-into-ssa.c (rewrite_dom_walker): Do not walk dom children
24237 in RPO order.
24238 (rewrite_update_dom_walker): Likewise.
24239 (mark_def_dom_walker): Likewise.
24240
24241 2018-02-01 Richard Sandiford <richard.sandiford@linaro.org>
24242
24243 * config/aarch64/aarch64-protos.h (aarch64_split_sve_subreg_move)
24244 (aarch64_maybe_expand_sve_subreg_move): Declare.
24245 * config/aarch64/aarch64.md (UNSPEC_REV_SUBREG): New unspec.
24246 * config/aarch64/predicates.md (aarch64_any_register_operand): New
24247 predicate.
24248 * config/aarch64/aarch64-sve.md (mov<mode>): Optimize subreg moves
24249 that are semantically a reverse operation.
24250 (*aarch64_sve_mov<mode>_subreg_be): New pattern.
24251 * config/aarch64/aarch64.c (aarch64_maybe_expand_sve_subreg_move):
24252 (aarch64_replace_reg_mode, aarch64_split_sve_subreg_move): New
24253 functions.
24254 (aarch64_can_change_mode_class): For big-endian, forbid changes
24255 between two SVE modes if they have different element sizes.
24256
24257 2018-02-01 Richard Sandiford <richard.sandiford@linaro.org>
24258
24259 * config/aarch64/aarch64.c (aarch64_expand_sve_const_vector): Prefer
24260 the TImode handling for big-endian targets.
24261
24262 2018-02-01 Richard Sandiford <richard.sandiford@linaro.org>
24263
24264 * config/aarch64/aarch64-sve.md (sve_ld1rq): Replace with...
24265 (*sve_ld1rq<Vesize>): ... this new pattern. Handle all element sizes,
24266 not just bytes.
24267 * config/aarch64/aarch64.c (aarch64_expand_sve_widened_duplicate):
24268 Remove BSWAP handing for big-endian targets and use the form of
24269 LD1RQ appropariate for the mode.
24270
24271 2018-02-01 Richard Sandiford <richard.sandiford@linaro.org>
24272
24273 * config/aarch64/aarch64.c (aarch64_simd_valid_immediate): Handle
24274 all CONST_VECTOR_DUPLICATE_P vectors, not just those with a single
24275 duplicated element.
24276
24277 2018-02-01 Richard Sandiford <richard.sandiford@linaro.org>
24278
24279 PR tearget/83845
24280 * config/aarch64/aarch64.c (aarch64_secondary_reload): Tighten
24281 check for operands that need to go through aarch64_sve_reload_be.
24282
24283 2018-02-01 Jakub Jelinek <jakub@redhat.com>
24284
24285 PR tree-optimization/81661
24286 PR tree-optimization/84117
24287 * tree-eh.h (rewrite_to_non_trapping_overflow): Declare.
24288 * tree-eh.c: Include gimplify.h.
24289 (find_trapping_overflow, replace_trapping_overflow,
24290 rewrite_to_non_trapping_overflow): New functions.
24291 * tree-vect-loop.c: Include tree-eh.h.
24292 (vect_get_loop_niters): Use rewrite_to_non_trapping_overflow.
24293 * tree-data-ref.c: Include tree-eh.h.
24294 (get_segment_min_max): Use rewrite_to_non_trapping_overflow.
24295
24296 2018-01-31 Uros Bizjak <ubizjak@gmail.com>
24297
24298 PR rtl-optimization/84123
24299 * combine.c (change_zero_ext): Check if hard register satisfies
24300 can_change_dest_mode before calling gen_lowpart_SUBREG.
24301
24302 2018-01-31 Vladimir Makarov <vmakarov@redhat.com>
24303
24304 PR target/82444
24305 * ira.c (ira_init_register_move_cost): Remove assert.
24306
24307 2018-01-31 Eric Botcazou <ebotcazou@adacore.com>
24308
24309 PR rtl-optimization/84071
24310 * doc/tm.texi.in (WORD_REGISTER_OPERATIONS): Add explicit case.
24311 * doc/tm.texi: Regenerate.
24312
24313 2018-01-31 Richard Biener <rguenther@suse.de>
24314
24315 PR tree-optimization/84132
24316 * tree-data-ref.c (analyze_miv_subscript): Properly
24317 check whether evolution_function_is_affine_multivariate_p
24318 before calling gcd_of_steps_may_divide_p.
24319
24320 2018-01-31 Julia Koval <julia.koval@intel.com>
24321
24322 PR target/83618
24323 * config/i386/i386.c (ix86_expand_builtin): Handle IX86_BUILTIN_RDPID.
24324 * config/i386/i386.md (rdpid_rex64) New.
24325 (rdpid): Make 32bit only.
24326
24327 2018-01-29 Aldy Hernandez <aldyh@redhat.com>
24328
24329 PR lto/84105
24330 * tree-pretty-print.c (dump_generic_node): Handle a TYPE_NAME with
24331 an IDENTIFIER_NODE for FUNCTION_TYPE's.
24332
24333 2018-01-31 Eric Botcazou <ebotcazou@adacore.com>
24334
24335 Revert
24336 2018-01-12 Eric Botcazou <ebotcazou@adacore.com>
24337
24338 * config/sparc/sparc.md (vxworks_load_got): Set the GOT register.
24339
24340 2018-01-31 Eric Botcazou <ebotcazou@adacore.com>
24341
24342 PR rtl-optimization/84071
24343 * combine.c (record_dead_and_set_regs_1): Record the source unmodified
24344 for a paradoxical SUBREG on a WORD_REGISTER_OPERATIONS target.
24345
24346 2018-01-31 Claudiu Zissulescu <claziss@synopsys.com>
24347
24348 * config/arc/arc.c (arc_handle_aux_attribute): New function.
24349 (arc_attribute_table): Add 'aux' attribute.
24350 (arc_in_small_data_p): Consider aux like variables.
24351 (arc_is_aux_reg_p): New function.
24352 (arc_asm_output_aligned_decl_local): Ignore 'aux' like variables.
24353 (arc_get_aux_arg): New function.
24354 (prepare_move_operands): Handle aux-register access.
24355 (arc_handle_aux_attribute): New function.
24356 * doc/extend.texi (ARC Variable attributes): Add subsection.
24357
24358 2018-01-31 Claudiu Zissulescu <claziss@synopsys.com>
24359
24360 * config/arc/arc-protos.h (arc_is_uncached_mem_p): Function proto.
24361 * config/arc/arc.c (arc_handle_uncached_attribute): New function.
24362 (arc_attribute_table): Add 'uncached' attribute.
24363 (arc_print_operand): Print '.di' flag for uncached memory
24364 accesses.
24365 (arc_in_small_data_p): Do not consider for small data the uncached
24366 types.
24367 (arc_is_uncached_mem_p): New function.
24368 * config/arc/predicates.md (compact_store_memory_operand): Check
24369 for uncached memory accesses.
24370 (nonvol_nonimm_operand): Likewise.
24371 * doc/extend.texi (ARC Type Attribute): New subsection.
24372
24373 2018-01-31 Jakub Jelinek <jakub@redhat.com>
24374
24375 PR c/84100
24376 * common.opt (falign-functions=, falign-jumps=, falign-labels=,
24377 falign-loops=): Add Optimization flag.
24378
24379 2018-01-30 Jeff Law <law@redhat.com>
24380
24381 PR target/84064
24382 * i386.c (ix86_adjust_stack_and_probe_stack_clash): New argument
24383 INT_REGISTERS_SAVED. Check it prior to calling
24384 get_scratch_register_on_entry.
24385 (ix86_adjust_stack_and_probe): Similarly.
24386 (ix86_emit_probe_stack_range): Similarly.
24387 (ix86_expand_prologue): Corresponding changes.
24388
24389 2018-01-30 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
24390
24391 PR target/40411
24392 * config/sol2.h (STARTFILE_ARCH_SPEC): Use -std=c*,
24393 -std=iso9899:199409 instead of -pedantic to select values-Xc.o.
24394
24395 2018-01-30 Vladimir Makarov <vmakarov@redhat.com>
24396
24397 PR target/84112
24398 * lra-constraints.c (curr_insn_transform): Process AND in the
24399 address.
24400
24401 2018-01-30 Jakub Jelinek <jakub@redhat.com>
24402
24403 PR rtl-optimization/83986
24404 * sched-deps.c (sched_analyze_insn): For frame related insns, add anti
24405 dependence against last_pending_memory_flush in addition to
24406 pending_jump_insns.
24407
24408 2018-01-30 Alexandre Oliva <aoliva@redhat.com>
24409
24410 PR tree-optimization/81611
24411 * tree-ssa-dom.c (simple_iv_increment_p): Skip intervening
24412 copies.
24413
24414 2018-01-30 Aaron Sawdey <acsawdey@linux.vnet.ibm.com>
24415
24416 PR target/83758
24417 * config/rs6000/rs6000.c (rs6000_internal_arg_pointer): Only return
24418 a reg rtx.
24419
24420 2018-01-30 Richard Biener <rguenther@suse.de>
24421 Jakub Jelinek <jakub@redhat.com>
24422
24423 PR tree-optimization/84111
24424 * tree-ssa-loop-ivcanon.c (tree_unroll_loops_completely_1): Skip
24425 inner loops added during recursion, as they don't have up-to-date
24426 SSA form.
24427
24428 2018-01-30 Jan Hubicka <hubicka@ucw.cz>
24429
24430 PR ipa/81360
24431 * ipa-inline.c (can_inline_edge_p): Break out late tests to...
24432 (can_inline_edge_by_limits_p): ... here.
24433 (can_early_inline_edge_p, check_callers,
24434 update_caller_keys, update_callee_keys, recursive_inlining,
24435 add_new_edges_to_heap, speculation_useful_p,
24436 inline_small_functions,
24437 inline_small_functions, flatten_function,
24438 inline_to_all_callers_1): Update.
24439
24440 2018-01-30 Jan Hubicka <hubicka@ucw.cz>
24441
24442 * profile-count.c (profile_count::combine_with_ipa_count): Handle
24443 zeros correctly.
24444
24445 2018-01-30 Richard Biener <rguenther@suse.de>
24446
24447 PR tree-optimization/83008
24448 * tree-vect-slp.c (vect_analyze_slp_cost_1): Properly cost
24449 invariant and constant vector uses in stmts when they need
24450 more than one stmt.
24451
24452 2018-01-30 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
24453
24454 PR bootstrap/84017
24455 * configure.ac (gcc_cv_as_shf_merge): Disable on Solaris 10/x86.
24456 * configure: Regenerate.
24457
24458 2018-01-30 Richard Sandiford <richard.sandiford@linaro.org>
24459
24460 * config/aarch64/aarch64-sve.md (*vec_extract<mode><Vel>_0): New
24461 pattern.
24462 (*vec_extract<mode><Vel>_v128): Require a nonzero lane number.
24463 Use gen_rtx_REG rather than gen_lowpart.
24464
24465 2018-01-30 Richard Sandiford <richard.sandiford@linaro.org>
24466
24467 * lra-constraints.c (match_reload): Use subreg_lowpart_offset
24468 rather than 0 when creating partial subregs.
24469
24470 2018-01-30 Richard Sandiford <richard.sandiford@linaro.org>
24471
24472 * vec-perm-indices.c (vec_perm_indices::series_p): Give examples
24473 of usage.
24474
24475 2018-01-29 Michael Meissner <meissner@linux.vnet.ibm.com>
24476
24477 PR target/81550
24478 * config/rs6000/rs6000.c (rs6000_setup_reg_addr_masks): If DFmode
24479 and SFmode can go in Altivec registers (-mcpu=power7 for DFmode,
24480 -mcpu=power8 for SFmode) don't set the PRE_INCDEC or PRE_MODIFY
24481 flags. This restores the settings used before the 2017-07-24.
24482 Turning off pre increment/decrement/modify allows IVOPTS to
24483 optimize DF/SF loops where the index is an int.
24484
24485 2018-01-29 Richard Biener <rguenther@suse.de>
24486 Kelvin Nilsen <kelvin@gcc.gnu.org>
24487
24488 PR bootstrap/80867
24489 * tree-vect-stmts.c (vectorizable_call): Don't call
24490 targetm.vectorize_builtin_md_vectorized_function if callee is
24491 NULL.
24492
24493 2018-01-22 Carl Love <cel@us.ibm.com>
24494
24495 * doc/extend.tex: Fix typo in second arg in
24496 __builtin_bcdadd_{lt|eq|gt|ov} and __builtin_bcdsub_{lt|eq|gt|ov}.
24497
24498 2018-01-29 Richard Biener <rguenther@suse.de>
24499
24500 PR tree-optimization/84086
24501 * tree-ssanames.c: Include cfgloop.h and tree-scalar-evolution.h.
24502 (flush_ssaname_freelist): When SSA names were released reset
24503 the SCEV hash table.
24504
24505 2018-01-29 Richard Biener <rguenther@suse.de>
24506
24507 PR tree-optimization/84057
24508 * tree-ssa-loop-ivcanon.c (unloop_loops): Deal with already
24509 removed paths when removing edges.
24510
24511 2018-01-27 H.J. Lu <hongjiu.lu@intel.com>
24512
24513 * doc/invoke.texi: Replace -mfunction-return==@var{choice} with
24514 -mfunction-return=@var{choice}.
24515
24516 2018-01-27 Bernd Edlinger <bernd.edlinger@hotmail.de>
24517
24518 PR diagnostic/84034
24519 * diagnostic-show-locus.c (get_line_width_without_trailing_whitespace):
24520 Handle CR like TAB.
24521 (layout::print_source_line): Likewise.
24522 (test_get_line_width_without_trailing_whitespace): Add test cases.
24523
24524 2018-01-27 Jakub Jelinek <jakub@redhat.com>
24525
24526 PR middle-end/84040
24527 * sched-deps.c (sched_macro_fuse_insns): Return immediately for
24528 debug insns.
24529
24530 2018-01-26 Jim Wilson <jimw@sifive.com>
24531
24532 * config/riscv/riscv.h (MAX_FIXED_MODE_SIZE): New.
24533
24534 * config/riscv/elf.h (LIB_SPEC): Don't include -lgloss when nosys.specs
24535 specified.
24536
24537 2018-01-26 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
24538
24539 * config/aarch64/aarch64.md: Add peepholes for CMP + SUB -> SUBS
24540 and CMP + SUB-immediate -> SUBS.
24541
24542 2018-01-26 Martin Sebor <msebor@redhat.com>
24543
24544 PR tree-optimization/83896
24545 * tree-ssa-strlen.c (get_string_len): Rename...
24546 (get_string_cst_length): ...to this. Return HOST_WIDE_INT.
24547 Avoid assuming length is constant.
24548 (handle_char_store): Use HOST_WIDE_INT for string length.
24549
24550 2018-01-26 Uros Bizjak <ubizjak@gmail.com>
24551
24552 PR target/81763
24553 * config/i386/i386.md (*andndi3_doubleword): Add earlyclobber
24554 to (=&r,r,rm) alternative. Add (=r,0,rm) and (=r,r,0) alternatives.
24555
24556 2018-01-26 Richard Biener <rguenther@suse.de>
24557
24558 PR rtl-optimization/84003
24559 * dse.c (record_store): Only record redundant stores when
24560 the earlier store aliases at least all accesses the later one does.
24561
24562 2018-01-26 Jakub Jelinek <jakub@redhat.com>
24563
24564 PR rtl-optimization/83985
24565 * dce.c (deletable_insn_p): Return false for separate shrink wrapping
24566 REG_CFA_RESTORE insns.
24567 (delete_unmarked_insns): Don't ignore separate shrink wrapping
24568 REG_CFA_RESTORE insns here.
24569
24570 PR c/83989
24571 * gimple-ssa-warn-restrict.c (builtin_memref::builtin_memref): Don't
24572 use SSA_NAME_VAR as base for SSA_NAMEs with non-NULL SSA_NAME_VAR.
24573
24574 2018-01-26 Claudiu Zissulescu <claziss@synopsys.com>
24575
24576 * config/arc/arc-arch.h (arc_tune_attr): Add ARC_TUNE_CORE_3.
24577 * config/arc/arc.c (arc_sched_issue_rate): Use ARC_TUNE_... .
24578 (arc_init): Likewise.
24579 (arc_override_options): Likewise.
24580 (arc_file_start): Choose Tag_ARC_CPU_variation based on arc_tune
24581 value.
24582 (hwloop_fail): Use TARGET_DBNZ when we want to check for dbnz insn
24583 support.
24584 * config/arc/arc.h (TARGET_DBNZ): Define.
24585 * config/arc/arc.md (attr tune): Add core_3, use ARC_TUNE_... to
24586 properly set the tune attribute.
24587 (dbnz): Use TARGET_DBNZ guard.
24588 * config/arc/arc.opt (mtune): Add core3 option.
24589
24590 2018-01-26 Claudiu Zissulescu <claziss@synopsys.com>
24591
24592 * config/arc/arc.c (arc_delegitimize_address_0): Refactored to
24593 recognize new pic like addresses.
24594 (arc_delegitimize_address): Clean up.
24595
24596 2018-01-26 Claudiu Zissulescu <claziss@synopsys.com>
24597
24598 * config/arc/arc-arches.def: Option mrf16 valid for all
24599 architectures.
24600 * config/arc/arc-c.def (__ARC_RF16__): New predefined macro.
24601 * config/arc/arc-cpus.def (em_mini): New cpu with rf16 on.
24602 * config/arc/arc-options.def (FL_RF16): Add mrf16 option.
24603 * config/arc/arc-tables.opt: Regenerate.
24604 * config/arc/arc.c (arc_conditional_register_usage): Handle
24605 reduced register file case.
24606 (arc_file_start): Set must have build attributes.
24607 * config/arc/arc.h (MAX_ARC_PARM_REGS): Conditional define using
24608 mrf16 option value.
24609 * config/arc/arc.opt (mrf16): Add new option.
24610 * config/arc/elf.h (ATTRIBUTE_PCS): Define.
24611 * config/arc/genmultilib.awk: Handle new mrf16 option.
24612 * config/arc/linux.h (ATTRIBUTE_PCS): Define.
24613 * config/arc/t-multilib: Regenerate.
24614 * doc/invoke.texi (ARC Options): Document mrf16 option.
24615
24616 2018-01-26 Claudiu Zissulescu <claziss@synopsys.com>
24617
24618 * config/arc/arc-protos.h: Add arc_is_secure_call_p proto.
24619 * config/arc/arc.c (arc_handle_secure_attribute): New function.
24620 (arc_attribute_table): Add 'secure_call' attribute.
24621 (arc_print_operand): Print secure call operand.
24622 (arc_function_ok_for_sibcall): Don't optimize tail calls when
24623 secure.
24624 (arc_is_secure_call_p): New function. * config/arc/arc.md
24625 (call_i): Add support for sjli instruction.
24626 (call_value_i): Likewise.
24627 * config/arc/constraints.md (Csc): New constraint.
24628
24629 2018-01-26 Claudiu Zissulescu <claziss@synopsys.com>
24630 John Eric Martin <John.Martin@emmicro-us.com>
24631
24632 * config/arc/arc-protos.h: Add arc_is_jli_call_p proto.
24633 * config/arc/arc.c (_arc_jli_section): New struct.
24634 (arc_jli_section): New type.
24635 (rc_jli_sections): New static variable.
24636 (arc_handle_jli_attribute): New function.
24637 (arc_attribute_table): Add jli_always and jli_fixed attribute.
24638 (arc_file_end): New function.
24639 (TARGET_ASM_FILE_END): Define.
24640 (arc_print_operand): Reuse 'S' letter for JLI output instruction.
24641 (arc_add_jli_section): New function.
24642 (jli_call_scan): Likewise.
24643 (arc_reorg): Call jli_call_scan.
24644 (arc_output_addsi): Remove 'S' from printing asm operand.
24645 (arc_is_jli_call_p): New function.
24646 * config/arc/arc.md (movqi_insn): Remove 'S' from printing asm
24647 operand.
24648 (movhi_insn): Likewise.
24649 (movsi_insn): Likewise.
24650 (movsi_set_cc_insn): Likewise.
24651 (loadqi_update): Likewise.
24652 (load_zeroextendqisi_update): Likewise.
24653 (load_signextendqisi_update): Likewise.
24654 (loadhi_update): Likewise.
24655 (load_zeroextendhisi_update): Likewise.
24656 (load_signextendhisi_update): Likewise.
24657 (loadsi_update): Likewise.
24658 (loadsf_update): Likewise.
24659 (movsicc_insn): Likewise.
24660 (bset_insn): Likewise.
24661 (bxor_insn): Likewise.
24662 (bclr_insn): Likewise.
24663 (bmsk_insn): Likewise.
24664 (bicsi3_insn): Likewise.
24665 (cmpsi_cc_c_insn): Likewise.
24666 (movsi_ne): Likewise.
24667 (movsi_cond_exec): Likewise.
24668 (clrsbsi2): Likewise.
24669 (norm_f): Likewise.
24670 (normw): Likewise.
24671 (swap): Likewise.
24672 (divaw): Likewise.
24673 (flag): Likewise.
24674 (sr): Likewise.
24675 (kflag): Likewise.
24676 (ffs): Likewise.
24677 (ffs_f): Likewise.
24678 (fls): Likewise.
24679 (call_i): Remove 'S' asm letter, add jli instruction.
24680 (call_value_i): Likewise.
24681 * config/arc/arc.op (mjli-always): New option.
24682 * config/arc/constraints.md (Cji): New constraint.
24683 * config/arc/fpx.md (addsf3_fpx): Remove 'S' from printing asm
24684 operand.
24685 (subsf3_fpx): Likewise.
24686 (mulsf3_fpx): Likewise.
24687 * config/arc/simdext.md (vendrec_insn): Remove 'S' from printing
24688 asm operand.
24689 * doc/extend.texi (ARC): Document 'jli-always' and 'jli-fixed'
24690 function attrbutes.
24691 * doc/invoke.texi (ARC): Document mjli-always option.
24692
24693 2018-01-26 Sebastian Perta <sebastian.perta@renesas.com>
24694
24695 * config/rl78/rl78.c (rl78_addsi3_internal): If operand 2 is const
24696 avoid addition with 0 and use incw and decw where possible.
24697
24698 2018-01-26 Richard Biener <rguenther@suse.de>
24699
24700 PR tree-optimization/81082
24701 * fold-const.c (fold_plusminus_mult_expr): Do not perform the
24702 association if it requires casting to unsigned.
24703 * match.pd ((A * C) +- (B * C) -> (A+-B)): New patterns derived
24704 from fold_plusminus_mult_expr to catch important cases late when
24705 range info is available.
24706
24707 2018-01-26 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
24708
24709 * config/i386/sol2.h (USE_HIDDEN_LINKONCE): Remove.
24710 * configure.ac (hidden_linkonce): New test.
24711 * configure: Regenerate.
24712 * config.in: Regenerate.
24713
24714 2018-01-26 Julia Koval <julia.koval@intel.com>
24715
24716 * config/i386/avx512bitalgintrin.h (_mm512_bitshuffle_epi64_mask,
24717 _mm512_mask_bitshuffle_epi64_mask, _mm256_bitshuffle_epi64_mask,
24718 _mm256_mask_bitshuffle_epi64_mask, _mm_bitshuffle_epi64_mask,
24719 _mm_mask_bitshuffle_epi64_mask): Fix type.
24720 * config/i386/i386-builtin-types.def (UHI_FTYPE_V2DI_V2DI_UHI,
24721 USI_FTYPE_V4DI_V4DI_USI): Remove.
24722 * config/i386/i386-builtin.def (__builtin_ia32_vpshufbitqmb512_mask,
24723 __builtin_ia32_vpshufbitqmb256_mask,
24724 __builtin_ia32_vpshufbitqmb128_mask): Fix types.
24725 * config/i386/i386.c (ix86_expand_args_builtin): Remove old types.
24726 * config/i386/sse.md (VI1_AVX512VLBW): Change types.
24727
24728 2018-01-26 Alan Modra <amodra@gmail.com>
24729
24730 PR target/84033
24731 * config/rs6000/rs6000-p8swap.c (rtx_is_swappable_p): Exclude
24732 UNSPEC_VBPERMQ. Sort other unspecs.
24733
24734 2018-01-25 David Edelsohn <dje.gcc@gmail.com>
24735
24736 * doc/invoke.texi (PowerPC Options): Document 'native' cpu type.
24737
24738 2018-01-25 Jan Hubicka <hubicka@ucw.cz>
24739
24740 PR middle-end/83055
24741 * predict.c (drop_profile): Do not push/pop cfun; update also
24742 node->count.
24743 (handle_missing_profiles): Fix logic looking for zero profiles.
24744
24745 2018-01-25 Jakub Jelinek <jakub@redhat.com>
24746
24747 PR middle-end/83977
24748 * ipa-fnsummary.c (compute_fn_summary): Clear can_change_signature
24749 on functions with #pragma omp declare simd or functions with simd
24750 attribute.
24751 * omp-simd-clone.c (expand_simd_clones): Revert 2018-01-24 change.
24752 * config/i386/i386.c (ix86_simd_clone_compute_vecsize_and_simdlen):
24753 Remove trailing \n from warning_at calls.
24754
24755 2018-01-25 Tom de Vries <tom@codesourcery.com>
24756
24757 PR target/84028
24758 * config/nvptx/nvptx.c (nvptx_single): Add exit insn after noreturn call
24759 for neutered workers.
24760
24761 2018-01-24 Joseph Myers <joseph@codesourcery.com>
24762
24763 PR target/68467
24764 * config/m68k/m68k.c (m68k_promote_function_mode): New function.
24765 (TARGET_PROMOTE_FUNCTION_MODE): New macro.
24766
24767 2018-01-24 Jeff Law <law@redhat.com>
24768
24769 PR target/83994
24770 * i386.c (get_probe_interval): Move to earlier point.
24771 (ix86_compute_frame_layout): If -fstack-clash-protection and
24772 the frame is larger than the probe interval, then use pushes
24773 to save registers rather than reg->mem moves.
24774 (ix86_expand_prologue): Remove conditional for int_registers_saved
24775 assertion.
24776
24777 2018-01-24 Vladimir Makarov <vmakarov@redhat.com>
24778
24779 PR target/84014
24780 * ira-build.c (setup_min_max_allocno_live_range_point): Set up
24781 min/max for never referenced object.
24782
24783 2018-01-24 Jakub Jelinek <jakub@redhat.com>
24784
24785 PR middle-end/83977
24786 * tree.c (free_lang_data_in_decl): Don't clear DECL_ABSTRACT_ORIGIN
24787 here.
24788 * omp-low.c (create_omp_child_function): Remove "omp declare simd"
24789 attributes from DECL_ATTRIBUTES (decl) without affecting
24790 DECL_ATTRIBUTES (current_function_decl).
24791 * omp-simd-clone.c (expand_simd_clones): Ignore DECL_ARTIFICIAL
24792 functions with non-NULL DECL_ABSTRACT_ORIGIN.
24793
24794 2018-01-24 Richard Sandiford <richard.sandiford@linaro.org>
24795
24796 PR tree-optimization/83979
24797 * fold-const.c (fold_comparison): Use constant_boolean_node
24798 instead of boolean_{true,false}_node.
24799
24800 2018-01-24 Jan Hubicka <hubicka@ucw.cz>
24801
24802 * ipa-profile.c (ipa_propagate_frequency_1): Fix logic skipping calls
24803 with zero counts.
24804
24805 2018-01-24 Bill Schmidt <wschmidt@linux.vnet.ibm.com>
24806
24807 * config/rs6000/rs6000.md (*call_indirect_nonlocal_sysv<mode>):
24808 Simplify the clause that sets the length attribute.
24809 (*call_value_indirect_nonlocal_sysv<mode>): Likewise.
24810 (*sibcall_nonlocal_sysv<mode>): Clean up code block; simplify the
24811 clause that sets the length attribute.
24812 (*sibcall_value_nonlocal_sysv<mode>): Likewise.
24813
24814 2018-01-24 Tom de Vries <tom@codesourcery.com>
24815
24816 PR target/83589
24817 * config/nvptx/nvptx.c (WORKAROUND_PTXJIT_BUG_2): Define to 1.
24818 (nvptx_pc_set, nvptx_condjump_label): New function. Copy from jump.c.
24819 Add strict parameter.
24820 (prevent_branch_around_nothing): Insert dummy insn between branch to
24821 label and label with no ptx insn inbetween.
24822 * config/nvptx/nvptx.md (define_insn "fake_nop"): New insn.
24823
24824 2018-01-24 Tom de Vries <tom@codesourcery.com>
24825
24826 PR target/81352
24827 * config/nvptx/nvptx.c (nvptx_single): Add exit insn after noreturn call
24828 for neutered threads in warp.
24829 * config/nvptx/nvptx.md (define_insn "exit"): New insn.
24830
24831 2018-01-24 Richard Biener <rguenther@suse.de>
24832
24833 PR tree-optimization/83176
24834 * tree-chrec.c (chrec_fold_plus_1): Handle (signed T){(T) .. }
24835 operands.
24836
24837 2018-01-24 Richard Biener <rguenther@suse.de>
24838
24839 PR tree-optimization/82819
24840 * graphite-isl-ast-to-gimple.c (binary_op_to_tree): Avoid
24841 code generating pluses that are no-ops in the target precision.
24842
24843 2018-01-24 Richard Biener <rguenther@suse.de>
24844
24845 PR middle-end/84000
24846 * tree-cfg.c (replace_loop_annotate): Handle annot_expr_parallel_kind.
24847
24848 2018-01-23 Jan Hubicka <hubicka@ucw.cz>
24849
24850 * cfgcleanup.c (try_crossjump_to_edge): Use combine_with_count
24851 to merge probabilities.
24852 * predict.c (probably_never_executed): Also mark as cold functions
24853 with global 0 profile and guessed local profile.
24854 * profile-count.c (profile_probability::combine_with_count): New
24855 member function.
24856 * profile-count.h (profile_probability::operator*,
24857 profile_probability::operator*=, profile_probability::operator/,
24858 profile_probability::operator/=): Reduce precision to adjusted
24859 and set value to guessed on contradictory divisions.
24860 (profile_probability::combine_with_freq): Remove.
24861 (profile_probability::combine_wiht_count): Declare.
24862 (profile_count::force_nonzero):: Set to adjusted.
24863 (profile_count::probability_in):: Set quality to adjusted.
24864 * tree-ssa-tail-merge.c (replace_block_by): Use
24865 combine_with_count.
24866
24867 2018-01-23 Andrew Waterman <andrew@sifive.com>
24868 Jim Wilson <jimw@sifive.com>
24869
24870 * config/riscv/riscv.c (riscv_stack_boundary): New.
24871 (riscv_option_override): Set riscv_stack_boundary. Handle
24872 riscv_preferred_stack_boundary_arg.
24873 * config/riscv/riscv.h (MIN_STACK_BOUNDARY, ABI_STACK_BOUNDARY): New.
24874 (BIGGEST_ALIGNMENT): Set to STACK_BOUNDARY.
24875 (STACK_BOUNDARY): Set to riscv_stack_boundary.
24876 (RISCV_STACK_ALIGN): Use STACK_BOUNDARY.
24877 * config/riscv/riscv.opt (mpreferred-stack-boundary): New.
24878 * doc/invoke.tex (RISC-V Options): Add -mpreferred-stack-boundary.
24879
24880 2018-01-23 H.J. Lu <hongjiu.lu@intel.com>
24881
24882 PR target/83905
24883 * config/i386/i386.c (ix86_expand_prologue): Use cost reference
24884 of struct ix86_frame.
24885 (ix86_expand_epilogue): Likewise. Add a local variable for
24886 the reg_save_offset field in struct ix86_frame.
24887
24888 2018-01-23 Bin Cheng <bin.cheng@arm.com>
24889
24890 PR tree-optimization/82604
24891 * tree-loop-distribution.c (enum partition_kind): New enum item
24892 PKIND_PARTIAL_MEMSET.
24893 (partition_builtin_p): Support above new enum item.
24894 (generate_code_for_partition): Ditto.
24895 (compute_access_range): Differentiate cases that equality can be
24896 proven at all loops, the innermost loops or no loops.
24897 (classify_builtin_st, classify_builtin_ldst): Adjust call to above
24898 function. Set PKIND_PARTIAL_MEMSET for partition appropriately.
24899 (finalize_partitions, distribute_loop): Don't fuse partition of
24900 PKIND_PARTIAL_MEMSET kind when distributing 3-level loop nest.
24901 (prepare_perfect_loop_nest): Distribute 3-level loop nest only if
24902 parloop is enabled.
24903
24904 2018-01-23 Martin Liska <mliska@suse.cz>
24905
24906 * predict.def (PRED_INDIR_CALL): Set probability to PROB_EVEN in
24907 order to ignore the predictor.
24908 (PRED_POLYMORPHIC_CALL): Likewise.
24909 (PRED_RECURSIVE_CALL): Likewise.
24910
24911 2018-01-23 Martin Liska <mliska@suse.cz>
24912
24913 * tree-profile.c (tree_profiling): Print function header to
24914 aware reader which function we are working on.
24915 * value-prof.c (gimple_find_values_to_profile): Do not print
24916 not interesting value histograms.
24917
24918 2018-01-23 Martin Liska <mliska@suse.cz>
24919
24920 * profile-count.h (enum profile_quality): Add
24921 profile_uninitialized as the first value. Do not number values
24922 as they are zero based.
24923 (profile_count::verify): Update sanity check.
24924 (profile_probability::verify): Likewise.
24925
24926 2018-01-23 Nathan Sidwell <nathan@acm.org>
24927
24928 * doc/invoke.texi (ffor-scope): Deprecate.
24929
24930 2018-01-23 David Malcolm <dmalcolm@redhat.com>
24931
24932 PR tree-optimization/83510
24933 * domwalk.c (set_all_edges_as_executable): New function.
24934 (dom_walker::dom_walker): Convert bool param
24935 "skip_unreachable_blocks" to enum reachability. Move setup of
24936 edge flags to set_all_edges_as_executable and only do it when
24937 reachability is REACHABLE_BLOCKS.
24938 * domwalk.h (enum dom_walker::reachability): New enum.
24939 (dom_walker::dom_walker): Convert bool param
24940 "skip_unreachable_blocks" to enum reachability.
24941 (set_all_edges_as_executable): New decl.
24942 * graphite-scop-detection.c (gather_bbs::gather_bbs): Convert
24943 from false for "skip_unreachable_blocks" to ALL_BLOCKS for
24944 "reachability".
24945 * tree-ssa-dom.c (dom_opt_dom_walker::dom_opt_dom_walker): Likewise,
24946 but converting true to REACHABLE_BLOCKS.
24947 * tree-ssa-sccvn.c (sccvn_dom_walker::sccvn_dom_walker): Likewise.
24948 * tree-vrp.c
24949 (check_array_bounds_dom_walker::check_array_bounds_dom_walker):
24950 Likewise, but converting it to REACHABLE_BLOCKS_PRESERVING_FLAGS.
24951 (vrp_dom_walker::vrp_dom_walker): Likewise, but converting it to
24952 REACHABLE_BLOCKS.
24953 (vrp_prop::vrp_finalize): Call set_all_edges_as_executable
24954 if check_all_array_refs will be called.
24955
24956 2018-01-23 David Malcolm <dmalcolm@redhat.com>
24957
24958 * tree.c (selftest::test_location_wrappers): Add more test
24959 coverage.
24960
24961 2018-01-23 David Malcolm <dmalcolm@redhat.com>
24962
24963 * sbitmap.c (selftest::test_set_range): Fix memory leaks.
24964 (selftest::test_bit_in_range): Likewise.
24965
24966 2018-01-23 Richard Sandiford <richard.sandiford@linaro.org>
24967
24968 PR testsuite/83888
24969 * doc/sourcebuild.texi (vect_float): Say that the selector
24970 only describes the situation when -funsafe-math-optimizations is on.
24971 (vect_float_strict): Document.
24972
24973 2018-01-23 Richard Sandiford <richard.sandiford@linaro.org>
24974
24975 PR tree-optimization/83965
24976 * tree-vect-patterns.c (vect_reassociating_reduction_p): New function.
24977 (vect_recog_dot_prod_pattern, vect_recog_sad_pattern): Use it
24978 instead of checking only for a reduction.
24979 (vect_recog_widen_sum_pattern): Likewise.
24980
24981 2018-01-23 Jan Hubicka <hubicka@ucw.cz>
24982
24983 * predict.c (probably_never_executed): Only use precise profile info.
24984 (compute_function_frequency): Skip after inlining hack since we now
24985 have quality checking.
24986
24987 2018-01-23 Jan Hubicka <hubicka@ucw.cz>
24988
24989 * profile-count.h (profile_probability::very_unlikely,
24990 profile_probability::unlikely, profile_probability::even): Set
24991 precision to guessed.
24992
24993 2018-01-23 Richard Biener <rguenther@suse.de>
24994
24995 PR tree-optimization/83963
24996 * graphite-scop-detection.c (scop_detection::harmful_loop_in_region):
24997 Properly terminate dominator walk when crossing the exit edge not
24998 when visiting its source block.
24999
25000 2018-01-23 Jakub Jelinek <jakub@redhat.com>
25001
25002 PR c++/83918
25003 * tree.c (maybe_wrap_with_location): Use NON_LVALUE_EXPR rather than
25004 VIEW_CONVERT_EXPR to wrap CONST_DECLs.
25005
25006 2018-01-22 Jakub Jelinek <jakub@redhat.com>
25007
25008 PR tree-optimization/83957
25009 * omp-expand.c (expand_omp_for_generic): Ignore virtual PHIs. Remove
25010 semicolon after for body surrounded by braces.
25011
25012 PR tree-optimization/83081
25013 * profile-count.h (profile_probability::split): New method.
25014 * dojump.c (do_jump_1) <case TRUTH_ANDIF_EXPR, case TRUTH_ORIF_EXPR>:
25015 Use profile_probability::split.
25016 (do_compare_rtx_and_jump): Fix adjustment of probabilities
25017 when splitting a single conditional jump into 2.
25018
25019 2018-01-22 David Malcolm <dmalcolm@redhat.com>
25020
25021 PR tree-optimization/69452
25022 * tree-ssa-loop-im.c (class move_computations_dom_walker): Remove
25023 decl.
25024
25025 2018-01-22 Sebastian Perta <sebastian.perta@renesas.com>
25026
25027 * config/rl78/rl78-expand.md (bswaphi2): New define_expand.
25028 * config/rl78/rl78-virt.md (*bswaphi2_virt): New define_insn.
25029 * config/rl78/rl78-real.md (*bswaphi2_real): New define_insn.
25030
25031 2018-01-22 Sebastian Perta <sebastian.perta@renesas.com>
25032
25033 * config/rl78/rl78-protos.h (rl78_split_movdi): New function
25034 declaration.
25035 * config/rl78/rl78.md (movdi): New define_expand.
25036 * config/rl78/rl78.c (rl78_split_movdi): New function.
25037
25038 2018-01-22 Michael Meissner <meissner@linux.vnet.ibm.com>
25039
25040 PR target/83862
25041 * config/rs6000/rs6000-protos.h (rs6000_split_signbit): Delete,
25042 no longer used.
25043 * config/rs6000/rs6000.c (rs6000_split_signbit): Likewise.
25044 * config/rs6000/rs6000.md (signbit<mode>2): Change code for IEEE
25045 128-bit to produce an UNSPEC move to get the double word with the
25046 signbit and then a shift directly to do signbit.
25047 (signbit<mode>2_dm): Replace old IEEE 128-bit signbit
25048 implementation with a new version that just does either a direct
25049 move or a regular move. Move memory interface to separate insns.
25050 Move insns so they are next to the expander.
25051 (signbit<mode>2_dm_mem_be): New combiner insns to combine load
25052 with signbit move. Split big and little endian case.
25053 (signbit<mode>2_dm_mem_le): Likewise.
25054 (signbit<mode>2_dm_<su>ext): Delete, no longer used.
25055 (signbit<mode>2_dm2): Likewise.
25056
25057 2018-01-22 Sebastian Perta <sebastian.perta@renesas.com>
25058
25059 * config/rl78/rl78.md (anddi3): New define_expand.
25060
25061 2018-01-22 Sebastian Perta <sebastian.perta@renesas.com>
25062
25063 * config/rl78/rl78.md (umindi3): New define_expand.
25064
25065 2018-01-22 Sebastian Perta <sebastian.perta@renesas.com>
25066
25067 * config/rl78/rl78.md (smindi3): New define_expand.
25068
25069 2018-01-22 Sebastian Perta <sebastian.perta@renesas.com>
25070
25071 * config/rl78/rl78.md (smaxdi3): New define_expand.
25072
25073 2018-01-22 Carl Love <cel@us.ibm.com>
25074
25075 * config/rs6000/rs6000-builtin.def (ST_ELEMREV_V1TI, LD_ELEMREV_V1TI,
25076 LVX_V1TI): Add macro expansion.
25077 * config/rs6000/rs6000-c.c (altivec_builtin_types): Add argument
25078 definitions for VSX_BUILTIN_VEC_XST_BE, VSX_BUILTIN_VEC_ST,
25079 VSX_BUILTIN_VEC_XL, LD_ELEMREV_V1TI builtins.
25080 * config/rs6000/rs6000-p8swap.c (insn_is_swappable_p);
25081 Change check to determine if the instruction is a byte reversing
25082 entry. Fix typo in comment.
25083 * config/rs6000/rs6000.c (altivec_expand_builtin): Add case entry
25084 for VSX_BUILTIN_ST_ELEMREV_V1TI and VSX_BUILTIN_LD_ELEMREV_V1TI.
25085 Add def_builtin calls for new builtins.
25086 * config/rs6000/vsx.md (vsx_st_elemrev_v1ti, vsx_ld_elemrev_v1ti):
25087 Add define_insn expansion.
25088
25089 2018-01-22 Sebastian Perta <sebastian.perta@renesas.com>
25090
25091 * config/rl78/rl78.md (umaxdi3): New define_expand.
25092
25093 2018-01-22 Sebastian Perta <sebastian.perta@renesas.com>
25094
25095 * config/rl78/rl78.c (rl78_note_reg_set): Fixed dead reg check
25096 for non-QImode registers.
25097
25098 2018-01-22 Richard Biener <rguenther@suse.de>
25099
25100 PR tree-optimization/83963
25101 * graphite-scop-detection.c (scop_detection::get_sese): Delay
25102 including the loop exit block.
25103 (scop_detection::merge_sese): Likewise.
25104 (scop_detection::add_scop): Do it here instead.
25105
25106 2018-01-22 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
25107
25108 * doc/sourcebuild.texi (arm_softfloat): Document.
25109
25110 2018-01-21 John David Anglin <danglin@gcc.gnu.org>
25111
25112 PR gcc/77734
25113 * config/pa/pa.c (pa_function_ok_for_sibcall): Use
25114 targetm.binds_local_p instead of TREE_PUBLIC to check local binding.
25115 Move TARGET_PORTABLE_RUNTIME check after TARGET_64BIT check.
25116
25117 2018-01-21 Bill Schmidt <wschmidt@linux.vnet.ibm.com>
25118 David Edelsohn <dje.gcc@gmail.com>
25119
25120 PR target/83946
25121 * config/rs6000/rs6000.md (*call_indirect_nonlocal_sysv<mode>):
25122 Change "crset eq" to "crset 2".
25123 (*call_value_indirect_nonlocal_sysv<mode>): Likewise.
25124 (*call_indirect_aix<mode>_nospec): Likewise.
25125 (*call_value_indirect_aix<mode>_nospec): Likewise.
25126 (*call_indirect_elfv2<mode>_nospec): Likewise.
25127 (*call_value_indirect_elfv2<mode>_nospec): Likewise.
25128 (*sibcall_nonlocal_sysv<mode>): Change "crset eq" to "crset 2";
25129 change assembly output from . to $.
25130 (*sibcall_value_nonlocal_sysv<mode>): Likewise.
25131 (indirect_jump<mode>_nospec): Change assembly output from . to $.
25132 (*tablejump<mode>_internal1_nospec): Likewise.
25133
25134 2018-01-21 Oleg Endo <olegendo@gcc.gnu.org>
25135
25136 PR target/80870
25137 * config/sh/sh_optimize_sett_clrt.cc:
25138 Use INCLUDE_ALGORITHM and INCLUDE_VECTOR instead of direct includes.
25139
25140 2018-01-20 Richard Sandiford <richard.sandiford@linaro.org>
25141
25142 PR tree-optimization/83940
25143 * tree-vect-stmts.c (vect_truncate_gather_scatter_offset): Set
25144 offset_dt to vect_constant_def rather than vect_unknown_def_type.
25145 (vect_check_load_store_mask): Add a mask_dt_out parameter and
25146 use it to pass back the definition type.
25147 (vect_check_store_rhs): Likewise rhs_dt_out.
25148 (vect_build_gather_load_calls): Add a mask_dt argument and use
25149 it instead of a call to vect_is_simple_use.
25150 (vectorizable_store): Update calls to vect_check_load_store_mask
25151 and vect_check_store_rhs. Use the dt returned by the latter instead
25152 of scatter_src_dt. Use the cached mask_dt and gs_info.offset_dt
25153 instead of calls to vect_is_simple_use. Pass the scalar rather
25154 than the vector operand to vect_is_simple_use when handling
25155 second and subsequent copies of an rhs value.
25156 (vectorizable_load): Update calls to vect_check_load_store_mask
25157 and vect_build_gather_load_calls. Use the cached mask_dt and
25158 gs_info.offset_dt instead of calls to vect_is_simple_use.
25159
25160 2018-01-20 Jakub Jelinek <jakub@redhat.com>
25161
25162 PR middle-end/83945
25163 * tree-emutls.c: Include gimplify.h.
25164 (lower_emutls_2): New function.
25165 (lower_emutls_1): If ADDR_EXPR is a gimple invariant and walk_tree
25166 with lower_emutls_2 callback finds some TLS decl in it, unshare_expr
25167 it before further processing.
25168
25169 PR target/83930
25170 * simplify-rtx.c (simplify_binary_operation_1) <case UMOD>: Use
25171 UINTVAL (trueop1) instead of INTVAL (op1).
25172
25173 2018-01-19 Jakub Jelinek <jakub@redhat.com>
25174
25175 PR debug/81570
25176 PR debug/83728
25177 * dwarf2cfi.c (DEFAULT_INCOMING_FRAME_SP_OFFSET): Define to
25178 INCOMING_FRAME_SP_OFFSET if not defined.
25179 (scan_trace): Add ENTRY argument. If true and
25180 DEFAULT_INCOMING_FRAME_SP_OFFSET != INCOMING_FRAME_SP_OFFSET,
25181 emit a note to adjust the CFA offset.
25182 (create_cfi_notes): Adjust scan_trace callers.
25183 (create_cie_data): Use DEFAULT_INCOMING_FRAME_SP_OFFSET rather than
25184 INCOMING_FRAME_SP_OFFSET in the CIE.
25185 * config/i386/i386.h (DEFAULT_INCOMING_FRAME_SP_OFFSET): Define.
25186 * config/stormy16/stormy16.h (DEFAULT_INCOMING_FRAME_SP_OFFSET):
25187 Likewise.
25188 * doc/tm.texi.in (DEFAULT_INCOMING_FRAME_SP_OFFSET): Document.
25189 * doc/tm.texi: Regenerated.
25190
25191 2018-01-19 Andreas Krebbel <krebbel@linux.vnet.ibm.com>
25192
25193 PR rtl-optimization/83147
25194 * lra-constraints.c (remove_inheritance_pseudos): Use
25195 lra_substitute_pseudo_within_insn.
25196
25197 2018-01-19 Tom de Vries <tom@codesourcery.com>
25198 Cesar Philippidis <cesar@codesourcery.com>
25199
25200 PR target/83920
25201 * config/nvptx/nvptx.c (nvptx_single): Fix jit workaround.
25202
25203 2018-01-19 Cesar Philippidis <cesar@codesourcery.com>
25204
25205 PR target/83790
25206 * config/nvptx/nvptx.c (output_init_frag): Don't use generic address
25207 spaces for function labels.
25208
25209 2018-01-19 Martin Liska <mliska@suse.cz>
25210
25211 * predict.def (PRED_LOOP_EXIT): Change from 85 to 89.
25212 (PRED_LOOP_EXIT_WITH_RECURSION): Change from 72 to 78.
25213 (PRED_LOOP_EXTRA_EXIT): Change from 83 to 67.
25214 (PRED_OPCODE_POSITIVE): Change from 64 to 59.
25215 (PRED_TREE_OPCODE_POSITIVE): Change from 64 to 59.
25216 (PRED_CONST_RETURN): Change from 69 to 65.
25217 (PRED_NULL_RETURN): Change from 91 to 71.
25218 (PRED_LOOP_IV_COMPARE_GUESS): Change from 98 to 64.
25219 (PRED_LOOP_GUARD): Change from 66 to 73.
25220
25221 2018-01-19 Martin Liska <mliska@suse.cz>
25222
25223 * predict.c (predict_insn_def): Add new assert.
25224 (struct branch_predictor): Change type to signed integer.
25225 (test_prediction_value_range): Amend test to cover
25226 PROB_UNINITIALIZED.
25227 * predict.def (PRED_LOOP_ITERATIONS): Use the new constant.
25228 (PRED_LOOP_ITERATIONS_GUESSED): Likewise.
25229 (PRED_LOOP_ITERATIONS_MAX): Likewise.
25230 (PRED_LOOP_IV_COMPARE): Likewise.
25231 * predict.h (PROB_UNINITIALIZED): Define new constant.
25232
25233 2018-01-19 Martin Liska <mliska@suse.cz>
25234
25235 * predict.c (dump_prediction): Add new format for
25236 analyze_brprob.py script which is enabled with -details
25237 suboption.
25238 * profile-count.h (precise_p): New function.
25239
25240 2018-01-19 Richard Sandiford <richard.sandiford@linaro.org>
25241
25242 PR tree-optimization/83922
25243 * tree-vect-loop.c (vect_verify_full_masking): Return false if
25244 there are no statements that need masking.
25245 (vect_active_double_reduction_p): New function.
25246 (vect_analyze_loop_operations): Use it when handling phis that
25247 are not in the loop header.
25248
25249 2018-01-19 Richard Sandiford <richard.sandiford@linaro.org>
25250
25251 PR tree-optimization/83914
25252 * tree-vect-loop.c (vectorizable_induction): Don't convert
25253 init_expr or apply the peeling adjustment for inductions
25254 that are nested within the vectorized loop.
25255
25256 2018-01-19 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
25257
25258 * config/arm/thumb2.md (*thumb2_negsi2_short): Use RSB mnemonic
25259 instead of NEG.
25260
25261 2018-01-18 Jakub Jelinek <jakub@redhat.com>
25262
25263 PR sanitizer/81715
25264 PR testsuite/83882
25265 * function.h (gimplify_parameters): Add gimple_seq * argument.
25266 * function.c: Include gimple.h and options.h.
25267 (gimplify_parameters): Add cleanup argument, add CLOBBER stmts
25268 for the added local temporaries if needed.
25269 * gimplify.c (gimplify_body): Adjust gimplify_parameters caller,
25270 if there are any parameter cleanups, wrap whole body into a
25271 try/finally with the cleanups.
25272
25273 2018-01-18 Wilco Dijkstra <wdijkstr@arm.com>
25274
25275 PR target/82964
25276 * config/aarch64/aarch64.c (aarch64_legitimate_constant_p):
25277 Use GET_MODE_CLASS for scalar floating point.
25278
25279 2018-01-18 Jan Hubicka <hubicka@ucw.cz>
25280
25281 PR ipa/82256
25282 patch by PaX Team
25283 * cgraphclones.c (cgraph_node::create_version_clone_with_body):
25284 Fix call of call_cgraph_insertion_hooks.
25285
25286 2018-01-18 Martin Sebor <msebor@redhat.com>
25287
25288 * doc/invoke.texi (-Wclass-memaccess): Tweak text.
25289
25290 2018-01-18 Jan Hubicka <hubicka@ucw.cz>
25291
25292 PR ipa/83619
25293 * cgraph.c (cgraph_edge::redirect_call_stmt_to_callee): Update edge
25294 frequencies.
25295
25296 2018-01-18 Boris Kolpackov <boris@codesynthesis.com>
25297
25298 PR other/70268
25299 * common.opt: (-ffile-prefix-map): New option.
25300 * opts.c (common_handle_option): Defer it.
25301 * opts-global.c (handle_common_deferred_options): Handle it.
25302 * debug.h (remap_debug_filename, add_debug_prefix_map): Move to...
25303 * file-prefix-map.h: New file.
25304 (remap_debug_filename, add_debug_prefix_map): ...here.
25305 (add_macro_prefix_map, add_file_prefix_map, remap_macro_filename): New.
25306 * final.c (debug_prefix_map, add_debug_prefix_map
25307 remap_debug_filename): Move to...
25308 * file-prefix-map.c: New file.
25309 (file_prefix_map, add_prefix_map, remap_filename) ...here and rename,
25310 generalize, get rid of alloca(), use strrchr() instead of strchr().
25311 (add_macro_prefix_map, add_debug_prefix_map, add_file_prefix_map):
25312 Implement in terms of add_prefix_map().
25313 (remap_macro_filename, remap_debug_filename): Implement in term of
25314 remap_filename().
25315 * Makefile.in (OBJS, PLUGIN_HEADERS): Add new files.
25316 * builtins.c (fold_builtin_FILE): Call remap_macro_filename().
25317 * dbxout.c: Include file-prefix-map.h.
25318 * varasm.c: Likewise.
25319 * vmsdbgout.c: Likewise.
25320 * xcoffout.c: Likewise.
25321 * dwarf2out.c: Likewise plus omit new options from DW_AT_producer.
25322 * doc/cppopts.texi (-fmacro-prefix-map): Document.
25323 * doc/invoke.texi (-ffile-prefix-map): Document.
25324 (-fdebug-prefix-map): Update description.
25325
25326 2018-01-18 Martin Liska <mliska@suse.cz>
25327
25328 * config/i386/i386.c (indirect_thunk_name): Document that also
25329 lfence is emitted.
25330 (output_indirect_thunk): Document why both instructions
25331 (pause and lfence) are generated.
25332
25333 2018-01-18 Richard Biener <rguenther@suse.de>
25334
25335 PR tree-optimization/83887
25336 * graphite-scop-detection.c
25337 (scop_detection::get_nearest_dom_with_single_entry): Remove.
25338 (scop_detection::get_nearest_pdom_with_single_exit): Likewise.
25339 (scop_detection::merge_sese): Re-implement with a flood-fill
25340 algorithm that properly finds a SESE region if it exists.
25341
25342 2018-01-18 Jakub Jelinek <jakub@redhat.com>
25343
25344 PR c/61240
25345 * match.pd ((P + A) - P, P - (P + A), (P + A) - (P + B)): For
25346 pointer_diff optimizations use view_convert instead of convert.
25347
25348 2018-01-17 Bill Schmidt <wschmidt@linux.vnet.ibm.com>
25349
25350 * config/rs6000/rs6000.md (*call_indirect_nonlocal_sysv<mode>):
25351 Generate different code for -mno-speculate-indirect-jumps.
25352 (*call_value_indirect_nonlocal_sysv<mode>): Likewise.
25353 (*call_indirect_aix<mode>): Disable for
25354 -mno-speculate-indirect-jumps.
25355 (*call_indirect_aix<mode>_nospec): New define_insn.
25356 (*call_value_indirect_aix<mode>): Disable for
25357 -mno-speculate-indirect-jumps.
25358 (*call_value_indirect_aix<mode>_nospec): New define_insn.
25359 (*sibcall_nonlocal_sysv<mode>): Generate different code for
25360 -mno-speculate-indirect-jumps.
25361 (*sibcall_value_nonlocal_sysv<mode>): Likewise.
25362
25363 2018-01-17 Michael Meissner <meissner@linux.vnet.ibm.com>
25364
25365 * config/rs6000/rs6000.c (rs6000_emit_move): If we load or store a
25366 long double type, set the flags for noting the default long double
25367 type, even if we don't pass or return a long double type.
25368
25369 2018-01-17 Jan Hubicka <hubicka@ucw.cz>
25370
25371 PR ipa/83051
25372 * ipa-inline.c (flatten_function): Do not overwrite final inlining
25373 failure.
25374
25375 2018-01-17 Will Schmidt <will_schmidt@vnet.ibm.com>
25376
25377 * config/rs6000/rs6000.c (rs6000_gimple_builtin): Add gimple folding
25378 support for merge[hl].
25379 (fold_mergehl_helper): New helper function.
25380 (tree-vector-builder.h): New #include for tree_vector_builder usage.
25381 * config/rs6000/altivec.md (altivec_vmrghw_direct): Add xxmrghw insn.
25382 (altivec_vmrglw_direct): Add xxmrglw insn.
25383
25384 2018-01-17 Andrew Waterman <andrew@sifive.com>
25385
25386 * config/riscv/riscv.c (riscv_conditional_register_usage): If
25387 UNITS_PER_FP_ARG is 0, set call_used_regs to 1 for all FP regs.
25388
25389 2018-01-17 David Malcolm <dmalcolm@redhat.com>
25390
25391 PR lto/83121
25392 * ipa-devirt.c (add_type_duplicate): When comparing memory layout,
25393 call the lto_location_cache before reading the
25394 DECL_SOURCE_LOCATION of the types.
25395
25396 2018-01-17 Wilco Dijkstra <wdijkstr@arm.com>
25397 Richard Sandiford <richard.sandiford@linaro.org>
25398
25399 * config/aarch64/aarch64.md (movti_aarch64): Use Uti constraint.
25400 * config/aarch64/aarch64.c (aarch64_mov128_immediate): New function.
25401 (aarch64_legitimate_constant_p): Just support CONST_DOUBLE
25402 SF/DF/TF mode to avoid creating illegal CONST_WIDE_INT immediates.
25403 * config/aarch64/aarch64-protos.h (aarch64_mov128_immediate):
25404 Add declaration.
25405 * config/aarch64/constraints.md (aarch64_movti_operand):
25406 Limit immediates.
25407 * config/aarch64/predicates.md (Uti): Add new constraint.
25408
25409 2018-01-17 Carl Love <cel@us.ibm.com>
25410
25411 * config/rs6000/vsx.md (define_expand xl_len_r,
25412 define_expand stxvl, define_expand *stxvl): Add match_dup argument.
25413 (define_insn): Add, match_dup 1 argument to define_insn stxvll and
25414 lxvll.
25415 (define_expand, define_insn): Move the shift left from the
25416 define_insn to the define_expand for lxvl and stxvl instructions.
25417 * config/rs6000/rs6000-builtin.def (BU_P9V_64BIT_VSX_2): Change LXVL
25418 and XL_LEN_R definitions to PURE.
25419
25420 2018-01-17 Uros Bizjak <ubizjak@gmail.com>
25421
25422 * config/i386/i386.c (indirect_thunk_name): Declare regno
25423 as unsigned int. Compare regno with INVALID_REGNUM.
25424 (output_indirect_thunk): Ditto.
25425 (output_indirect_thunk_function): Ditto.
25426 (ix86_code_end): Declare regno as unsigned int. Use INVALID_REGNUM
25427 in the call to output_indirect_thunk_function.
25428
25429 2018-01-17 Richard Sandiford <richard.sandiford@linaro.org>
25430
25431 PR middle-end/83884
25432 * expr.c (expand_expr_real_1): Use the size of GET_MODE (op0)
25433 rather than the size of inner_type to determine the stack slot size
25434 when handling VIEW_CONVERT_EXPRs on strict-alignment targets.
25435
25436 2018-01-16 Sebastian Peryt <sebastian.peryt@intel.com>
25437
25438 PR target/83546
25439 * config/i386/i386.c (ix86_option_override_internal): Add PTA_RDRND
25440 to PTA_SILVERMONT.
25441
25442 2018-01-16 Michael Meissner <meissner@linux.vnet.ibm.com>
25443
25444 * config.gcc (powerpc*-linux*-*): Add support for 64-bit little
25445 endian Linux systems to optionally enable multilibs for selecting
25446 the long double type if the user configured an explicit type.
25447 * config/rs6000/rs6000.h (TARGET_IEEEQUAD_MULTILIB): Indicate we
25448 have no long double multilibs if not defined.
25449 * config/rs6000/rs6000.c (rs6000_option_override_internal): Do not
25450 warn if the user used -mabi={ieee,ibm}longdouble and we built
25451 multilibs for long double.
25452 * config/rs6000/linux64.h (MULTILIB_DEFAULTS_IEEE): Define as the
25453 appropriate multilib option.
25454 (MULTILIB_DEFAULTS): Add MULTILIB_DEFAULTS_IEEE to the default
25455 multilib options.
25456 * config/rs6000/t-ldouble-linux64le-ibm: New configuration files
25457 for building long double multilibs.
25458 * config/rs6000/t-ldouble-linux64le-ieee: Likewise.
25459
25460 2018-01-16 John David Anglin <danglin@gcc.gnu.org>
25461
25462 * config.gcc (hppa*-*-linux*): Change callee copies ABI to caller
25463 copies.
25464
25465 * config/pa.h (MALLOC_ABI_ALIGNMENT): Set 32-bit alignment default to
25466 64 bits.
25467 * config/pa/pa32-linux.h (MALLOC_ABI_ALIGNMENT): Set alignment to
25468 128 bits.
25469
25470 * config/pa/som.h (ASM_DECLARE_FUNCTION_NAME): Cleanup type and mode
25471 variables.
25472
25473 * config/pa/pa.c (pa_function_arg_size): Apply CEIL to GET_MODE_SIZE
25474 return value.
25475
25476 2018-01-16 Eric Botcazou <ebotcazou@adacore.com>
25477
25478 * gimple-ssa-warn-restrict.c (builtin_memref::builtin_memref): For an
25479 ADDR_EXPR, do not count the offset of a COMPONENT_REF twice.
25480
25481 2018-01-16 Kelvin Nilsen <kelvin@gcc.gnu.org>
25482
25483 * config/rs6000/rs6000-p8swap.c (rs6000_gen_stvx): Generate
25484 different rtl trees depending on TARGET_64BIT.
25485 (rs6000_gen_lvx): Likewise.
25486
25487 2018-01-16 Eric Botcazou <ebotcazou@adacore.com>
25488
25489 * config/visium/visium.md (nop): Tweak comment.
25490 (hazard_nop): Likewise.
25491
25492 2018-01-16 Bill Schmidt <wschmidt@linux.vnet.ibm.com>
25493
25494 * config/rs6000/rs6000.c (rs6000_opt_vars): Add entry for
25495 -mspeculate-indirect-jumps.
25496 * config/rs6000/rs6000.md (*call_indirect_elfv2<mode>): Disable
25497 for -mno-speculate-indirect-jumps.
25498 (*call_indirect_elfv2<mode>_nospec): New define_insn.
25499 (*call_value_indirect_elfv2<mode>): Disable for
25500 -mno-speculate-indirect-jumps.
25501 (*call_value_indirect_elfv2<mode>_nospec): New define_insn.
25502 (indirect_jump): Emit different RTL for
25503 -mno-speculate-indirect-jumps.
25504 (*indirect_jump<mode>): Disable for
25505 -mno-speculate-indirect-jumps.
25506 (*indirect_jump<mode>_nospec): New define_insn.
25507 (tablejump): Emit different RTL for
25508 -mno-speculate-indirect-jumps.
25509 (tablejumpsi): Disable for -mno-speculate-indirect-jumps.
25510 (tablejumpsi_nospec): New define_expand.
25511 (tablejumpdi): Disable for -mno-speculate-indirect-jumps.
25512 (tablejumpdi_nospec): New define_expand.
25513 (*tablejump<mode>_internal1): Disable for
25514 -mno-speculate-indirect-jumps.
25515 (*tablejump<mode>_internal1_nospec): New define_insn.
25516 * config/rs6000/rs6000.opt (mspeculate-indirect-jumps): New
25517 option.
25518
25519 2018-01-16 Artyom Skrobov tyomitch@gmail.com
25520
25521 * caller-save.c (insert_save): Drop unnecessary parameter. All
25522 callers updated.
25523
25524 2018-01-16 Jakub Jelinek <jakub@redhat.com>
25525 Richard Biener <rguenth@suse.de>
25526
25527 PR libgomp/83590
25528 * gimplify.c (gimplify_one_sizepos): For is_gimple_constant (expr)
25529 return early, inline manually is_gimple_sizepos. Make sure if we
25530 call gimplify_expr we don't end up with a gimple constant.
25531 * tree.c (variably_modified_type_p): Don't return true for
25532 is_gimple_constant (_t). Inline manually is_gimple_sizepos.
25533 * gimplify.h (is_gimple_sizepos): Remove.
25534
25535 2018-01-16 Richard Sandiford <richard.sandiford@linaro.org>
25536
25537 PR tree-optimization/83857
25538 * tree-vect-loop.c (vect_analyze_loop_operations): Don't call
25539 vectorizable_live_operation for pure SLP statements.
25540 (vectorizable_live_operation): Handle PHIs.
25541
25542 2018-01-16 Richard Biener <rguenther@suse.de>
25543
25544 PR tree-optimization/83867
25545 * tree-vect-stmts.c (vect_transform_stmt): Precompute
25546 nested_in_vect_loop_p since the scalar stmt may get invalidated.
25547
25548 2018-01-16 Jakub Jelinek <jakub@redhat.com>
25549
25550 PR c/83844
25551 * stor-layout.c (handle_warn_if_not_align): Use byte_position and
25552 multiple_of_p instead of unchecked tree_to_uhwi and UHWI check.
25553 If off is not INTEGER_CST, issue a may not be aligned warning
25554 rather than isn't aligned. Use isn%'t rather than isn't.
25555 * fold-const.c (multiple_of_p) <case BIT_AND_EXPR>: Don't fall through
25556 into MULT_EXPR.
25557 <case MULT_EXPR>: Improve the case when bottom and one of the
25558 MULT_EXPR operands are INTEGER_CSTs and bottom is multiple of that
25559 operand, in that case check if the other operand is multiple of
25560 bottom divided by the INTEGER_CST operand.
25561
25562 2018-01-16 Richard Sandiford <richard.sandiford@linaro.org>
25563
25564 PR target/83858
25565 * config/pa/pa.h (FUNCTION_ARG_SIZE): Delete.
25566 * config/pa/pa-protos.h (pa_function_arg_size): Declare.
25567 * config/pa/som.h (ASM_DECLARE_FUNCTION_NAME): Use
25568 pa_function_arg_size instead of FUNCTION_ARG_SIZE.
25569 * config/pa/pa.c (pa_function_arg_advance): Likewise.
25570 (pa_function_arg, pa_arg_partial_bytes): Likewise.
25571 (pa_function_arg_size): New function.
25572
25573 2018-01-16 Richard Sandiford <richard.sandiford@linaro.org>
25574
25575 * fold-const.c (fold_ternary_loc): Construct the vec_perm_indices
25576 in a separate statement.
25577
25578 2018-01-16 Richard Sandiford <richard.sandiford@linaro.org>
25579
25580 PR tree-optimization/83847
25581 * tree-vect-data-refs.c (vect_analyze_data_ref_accesses): Don't
25582 group gathers and scatters.
25583
25584 2018-01-16 Jakub Jelinek <jakub@redhat.com>
25585
25586 PR rtl-optimization/86620
25587 * params.def (max-sched-ready-insns): Bump minimum value to 1.
25588
25589 PR rtl-optimization/83213
25590 * recog.c (peep2_attempt): Copy over CROSSING_JUMP_P from peepinsn
25591 to last if both are JUMP_INSNs.
25592
25593 PR tree-optimization/83843
25594 * gimple-ssa-store-merging.c
25595 (imm_store_chain_info::output_merged_store): Handle bit_not_p on
25596 store_immediate_info for bswap/nop orig_stores.
25597
25598 2018-01-15 Andrew Waterman <andrew@sifive.com>
25599
25600 * config/riscv/riscv.c (riscv_rtx_costs) <MULT>: Increase cost if
25601 !TARGET_MUL.
25602 <UDIV>: Increase cost if !TARGET_DIV.
25603
25604 2018-01-15 Segher Boessenkool <segher@kernel.crashing.org>
25605
25606 * config/rs6000/rs6000.md (define_attr "type"): Remove delayed_cr.
25607 (define_attr "cr_logical_3op"): New.
25608 (cceq_ior_compare): Adjust.
25609 (cceq_ior_compare_complement): Adjust.
25610 (*cceq_rev_compare): Adjust.
25611 * config/rs6000/rs6000.c (rs6000_adjust_cost): Adjust.
25612 (is_cracked_insn): Adjust.
25613 (insn_must_be_first_in_group): Adjust.
25614 * config/rs6000/40x.md: Adjust.
25615 * config/rs6000/440.md: Adjust.
25616 * config/rs6000/476.md: Adjust.
25617 * config/rs6000/601.md: Adjust.
25618 * config/rs6000/603.md: Adjust.
25619 * config/rs6000/6xx.md: Adjust.
25620 * config/rs6000/7450.md: Adjust.
25621 * config/rs6000/7xx.md: Adjust.
25622 * config/rs6000/8540.md: Adjust.
25623 * config/rs6000/cell.md: Adjust.
25624 * config/rs6000/e300c2c3.md: Adjust.
25625 * config/rs6000/e500mc.md: Adjust.
25626 * config/rs6000/e500mc64.md: Adjust.
25627 * config/rs6000/e5500.md: Adjust.
25628 * config/rs6000/e6500.md: Adjust.
25629 * config/rs6000/mpc.md: Adjust.
25630 * config/rs6000/power4.md: Adjust.
25631 * config/rs6000/power5.md: Adjust.
25632 * config/rs6000/power6.md: Adjust.
25633 * config/rs6000/power7.md: Adjust.
25634 * config/rs6000/power8.md: Adjust.
25635 * config/rs6000/power9.md: Adjust.
25636 * config/rs6000/rs64.md: Adjust.
25637 * config/rs6000/titan.md: Adjust.
25638
25639 2018-01-15 H.J. Lu <hongjiu.lu@intel.com>
25640
25641 * config/i386/predicates.md (indirect_branch_operand): Rewrite
25642 ix86_indirect_branch_register logic.
25643
25644 2018-01-15 H.J. Lu <hongjiu.lu@intel.com>
25645
25646 * config/i386/constraints.md (Bs): Update
25647 ix86_indirect_branch_register check. Don't check
25648 ix86_indirect_branch_register with GOT_memory_operand.
25649 (Bw): Likewise.
25650 * config/i386/predicates.md (GOT_memory_operand): Don't check
25651 ix86_indirect_branch_register here.
25652 (GOT32_symbol_operand): Likewise.
25653
25654 2018-01-15 H.J. Lu <hongjiu.lu@intel.com>
25655
25656 * config/i386/predicates.md (constant_call_address_operand):
25657 Rewrite ix86_indirect_branch_register logic.
25658 (sibcall_insn_operand): Likewise.
25659
25660 2018-01-15 H.J. Lu <hongjiu.lu@intel.com>
25661
25662 * config/i386/constraints.md (Bs): Replace
25663 ix86_indirect_branch_thunk_register with
25664 ix86_indirect_branch_register.
25665 (Bw): Likewise.
25666 * config/i386/i386.md (indirect_jump): Likewise.
25667 (tablejump): Likewise.
25668 (*sibcall_memory): Likewise.
25669 (*sibcall_value_memory): Likewise.
25670 Peepholes of indirect call and jump via memory: Likewise.
25671 * config/i386/i386.opt: Likewise.
25672 * config/i386/predicates.md (indirect_branch_operand): Likewise.
25673 (GOT_memory_operand): Likewise.
25674 (call_insn_operand): Likewise.
25675 (sibcall_insn_operand): Likewise.
25676 (GOT32_symbol_operand): Likewise.
25677
25678 2018-01-15 Jakub Jelinek <jakub@redhat.com>
25679
25680 PR middle-end/83837
25681 * omp-expand.c (expand_omp_atomic_pipeline): Use loaded_val
25682 type rather than type addr's type points to.
25683 (expand_omp_atomic_mutex): Likewise.
25684 (expand_omp_atomic): Likewise.
25685
25686 2018-01-15 H.J. Lu <hongjiu.lu@intel.com>
25687
25688 PR target/83839
25689 * config/i386/i386.c (output_indirect_thunk_function): Use
25690 ASM_OUTPUT_LABEL, instead of ASM_OUTPUT_DEF, for TARGET_MACHO
25691 for __x86_return_thunk.
25692
25693 2018-01-15 Richard Biener <rguenther@suse.de>
25694
25695 PR middle-end/83850
25696 * expmed.c (extract_bit_field_1): Fix typo.
25697
25698 2018-01-15 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
25699
25700 PR target/83687
25701 * config/arm/iterators.md (VF): New mode iterator.
25702 * config/arm/neon.md (neon_vabd<mode>_2): Use the above.
25703 Remove integer-related logic from pattern.
25704 (neon_vabd<mode>_3): Likewise.
25705
25706 2018-01-15 Jakub Jelinek <jakub@redhat.com>
25707
25708 PR middle-end/82694
25709 * common.opt (fstrict-overflow): No longer an alias.
25710 (fwrapv-pointer): New option.
25711 * tree.h (TYPE_OVERFLOW_WRAPS, TYPE_OVERFLOW_UNDEFINED): Define
25712 also for pointer types based on flag_wrapv_pointer.
25713 * opts.c (common_handle_option) <case OPT_fstrict_overflow>: Set
25714 opts->x_flag_wrap[pv] to !value, clear opts->x_flag_trapv if
25715 opts->x_flag_wrapv got set.
25716 * fold-const.c (fold_comparison, fold_binary_loc): Revert 2017-08-01
25717 changes, just use TYPE_OVERFLOW_UNDEFINED on pointer type instead of
25718 POINTER_TYPE_OVERFLOW_UNDEFINED.
25719 * match.pd: Likewise in address comparison pattern.
25720 * doc/invoke.texi: Document -fwrapv and -fstrict-overflow.
25721
25722 2018-01-15 Richard Biener <rguenther@suse.de>
25723
25724 PR lto/83804
25725 * tree.c (free_lang_data_in_type): Always unlink TYPE_DECLs
25726 from TYPE_FIELDS. Free TYPE_BINFO if not used by devirtualization.
25727 Reset type names to their identifier if their TYPE_DECL doesn't
25728 have linkage (and thus is used for ODR and devirt).
25729 (save_debug_info_for_decl): Remove.
25730 (save_debug_info_for_type): Likewise.
25731 (add_tree_to_fld_list): Adjust.
25732 * tree-pretty-print.c (dump_generic_node): Make dumping of
25733 type names more robust.
25734
25735 2018-01-15 Richard Biener <rguenther@suse.de>
25736
25737 * BASE-VER: Bump to 8.0.1.
25738
25739 2018-01-14 Martin Sebor <msebor@redhat.com>
25740
25741 PR other/83508
25742 * builtins.c (check_access): Avoid warning when the no-warning bit
25743 is set.
25744
25745 2018-01-14 Cory Fields <cory-nospam-@coryfields.com>
25746
25747 * tree-ssa-loop-im.c (sort_bbs_in_loop_postorder_cmp): Stabilize sort.
25748 * ira-color (allocno_hard_regs_compare): Likewise.
25749
25750 2018-01-14 Nathan Rossi <nathan@nathanrossi.com>
25751
25752 PR target/83013
25753 * config/microblaze/microblaze.c (microblaze_asm_output_ident):
25754 Use .pushsection/.popsection.
25755
25756 2018-01-14 Martin Sebor <msebor@redhat.com>
25757
25758 PR c++/81327
25759 * doc/invoke.texi (-Wlass-memaccess): Document suppression by casting.
25760
25761 2018-01-14 Jakub Jelinek <jakub@redhat.com>
25762
25763 * config.gcc (i[34567]86-*-*): Remove one duplicate gfniintrin.h
25764 entry from extra_headers.
25765 (x86_64-*-*): Remove two duplicate gfniintrin.h entries from
25766 extra_headers, make the list bitwise identical to the i?86-*-* one.
25767
25768 2018-01-14 H.J. Lu <hongjiu.lu@intel.com>
25769
25770 * config/i386/i386.c (ix86_set_indirect_branch_type): Disallow
25771 -mcmodel=large with -mindirect-branch=thunk,
25772 -mindirect-branch=thunk-extern, -mfunction-return=thunk and
25773 -mfunction-return=thunk-extern.
25774 * doc/invoke.texi: Document -mcmodel=large is incompatible with
25775 -mindirect-branch=thunk, -mindirect-branch=thunk-extern,
25776 -mfunction-return=thunk and -mfunction-return=thunk-extern.
25777
25778 2018-01-14 H.J. Lu <hongjiu.lu@intel.com>
25779
25780 * config/i386/i386.c (print_reg): Print the name of the full
25781 integer register without '%'.
25782 (ix86_print_operand): Handle 'V'.
25783 * doc/extend.texi: Document 'V' modifier.
25784
25785 2018-01-14 H.J. Lu <hongjiu.lu@intel.com>
25786
25787 * config/i386/constraints.md (Bs): Disallow memory operand for
25788 -mindirect-branch-register.
25789 (Bw): Likewise.
25790 * config/i386/predicates.md (indirect_branch_operand): Likewise.
25791 (GOT_memory_operand): Likewise.
25792 (call_insn_operand): Likewise.
25793 (sibcall_insn_operand): Likewise.
25794 (GOT32_symbol_operand): Likewise.
25795 * config/i386/i386.md (indirect_jump): Call convert_memory_address
25796 for -mindirect-branch-register.
25797 (tablejump): Likewise.
25798 (*sibcall_memory): Likewise.
25799 (*sibcall_value_memory): Likewise.
25800 Disallow peepholes of indirect call and jump via memory for
25801 -mindirect-branch-register.
25802 (*call_pop): Replace m with Bw.
25803 (*call_value_pop): Likewise.
25804 (*sibcall_pop_memory): Replace m with Bs.
25805 * config/i386/i386.opt (mindirect-branch-register): New option.
25806 * doc/invoke.texi: Document -mindirect-branch-register option.
25807
25808 2018-01-14 H.J. Lu <hongjiu.lu@intel.com>
25809
25810 * config/i386/i386-protos.h (ix86_output_function_return): New.
25811 * config/i386/i386.c (ix86_set_indirect_branch_type): Also
25812 set function_return_type.
25813 (indirect_thunk_name): Add ret_p to indicate thunk for function
25814 return.
25815 (output_indirect_thunk_function): Pass false to
25816 indirect_thunk_name.
25817 (ix86_output_indirect_branch_via_reg): Likewise.
25818 (ix86_output_indirect_branch_via_push): Likewise.
25819 (output_indirect_thunk_function): Create alias for function
25820 return thunk if regno < 0.
25821 (ix86_output_function_return): New function.
25822 (ix86_handle_fndecl_attribute): Handle function_return.
25823 (ix86_attribute_table): Add function_return.
25824 * config/i386/i386.h (machine_function): Add
25825 function_return_type.
25826 * config/i386/i386.md (simple_return_internal): Use
25827 ix86_output_function_return.
25828 (simple_return_internal_long): Likewise.
25829 * config/i386/i386.opt (mfunction-return=): New option.
25830 (indirect_branch): Mention -mfunction-return=.
25831 * doc/extend.texi: Document function_return function attribute.
25832 * doc/invoke.texi: Document -mfunction-return= option.
25833
25834 2018-01-14 H.J. Lu <hongjiu.lu@intel.com>
25835
25836 * config/i386/i386-opts.h (indirect_branch): New.
25837 * config/i386/i386-protos.h (ix86_output_indirect_jmp): Likewise.
25838 * config/i386/i386.c (ix86_using_red_zone): Disallow red-zone
25839 with local indirect jump when converting indirect call and jump.
25840 (ix86_set_indirect_branch_type): New.
25841 (ix86_set_current_function): Call ix86_set_indirect_branch_type.
25842 (indirectlabelno): New.
25843 (indirect_thunk_needed): Likewise.
25844 (indirect_thunk_bnd_needed): Likewise.
25845 (indirect_thunks_used): Likewise.
25846 (indirect_thunks_bnd_used): Likewise.
25847 (INDIRECT_LABEL): Likewise.
25848 (indirect_thunk_name): Likewise.
25849 (output_indirect_thunk): Likewise.
25850 (output_indirect_thunk_function): Likewise.
25851 (ix86_output_indirect_branch_via_reg): Likewise.
25852 (ix86_output_indirect_branch_via_push): Likewise.
25853 (ix86_output_indirect_branch): Likewise.
25854 (ix86_output_indirect_jmp): Likewise.
25855 (ix86_code_end): Call output_indirect_thunk_function if needed.
25856 (ix86_output_call_insn): Call ix86_output_indirect_branch if
25857 needed.
25858 (ix86_handle_fndecl_attribute): Handle indirect_branch.
25859 (ix86_attribute_table): Add indirect_branch.
25860 * config/i386/i386.h (machine_function): Add indirect_branch_type
25861 and has_local_indirect_jump.
25862 * config/i386/i386.md (indirect_jump): Set has_local_indirect_jump
25863 to true.
25864 (tablejump): Likewise.
25865 (*indirect_jump): Use ix86_output_indirect_jmp.
25866 (*tablejump_1): Likewise.
25867 (simple_return_indirect_internal): Likewise.
25868 * config/i386/i386.opt (mindirect-branch=): New option.
25869 (indirect_branch): New.
25870 (keep): Likewise.
25871 (thunk): Likewise.
25872 (thunk-inline): Likewise.
25873 (thunk-extern): Likewise.
25874 * doc/extend.texi: Document indirect_branch function attribute.
25875 * doc/invoke.texi: Document -mindirect-branch= option.
25876
25877 2018-01-14 Jan Hubicka <hubicka@ucw.cz>
25878
25879 PR ipa/83051
25880 * ipa-inline.c (edge_badness): Tolerate roundoff errors.
25881
25882 2018-01-14 Richard Sandiford <richard.sandiford@linaro.org>
25883
25884 * ipa-inline.c (want_inline_small_function_p): Return false if
25885 inlining has already failed with CIF_FINAL_ERROR.
25886 (update_caller_keys): Call want_inline_small_function_p before
25887 can_inline_edge_p.
25888 (update_callee_keys): Likewise.
25889
25890 2018-01-10 Kelvin Nilsen <kelvin@gcc.gnu.org>
25891
25892 * config/rs6000/rs6000-p8swap.c (rs6000_sum_of_two_registers_p):
25893 New function.
25894 (rs6000_quadword_masked_address_p): Likewise.
25895 (quad_aligned_load_p): Likewise.
25896 (quad_aligned_store_p): Likewise.
25897 (const_load_sequence_p): Add comment to describe the outer-most loop.
25898 (mimic_memory_attributes_and_flags): New function.
25899 (rs6000_gen_stvx): Likewise.
25900 (replace_swapped_aligned_store): Likewise.
25901 (rs6000_gen_lvx): Likewise.
25902 (replace_swapped_aligned_load): Likewise.
25903 (replace_swapped_load_constant): Capitalize argument name in
25904 comment describing this function.
25905 (rs6000_analyze_swaps): Add a third pass to search for vector loads
25906 and stores that access quad-word aligned addresses and replace
25907 with stvx or lvx instructions when appropriate.
25908 * config/rs6000/rs6000-protos.h (rs6000_sum_of_two_registers_p):
25909 New function prototype.
25910 (rs6000_quadword_masked_address_p): Likewise.
25911 (rs6000_gen_lvx): Likewise.
25912 (rs6000_gen_stvx): Likewise.
25913 * config/rs6000/vsx.md (*vsx_le_perm_load_<mode>): For modes
25914 VSX_D (V2DF, V2DI), modify this split to select lvx instruction
25915 when memory address is aligned.
25916 (*vsx_le_perm_load_<mode>): For modes VSX_W (V4SF, V4SI), modify
25917 this split to select lvx instruction when memory address is aligned.
25918 (*vsx_le_perm_load_v8hi): Modify this split to select lvx
25919 instruction when memory address is aligned.
25920 (*vsx_le_perm_load_v16qi): Likewise.
25921 (four unnamed splitters): Modify to select the stvx instruction
25922 when memory is aligned.
25923
25924 2018-01-13 Jan Hubicka <hubicka@ucw.cz>
25925
25926 * predict.c (determine_unlikely_bbs): Handle correctly BBs
25927 which appears in the queue multiple times.
25928
25929 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
25930 Alan Hayward <alan.hayward@arm.com>
25931 David Sherwood <david.sherwood@arm.com>
25932
25933 * tree-vectorizer.h (vec_lower_bound): New structure.
25934 (_loop_vec_info): Add check_nonzero and lower_bounds.
25935 (LOOP_VINFO_CHECK_NONZERO): New macro.
25936 (LOOP_VINFO_LOWER_BOUNDS): Likewise.
25937 (LOOP_REQUIRES_VERSIONING_FOR_ALIAS): Check lower_bounds too.
25938 * tree-data-ref.h (dr_with_seg_len): Add access_size and align
25939 fields. Make seg_len the distance travelled, not including the
25940 access size.
25941 (dr_direction_indicator): Declare.
25942 (dr_zero_step_indicator): Likewise.
25943 (dr_known_forward_stride_p): Likewise.
25944 * tree-data-ref.c: Include stringpool.h, tree-vrp.h and
25945 tree-ssanames.h.
25946 (runtime_alias_check_p): Allow runtime alias checks with
25947 variable strides.
25948 (operator ==): Compare access_size and align.
25949 (prune_runtime_alias_test_list): Rework for new distinction between
25950 the access_size and seg_len.
25951 (create_intersect_range_checks_index): Likewise. Cope with polynomial
25952 segment lengths.
25953 (get_segment_min_max): New function.
25954 (create_intersect_range_checks): Use it.
25955 (dr_step_indicator): New function.
25956 (dr_direction_indicator): Likewise.
25957 (dr_zero_step_indicator): Likewise.
25958 (dr_known_forward_stride_p): Likewise.
25959 * tree-loop-distribution.c (data_ref_segment_size): Return
25960 DR_STEP * (niters - 1).
25961 (compute_alias_check_pairs): Update call to the dr_with_seg_len
25962 constructor.
25963 * tree-vect-data-refs.c (vect_check_nonzero_value): New function.
25964 (vect_preserves_scalar_order_p): New function, split out from...
25965 (vect_analyze_data_ref_dependence): ...here. Check for zero steps.
25966 (vect_vfa_segment_size): Return DR_STEP * (length_factor - 1).
25967 (vect_vfa_access_size): New function.
25968 (vect_vfa_align): Likewise.
25969 (vect_compile_time_alias): Take access_size_a and access_b arguments.
25970 (dump_lower_bound): New function.
25971 (vect_check_lower_bound): Likewise.
25972 (vect_small_gap_p): Likewise.
25973 (vectorizable_with_step_bound_p): Likewise.
25974 (vect_prune_runtime_alias_test_list): Ignore cross-iteration
25975 depencies if the vectorization factor is 1. Convert the checks
25976 for nonzero steps into checks on the bounds of DR_STEP. Try using
25977 a bunds check for variable steps if the minimum required step is
25978 relatively small. Update calls to the dr_with_seg_len
25979 constructor and to vect_compile_time_alias.
25980 * tree-vect-loop-manip.c (vect_create_cond_for_lower_bounds): New
25981 function.
25982 (vect_loop_versioning): Call it.
25983 * tree-vect-loop.c (vect_analyze_loop_2): Clear LOOP_VINFO_LOWER_BOUNDS
25984 when retrying.
25985 (vect_estimate_min_profitable_iters): Account for any bounds checks.
25986
25987 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
25988 Alan Hayward <alan.hayward@arm.com>
25989 David Sherwood <david.sherwood@arm.com>
25990
25991 * doc/sourcebuild.texi (vect_scatter_store): Document.
25992 * optabs.def (scatter_store_optab, mask_scatter_store_optab): New
25993 optabs.
25994 * doc/md.texi (scatter_store@var{m}, mask_scatter_store@var{m}):
25995 Document.
25996 * genopinit.c (main): Add supports_vec_scatter_store and
25997 supports_vec_scatter_store_cached to target_optabs.
25998 * gimple.h (gimple_expr_type): Handle IFN_SCATTER_STORE and
25999 IFN_MASK_SCATTER_STORE.
26000 * internal-fn.def (SCATTER_STORE, MASK_SCATTER_STORE): New internal
26001 functions.
26002 * internal-fn.h (internal_store_fn_p): Declare.
26003 (internal_fn_stored_value_index): Likewise.
26004 * internal-fn.c (scatter_store_direct): New macro.
26005 (expand_scatter_store_optab_fn): New function.
26006 (direct_scatter_store_optab_supported_p): New macro.
26007 (internal_store_fn_p): New function.
26008 (internal_gather_scatter_fn_p): Handle IFN_SCATTER_STORE and
26009 IFN_MASK_SCATTER_STORE.
26010 (internal_fn_mask_index): Likewise.
26011 (internal_fn_stored_value_index): New function.
26012 (internal_gather_scatter_fn_supported_p): Adjust operand numbers
26013 for scatter stores.
26014 * optabs-query.h (supports_vec_scatter_store_p): Declare.
26015 * optabs-query.c (supports_vec_scatter_store_p): New function.
26016 * tree-vectorizer.h (vect_get_store_rhs): Declare.
26017 * tree-vect-data-refs.c (vect_analyze_data_ref_access): Return
26018 true for scatter stores.
26019 (vect_gather_scatter_fn_p): Handle scatter stores too.
26020 (vect_check_gather_scatter): Consider using scatter stores if
26021 supports_vec_scatter_store_p.
26022 * tree-vect-patterns.c (vect_try_gather_scatter_pattern): Handle
26023 scatter stores too.
26024 * tree-vect-stmts.c (exist_non_indexing_operands_for_use_p): Use
26025 internal_fn_stored_value_index.
26026 (check_load_store_masking): Handle scatter stores too.
26027 (vect_get_store_rhs): Make public.
26028 (vectorizable_call): Use internal_store_fn_p.
26029 (vectorizable_store): Handle scatter store internal functions.
26030 (vect_transform_stmt): Compare GROUP_STORE_COUNT with GROUP_SIZE
26031 when deciding whether the end of the group has been reached.
26032 * config/aarch64/aarch64.md (UNSPEC_ST1_SCATTER): New unspec.
26033 * config/aarch64/aarch64-sve.md (scatter_store<mode>): New expander.
26034 (mask_scatter_store<mode>): New insns.
26035
26036 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
26037 Alan Hayward <alan.hayward@arm.com>
26038 David Sherwood <david.sherwood@arm.com>
26039
26040 * tree-vectorizer.h (vect_gather_scatter_fn_p): Declare.
26041 * tree-vect-data-refs.c (vect_gather_scatter_fn_p): Make public.
26042 * tree-vect-stmts.c (vect_truncate_gather_scatter_offset): New
26043 function.
26044 (vect_use_strided_gather_scatters_p): Take a masked_p argument.
26045 Use vect_truncate_gather_scatter_offset if we can't treat the
26046 operation as a normal gather load or scatter store.
26047 (get_group_load_store_type): Take the gather_scatter_info
26048 as argument. Try using a gather load or scatter store for
26049 single-element groups.
26050 (get_load_store_type): Update calls to get_group_load_store_type
26051 and vect_use_strided_gather_scatters_p.
26052
26053 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
26054 Alan Hayward <alan.hayward@arm.com>
26055 David Sherwood <david.sherwood@arm.com>
26056
26057 * tree-vectorizer.h (vect_create_data_ref_ptr): Take an extra
26058 optional tree argument.
26059 * tree-vect-data-refs.c (vect_check_gather_scatter): Check for
26060 null target hooks.
26061 (vect_create_data_ref_ptr): Take the iv_step as an optional argument,
26062 but continue to use the current value as a fallback.
26063 (bump_vector_ptr): Use operand_equal_p rather than tree_int_cst_compare
26064 to compare the updates.
26065 * tree-vect-stmts.c (vect_use_strided_gather_scatters_p): New function.
26066 (get_load_store_type): Use it when handling a strided access.
26067 (vect_get_strided_load_store_ops): New function.
26068 (vect_get_data_ptr_increment): Likewise.
26069 (vectorizable_load): Handle strided gather loads. Always pass
26070 a step to vect_create_data_ref_ptr and bump_vector_ptr.
26071
26072 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
26073 Alan Hayward <alan.hayward@arm.com>
26074 David Sherwood <david.sherwood@arm.com>
26075
26076 * doc/md.texi (gather_load@var{m}): Document.
26077 (mask_gather_load@var{m}): Likewise.
26078 * genopinit.c (main): Add supports_vec_gather_load and
26079 supports_vec_gather_load_cached to target_optabs.
26080 * optabs-tree.c (init_tree_optimization_optabs): Use
26081 ggc_cleared_alloc to allocate target_optabs.
26082 * optabs.def (gather_load_optab, mask_gather_laod_optab): New optabs.
26083 * internal-fn.def (GATHER_LOAD, MASK_GATHER_LOAD): New internal
26084 functions.
26085 * internal-fn.h (internal_load_fn_p): Declare.
26086 (internal_gather_scatter_fn_p): Likewise.
26087 (internal_fn_mask_index): Likewise.
26088 (internal_gather_scatter_fn_supported_p): Likewise.
26089 * internal-fn.c (gather_load_direct): New macro.
26090 (expand_gather_load_optab_fn): New function.
26091 (direct_gather_load_optab_supported_p): New macro.
26092 (direct_internal_fn_optab): New function.
26093 (internal_load_fn_p): Likewise.
26094 (internal_gather_scatter_fn_p): Likewise.
26095 (internal_fn_mask_index): Likewise.
26096 (internal_gather_scatter_fn_supported_p): Likewise.
26097 * optabs-query.c (supports_at_least_one_mode_p): New function.
26098 (supports_vec_gather_load_p): Likewise.
26099 * optabs-query.h (supports_vec_gather_load_p): Declare.
26100 * tree-vectorizer.h (gather_scatter_info): Add ifn, element_type
26101 and memory_type field.
26102 (NUM_PATTERNS): Bump to 15.
26103 * tree-vect-data-refs.c: Include internal-fn.h.
26104 (vect_gather_scatter_fn_p): New function.
26105 (vect_describe_gather_scatter_call): Likewise.
26106 (vect_check_gather_scatter): Try using internal functions for
26107 gather loads. Recognize existing calls to a gather load function.
26108 (vect_analyze_data_refs): Consider using gather loads if
26109 supports_vec_gather_load_p.
26110 * tree-vect-patterns.c (vect_get_load_store_mask): New function.
26111 (vect_get_gather_scatter_offset_type): Likewise.
26112 (vect_convert_mask_for_vectype): Likewise.
26113 (vect_add_conversion_to_patterm): Likewise.
26114 (vect_try_gather_scatter_pattern): Likewise.
26115 (vect_recog_gather_scatter_pattern): New pattern recognizer.
26116 (vect_vect_recog_func_ptrs): Add it.
26117 * tree-vect-stmts.c (exist_non_indexing_operands_for_use_p): Use
26118 internal_fn_mask_index and internal_gather_scatter_fn_p.
26119 (check_load_store_masking): Take the gather_scatter_info as an
26120 argument and handle gather loads.
26121 (vect_get_gather_scatter_ops): New function.
26122 (vectorizable_call): Check internal_load_fn_p.
26123 (vectorizable_load): Likewise. Handle gather load internal
26124 functions.
26125 (vectorizable_store): Update call to check_load_store_masking.
26126 * config/aarch64/aarch64.md (UNSPEC_LD1_GATHER): New unspec.
26127 * config/aarch64/iterators.md (SVE_S, SVE_D): New mode iterators.
26128 * config/aarch64/predicates.md (aarch64_gather_scale_operand_w)
26129 (aarch64_gather_scale_operand_d): New predicates.
26130 * config/aarch64/aarch64-sve.md (gather_load<mode>): New expander.
26131 (mask_gather_load<mode>): New insns.
26132
26133 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
26134 Alan Hayward <alan.hayward@arm.com>
26135 David Sherwood <david.sherwood@arm.com>
26136
26137 * optabs.def (fold_left_plus_optab): New optab.
26138 * doc/md.texi (fold_left_plus_@var{m}): Document.
26139 * internal-fn.def (IFN_FOLD_LEFT_PLUS): New internal function.
26140 * internal-fn.c (fold_left_direct): Define.
26141 (expand_fold_left_optab_fn): Likewise.
26142 (direct_fold_left_optab_supported_p): Likewise.
26143 * fold-const-call.c (fold_const_fold_left): New function.
26144 (fold_const_call): Use it to fold CFN_FOLD_LEFT_PLUS.
26145 * tree-parloops.c (valid_reduction_p): New function.
26146 (gather_scalar_reductions): Use it.
26147 * tree-vectorizer.h (FOLD_LEFT_REDUCTION): New vect_reduction_type.
26148 (vect_finish_replace_stmt): Declare.
26149 * tree-vect-loop.c (fold_left_reduction_fn): New function.
26150 (needs_fold_left_reduction_p): New function, split out from...
26151 (vect_is_simple_reduction): ...here. Accept reductions that
26152 forbid reassociation, but give them type FOLD_LEFT_REDUCTION.
26153 (vect_force_simple_reduction): Also store the reduction type in
26154 the assignment's STMT_VINFO_REDUC_TYPE.
26155 (vect_model_reduction_cost): Handle FOLD_LEFT_REDUCTION.
26156 (merge_with_identity): New function.
26157 (vect_expand_fold_left): Likewise.
26158 (vectorize_fold_left_reduction): Likewise.
26159 (vectorizable_reduction): Handle FOLD_LEFT_REDUCTION. Leave the
26160 scalar phi in place for it. Check for target support and reject
26161 cases that would reassociate the operation. Defer the transform
26162 phase to vectorize_fold_left_reduction.
26163 * config/aarch64/aarch64.md (UNSPEC_FADDA): New unspec.
26164 * config/aarch64/aarch64-sve.md (fold_left_plus_<mode>): New expander.
26165 (*fold_left_plus_<mode>, *pred_fold_left_plus_<mode>): New insns.
26166
26167 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
26168
26169 * tree-if-conv.c (predicate_mem_writes): Remove redundant
26170 call to ifc_temp_var.
26171
26172 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
26173 Alan Hayward <alan.hayward@arm.com>
26174 David Sherwood <david.sherwood@arm.com>
26175
26176 * target.def (legitimize_address_displacement): Take the original
26177 offset as a poly_int.
26178 * targhooks.h (default_legitimize_address_displacement): Update
26179 accordingly.
26180 * targhooks.c (default_legitimize_address_displacement): Likewise.
26181 * doc/tm.texi: Regenerate.
26182 * lra-constraints.c (base_plus_disp_to_reg): Take the displacement
26183 as an argument, moving assert of ad->disp == ad->disp_term to...
26184 (process_address_1): ...here. Update calls to base_plus_disp_to_reg.
26185 Try calling targetm.legitimize_address_displacement before expanding
26186 the address rather than afterwards, and adjust for the new interface.
26187 * config/aarch64/aarch64.c (aarch64_legitimize_address_displacement):
26188 Match the new hook interface. Handle SVE addresses.
26189 * config/sh/sh.c (sh_legitimize_address_displacement): Make the
26190 new hook interface.
26191
26192 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
26193
26194 * Makefile.in (OBJS): Add early-remat.o.
26195 * target.def (select_early_remat_modes): New hook.
26196 * doc/tm.texi.in (TARGET_SELECT_EARLY_REMAT_MODES): New hook.
26197 * doc/tm.texi: Regenerate.
26198 * targhooks.h (default_select_early_remat_modes): Declare.
26199 * targhooks.c (default_select_early_remat_modes): New function.
26200 * timevar.def (TV_EARLY_REMAT): New timevar.
26201 * passes.def (pass_early_remat): New pass.
26202 * tree-pass.h (make_pass_early_remat): Declare.
26203 * early-remat.c: New file.
26204 * config/aarch64/aarch64.c (aarch64_select_early_remat_modes): New
26205 function.
26206 (TARGET_SELECT_EARLY_REMAT_MODES): Define.
26207
26208 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
26209 Alan Hayward <alan.hayward@arm.com>
26210 David Sherwood <david.sherwood@arm.com>
26211
26212 * tree-vect-loop-manip.c (vect_gen_scalar_loop_niters): Replace
26213 vfm1 with a bound_epilog parameter.
26214 (vect_do_peeling): Update calls accordingly, and move the prologue
26215 call earlier in the function. Treat the base bound_epilog as 0 for
26216 fully-masked loops and retain vf - 1 for other loops. Add 1 to
26217 this base when peeling for gaps.
26218 * tree-vect-loop.c (vect_analyze_loop_2): Allow peeling for gaps
26219 with fully-masked loops.
26220 (vect_estimate_min_profitable_iters): Handle the single peeled
26221 iteration in that case.
26222
26223 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
26224 Alan Hayward <alan.hayward@arm.com>
26225 David Sherwood <david.sherwood@arm.com>
26226
26227 * tree-vect-data-refs.c (vect_analyze_group_access_1): Allow
26228 single-element interleaving even if the size is not a power of 2.
26229 * tree-vect-stmts.c (get_load_store_type): Disallow elementwise
26230 accesses for single-element interleaving if the group size is
26231 not a power of 2.
26232
26233 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
26234 Alan Hayward <alan.hayward@arm.com>
26235 David Sherwood <david.sherwood@arm.com>
26236
26237 * doc/md.texi (fold_extract_last_@var{m}): Document.
26238 * doc/sourcebuild.texi (vect_fold_extract_last): Likewise.
26239 * optabs.def (fold_extract_last_optab): New optab.
26240 * internal-fn.def (FOLD_EXTRACT_LAST): New internal function.
26241 * internal-fn.c (fold_extract_direct): New macro.
26242 (expand_fold_extract_optab_fn): Likewise.
26243 (direct_fold_extract_optab_supported_p): Likewise.
26244 * tree-vectorizer.h (EXTRACT_LAST_REDUCTION): New vect_reduction_type.
26245 * tree-vect-loop.c (vect_model_reduction_cost): Handle
26246 EXTRACT_LAST_REDUCTION.
26247 (get_initial_def_for_reduction): Do not create an initial vector
26248 for EXTRACT_LAST_REDUCTION reductions.
26249 (vectorizable_reduction): Leave the scalar phi in place for
26250 EXTRACT_LAST_REDUCTIONs. Try using EXTRACT_LAST_REDUCTION
26251 ahead of INTEGER_INDUC_COND_REDUCTION. Do not check for an
26252 epilogue code for EXTRACT_LAST_REDUCTION and defer the
26253 transform phase to vectorizable_condition.
26254 * tree-vect-stmts.c (vect_finish_stmt_generation_1): New function,
26255 split out from...
26256 (vect_finish_stmt_generation): ...here.
26257 (vect_finish_replace_stmt): New function.
26258 (vectorizable_condition): Handle EXTRACT_LAST_REDUCTION.
26259 * config/aarch64/aarch64-sve.md (fold_extract_last_<mode>): New
26260 pattern.
26261 * config/aarch64/aarch64.md (UNSPEC_CLASTB): New unspec.
26262
26263 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
26264 Alan Hayward <alan.hayward@arm.com>
26265 David Sherwood <david.sherwood@arm.com>
26266
26267 * doc/md.texi (extract_last_@var{m}): Document.
26268 * optabs.def (extract_last_optab): New optab.
26269 * internal-fn.def (EXTRACT_LAST): New internal function.
26270 * internal-fn.c (cond_unary_direct): New macro.
26271 (expand_cond_unary_optab_fn): Likewise.
26272 (direct_cond_unary_optab_supported_p): Likewise.
26273 * tree-vect-loop.c (vectorizable_live_operation): Allow fully-masked
26274 loops using EXTRACT_LAST.
26275 * config/aarch64/aarch64-sve.md (aarch64_sve_lastb<mode>): Rename to...
26276 (extract_last_<mode>): ...this optab.
26277 (vec_extract<mode><Vel>): Update accordingly.
26278
26279 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
26280 Alan Hayward <alan.hayward@arm.com>
26281 David Sherwood <david.sherwood@arm.com>
26282
26283 * target.def (empty_mask_is_expensive): New hook.
26284 * doc/tm.texi.in (TARGET_VECTORIZE_EMPTY_MASK_IS_EXPENSIVE): New hook.
26285 * doc/tm.texi: Regenerate.
26286 * targhooks.h (default_empty_mask_is_expensive): Declare.
26287 * targhooks.c (default_empty_mask_is_expensive): New function.
26288 * tree-vectorizer.c (vectorize_loops): Only call optimize_mask_stores
26289 if the target says that empty masks are expensive.
26290 * config/aarch64/aarch64.c (aarch64_empty_mask_is_expensive):
26291 New function.
26292 (TARGET_VECTORIZE_EMPTY_MASK_IS_EXPENSIVE): Redefine.
26293
26294 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
26295 Alan Hayward <alan.hayward@arm.com>
26296 David Sherwood <david.sherwood@arm.com>
26297
26298 * tree-vectorizer.h (_loop_vec_info::mask_skip_niters): New field.
26299 (LOOP_VINFO_MASK_SKIP_NITERS): New macro.
26300 (vect_use_loop_mask_for_alignment_p): New function.
26301 (vect_prepare_for_masked_peels, vect_gen_while_not): Declare.
26302 * tree-vect-loop-manip.c (vect_set_loop_masks_directly): Add an
26303 niters_skip argument. Make sure that the first niters_skip elements
26304 of the first iteration are inactive.
26305 (vect_set_loop_condition_masked): Handle LOOP_VINFO_MASK_SKIP_NITERS.
26306 Update call to vect_set_loop_masks_directly.
26307 (get_misalign_in_elems): New function, split out from...
26308 (vect_gen_prolog_loop_niters): ...here.
26309 (vect_update_init_of_dr): Take a code argument that specifies whether
26310 the adjustment should be added or subtracted.
26311 (vect_update_init_of_drs): Likewise.
26312 (vect_prepare_for_masked_peels): New function.
26313 (vect_do_peeling): Skip prologue peeling if we're using a mask
26314 instead. Update call to vect_update_inits_of_drs.
26315 * tree-vect-loop.c (_loop_vec_info::_loop_vec_info): Initialize
26316 mask_skip_niters.
26317 (vect_analyze_loop_2): Allow fully-masked loops with peeling for
26318 alignment. Do not include the number of peeled iterations in
26319 the minimum threshold in that case.
26320 (vectorizable_induction): Adjust the start value down by
26321 LOOP_VINFO_MASK_SKIP_NITERS iterations.
26322 (vect_transform_loop): Call vect_prepare_for_masked_peels.
26323 Take the number of skipped iterations into account when calculating
26324 the loop bounds.
26325 * tree-vect-stmts.c (vect_gen_while_not): New function.
26326
26327 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
26328 Alan Hayward <alan.hayward@arm.com>
26329 David Sherwood <david.sherwood@arm.com>
26330
26331 * doc/sourcebuild.texi (vect_fully_masked): Document.
26332 * params.def (PARAM_MIN_VECT_LOOP_BOUND): Change minimum and
26333 default value to 0.
26334 * tree-vect-loop.c (vect_analyze_loop_costing): New function,
26335 split out from...
26336 (vect_analyze_loop_2): ...here. Don't check the vectorization
26337 factor against the number of loop iterations if the loop is
26338 fully-masked.
26339
26340 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
26341 Alan Hayward <alan.hayward@arm.com>
26342 David Sherwood <david.sherwood@arm.com>
26343
26344 * tree-ssa-loop-ivopts.c (USE_ADDRESS): Split into...
26345 (USE_REF_ADDRESS, USE_PTR_ADDRESS): ...these new use types.
26346 (dump_groups): Update accordingly.
26347 (iv_use::mem_type): New member variable.
26348 (address_p): New function.
26349 (record_use): Add a mem_type argument and initialize the new
26350 mem_type field.
26351 (record_group_use): Add a mem_type argument. Use address_p.
26352 Remove obsolete null checks of base_object. Update call to record_use.
26353 (find_interesting_uses_op): Update call to record_group_use.
26354 (find_interesting_uses_cond): Likewise.
26355 (find_interesting_uses_address): Likewise.
26356 (get_mem_type_for_internal_fn): New function.
26357 (find_address_like_use): Likewise.
26358 (find_interesting_uses_stmt): Try find_address_like_use before
26359 calling find_interesting_uses_op.
26360 (addr_offset_valid_p): Use the iv mem_type field as the type
26361 of the addressed memory.
26362 (add_autoinc_candidates): Likewise.
26363 (get_address_cost): Likewise.
26364 (split_small_address_groups_p): Use address_p.
26365 (split_address_groups): Likewise.
26366 (add_iv_candidate_for_use): Likewise.
26367 (autoinc_possible_for_pair): Likewise.
26368 (rewrite_groups): Likewise.
26369 (get_use_type): Check for USE_REF_ADDRESS instead of USE_ADDRESS.
26370 (determine_group_iv_cost): Update after split of USE_ADDRESS.
26371 (get_alias_ptr_type_for_ptr_address): New function.
26372 (rewrite_use_address): Rewrite address uses in calls that were
26373 identified by find_address_like_use.
26374
26375 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
26376 Alan Hayward <alan.hayward@arm.com>
26377 David Sherwood <david.sherwood@arm.com>
26378
26379 * expr.c (expand_expr_addr_expr_1): Handle ADDR_EXPRs of
26380 TARGET_MEM_REFs.
26381 * gimple-expr.h (is_gimple_addressable: Likewise.
26382 * gimple-expr.c (is_gimple_address): Likewise.
26383 * internal-fn.c (expand_call_mem_ref): New function.
26384 (expand_mask_load_optab_fn): Use it.
26385 (expand_mask_store_optab_fn): Likewise.
26386
26387 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
26388 Alan Hayward <alan.hayward@arm.com>
26389 David Sherwood <david.sherwood@arm.com>
26390
26391 * doc/md.texi (cond_add@var{mode}, cond_sub@var{mode})
26392 (cond_and@var{mode}, cond_ior@var{mode}, cond_xor@var{mode})
26393 (cond_smin@var{mode}, cond_smax@var{mode}, cond_umin@var{mode})
26394 (cond_umax@var{mode}): Document.
26395 * optabs.def (cond_add_optab, cond_sub_optab, cond_and_optab)
26396 (cond_ior_optab, cond_xor_optab, cond_smin_optab, cond_smax_optab)
26397 (cond_umin_optab, cond_umax_optab): New optabs.
26398 * internal-fn.def (COND_ADD, COND_SUB, COND_MIN, COND_MAX, COND_AND)
26399 (COND_IOR, COND_XOR): New internal functions.
26400 * internal-fn.h (get_conditional_internal_fn): Declare.
26401 * internal-fn.c (cond_binary_direct): New macro.
26402 (expand_cond_binary_optab_fn): Likewise.
26403 (direct_cond_binary_optab_supported_p): Likewise.
26404 (get_conditional_internal_fn): New function.
26405 * tree-vect-loop.c (vectorizable_reduction): Handle fully-masked loops.
26406 Cope with reduction statements that are vectorized as calls rather
26407 than assignments.
26408 * config/aarch64/aarch64-sve.md (cond_<optab><mode>): New insns.
26409 * config/aarch64/iterators.md (UNSPEC_COND_ADD, UNSPEC_COND_SUB)
26410 (UNSPEC_COND_SMAX, UNSPEC_COND_UMAX, UNSPEC_COND_SMIN)
26411 (UNSPEC_COND_UMIN, UNSPEC_COND_AND, UNSPEC_COND_ORR)
26412 (UNSPEC_COND_EOR): New unspecs.
26413 (optab): Add mappings for them.
26414 (SVE_COND_INT_OP, SVE_COND_FP_OP): New int iterators.
26415 (sve_int_op, sve_fp_op): New int attributes.
26416
26417 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
26418 Alan Hayward <alan.hayward@arm.com>
26419 David Sherwood <david.sherwood@arm.com>
26420
26421 * optabs.def (while_ult_optab): New optab.
26422 * doc/md.texi (while_ult@var{m}@var{n}): Document.
26423 * internal-fn.def (WHILE_ULT): New internal function.
26424 * internal-fn.h (direct_internal_fn_supported_p): New override
26425 that takes two types as argument.
26426 * internal-fn.c (while_direct): New macro.
26427 (expand_while_optab_fn): New function.
26428 (convert_optab_supported_p): Likewise.
26429 (direct_while_optab_supported_p): New macro.
26430 * wide-int.h (wi::udiv_ceil): New function.
26431 * tree-vectorizer.h (rgroup_masks): New structure.
26432 (vec_loop_masks): New typedef.
26433 (_loop_vec_info): Add masks, mask_compare_type, can_fully_mask_p
26434 and fully_masked_p.
26435 (LOOP_VINFO_CAN_FULLY_MASK_P, LOOP_VINFO_FULLY_MASKED_P)
26436 (LOOP_VINFO_MASKS, LOOP_VINFO_MASK_COMPARE_TYPE): New macros.
26437 (vect_max_vf): New function.
26438 (slpeel_make_loop_iterate_ntimes): Delete.
26439 (vect_set_loop_condition, vect_get_loop_mask_type, vect_gen_while)
26440 (vect_halve_mask_nunits, vect_double_mask_nunits): Declare.
26441 (vect_record_loop_mask, vect_get_loop_mask): Likewise.
26442 * tree-vect-loop-manip.c: Include tree-ssa-loop-niter.h,
26443 internal-fn.h, stor-layout.h and optabs-query.h.
26444 (vect_set_loop_mask): New function.
26445 (add_preheader_seq): Likewise.
26446 (add_header_seq): Likewise.
26447 (interleave_supported_p): Likewise.
26448 (vect_maybe_permute_loop_masks): Likewise.
26449 (vect_set_loop_masks_directly): Likewise.
26450 (vect_set_loop_condition_masked): Likewise.
26451 (vect_set_loop_condition_unmasked): New function, split out from
26452 slpeel_make_loop_iterate_ntimes.
26453 (slpeel_make_loop_iterate_ntimes): Rename to..
26454 (vect_set_loop_condition): ...this. Use vect_set_loop_condition_masked
26455 for fully-masked loops and vect_set_loop_condition_unmasked otherwise.
26456 (vect_do_peeling): Update call accordingly.
26457 (vect_gen_vector_loop_niters): Use VF as the step for fully-masked
26458 loops.
26459 * tree-vect-loop.c (_loop_vec_info::_loop_vec_info): Initialize
26460 mask_compare_type, can_fully_mask_p and fully_masked_p.
26461 (release_vec_loop_masks): New function.
26462 (_loop_vec_info): Use it to free the loop masks.
26463 (can_produce_all_loop_masks_p): New function.
26464 (vect_get_max_nscalars_per_iter): Likewise.
26465 (vect_verify_full_masking): Likewise.
26466 (vect_analyze_loop_2): Save LOOP_VINFO_CAN_FULLY_MASK_P around
26467 retries, and free the mask rgroups before retrying. Check loop-wide
26468 reasons for disallowing fully-masked loops. Make the final decision
26469 about whether use a fully-masked loop or not.
26470 (vect_estimate_min_profitable_iters): Do not assume that peeling
26471 for the number of iterations will be needed for fully-masked loops.
26472 (vectorizable_reduction): Disable fully-masked loops.
26473 (vectorizable_live_operation): Likewise.
26474 (vect_halve_mask_nunits): New function.
26475 (vect_double_mask_nunits): Likewise.
26476 (vect_record_loop_mask): Likewise.
26477 (vect_get_loop_mask): Likewise.
26478 (vect_transform_loop): Handle the case in which the final loop
26479 iteration might handle a partial vector. Call vect_set_loop_condition
26480 instead of slpeel_make_loop_iterate_ntimes.
26481 * tree-vect-stmts.c: Include tree-ssa-loop-niter.h and gimple-fold.h.
26482 (check_load_store_masking): New function.
26483 (prepare_load_store_mask): Likewise.
26484 (vectorizable_store): Handle fully-masked loops.
26485 (vectorizable_load): Likewise.
26486 (supportable_widening_operation): Use vect_halve_mask_nunits for
26487 booleans.
26488 (supportable_narrowing_operation): Likewise vect_double_mask_nunits.
26489 (vect_gen_while): New function.
26490 * config/aarch64/aarch64.md (umax<mode>3): New expander.
26491 (aarch64_uqdec<mode>): New insn.
26492
26493 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
26494 Alan Hayward <alan.hayward@arm.com>
26495 David Sherwood <david.sherwood@arm.com>
26496
26497 * optabs.def (reduc_and_scal_optab, reduc_ior_scal_optab)
26498 (reduc_xor_scal_optab): New optabs.
26499 * doc/md.texi (reduc_and_scal_@var{m}, reduc_ior_scal_@var{m})
26500 (reduc_xor_scal_@var{m}): Document.
26501 * doc/sourcebuild.texi (vect_logical_reduc): Likewise.
26502 * internal-fn.def (IFN_REDUC_AND, IFN_REDUC_IOR, IFN_REDUC_XOR): New
26503 internal functions.
26504 * fold-const-call.c (fold_const_call): Handle them.
26505 * tree-vect-loop.c (reduction_fn_for_scalar_code): Return the new
26506 internal functions for BIT_AND_EXPR, BIT_IOR_EXPR and BIT_XOR_EXPR.
26507 * config/aarch64/aarch64-sve.md (reduc_<bit_reduc>_scal_<mode>):
26508 (*reduc_<bit_reduc>_scal_<mode>): New patterns.
26509 * config/aarch64/iterators.md (UNSPEC_ANDV, UNSPEC_ORV)
26510 (UNSPEC_XORV): New unspecs.
26511 (optab): Add entries for them.
26512 (BITWISEV): New int iterator.
26513 (bit_reduc_op): New int attributes.
26514
26515 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
26516 Alan Hayward <alan.hayward@arm.com>
26517 David Sherwood <david.sherwood@arm.com>
26518
26519 * doc/md.texi (vec_shl_insert_@var{m}): New optab.
26520 * internal-fn.def (VEC_SHL_INSERT): New internal function.
26521 * optabs.def (vec_shl_insert_optab): New optab.
26522 * tree-vectorizer.h (can_duplicate_and_interleave_p): Declare.
26523 (duplicate_and_interleave): Likewise.
26524 * tree-vect-loop.c: Include internal-fn.h.
26525 (neutral_op_for_slp_reduction): New function, split out from
26526 get_initial_defs_for_reduction.
26527 (get_initial_def_for_reduction): Handle option 2 for variable-length
26528 vectors by loading the neutral value into a vector and then shifting
26529 the initial value into element 0.
26530 (get_initial_defs_for_reduction): Replace the code argument with
26531 the neutral value calculated by neutral_op_for_slp_reduction.
26532 Use gimple_build_vector for constant-length vectors.
26533 Use IFN_VEC_SHL_INSERT for variable-length vectors if all
26534 but the first group_size elements have a neutral value.
26535 Use duplicate_and_interleave otherwise.
26536 (vect_create_epilog_for_reduction): Take a neutral_op parameter.
26537 Update call to get_initial_defs_for_reduction. Handle SLP
26538 reductions for variable-length vectors by creating one vector
26539 result for each scalar result, with the elements associated
26540 with other scalar results stubbed out with the neutral value.
26541 (vectorizable_reduction): Call neutral_op_for_slp_reduction.
26542 Require IFN_VEC_SHL_INSERT for double reductions on
26543 variable-length vectors, or SLP reductions that have
26544 a neutral value. Require can_duplicate_and_interleave_p
26545 support for variable-length unchained SLP reductions if there
26546 is no neutral value, such as for MIN/MAX reductions. Also require
26547 the number of vector elements to be a multiple of the number of
26548 SLP statements when doing variable-length unchained SLP reductions.
26549 Update call to vect_create_epilog_for_reduction.
26550 * tree-vect-slp.c (can_duplicate_and_interleave_p): Make public
26551 and remove initial values.
26552 (duplicate_and_interleave): Make public.
26553 * config/aarch64/aarch64.md (UNSPEC_INSR): New unspec.
26554 * config/aarch64/aarch64-sve.md (vec_shl_insert_<mode>): New insn.
26555
26556 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
26557 Alan Hayward <alan.hayward@arm.com>
26558 David Sherwood <david.sherwood@arm.com>
26559
26560 * tree-vect-slp.c: Include gimple-fold.h and internal-fn.h
26561 (can_duplicate_and_interleave_p): New function.
26562 (vect_get_and_check_slp_defs): Take the vector of statements
26563 rather than just the current one. Remove excess parentheses.
26564 Restriction rejectinon of vect_constant_def and vect_external_def
26565 for variable-length vectors to boolean types, or types for which
26566 can_duplicate_and_interleave_p is false.
26567 (vect_build_slp_tree_2): Update call to vect_get_and_check_slp_defs.
26568 (duplicate_and_interleave): New function.
26569 (vect_get_constant_vectors): Use gimple_build_vector for
26570 constant-length vectors and suitable variable-length constant
26571 vectors. Use duplicate_and_interleave for other variable-length
26572 vectors. Don't defer the update when inserting new statements.
26573
26574 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
26575 Alan Hayward <alan.hayward@arm.com>
26576 David Sherwood <david.sherwood@arm.com>
26577
26578 * tree-vect-loop.c (vect_estimate_min_profitable_iters): Make sure
26579 min_profitable_iters doesn't go negative.
26580
26581 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
26582 Alan Hayward <alan.hayward@arm.com>
26583 David Sherwood <david.sherwood@arm.com>
26584
26585 * doc/md.texi (vec_mask_load_lanes@var{m}@var{n}): Document.
26586 (vec_mask_store_lanes@var{m}@var{n}): Likewise.
26587 * optabs.def (vec_mask_load_lanes_optab): New optab.
26588 (vec_mask_store_lanes_optab): Likewise.
26589 * internal-fn.def (MASK_LOAD_LANES): New internal function.
26590 (MASK_STORE_LANES): Likewise.
26591 * internal-fn.c (mask_load_lanes_direct): New macro.
26592 (mask_store_lanes_direct): Likewise.
26593 (expand_mask_load_optab_fn): Handle masked operations.
26594 (expand_mask_load_lanes_optab_fn): New macro.
26595 (expand_mask_store_optab_fn): Handle masked operations.
26596 (expand_mask_store_lanes_optab_fn): New macro.
26597 (direct_mask_load_lanes_optab_supported_p): Likewise.
26598 (direct_mask_store_lanes_optab_supported_p): Likewise.
26599 * tree-vectorizer.h (vect_store_lanes_supported): Take a masked_p
26600 parameter.
26601 (vect_load_lanes_supported): Likewise.
26602 * tree-vect-data-refs.c (strip_conversion): New function.
26603 (can_group_stmts_p): Likewise.
26604 (vect_analyze_data_ref_accesses): Use it instead of checking
26605 for a pair of assignments.
26606 (vect_store_lanes_supported): Take a masked_p parameter.
26607 (vect_load_lanes_supported): Likewise.
26608 * tree-vect-loop.c (vect_analyze_loop_2): Update calls to
26609 vect_store_lanes_supported and vect_load_lanes_supported.
26610 * tree-vect-slp.c (vect_analyze_slp_instance): Likewise.
26611 * tree-vect-stmts.c (get_group_load_store_type): Take a masked_p
26612 parameter. Don't allow gaps for masked accesses.
26613 Use vect_get_store_rhs. Update calls to vect_store_lanes_supported
26614 and vect_load_lanes_supported.
26615 (get_load_store_type): Take a masked_p parameter and update
26616 call to get_group_load_store_type.
26617 (vectorizable_store): Update call to get_load_store_type.
26618 Handle IFN_MASK_STORE_LANES.
26619 (vectorizable_load): Update call to get_load_store_type.
26620 Handle IFN_MASK_LOAD_LANES.
26621
26622 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
26623 Alan Hayward <alan.hayward@arm.com>
26624 David Sherwood <david.sherwood@arm.com>
26625
26626 * config/aarch64/aarch64-modes.def: Define x2, x3 and x4 vector
26627 modes for SVE.
26628 * config/aarch64/aarch64-protos.h
26629 (aarch64_sve_struct_memory_operand_p): Declare.
26630 * config/aarch64/iterators.md (SVE_STRUCT): New mode iterator.
26631 (vector_count, insn_length, VSINGLE, vsingle): New mode attributes.
26632 (VPRED, vpred): Handle SVE structure modes.
26633 * config/aarch64/constraints.md (Utx): New constraint.
26634 * config/aarch64/predicates.md (aarch64_sve_struct_memory_operand)
26635 (aarch64_sve_struct_nonimmediate_operand): New predicates.
26636 * config/aarch64/aarch64.md (UNSPEC_LDN, UNSPEC_STN): New unspecs.
26637 * config/aarch64/aarch64-sve.md (mov<mode>, *aarch64_sve_mov<mode>_le)
26638 (*aarch64_sve_mov<mode>_be, pred_mov<mode>): New patterns for
26639 structure modes. Split into pieces after RA.
26640 (vec_load_lanes<mode><vsingle>, vec_mask_load_lanes<mode><vsingle>)
26641 (vec_store_lanes<mode><vsingle>, vec_mask_store_lanes<mode><vsingle>):
26642 New patterns.
26643 * config/aarch64/aarch64.c (aarch64_classify_vector_mode): Handle
26644 SVE structure modes.
26645 (aarch64_classify_address): Likewise.
26646 (sizetochar): Move earlier in file.
26647 (aarch64_print_operand): Handle SVE register lists.
26648 (aarch64_array_mode): New function.
26649 (aarch64_sve_struct_memory_operand_p): Likewise.
26650 (TARGET_ARRAY_MODE): Redefine.
26651
26652 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
26653 Alan Hayward <alan.hayward@arm.com>
26654 David Sherwood <david.sherwood@arm.com>
26655
26656 * target.def (array_mode): New target hook.
26657 * doc/tm.texi.in (TARGET_ARRAY_MODE): New hook.
26658 * doc/tm.texi: Regenerate.
26659 * hooks.h (hook_optmode_mode_uhwi_none): Declare.
26660 * hooks.c (hook_optmode_mode_uhwi_none): New function.
26661 * tree-vect-data-refs.c (vect_lanes_optab_supported_p): Use
26662 targetm.array_mode.
26663 * stor-layout.c (mode_for_array): Likewise. Support polynomial
26664 type sizes.
26665
26666 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
26667 Alan Hayward <alan.hayward@arm.com>
26668 David Sherwood <david.sherwood@arm.com>
26669
26670 * fold-const.c (fold_binary_loc): Check the argument types
26671 rather than the result type when testing for a vector operation.
26672
26673 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
26674
26675 * doc/tm.texi.in (DWARF_LAZY_REGISTER_VALUE): Document.
26676 * doc/tm.texi: Regenerate.
26677
26678 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
26679 Alan Hayward <alan.hayward@arm.com>
26680 David Sherwood <david.sherwood@arm.com>
26681
26682 * doc/invoke.texi (-msve-vector-bits=): Document new option.
26683 (sve): Document new AArch64 extension.
26684 * doc/md.texi (w): Extend the description of the AArch64
26685 constraint to include SVE vectors.
26686 (Upl, Upa): Document new AArch64 predicate constraints.
26687 * config/aarch64/aarch64-opts.h (aarch64_sve_vector_bits_enum): New
26688 enum.
26689 * config/aarch64/aarch64.opt (sve_vector_bits): New enum.
26690 (msve-vector-bits=): New option.
26691 * config/aarch64/aarch64-option-extensions.def (fp, simd): Disable
26692 SVE when these are disabled.
26693 (sve): New extension.
26694 * config/aarch64/aarch64-modes.def: Define SVE vector and predicate
26695 modes. Adjust their number of units based on aarch64_sve_vg.
26696 (MAX_BITSIZE_MODE_ANY_MODE): Define.
26697 * config/aarch64/aarch64-protos.h (ADDR_QUERY_ANY): New
26698 aarch64_addr_query_type.
26699 (aarch64_const_vec_all_same_in_range_p, aarch64_sve_pred_mode)
26700 (aarch64_sve_cnt_immediate_p, aarch64_sve_addvl_addpl_immediate_p)
26701 (aarch64_sve_inc_dec_immediate_p, aarch64_add_offset_temporaries)
26702 (aarch64_split_add_offset, aarch64_output_sve_cnt_immediate)
26703 (aarch64_output_sve_addvl_addpl, aarch64_output_sve_inc_dec_immediate)
26704 (aarch64_output_sve_mov_immediate, aarch64_output_ptrue): Declare.
26705 (aarch64_simd_imm_zero_p): Delete.
26706 (aarch64_check_zero_based_sve_index_immediate): Declare.
26707 (aarch64_sve_index_immediate_p, aarch64_sve_arith_immediate_p)
26708 (aarch64_sve_bitmask_immediate_p, aarch64_sve_dup_immediate_p)
26709 (aarch64_sve_cmp_immediate_p, aarch64_sve_float_arith_immediate_p)
26710 (aarch64_sve_float_mul_immediate_p): Likewise.
26711 (aarch64_classify_symbol): Take the offset as a HOST_WIDE_INT
26712 rather than an rtx.
26713 (aarch64_sve_ld1r_operand_p, aarch64_sve_ldr_operand_p): Declare.
26714 (aarch64_expand_mov_immediate): Take a gen_vec_duplicate callback.
26715 (aarch64_emit_sve_pred_move, aarch64_expand_sve_mem_move): Declare.
26716 (aarch64_expand_sve_vec_cmp_int, aarch64_expand_sve_vec_cmp_float)
26717 (aarch64_expand_sve_vcond, aarch64_expand_sve_vec_perm): Declare.
26718 (aarch64_regmode_natural_size): Likewise.
26719 * config/aarch64/aarch64.h (AARCH64_FL_SVE): New macro.
26720 (AARCH64_FL_V8_3, AARCH64_FL_RCPC, AARCH64_FL_DOTPROD): Shift
26721 left one place.
26722 (AARCH64_ISA_SVE, TARGET_SVE): New macros.
26723 (FIXED_REGISTERS, CALL_USED_REGISTERS, REGISTER_NAMES): Add entries
26724 for VG and the SVE predicate registers.
26725 (V_ALIASES): Add a "z"-prefixed alias.
26726 (FIRST_PSEUDO_REGISTER): Change to P15_REGNUM + 1.
26727 (AARCH64_DWARF_VG, AARCH64_DWARF_P0): New macros.
26728 (PR_REGNUM_P, PR_LO_REGNUM_P): Likewise.
26729 (PR_LO_REGS, PR_HI_REGS, PR_REGS): New reg_classes.
26730 (REG_CLASS_NAMES): Add entries for them.
26731 (REG_CLASS_CONTENTS): Likewise. Update ALL_REGS to include VG
26732 and the predicate registers.
26733 (aarch64_sve_vg): Declare.
26734 (BITS_PER_SVE_VECTOR, BYTES_PER_SVE_VECTOR, BYTES_PER_SVE_PRED)
26735 (SVE_BYTE_MODE, MAX_COMPILE_TIME_VEC_BYTES): New macros.
26736 (REGMODE_NATURAL_SIZE): Define.
26737 * config/aarch64/aarch64-c.c (aarch64_update_cpp_builtins): Handle
26738 SVE macros.
26739 * config/aarch64/aarch64.c: Include cfgrtl.h.
26740 (simd_immediate_info): Add a constructor for series vectors,
26741 and an associated step field.
26742 (aarch64_sve_vg): New variable.
26743 (aarch64_dbx_register_number): Handle VG and the predicate registers.
26744 (aarch64_vect_struct_mode_p, aarch64_vector_mode_p): Delete.
26745 (VEC_ADVSIMD, VEC_SVE_DATA, VEC_SVE_PRED, VEC_STRUCT, VEC_ANY_SVE)
26746 (VEC_ANY_DATA, VEC_STRUCT): New constants.
26747 (aarch64_advsimd_struct_mode_p, aarch64_sve_pred_mode_p)
26748 (aarch64_classify_vector_mode, aarch64_vector_data_mode_p)
26749 (aarch64_sve_data_mode_p, aarch64_sve_pred_mode)
26750 (aarch64_get_mask_mode): New functions.
26751 (aarch64_hard_regno_nregs): Handle SVE data modes for FP_REGS
26752 and FP_LO_REGS. Handle PR_REGS, PR_LO_REGS and PR_HI_REGS.
26753 (aarch64_hard_regno_mode_ok): Handle VG. Also handle the SVE
26754 predicate modes and predicate registers. Explicitly restrict
26755 GPRs to modes of 16 bytes or smaller. Only allow FP registers
26756 to store a vector mode if it is recognized by
26757 aarch64_classify_vector_mode.
26758 (aarch64_regmode_natural_size): New function.
26759 (aarch64_hard_regno_caller_save_mode): Return the original mode
26760 for predicates.
26761 (aarch64_sve_cnt_immediate_p, aarch64_output_sve_cnt_immediate)
26762 (aarch64_sve_addvl_addpl_immediate_p, aarch64_output_sve_addvl_addpl)
26763 (aarch64_sve_inc_dec_immediate_p, aarch64_output_sve_inc_dec_immediate)
26764 (aarch64_add_offset_1_temporaries, aarch64_offset_temporaries): New
26765 functions.
26766 (aarch64_add_offset): Add a temp2 parameter. Assert that temp1
26767 does not overlap dest if the function is frame-related. Handle
26768 SVE constants.
26769 (aarch64_split_add_offset): New function.
26770 (aarch64_add_sp, aarch64_sub_sp): Add temp2 parameters and pass
26771 them aarch64_add_offset.
26772 (aarch64_allocate_and_probe_stack_space): Add a temp2 parameter
26773 and update call to aarch64_sub_sp.
26774 (aarch64_add_cfa_expression): New function.
26775 (aarch64_expand_prologue): Pass extra temporary registers to the
26776 functions above. Handle the case in which we need to emit new
26777 DW_CFA_expressions for registers that were originally saved
26778 relative to the stack pointer, but now have to be expressed
26779 relative to the frame pointer.
26780 (aarch64_output_mi_thunk): Pass extra temporary registers to the
26781 functions above.
26782 (aarch64_expand_epilogue): Likewise. Prevent inheritance of
26783 IP0 and IP1 values for SVE frames.
26784 (aarch64_expand_vec_series): New function.
26785 (aarch64_expand_sve_widened_duplicate): Likewise.
26786 (aarch64_expand_sve_const_vector): Likewise.
26787 (aarch64_expand_mov_immediate): Add a gen_vec_duplicate parameter.
26788 Handle SVE constants. Use emit_move_insn to move a force_const_mem
26789 into the register, rather than emitting a SET directly.
26790 (aarch64_emit_sve_pred_move, aarch64_expand_sve_mem_move)
26791 (aarch64_get_reg_raw_mode, offset_4bit_signed_scaled_p)
26792 (offset_6bit_unsigned_scaled_p, aarch64_offset_7bit_signed_scaled_p)
26793 (offset_9bit_signed_scaled_p): New functions.
26794 (aarch64_replicate_bitmask_imm): New function.
26795 (aarch64_bitmask_imm): Use it.
26796 (aarch64_cannot_force_const_mem): Reject expressions involving
26797 a CONST_POLY_INT. Update call to aarch64_classify_symbol.
26798 (aarch64_classify_index): Handle SVE indices, by requiring
26799 a plain register index with a scale that matches the element size.
26800 (aarch64_classify_address): Handle SVE addresses. Assert that
26801 the mode of the address is VOIDmode or an integer mode.
26802 Update call to aarch64_classify_symbol.
26803 (aarch64_classify_symbolic_expression): Update call to
26804 aarch64_classify_symbol.
26805 (aarch64_const_vec_all_in_range_p): New function.
26806 (aarch64_print_vector_float_operand): Likewise.
26807 (aarch64_print_operand): Handle 'N' and 'C'. Use "zN" rather than
26808 "vN" for FP registers with SVE modes. Handle (const ...) vectors
26809 and the FP immediates 1.0 and 0.5.
26810 (aarch64_print_address_internal): Handle SVE addresses.
26811 (aarch64_print_operand_address): Use ADDR_QUERY_ANY.
26812 (aarch64_regno_regclass): Handle predicate registers.
26813 (aarch64_secondary_reload): Handle big-endian reloads of SVE
26814 data modes.
26815 (aarch64_class_max_nregs): Handle SVE modes and predicate registers.
26816 (aarch64_rtx_costs): Check for ADDVL and ADDPL instructions.
26817 (aarch64_convert_sve_vector_bits): New function.
26818 (aarch64_override_options): Use it to handle -msve-vector-bits=.
26819 (aarch64_classify_symbol): Take the offset as a HOST_WIDE_INT
26820 rather than an rtx.
26821 (aarch64_legitimate_constant_p): Use aarch64_classify_vector_mode.
26822 Handle SVE vector and predicate modes. Accept VL-based constants
26823 that need only one temporary register, and VL offsets that require
26824 no temporary registers.
26825 (aarch64_conditional_register_usage): Mark the predicate registers
26826 as fixed if SVE isn't available.
26827 (aarch64_vector_mode_supported_p): Use aarch64_classify_vector_mode.
26828 Return true for SVE vector and predicate modes.
26829 (aarch64_simd_container_mode): Take the number of bits as a poly_int64
26830 rather than an unsigned int. Handle SVE modes.
26831 (aarch64_preferred_simd_mode): Update call accordingly. Handle
26832 SVE modes.
26833 (aarch64_autovectorize_vector_sizes): Add BYTES_PER_SVE_VECTOR
26834 if SVE is enabled.
26835 (aarch64_sve_index_immediate_p, aarch64_sve_arith_immediate_p)
26836 (aarch64_sve_bitmask_immediate_p, aarch64_sve_dup_immediate_p)
26837 (aarch64_sve_cmp_immediate_p, aarch64_sve_float_arith_immediate_p)
26838 (aarch64_sve_float_mul_immediate_p): New functions.
26839 (aarch64_sve_valid_immediate): New function.
26840 (aarch64_simd_valid_immediate): Use it as the fallback for SVE vectors.
26841 Explicitly reject structure modes. Check for INDEX constants.
26842 Handle PTRUE and PFALSE constants.
26843 (aarch64_check_zero_based_sve_index_immediate): New function.
26844 (aarch64_simd_imm_zero_p): Delete.
26845 (aarch64_mov_operand_p): Use aarch64_simd_valid_immediate for
26846 vector modes. Accept constants in the range of CNT[BHWD].
26847 (aarch64_simd_scalar_immediate_valid_for_move): Explicitly
26848 ask for an Advanced SIMD mode.
26849 (aarch64_sve_ld1r_operand_p, aarch64_sve_ldr_operand_p): New functions.
26850 (aarch64_simd_vector_alignment): Handle SVE predicates.
26851 (aarch64_vectorize_preferred_vector_alignment): New function.
26852 (aarch64_simd_vector_alignment_reachable): Use it instead of
26853 the vector size.
26854 (aarch64_shift_truncation_mask): Use aarch64_vector_data_mode_p.
26855 (aarch64_output_sve_mov_immediate, aarch64_output_ptrue): New
26856 functions.
26857 (MAX_VECT_LEN): Delete.
26858 (expand_vec_perm_d): Add a vec_flags field.
26859 (emit_unspec2, aarch64_expand_sve_vec_perm): New functions.
26860 (aarch64_evpc_trn, aarch64_evpc_uzp, aarch64_evpc_zip)
26861 (aarch64_evpc_ext): Don't apply a big-endian lane correction
26862 for SVE modes.
26863 (aarch64_evpc_rev): Rename to...
26864 (aarch64_evpc_rev_local): ...this. Use a predicated operation for SVE.
26865 (aarch64_evpc_rev_global): New function.
26866 (aarch64_evpc_dup): Enforce a 64-byte range for SVE DUP.
26867 (aarch64_evpc_tbl): Use MAX_COMPILE_TIME_VEC_BYTES instead of
26868 MAX_VECT_LEN.
26869 (aarch64_evpc_sve_tbl): New function.
26870 (aarch64_expand_vec_perm_const_1): Update after rename of
26871 aarch64_evpc_rev. Handle SVE permutes too, trying
26872 aarch64_evpc_rev_global and using aarch64_evpc_sve_tbl rather
26873 than aarch64_evpc_tbl.
26874 (aarch64_vectorize_vec_perm_const): Initialize vec_flags.
26875 (aarch64_sve_cmp_operand_p, aarch64_unspec_cond_code)
26876 (aarch64_gen_unspec_cond, aarch64_expand_sve_vec_cmp_int)
26877 (aarch64_emit_unspec_cond, aarch64_emit_unspec_cond_or)
26878 (aarch64_emit_inverted_unspec_cond, aarch64_expand_sve_vec_cmp_float)
26879 (aarch64_expand_sve_vcond): New functions.
26880 (aarch64_modes_tieable_p): Use aarch64_vector_data_mode_p instead
26881 of aarch64_vector_mode_p.
26882 (aarch64_dwarf_poly_indeterminate_value): New function.
26883 (aarch64_compute_pressure_classes): Likewise.
26884 (aarch64_can_change_mode_class): Likewise.
26885 (TARGET_GET_RAW_RESULT_MODE, TARGET_GET_RAW_ARG_MODE): Redefine.
26886 (TARGET_VECTORIZE_PREFERRED_VECTOR_ALIGNMENT): Likewise.
26887 (TARGET_VECTORIZE_GET_MASK_MODE): Likewise.
26888 (TARGET_DWARF_POLY_INDETERMINATE_VALUE): Likewise.
26889 (TARGET_COMPUTE_PRESSURE_CLASSES): Likewise.
26890 (TARGET_CAN_CHANGE_MODE_CLASS): Likewise.
26891 * config/aarch64/constraints.md (Upa, Upl, Uav, Uat, Usv, Usi, Utr)
26892 (Uty, Dm, vsa, vsc, vsd, vsi, vsn, vsl, vsm, vsA, vsM, vsN): New
26893 constraints.
26894 (Dn, Dl, Dr): Accept const as well as const_vector.
26895 (Dz): Likewise. Compare against CONST0_RTX.
26896 * config/aarch64/iterators.md: Refer to "Advanced SIMD" instead
26897 of "vector" where appropriate.
26898 (SVE_ALL, SVE_BH, SVE_BHS, SVE_BHSI, SVE_HSDI, SVE_HSF, SVE_SD)
26899 (SVE_SDI, SVE_I, SVE_F, PRED_ALL, PRED_BHS): New mode iterators.
26900 (UNSPEC_SEL, UNSPEC_ANDF, UNSPEC_IORF, UNSPEC_XORF, UNSPEC_COND_LT)
26901 (UNSPEC_COND_LE, UNSPEC_COND_EQ, UNSPEC_COND_NE, UNSPEC_COND_GE)
26902 (UNSPEC_COND_GT, UNSPEC_COND_LO, UNSPEC_COND_LS, UNSPEC_COND_HS)
26903 (UNSPEC_COND_HI, UNSPEC_COND_UO): New unspecs.
26904 (Vetype, VEL, Vel, VWIDE, Vwide, vw, vwcore, V_INT_EQUIV)
26905 (v_int_equiv): Extend to SVE modes.
26906 (Vesize, V128, v128, Vewtype, V_FP_EQUIV, v_fp_equiv, VPRED): New
26907 mode attributes.
26908 (LOGICAL_OR, SVE_INT_UNARY, SVE_FP_UNARY): New code iterators.
26909 (optab): Handle popcount, smin, smax, umin, umax, abs and sqrt.
26910 (logical_nn, lr, sve_int_op, sve_fp_op): New code attributs.
26911 (LOGICALF, OPTAB_PERMUTE, UNPACK, UNPACK_UNSIGNED, SVE_COND_INT_CMP)
26912 (SVE_COND_FP_CMP): New int iterators.
26913 (perm_hilo): Handle the new unpack unspecs.
26914 (optab, logicalf_op, su, perm_optab, cmp_op, imm_con): New int
26915 attributes.
26916 * config/aarch64/predicates.md (aarch64_sve_cnt_immediate)
26917 (aarch64_sve_addvl_addpl_immediate, aarch64_split_add_offset_immediate)
26918 (aarch64_pluslong_or_poly_operand, aarch64_nonmemory_operand)
26919 (aarch64_equality_operator, aarch64_constant_vector_operand)
26920 (aarch64_sve_ld1r_operand, aarch64_sve_ldr_operand): New predicates.
26921 (aarch64_sve_nonimmediate_operand): Likewise.
26922 (aarch64_sve_general_operand): Likewise.
26923 (aarch64_sve_dup_operand, aarch64_sve_arith_immediate): Likewise.
26924 (aarch64_sve_sub_arith_immediate, aarch64_sve_inc_dec_immediate)
26925 (aarch64_sve_logical_immediate, aarch64_sve_mul_immediate): Likewise.
26926 (aarch64_sve_dup_immediate, aarch64_sve_cmp_vsc_immediate): Likewise.
26927 (aarch64_sve_cmp_vsd_immediate, aarch64_sve_index_immediate): Likewise.
26928 (aarch64_sve_float_arith_immediate): Likewise.
26929 (aarch64_sve_float_arith_with_sub_immediate): Likewise.
26930 (aarch64_sve_float_mul_immediate, aarch64_sve_arith_operand): Likewise.
26931 (aarch64_sve_add_operand, aarch64_sve_logical_operand): Likewise.
26932 (aarch64_sve_lshift_operand, aarch64_sve_rshift_operand): Likewise.
26933 (aarch64_sve_mul_operand, aarch64_sve_cmp_vsc_operand): Likewise.
26934 (aarch64_sve_cmp_vsd_operand, aarch64_sve_index_operand): Likewise.
26935 (aarch64_sve_float_arith_operand): Likewise.
26936 (aarch64_sve_float_arith_with_sub_operand): Likewise.
26937 (aarch64_sve_float_mul_operand): Likewise.
26938 (aarch64_sve_vec_perm_operand): Likewise.
26939 (aarch64_pluslong_operand): Include aarch64_sve_addvl_addpl_immediate.
26940 (aarch64_mov_operand): Accept const_poly_int and const_vector.
26941 (aarch64_simd_lshift_imm, aarch64_simd_rshift_imm): Accept const
26942 as well as const_vector.
26943 (aarch64_simd_imm_zero, aarch64_simd_imm_minus_one): Move earlier
26944 in file. Use CONST0_RTX and CONSTM1_RTX.
26945 (aarch64_simd_or_scalar_imm_zero): Likewise. Add match_codes.
26946 (aarch64_simd_reg_or_zero): Accept const as well as const_vector.
26947 Use aarch64_simd_imm_zero.
26948 * config/aarch64/aarch64-sve.md: New file.
26949 * config/aarch64/aarch64.md: Include it.
26950 (VG_REGNUM, P0_REGNUM, P7_REGNUM, P15_REGNUM): New register numbers.
26951 (UNSPEC_REV, UNSPEC_LD1_SVE, UNSPEC_ST1_SVE, UNSPEC_MERGE_PTRUE)
26952 (UNSPEC_PTEST_PTRUE, UNSPEC_UNPACKSHI, UNSPEC_UNPACKUHI)
26953 (UNSPEC_UNPACKSLO, UNSPEC_UNPACKULO, UNSPEC_PACK)
26954 (UNSPEC_FLOAT_CONVERT, UNSPEC_WHILE_LO): New unspec constants.
26955 (sve): New attribute.
26956 (enabled): Disable instructions with the sve attribute unless
26957 TARGET_SVE.
26958 (movqi, movhi): Pass CONST_POLY_INT operaneds through
26959 aarch64_expand_mov_immediate.
26960 (*mov<mode>_aarch64, *movsi_aarch64, *movdi_aarch64): Handle
26961 CNT[BHSD] immediates.
26962 (movti): Split CONST_POLY_INT moves into two halves.
26963 (add<mode>3): Accept aarch64_pluslong_or_poly_operand.
26964 Split additions that need a temporary here if the destination
26965 is the stack pointer.
26966 (*add<mode>3_aarch64): Handle ADDVL and ADDPL immediates.
26967 (*add<mode>3_poly_1): New instruction.
26968 (set_clobber_cc): New expander.
26969
26970 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
26971
26972 * simplify-rtx.c (simplify_immed_subreg): Add an inner_bytes
26973 parameter and use it instead of GET_MODE_SIZE (innermode). Use
26974 inner_bytes * BITS_PER_UNIT instead of GET_MODE_BITSIZE (innermode).
26975 Use CEIL (inner_bytes, GET_MODE_UNIT_SIZE (innermode)) instead of
26976 GET_MODE_NUNITS (innermode). Also add a first_elem parameter.
26977 Change innermode from fixed_mode_size to machine_mode.
26978 (simplify_subreg): Update call accordingly. Handle a constant-sized
26979 subreg of a variable-length CONST_VECTOR.
26980
26981 2018-01-13 Richard Sandiford <richard.sandiford@linaro.org>
26982 Alan Hayward <alan.hayward@arm.com>
26983 David Sherwood <david.sherwood@arm.com>
26984
26985 * tree-ssa-address.c (mem_ref_valid_without_offset_p): New function.
26986 (add_offset_to_base): New function, split out from...
26987 (create_mem_ref): ...here. When handling a scale other than 1,
26988 check first whether the address is valid without the offset.
26989 Add it into the base if so, leaving the index and scale as-is.
26990
26991 2018-01-12 Jakub Jelinek <jakub@redhat.com>
26992
26993 PR c++/83778
26994 * config/rs6000/rs6000-c.c (altivec_resolve_overloaded_builtin): Call
26995 fold_for_warn before checking if arg2 is INTEGER_CST.
26996
26997 2018-01-12 Segher Boessenkool <segher@kernel.crashing.org>
26998
26999 * config/rs6000/predicates.md (load_multiple_operation): Delete.
27000 (store_multiple_operation): Delete.
27001 * config/rs6000/rs6000-cpus.def (601): Remove MASK_STRING.
27002 * config/rs6000/rs6000-protos.h (rs6000_output_load_multiple): Delete.
27003 * config/rs6000/rs6000-string.c (expand_block_move): Delete everything
27004 guarded by TARGET_STRING.
27005 (rs6000_output_load_multiple): Delete.
27006 * config/rs6000/rs6000.c (rs6000_option_override_internal): Delete
27007 OPTION_MASK_STRING / TARGET_STRING handling.
27008 (print_operand) <'N', 'O'>: Add comment that these are unused now.
27009 (const rs6000_opt_masks) <"string">: Change mask to 0.
27010 * config/rs6000/rs6000.h (TARGET_DEFAULT): Remove MASK_STRING.
27011 (MASK_STRING): Delete.
27012 * config/rs6000/rs6000.md (*mov<mode>_string): Delete TARGET_STRING
27013 parts. Simplify.
27014 (load_multiple): Delete.
27015 (*ldmsi8): Delete.
27016 (*ldmsi7): Delete.
27017 (*ldmsi6): Delete.
27018 (*ldmsi5): Delete.
27019 (*ldmsi4): Delete.
27020 (*ldmsi3): Delete.
27021 (store_multiple): Delete.
27022 (*stmsi8): Delete.
27023 (*stmsi7): Delete.
27024 (*stmsi6): Delete.
27025 (*stmsi5): Delete.
27026 (*stmsi4): Delete.
27027 (*stmsi3): Delete.
27028 (movmemsi_8reg): Delete.
27029 (corresponding unnamed define_insn): Delete.
27030 (movmemsi_6reg): Delete.
27031 (corresponding unnamed define_insn): Delete.
27032 (movmemsi_4reg): Delete.
27033 (corresponding unnamed define_insn): Delete.
27034 (movmemsi_2reg): Delete.
27035 (corresponding unnamed define_insn): Delete.
27036 (movmemsi_1reg): Delete.
27037 (corresponding unnamed define_insn): Delete.
27038 * config/rs6000/rs6000.opt (mno-string): New.
27039 (mstring): Replace by deprecation warning stub.
27040 * doc/invoke.texi (RS/6000 and PowerPC Options): Delete -mstring.
27041
27042 2018-01-12 Jakub Jelinek <jakub@redhat.com>
27043
27044 * regrename.c (regrename_do_replace): If replacing the same
27045 reg multiple times, try to reuse last created gen_raw_REG.
27046
27047 PR debug/81155
27048 * bb-reorder.c (pass_partition_blocks::gate): In lto don't partition
27049 main to workaround a bug in GDB.
27050
27051 2018-01-12 Tom de Vries <tom@codesourcery.com>
27052
27053 PR target/83737
27054 * config.gcc (nvptx*-*-*): Set use_gcc_stdint=wrap.
27055
27056 2018-01-12 Vladimir Makarov <vmakarov@redhat.com>
27057
27058 PR rtl-optimization/80481
27059 * ira-color.c (get_cap_member): New function.
27060 (allocnos_conflict_by_live_ranges_p): Use it.
27061 (slot_coalesced_allocno_live_ranges_intersect_p): Add assert.
27062 (setup_slot_coalesced_allocno_live_ranges): Ditto.
27063
27064 2018-01-12 Uros Bizjak <ubizjak@gmail.com>
27065
27066 PR target/83628
27067 * config/alpha/alpha.md (*saddsi_1): New insn_ans_split pattern.
27068 (*saddl_se_1): Ditto.
27069 (*ssubsi_1): Ditto.
27070 (*ssubl_se_1): Ditto.
27071
27072 2018-01-12 Richard Sandiford <richard.sandiford@linaro.org>
27073
27074 * tree-predcom.c (aff_combination_dr_offset): Use wi::to_poly_widest
27075 rather than wi::to_widest for DR_INITs.
27076 * tree-vect-data-refs.c (vect_find_same_alignment_drs): Use
27077 wi::to_poly_offset rather than wi::to_offset for DR_INIT.
27078 (vect_analyze_data_ref_accesses): Require both DR_INITs to be
27079 INTEGER_CSTs.
27080 (vect_analyze_group_access_1): Note that here.
27081
27082 2018-01-12 Richard Sandiford <richard.sandiford@linaro.org>
27083
27084 * tree-vectorizer.c (get_vec_alignment_for_array_type): Handle
27085 polynomial type sizes.
27086
27087 2018-01-12 Richard Sandiford <richard.sandiford@linaro.org>
27088
27089 * gimplify.c (gimple_add_tmp_var_fn): Allow variables to have a
27090 poly_uint64 size, rather than requiring an unsigned HOST_WIDE_INT size.
27091 (gimple_add_tmp_var): Likewise.
27092
27093 2018-01-12 Martin Liska <mliska@suse.cz>
27094
27095 * gimple.c (gimple_alloc_counts): Use uint64_t instead of int.
27096 (gimple_alloc_sizes): Likewise.
27097 (dump_gimple_statistics): Use PRIu64 in printf format.
27098 * gimple.h: Change uint64_t to int.
27099
27100 2018-01-12 Martin Liska <mliska@suse.cz>
27101
27102 * tree-core.h: Use uint64_t instead of int.
27103 * tree.c (tree_node_counts): Likewise.
27104 (tree_node_sizes): Likewise.
27105 (dump_tree_statistics): Use PRIu64 in printf format.
27106
27107 2018-01-12 Martin Liska <mliska@suse.cz>
27108
27109 * Makefile.in: As qsort_chk is implemented in vec.c, add
27110 vec.o to linkage of gencfn-macros.
27111 * tree.c (build_new_poly_int_cst): Add CXX_MEM_STAT_INFO as it's
27112 passing the info to record_node_allocation_statistics.
27113 (test_vector_cst_patterns): Add CXX_MEM_STAT_INFO to declaration
27114 and pass the info.
27115 * ggc-common.c (struct ggc_usage): Add operator== and use
27116 it in operator< and compare function.
27117 * mem-stats.h (struct mem_usage): Likewise.
27118 * vec.c (struct vec_usage): Remove operator< and compare
27119 function. Can be simply inherited.
27120
27121 2018-01-12 Martin Jambor <mjambor@suse.cz>
27122
27123 PR target/81616
27124 * params.def: New parameter PARAM_AVOID_FMA_MAX_BITS.
27125 * tree-ssa-math-opts.c: Include domwalk.h.
27126 (convert_mult_to_fma_1): New function.
27127 (fma_transformation_info): New type.
27128 (fma_deferring_state): Likewise.
27129 (cancel_fma_deferring): New function.
27130 (result_of_phi): Likewise.
27131 (last_fma_candidate_feeds_initial_phi): Likewise.
27132 (convert_mult_to_fma): Added deferring logic, split actual
27133 transformation to convert_mult_to_fma_1.
27134 (math_opts_dom_walker): New type.
27135 (math_opts_dom_walker::after_dom_children): New method, body moved
27136 here from pass_optimize_widening_mul::execute, added deferring logic
27137 bits.
27138 (pass_optimize_widening_mul::execute): Moved most of code to
27139 math_opts_dom_walker::after_dom_children.
27140 * config/i386/x86-tune.def (X86_TUNE_AVOID_128FMA_CHAINS): New.
27141 * config/i386/i386.c (ix86_option_override_internal): Added
27142 maybe_setting of PARAM_AVOID_FMA_MAX_BITS.
27143
27144 2018-01-12 Richard Biener <rguenther@suse.de>
27145
27146 PR debug/83157
27147 * dwarf2out.c (gen_variable_die): Do not reset old_die for
27148 inline instance vars.
27149
27150 2018-01-12 Oleg Endo <olegendo@gcc.gnu.org>
27151
27152 PR target/81819
27153 * config/rx/rx.c (rx_is_restricted_memory_address):
27154 Handle SUBREG case.
27155
27156 2018-01-12 Richard Biener <rguenther@suse.de>
27157
27158 PR tree-optimization/80846
27159 * target.def (split_reduction): New target hook.
27160 * targhooks.c (default_split_reduction): New function.
27161 * targhooks.h (default_split_reduction): Declare.
27162 * tree-vect-loop.c (vect_create_epilog_for_reduction): If the
27163 target requests first reduce vectors by combining low and high
27164 parts.
27165 * tree-vect-stmts.c (vect_gen_perm_mask_any): Adjust.
27166 (get_vectype_for_scalar_type_and_size): Export.
27167 * tree-vectorizer.h (get_vectype_for_scalar_type_and_size): Declare.
27168 * doc/tm.texi.in (TARGET_VECTORIZE_SPLIT_REDUCTION): Document.
27169 * doc/tm.texi: Regenerate.
27170 * config/i386/i386.c (ix86_split_reduction): Implement
27171 TARGET_VECTORIZE_SPLIT_REDUCTION.
27172
27173 2018-01-12 Eric Botcazou <ebotcazou@adacore.com>
27174
27175 PR target/83368
27176 * config/sparc/sparc.h (PIC_OFFSET_TABLE_REGNUM): Set to INVALID_REGNUM
27177 in PIC mode except for TARGET_VXWORKS_RTP.
27178 * config/sparc/sparc.c: Include cfgrtl.h.
27179 (TARGET_INIT_PIC_REG): Define.
27180 (TARGET_USE_PSEUDO_PIC_REG): Likewise.
27181 (sparc_pic_register_p): New predicate.
27182 (sparc_legitimate_address_p): Use it.
27183 (sparc_legitimize_pic_address): Likewise.
27184 (sparc_delegitimize_address): Likewise.
27185 (sparc_mode_dependent_address_p): Likewise.
27186 (gen_load_pcrel_sym): Remove 4th parameter.
27187 (load_got_register): Adjust call to above. Remove obsolete stuff.
27188 (sparc_expand_prologue): Do not call load_got_register here.
27189 (sparc_flat_expand_prologue): Likewise.
27190 (sparc_output_mi_thunk): Set the pic_offset_table_rtx object.
27191 (sparc_use_pseudo_pic_reg): New function.
27192 (sparc_init_pic_reg): Likewise.
27193 * config/sparc/sparc.md (vxworks_load_got): Set the GOT register.
27194 (builtin_setjmp_receiver): Enable only for TARGET_VXWORKS_RTP.
27195
27196 2018-01-12 Christophe Lyon <christophe.lyon@linaro.org>
27197
27198 * doc/sourcebuild.texi (Effective-Target Keywords, Other attributes):
27199 Add item for branch_cost.
27200
27201 2018-01-12 Eric Botcazou <ebotcazou@adacore.com>
27202
27203 PR rtl-optimization/83565
27204 * rtlanal.c (nonzero_bits1): On WORD_REGISTER_OPERATIONS machines, do
27205 not extend the result to a larger mode for rotate operations.
27206 (num_sign_bit_copies1): Likewise.
27207
27208 2018-01-12 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
27209
27210 PR target/40411
27211 * config/sol2.h (STARTFILE_ARCH_SPEC): Don't use with -shared or
27212 -symbolic.
27213 Use values-Xc.o for -pedantic.
27214 Link with values-xpg4.o for C90, values-xpg6.o otherwise.
27215
27216 2018-01-12 Martin Liska <mliska@suse.cz>
27217
27218 PR ipa/83054
27219 * ipa-devirt.c (final_warning_record::grow_type_warnings):
27220 New function.
27221 (possible_polymorphic_call_targets): Use it.
27222 (ipa_devirt): Likewise.
27223
27224 2018-01-12 Martin Liska <mliska@suse.cz>
27225
27226 * profile-count.h (enum profile_quality): Use 0 as invalid
27227 enum value of profile_quality.
27228
27229 2018-01-12 Chung-Ju Wu <jasonwucj@gmail.com>
27230
27231 * doc/invoke.texi (NDS32 Options): Add -mext-perf, -mext-perf2 and
27232 -mext-string options.
27233
27234 2018-01-12 Richard Biener <rguenther@suse.de>
27235
27236 * lto-streamer-out.c (DFS::DFS_write_tree_body): Process
27237 DECL_DEBUG_EXPR conditional on DECL_HAS_DEBUG_EXPR_P.
27238 * tree-streamer-in.c (lto_input_ts_decl_common_tree_pointers):
27239 Likewise.
27240 * tree-streamer-out.c (write_ts_decl_common_tree_pointers): Likewise.
27241
27242 2018-01-11 Michael Meissner <meissner@linux.vnet.ibm.com>
27243
27244 * configure.ac (--with-long-double-format): Add support for the
27245 configuration option to change the default long double format on
27246 PowerPC systems.
27247 * config.gcc (powerpc*-linux*-*): Likewise.
27248 * configure: Regenerate.
27249 * config/rs6000/rs6000-c.c (rs6000_cpu_cpp_builtins): If long
27250 double is IEEE, define __KC__ and __KF__ to allow floatn.h to be
27251 used without modification.
27252
27253 2018-01-11 Bill Schmidt <wschmidt@linux.vnet.ibm.com>
27254
27255 * config/rs6000/rs6000-builtin.def (BU_P7_MISC_X): New #define.
27256 (SPEC_BARRIER): New instantiation of BU_P7_MISC_X.
27257 * config/rs6000/rs6000.c (rs6000_expand_builtin): Handle
27258 MISC_BUILTIN_SPEC_BARRIER.
27259 (rs6000_init_builtins): Likewise.
27260 * config/rs6000/rs6000.md (UNSPECV_SPEC_BARRIER): New UNSPECV
27261 enum value.
27262 (speculation_barrier): New define_insn.
27263 * doc/extend.texi: Document __builtin_speculation_barrier.
27264
27265 2018-01-11 Jakub Jelinek <jakub@redhat.com>
27266
27267 PR target/83203
27268 * config/i386/i386.c (ix86_expand_vector_init_one_nonzero): If one_var
27269 is 0, for V{8,16}S[IF] and V[48]D[IF]mode use gen_vec_set<mode>_0.
27270 * config/i386/sse.md (VI8_AVX_AVX512F, VI4F_256_512): New mode
27271 iterators.
27272 (ssescalarmodesuffix): Add 512-bit vectors. Use "d" or "q" for
27273 integral modes instead of "ss" and "sd".
27274 (vec_set<mode>_0): New define_insns for 256-bit and 512-bit
27275 vectors with 32-bit and 64-bit elements.
27276 (vecdupssescalarmodesuffix): New mode attribute.
27277 (vec_dup<mode>): Use it.
27278
27279 2018-01-11 H.J. Lu <hongjiu.lu@intel.com>
27280
27281 PR target/83330
27282 * config/i386/i386.c (ix86_compute_frame_layout): Align stack
27283 frame if argument is passed on stack.
27284
27285 2018-01-11 Jakub Jelinek <jakub@redhat.com>
27286
27287 PR target/82682
27288 * ree.c (combine_reaching_defs): Optimize also
27289 reg2=exp; reg1=reg2; reg2=any_extend(reg1); into
27290 reg2=any_extend(exp); reg1=reg2;, formatting fix.
27291
27292 2018-01-11 Jan Hubicka <hubicka@ucw.cz>
27293
27294 PR middle-end/83189
27295 * gimple-ssa-isolate-paths.c (isolate_path): Fix profile update.
27296
27297 2018-01-11 Jan Hubicka <hubicka@ucw.cz>
27298
27299 PR middle-end/83718
27300 * tree-inline.c (copy_cfg_body): Adjust num&den for scaling
27301 after they are computed.
27302
27303 2018-01-11 Bin Cheng <bin.cheng@arm.com>
27304
27305 PR tree-optimization/83695
27306 * gimple-loop-linterchange.cc
27307 (tree_loop_interchange::interchange_loops): Call scev_reset_htab to
27308 reset cached scev information after interchange.
27309 (pass_linterchange::execute): Remove call to scev_reset_htab.
27310
27311 2018-01-11 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
27312
27313 * config/arm/arm_neon.h (vfmlal_lane_low_u32, vfmlal_lane_high_u32,
27314 vfmlalq_laneq_low_u32, vfmlalq_lane_low_u32, vfmlal_laneq_low_u32,
27315 vfmlalq_laneq_high_u32, vfmlalq_lane_high_u32, vfmlal_laneq_high_u32,
27316 vfmlsl_lane_low_u32, vfmlsl_lane_high_u32, vfmlslq_laneq_low_u32,
27317 vfmlslq_lane_low_u32, vfmlsl_laneq_low_u32, vfmlslq_laneq_high_u32,
27318 vfmlslq_lane_high_u32, vfmlsl_laneq_high_u32): Define.
27319 * config/arm/arm_neon_builtins.def (vfmal_lane_low,
27320 vfmal_lane_lowv4hf, vfmal_lane_lowv8hf, vfmal_lane_high,
27321 vfmal_lane_highv4hf, vfmal_lane_highv8hf, vfmsl_lane_low,
27322 vfmsl_lane_lowv4hf, vfmsl_lane_lowv8hf, vfmsl_lane_high,
27323 vfmsl_lane_highv4hf, vfmsl_lane_highv8hf): New sets of builtins.
27324 * config/arm/iterators.md (VFMLSEL2, vfmlsel2): New mode attributes.
27325 (V_lane_reg): Likewise.
27326 * config/arm/neon.md (neon_vfm<vfml_op>l_lane_<vfml_half><VCVTF:mode>):
27327 New define_expand.
27328 (neon_vfm<vfml_op>l_lane_<vfml_half><vfmlsel2><mode>): Likewise.
27329 (vfmal_lane_low<mode>_intrinsic,
27330 vfmal_lane_low<vfmlsel2><mode>_intrinsic,
27331 vfmal_lane_high<vfmlsel2><mode>_intrinsic,
27332 vfmal_lane_high<mode>_intrinsic, vfmsl_lane_low<mode>_intrinsic,
27333 vfmsl_lane_low<vfmlsel2><mode>_intrinsic,
27334 vfmsl_lane_high<vfmlsel2><mode>_intrinsic,
27335 vfmsl_lane_high<mode>_intrinsic): New define_insns.
27336
27337 2018-01-11 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
27338
27339 * config/arm/arm-cpus.in (fp16fml): New feature.
27340 (ALL_SIMD): Add fp16fml.
27341 (armv8.2-a): Add fp16fml as an option.
27342 (armv8.3-a): Likewise.
27343 (armv8.4-a): Add fp16fml as part of fp16.
27344 * config/arm/arm.h (TARGET_FP16FML): Define.
27345 * config/arm/arm-c.c (arm_cpu_builtins): Define __ARM_FEATURE_FP16_FML
27346 when appropriate.
27347 * config/arm/arm-modes.def (V2HF): Define.
27348 * config/arm/arm_neon.h (vfmlal_low_u32, vfmlsl_low_u32,
27349 vfmlal_high_u32, vfmlsl_high_u32, vfmlalq_low_u32,
27350 vfmlslq_low_u32, vfmlalq_high_u32, vfmlslq_high_u32): Define.
27351 * config/arm/arm_neon_builtins.def (vfmal_low, vfmal_high,
27352 vfmsl_low, vfmsl_high): New set of builtins.
27353 * config/arm/iterators.md (PLUSMINUS): New code iterator.
27354 (vfml_op): New code attribute.
27355 (VFMLHALVES): New int iterator.
27356 (VFML, VFMLSEL): New mode attributes.
27357 (V_reg): Define mapping for V2HF.
27358 (V_hi, V_lo): New mode attributes.
27359 (VF_constraint): Likewise.
27360 (vfml_half, vfml_half_selector): New int attributes.
27361 * config/arm/neon.md (neon_vfm<vfml_op>l_<vfml_half><mode>): New
27362 define_expand.
27363 (vfmal_low<mode>_intrinsic, vfmsl_high<mode>_intrinsic,
27364 vfmal_high<mode>_intrinsic, vfmsl_low<mode>_intrinsic):
27365 New define_insn.
27366 * config/arm/t-arm-elf (v8_fps): Add fp16fml.
27367 * config/arm/t-multilib (v8_2_a_simd_variants): Add fp16fml.
27368 * config/arm/unspecs.md (UNSPEC_VFML_LO, UNSPEC_VFML_HI): New unspecs.
27369 * doc/invoke.texi (ARM Options): Document fp16fml. Update armv8.4-a
27370 documentation.
27371 * doc/sourcebuild.texi (arm_fp16fml_neon_ok, arm_fp16fml_neon):
27372 Document new effective target and option set.
27373
27374 2018-01-11 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
27375
27376 * config/arm/arm-cpus.in (armv8_4): New feature.
27377 (ARMv8_4a): New fgroup.
27378 (armv8.4-a): New arch.
27379 * config/arm/arm-tables.opt: Regenerate.
27380 * config/arm/t-aprofile: Add matching rules for -march=armv8.4-a.
27381 * config/arm/t-arm-elf (all_v8_archs): Add armv8.4-a.
27382 * config/arm/t-multilib (v8_4_a_simd_variants): New variable.
27383 Add matching rules for -march=armv8.4-a and extensions.
27384 * doc/invoke.texi (ARM Options): Document -march=armv8.4-a.
27385
27386 2018-01-11 Oleg Endo <olegendo@gcc.gnu.org>
27387
27388 PR target/81821
27389 * config/rx/rx.md (BW): New mode attribute.
27390 (sync_lock_test_and_setsi): Add mode suffix to insn output.
27391
27392 2018-01-11 Richard Biener <rguenther@suse.de>
27393
27394 PR tree-optimization/83435
27395 * graphite.c (canonicalize_loop_form): Ignore fake loop exit edges.
27396 * graphite-scop-detection.c (scop_detection::get_sese): Likewise.
27397 * tree-vrp.c (add_assert_info): Drop TREE_OVERFLOW if they appear.
27398
27399 2018-01-11 Richard Sandiford <richard.sandiford@linaro.org>
27400 Alan Hayward <alan.hayward@arm.com>
27401 David Sherwood <david.sherwood@arm.com>
27402
27403 * config/aarch64/aarch64.c (aarch64_address_info): Add a const_offset
27404 field.
27405 (aarch64_classify_address): Initialize it. Track polynomial offsets.
27406 (aarch64_print_address_internal): Use it to check for a zero offset.
27407
27408 2018-01-11 Richard Sandiford <richard.sandiford@linaro.org>
27409 Alan Hayward <alan.hayward@arm.com>
27410 David Sherwood <david.sherwood@arm.com>
27411
27412 * config/aarch64/aarch64-modes.def (NUM_POLY_INT_COEFFS): Set to 2.
27413 * config/aarch64/aarch64-protos.h (aarch64_initial_elimination_offset):
27414 Return a poly_int64 rather than a HOST_WIDE_INT.
27415 (aarch64_offset_7bit_signed_scaled_p): Take the offset as a poly_int64
27416 rather than a HOST_WIDE_INT.
27417 * config/aarch64/aarch64.h (aarch64_frame): Protect with
27418 HAVE_POLY_INT_H rather than HOST_WIDE_INT. Change locals_offset,
27419 hard_fp_offset, frame_size, initial_adjust, callee_offset and
27420 final_offset from HOST_WIDE_INT to poly_int64.
27421 * config/aarch64/aarch64-builtins.c (aarch64_simd_expand_args): Use
27422 to_constant when getting the number of units in an Advanced SIMD
27423 mode.
27424 (aarch64_builtin_vectorized_function): Check for a constant number
27425 of units.
27426 * config/aarch64/aarch64-simd.md (mov<mode>): Handle polynomial
27427 GET_MODE_SIZE.
27428 (aarch64_ld<VSTRUCT:nregs>_lane<VALLDIF:mode>): Use the nunits
27429 attribute instead of GET_MODE_NUNITS.
27430 * config/aarch64/aarch64.c (aarch64_hard_regno_nregs)
27431 (aarch64_class_max_nregs): Use the constant_lowest_bound of the
27432 GET_MODE_SIZE for fixed-size registers.
27433 (aarch64_const_vec_all_same_in_range_p): Use const_vec_duplicate_p.
27434 (aarch64_hard_regno_call_part_clobbered, aarch64_classify_index)
27435 (aarch64_mode_valid_for_sched_fusion_p, aarch64_classify_address)
27436 (aarch64_legitimize_address_displacement, aarch64_secondary_reload)
27437 (aarch64_print_operand, aarch64_print_address_internal)
27438 (aarch64_address_cost, aarch64_rtx_costs, aarch64_register_move_cost)
27439 (aarch64_short_vector_p, aapcs_vfp_sub_candidate)
27440 (aarch64_simd_attr_length_rglist, aarch64_operands_ok_for_ldpstp):
27441 Handle polynomial GET_MODE_SIZE.
27442 (aarch64_hard_regno_caller_save_mode): Likewise. Return modes
27443 wider than SImode without modification.
27444 (tls_symbolic_operand_type): Use strip_offset instead of split_const.
27445 (aarch64_pass_by_reference, aarch64_layout_arg, aarch64_pad_reg_upward)
27446 (aarch64_gimplify_va_arg_expr): Assert that we don't yet handle
27447 passing and returning SVE modes.
27448 (aarch64_function_value, aarch64_layout_arg): Use gen_int_mode
27449 rather than GEN_INT.
27450 (aarch64_emit_probe_stack_range): Take the size as a poly_int64
27451 rather than a HOST_WIDE_INT, but call sorry if it isn't constant.
27452 (aarch64_allocate_and_probe_stack_space): Likewise.
27453 (aarch64_layout_frame): Cope with polynomial offsets.
27454 (aarch64_save_callee_saves, aarch64_restore_callee_saves): Take the
27455 start_offset as a poly_int64 rather than a HOST_WIDE_INT. Track
27456 polynomial offsets.
27457 (offset_9bit_signed_unscaled_p, offset_12bit_unsigned_scaled_p)
27458 (aarch64_offset_7bit_signed_scaled_p): Take the offset as a
27459 poly_int64 rather than a HOST_WIDE_INT.
27460 (aarch64_get_separate_components, aarch64_process_components)
27461 (aarch64_expand_prologue, aarch64_expand_epilogue)
27462 (aarch64_use_return_insn_p): Handle polynomial frame offsets.
27463 (aarch64_anchor_offset): New function, split out from...
27464 (aarch64_legitimize_address): ...here.
27465 (aarch64_builtin_vectorization_cost): Handle polynomial
27466 TYPE_VECTOR_SUBPARTS.
27467 (aarch64_simd_check_vect_par_cnst_half): Handle polynomial
27468 GET_MODE_NUNITS.
27469 (aarch64_simd_make_constant, aarch64_expand_vector_init): Get the
27470 number of elements from the PARALLEL rather than the mode.
27471 (aarch64_shift_truncation_mask): Use GET_MODE_UNIT_BITSIZE
27472 rather than GET_MODE_BITSIZE.
27473 (aarch64_evpc_trn, aarch64_evpc_uzp, aarch64_evpc_ext)
27474 (aarch64_evpc_rev, aarch64_evpc_dup, aarch64_evpc_zip)
27475 (aarch64_expand_vec_perm_const_1): Handle polynomial
27476 d->perm.length () and d->perm elements.
27477 (aarch64_evpc_tbl): Likewise. Use nelt rather than GET_MODE_NUNITS.
27478 Apply to_constant to d->perm elements.
27479 (aarch64_simd_valid_immediate, aarch64_vec_fpconst_pow_of_2): Handle
27480 polynomial CONST_VECTOR_NUNITS.
27481 (aarch64_move_pointer): Take amount as a poly_int64 rather
27482 than an int.
27483 (aarch64_progress_pointer): Avoid temporary variable.
27484 * config/aarch64/aarch64.md (aarch64_<crc_variant>): Use
27485 the mode attribute instead of GET_MODE.
27486
27487 2018-01-11 Richard Sandiford <richard.sandiford@linaro.org>
27488 Alan Hayward <alan.hayward@arm.com>
27489 David Sherwood <david.sherwood@arm.com>
27490
27491 * config/aarch64/aarch64.c (aarch64_force_temporary): Assert that
27492 x exists before using it.
27493 (aarch64_add_constant_internal): Rename to...
27494 (aarch64_add_offset_1): ...this. Replace regnum with separate
27495 src and dest rtxes. Handle the case in which they're different,
27496 including when the offset is zero. Replace scratchreg with an rtx.
27497 Use 2 additions if there is no spare register into which we can
27498 move a 16-bit constant.
27499 (aarch64_add_constant): Delete.
27500 (aarch64_add_offset): Replace reg with separate src and dest
27501 rtxes. Take a poly_int64 offset instead of a HOST_WIDE_INT.
27502 Use aarch64_add_offset_1.
27503 (aarch64_add_sp, aarch64_sub_sp): Take the scratch register as
27504 an rtx rather than an int. Take the delta as a poly_int64
27505 rather than a HOST_WIDE_INT. Use aarch64_add_offset.
27506 (aarch64_expand_mov_immediate): Update uses of aarch64_add_offset.
27507 (aarch64_expand_prologue): Update calls to aarch64_sub_sp,
27508 aarch64_allocate_and_probe_stack_space and aarch64_add_offset.
27509 (aarch64_expand_epilogue): Update calls to aarch64_add_offset
27510 and aarch64_add_sp.
27511 (aarch64_output_mi_thunk): Use aarch64_add_offset rather than
27512 aarch64_add_constant.
27513
27514 2018-01-11 Richard Sandiford <richard.sandiford@linaro.org>
27515
27516 * config/aarch64/aarch64.c (aarch64_reinterpret_float_as_int):
27517 Use scalar_float_mode.
27518
27519 2018-01-11 Richard Sandiford <richard.sandiford@linaro.org>
27520
27521 * config/aarch64/aarch64-simd.md
27522 (aarch64_fml<f16mac1>l<f16quad>_low<mode>): Avoid GET_MODE_NUNITS.
27523 (aarch64_fml<f16mac1>l<f16quad>_high<mode>): Likewise.
27524 (aarch64_fml<f16mac1>l_lane_lowv2sf): Likewise.
27525 (aarch64_fml<f16mac1>l_lane_highv2sf): Likewise.
27526 (aarch64_fml<f16mac1>lq_laneq_lowv4sf): Likewise.
27527 (aarch64_fml<f16mac1>lq_laneq_highv4sf): Likewise.
27528 (aarch64_fml<f16mac1>l_laneq_lowv2sf): Likewise.
27529 (aarch64_fml<f16mac1>l_laneq_highv2sf): Likewise.
27530 (aarch64_fml<f16mac1>lq_lane_lowv4sf): Likewise.
27531 (aarch64_fml<f16mac1>lq_lane_highv4sf): Likewise.
27532
27533 2018-01-11 Prathamesh Kulkarni <prathamesh.kulkarni@linaro.org>
27534
27535 PR target/83514
27536 * config/arm/arm.c (arm_declare_function_name): Set arch_to_print if
27537 targ_options->x_arm_arch_string is non NULL.
27538
27539 2018-01-11 Tamar Christina <tamar.christina@arm.com>
27540
27541 * config/aarch64/aarch64.h
27542 (AARCH64_FL_FOR_ARCH8_4): Add AARCH64_FL_DOTPROD.
27543
27544 2018-01-11 Sudakshina Das <sudi.das@arm.com>
27545
27546 PR target/82096
27547 * expmed.c (emit_store_flag_force): Swap if const op0
27548 and change VOIDmode to mode of op0.
27549
27550 2018-01-11 Richard Sandiford <richard.sandiford@linaro.org>
27551
27552 PR rtl-optimization/83761
27553 * caller-save.c (replace_reg_with_saved_mem): Pass bits rather
27554 than bytes to mode_for_size.
27555
27556 2018-01-10 Jan Hubicka <hubicka@ucw.cz>
27557
27558 PR middle-end/83189
27559 * gfortran.fortran-torture/compile/pr83189.f90: New testcase.
27560 * tree-ssa-loop-manip.c (tree_transform_and_unroll_loop): Handle zero
27561 profile.
27562
27563 2018-01-10 Jan Hubicka <hubicka@ucw.cz>
27564
27565 PR middle-end/83575
27566 * cfgrtl.c (rtl_verify_edges): Only verify fixability of partition
27567 when in layout mode.
27568 (cfg_layout_finalize): Do not verify cfg before we are out of layout.
27569 * cfgcleanup.c (try_optimize_cfg): Only verify flow info when doing
27570 partition fixup.
27571
27572 2018-01-10 Michael Collison <michael.collison@arm.com>
27573
27574 * config/aarch64/aarch64-modes.def (V2HF): New VECTOR_MODE.
27575 * config/aarch64/aarch64-option-extension.def: Add
27576 AARCH64_OPT_EXTENSION of 'fp16fml'.
27577 * config/aarch64/aarch64-c.c (aarch64_update_cpp_builtins):
27578 (__ARM_FEATURE_FP16_FML): Define if TARGET_F16FML is true.
27579 * config/aarch64/predicates.md (aarch64_lane_imm3): New predicate.
27580 * config/aarch64/constraints.md (Ui7): New constraint.
27581 * config/aarch64/iterators.md (VFMLA_W): New mode iterator.
27582 (VFMLA_SEL_W): Ditto.
27583 (f16quad): Ditto.
27584 (f16mac1): Ditto.
27585 (VFMLA16_LOW): New int iterator.
27586 (VFMLA16_HIGH): Ditto.
27587 (UNSPEC_FMLAL): New unspec.
27588 (UNSPEC_FMLSL): Ditto.
27589 (UNSPEC_FMLAL2): Ditto.
27590 (UNSPEC_FMLSL2): Ditto.
27591 (f16mac): New code attribute.
27592 * config/aarch64/aarch64-simd-builtins.def
27593 (aarch64_fmlal_lowv2sf): Ditto.
27594 (aarch64_fmlsl_lowv2sf): Ditto.
27595 (aarch64_fmlalq_lowv4sf): Ditto.
27596 (aarch64_fmlslq_lowv4sf): Ditto.
27597 (aarch64_fmlal_highv2sf): Ditto.
27598 (aarch64_fmlsl_highv2sf): Ditto.
27599 (aarch64_fmlalq_highv4sf): Ditto.
27600 (aarch64_fmlslq_highv4sf): Ditto.
27601 (aarch64_fmlal_lane_lowv2sf): Ditto.
27602 (aarch64_fmlsl_lane_lowv2sf): Ditto.
27603 (aarch64_fmlal_laneq_lowv2sf): Ditto.
27604 (aarch64_fmlsl_laneq_lowv2sf): Ditto.
27605 (aarch64_fmlalq_lane_lowv4sf): Ditto.
27606 (aarch64_fmlsl_lane_lowv4sf): Ditto.
27607 (aarch64_fmlalq_laneq_lowv4sf): Ditto.
27608 (aarch64_fmlsl_laneq_lowv4sf): Ditto.
27609 (aarch64_fmlal_lane_highv2sf): Ditto.
27610 (aarch64_fmlsl_lane_highv2sf): Ditto.
27611 (aarch64_fmlal_laneq_highv2sf): Ditto.
27612 (aarch64_fmlsl_laneq_highv2sf): Ditto.
27613 (aarch64_fmlalq_lane_highv4sf): Ditto.
27614 (aarch64_fmlsl_lane_highv4sf): Ditto.
27615 (aarch64_fmlalq_laneq_highv4sf): Ditto.
27616 (aarch64_fmlsl_laneq_highv4sf): Ditto.
27617 * config/aarch64/aarch64-simd.md:
27618 (aarch64_fml<f16mac1>l<f16quad>_low<mode>): New pattern.
27619 (aarch64_fml<f16mac1>l<f16quad>_high<mode>): Ditto.
27620 (aarch64_simd_fml<f16mac1>l<f16quad>_low<mode>): Ditto.
27621 (aarch64_simd_fml<f16mac1>l<f16quad>_high<mode>): Ditto.
27622 (aarch64_fml<f16mac1>l_lane_lowv2sf): Ditto.
27623 (aarch64_fml<f16mac1>l_lane_highv2sf): Ditto.
27624 (aarch64_simd_fml<f16mac>l_lane_lowv2sf): Ditto.
27625 (aarch64_simd_fml<f16mac>l_lane_highv2sf): Ditto.
27626 (aarch64_fml<f16mac1>lq_laneq_lowv4sf): Ditto.
27627 (aarch64_fml<f16mac1>lq_laneq_highv4sf): Ditto.
27628 (aarch64_simd_fml<f16mac>lq_laneq_lowv4sf): Ditto.
27629 (aarch64_simd_fml<f16mac>lq_laneq_highv4sf): Ditto.
27630 (aarch64_fml<f16mac1>l_laneq_lowv2sf): Ditto.
27631 (aarch64_fml<f16mac1>l_laneq_highv2sf): Ditto.
27632 (aarch64_simd_fml<f16mac>l_laneq_lowv2sf): Ditto.
27633 (aarch64_simd_fml<f16mac>l_laneq_highv2sf): Ditto.
27634 (aarch64_fml<f16mac1>lq_lane_lowv4sf): Ditto.
27635 (aarch64_fml<f16mac1>lq_lane_highv4sf): Ditto.
27636 (aarch64_simd_fml<f16mac>lq_lane_lowv4sf): Ditto.
27637 (aarch64_simd_fml<f16mac>lq_lane_highv4sf): Ditto.
27638 * config/aarch64/arm_neon.h (vfmlal_low_u32): New intrinsic.
27639 (vfmlsl_low_u32): Ditto.
27640 (vfmlalq_low_u32): Ditto.
27641 (vfmlslq_low_u32): Ditto.
27642 (vfmlal_high_u32): Ditto.
27643 (vfmlsl_high_u32): Ditto.
27644 (vfmlalq_high_u32): Ditto.
27645 (vfmlslq_high_u32): Ditto.
27646 (vfmlal_lane_low_u32): Ditto.
27647 (vfmlsl_lane_low_u32): Ditto.
27648 (vfmlal_laneq_low_u32): Ditto.
27649 (vfmlsl_laneq_low_u32): Ditto.
27650 (vfmlalq_lane_low_u32): Ditto.
27651 (vfmlslq_lane_low_u32): Ditto.
27652 (vfmlalq_laneq_low_u32): Ditto.
27653 (vfmlslq_laneq_low_u32): Ditto.
27654 (vfmlal_lane_high_u32): Ditto.
27655 (vfmlsl_lane_high_u32): Ditto.
27656 (vfmlal_laneq_high_u32): Ditto.
27657 (vfmlsl_laneq_high_u32): Ditto.
27658 (vfmlalq_lane_high_u32): Ditto.
27659 (vfmlslq_lane_high_u32): Ditto.
27660 (vfmlalq_laneq_high_u32): Ditto.
27661 (vfmlslq_laneq_high_u32): Ditto.
27662 * config/aarch64/aarch64.h (AARCH64_FL_F16SML): New flag.
27663 (AARCH64_FL_FOR_ARCH8_4): New.
27664 (AARCH64_ISA_F16FML): New ISA flag.
27665 (TARGET_F16FML): New feature flag for fp16fml.
27666 (doc/invoke.texi): Document new fp16fml option.
27667
27668 2018-01-10 Michael Collison <michael.collison@arm.com>
27669
27670 * config/aarch64/aarch64-builtins.c:
27671 (aarch64_types_ternopu_imm_qualifiers, TYPES_TERNOPUI): New.
27672 * config/aarch64/aarch64-c.c (aarch64_update_cpp_builtins):
27673 (__ARM_FEATURE_SHA3): Define if TARGET_SHA3 is true.
27674 * config/aarch64/aarch64.h (AARCH64_FL_SHA3): New flags.
27675 (AARCH64_ISA_SHA3): New ISA flag.
27676 (TARGET_SHA3): New feature flag for sha3.
27677 * config/aarch64/iterators.md (sha512_op): New int attribute.
27678 (CRYPTO_SHA512): New int iterator.
27679 (UNSPEC_SHA512H): New unspec.
27680 (UNSPEC_SHA512H2): Ditto.
27681 (UNSPEC_SHA512SU0): Ditto.
27682 (UNSPEC_SHA512SU1): Ditto.
27683 * config/aarch64/aarch64-simd-builtins.def
27684 (aarch64_crypto_sha512hqv2di): New builtin.
27685 (aarch64_crypto_sha512h2qv2di): Ditto.
27686 (aarch64_crypto_sha512su0qv2di): Ditto.
27687 (aarch64_crypto_sha512su1qv2di): Ditto.
27688 (aarch64_eor3qv8hi): Ditto.
27689 (aarch64_rax1qv2di): Ditto.
27690 (aarch64_xarqv2di): Ditto.
27691 (aarch64_bcaxqv8hi): Ditto.
27692 * config/aarch64/aarch64-simd.md:
27693 (aarch64_crypto_sha512h<sha512_op>qv2di): New pattern.
27694 (aarch64_crypto_sha512su0qv2di): Ditto.
27695 (aarch64_crypto_sha512su1qv2di): Ditto.
27696 (aarch64_eor3qv8hi): Ditto.
27697 (aarch64_rax1qv2di): Ditto.
27698 (aarch64_xarqv2di): Ditto.
27699 (aarch64_bcaxqv8hi): Ditto.
27700 * config/aarch64/arm_neon.h (vsha512hq_u64): New intrinsic.
27701 (vsha512h2q_u64): Ditto.
27702 (vsha512su0q_u64): Ditto.
27703 (vsha512su1q_u64): Ditto.
27704 (veor3q_u16): Ditto.
27705 (vrax1q_u64): Ditto.
27706 (vxarq_u64): Ditto.
27707 (vbcaxq_u16): Ditto.
27708 * config/arm/types.md (crypto_sha512): New type attribute.
27709 (crypto_sha3): Ditto.
27710 (doc/invoke.texi): Document new sha3 option.
27711
27712 2018-01-10 Michael Collison <michael.collison@arm.com>
27713
27714 * config/aarch64/aarch64-builtins.c:
27715 (aarch64_types_quadopu_imm_qualifiers, TYPES_QUADOPUI): New.
27716 * config/aarch64/aarch64-c.c (aarch64_update_cpp_builtins):
27717 (__ARM_FEATURE_SM3): Define if TARGET_SM4 is true.
27718 (__ARM_FEATURE_SM4): Define if TARGET_SM4 is true.
27719 * config/aarch64/aarch64.h (AARCH64_FL_SM4): New flags.
27720 (AARCH64_ISA_SM4): New ISA flag.
27721 (TARGET_SM4): New feature flag for sm4.
27722 * config/aarch64/aarch64-simd-builtins.def
27723 (aarch64_sm3ss1qv4si): Ditto.
27724 (aarch64_sm3tt1aq4si): Ditto.
27725 (aarch64_sm3tt1bq4si): Ditto.
27726 (aarch64_sm3tt2aq4si): Ditto.
27727 (aarch64_sm3tt2bq4si): Ditto.
27728 (aarch64_sm3partw1qv4si): Ditto.
27729 (aarch64_sm3partw2qv4si): Ditto.
27730 (aarch64_sm4eqv4si): Ditto.
27731 (aarch64_sm4ekeyqv4si): Ditto.
27732 * config/aarch64/aarch64-simd.md:
27733 (aarch64_sm3ss1qv4si): Ditto.
27734 (aarch64_sm3tt<sm3tt_op>qv4si): Ditto.
27735 (aarch64_sm3partw<sm3part_op>qv4si): Ditto.
27736 (aarch64_sm4eqv4si): Ditto.
27737 (aarch64_sm4ekeyqv4si): Ditto.
27738 * config/aarch64/iterators.md (sm3tt_op): New int iterator.
27739 (sm3part_op): Ditto.
27740 (CRYPTO_SM3TT): Ditto.
27741 (CRYPTO_SM3PART): Ditto.
27742 (UNSPEC_SM3SS1): New unspec.
27743 (UNSPEC_SM3TT1A): Ditto.
27744 (UNSPEC_SM3TT1B): Ditto.
27745 (UNSPEC_SM3TT2A): Ditto.
27746 (UNSPEC_SM3TT2B): Ditto.
27747 (UNSPEC_SM3PARTW1): Ditto.
27748 (UNSPEC_SM3PARTW2): Ditto.
27749 (UNSPEC_SM4E): Ditto.
27750 (UNSPEC_SM4EKEY): Ditto.
27751 * config/aarch64/constraints.md (Ui2): New constraint.
27752 * config/aarch64/predicates.md (aarch64_imm2): New predicate.
27753 * config/arm/types.md (crypto_sm3): New type attribute.
27754 (crypto_sm4): Ditto.
27755 * config/aarch64/arm_neon.h (vsm3ss1q_u32): New intrinsic.
27756 (vsm3tt1aq_u32): Ditto.
27757 (vsm3tt1bq_u32): Ditto.
27758 (vsm3tt2aq_u32): Ditto.
27759 (vsm3tt2bq_u32): Ditto.
27760 (vsm3partw1q_u32): Ditto.
27761 (vsm3partw2q_u32): Ditto.
27762 (vsm4eq_u32): Ditto.
27763 (vsm4ekeyq_u32): Ditto.
27764 (doc/invoke.texi): Document new sm4 option.
27765
27766 2018-01-10 Michael Collison <michael.collison@arm.com>
27767
27768 * config/aarch64/aarch64-arches.def (armv8.4-a): New architecture.
27769 * config/aarch64/aarch64.h (AARCH64_ISA_V8_4): New ISA flag.
27770 (AARCH64_FL_FOR_ARCH8_4): New.
27771 (AARCH64_FL_V8_4): New flag.
27772 (doc/invoke.texi): Document new armv8.4-a option.
27773
27774 2018-01-10 Michael Collison <michael.collison@arm.com>
27775
27776 * config/aarch64/aarch64-c.c (aarch64_update_cpp_builtins):
27777 (__ARM_FEATURE_AES): Define if TARGET_AES is true.
27778 (__ARM_FEATURE_SHA2): Define if TARGET_SHA2 is true.
27779 * config/aarch64/aarch64-option-extension.def: Add
27780 AARCH64_OPT_EXTENSION of 'sha2'.
27781 (aes): Add AARCH64_OPT_EXTENSION of 'aes'.
27782 (crypto): Disable sha2 and aes if crypto disabled.
27783 (crypto): Enable aes and sha2 if enabled.
27784 (simd): Disable sha2 and aes if simd disabled.
27785 * config/aarch64/aarch64.h (AARCH64_FL_AES, AARCH64_FL_SHA2):
27786 New flags.
27787 (AARCH64_ISA_AES, AARCH64_ISA_SHA2): New ISA flags.
27788 (TARGET_SHA2): New feature flag for sha2.
27789 (TARGET_AES): New feature flag for aes.
27790 * config/aarch64/aarch64-simd.md:
27791 (aarch64_crypto_aes<aes_op>v16qi): Make pattern
27792 conditional on TARGET_AES.
27793 (aarch64_crypto_aes<aesmc_op>v16qi): Ditto.
27794 (aarch64_crypto_sha1hsi): Make pattern conditional
27795 on TARGET_SHA2.
27796 (aarch64_crypto_sha1hv4si): Ditto.
27797 (aarch64_be_crypto_sha1hv4si): Ditto.
27798 (aarch64_crypto_sha1su1v4si): Ditto.
27799 (aarch64_crypto_sha1<sha1_op>v4si): Ditto.
27800 (aarch64_crypto_sha1su0v4si): Ditto.
27801 (aarch64_crypto_sha256h<sha256_op>v4si): Ditto.
27802 (aarch64_crypto_sha256su0v4si): Ditto.
27803 (aarch64_crypto_sha256su1v4si): Ditto.
27804 (doc/invoke.texi): Document new aes and sha2 options.
27805
27806 2018-01-10 Martin Sebor <msebor@redhat.com>
27807
27808 PR tree-optimization/83781
27809 * gimple-fold.c (get_range_strlen): Avoid treating arrays of pointers
27810 as string arrays.
27811
27812 2018-01-11 Martin Sebor <msebor@gmail.com>
27813 Prathamesh Kulkarni <prathamesh.kulkarni@linaro.org>
27814
27815 PR tree-optimization/83501
27816 PR tree-optimization/81703
27817
27818 * tree-ssa-strlen.c (get_string_cst): Rename...
27819 (get_string_len): ...to this. Handle global constants.
27820 (handle_char_store): Adjust.
27821
27822 2018-01-10 Kito Cheng <kito.cheng@gmail.com>
27823 Jim Wilson <jimw@sifive.com>
27824
27825 * config/riscv/riscv-protos.h (riscv_output_return): New.
27826 * config/riscv/riscv.c (struct machine_function): New naked_p field.
27827 (riscv_attribute_table, riscv_output_return),
27828 (riscv_handle_fndecl_attribute, riscv_naked_function_p),
27829 (riscv_allocate_stack_slots_for_args, riscv_warn_func_return): New.
27830 (riscv_compute_frame_info): Only compute frame->mask if not a naked
27831 function.
27832 (riscv_expand_prologue): Add early return for naked function.
27833 (riscv_expand_epilogue): Likewise.
27834 (riscv_function_ok_for_sibcall): Return false for naked function.
27835 (riscv_set_current_function): New.
27836 (TARGET_SET_CURRENT_FUNCTION, TARGET_ALLOCATE_STACK_SLOTS_FOR_ARGS),
27837 (TARGET_ATTRIBUTE_TABLE, TARGET_WARN_FUNC_RETURN): New.
27838 * config/riscv/riscv.md (simple_return): Call riscv_output_return.
27839 * doc/extend.texi (RISC-V Function Attributes): New.
27840
27841 2018-01-10 Michael Meissner <meissner@linux.vnet.ibm.com>
27842
27843 * config/rs6000/rs6000.c (is_complex_IBM_long_double): Explicitly
27844 check for 128-bit long double before checking TCmode.
27845 * config/rs6000/rs6000.h (FLOAT128_IEEE_P): Explicitly check for
27846 128-bit long doubles before checking TFmode or TCmode.
27847 (FLOAT128_IBM_P): Likewise.
27848
27849 2018-01-10 Martin Sebor <msebor@redhat.com>
27850
27851 PR tree-optimization/83671
27852 * builtins.c (c_strlen): Unconditionally return zero for the empty
27853 string.
27854 Use -Warray-bounds for warnings.
27855 * gimple-fold.c (get_range_strlen): Handle non-constant lengths
27856 for non-constant array indices with COMPONENT_REF, arrays of
27857 arrays, and pointers to arrays.
27858 (gimple_fold_builtin_strlen): Determine and set length range for
27859 non-constant character arrays.
27860
27861 2018-01-10 Aldy Hernandez <aldyh@redhat.com>
27862
27863 PR middle-end/81897
27864 * tree-ssa-uninit.c (convert_control_dep_chain_into_preds): Skip
27865 empty blocks.
27866
27867 2018-01-10 Eric Botcazou <ebotcazou@adacore.com>
27868
27869 * dwarf2out.c (dwarf2out_var_location): Do not pass NULL to fprintf.
27870
27871 2018-01-10 Peter Bergner <bergner@vnet.ibm.com>
27872
27873 PR target/83399
27874 * config/rs6000/rs6000.c (print_operand) <'y'>: Use
27875 VECTOR_MEM_ALTIVEC_OR_VSX_P.
27876 * config/rs6000/vsx.md (*vsx_le_perm_load_<mode> for VSX_D): Use
27877 indexed_or_indirect_operand predicate.
27878 (*vsx_le_perm_load_<mode> for VSX_W): Likewise.
27879 (*vsx_le_perm_load_v8hi): Likewise.
27880 (*vsx_le_perm_load_v16qi): Likewise.
27881 (*vsx_le_perm_store_<mode> for VSX_D): Likewise.
27882 (*vsx_le_perm_store_<mode> for VSX_W): Likewise.
27883 (*vsx_le_perm_store_v8hi): Likewise.
27884 (*vsx_le_perm_store_v16qi): Likewise.
27885 (eight unnamed splitters): Likewise.
27886
27887 2018-01-10 Peter Bergner <bergner@vnet.ibm.com>
27888
27889 * config/rs6000/x86intrin.h: Change #warning to #error. Update message.
27890 * config/rs6000/emmintrin.h: Likewise.
27891 * config/rs6000/mmintrin.h: Likewise.
27892 * config/rs6000/xmmintrin.h: Likewise.
27893
27894 2018-01-10 David Malcolm <dmalcolm@redhat.com>
27895
27896 PR c++/43486
27897 * tree-core.h: Document EXPR_LOCATION_WRAPPER_P's usage of
27898 "public_flag".
27899 * tree.c (tree_nop_conversion): Return true for location wrapper
27900 nodes.
27901 (maybe_wrap_with_location): New function.
27902 (selftest::check_strip_nops): New function.
27903 (selftest::test_location_wrappers): New function.
27904 (selftest::tree_c_tests): Call it.
27905 * tree.h (STRIP_ANY_LOCATION_WRAPPER): New macro.
27906 (maybe_wrap_with_location): New decl.
27907 (EXPR_LOCATION_WRAPPER_P): New macro.
27908 (location_wrapper_p): New inline function.
27909 (tree_strip_any_location_wrapper): New inline function.
27910
27911 2018-01-10 H.J. Lu <hongjiu.lu@intel.com>
27912
27913 PR target/83735
27914 * config/i386/i386.c (ix86_compute_frame_layout): Always adjust
27915 stack_realign_offset for the largest alignment of stack slot
27916 actually used.
27917 (ix86_find_max_used_stack_alignment): New function.
27918 (ix86_finalize_stack_frame_flags): Use it. Set
27919 max_used_stack_alignment if we don't realign stack.
27920 * config/i386/i386.h (machine_function): Add
27921 max_used_stack_alignment.
27922
27923 2018-01-10 Christophe Lyon <christophe.lyon@linaro.org>
27924
27925 * config/arm/arm.opt (-mbranch-cost): New option.
27926 * config/arm/arm.h (BRANCH_COST): Take arm_branch_cost into
27927 account.
27928
27929 2018-01-10 Segher Boessenkool <segher@kernel.crashing.org>
27930
27931 PR target/83629
27932 * config/rs6000/rs6000.md (load_toc_v4_PIC_2, load_toc_v4_PIC_3b,
27933 load_toc_v4_PIC_3c): Wrap const term in CONST RTL.
27934
27935 2018-01-10 Richard Biener <rguenther@suse.de>
27936
27937 PR debug/83765
27938 * dwarf2out.c (gen_subprogram_die): Hoist old_die && declaration
27939 early out so it also covers the case where we have a non-NULL
27940 origin.
27941
27942 2018-01-10 Richard Sandiford <richard.sandiford@linaro.org>
27943
27944 PR tree-optimization/83753
27945 * tree-vect-stmts.c (get_group_load_store_type): Use VMAT_CONTIGUOUS
27946 for non-strided grouped accesses if the number of elements is 1.
27947
27948 2018-01-10 Jan Hubicka <hubicka@ucw.cz>
27949
27950 PR target/81616
27951 * i386.c (ix86_vectorize_builtin_gather): Check TARGET_USE_GATHER.
27952 * i386.h (TARGET_USE_GATHER): Define.
27953 * x86-tune.def (X86_TUNE_USE_GATHER): New.
27954
27955 2018-01-10 Martin Liska <mliska@suse.cz>
27956
27957 PR bootstrap/82831
27958 * basic-block.h (CLEANUP_NO_PARTITIONING): New define.
27959 * bb-reorder.c (pass_reorder_blocks::execute): Do not clean up
27960 partitioning.
27961 * cfgcleanup.c (try_optimize_cfg): Fix up partitioning if
27962 CLEANUP_NO_PARTITIONING is not set.
27963
27964 2018-01-10 Richard Sandiford <richard.sandiford@linaro.org>
27965
27966 * doc/rtl.texi: Remove documentation of (const ...) wrappers
27967 for vectors, as a partial revert of r254296.
27968 * rtl.h (const_vec_p): Delete.
27969 (const_vec_duplicate_p): Don't test for vector CONSTs.
27970 (unwrap_const_vec_duplicate, const_vec_series_p): Likewise.
27971 * expmed.c (make_tree): Likewise.
27972
27973 Revert:
27974 * common.md (E, F): Use CONSTANT_P instead of checking for
27975 CONST_VECTOR.
27976 * emit-rtl.c (gen_lowpart_common): Use const_vec_p instead of
27977 checking for CONST_VECTOR.
27978
27979 2018-01-09 Jan Hubicka <hubicka@ucw.cz>
27980
27981 PR middle-end/83575
27982 * predict.c (force_edge_cold): Handle in more sane way edges
27983 with no prediction.
27984
27985 2018-01-09 Carl Love <cel@us.ibm.com>
27986
27987 * config/rs6002/altivec.md (p8_vmrgow): Add support for V2DI, V2DF,
27988 V4SI, V4SF types.
27989 (p8_vmrgew): Add support for V2DI, V2DF, V4SF types.
27990 * config/rs6000/rs6000-builtin.def: Add definitions for FLOAT2_V2DF,
27991 VMRGEW_V2DI, VMRGEW_V2DF, VMRGEW_V4SF, VMRGOW_V4SI, VMRGOW_V4SF,
27992 VMRGOW_V2DI, VMRGOW_V2DF. Remove definition for VMRGOW.
27993 * config/rs6000/rs6000-c.c (VSX_BUILTIN_VEC_FLOAT2,
27994 P8V_BUILTIN_VEC_VMRGEW, P8V_BUILTIN_VEC_VMRGOW): Add definitions.
27995 * config/rs6000/rs6000-protos.h: Add extern defition for
27996 rs6000_generate_float2_double_code.
27997 * config/rs6000/rs6000.c (rs6000_generate_float2_double_code): Add
27998 function.
27999 * config/rs6000/vsx.md (vsx_xvcdpsp): Add define_insn.
28000 (float2_v2df): Add define_expand.
28001
28002 2018-01-09 Uros Bizjak <ubizjak@gmail.com>
28003
28004 PR target/83628
28005 * combine.c (force_int_to_mode) <case ASHIFT>: Use mode instead of
28006 op_mode in the force_to_mode call.
28007
28008 2018-01-09 Richard Sandiford <richard.sandiford@linaro.org>
28009
28010 * config/aarch64/aarch64.c (aarch64_evpc_trn): Use d.perm.series_p
28011 instead of checking each element individually.
28012 (aarch64_evpc_uzp): Likewise.
28013 (aarch64_evpc_zip): Likewise.
28014 (aarch64_evpc_ext): Likewise.
28015 (aarch64_evpc_rev): Likewise.
28016 (aarch64_evpc_dup): Test the encoding for a single duplicated element,
28017 instead of checking each element individually. Return true without
28018 generating rtl if
28019 (aarch64_vectorize_vec_perm_const): Use all_from_input_p to test
28020 whether all selected elements come from the same input, instead of
28021 checking each element individually. Remove calls to gen_rtx_REG,
28022 start_sequence and end_sequence and instead assert that no rtl is
28023 generated.
28024
28025 2018-01-09 Richard Sandiford <richard.sandiford@linaro.org>
28026
28027 * config/aarch64/aarch64.c (aarch64_legitimate_constant_p): Fix
28028 order of HIGH and CONST checks.
28029
28030 2018-01-09 Richard Sandiford <richard.sandiford@linaro.org>
28031
28032 * tree-vect-stmts.c (permute_vec_elements): Create a fresh variable
28033 if the destination isn't an SSA_NAME.
28034
28035 2018-01-09 Richard Biener <rguenther@suse.de>
28036
28037 PR tree-optimization/83668
28038 * graphite.c (canonicalize_loop_closed_ssa): Add edge argument,
28039 move prologue...
28040 (canonicalize_loop_form): ... here, renamed from ...
28041 (canonicalize_loop_closed_ssa_form): ... this and amended to
28042 swap successor edges for loop exit blocks to make us use
28043 the RPO order we need for initial schedule generation.
28044
28045 2018-01-09 Joseph Myers <joseph@codesourcery.com>
28046
28047 PR tree-optimization/64811
28048 * match.pd: When optimizing comparisons with Inf, avoid
28049 introducing or losing exceptions from comparisons with NaN.
28050
28051 2018-01-09 Martin Liska <mliska@suse.cz>
28052
28053 PR sanitizer/82517
28054 * asan.c (shadow_mem_size): Add gcc_assert.
28055
28056 2018-01-09 Georg-Johann Lay <avr@gjlay.de>
28057
28058 Don't save registers in main().
28059
28060 PR target/83738
28061 * doc/invoke.texi (AVR Options) [-mmain-is-OS_task]: Document it.
28062 * config/avr/avr.opt (-mmain-is-OS_task): New target option.
28063 * config/avr/avr.c (avr_set_current_function): Don't error if
28064 naked, OS_task or OS_main are specified at the same time.
28065 (avr_function_ok_for_sibcall): Don't disable sibcalls for OS_task,
28066 OS_main.
28067 (avr_insert_attributes) [-mmain-is-OS_task] <main>: Add OS_task
28068 attribute.
28069 * common/config/avr/avr-common.c (avr_option_optimization_table):
28070 Switch on -mmain-is-OS_task for optimizing compilations.
28071
28072 2018-01-09 Richard Biener <rguenther@suse.de>
28073
28074 PR tree-optimization/83572
28075 * graphite.c: Include cfganal.h.
28076 (graphite_transform_loops): Connect infinite loops to exit
28077 and remove fake edges at the end.
28078
28079 2018-01-09 Jan Hubicka <hubicka@ucw.cz>
28080
28081 * ipa-inline.c (edge_badness): Revert accidental checkin.
28082
28083 2018-01-09 Jan Hubicka <hubicka@ucw.cz>
28084
28085 PR ipa/80763
28086 * ipa-comdats.c (set_comdat_group): Only set comdat group of real
28087 symbols; not inline clones.
28088
28089 2018-01-09 Jakub Jelinek <jakub@redhat.com>
28090
28091 PR target/83507
28092 * modulo-sched.c (schedule_reg_moves): Punt if we'd need to move
28093 hard registers. Formatting fixes.
28094
28095 PR preprocessor/83722
28096 * gcc.c (try_generate_repro): Pass
28097 &temp_stderr_files[RETRY_ICE_ATTEMPTS - 1] rather than
28098 &temp_stdout_files[RETRY_ICE_ATTEMPTS - 1] as last argument to
28099 do_report_bug.
28100
28101 2018-01-08 Monk Chiang <sh.chiang04@gmail.com>
28102 Kito Cheng <kito.cheng@gmail.com>
28103
28104 * config/riscv/riscv.c (machine_function::is_leaf): Remove field.
28105 (riscv_leaf_function_p): Delete.
28106 (riscv_function_ok_for_sibcall): Return false when TARGET_SAVE_RESTORE.
28107
28108 2018-01-08 Aaron Sawdey <acsawdey@linux.vnet.ibm.com>
28109
28110 * config/rs6000/rs6000-string.c (do_load_for_compare_from_addr): New
28111 function.
28112 (do_ifelse): New function.
28113 (do_isel): New function.
28114 (do_sub3): New function.
28115 (do_add3): New function.
28116 (do_load_mask_compare): New function.
28117 (do_overlap_load_compare): New function.
28118 (expand_compare_loop): New function.
28119 (expand_block_compare): Call expand_compare_loop() when appropriate.
28120 * config/rs6000/rs6000.opt (-mblock-compare-inline-limit): Change
28121 option description.
28122 (-mblock-compare-inline-loop-limit): New option.
28123
28124 2018-01-08 Bill Schmidt <wschmidt@linux.vnet.ibm.com>
28125
28126 PR target/83677
28127 * config/rs6000/altivec.md (*altivec_vpermr_<mode>_internal):
28128 Reverse order of second and third operands in first alternative.
28129 * config/rs6000/rs6000.c (rs6000_expand_vector_set): Reverse order
28130 of first and second elements in UNSPEC_VPERMR vector.
28131 (altivec_expand_vec_perm_le): Likewise.
28132
28133 2018-01-08 Jeff Law <law@redhat.com>
28134
28135 PR rtl-optimizatin/81308
28136 * tree-switch-conversion.c (cfg_altered): New file scoped static.
28137 (process_switch): If group_case_labels makes a change, then set
28138 cfg_altered.
28139 (pass_convert_switch::execute): If a switch is converted, then
28140 set cfg_altered. Return TODO_cfg_cleanup if cfg_altered is true.
28141
28142 PR rtl-optimization/81308
28143 * recog.c (split_all_insns): Conditionally cleanup the CFG after
28144 splitting insns.
28145
28146 2018-01-08 Vidya Praveen <vidyapraveen@arm.com>
28147
28148 PR target/83663 - Revert r255946
28149 * config/aarch64/aarch64.c (aarch64_expand_vector_init): Modify code
28150 generation for cases where splatting a value is not useful.
28151 * simplify-rtx.c (simplify_ternary_operation): Simplify vec_merge
28152 across a vec_duplicate and a paradoxical subreg forming a vector
28153 mode to a vec_concat.
28154
28155 2018-01-08 Kyrylo Tkachov <kyrylo.tkachov@arm.com>
28156
28157 * config/arm/t-aprofile (MULTILIB_MATCHES): Add mapping rules for
28158 -march=armv8.3-a variants.
28159 * config/arm/t-multilib: Likewise.
28160 * config/arm/t-arm-elf: Likewise. Handle dotprod extension.
28161
28162 2018-01-08 Aaron Sawdey <acsawdey@linux.vnet.ibm.com>
28163
28164 * config/rs6000/rs6000.md (cceq_ior_compare): Remove * so I can use it
28165 to generate rtl.
28166 (cceq_ior_compare_complement): Give it a name so I can use it, and
28167 change boolean_or_operator predicate to boolean_operator so it can
28168 be used to generate a crand.
28169 (eqne): New code iterator.
28170 (bd/bd_neg): New code_attrs.
28171 (<bd>_<mode>): New name for ctr<mode>_internal[12] now combined into
28172 a single define_insn.
28173 (<bd>tf_<mode>): A new insn pattern for the conditional form branch
28174 decrement (bdnzt/bdnzf/bdzt/bdzf).
28175 * config/rs6000/rs6000.c (rs6000_legitimate_combined_insn): Updated
28176 with the new names of the branch decrement patterns, and added the
28177 names of the branch decrement conditional patterns.
28178
28179 2018-01-08 Richard Biener <rguenther@suse.de>
28180
28181 PR tree-optimization/83563
28182 * graphite.c (canonicalize_loop_closed_ssa_form): Reset the SCEV
28183 cache.
28184
28185 2018-01-08 Richard Biener <rguenther@suse.de>
28186
28187 PR middle-end/83713
28188 * convert.c (do_narrow): Properly guard TYPE_OVERFLOW_WRAPS checks.
28189
28190 2018-01-08 Richard Biener <rguenther@suse.de>
28191
28192 PR tree-optimization/83685
28193 * tree-ssa-pre.c (create_expression_by_pieces): Do not insert
28194 references to abnormals.
28195
28196 2018-01-08 Richard Biener <rguenther@suse.de>
28197
28198 PR lto/83719
28199 * dwarf2out.c (output_indirect_strings): Handle empty
28200 skeleton_debug_str_hash.
28201 (dwarf2out_early_finish): Index strings for -gsplit-dwarf.
28202
28203 2018-01-08 Claudiu Zissulescu <claziss@synopsys.com>
28204
28205 * config/arc/arc.c (TARGET_TRAMPOLINE_ADJUST_ADDRESS): Delete.
28206 (emit_store_direct): Likewise.
28207 (arc_trampoline_adjust_address): Likewise.
28208 (arc_asm_trampoline_template): New function.
28209 (arc_initialize_trampoline): Use asm_trampoline_template.
28210 (TARGET_ASM_TRAMPOLINE_TEMPLATE): Define.
28211 * config/arc/arc.h (TRAMPOLINE_SIZE): Adjust to 16.
28212 * config/arc/arc.md (flush_icache): Delete pattern.
28213
28214 2018-01-08 Claudiu Zissulescu <claziss@synopsys.com>
28215
28216 * config/arc/arc-c.def (__ARC_UNALIGNED__): New define.
28217 * config/arc/arc.h (STRICT_ALIGNMENT): Control this macro using
28218 munaligned-access.
28219
28220 2018-01-08 Sebastian Huber <sebastian.huber@embedded-brains.de>
28221
28222 PR target/83681
28223 * config/epiphany/epiphany.h (make_pass_mode_switch_use): Guard
28224 by not USED_FOR_TARGET.
28225 (make_pass_resolve_sw_modes): Likewise.
28226
28227 2018-01-08 Sebastian Huber <sebastian.huber@embedded-brains.de>
28228
28229 * config/nios2/nios2.h (nios2_section_threshold): Guard by not
28230 USED_FOR_TARGET.
28231
28232 2018-01-08 Richard Biener <rguenther@suse.de>
28233
28234 PR middle-end/83580
28235 * tree-data-ref.c (split_constant_offset): Remove STRIP_NOPS.
28236
28237 2018-01-08 Richard Biener <rguenther@suse.de>
28238
28239 PR middle-end/83517
28240 * match.pd ((t * 2) / 2) -> t): Add missing :c.
28241
28242 2018-01-06 Aldy Hernandez <aldyh@redhat.com>
28243
28244 PR middle-end/81897
28245 * tree-ssa-uninit.c (compute_control_dep_chain): Do not bail on
28246 basic blocks with a small number of successors.
28247 (convert_control_dep_chain_into_preds): Improve handling of
28248 forwarder blocks.
28249 (dump_predicates): Split apart into...
28250 (dump_pred_chain): ...here...
28251 (dump_pred_info): ...and here.
28252 (can_one_predicate_be_invalidated_p): Add debugging printfs.
28253 (can_chain_union_be_invalidated_p): Improve check for invalidation
28254 of paths.
28255 (uninit_uses_cannot_happen): Avoid unnecessary if
28256 convert_control_dep_chain_into_preds yielded nothing.
28257
28258 2018-01-06 Martin Sebor <msebor@redhat.com>
28259
28260 PR tree-optimization/83640
28261 * gimple-ssa-warn-restrict.c (builtin_access::builtin_access): Avoid
28262 subtracting negative offset from size.
28263 (builtin_access::overlap): Adjust offset bounds of the access to fall
28264 within the size of the object if possible.
28265
28266 2018-01-06 Richard Sandiford <richard.sandiford@linaro.org>
28267
28268 PR rtl-optimization/83699
28269 * expmed.c (extract_bit_field_1): Restrict the vector usage of
28270 extract_bit_field_as_subreg to cases in which the extracted
28271 value is also a vector.
28272
28273 * lra-constraints.c (process_alt_operands): Test for the equivalence
28274 substitutions when detecting a possible reload cycle.
28275
28276 2018-01-06 Jakub Jelinek <jakub@redhat.com>
28277
28278 PR debug/83480
28279 * toplev.c (process_options): Don't enable debug_nonbind_markers_p
28280 by default if flag_selective_schedling{,2}. Formatting fixes.
28281
28282 PR rtl-optimization/83682
28283 * rtl.h (const_vec_duplicate_p): Only return true for VEC_DUPLICATE
28284 if it has non-VECTOR_MODE element mode.
28285 (vec_duplicate_p): Likewise.
28286
28287 PR middle-end/83694
28288 * cfgexpand.c (expand_debug_expr): Punt if mode1 is VOIDmode
28289 and bitsize might be greater than MAX_BITSIZE_MODE_ANY_INT.
28290
28291 2018-01-05 Jakub Jelinek <jakub@redhat.com>
28292
28293 PR target/83604
28294 * config/i386/i386-builtin.def
28295 (__builtin_ia32_vgf2p8affineinvqb_v64qi,
28296 __builtin_ia32_vgf2p8affineqb_v64qi, __builtin_ia32_vgf2p8mulb_v64qi):
28297 Require also OPTION_MASK_ISA_AVX512F in addition to
28298 OPTION_MASK_ISA_GFNI.
28299 (__builtin_ia32_vgf2p8affineinvqb_v16qi_mask,
28300 __builtin_ia32_vgf2p8affineqb_v16qi_mask): Require
28301 OPTION_MASK_ISA_AVX512VL instead of OPTION_MASK_ISA_SSE in addition
28302 to OPTION_MASK_ISA_GFNI.
28303 (__builtin_ia32_vgf2p8mulb_v32qi_mask): Require
28304 OPTION_MASK_ISA_AVX512VL in addition to OPTION_MASK_ISA_GFNI and
28305 OPTION_MASK_ISA_AVX512BW.
28306 (__builtin_ia32_vgf2p8mulb_v16qi_mask): Require
28307 OPTION_MASK_ISA_AVX512VL instead of OPTION_MASK_ISA_AVX512BW in
28308 addition to OPTION_MASK_ISA_GFNI.
28309 (__builtin_ia32_vgf2p8affineinvqb_v16qi,
28310 __builtin_ia32_vgf2p8affineqb_v16qi, __builtin_ia32_vgf2p8mulb_v16qi):
28311 Require OPTION_MASK_ISA_SSE2 instead of OPTION_MASK_ISA_SSE in addition
28312 to OPTION_MASK_ISA_GFNI.
28313 * config/i386/i386.c (def_builtin): Change to builtin isa/isa2 being
28314 a requirement for all ISAs rather than any of them with a few
28315 exceptions.
28316 (ix86_add_new_builtins): Clear OPTION_MASK_ISA_64BIT from isa before
28317 processing.
28318 (ix86_expand_builtin): Require all ISAs from builtin's isa and isa2
28319 bitmasks to be enabled with 3 exceptions, instead of requiring any
28320 enabled ISA with lots of exceptions.
28321 * config/i386/sse.md (vgf2p8affineinvqb_<mode><mask_name>,
28322 vgf2p8affineqb_<mode><mask_name>, vgf2p8mulb_<mode><mask_name>):
28323 Change avx512bw in isa attribute to avx512f.
28324 * config/i386/sgxintrin.h: Add license boilerplate.
28325 * config/i386/vaesintrin.h: Likewise. Fix macro spelling __AVX512F
28326 to __AVX512F__ and __AVX512VL to __AVX512VL__.
28327 (_mm256_aesdec_epi128, _mm256_aesdeclast_epi128, _mm256_aesenc_epi128,
28328 _mm256_aesenclast_epi128): Enable temporarily avx if __AVX__ is not
28329 defined.
28330 * config/i386/gfniintrin.h (_mm_gf2p8mul_epi8,
28331 _mm_gf2p8affineinv_epi64_epi8, _mm_gf2p8affine_epi64_epi8): Enable
28332 temporarily sse2 rather than sse if not enabled already.
28333
28334 PR target/83604
28335 * config/i386/sse.md (VI248_VLBW): Rename to ...
28336 (VI248_AVX512VL): ... this. Don't guard V32HI with TARGET_AVX512BW.
28337 (vpshrd_<mode><mask_name>, vpshld_<mode><mask_name>,
28338 vpshrdv_<mode>, vpshrdv_<mode>_mask, vpshrdv_<mode>_maskz,
28339 vpshrdv_<mode>_maskz_1, vpshldv_<mode>, vpshldv_<mode>_mask,
28340 vpshldv_<mode>_maskz, vpshldv_<mode>_maskz_1): Use VI248_AVX512VL
28341 mode iterator instead of VI248_VLBW.
28342
28343 2018-01-05 Jan Hubicka <hubicka@ucw.cz>
28344
28345 * ipa-fnsummary.c (record_modified_bb_info): Add OP.
28346 (record_modified): Skip clobbers; add debug output.
28347 (param_change_prob): Use sreal frequencies.
28348
28349 2018-01-05 Richard Sandiford <richard.sandiford@linaro.org>
28350
28351 * tree-vect-data-refs.c (vect_compute_data_ref_alignment): Don't
28352 punt for user-aligned variables.
28353
28354 2018-01-05 Richard Sandiford <richard.sandiford@linaro.org>
28355
28356 * tree-chrec.c (chrec_contains_symbols): Return true for
28357 POLY_INT_CST.
28358
28359 2018-01-05 Sudakshina Das <sudi.das@arm.com>
28360
28361 PR target/82439
28362 * simplify-rtx.c (simplify_relational_operation_1): Add simplifications
28363 of (x|y) == x for BICS pattern.
28364
28365 2018-01-05 Jakub Jelinek <jakub@redhat.com>
28366
28367 PR tree-optimization/83605
28368 * gimple-ssa-strength-reduction.c: Include tree-eh.h.
28369 (find_candidates_dom_walker::before_dom_children): Ignore stmts that
28370 can throw.
28371
28372 2018-01-05 Sebastian Huber <sebastian.huber@embedded-brains.de>
28373
28374 * config.gcc (epiphany-*-elf*): Add (epiphany-*-rtems*) configuration.
28375 * config/epiphany/rtems.h: New file.
28376
28377 2018-01-04 Jakub Jelinek <jakub@redhat.com>
28378 Uros Bizjak <ubizjak@gmail.com>
28379
28380 PR target/83554
28381 * config/i386/i386.md (*<rotate_insn>hi3_1 splitter): Use
28382 QIreg_operand instead of register_operand predicate.
28383 * config/i386/i386.c (ix86_rop_should_change_byte_p,
28384 set_rop_modrm_reg_bits, ix86_mitigate_rop): Use -mmitigate-rop in
28385 comments instead of -fmitigate[-_]rop.
28386
28387 2018-01-04 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
28388
28389 PR bootstrap/81926
28390 * cgraphunit.c (symbol_table::compile): Switch to text_section
28391 before calling assembly_start debug hook.
28392 * run-rtl-passes.c (run_rtl_passes): Likewise.
28393 Include output.h.
28394
28395 2018-01-04 Richard Sandiford <richard.sandiford@linaro.org>
28396
28397 * tree-vrp.c (extract_range_from_binary_expr_1): Check
28398 range_int_cst_p rather than !symbolic_range_p before calling
28399 extract_range_from_multiplicative_op_1.
28400
28401 2018-01-04 Jeff Law <law@redhat.com>
28402
28403 * tree-ssa-math-opts.c (execute_cse_reciprocals_1): Remove
28404 redundant test in assertion.
28405
28406 2018-01-04 Richard Sandiford <richard.sandiford@linaro.org>
28407
28408 * doc/rtl.texi: Document machine_mode wrapper classes.
28409
28410 2018-01-04 Richard Sandiford <richard.sandiford@linaro.org>
28411
28412 * fold-const.c (fold_ternary_loc): Check tree_fits_uhwi_p before
28413 using tree_to_uhwi.
28414
28415 2018-01-04 Richard Sandiford <richard.sandiford@linaro.org>
28416
28417 * tree-ssa-forwprop.c (is_combined_permutation_identity): Allow
28418 the VEC_PERM_EXPR fold to fail.
28419
28420 2018-01-04 Jakub Jelinek <jakub@redhat.com>
28421
28422 PR debug/83585
28423 * bb-reorder.c (insert_section_boundary_note): Set has_bb_partition
28424 to switched_sections.
28425
28426 2018-01-04 Richard Sandiford <richard.sandiford@linaro.org>
28427
28428 PR target/83680
28429 * config/arm/arm.c (arm_vectorize_vec_perm_const): Fix inverted
28430 test for d.testing.
28431
28432 2018-01-04 Peter Bergner <bergner@vnet.ibm.com>
28433
28434 PR target/83387
28435 * config/rs6000/rs6000.c (rs6000_discover_homogeneous_aggregate): Do not
28436 allow arguments in FP registers if TARGET_HARD_FLOAT is false.
28437
28438 2018-01-04 Jakub Jelinek <jakub@redhat.com>
28439
28440 PR debug/83666
28441 * cfgexpand.c (expand_debug_expr) <case BIT_FIELD_REF>: Punt if mode
28442 is BLKmode and bitpos not zero or mode change is needed.
28443
28444 2018-01-04 Richard Sandiford <richard.sandiford@linaro.org>
28445
28446 PR target/83675
28447 * config/sparc/sparc.c (sparc_vectorize_vec_perm_const): Require
28448 TARGET_VIS2.
28449
28450 2018-01-04 Uros Bizjak <ubizjak@gmail.com>
28451
28452 PR target/83628
28453 * config/alpha/alpha.md (*sadd<modesuffix>): Use ASHIFT
28454 instead of MULT rtx. Update all corresponding splitters.
28455 (*saddl_se): Ditto.
28456 (*ssub<modesuffix>): Ditto.
28457 (*ssubl_se): Ditto.
28458 (*cmp_sadd_di): Update split patterns.
28459 (*cmp_sadd_si): Ditto.
28460 (*cmp_sadd_sidi): Ditto.
28461 (*cmp_ssub_di): Ditto.
28462 (*cmp_ssub_si): Ditto.
28463 (*cmp_ssub_sidi): Ditto.
28464 * config/alpha/predicates.md (const23_operand): New predicate.
28465 * config/alpha/alpha.c (alpha_rtx_costs) [PLUS, MINUS]:
28466 Look for ASHIFT, not MULT inner operand.
28467 (alpha_split_conditional_move): Update for *sadd<modesuffix> change.
28468
28469 2018-01-04 Martin Liska <mliska@suse.cz>
28470
28471 PR gcov-profile/83669
28472 * gcov.c (output_intermediate_file): Add version to intermediate
28473 gcov file.
28474 * doc/gcov.texi: Document new field 'version' in intermediate
28475 file format. Fix location of '-k' option of gcov command.
28476
28477 2018-01-04 Martin Liska <mliska@suse.cz>
28478
28479 PR ipa/82352
28480 * ipa-icf.c (sem_function::merge): Do not cross comdat boundary.
28481
28482 2018-01-04 Jakub Jelinek <jakub@redhat.com>
28483
28484 * gimple-ssa-sprintf.c (parse_directive): Cast second dir.len to uhwi.
28485
28486 2018-01-03 Martin Sebor <msebor@redhat.com>
28487
28488 PR tree-optimization/83655
28489 * gimple-ssa-warn-restrict.c (wrestrict_dom_walker::check_call): Avoid
28490 checking calls with invalid arguments.
28491
28492 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
28493
28494 * tree-vect-stmts.c (vect_get_store_rhs): New function.
28495 (vectorizable_mask_load_store): Delete.
28496 (vectorizable_call): Return false for masked loads and stores.
28497 (vectorizable_store): Handle IFN_MASK_STORE. Use vect_get_store_rhs
28498 instead of gimple_assign_rhs1.
28499 (vectorizable_load): Handle IFN_MASK_LOAD.
28500 (vect_transform_stmt): Don't set is_store for call_vec_info_type.
28501
28502 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
28503
28504 * tree-vect-stmts.c (vect_build_gather_load_calls): New function,
28505 split out from..,
28506 (vectorizable_mask_load_store): ...here.
28507 (vectorizable_load): ...and here.
28508
28509 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
28510
28511 * tree-vect-stmts.c (vect_build_all_ones_mask)
28512 (vect_build_zero_merge_argument): New functions, split out from...
28513 (vectorizable_load): ...here.
28514
28515 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
28516
28517 * tree-vect-stmts.c (vect_check_store_rhs): New function,
28518 split out from...
28519 (vectorizable_mask_load_store): ...here.
28520 (vectorizable_store): ...and here.
28521
28522 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
28523
28524 * tree-vect-stmts.c (vect_check_load_store_mask): New function,
28525 split out from...
28526 (vectorizable_mask_load_store): ...here.
28527
28528 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
28529
28530 * tree-vectorizer.h (vec_load_store_type): Moved from tree-vec-stmts.c
28531 (vect_model_store_cost): Take a vec_load_store_type instead of a
28532 vect_def_type.
28533 * tree-vect-stmts.c (vec_load_store_type): Move to tree-vectorizer.h.
28534 (vect_model_store_cost): Take a vec_load_store_type instead of a
28535 vect_def_type.
28536 (vectorizable_mask_load_store): Update accordingly.
28537 (vectorizable_store): Likewise.
28538 * tree-vect-slp.c (vect_analyze_slp_cost_1): Update accordingly.
28539
28540 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
28541
28542 * tree-vect-loop.c (vect_transform_loop): Stub out scalar
28543 IFN_MASK_LOAD calls here rather than...
28544 * tree-vect-stmts.c (vectorizable_mask_load_store): ...here.
28545
28546 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
28547 Alan Hayward <alan.hayward@arm.com>
28548 David Sherwood <david.sherwood@arm.com>
28549
28550 * expmed.c (extract_bit_field_1): For vector extracts,
28551 fall back to extract_bit_field_as_subreg if vec_extract
28552 isn't available.
28553
28554 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
28555 Alan Hayward <alan.hayward@arm.com>
28556 David Sherwood <david.sherwood@arm.com>
28557
28558 * lra-spills.c (pseudo_reg_slot_compare): Sort slots by whether
28559 they are variable or constant sized.
28560 (assign_stack_slot_num_and_sort_pseudos): Don't reuse variable-sized
28561 slots for constant-sized data.
28562
28563 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
28564 Alan Hayward <alan.hayward@arm.com>
28565 David Sherwood <david.sherwood@arm.com>
28566
28567 * tree-vect-patterns.c (vect_recog_mask_conversion_pattern): When
28568 handling COND_EXPRs with boolean comparisons, try to find a better
28569 basis for the mask type than the boolean itself.
28570
28571 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
28572
28573 * doc/rtl.texi (MAX_BITSIZE_MODE_ANY_MODE): Describe how the default
28574 is calculated and how it can be overridden.
28575 * genmodes.c (max_bitsize_mode_any_mode): New variable.
28576 (create_modes): Initialize it from MAX_BITSIZE_MODE_ANY_MODE,
28577 if defined.
28578 (emit_max_int): Use it to set the output MAX_BITSIZE_MODE_ANY_MODE,
28579 if nonzero.
28580
28581 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
28582 Alan Hayward <alan.hayward@arm.com>
28583 David Sherwood <david.sherwood@arm.com>
28584
28585 * config/aarch64/aarch64-protos.h (aarch64_output_simd_mov_immediate):
28586 Remove the mode argument.
28587 (aarch64_simd_valid_immediate): Remove the mode and inverse
28588 arguments.
28589 * config/aarch64/iterators.md (bitsize): New iterator.
28590 * config/aarch64/aarch64-simd.md (*aarch64_simd_mov<mode>, and<mode>3)
28591 (ior<mode>3): Update calls to aarch64_output_simd_mov_immediate.
28592 * config/aarch64/constraints.md (Do, Db, Dn): Update calls to
28593 aarch64_simd_valid_immediate.
28594 * config/aarch64/predicates.md (aarch64_reg_or_orr_imm): Likewise.
28595 (aarch64_reg_or_bic_imm): Likewise.
28596 * config/aarch64/aarch64.c (simd_immediate_info): Replace mvn
28597 with an insn_type enum and msl with a modifier_type enum.
28598 Replace element_width with a scalar_mode. Change the shift
28599 to unsigned int. Add constructors for scalar_float_mode and
28600 scalar_int_mode elements.
28601 (aarch64_vect_float_const_representable_p): Delete.
28602 (aarch64_can_const_movi_rtx_p)
28603 (aarch64_simd_scalar_immediate_valid_for_move)
28604 (aarch64_simd_make_constant): Update call to
28605 aarch64_simd_valid_immediate.
28606 (aarch64_advsimd_valid_immediate_hs): New function.
28607 (aarch64_advsimd_valid_immediate): Likewise.
28608 (aarch64_simd_valid_immediate): Remove mode and inverse
28609 arguments. Rewrite to use the above. Use const_vec_duplicate_p
28610 to detect duplicated constants and use aarch64_float_const_zero_rtx_p
28611 and aarch64_float_const_representable_p on the result.
28612 (aarch64_output_simd_mov_immediate): Remove mode argument.
28613 Update call to aarch64_simd_valid_immediate and use of
28614 simd_immediate_info.
28615 (aarch64_output_scalar_simd_mov_immediate): Update call
28616 accordingly.
28617
28618 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
28619 Alan Hayward <alan.hayward@arm.com>
28620 David Sherwood <david.sherwood@arm.com>
28621
28622 * machmode.h (mode_precision): Prefix with CONST_MODE_PRECISION.
28623 (mode_nunits): Likewise CONST_MODE_NUNITS.
28624 * machmode.def (ADJUST_NUNITS): Document.
28625 * genmodes.c (mode_data::need_nunits_adj): New field.
28626 (blank_mode): Update accordingly.
28627 (adj_nunits): New variable.
28628 (print_maybe_const_decl): Replace CATEGORY with a NEEDS_ADJ
28629 parameter.
28630 (emit_mode_size_inline): Set need_bytesize_adj for all modes
28631 listed in adj_nunits.
28632 (emit_mode_nunits_inline): Set need_nunits_adj for all modes
28633 listed in adj_nunits. Don't emit case statements for such modes.
28634 (emit_insn_modes_h): Emit definitions of CONST_MODE_NUNITS
28635 and CONST_MODE_PRECISION. Make CONST_MODE_SIZE expand to
28636 nothing if adj_nunits is nonnull.
28637 (emit_mode_precision, emit_mode_nunits): Use print_maybe_const_decl.
28638 (emit_mode_unit_size, emit_mode_base_align, emit_mode_ibit)
28639 (emit_mode_fbit): Update use of print_maybe_const_decl.
28640 (emit_move_size): Likewise. Treat the array as non-const
28641 if adj_nunits.
28642 (emit_mode_adjustments): Handle adj_nunits.
28643
28644 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
28645
28646 * machmode.def (VECTOR_MODES_WITH_PREFIX): Document.
28647 * genmodes.c (VECTOR_MODES_WITH_PREFIX): New macro.
28648 (VECTOR_MODES): Use it.
28649 (make_vector_modes): Take the prefix as an argument.
28650
28651 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
28652 Alan Hayward <alan.hayward@arm.com>
28653 David Sherwood <david.sherwood@arm.com>
28654
28655 * mode-classes.def (MODE_VECTOR_BOOL): New mode class.
28656 * machmode.h (INTEGRAL_MODE_P, VECTOR_MODE_P): Return true
28657 for MODE_VECTOR_BOOL.
28658 * machmode.def (VECTOR_BOOL_MODE): Document.
28659 * genmodes.c (VECTOR_BOOL_MODE): New macro.
28660 (make_vector_bool_mode): New function.
28661 (complete_mode, emit_mode_wider, emit_mode_adjustments): Handle
28662 MODE_VECTOR_BOOL.
28663 * lto-streamer-in.c (lto_input_mode_table): Likewise.
28664 * rtx-vector-builder.c (rtx_vector_builder::find_cached_value):
28665 Likewise.
28666 * stor-layout.c (int_mode_for_mode): Likewise.
28667 * tree.c (build_vector_type_for_mode): Likewise.
28668 * varasm.c (output_constant_pool_2): Likewise.
28669 * emit-rtl.c (init_emit_once): Make sure that CONST1_RTX (BImode) and
28670 CONSTM1_RTX (BImode) are the same thing. Initialize const_tiny_rtx
28671 for MODE_VECTOR_BOOL.
28672 * expr.c (expand_expr_real_1): Use VECTOR_MODE_P instead of a list
28673 of mode class checks.
28674 * tree-vect-generic.c (expand_vector_operation): Use VECTOR_MODE_P
28675 instead of a list of mode class checks.
28676 (expand_vector_scalar_condition): Likewise.
28677 (type_for_widest_vector_mode): Handle BImode as an inner mode.
28678
28679 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
28680 Alan Hayward <alan.hayward@arm.com>
28681 David Sherwood <david.sherwood@arm.com>
28682
28683 * machmode.h (mode_size): Change from unsigned short to
28684 poly_uint16_pod.
28685 (mode_to_bytes): Return a poly_uint16 rather than an unsigned short.
28686 (GET_MODE_SIZE): Return a constant if ONLY_FIXED_SIZE_MODES,
28687 or if measurement_type is not polynomial.
28688 (fixed_size_mode::includes_p): Check for constant-sized modes.
28689 * genmodes.c (emit_mode_size_inline): Make mode_size_inline
28690 return a poly_uint16 rather than an unsigned short.
28691 (emit_mode_size): Change the type of mode_size from unsigned short
28692 to poly_uint16_pod. Use ZERO_COEFFS for the initializer.
28693 (emit_mode_adjustments): Cope with polynomial vector sizes.
28694 * lto-streamer-in.c (lto_input_mode_table): Use bp_unpack_poly_value
28695 for GET_MODE_SIZE.
28696 * lto-streamer-out.c (lto_write_mode_table): Use bp_pack_poly_value
28697 for GET_MODE_SIZE.
28698 * auto-inc-dec.c (try_merge): Treat GET_MODE_SIZE as polynomial.
28699 * builtins.c (expand_ifn_atomic_compare_exchange_into_call): Likewise.
28700 * caller-save.c (setup_save_areas): Likewise.
28701 (replace_reg_with_saved_mem): Likewise.
28702 * calls.c (emit_library_call_value_1): Likewise.
28703 * combine-stack-adj.c (combine_stack_adjustments_for_block): Likewise.
28704 * combine.c (simplify_set, make_extraction, simplify_shift_const_1)
28705 (gen_lowpart_for_combine): Likewise.
28706 * convert.c (convert_to_integer_1): Likewise.
28707 * cse.c (equiv_constant, cse_insn): Likewise.
28708 * cselib.c (autoinc_split, cselib_hash_rtx): Likewise.
28709 (cselib_subst_to_values): Likewise.
28710 * dce.c (word_dce_process_block): Likewise.
28711 * df-problems.c (df_word_lr_mark_ref): Likewise.
28712 * dwarf2cfi.c (init_one_dwarf_reg_size): Likewise.
28713 * dwarf2out.c (multiple_reg_loc_descriptor, mem_loc_descriptor)
28714 (concat_loc_descriptor, concatn_loc_descriptor, loc_descriptor)
28715 (rtl_for_decl_location): Likewise.
28716 * emit-rtl.c (gen_highpart, widen_memory_access): Likewise.
28717 * expmed.c (extract_bit_field_1, extract_integral_bit_field): Likewise.
28718 * expr.c (emit_group_load_1, clear_storage_hints): Likewise.
28719 (emit_move_complex, emit_move_multi_word, emit_push_insn): Likewise.
28720 (expand_expr_real_1): Likewise.
28721 * function.c (assign_parm_setup_block_p, assign_parm_setup_block)
28722 (pad_below): Likewise.
28723 * gimple-fold.c (optimize_atomic_compare_exchange_p): Likewise.
28724 * gimple-ssa-store-merging.c (rhs_valid_for_store_merging_p): Likewise.
28725 * ira.c (get_subreg_tracking_sizes): Likewise.
28726 * ira-build.c (ira_create_allocno_objects): Likewise.
28727 * ira-color.c (coalesced_pseudo_reg_slot_compare): Likewise.
28728 (ira_sort_regnos_for_alter_reg): Likewise.
28729 * ira-costs.c (record_operand_costs): Likewise.
28730 * lower-subreg.c (interesting_mode_p, simplify_gen_subreg_concatn)
28731 (resolve_simple_move): Likewise.
28732 * lra-constraints.c (get_reload_reg, operands_match_p): Likewise.
28733 (process_addr_reg, simplify_operand_subreg, curr_insn_transform)
28734 (lra_constraints): Likewise.
28735 (CONST_POOL_OK_P): Reject variable-sized modes.
28736 * lra-spills.c (slot, assign_mem_slot, pseudo_reg_slot_compare)
28737 (add_pseudo_to_slot, lra_spill): Likewise.
28738 * omp-low.c (omp_clause_aligned_alignment): Likewise.
28739 * optabs-query.c (get_best_extraction_insn): Likewise.
28740 * optabs-tree.c (expand_vec_cond_expr_p): Likewise.
28741 * optabs.c (expand_vec_perm_var, expand_vec_cond_expr): Likewise.
28742 (expand_mult_highpart, valid_multiword_target_p): Likewise.
28743 * recog.c (offsettable_address_addr_space_p): Likewise.
28744 * regcprop.c (maybe_mode_change): Likewise.
28745 * reginfo.c (choose_hard_reg_mode, record_subregs_of_mode): Likewise.
28746 * regrename.c (build_def_use): Likewise.
28747 * regstat.c (dump_reg_info): Likewise.
28748 * reload.c (complex_word_subreg_p, push_reload, find_dummy_reload)
28749 (find_reloads, find_reloads_subreg_address): Likewise.
28750 * reload1.c (eliminate_regs_1): Likewise.
28751 * rtlanal.c (for_each_inc_dec_find_inc_dec, rtx_cost): Likewise.
28752 * simplify-rtx.c (avoid_constant_pool_reference): Likewise.
28753 (simplify_binary_operation_1, simplify_subreg): Likewise.
28754 * targhooks.c (default_function_arg_padding): Likewise.
28755 (default_hard_regno_nregs, default_class_max_nregs): Likewise.
28756 * tree-cfg.c (verify_gimple_assign_binary): Likewise.
28757 (verify_gimple_assign_ternary): Likewise.
28758 * tree-inline.c (estimate_move_cost): Likewise.
28759 * tree-ssa-forwprop.c (simplify_vector_constructor): Likewise.
28760 * tree-ssa-loop-ivopts.c (add_autoinc_candidates): Likewise.
28761 (get_address_cost_ainc): Likewise.
28762 * tree-vect-data-refs.c (vect_enhance_data_refs_alignment): Likewise.
28763 (vect_supportable_dr_alignment): Likewise.
28764 * tree-vect-loop.c (vect_determine_vectorization_factor): Likewise.
28765 (vectorizable_reduction): Likewise.
28766 * tree-vect-stmts.c (vectorizable_assignment, vectorizable_shift)
28767 (vectorizable_operation, vectorizable_load): Likewise.
28768 * tree.c (build_same_sized_truth_vector_type): Likewise.
28769 * valtrack.c (cleanup_auto_inc_dec): Likewise.
28770 * var-tracking.c (emit_note_insn_var_location): Likewise.
28771 * config/arc/arc.h (ASM_OUTPUT_CASE_END): Use as_a <scalar_int_mode>.
28772 (ADDR_VEC_ALIGN): Likewise.
28773
28774 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
28775 Alan Hayward <alan.hayward@arm.com>
28776 David Sherwood <david.sherwood@arm.com>
28777
28778 * machmode.h (mode_to_bits): Return a poly_uint16 rather than an
28779 unsigned short.
28780 (GET_MODE_BITSIZE): Return a constant if ONLY_FIXED_SIZE_MODES,
28781 or if measurement_type is polynomial.
28782 * calls.c (shift_return_value): Treat GET_MODE_BITSIZE as polynomial.
28783 * combine.c (make_extraction): Likewise.
28784 * dse.c (find_shift_sequence): Likewise.
28785 * dwarf2out.c (mem_loc_descriptor): Likewise.
28786 * expmed.c (store_integral_bit_field, extract_bit_field_1): Likewise.
28787 (extract_bit_field, extract_low_bits): Likewise.
28788 * expr.c (convert_move, convert_modes, emit_move_insn_1): Likewise.
28789 (optimize_bitfield_assignment_op, expand_assignment): Likewise.
28790 (store_expr_with_bounds, store_field, expand_expr_real_1): Likewise.
28791 * fold-const.c (optimize_bit_field_compare, merge_ranges): Likewise.
28792 * gimple-fold.c (optimize_atomic_compare_exchange_p): Likewise.
28793 * reload.c (find_reloads): Likewise.
28794 * reload1.c (alter_reg): Likewise.
28795 * stor-layout.c (bitwise_mode_for_mode, compute_record_mode): Likewise.
28796 * targhooks.c (default_secondary_memory_needed_mode): Likewise.
28797 * tree-if-conv.c (predicate_mem_writes): Likewise.
28798 * tree-ssa-strlen.c (handle_builtin_memcmp): Likewise.
28799 * tree-vect-patterns.c (adjust_bool_pattern): Likewise.
28800 * tree-vect-stmts.c (vectorizable_simd_clone_call): Likewise.
28801 * valtrack.c (dead_debug_insert_temp): Likewise.
28802 * varasm.c (mergeable_constant_section): Likewise.
28803 * config/sh/sh.h (LOCAL_ALIGNMENT): Use as_a <fixed_size_mode>.
28804
28805 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
28806 Alan Hayward <alan.hayward@arm.com>
28807 David Sherwood <david.sherwood@arm.com>
28808
28809 * expr.c (expand_assignment): Cope with polynomial mode sizes
28810 when assigning to a CONCAT.
28811
28812 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
28813 Alan Hayward <alan.hayward@arm.com>
28814 David Sherwood <david.sherwood@arm.com>
28815
28816 * machmode.h (mode_precision): Change from unsigned short to
28817 poly_uint16_pod.
28818 (mode_to_precision): Return a poly_uint16 rather than an unsigned
28819 short.
28820 (GET_MODE_PRECISION): Return a constant if ONLY_FIXED_SIZE_MODES,
28821 or if measurement_type is not polynomial.
28822 (HWI_COMPUTABLE_MODE_P): Turn into a function. Optimize the case
28823 in which the mode is already known to be a scalar_int_mode.
28824 * genmodes.c (emit_mode_precision): Change the type of mode_precision
28825 from unsigned short to poly_uint16_pod. Use ZERO_COEFFS for the
28826 initializer.
28827 * lto-streamer-in.c (lto_input_mode_table): Use bp_unpack_poly_value
28828 for GET_MODE_PRECISION.
28829 * lto-streamer-out.c (lto_write_mode_table): Use bp_pack_poly_value
28830 for GET_MODE_PRECISION.
28831 * combine.c (update_rsp_from_reg_equal): Treat GET_MODE_PRECISION
28832 as polynomial.
28833 (try_combine, find_split_point, combine_simplify_rtx): Likewise.
28834 (expand_field_assignment, make_extraction): Likewise.
28835 (make_compound_operation_int, record_dead_and_set_regs_1): Likewise.
28836 (get_last_value): Likewise.
28837 * convert.c (convert_to_integer_1): Likewise.
28838 * cse.c (cse_insn): Likewise.
28839 * expr.c (expand_expr_real_1): Likewise.
28840 * lra-constraints.c (simplify_operand_subreg): Likewise.
28841 * optabs-query.c (can_atomic_load_p): Likewise.
28842 * optabs.c (expand_atomic_load): Likewise.
28843 (expand_atomic_store): Likewise.
28844 * ree.c (combine_reaching_defs): Likewise.
28845 * rtl.h (partial_subreg_p, paradoxical_subreg_p): Likewise.
28846 * rtlanal.c (nonzero_bits1, lsb_bitfield_op_p): Likewise.
28847 * tree.h (type_has_mode_precision_p): Likewise.
28848 * ubsan.c (instrument_si_overflow): Likewise.
28849
28850 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
28851 Alan Hayward <alan.hayward@arm.com>
28852 David Sherwood <david.sherwood@arm.com>
28853
28854 * tree.h (TYPE_VECTOR_SUBPARTS): Turn into a function and handle
28855 polynomial numbers of units.
28856 (SET_TYPE_VECTOR_SUBPARTS): Likewise.
28857 (valid_vector_subparts_p): New function.
28858 (build_vector_type): Remove temporary shim and take the number
28859 of units as a poly_uint64 rather than an int.
28860 (build_opaque_vector_type): Take the number of units as a
28861 poly_uint64 rather than an int.
28862 * tree.c (build_vector_from_ctor): Handle polynomial
28863 TYPE_VECTOR_SUBPARTS.
28864 (type_hash_canon_hash, type_cache_hasher::equal): Likewise.
28865 (uniform_vector_p, vector_type_mode, build_vector): Likewise.
28866 (build_vector_from_val): If the number of units is variable,
28867 use build_vec_duplicate_cst for constant operands and
28868 VEC_DUPLICATE_EXPR otherwise.
28869 (make_vector_type): Remove temporary is_constant ().
28870 (build_vector_type, build_opaque_vector_type): Take the number of
28871 units as a poly_uint64 rather than an int.
28872 (check_vector_cst): Handle polynomial TYPE_VECTOR_SUBPARTS and
28873 VECTOR_CST_NELTS.
28874 * cfgexpand.c (expand_debug_expr): Likewise.
28875 * expr.c (count_type_elements, categorize_ctor_elements_1): Likewise.
28876 (store_constructor, expand_expr_real_1): Likewise.
28877 (const_scalar_mask_from_tree): Likewise.
28878 * fold-const-call.c (fold_const_reduction): Likewise.
28879 * fold-const.c (const_binop, const_unop, fold_convert_const): Likewise.
28880 (operand_equal_p, fold_vec_perm, fold_ternary_loc): Likewise.
28881 (native_encode_vector, vec_cst_ctor_to_array): Likewise.
28882 (fold_relational_const): Likewise.
28883 (native_interpret_vector): Likewise. Change the size from an
28884 int to an unsigned int.
28885 * gimple-fold.c (gimple_fold_stmt_to_constant_1): Handle polynomial
28886 TYPE_VECTOR_SUBPARTS.
28887 (gimple_fold_indirect_ref, gimple_build_vector): Likewise.
28888 (gimple_build_vector_from_val): Use VEC_DUPLICATE_EXPR when
28889 duplicating a non-constant operand into a variable-length vector.
28890 * hsa-brig.c (hsa_op_immed::emit_to_buffer): Handle polynomial
28891 TYPE_VECTOR_SUBPARTS and VECTOR_CST_NELTS.
28892 * ipa-icf.c (sem_variable::equals): Likewise.
28893 * match.pd: Likewise.
28894 * omp-simd-clone.c (simd_clone_subparts): Likewise.
28895 * print-tree.c (print_node): Likewise.
28896 * stor-layout.c (layout_type): Likewise.
28897 * targhooks.c (default_builtin_vectorization_cost): Likewise.
28898 * tree-cfg.c (verify_gimple_comparison): Likewise.
28899 (verify_gimple_assign_binary): Likewise.
28900 (verify_gimple_assign_ternary): Likewise.
28901 (verify_gimple_assign_single): Likewise.
28902 * tree-pretty-print.c (dump_generic_node): Likewise.
28903 * tree-ssa-forwprop.c (simplify_vector_constructor): Likewise.
28904 (simplify_bitfield_ref, is_combined_permutation_identity): Likewise.
28905 * tree-vect-data-refs.c (vect_permute_store_chain): Likewise.
28906 (vect_grouped_load_supported, vect_permute_load_chain): Likewise.
28907 (vect_shift_permute_load_chain): Likewise.
28908 * tree-vect-generic.c (nunits_for_known_piecewise_op): Likewise.
28909 (expand_vector_condition, optimize_vector_constructor): Likewise.
28910 (lower_vec_perm, get_compute_type): Likewise.
28911 * tree-vect-loop.c (vect_determine_vectorization_factor): Likewise.
28912 (get_initial_defs_for_reduction, vect_transform_loop): Likewise.
28913 * tree-vect-patterns.c (vect_recog_bool_pattern): Likewise.
28914 (vect_recog_mask_conversion_pattern): Likewise.
28915 * tree-vect-slp.c (vect_supported_load_permutation_p): Likewise.
28916 (vect_get_constant_vectors, vect_transform_slp_perm_load): Likewise.
28917 * tree-vect-stmts.c (perm_mask_for_reverse): Likewise.
28918 (get_group_load_store_type, vectorizable_mask_load_store): Likewise.
28919 (vectorizable_bswap, simd_clone_subparts, vectorizable_assignment)
28920 (vectorizable_shift, vectorizable_operation, vectorizable_store)
28921 (vectorizable_load, vect_is_simple_cond, vectorizable_comparison)
28922 (supportable_widening_operation): Likewise.
28923 (supportable_narrowing_operation): Likewise.
28924 * tree-vector-builder.c (tree_vector_builder::binary_encoded_nelts):
28925 Likewise.
28926 * varasm.c (output_constant): Likewise.
28927
28928 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
28929 Alan Hayward <alan.hayward@arm.com>
28930 David Sherwood <david.sherwood@arm.com>
28931
28932 * tree-vect-data-refs.c (vect_permute_store_chain): Reorganize
28933 so that both the length == 3 and length != 3 cases set up their
28934 own permute vectors. Add comments explaining why we know the
28935 number of elements is constant.
28936 (vect_permute_load_chain): Likewise.
28937
28938 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
28939 Alan Hayward <alan.hayward@arm.com>
28940 David Sherwood <david.sherwood@arm.com>
28941
28942 * machmode.h (mode_nunits): Change from unsigned char to
28943 poly_uint16_pod.
28944 (ONLY_FIXED_SIZE_MODES): New macro.
28945 (pod_mode::measurement_type, scalar_int_mode::measurement_type)
28946 (scalar_float_mode::measurement_type, scalar_mode::measurement_type)
28947 (complex_mode::measurement_type, fixed_size_mode::measurement_type):
28948 New typedefs.
28949 (mode_to_nunits): Return a poly_uint16 rather than an unsigned short.
28950 (GET_MODE_NUNITS): Return a constant if ONLY_FIXED_SIZE_MODES,
28951 or if measurement_type is not polynomial.
28952 * genmodes.c (ZERO_COEFFS): New macro.
28953 (emit_mode_nunits_inline): Make mode_nunits_inline return a
28954 poly_uint16.
28955 (emit_mode_nunits): Change the type of mode_nunits to poly_uint16_pod.
28956 Use ZERO_COEFFS when emitting initializers.
28957 * data-streamer.h (bp_pack_poly_value): New function.
28958 (bp_unpack_poly_value): Likewise.
28959 * lto-streamer-in.c (lto_input_mode_table): Use bp_unpack_poly_value
28960 for GET_MODE_NUNITS.
28961 * lto-streamer-out.c (lto_write_mode_table): Use bp_pack_poly_value
28962 for GET_MODE_NUNITS.
28963 * tree.c (make_vector_type): Remove temporary shim and make
28964 the real function take the number of units as a poly_uint64
28965 rather than an int.
28966 (build_vector_type_for_mode): Handle polynomial nunits.
28967 * dwarf2out.c (loc_descriptor, add_const_value_attribute): Likewise.
28968 * emit-rtl.c (const_vec_series_p_1): Likewise.
28969 (gen_rtx_CONST_VECTOR): Likewise.
28970 * fold-const.c (test_vec_duplicate_folding): Likewise.
28971 * genrecog.c (validate_pattern): Likewise.
28972 * optabs-query.c (can_vec_perm_var_p, can_mult_highpart_p): Likewise.
28973 * optabs-tree.c (expand_vec_cond_expr_p): Likewise.
28974 * optabs.c (expand_vector_broadcast, expand_binop_directly): Likewise.
28975 (shift_amt_for_vec_perm_mask, expand_vec_perm_var): Likewise.
28976 (expand_vec_cond_expr, expand_mult_highpart): Likewise.
28977 * rtlanal.c (subreg_get_info): Likewise.
28978 * tree-vect-data-refs.c (vect_grouped_store_supported): Likewise.
28979 (vect_grouped_load_supported): Likewise.
28980 * tree-vect-generic.c (type_for_widest_vector_mode): Likewise.
28981 * tree-vect-loop.c (have_whole_vector_shift): Likewise.
28982 * simplify-rtx.c (simplify_unary_operation_1): Likewise.
28983 (simplify_const_unary_operation, simplify_binary_operation_1)
28984 (simplify_const_binary_operation, simplify_ternary_operation)
28985 (test_vector_ops_duplicate, test_vector_ops): Likewise.
28986 (simplify_immed_subreg): Use GET_MODE_NUNITS on a fixed_size_mode
28987 instead of CONST_VECTOR_NUNITS.
28988 * varasm.c (output_constant_pool_2): Likewise.
28989 * rtx-vector-builder.c (rtx_vector_builder::build): Only include the
28990 explicit-encoded elements in the XVEC for variable-length vectors.
28991
28992 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
28993
28994 * lra-constraints.c (curr_insn_transform): Use partial_subreg_p.
28995
28996 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
28997 Alan Hayward <alan.hayward@arm.com>
28998 David Sherwood <david.sherwood@arm.com>
28999
29000 * coretypes.h (fixed_size_mode): Declare.
29001 (fixed_size_mode_pod): New typedef.
29002 * builtins.h (target_builtins::x_apply_args_mode)
29003 (target_builtins::x_apply_result_mode): Change type to
29004 fixed_size_mode_pod.
29005 * builtins.c (apply_args_size, apply_result_size, result_vector)
29006 (expand_builtin_apply_args_1, expand_builtin_apply)
29007 (expand_builtin_return): Update accordingly.
29008
29009 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
29010
29011 * cse.c (hash_rtx_cb): Hash only the encoded elements.
29012 * cselib.c (cselib_hash_rtx): Likewise.
29013 * expmed.c (make_tree): Build VECTOR_CSTs directly from the
29014 CONST_VECTOR encoding.
29015
29016 2018-01-03 Jakub Jelinek <jakub@redhat.com>
29017 Jeff Law <law@redhat.com>
29018
29019 PR target/83641
29020 * config/i386/i386.c (ix86_adjust_stack_and_probe_stack_clash): For
29021 noreturn probe, use gen_pop instead of ix86_emit_restore_reg_using_pop,
29022 only set RTX_FRAME_RELATED_P on both the push and pop if cfa_reg is sp
29023 and add REG_CFA_ADJUST_CFA notes in that case to both insns.
29024
29025 PR target/83641
29026 * config/i386/i386.c (ix86_adjust_stack_and_probe_stack_clash): Do not
29027 explicitly probe *sp in a noreturn function if there were any callee
29028 register saves or frame pointer is needed.
29029
29030 2018-01-03 Jakub Jelinek <jakub@redhat.com>
29031
29032 PR debug/83621
29033 * cfgexpand.c (expand_debug_expr): Return NULL if mode is
29034 BLKmode for ternary, binary or unary expressions.
29035
29036 PR debug/83645
29037 * var-tracking.c (delete_vta_debug_insn): New inline function.
29038 (delete_vta_debug_insns): Add USE_CFG argument, if true, walk just
29039 insns from get_insns () to NULL instead of each bb separately.
29040 Use delete_vta_debug_insn. No longer static.
29041 (vt_debug_insns_local, variable_tracking_main_1): Adjust
29042 delete_vta_debug_insns callers.
29043 * rtl.h (delete_vta_debug_insns): Declare.
29044 * final.c (rest_of_handle_final): Call delete_vta_debug_insns
29045 instead of variable_tracking_main.
29046
29047 2018-01-03 Martin Sebor <msebor@redhat.com>
29048
29049 PR tree-optimization/83603
29050 * calls.c (maybe_warn_nonstring_arg): Avoid accessing function
29051 arguments past the endof the argument list in functions declared
29052 without a prototype.
29053 * gimple-ssa-warn-restrict.c (wrestrict_dom_walker::check_call):
29054 Avoid checking when arguments are null.
29055
29056 2018-01-03 Martin Sebor <msebor@redhat.com>
29057
29058 PR c/83559
29059 * doc/extend.texi (attribute const): Fix a typo.
29060 * ipa-pure-const.c ((warn_function_const, warn_function_pure): Avoid
29061 issuing -Wsuggest-attribute for void functions.
29062
29063 2018-01-03 Martin Sebor <msebor@redhat.com>
29064
29065 * gimple-ssa-warn-restrict.c (builtin_memref::builtin_memref): Use
29066 offset_int::from instead of wide_int::to_shwi.
29067 (maybe_diag_overlap): Remove assertion.
29068 Use HOST_WIDE_INT_PRINT_DEC instead of %lli.
29069 * gimple-ssa-sprintf.c (format_directive): Same.
29070 (parse_directive): Same.
29071 (sprintf_dom_walker::compute_format_length): Same.
29072 (try_substitute_return_value): Same.
29073
29074 2018-01-03 Jeff Law <law@redhat.com>
29075
29076 PR middle-end/83654
29077 * explow.c (anti_adjust_stack_and_probe_stack_clash): Test a
29078 non-constant residual for zero at runtime and avoid probing in
29079 that case. Reorganize code for trailing problem to mirror handling
29080 of the residual.
29081
29082 2018-01-03 Prathamesh Kulkarni <prathamesh.kulkarni@linaro.org>
29083
29084 PR tree-optimization/83501
29085 * tree-ssa-strlen.c (get_string_cst): New.
29086 (handle_char_store): Call get_string_cst.
29087
29088 2018-01-03 Martin Liska <mliska@suse.cz>
29089
29090 PR tree-optimization/83593
29091 * tree-ssa-strlen.c: Include tree-cfg.h.
29092 (strlen_check_and_optimize_stmt): Add new argument cleanup_eh.
29093 (strlen_dom_walker): Add new member variable m_cleanup_cfg.
29094 (strlen_dom_walker::strlen_dom_walker): Initialize m_cleanup_cfg
29095 to false.
29096 (strlen_dom_walker::before_dom_children): Call
29097 gimple_purge_dead_eh_edges. Dump tranformation with details
29098 dump flags.
29099 (strlen_dom_walker::before_dom_children): Update call by adding
29100 new argument cleanup_eh.
29101 (pass_strlen::execute): Return TODO_cleanup_cfg if needed.
29102
29103 2018-01-03 Martin Liska <mliska@suse.cz>
29104
29105 PR ipa/83549
29106 * cif-code.def (VARIADIC_THUNK): New enum value.
29107 * ipa-fnsummary.c (compute_fn_summary): Do not inline variadic
29108 thunks.
29109
29110 2018-01-03 Jan Beulich <jbeulich@suse.com>
29111
29112 * sse.md (mov<mode>_internal): Tighten condition for when to use
29113 vmovdqu<ssescalarsize> for TI and OI modes.
29114
29115 2018-01-03 Jakub Jelinek <jakub@redhat.com>
29116
29117 Update copyright years.
29118
29119 2018-01-03 Martin Liska <mliska@suse.cz>
29120
29121 PR ipa/83594
29122 * ipa-visibility.c (function_and_variable_visibility): Skip
29123 functions with noipa attribure.
29124
29125 2018-01-03 Jakub Jelinek <jakub@redhat.com>
29126
29127 * gcc.c (process_command): Update copyright notice dates.
29128 * gcov-dump.c (print_version): Ditto.
29129 * gcov.c (print_version): Ditto.
29130 * gcov-tool.c (print_version): Ditto.
29131 * gengtype.c (create_file): Ditto.
29132 * doc/cpp.texi: Bump @copying's copyright year.
29133 * doc/cppinternals.texi: Ditto.
29134 * doc/gcc.texi: Ditto.
29135 * doc/gccint.texi: Ditto.
29136 * doc/gcov.texi: Ditto.
29137 * doc/install.texi: Ditto.
29138 * doc/invoke.texi: Ditto.
29139
29140 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
29141
29142 * vector-builder.h (vector_builder::m_full_nelts): Change from
29143 unsigned int to poly_uint64.
29144 (vector_builder::full_nelts): Update prototype accordingly.
29145 (vector_builder::new_vector): Likewise.
29146 (vector_builder::encoded_full_vector_p): Handle polynomial full_nelts.
29147 (vector_builder::operator ==): Likewise.
29148 (vector_builder::finalize): Likewise.
29149 * int-vector-builder.h (int_vector_builder::int_vector_builder):
29150 Take the number of elements as a poly_uint64 rather than an
29151 unsigned int.
29152 * vec-perm-indices.h (vec_perm_indices::m_nelts_per_input): Change
29153 from unsigned int to poly_uint64.
29154 (vec_perm_indices::vec_perm_indices): Update prototype accordingly.
29155 (vec_perm_indices::new_vector): Likewise.
29156 (vec_perm_indices::length): Likewise.
29157 (vec_perm_indices::nelts_per_input): Likewise.
29158 (vec_perm_indices::input_nelts): Likewise.
29159 * vec-perm-indices.c (vec_perm_indices::new_vector): Take the
29160 number of elements per input as a poly_uint64 rather than an
29161 unsigned int. Use the original encoding for variable-length
29162 vectors, rather than clamping each individual element.
29163 For the second and subsequent elements in each pattern,
29164 clamp the step and base before clamping their sum.
29165 (vec_perm_indices::series_p): Handle polynomial element counts.
29166 (vec_perm_indices::all_in_range_p): Likewise.
29167 (vec_perm_indices_to_tree): Likewise.
29168 (vec_perm_indices_to_rtx): Likewise.
29169 * tree-vect-stmts.c (vect_gen_perm_mask_any): Likewise.
29170 * tree-vector-builder.c (tree_vector_builder::new_unary_operation)
29171 (tree_vector_builder::new_binary_operation): Handle polynomial
29172 element counts. Return false if we need to know the number
29173 of elements at compile time.
29174 * fold-const.c (fold_vec_perm): Punt if the number of elements
29175 isn't known at compile time.
29176
29177 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
29178
29179 * vec-perm-indices.h (vec_perm_builder): Change element type
29180 from HOST_WIDE_INT to poly_int64.
29181 (vec_perm_indices::element_type): Update accordingly.
29182 (vec_perm_indices::clamp): Handle polynomial element_types.
29183 * vec-perm-indices.c (vec_perm_indices::series_p): Likewise.
29184 (vec_perm_indices::all_in_range_p): Likewise.
29185 (tree_to_vec_perm_builder): Check for poly_int64 trees rather
29186 than shwi trees.
29187 * vector-builder.h (vector_builder::stepped_sequence_p): Handle
29188 polynomial vec_perm_indices element types.
29189 * int-vector-builder.h (int_vector_builder::equal_p): Likewise.
29190 * fold-const.c (fold_vec_perm): Likewise.
29191 * optabs.c (shift_amt_for_vec_perm_mask): Likewise.
29192 * tree-vect-generic.c (lower_vec_perm): Likewise.
29193 * tree-vect-slp.c (vect_transform_slp_perm_load): Likewise.
29194 * config/aarch64/aarch64.c (aarch64_evpc_tbl): Cast d->perm
29195 element type to HOST_WIDE_INT.
29196
29197 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
29198 Alan Hayward <alan.hayward@arm.com>
29199 David Sherwood <david.sherwood@arm.com>
29200
29201 * alias.c (addr_side_effect_eval): Take the size as a poly_int64
29202 rather than an int. Use plus_constant.
29203 (memrefs_conflict_p): Take the sizes as poly_int64s rather than ints.
29204 Take the offset "c" as a poly_int64 rather than a HOST_WIDE_INT.
29205
29206 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
29207 Alan Hayward <alan.hayward@arm.com>
29208 David Sherwood <david.sherwood@arm.com>
29209
29210 * calls.c (emit_call_1, expand_call): Change struct_value_size from
29211 a HOST_WIDE_INT to a poly_int64.
29212
29213 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
29214 Alan Hayward <alan.hayward@arm.com>
29215 David Sherwood <david.sherwood@arm.com>
29216
29217 * calls.c (load_register_parameters): Cope with polynomial
29218 mode sizes. Require a constant size for BLKmode parameters
29219 that aren't described by a PARALLEL. If BLOCK_REG_PADDING
29220 forces a parameter to be padded at the lsb end in order to
29221 fill a complete number of words, require the parameter size
29222 to be ordered wrt UNITS_PER_WORD.
29223
29224 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
29225 Alan Hayward <alan.hayward@arm.com>
29226 David Sherwood <david.sherwood@arm.com>
29227
29228 * reload1.c (spill_stack_slot_width): Change element type
29229 from unsigned int to poly_uint64_pod.
29230 (alter_reg): Treat mode sizes as polynomial.
29231
29232 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
29233 Alan Hayward <alan.hayward@arm.com>
29234 David Sherwood <david.sherwood@arm.com>
29235
29236 * reload.c (complex_word_subreg_p): New function.
29237 (reload_inner_reg_of_subreg, push_reload): Use it.
29238
29239 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
29240 Alan Hayward <alan.hayward@arm.com>
29241 David Sherwood <david.sherwood@arm.com>
29242
29243 * lra-constraints.c (process_alt_operands): Reject matched
29244 operands whose sizes aren't ordered.
29245 (match_reload): Refer to this check here.
29246
29247 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
29248 Alan Hayward <alan.hayward@arm.com>
29249 David Sherwood <david.sherwood@arm.com>
29250
29251 * builtins.c (expand_ifn_atomic_compare_exchange_into_call): Assert
29252 that the mode size is in the set {1, 2, 4, 8, 16}.
29253
29254 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
29255 Alan Hayward <alan.hayward@arm.com>
29256 David Sherwood <david.sherwood@arm.com>
29257
29258 * var-tracking.c (adjust_mems): Treat mode sizes as polynomial.
29259 Use plus_constant instead of gen_rtx_PLUS.
29260
29261 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
29262 Alan Hayward <alan.hayward@arm.com>
29263 David Sherwood <david.sherwood@arm.com>
29264
29265 * config/cr16/cr16-protos.h (cr16_push_rounding): Declare.
29266 * config/cr16/cr16.h (PUSH_ROUNDING): Move implementation to...
29267 * config/cr16/cr16.c (cr16_push_rounding): ...this new function.
29268 * config/h8300/h8300-protos.h (h8300_push_rounding): Declare.
29269 * config/h8300/h8300.h (PUSH_ROUNDING): Move implementation to...
29270 * config/h8300/h8300.c (h8300_push_rounding): ...this new function.
29271 * config/i386/i386-protos.h (ix86_push_rounding): Declare.
29272 * config/i386/i386.h (PUSH_ROUNDING): Move implementation to...
29273 * config/i386/i386.c (ix86_push_rounding): ...this new function.
29274 * config/m32c/m32c-protos.h (m32c_push_rounding): Take and return
29275 a poly_int64.
29276 * config/m32c/m32c.c (m32c_push_rounding): Likewise.
29277 * config/m68k/m68k-protos.h (m68k_push_rounding): Declare.
29278 * config/m68k/m68k.h (PUSH_ROUNDING): Move implementation to...
29279 * config/m68k/m68k.c (m68k_push_rounding): ...this new function.
29280 * config/pdp11/pdp11-protos.h (pdp11_push_rounding): Declare.
29281 * config/pdp11/pdp11.h (PUSH_ROUNDING): Move implementation to...
29282 * config/pdp11/pdp11.c (pdp11_push_rounding): ...this new function.
29283 * config/stormy16/stormy16-protos.h (xstormy16_push_rounding): Declare.
29284 * config/stormy16/stormy16.h (PUSH_ROUNDING): Move implementation to...
29285 * config/stormy16/stormy16.c (xstormy16_push_rounding): ...this new
29286 function.
29287 * expr.c (emit_move_resolve_push): Treat the input and result
29288 of PUSH_ROUNDING as a poly_int64.
29289 (emit_move_complex_push, emit_single_push_insn_1): Likewise.
29290 (emit_push_insn): Likewise.
29291 * lra-eliminations.c (mark_not_eliminable): Likewise.
29292 * recog.c (push_operand): Likewise.
29293 * reload1.c (elimination_effects): Likewise.
29294 * rtlanal.c (nonzero_bits1): Likewise.
29295 * calls.c (store_one_arg): Likewise. Require the padding to be
29296 known at compile time.
29297
29298 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
29299 Alan Hayward <alan.hayward@arm.com>
29300 David Sherwood <david.sherwood@arm.com>
29301
29302 * expr.c (emit_single_push_insn_1): Treat mode sizes as polynomial.
29303 Use plus_constant instead of gen_rtx_PLUS.
29304
29305 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
29306 Alan Hayward <alan.hayward@arm.com>
29307 David Sherwood <david.sherwood@arm.com>
29308
29309 * auto-inc-dec.c (set_inc_state): Take the mode size as a poly_int64
29310 rather than an int.
29311
29312 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
29313 Alan Hayward <alan.hayward@arm.com>
29314 David Sherwood <david.sherwood@arm.com>
29315
29316 * expr.c (expand_expr_real_1): Use tree_to_poly_uint64
29317 instead of int_size_in_bytes when handling VIEW_CONVERT_EXPRs
29318 via stack temporaries. Treat the mode size as polynomial too.
29319
29320 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
29321 Alan Hayward <alan.hayward@arm.com>
29322 David Sherwood <david.sherwood@arm.com>
29323
29324 * expr.c (expand_expr_real_2): When handling conversions involving
29325 unions, apply tree_to_poly_uint64 to the TYPE_SIZE rather than
29326 multiplying int_size_in_bytes by BITS_PER_UNIT. Treat GET_MODE_BISIZE
29327 as a poly_uint64 too.
29328
29329 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
29330 Alan Hayward <alan.hayward@arm.com>
29331 David Sherwood <david.sherwood@arm.com>
29332
29333 * rtlanal.c (subreg_get_info): Handle polynomial mode sizes.
29334
29335 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
29336 Alan Hayward <alan.hayward@arm.com>
29337 David Sherwood <david.sherwood@arm.com>
29338
29339 * combine.c (can_change_dest_mode): Handle polynomial
29340 REGMODE_NATURAL_SIZE.
29341 * expmed.c (store_bit_field_1): Likewise.
29342 * expr.c (store_constructor): Likewise.
29343 * emit-rtl.c (validate_subreg): Operate on polynomial mode sizes
29344 and polynomial REGMODE_NATURAL_SIZE.
29345 (gen_lowpart_common): Likewise.
29346 * reginfo.c (record_subregs_of_mode): Likewise.
29347 * rtlanal.c (read_modify_subreg_p): Likewise.
29348
29349 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
29350 Alan Hayward <alan.hayward@arm.com>
29351 David Sherwood <david.sherwood@arm.com>
29352
29353 * internal-fn.c (expand_vector_ubsan_overflow): Handle polynomial
29354 numbers of elements.
29355
29356 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
29357 Alan Hayward <alan.hayward@arm.com>
29358 David Sherwood <david.sherwood@arm.com>
29359
29360 * match.pd: Cope with polynomial numbers of vector elements.
29361
29362 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
29363 Alan Hayward <alan.hayward@arm.com>
29364 David Sherwood <david.sherwood@arm.com>
29365
29366 * fold-const.c (fold_indirect_ref_1): Handle polynomial offsets
29367 in a POINTER_PLUS_EXPR.
29368
29369 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
29370 Alan Hayward <alan.hayward@arm.com>
29371 David Sherwood <david.sherwood@arm.com>
29372
29373 * omp-simd-clone.c (simd_clone_subparts): New function.
29374 (simd_clone_init_simd_arrays): Use it instead of TYPE_VECTOR_SUBPARTS.
29375 (ipa_simd_modify_function_body): Likewise.
29376
29377 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
29378 Alan Hayward <alan.hayward@arm.com>
29379 David Sherwood <david.sherwood@arm.com>
29380
29381 * tree-vect-generic.c (nunits_for_known_piecewise_op): New function.
29382 (expand_vector_piecewise): Use it instead of TYPE_VECTOR_SUBPARTS.
29383 (expand_vector_addition, add_rshift, expand_vector_divmod): Likewise.
29384 (expand_vector_condition, vector_element): Likewise.
29385 (subparts_gt): New function.
29386 (get_compute_type): Use subparts_gt.
29387 (count_type_subparts): Delete.
29388 (expand_vector_operations_1): Use subparts_gt instead of
29389 count_type_subparts.
29390
29391 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
29392 Alan Hayward <alan.hayward@arm.com>
29393 David Sherwood <david.sherwood@arm.com>
29394
29395 * tree-vect-data-refs.c (vect_no_alias_p): Replace with...
29396 (vect_compile_time_alias): ...this new function. Do the calculation
29397 on poly_ints rather than trees.
29398 (vect_prune_runtime_alias_test_list): Update call accordingly.
29399
29400 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
29401 Alan Hayward <alan.hayward@arm.com>
29402 David Sherwood <david.sherwood@arm.com>
29403
29404 * tree-vect-slp.c (vect_build_slp_tree_1): Handle polynomial
29405 numbers of units.
29406 (vect_schedule_slp_instance): Likewise.
29407
29408 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
29409 Alan Hayward <alan.hayward@arm.com>
29410 David Sherwood <david.sherwood@arm.com>
29411
29412 * tree-vect-slp.c (vect_get_and_check_slp_defs): Reject
29413 constant and extern definitions for variable-length vectors.
29414 (vect_get_constant_vectors): Note that the number of units
29415 is known to be constant.
29416
29417 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
29418 Alan Hayward <alan.hayward@arm.com>
29419 David Sherwood <david.sherwood@arm.com>
29420
29421 * tree-vect-stmts.c (vectorizable_conversion): Treat the number
29422 of units as polynomial. Choose between WIDE and NARROW based
29423 on multiple_p.
29424
29425 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
29426 Alan Hayward <alan.hayward@arm.com>
29427 David Sherwood <david.sherwood@arm.com>
29428
29429 * tree-vect-stmts.c (simd_clone_subparts): New function.
29430 (vectorizable_simd_clone_call): Use it instead of TYPE_VECTOR_SUBPARTS.
29431
29432 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
29433 Alan Hayward <alan.hayward@arm.com>
29434 David Sherwood <david.sherwood@arm.com>
29435
29436 * tree-vect-stmts.c (vectorizable_call): Treat the number of
29437 vectors as polynomial. Use build_index_vector for
29438 IFN_GOMP_SIMD_LANE.
29439
29440 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
29441 Alan Hayward <alan.hayward@arm.com>
29442 David Sherwood <david.sherwood@arm.com>
29443
29444 * tree-vect-stmts.c (get_load_store_type): Treat the number of
29445 units as polynomial. Reject VMAT_ELEMENTWISE and VMAT_STRIDED_SLP
29446 for variable-length vectors.
29447 (vectorizable_mask_load_store): Treat the number of units as
29448 polynomial, asserting that it is constant if the condition has
29449 already been enforced.
29450 (vectorizable_store, vectorizable_load): Likewise.
29451
29452 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
29453 Alan Hayward <alan.hayward@arm.com>
29454 David Sherwood <david.sherwood@arm.com>
29455
29456 * tree-vect-loop.c (vectorizable_live_operation): Treat the number
29457 of units as polynomial. Punt if we can't tell at compile time
29458 which vector contains the final result.
29459
29460 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
29461 Alan Hayward <alan.hayward@arm.com>
29462 David Sherwood <david.sherwood@arm.com>
29463
29464 * tree-vect-loop.c (vectorizable_induction): Treat the number
29465 of units as polynomial. Punt on SLP inductions. Use an integer
29466 VEC_SERIES_EXPR for variable-length integer reductions. Use a
29467 cast of such a series for variable-length floating-point
29468 reductions.
29469
29470 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
29471 Alan Hayward <alan.hayward@arm.com>
29472 David Sherwood <david.sherwood@arm.com>
29473
29474 * tree.h (build_index_vector): Declare.
29475 * tree.c (build_index_vector): New function.
29476 * tree-vect-loop.c (get_initial_defs_for_reduction): Treat the number
29477 of units as polynomial, forcibly converting it to a constant if
29478 vectorizable_reduction has already enforced the condition.
29479 (vect_create_epilog_for_reduction): Likewise. Use build_index_vector
29480 to create a {1,2,3,...} vector.
29481 (vectorizable_reduction): Treat the number of units as polynomial.
29482 Choose vectype_in based on the largest scalar element size rather
29483 than the smallest number of units. Enforce the restrictions
29484 relied on above.
29485
29486 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
29487 Alan Hayward <alan.hayward@arm.com>
29488 David Sherwood <david.sherwood@arm.com>
29489
29490 * tree-vect-data-refs.c (vector_alignment_reachable_p): Treat the
29491 number of units as polynomial.
29492
29493 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
29494 Alan Hayward <alan.hayward@arm.com>
29495 David Sherwood <david.sherwood@arm.com>
29496
29497 * target.h (vector_sizes, auto_vector_sizes): New typedefs.
29498 * target.def (autovectorize_vector_sizes): Return the vector sizes
29499 by pointer, using vector_sizes rather than a bitmask.
29500 * targhooks.h (default_autovectorize_vector_sizes): Update accordingly.
29501 * targhooks.c (default_autovectorize_vector_sizes): Likewise.
29502 * config/aarch64/aarch64.c (aarch64_autovectorize_vector_sizes):
29503 Likewise.
29504 * config/arc/arc.c (arc_autovectorize_vector_sizes): Likewise.
29505 * config/arm/arm.c (arm_autovectorize_vector_sizes): Likewise.
29506 * config/i386/i386.c (ix86_autovectorize_vector_sizes): Likewise.
29507 * config/mips/mips.c (mips_autovectorize_vector_sizes): Likewise.
29508 * omp-general.c (omp_max_vf): Likewise.
29509 * omp-low.c (omp_clause_aligned_alignment): Likewise.
29510 * optabs-query.c (can_vec_mask_load_store_p): Likewise.
29511 * tree-vect-loop.c (vect_analyze_loop): Likewise.
29512 * tree-vect-slp.c (vect_slp_bb): Likewise.
29513 * doc/tm.texi: Regenerate.
29514 * tree-vectorizer.h (current_vector_size): Change from an unsigned int
29515 to a poly_uint64.
29516 * tree-vect-stmts.c (get_vectype_for_scalar_type_and_size): Take
29517 the vector size as a poly_uint64 rather than an unsigned int.
29518 (current_vector_size): Change from an unsigned int to a poly_uint64.
29519 (get_vectype_for_scalar_type): Update accordingly.
29520 * tree.h (build_truth_vector_type): Take the size and number of
29521 units as a poly_uint64 rather than an unsigned int.
29522 (build_vector_type): Add a temporary overload that takes
29523 the number of units as a poly_uint64 rather than an unsigned int.
29524 * tree.c (make_vector_type): Likewise.
29525 (build_truth_vector_type): Take the number of units as a poly_uint64
29526 rather than an unsigned int.
29527
29528 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
29529 Alan Hayward <alan.hayward@arm.com>
29530 David Sherwood <david.sherwood@arm.com>
29531
29532 * target.def (get_mask_mode): Take the number of units and length
29533 as poly_uint64s rather than unsigned ints.
29534 * targhooks.h (default_get_mask_mode): Update accordingly.
29535 * targhooks.c (default_get_mask_mode): Likewise.
29536 * config/i386/i386.c (ix86_get_mask_mode): Likewise.
29537 * doc/tm.texi: Regenerate.
29538
29539 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
29540 Alan Hayward <alan.hayward@arm.com>
29541 David Sherwood <david.sherwood@arm.com>
29542
29543 * omp-general.h (omp_max_vf): Return a poly_uint64 instead of an int.
29544 * omp-general.c (omp_max_vf): Likewise.
29545 * omp-expand.c (omp_adjust_chunk_size): Update call to omp_max_vf.
29546 (expand_omp_simd): Handle polynomial safelen.
29547 * omp-low.c (omplow_simd_context): Add a default constructor.
29548 (omplow_simd_context::max_vf): Change from int to poly_uint64.
29549 (lower_rec_simd_input_clauses): Update accordingly.
29550 (lower_rec_input_clauses): Likewise.
29551
29552 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
29553 Alan Hayward <alan.hayward@arm.com>
29554 David Sherwood <david.sherwood@arm.com>
29555
29556 * tree-vectorizer.h (vect_nunits_for_cost): New function.
29557 * tree-vect-loop.c (vect_model_reduction_cost): Use it.
29558 * tree-vect-slp.c (vect_analyze_slp_cost_1): Likewise.
29559 (vect_analyze_slp_cost): Likewise.
29560 * tree-vect-stmts.c (vect_model_store_cost): Likewise.
29561 (vect_model_load_cost): Likewise.
29562
29563 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
29564 Alan Hayward <alan.hayward@arm.com>
29565 David Sherwood <david.sherwood@arm.com>
29566
29567 * tree-vect-slp.c (vect_record_max_nunits, vect_build_slp_tree_1)
29568 (vect_build_slp_tree_2, vect_build_slp_tree): Change max_nunits
29569 from an unsigned int * to a poly_uint64_pod *.
29570 (calculate_unrolling_factor): New function.
29571 (vect_analyze_slp_instance): Use it. Track polynomial max_nunits.
29572
29573 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
29574 Alan Hayward <alan.hayward@arm.com>
29575 David Sherwood <david.sherwood@arm.com>
29576
29577 * tree-vectorizer.h (_slp_instance::unrolling_factor): Change
29578 from an unsigned int to a poly_uint64.
29579 (_loop_vec_info::slp_unrolling_factor): Likewise.
29580 (_loop_vec_info::vectorization_factor): Change from an int
29581 to a poly_uint64.
29582 (MAX_VECTORIZATION_FACTOR): Bump from 64 to INT_MAX.
29583 (vect_get_num_vectors): New function.
29584 (vect_update_max_nunits, vect_vf_for_cost): Likewise.
29585 (vect_get_num_copies): Use vect_get_num_vectors.
29586 (vect_analyze_data_ref_dependences): Change max_vf from an int *
29587 to an unsigned int *.
29588 (vect_analyze_data_refs): Change min_vf from an int * to a
29589 poly_uint64 *.
29590 (vect_transform_slp_perm_load): Take the vf as a poly_uint64 rather
29591 than an unsigned HOST_WIDE_INT.
29592 * tree-vect-data-refs.c (vect_analyze_possibly_independent_ddr)
29593 (vect_analyze_data_ref_dependence): Change max_vf from an int *
29594 to an unsigned int *.
29595 (vect_analyze_data_ref_dependences): Likewise.
29596 (vect_compute_data_ref_alignment): Handle polynomial vf.
29597 (vect_enhance_data_refs_alignment): Likewise.
29598 (vect_prune_runtime_alias_test_list): Likewise.
29599 (vect_shift_permute_load_chain): Likewise.
29600 (vect_supportable_dr_alignment): Likewise.
29601 (dependence_distance_ge_vf): Take the vectorization factor as a
29602 poly_uint64 rather than an unsigned HOST_WIDE_INT.
29603 (vect_analyze_data_refs): Change min_vf from an int * to a
29604 poly_uint64 *.
29605 * tree-vect-loop-manip.c (vect_gen_scalar_loop_niters): Take
29606 vfm1 as a poly_uint64 rather than an int. Make the same change
29607 for the returned bound_scalar.
29608 (vect_gen_vector_loop_niters): Handle polynomial vf.
29609 (vect_do_peeling): Likewise. Update call to
29610 vect_gen_scalar_loop_niters and handle polynomial bound_scalars.
29611 (vect_gen_vector_loop_niters_mult_vf): Assert that the vf must
29612 be constant.
29613 * tree-vect-loop.c (vect_determine_vectorization_factor)
29614 (vect_update_vf_for_slp, vect_analyze_loop_2): Handle polynomial vf.
29615 (vect_get_known_peeling_cost): Likewise.
29616 (vect_estimate_min_profitable_iters, vectorizable_reduction): Likewise.
29617 (vect_worthwhile_without_simd_p, vectorizable_induction): Likewise.
29618 (vect_transform_loop): Likewise. Use the lowest possible VF when
29619 updating the upper bounds of the loop.
29620 (vect_min_worthwhile_factor): Make static. Return an unsigned int
29621 rather than an int.
29622 * tree-vect-slp.c (vect_attempt_slp_rearrange_stmts): Cope with
29623 polynomial unroll factors.
29624 (vect_analyze_slp_cost_1, vect_analyze_slp_instance): Likewise.
29625 (vect_make_slp_decision): Likewise.
29626 (vect_supported_load_permutation_p): Likewise, and polynomial
29627 vf too.
29628 (vect_analyze_slp_cost): Handle polynomial vf.
29629 (vect_slp_analyze_node_operations): Likewise.
29630 (vect_slp_analyze_bb_1): Likewise.
29631 (vect_transform_slp_perm_load): Take the vf as a poly_uint64 rather
29632 than an unsigned HOST_WIDE_INT.
29633 * tree-vect-stmts.c (vectorizable_simd_clone_call, vectorizable_store)
29634 (vectorizable_load): Handle polynomial vf.
29635 * tree-vectorizer.c (simduid_to_vf::vf): Change from an int to
29636 a poly_uint64.
29637 (adjust_simduid_builtins, shrink_simd_arrays): Update accordingly.
29638
29639 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
29640 Alan Hayward <alan.hayward@arm.com>
29641 David Sherwood <david.sherwood@arm.com>
29642
29643 * match.pd: Handle bit operations involving three constants
29644 and try to fold one pair.
29645
29646 2018-01-03 Richard Sandiford <richard.sandiford@linaro.org>
29647
29648 * tree-vect-loop-manip.c: Include gimple-fold.h.
29649 (slpeel_make_loop_iterate_ntimes): Add step, final_iv and
29650 niters_maybe_zero parameters. Handle other cases besides a step of 1.
29651 (vect_gen_vector_loop_niters): Add a step_vector_ptr parameter.
29652 Add a path that uses a step of VF instead of 1, but disable it
29653 for now.
29654 (vect_do_peeling): Add step_vector, niters_vector_mult_vf_var
29655 and niters_no_overflow parameters. Update calls to
29656 slpeel_make_loop_iterate_ntimes and vect_gen_vector_loop_niters.
29657 Create a new SSA name if the latter choses to use a ste other
29658 than zero, and return it via niters_vector_mult_vf_var.
29659 * tree-vect-loop.c (vect_transform_loop): Update calls to
29660 vect_do_peeling, vect_gen_vector_loop_niters and
29661 slpeel_make_loop_iterate_ntimes.
29662 * tree-vectorizer.h (slpeel_make_loop_iterate_ntimes, vect_do_peeling)
29663 (vect_gen_vector_loop_niters): Update declarations after above changes.
29664
29665 2018-01-02 Michael Meissner <meissner@linux.vnet.ibm.com>
29666
29667 * config/rs6000/rs6000.md (floor<mode>2): Add support for IEEE
29668 128-bit round to integer instructions.
29669 (ceil<mode>2): Likewise.
29670 (btrunc<mode>2): Likewise.
29671 (round<mode>2): Likewise.
29672
29673 2018-01-02 Aaron Sawdey <acsawdey@linux.vnet.ibm.com>
29674
29675 * config/rs6000/rs6000-string.c (expand_block_move): Allow the use of
29676 unaligned VSX load/store on P8/P9.
29677 (expand_block_clear): Allow the use of unaligned VSX
29678 load/store on P8/P9.
29679
29680 2018-01-02 Bill Schmidt <wschmidt@linux.vnet.ibm.com>
29681
29682 * config/rs6000/rs6000-p8swap.c (swap_feeds_both_load_and_store):
29683 New function.
29684 (rs6000_analyze_swaps): Mark a web unoptimizable if it contains a
29685 swap associated with both a load and a store.
29686
29687 2018-01-02 Andrew Waterman <andrew@sifive.com>
29688
29689 * config/riscv/linux.h (ICACHE_FLUSH_FUNC): New.
29690 * config/riscv/riscv.md (clear_cache): Use it.
29691
29692 2018-01-02 Artyom Skrobov <tyomitch@gmail.com>
29693
29694 * web.c: Remove out-of-date comment.
29695
29696 2018-01-02 Richard Sandiford <richard.sandiford@linaro.org>
29697
29698 * expr.c (fixup_args_size_notes): Check that any existing
29699 REG_ARGS_SIZE notes are correct, and don't try to re-add them.
29700 (emit_single_push_insn_1): Move stack_pointer_delta adjustment to...
29701 (emit_single_push_insn): ...here.
29702
29703 2018-01-02 Richard Sandiford <richard.sandiford@linaro.org>
29704
29705 * rtl.h (CONST_VECTOR_ELT): Redefine to const_vector_elt.
29706 (const_vector_encoded_nelts): New function.
29707 (CONST_VECTOR_NUNITS): Redefine to use GET_MODE_NUNITS.
29708 (const_vector_int_elt, const_vector_elt): Declare.
29709 * emit-rtl.c (const_vector_int_elt_1): New function.
29710 (const_vector_elt): Likewise.
29711 * simplify-rtx.c (simplify_immed_subreg): Avoid taking the address
29712 of CONST_VECTOR_ELT.
29713
29714 2018-01-02 Richard Sandiford <richard.sandiford@linaro.org>
29715
29716 * expr.c: Include rtx-vector-builder.h.
29717 (const_vector_mask_from_tree): Use rtx_vector_builder and operate
29718 directly on the tree encoding.
29719 (const_vector_from_tree): Likewise.
29720 * optabs.c: Include rtx-vector-builder.h.
29721 (expand_vec_perm_var): Use rtx_vector_builder and create a repeating
29722 sequence of "u" values.
29723 * vec-perm-indices.c: Include rtx-vector-builder.h.
29724 (vec_perm_indices_to_rtx): Use rtx_vector_builder and operate
29725 directly on the vec_perm_indices encoding.
29726
29727 2018-01-02 Richard Sandiford <richard.sandiford@linaro.org>
29728
29729 * doc/rtl.texi (const_vector): Describe new encoding scheme.
29730 * Makefile.in (OBJS): Add rtx-vector-builder.o.
29731 * rtx-vector-builder.h: New file.
29732 * rtx-vector-builder.c: Likewise.
29733 * rtl.h (rtx_def::u2): Add a const_vector field.
29734 (CONST_VECTOR_NPATTERNS): New macro.
29735 (CONST_VECTOR_NELTS_PER_PATTERN): Likewise.
29736 (CONST_VECTOR_DUPLICATE_P): Likewise.
29737 (CONST_VECTOR_STEPPED_P): Likewise.
29738 (CONST_VECTOR_ENCODED_ELT): Likewise.
29739 (const_vec_duplicate_p): Check for a duplicated vector encoding.
29740 (unwrap_const_vec_duplicate): Likewise.
29741 (const_vec_series_p): Check for a non-duplicated vector encoding.
29742 Say that the function only returns true for integer vectors.
29743 * emit-rtl.c: Include rtx-vector-builder.h.
29744 (gen_const_vec_duplicate_1): Delete.
29745 (gen_const_vector): Call gen_const_vec_duplicate instead of
29746 gen_const_vec_duplicate_1.
29747 (const_vec_series_p_1): Operate directly on the CONST_VECTOR encoding.
29748 (gen_const_vec_duplicate): Use rtx_vector_builder.
29749 (gen_const_vec_series): Likewise.
29750 (gen_rtx_CONST_VECTOR): Likewise.
29751 * config/powerpcspe/powerpcspe.c: Include rtx-vector-builder.h.
29752 (swap_const_vector_halves): Take an rtx pointer rather than rtx.
29753 Build a new vector rather than modifying a CONST_VECTOR in-place.
29754 (handle_special_swappables): Update call accordingly.
29755 * config/rs6000/rs6000-p8swap.c: Include rtx-vector-builder.h.
29756 (swap_const_vector_halves): Take an rtx pointer rather than rtx.
29757 Build a new vector rather than modifying a CONST_VECTOR in-place.
29758 (handle_special_swappables): Update call accordingly.
29759
29760 2018-01-02 Richard Sandiford <richard.sandiford@linaro.org>
29761
29762 * simplify-rtx.c (simplify_const_binary_operation): Use
29763 CONST_VECTOR_ELT instead of XVECEXP.
29764
29765 2018-01-02 Richard Sandiford <richard.sandiford@linaro.org>
29766
29767 * tree-cfg.c (verify_gimple_assign_ternary): Allow the size of
29768 the selector elements to be different from the data elements
29769 if the selector is a VECTOR_CST.
29770 * tree-vect-stmts.c (vect_gen_perm_mask_any): Use a vector of
29771 ssizetype for the selector.
29772
29773 2018-01-02 Richard Sandiford <richard.sandiford@linaro.org>
29774
29775 * optabs.c (shift_amt_for_vec_perm_mask): Try using series_p
29776 before testing each element individually.
29777 * tree-vect-generic.c (lower_vec_perm): Likewise.
29778
29779 2018-01-02 Richard Sandiford <richard.sandiford@linaro.org>
29780
29781 * selftest.h (selftest::vec_perm_indices_c_tests): Declare.
29782 * selftest-run-tests.c (selftest::run_tests): Call it.
29783 * vector-builder.h (vector_builder::operator ==): New function.
29784 (vector_builder::operator !=): Likewise.
29785 * vec-perm-indices.h (vec_perm_indices::series_p): Declare.
29786 (vec_perm_indices::all_from_input_p): New function.
29787 * vec-perm-indices.c (vec_perm_indices::series_p): Likewise.
29788 (test_vec_perm_12, selftest::vec_perm_indices_c_tests): Likewise.
29789 * fold-const.c (fold_ternary_loc): Use tree_to_vec_perm_builder
29790 instead of reading the VECTOR_CST directly. Detect whether both
29791 vector inputs are the same before constructing the vec_perm_indices,
29792 and update the number of inputs argument accordingly. Use the
29793 utility functions added above. Only construct sel2 if we need to.
29794
29795 2018-01-02 Richard Sandiford <richard.sandiford@linaro.org>
29796
29797 * optabs.c (expand_vec_perm_var): Use an explicit encoding for
29798 the broadcast of the low byte.
29799 (expand_mult_highpart): Use an explicit encoding for the permutes.
29800 * optabs-query.c (can_mult_highpart_p): Likewise.
29801 * tree-vect-loop.c (calc_vec_perm_mask_for_shift): Likewise.
29802 * tree-vect-stmts.c (perm_mask_for_reverse): Likewise.
29803 (vectorizable_bswap): Likewise.
29804 * tree-vect-data-refs.c (vect_grouped_store_supported): Use an
29805 explicit encoding for the power-of-2 permutes.
29806 (vect_permute_store_chain): Likewise.
29807 (vect_grouped_load_supported): Likewise.
29808 (vect_permute_load_chain): Likewise.
29809
29810 2018-01-02 Richard Sandiford <richard.sandiford@linaro.org>
29811
29812 * vec-perm-indices.h (vec_perm_indices_to_tree): Declare.
29813 * vec-perm-indices.c (vec_perm_indices_to_tree): New function.
29814 * tree-ssa-forwprop.c (simplify_vector_constructor): Use it.
29815 * tree-vect-slp.c (vect_transform_slp_perm_load): Likewise.
29816 * tree-vect-stmts.c (vectorizable_bswap): Likewise.
29817 (vect_gen_perm_mask_any): Likewise.
29818
29819 2018-01-02 Richard Sandiford <richard.sandiford@linaro.org>
29820
29821 * int-vector-builder.h: New file.
29822 * vec-perm-indices.h: Include int-vector-builder.h.
29823 (vec_perm_indices): Redefine as an int_vector_builder.
29824 (auto_vec_perm_indices): Delete.
29825 (vec_perm_builder): Redefine as a stand-alone class.
29826 (vec_perm_indices::vec_perm_indices): New function.
29827 (vec_perm_indices::clamp): Likewise.
29828 * vec-perm-indices.c: Include fold-const.h and tree-vector-builder.h.
29829 (vec_perm_indices::new_vector): New function.
29830 (vec_perm_indices::new_expanded_vector): Update for new
29831 vec_perm_indices class.
29832 (vec_perm_indices::rotate_inputs): New function.
29833 (vec_perm_indices::all_in_range_p): Operate directly on the
29834 encoded form, without computing elided elements.
29835 (tree_to_vec_perm_builder): Operate directly on the VECTOR_CST
29836 encoding. Update for new vec_perm_indices class.
29837 * optabs.c (expand_vec_perm_const): Create a vec_perm_indices for
29838 the given vec_perm_builder.
29839 (expand_vec_perm_var): Update vec_perm_builder constructor.
29840 (expand_mult_highpart): Use vec_perm_builder instead of
29841 auto_vec_perm_indices.
29842 * optabs-query.c (can_mult_highpart_p): Use vec_perm_builder and
29843 vec_perm_indices instead of auto_vec_perm_indices. Use a single
29844 or double series encoding as appropriate.
29845 * fold-const.c (fold_ternary_loc): Use vec_perm_builder and
29846 vec_perm_indices instead of auto_vec_perm_indices.
29847 * tree-ssa-forwprop.c (simplify_vector_constructor): Likewise.
29848 * tree-vect-data-refs.c (vect_grouped_store_supported): Likewise.
29849 (vect_permute_store_chain): Likewise.
29850 (vect_grouped_load_supported): Likewise.
29851 (vect_permute_load_chain): Likewise.
29852 (vect_shift_permute_load_chain): Likewise.
29853 * tree-vect-slp.c (vect_build_slp_tree_1): Likewise.
29854 (vect_transform_slp_perm_load): Likewise.
29855 (vect_schedule_slp_instance): Likewise.
29856 * tree-vect-stmts.c (perm_mask_for_reverse): Likewise.
29857 (vectorizable_mask_load_store): Likewise.
29858 (vectorizable_bswap): Likewise.
29859 (vectorizable_store): Likewise.
29860 (vectorizable_load): Likewise.
29861 * tree-vect-generic.c (lower_vec_perm): Use vec_perm_builder and
29862 vec_perm_indices instead of auto_vec_perm_indices. Use
29863 tree_to_vec_perm_builder to read the vector from a tree.
29864 * tree-vect-loop.c (calc_vec_perm_mask_for_shift): Take a
29865 vec_perm_builder instead of a vec_perm_indices.
29866 (have_whole_vector_shift): Use vec_perm_builder and
29867 vec_perm_indices instead of auto_vec_perm_indices. Leave the
29868 truncation to calc_vec_perm_mask_for_shift.
29869 (vect_create_epilog_for_reduction): Likewise.
29870 * config/aarch64/aarch64.c (expand_vec_perm_d::perm): Change
29871 from auto_vec_perm_indices to vec_perm_indices.
29872 (aarch64_expand_vec_perm_const_1): Use rotate_inputs on d.perm
29873 instead of changing individual elements.
29874 (aarch64_vectorize_vec_perm_const): Use new_vector to install
29875 the vector in d.perm.
29876 * config/arm/arm.c (expand_vec_perm_d::perm): Change
29877 from auto_vec_perm_indices to vec_perm_indices.
29878 (arm_expand_vec_perm_const_1): Use rotate_inputs on d.perm
29879 instead of changing individual elements.
29880 (arm_vectorize_vec_perm_const): Use new_vector to install
29881 the vector in d.perm.
29882 * config/powerpcspe/powerpcspe.c (rs6000_expand_extract_even):
29883 Update vec_perm_builder constructor.
29884 (rs6000_expand_interleave): Likewise.
29885 * config/rs6000/rs6000.c (rs6000_expand_extract_even): Likewise.
29886 (rs6000_expand_interleave): Likewise.
29887
29888 2018-01-02 Richard Sandiford <richard.sandiford@linaro.org>
29889
29890 * optabs-query.c (can_vec_perm_var_p): Check whether lowering
29891 to qimode could truncate the indices.
29892 * optabs.c (expand_vec_perm_var): Likewise.
29893
29894 2018-01-02 Richard Sandiford <richard.sandiford@linaro.org>
29895
29896 * Makefile.in (OBJS): Add vec-perm-indices.o.
29897 * vec-perm-indices.h: New file.
29898 * vec-perm-indices.c: Likewise.
29899 * target.h (vec_perm_indices): Replace with a forward class
29900 declaration.
29901 (auto_vec_perm_indices): Move to vec-perm-indices.h.
29902 * optabs.h: Include vec-perm-indices.h.
29903 (expand_vec_perm): Delete.
29904 (selector_fits_mode_p, expand_vec_perm_var): Declare.
29905 (expand_vec_perm_const): Declare.
29906 * target.def (vec_perm_const_ok): Replace with...
29907 (vec_perm_const): ...this new hook.
29908 * doc/tm.texi.in (TARGET_VECTORIZE_VEC_PERM_CONST_OK): Replace with...
29909 (TARGET_VECTORIZE_VEC_PERM_CONST): ...this new hook.
29910 * doc/tm.texi: Regenerate.
29911 * optabs.def (vec_perm_const): Delete.
29912 * doc/md.texi (vec_perm_const): Likewise.
29913 (vec_perm): Refer to TARGET_VECTORIZE_VEC_PERM_CONST.
29914 * expr.c (expand_expr_real_2): Use expand_vec_perm_const rather than
29915 expand_vec_perm for constant permutation vectors. Assert that
29916 the mode of variable permutation vectors is the integer equivalent
29917 of the mode that is being permuted.
29918 * optabs-query.h (selector_fits_mode_p): Declare.
29919 * optabs-query.c: Include vec-perm-indices.h.
29920 (selector_fits_mode_p): New function.
29921 (can_vec_perm_const_p): Check whether targetm.vectorize.vec_perm_const
29922 is defined, instead of checking whether the vec_perm_const_optab
29923 exists. Use targetm.vectorize.vec_perm_const instead of
29924 targetm.vectorize.vec_perm_const_ok. Check whether the indices
29925 fit in the vector mode before using a variable permute.
29926 * optabs.c (shift_amt_for_vec_perm_mask): Take a mode and a
29927 vec_perm_indices instead of an rtx.
29928 (expand_vec_perm): Replace with...
29929 (expand_vec_perm_const): ...this new function. Take the selector
29930 as a vec_perm_indices rather than an rtx. Also take the mode of
29931 the selector. Update call to shift_amt_for_vec_perm_mask.
29932 Use targetm.vectorize.vec_perm_const instead of vec_perm_const_optab.
29933 Use vec_perm_indices::new_expanded_vector to expand the original
29934 selector into bytes. Check whether the indices fit in the vector
29935 mode before using a variable permute.
29936 (expand_vec_perm_var): Make global.
29937 (expand_mult_highpart): Use expand_vec_perm_const.
29938 * fold-const.c: Includes vec-perm-indices.h.
29939 * tree-ssa-forwprop.c: Likewise.
29940 * tree-vect-data-refs.c: Likewise.
29941 * tree-vect-generic.c: Likewise.
29942 * tree-vect-loop.c: Likewise.
29943 * tree-vect-slp.c: Likewise.
29944 * tree-vect-stmts.c: Likewise.
29945 * config/aarch64/aarch64-protos.h (aarch64_expand_vec_perm_const):
29946 Delete.
29947 * config/aarch64/aarch64-simd.md (vec_perm_const<mode>): Delete.
29948 * config/aarch64/aarch64.c (aarch64_expand_vec_perm_const)
29949 (aarch64_vectorize_vec_perm_const_ok): Fuse into...
29950 (aarch64_vectorize_vec_perm_const): ...this new function.
29951 (TARGET_VECTORIZE_VEC_PERM_CONST_OK): Delete.
29952 (TARGET_VECTORIZE_VEC_PERM_CONST): Redefine.
29953 * config/arm/arm-protos.h (arm_expand_vec_perm_const): Delete.
29954 * config/arm/vec-common.md (vec_perm_const<mode>): Delete.
29955 * config/arm/arm.c (TARGET_VECTORIZE_VEC_PERM_CONST_OK): Delete.
29956 (TARGET_VECTORIZE_VEC_PERM_CONST): Redefine.
29957 (arm_expand_vec_perm_const, arm_vectorize_vec_perm_const_ok): Merge
29958 into...
29959 (arm_vectorize_vec_perm_const): ...this new function. Explicitly
29960 check for NEON modes.
29961 * config/i386/i386-protos.h (ix86_expand_vec_perm_const): Delete.
29962 * config/i386/sse.md (VEC_PERM_CONST, vec_perm_const<mode>): Delete.
29963 * config/i386/i386.c (ix86_expand_vec_perm_const_1): Update comment.
29964 (ix86_expand_vec_perm_const, ix86_vectorize_vec_perm_const_ok): Merge
29965 into...
29966 (ix86_vectorize_vec_perm_const): ...this new function. Incorporate
29967 the old VEC_PERM_CONST conditions.
29968 * config/ia64/ia64-protos.h (ia64_expand_vec_perm_const): Delete.
29969 * config/ia64/vect.md (vec_perm_const<mode>): Delete.
29970 * config/ia64/ia64.c (ia64_expand_vec_perm_const)
29971 (ia64_vectorize_vec_perm_const_ok): Merge into...
29972 (ia64_vectorize_vec_perm_const): ...this new function.
29973 * config/mips/loongson.md (vec_perm_const<mode>): Delete.
29974 * config/mips/mips-msa.md (vec_perm_const<mode>): Delete.
29975 * config/mips/mips-ps-3d.md (vec_perm_constv2sf): Delete.
29976 * config/mips/mips-protos.h (mips_expand_vec_perm_const): Delete.
29977 * config/mips/mips.c (mips_expand_vec_perm_const)
29978 (mips_vectorize_vec_perm_const_ok): Merge into...
29979 (mips_vectorize_vec_perm_const): ...this new function.
29980 * config/powerpcspe/altivec.md (vec_perm_constv16qi): Delete.
29981 * config/powerpcspe/paired.md (vec_perm_constv2sf): Delete.
29982 * config/powerpcspe/spe.md (vec_perm_constv2si): Delete.
29983 * config/powerpcspe/vsx.md (vec_perm_const<mode>): Delete.
29984 * config/powerpcspe/powerpcspe-protos.h (altivec_expand_vec_perm_const)
29985 (rs6000_expand_vec_perm_const): Delete.
29986 * config/powerpcspe/powerpcspe.c (TARGET_VECTORIZE_VEC_PERM_CONST_OK):
29987 Delete.
29988 (TARGET_VECTORIZE_VEC_PERM_CONST): Redefine.
29989 (altivec_expand_vec_perm_const_le): Take each operand individually.
29990 Operate on constant selectors rather than rtxes.
29991 (altivec_expand_vec_perm_const): Likewise. Update call to
29992 altivec_expand_vec_perm_const_le.
29993 (rs6000_expand_vec_perm_const): Delete.
29994 (rs6000_vectorize_vec_perm_const_ok): Delete.
29995 (rs6000_vectorize_vec_perm_const): New function.
29996 (rs6000_do_expand_vec_perm): Take a vec_perm_builder instead of
29997 an element count and rtx array.
29998 (rs6000_expand_extract_even): Update call accordingly.
29999 (rs6000_expand_interleave): Likewise.
30000 * config/rs6000/altivec.md (vec_perm_constv16qi): Delete.
30001 * config/rs6000/paired.md (vec_perm_constv2sf): Delete.
30002 * config/rs6000/vsx.md (vec_perm_const<mode>): Delete.
30003 * config/rs6000/rs6000-protos.h (altivec_expand_vec_perm_const)
30004 (rs6000_expand_vec_perm_const): Delete.
30005 * config/rs6000/rs6000.c (TARGET_VECTORIZE_VEC_PERM_CONST_OK): Delete.
30006 (TARGET_VECTORIZE_VEC_PERM_CONST): Redefine.
30007 (altivec_expand_vec_perm_const_le): Take each operand individually.
30008 Operate on constant selectors rather than rtxes.
30009 (altivec_expand_vec_perm_const): Likewise. Update call to
30010 altivec_expand_vec_perm_const_le.
30011 (rs6000_expand_vec_perm_const): Delete.
30012 (rs6000_vectorize_vec_perm_const_ok): Delete.
30013 (rs6000_vectorize_vec_perm_const): New function. Remove stray
30014 reference to the SPE evmerge intructions.
30015 (rs6000_do_expand_vec_perm): Take a vec_perm_builder instead of
30016 an element count and rtx array.
30017 (rs6000_expand_extract_even): Update call accordingly.
30018 (rs6000_expand_interleave): Likewise.
30019 * config/sparc/sparc.md (vec_perm_constv8qi): Delete in favor of...
30020 * config/sparc/sparc.c (sparc_vectorize_vec_perm_const): ...this
30021 new function.
30022 (TARGET_VECTORIZE_VEC_PERM_CONST): Redefine.
30023
30024 2018-01-02 Richard Sandiford <richard.sandiford@linaro.org>
30025
30026 * optabs.c (expand_vec_perm_1): Assert that SEL has an integer
30027 vector mode and that that mode matches the mode of the data
30028 being permuted.
30029 (expand_vec_perm): Split handling of non-CONST_VECTOR selectors
30030 out into expand_vec_perm_var. Do all CONST_VECTOR handling here,
30031 directly using expand_vec_perm_1 when forcing selectors into
30032 registers.
30033 (expand_vec_perm_var): New function, split out from expand_vec_perm.
30034
30035 2018-01-02 Richard Sandiford <richard.sandiford@linaro.org>
30036
30037 * optabs-query.h (can_vec_perm_p): Delete.
30038 (can_vec_perm_var_p, can_vec_perm_const_p): Declare.
30039 * optabs-query.c (can_vec_perm_p): Split into...
30040 (can_vec_perm_var_p, can_vec_perm_const_p): ...these two functions.
30041 (can_mult_highpart_p): Use can_vec_perm_const_p to test whether a
30042 particular selector is valid.
30043 * tree-ssa-forwprop.c (simplify_vector_constructor): Likewise.
30044 * tree-vect-data-refs.c (vect_grouped_store_supported): Likewise.
30045 (vect_grouped_load_supported): Likewise.
30046 (vect_shift_permute_load_chain): Likewise.
30047 * tree-vect-slp.c (vect_build_slp_tree_1): Likewise.
30048 (vect_transform_slp_perm_load): Likewise.
30049 * tree-vect-stmts.c (perm_mask_for_reverse): Likewise.
30050 (vectorizable_bswap): Likewise.
30051 (vect_gen_perm_mask_checked): Likewise.
30052 * fold-const.c (fold_ternary_loc): Likewise. Don't take
30053 implementations of variable permutation vectors into account
30054 when deciding which selector to use.
30055 * tree-vect-loop.c (have_whole_vector_shift): Don't check whether
30056 vec_perm_const_optab is supported; instead use can_vec_perm_const_p
30057 with a false third argument.
30058 * tree-vect-generic.c (lower_vec_perm): Use can_vec_perm_const_p
30059 to test whether the constant selector is valid and can_vec_perm_var_p
30060 to test whether a variable selector is valid.
30061
30062 2018-01-02 Richard Sandiford <richard.sandiford@linaro.org>
30063
30064 * optabs-query.h (can_vec_perm_p): Take a const vec_perm_indices *.
30065 * optabs-query.c (can_vec_perm_p): Likewise.
30066 * fold-const.c (fold_vec_perm): Take a const vec_perm_indices &
30067 instead of vec_perm_indices.
30068 * tree-vectorizer.h (vect_gen_perm_mask_any): Likewise,
30069 (vect_gen_perm_mask_checked): Likewise,
30070 * tree-vect-stmts.c (vect_gen_perm_mask_any): Likewise,
30071 (vect_gen_perm_mask_checked): Likewise,
30072
30073 2018-01-02 Richard Sandiford <richard.sandiford@linaro.org>
30074
30075 * optabs-query.h (qimode_for_vec_perm): Declare.
30076 * optabs-query.c (can_vec_perm_p): Split out qimode search to...
30077 (qimode_for_vec_perm): ...this new function.
30078 * optabs.c (expand_vec_perm): Use qimode_for_vec_perm.
30079
30080 2018-01-02 Aaron Sawdey <acsawdey@linux.vnet.ibm.com>
30081
30082 * rtlanal.c (canonicalize_condition): Return 0 if final rtx
30083 does not have a conditional at the top.
30084
30085 2018-01-02 Richard Biener <rguenther@suse.de>
30086
30087 * ipa-inline.c (big_speedup_p): Fix expression.
30088
30089 2018-01-02 Jan Hubicka <hubicka@ucw.cz>
30090
30091 PR target/81616
30092 * config/i386/x86-tune-costs.h: Increase cost of integer load costs
30093 for generic 4->6.
30094
30095 2018-01-02 Jan Hubicka <hubicka@ucw.cz>
30096
30097 PR target/81616
30098 Generic tuning.
30099 * x86-tune-costs.h (generic_cost): Reduce cost of FDIV 20->17,
30100 cost of sqrt 20->14, DIVSS 18->13, DIVSD 32->17, SQRtSS 30->14
30101 and SQRTsD 58->18, cond_not_taken_branch_cost. 2->1. Increase
30102 cond_taken_branch_cost 3->4.
30103
30104 2018-01-01 Jakub Jelinek <jakub@redhat.com>
30105
30106 PR tree-optimization/83581
30107 * tree-loop-distribution.c (pass_loop_distribution::execute): Return
30108 TODO_cleanup_cfg if any changes have been made.
30109
30110 PR middle-end/83608
30111 * expr.c (store_expr_with_bounds): Use simplify_gen_subreg instead of
30112 convert_modes if target mode has the right side, but different mode
30113 class.
30114
30115 PR middle-end/83609
30116 * expr.c (expand_assignment): Fix up a typo in simplify_gen_subreg
30117 last argument when extracting from CONCAT. If either from_real or
30118 from_imag is NULL, use expansion through memory. If result is not
30119 a CONCAT and simplify_gen_subreg fails, try to simplify_gen_subreg
30120 the parts directly to inner mode, if even that fails, use expansion
30121 through memory.
30122
30123 PR middle-end/83623
30124 * expmed.c (expand_shift_1): For 2-byte rotates by BITS_PER_UNIT,
30125 check for bswap in mode rather than HImode and use that in expand_unop
30126 too.
30127 \f
30128 Copyright (C) 2018 Free Software Foundation, Inc.
30129
30130 Copying and distribution of this file, with or without modification,
30131 are permitted in any medium without royalty provided the copyright
30132 notice and this notice are preserved.